summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorWilliam S Fulton <wsf@fultondesigns.co.uk>2018-04-30 19:42:54 +0100
committerWilliam S Fulton <wsf@fultondesigns.co.uk>2018-05-04 20:02:13 +0100
commit44f599bb6f3dbbb6d9488f214d92c65fdf17114e (patch)
tree2b8acdf5eb14a091b785c7f611d3ebe67cbc4e2b /configure.ac
parent7774cdf71ffec3d13980bcc2ec4f00ff912cdede (diff)
downloadswig-44f599bb6f3dbbb6d9488f214d92c65fdf17114e.tar.gz
Improve detection of Python's 2to3 tool
Distributions seem to install it as 2to3-X.Y where the interpreter is installed as pythonX.Y
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac3
1 files changed, 2 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index bdfdcbb7a..0a90d39f5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -904,7 +904,8 @@ fi
AC_ARG_WITH(2to3, AS_HELP_STRING([--with-2to3=path], [Set location of Python 2to3 tool]), [PY2TO3BIN="$withval"], [PY2TO3BIN="yes"])
if test -n "$PYTHON3"; then
if test "x$PY2TO3BIN" = xyes; then
- AC_CHECK_PROGS(PY2TO3, 2to3)
+ py3to2=`echo $PYTHON3 | sed -e "s/python/2to3-/"`
+ AC_CHECK_PROGS(PY2TO3, $py3to2 2to3)
else
PY2TO3="$PY2TO3BIN"
fi