Using "/usr/bin/env" is against Fedora Packaging Guidelines [1].

Moreover, in this specific case, it also prevent "make rpm-fedora" to
successfully complete on "Fedora Rawhide" since "#!/usr/bin/env python"
must not be used anymore [2].

[1] https://fedoraproject.org/wiki/Packaging:Guidelines#Shebang_lines
[2] https://fedoraproject.org/wiki/Changes/Make_ambiguous_python_shebangs_error

CC: Qiuyu Xiao <[email protected]>
Fixes: 22c5eafb6efa ("ipsec: reintroduce IPsec support for tunneling")
Signed-off-by: Timothy Redaelli <[email protected]>
---
Detected by my Fedora/CentOS nigthly CI: https://gitlab.com/drizzt/ovs/pipelines
---
 ipsec/automake.mk                                 | 7 +++++--
 ipsec/{ovs-monitor-ipsec => ovs-monitor-ipsec.in} | 2 +-
 2 files changed, 6 insertions(+), 3 deletions(-)
 rename ipsec/{ovs-monitor-ipsec => ovs-monitor-ipsec.in} (99%)

diff --git a/ipsec/automake.mk b/ipsec/automake.mk
index 1e530cb42..445b37ac9 100644
--- a/ipsec/automake.mk
+++ b/ipsec/automake.mk
@@ -5,6 +5,9 @@
 # notice and this notice are preserved.  This file is offered as-is,
 # without warranty of any kind.
 
-EXTRA_DIST += \
+bin_SCRIPTS += \
         ipsec/ovs-monitor-ipsec
-FLAKE8_PYFILES += ipsec/ovs-monitor-ipsec
+
+EXTRA_DIST += \
+        ipsec/ovs-monitor-ipsec.in
+FLAKE8_PYFILES += ipsec/ovs-monitor-ipsec.in
diff --git a/ipsec/ovs-monitor-ipsec b/ipsec/ovs-monitor-ipsec.in
similarity index 99%
rename from ipsec/ovs-monitor-ipsec
rename to ipsec/ovs-monitor-ipsec.in
index c93081d32..4710be039 100755
--- a/ipsec/ovs-monitor-ipsec
+++ b/ipsec/ovs-monitor-ipsec.in
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#! @PYTHON@
 # Copyright (c) 2017 Nicira, Inc.
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
-- 
2.19.1

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to