utilities: Tweak python shebangs to use env
authorYAMAMOTO Takashi <yamamoto@ovn.org>
Fri, 13 May 2016 14:36:15 +0000 (14:36 +0000)
committerYAMAMOTO Takashi <yamamoto@ovn.org>
Fri, 20 May 2016 06:13:59 +0000 (15:13 +0900)
"python" command provided by pkg_alternatives is a shell script.
At least on NetBSD-7, execve can't execute scripts whose interpreter
is another shell script.  (While some "rich" shells like zsh seem
to have handle the case by itself, NetBSD's /bin/sh doesn't.)
Workaround the issue by using env command for shebangs for
these scripts.

Noticed with the recent tunnel-push-pop.at tests using ovs-pcap command.

Signed-off-by: YAMAMOTO Takashi <yamamoto@ovn.org>
Acked-by: Ben Pfaff <blp@ovn.org>
utilities/ovs-check-dead-ifs.in
utilities/ovs-dpctl-top.in
utilities/ovs-l3ping.in
utilities/ovs-parse-backtrace.in
utilities/ovs-pcap.in
utilities/ovs-tcpundump.in
utilities/ovs-test.in
utilities/ovs-vlan-test.in

index ac54f6c..127ba38 100755 (executable)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 
 import os
 import re
index 7f0f1f8..401a80e 100755 (executable)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Copyright (c) 2013 Nicira, Inc.
 #
index 1b07972..38ac491 100644 (file)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
index 350cbd9..c8a4385 100755 (executable)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Copyright (c) 2012 Nicira, Inc.
 #
index ae30047..98b8d53 100755 (executable)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Copyright (c) 2010 Nicira, Inc.
 #
index 57300cd..46e1d74 100755 (executable)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Copyright (c) 2010 Nicira, Inc.
 #
index fb1f9ad..46ad6fa 100644 (file)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
index e229498..7a89936 100755 (executable)
@@ -1,4 +1,4 @@
-#! @PYTHON@
+#! /usr/bin/env @PYTHON@
 #
 # Copyright (c) 2010 Nicira, Inc.
 #