]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
use pkg-config to ensure python3-devel is installed
authorDwight Engen <dwight.engen@oracle.com>
Thu, 10 Jan 2013 20:45:22 +0000 (15:45 -0500)
committerStéphane Graber <stgraber@ubuntu.com>
Fri, 11 Jan 2013 17:45:48 +0000 (12:45 -0500)
The Python.h header varies in location by distribution, so instead use
pkg-config to ensure the python3 devel package is installed. Tested with
Ubuntu 12.04 and Fedora 17. Fixes --enable-python on Fedora 17.

Signed-off-by: Dwight Engen <dwight.engen@oracle.com>
Acked-by: Stéphane Graber <stgraber@ubuntu.com>
configure.ac

index 0089f93ebb37bdd79112c0b27317fc6bf1e003b1..1df24f3f4be19b56abb639a3fa65436790269e5c 100644 (file)
@@ -134,7 +134,7 @@ AM_CONDITIONAL([ENABLE_PYTHON], [test "x$enable_python" = "xyes"])
 
 AM_COND_IF([ENABLE_PYTHON],
        [AM_PATH_PYTHON([3.2], [], [AC_MSG_ERROR([You must install python3])])
-       AC_CHECK_HEADER([python$PYTHON_VERSION/Python.h],[],[AC_MSG_ERROR([You must install python3-dev])])
+       PKG_CHECK_MODULES([PYTHONDEV], [python3 >= 3.2],[],[AC_MSG_ERROR([You must install python3-dev])])
        AC_DEFINE_UNQUOTED([ENABLE_PYTHON], 1, [Python3 is available])])
 
 # Optional test binaries