From: Daniel Hokka Zakrisson Date: Wed, 29 Oct 2008 18:37:15 +0000 (+0000) Subject: Just in case anything else wants to use Python as part of the build process. X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b6e49b3a7d123c5616559e1016bed82a78c9ee58;p=util-vserver.git Just in case anything else wants to use Python as part of the build process. git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2805 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- diff --git a/configure.ac b/configure.ac index dfb44a1..5fd23e5 100644 --- a/configure.ac +++ b/configure.ac @@ -453,22 +453,27 @@ dnl ######################## dnl Check for Python AM_PATH_PYTHON(,, [:]) +if test "x$PYTHON" != x:; then + ensc_have_python=true +else + ensc_have_python=false +fi ensc_python_config=python-config AC_ARG_WITH(python, AC_HELP_STRING([--with-python=FILE], [use FILE to query Python build details (default: python-config)]), [ case "$withval" in - (no) PYTHON=:;; + (no) ensc_have_python=false;; (yes) ;; (*) ensc_python_config="$withval";; esac]) -if $ensc_python_config --cflags > /dev/null 2>&1; then +if $ensc_have_python && $ensc_python_config --cflags > /dev/null 2>&1; then PYTHON_CFLAGS=`$ensc_python_config --cflags` PYTHON_LDFLAGS=`$ensc_python_config --ldflags` AC_SUBST(PYTHON_CFLAGS) AC_SUBST(PYTHON_LDFLAGS) else - PYTHON=: + ensc_have_python=false fi -AM_CONDITIONAL([HAVE_PYTHON], [test "x$PYTHON" != x:]) +AM_CONDITIONAL([HAVE_PYTHON], [$ensc_have_python]) dnl Python stuff ends here dnl ########################