Hi Automake experts, On macOS, if CPython is configured with --enable-framework (default for MacPorts [1]), Python packages should be installed in ${prefix}/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages. However, AM_PATH_PYTHON gives pythondir=${prefix}/lib/python3.7/site-packages.
Here's a minimal example configure.ac: AC_PREREQ(2.57) AC_INIT([automake-python-test], 0.1) AM_INIT_AUTOMAKE([foreign]) AM_PATH_PYTHON([2.7]) AC_CONFIG_FILES([Makefile]) The issue appears to be that AM_PATH_PYTHON overwrites the 'base' variable. If we remove this overwrite like [2], pythondir contains the correct path. Related bug report in MacPorts: https://trac.macports.org/ticket/57329 Regards, Chih-Hsuan Yen [1] https://github.com/macports/macports-ports/blob/834d761210be0d989076000c454a4a1e32209af5/lang/python37/Portfile#L57 [2] https://github.com/macports/macports-ports/blob/master/devel/automake/files/patch-issue57329.diff