From: Richard Kreckel Date: Sun, 23 Aug 2020 14:09:34 +0000 (+0200) Subject: [build] Fix Python detection in Autotools build. X-Git-Tag: release_1-8-0~24 X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=commitdiff_plain;h=67111f007a38497508b72603408b8f59a8e110a5;hp=7550e991907e1bd8dad50bfdb5af2ff2f312af8f [build] Fix Python detection in Autotools build. This was a latent bug: the PYTHON variable was not set in Makefiles, only PYTHON3 was, but scripts were still invoked with $(PYTHON). While at it, let's also accept python2 >= 2.7. --- diff --git a/configure.ac b/configure.ac index 32ba1485..3529a65e 100644 --- a/configure.ac +++ b/configure.ac @@ -59,10 +59,9 @@ dnl Check for stuff needed for building the GiNaC interactive shell (ginsh). AC_CHECK_HEADERS(unistd.h) GINAC_HAVE_RUSAGE GINAC_READLINE -dnl Python3 is necessary for building function.{cpp,h} -AC_PATH_PROG(PYTHON3, python3, "") -AS_IF([test -z "$PYTHON3" -a ! -f "$srcdir/ginac/function.cpp"], - [AC_MSG_ERROR([GiNaC will not compile because Python3 is missing])]) +dnl Python is necessary for building function.{cpp,h} +AM_PATH_PYTHON([2.7],, + [AC_MSG_ERROR([GiNaC will not compile because Python is missing])]) dnl Check for dl library (needed for GiNaC::compile). GINAC_EXCOMPILER