From b1b92468d8e80bae2e5337fc6a8f15c6f340829d Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 20 Aug 2012 20:54:42 +0700 Subject: [PATCH] Fix out-of-tree build of modperl/modpython. It was broken when compiling from tarball (where swig files already exist), but with swig around --- configure.ac | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 43477453..5cfc4654 100644 --- a/configure.ac +++ b/configure.ac @@ -343,8 +343,12 @@ if test "x$PERL" != xno -o "x$PYTHON" != xno; then AC_MSG_ERROR([Could not found appropriate SWIG installation. Check config.log for details.]) fi fi + if test -r "$srcdir/modules/modperl/ZNC.cpp" -a -r "$srcdir/modules/modpython/_znc_core.cpp"; then + AC_MSG_NOTICE([modperl/modpython files are found, disabling SWIG]) + USESWIG=no + fi if test "x$USESWIG" = xno; then - if test "(" "x$PERL" != xno -a ! -r "$srcdir/modules/modperl/ZNC.cpp" ")" -o "(" "x$PYTHON" != xno -a ! -r "$srcdir/modules/modpython/_znc_core.cpp" ")"; then + if test ! -r "$srcdir/modules/modperl/ZNC.cpp" -o ! -r "$srcdir/modules/modpython/_znc_core.cpp"; then AC_MSG_ERROR([Can not build modperl/modpython. Either install SWIG, or build ZNC from a tarball, or disable modperl/modpython. Check config.log for details.]) else AC_MSG_NOTICE([modperl/modpython files are found, no SWIG needed])