]> git.ipfire.org Git - pakfire.git/commitdiff
configure: Try to embed Python, but fall back to old behaviour
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 11 Jun 2021 11:02:08 +0000 (11:02 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 11 Jun 2021 11:02:08 +0000 (11:02 +0000)
Python has introduced a new way to embed the library into a module which
is incompatible with older ways. Hence we check for -embed first and
fall back to the "regular" library if the new one could not be found.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
configure.ac

index 612575958d37aa458eb2282897d0dd54549ff94a..ab098707669183b3a1c07fdb07fad97cc5cb377f 100644 (file)
@@ -173,7 +173,8 @@ LIBS="$save_LIBS"
 
 PKG_CHECK_MODULES([ARCHIVE], [libarchive >= 3.3.3])
 PKG_CHECK_MODULES([CURL], [libcurl])
-PKG_CHECK_MODULES([PYTHON_DEVEL], [python-${PYTHON_VERSION}-embed python-${PYTHON_VERSION}])
+PKG_CHECK_MODULES([PYTHON_DEVEL], [python-${PYTHON_VERSION}-embed],
+       [], [PKG_CHECK_MODULES([PYTHON_DEVEL], [python-${PYTHON_VERSION}])])
 PKG_CHECK_MODULES([JSON_C], [json-c])
 PKG_CHECK_MODULES([LZMA], [liblzma])
 PKG_CHECK_MODULES([OPENSSL], [openssl >= 1.1.1])