From dac2b7d4515852e2ab9d90d93b62d0d4de5ca3ad Mon Sep 17 00:00:00 2001 From: Jürgen Knödlseder Date: Fri, 4 Sep 2020 15:18:07 +0200 Subject: [PATCH] Add Python include path in search for Python.h (#3329) --- ChangeLog | 3 ++- configure.ac | 10 ++++++++-- doc/source/admin/release_history/1.7.1.rst | 6 ++++-- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index c4ce8e0..c97b221 100755 --- a/ChangeLog +++ b/ChangeLog @@ -4,11 +4,12 @@ ======================== -2020-08-21 +2020-09-04 * Bug fix version 1.7.1 released ================================ + Add Python include path in search for Python.h (#3329) Test for Big Sur in configuration step (#3326) Copy Python module into pyext/ctools folder (#3322) Add units to reference manual of response cube tools (#3321) diff --git a/configure.ac b/configure.ac index 9bf3d50..741a910 100755 --- a/configure.ac +++ b/configure.ac @@ -686,7 +686,10 @@ else python_path=`$PYTHON -c "import distutils.sysconfig; \ print(distutils.sysconfig.get_python_inc());"` if test -n "${python_path}"; then - AC_CHECK_HEADERS($python_path/Python.h, [has_python_h="yes"], [has_python_h="no"]) + SAVED_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS -I$python_path" + AC_CHECK_HEADERS($python_path/Python.h, [has_python_h="yes"], [has_python_h="no"]) + CPPFLAGS=$SAVED_CPPFLAGS python_path="-I$python_path" fi PYTHON_CPPFLAGS=$python_path @@ -727,8 +730,11 @@ else PY_INCLUDE="$PY_INCLUDE$PYTHON_VERSION" # Check if we have Python.h + SAVED_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS -I$PY_INCLUDE" AC_CHECK_HEADERS($PY_INCLUDE/Python.h, [has_python_h="yes"], [has_python_h="no"]) - + CPPFLAGS=$SAVED_CPPFLAGS + # Signal any problem if test "x$has_python_h" = "xno"; then AC_MSG_WARN([No Python header file "$PY_INCLUDE/Python.h" found. Please install appropriate Python development package.]) diff --git a/doc/source/admin/release_history/1.7.1.rst b/doc/source/admin/release_history/1.7.1.rst index fc24fa1..dd0a29f 100644 --- a/doc/source/admin/release_history/1.7.1.rst +++ b/doc/source/admin/release_history/1.7.1.rst @@ -1,7 +1,7 @@ .. _1.7.1: -ctools 1.7.1 release (21 August 2020) -===================================== +ctools 1.7.1 release (4 September 2020) +======================================= Overview -------- @@ -10,6 +10,8 @@ ctools 1.7.1 is a bug fix release for ctools release 1.7. The following bugs were fixed: +* [`3329 `_] - +Add Python include path in search for ``Python.h`` * [`3326 `_] - Test for Big Sur in configuration step * [`3322 `_] - -- libgit2 0.21.4