X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=blobdiff_plain;f=configure.ac;h=d6472a52570ba443b4334749c4a450b34f6cbf68;hp=f6fb661e7dbb273e9b7c586342c7c6546d1c7b9d;hb=e3acf93ce9e87ce308cf50a4f41408b25dd910e9;hpb=3a7eb8ebdb47878ab9bd6b8aff88744365179f87 diff --git a/configure.ac b/configure.ac index f6fb661..d6472a5 100644 --- a/configure.ac +++ b/configure.ac @@ -18,7 +18,7 @@ # major/minor/release must be numbers m4_define([libguestfs_major], [1]) m4_define([libguestfs_minor], [7]) -m4_define([libguestfs_release], [2]) +m4_define([libguestfs_release], [3]) # extra can be any string m4_define([libguestfs_extra], []) @@ -572,6 +572,9 @@ AS_IF([test "x$enable_python" != "xno"], fi AC_MSG_RESULT([not found]) done + if test "x$PYTHON_INCLUDEDIR" = "x"; then + AC_MSG_WARN([Python include directory not found]) + fi for d in \ $PYTHON_PREFIX/lib64/python$PYTHON_VERSION/site-packages \ @@ -588,6 +591,9 @@ AS_IF([test "x$enable_python" != "xno"], fi AC_MSG_RESULT([not found]) done + if test "x$PYTHON_SITE_PACKAGES" = "x"; then + AC_MSG_WARN([Python site-packages directory not found]) + fi old_LIBS="$LIBS" LIBS="$LIBS -lpython$PYTHON_VERSION" @@ -604,9 +610,15 @@ AM_CONDITIONAL([HAVE_PYTHON], [test "x$PYTHON_INCLUDEDIR" != "x" && test "x$PYTHON_SITE_PACKAGES" != "x"]) dnl Check for Ruby and rake (optional, for Ruby bindings). -AC_CHECK_LIB([ruby],[ruby_init],[HAVE_LIBRUBY=1],[HAVE_LIBRUBY=0]) -AC_CHECK_PROG([RAKE],[rake],[rake],[no]) - +AC_ARG_ENABLE([ruby], + AS_HELP_STRING([--disable-ruby], [Disable Ruby language bindings]), + [], + [enable_ruby=yes]) +AS_IF([test "x$enable_ruby" != "xno"], + [ + AC_CHECK_LIB([ruby],[ruby_init],[HAVE_LIBRUBY=1],[HAVE_LIBRUBY=0]) + AC_CHECK_PROG([RAKE],[rake],[rake],[no]) + ]) AM_CONDITIONAL([HAVE_RUBY], [test "x$RAKE" != "xno" && test -n "$HAVE_LIBRUBY"]) @@ -751,25 +763,50 @@ AC_SUBST(JNI_VERSION_INFO) AM_CONDITIONAL([HAVE_JAVA],[test -n "$JAVAC"]) dnl Check for Haskell (GHC). -AC_CHECK_PROG([GHC],[ghc],[ghc],[no]) - +GHC=no +AC_ARG_ENABLE([haskell], + AS_HELP_STRING([--disable-haskell], [Disable Haskell language bindings]), + [], + [enable_haskell=yes]) +AS_IF([test "x$enable_haskell" != "xno"], + [ + GHC= + AC_CHECK_PROG([GHC],[ghc],[ghc],[no]) + ]) AM_CONDITIONAL([HAVE_HASKELL], [test "x$GHC" != "xno"]) +dnl PHP +PHP=no +AC_ARG_ENABLE([php], + AS_HELP_STRING([--disable-php], [Disable PHP language bindings]), + [], + [enable_php=yes]) +AS_IF([test "x$enable_php" != "xno"], + [ + PHP= + AC_CHECK_PROG([PHP],[php],[php],[no]) + AC_CHECK_PROG([PHPIZE],[phpize],[phpize],[no]) + ]) +AM_CONDITIONAL([HAVE_PHP], [test "x$PHP" != "xno" && test "x$PHPIZE" != "xno"]) + dnl Check for Perl modules needed by virt-df, inspector, etc. -missing_perl_modules=no -for pm in Pod::Usage Getopt::Long Sys::Virt Data::Dumper XML::Writer Locale::TextDomain Win::Hivex Win::Hivex::Regedit; do - AC_MSG_CHECKING([for $pm]) - if ! perl -M$pm -e1 >/dev/null 2>&1; then - AC_MSG_RESULT([no]) - missing_perl_modules=yes - else - AC_MSG_RESULT([yes]) - fi -done -if test "x$missing_perl_modules" = "xyes"; then - AC_MSG_WARN([some Perl modules required to compile virt-inspector and the other virt-* tools are missing]) -fi +AS_IF([test "x$PERL" != "xno"], + [ + missing_perl_modules=no + for pm in Pod::Usage Getopt::Long Sys::Virt Data::Dumper XML::Writer Locale::TextDomain Win::Hivex Win::Hivex::Regedit; do + AC_MSG_CHECKING([for $pm]) + if ! $PERL -M$pm -e1 >/dev/null 2>&1; then + AC_MSG_RESULT([no]) + missing_perl_modules=yes + else + AC_MSG_RESULT([yes]) + fi + done + if test "x$missing_perl_modules" = "xyes"; then + AC_MSG_WARN([some Perl modules required to compile virt-inspector and the other virt-* tools are missing]) + fi + ]) AM_CONDITIONAL([HAVE_INSPECTOR], [test "x$PERL" != "xno" && test "x$missing_perl_modules" != "xyes"]) @@ -780,11 +817,6 @@ dnl po4a for translating man pages and POD files (optional). AC_CHECK_PROG([PO4A],[po4a],[po4a],[no]) AM_CONDITIONAL([HAVE_PO4A], [test "x$PO4A" != "xno"]) -dnl PHP -AC_CHECK_PROG([PHP],[php],[php],[no]) -AC_CHECK_PROG([PHPIZE],[phpize],[phpize],[no]) -AM_CONDITIONAL([HAVE_PHP], [test "x$PHP" != "xno" && test "x$PHPIZE" != "xno"]) - dnl Library versioning. MAX_PROC_NR=`cat $srcdir/src/MAX_PROC_NR` AC_SUBST(MAX_PROC_NR)