mirror of
https://gitlab.com/apparmor/apparmor.git
synced 2025-03-04 08:24:42 +01:00
Subject: libapparmor - fail configure if interpreter for lang bindings not found
This patch causes libapparmor's configure script to exit with an error if a language binding is asked for and the relevant interpreter is not found. The previous behavior was to *silently* disable the binding. Signed-off-by: Steve Beattie <steve@nxnw.org> Acked-by: Tyler Hicks <tyhicks@canonical.com>
This commit is contained in:
parent
e5ce6f92ac
commit
54b6b527c7
1 changed files with 10 additions and 15 deletions
|
@ -23,14 +23,11 @@ AC_ARG_WITH(python,
|
|||
[AC_MSG_RESULT($withval)], [AC_MSG_RESULT(no)])
|
||||
if test "$with_python" = "yes"; then
|
||||
test -z "$SWIG" && AC_MSG_ERROR([swig is required when enabling python bindings])
|
||||
AC_PATH_PROG(PYTHON, python, no)
|
||||
if test x$PYTHON = xno; then
|
||||
enable_python = no
|
||||
else
|
||||
sinclude(m4/ac_python_devel.m4)
|
||||
AC_PYTHON_DEVEL
|
||||
AM_PATH_PYTHON
|
||||
fi
|
||||
AC_PATH_PROG(PYTHON, python)
|
||||
test -z "$PYTHON" && AC_MSG_ERROR([python is required when enabling python bindings])
|
||||
sinclude(m4/ac_python_devel.m4)
|
||||
AC_PYTHON_DEVEL
|
||||
AM_PATH_PYTHON
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING(Checking for perl)
|
||||
|
@ -39,13 +36,10 @@ AC_ARG_WITH(perl,
|
|||
[AC_MSG_RESULT($withval)], [AC_MSG_RESULT(no)])
|
||||
if test "$with_perl" = "yes"; then
|
||||
test -z "$SWIG" && AC_MSG_ERROR([swig is required when enabling perl bindings])
|
||||
AC_PATH_PROG(PERL, perl, no)
|
||||
if test x$PERL = xno; then
|
||||
enable_perl=no
|
||||
else
|
||||
perl_includedir="`$PERL -e 'use Config; print $Config{archlib}'`/CORE"
|
||||
AC_CHECK_FILE($perl_includedir/perl.h, enable_perl=yes, enable_perl=no)
|
||||
fi
|
||||
AC_PATH_PROG(PERL, perl)
|
||||
test -z "$PERL" && AC_MSG_ERROR([perl is required when enabling perl bindings])
|
||||
perl_includedir="`$PERL -e 'use Config; print $Config{archlib}'`/CORE"
|
||||
AC_CHECK_FILE($perl_includedir/perl.h, enable_perl=yes, enable_perl=no)
|
||||
fi
|
||||
|
||||
|
||||
|
@ -56,6 +50,7 @@ AC_ARG_WITH(ruby,
|
|||
if test "$with_ruby" = "yes"; then
|
||||
test -z "$SWIG" && AC_MSG_ERROR([swig is required when enabling ruby bindings])
|
||||
AC_PATH_PROG([RUBY], [ruby])
|
||||
test -z "$RUBY" && AC_MSG_ERROR([ruby is required when enabling ruby bindings])
|
||||
fi
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue