Hi, With automake master, on an Ubuntu 22.04 system (with Python 3.10), I get a reproducible test failure:
FAIL: t/python-prefix Find the log below. If I understand it correctly, the problem is that the test's lines py_inst_site=inst/lib/python$py_version/site-packages and py_installed "$py_inst_site"/one.py expect that "make install" creates a file inst/lib/python3.10/site-packages/one.py . But that's not what it does. Instead it creates a file inst/local/lib/python3.10/dist-packages/one.py Note the two relevant differences: - a 'local/' has been inserted, - 'site-packages' has been replaced with 'dist-packages'. Here's the full file list after "make install": $ find inst -type f | LC_ALL=C sort inst/local/lib/python3.10/dist-packages/__pycache__/one.cpython-310.opt-1.pyc inst/local/lib/python3.10/dist-packages/__pycache__/one.cpython-310.opt-2.pyc inst/local/lib/python3.10/dist-packages/__pycache__/one.cpython-310.pyc inst/local/lib/python3.10/dist-packages/one.py inst/local/lib/python3.10/dist-packages/python-prefix/__pycache__/pkgtwo.cpython-310.opt-1.pyc inst/local/lib/python3.10/dist-packages/python-prefix/__pycache__/pkgtwo.cpython-310.opt-2.pyc inst/local/lib/python3.10/dist-packages/python-prefix/__pycache__/pkgtwo.cpython-310.pyc inst/local/lib/python3.10/dist-packages/python-prefix/pkgtwo.py There's some discussion about this 'local/' part in https://bugzilla.redhat.com/show_bug.cgi?id=2026979 Probably also relevant: https://stackoverflow.com/questions/9387928/ Bruno =============================== test-suite.log =============================== FAIL: t/python-prefix ===================== python-prefix: running python -V Python 3.10.6 Running from installcheck: no Test Protocol: none PATH = /AUTOMAKE/automake/bin:/AUTOMAKE/automake/t/ax:/arch/x86_64-linux-gnu/gnu-inst-autoconf/2.72-20230624/bin:/home/bruno/bin:/darch/x86_64-linux-gnu/gnu/bin:/arch/local/x86_64-linux-gnu/bin:/arch/local/x86_64-linux/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin ++ pwd /AUTOMAKE/automake/t/python-prefix.dir + cat + cat + test -z python + py_exec=python ++ python -c 'import sys; print("%u.%u" % sys.version_info[:2])' + py_version=3.10 + py_inst_site=inst/lib/python3.10/site-packages + py_instexec_site=instexec/lib/python3.10/site-packages + aclocal-1.16 -Werror + autoconf + automake-1.16 --foreign -Werror -Wall --add-missing Makefile.am:2: installing './py-compile' + mkdir build + cd build ++ pwd + ../configure --with-python_prefix=/AUTOMAKE/automake/t/python-prefix.dir/build/inst checking for a BSD-compatible install... /arch/local/x86_64-linux/bin/install -c checking whether sleep supports fractional seconds... true checking the filesystem timestamp resolution... 0.2 checking whether build environment is sane... yes checking for a race-free mkdir -p... /arch/local/x86_64-linux/bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking xargs -n works... yes checking for python... /home/bruno/bin/python checking for python version... 3.10 checking for python platform... linux checking for explicit python prefix... /AUTOMAKE/automake/t/python-prefix.dir/build/inst checking for python_prefix-given python exec_prefix... /AUTOMAKE/automake/t/python-prefix.dir/build/inst checking for python script directory (pythondir)... ${PYTHON_PREFIX}/local/lib/python3.10/dist-packages checking for python extension module directory (pyexecdir)... ${PYTHON_EXEC_PREFIX}/local/lib/python3.10/dist-packages checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile + make install make[1]: Entering directory '/AUTOMAKE/automake/t/python-prefix.dir/build' make[1]: Nothing to be done for 'install-exec-am'. echo 'def pkgtwo(): return 1' >pkgtwo.py || rm -f pkgtwo.py /arch/local/x86_64-linux/bin/mkdir -p '/AUTOMAKE/automake/t/python-prefix.dir/build/inst/local/lib/python3.10/dist-packages/python-prefix' /arch/local/x86_64-linux/bin/install -c -m 644 pkgtwo.py '/AUTOMAKE/automake/t/python-prefix.dir/build/inst/local/lib/python3.10/dist-packages/python-prefix' Byte-compiling python modules... pkgtwo.py Byte-compiling python modules (optimized versions) ... pkgtwo.py Byte-compiling python modules (more optimized versions) ... pkgtwo.py echo 'def one(): return 1' >one.py || rm -f one.py /arch/local/x86_64-linux/bin/mkdir -p '/AUTOMAKE/automake/t/python-prefix.dir/build/inst/local/lib/python3.10/dist-packages' /arch/local/x86_64-linux/bin/install -c -m 644 one.py '/AUTOMAKE/automake/t/python-prefix.dir/build/inst/local/lib/python3.10/dist-packages' Byte-compiling python modules... one.py Byte-compiling python modules (optimized versions) ... one.py Byte-compiling python modules (more optimized versions) ... one.py make[1]: Leaving directory '/AUTOMAKE/automake/t/python-prefix.dir/build' + py_installed inst/lib/python3.10/site-packages/one.py + case $#,$1 in + am_test_py_file='test -f' + case $1 in + am_target_py_file=inst/lib/python3.10/site-packages/one.py + test -f inst/lib/python3.10/site-packages/one.py + am_exit_trap 1 + exit_status=1 + set +e + cd /AUTOMAKE/automake + test none = tap + case $am_explicit_skips in + test 1 -eq 0 + keep_testdirs=yes + am_keeping_testdirs + case $keep_testdirs in + return 0 + set +x FAIL t/python-prefix.sh (exit status: 1)