From 4cbd409508c04855070869017fe3e49c0242c6c9 Mon Sep 17 00:00:00 2001 From: Chris Packham Date: Sun, 29 Oct 2023 14:59:16 +1300 Subject: [PATCH] m4/ctng_python.m4: Use AC_PATH_PROGS for full path We use the information from various configure time checks to populate paths.sh. The paths used are all absolute except for the python binary. In the switch to a more comprehensive check for python by commit fa05153e ("Make checking for python more predictable.") we ended up using AC_CHECK_PROGS which checks for the program on the path and sets the variable to the name of the program. This makes python inconsistent with the other programs and seems to cause problems for MSYS2. Use AC_PATH_PROGS instead which does the same check but sets the variable to the absolute name of the program Fixes #2047 Signed-off-by: Chris Packham --- m4/ctng_python.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/m4/ctng_python.m4 b/m4/ctng_python.m4 index 7f0c9473..a223b2be 100644 --- a/m4/ctng_python.m4 +++ b/m4/ctng_python.m4 @@ -63,7 +63,7 @@ AC_DEFUN([CTNG_PYTHON], for python in python3.12 python3.11 python3.10 python3.9 python3.8 python3.7 dnl python3.6 python3.5 python3.4 python3.3 python3.2 python3.1 python3.0 python2.7 dnl python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python; do - AC_CHECK_PROGS(PYTHON_BIN, [$python]) + AC_PATH_PROGS(PYTHON_BIN, [$python]) ctng_python_bin=$PYTHON_BIN if test "$ctng_python_bin" != ""; then AC_CHECK_LIB($ctng_python_bin, main, ctng_python_lib=$ctng_python_bin, ctng_python_lib=no)