diff options
author | Richard W.M. Jones <rjones@redhat.com> | 2010-11-08 14:53:48 +0000 |
---|---|---|
committer | Richard W.M. Jones <rjones@redhat.com> | 2010-11-08 14:53:48 +0000 |
commit | 8e4a4d3d88b814504c6f2abbf6bf3dab789021b1 (patch) | |
tree | a62675a59a49eda5646c7eda402dfed65074c1fb /configure.ac | |
parent | ada875642332b56acbf75d68e964f2f16ca50530 (diff) | |
download | libguestfs-8e4a4d3d88b814504c6f2abbf6bf3dab789021b1.tar.gz libguestfs-8e4a4d3d88b814504c6f2abbf6bf3dab789021b1.tar.xz libguestfs-8e4a4d3d88b814504c6f2abbf6bf3dab789021b1.zip |
build: Test for virt tools Perl libraries conditionally.
Only test for these if $PERL is defined, and use $PERL as
the interpreter.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/configure.ac b/configure.ac index 81e63c59..db2eb029 100644 --- a/configure.ac +++ b/configure.ac @@ -777,19 +777,22 @@ AM_CONDITIONAL([HAVE_HASKELL], [test "x$GHC" != "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"]) |