Skip to content

Commit

Permalink
m4: Try to use "python" as Python2 interpreter only as last resort
Browse files Browse the repository at this point in the history
This patch tries to find Python 2 as "python2", then "python2.7" and finally
"python".

This is needed since "/usr/bin/python" is used as Python 3 on some Linux
distributions (for example on Arch Linux) and on Fedora 28
"/usr/bin/python" will be deprecated [1]:
    "All scripts shall explicitly use /usr/bin/python2."

[1] https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3

Signed-off-by: Timothy Redaelli <[email protected]>
Signed-off-by: Ben Pfaff <[email protected]>
  • Loading branch information
drizzt authored and blp committed Mar 8, 2018
1 parent d130958 commit 2c6761d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion m4/openvswitch.m4
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ AC_DEFUN([OVS_CHECK_PYTHON],
ovs_cv_python=$PYTHON
else
ovs_cv_python=no
for binary in python python2.7; do
for binary in python2 python2.7 python; do
ovs_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for dir in $PATH; do
IFS=$ovs_save_IFS
Expand Down

0 comments on commit 2c6761d

Please sign in to comment.