Regression introduced in commit 53cb23f4. * configure.ac: Let --with-python default to check. --- configure.ac | 29 ++++++++++++++++++++--------- 1 files changed, 20 insertions(+), 9 deletions(-) diff --git a/configure.ac b/configure.ac index dcec371..1fdcf27 100644 --- a/configure.ac +++ b/configure.ac @@ -1820,12 +1820,12 @@ dnl check for python dnl AC_ARG_WITH([python], - AC_HELP_STRING([--with-python], [Build python bindings @<:@default=yes@:>@]),[],[with_python=yes]) + AC_HELP_STRING([--with-python], + [Build python bindings @<:@default=check@:>@]),[],[with_python=check]) if test "$enable_shared:$with_python" = no:yes; then - AC_MSG_WARN([Disabling shared libraries is incompatible with building Python extensions.]) - AC_MSG_WARN([Ignoring --with-python.]) - with_python=no + AC_MSG_ERROR([Disabling shared libraries is incompatible with building + Python extensions.]) fi PYTHON_VERSION= @@ -1851,7 +1851,7 @@ if test "$with_python" != "no" ; then fi fi - if test "$with_python" = "yes" ; then + if test "$with_python" = "yes" || test "$with_python" = "check"; then AM_PATH_PYTHON(,, [:]) if test "$PYTHON" != : ; then @@ -1860,30 +1860,41 @@ if test "$with_python" != "no" ; then if test -x "$PYTHON_CONFIG" then PYTHON_INCLUDES=`$PYTHON_CONFIG --includes` + with_python=yes else if test -r $PYTHON_EXEC_PREFIX/include/python$PYTHON_VERSION/Python.h then PYTHON_INCLUDES=-I$PYTHON_EXEC_PREFIX/include/python$PYTHON_VERSION + with_python=yes else if test -r $prefix/include/python$PYTHON_VERSION/Python.h then PYTHON_INCLUDES=-I$prefix/include/python$PYTHON_VERSION + with_python=yes else if test -r /usr/include/python$PYTHON_VERSION/Python.h then PYTHON_INCLUDES=-I/usr/include/python$PYTHON_VERSION + with_python=yes + elif test "$with_python" = "yes"; then + AC_MSG_ERROR([You must install python-devel to + build Python bindings]) else - AC_MSG_ERROR([You must install python-devel to build Python bindings]) + AC_MSG_WARN([Could not find python-devel, disabling + bindings]) + with_python=no fi fi fi fi - else + elif test "$with_python" = "yes"; then AC_MSG_ERROR([You must install python to build Python bindings]) + else + AC_MSG_WARN([Could not find python, disabling bindings]) + with_python=no fi else - AC_MSG_NOTICE([Could not find python in $with_python, disabling bindings]) - with_python=no + AC_MSG_ERROR([Could not find python in $with_python]) fi fi AM_CONDITIONAL([WITH_PYTHON], [test "$with_python" = "yes"]) -- 1.7.4.4 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list