X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=configure.in;h=7c4e417d90719f8097763c7c334b5375f4304903;hb=38f27d544d9dec62d9aa382098507d8fc36c61f8;hp=719f94e51a7c7b5eac3ff5229a34d975787cfc96;hpb=351026b0595385ca5376211c1af965bf2d4731b9;p=collectd.git diff --git a/configure.in b/configure.in index 719f94e5..7c4e417d 100644 --- a/configure.in +++ b/configure.in @@ -1263,6 +1263,90 @@ AC_SUBST(GANGLIA_LIBS) AM_CONDITIONAL(BUILD_WITH_LIBGANGLIA, test "x$with_libganglia" = "xyes") # }}} +# --with-libgcrypt {{{ +GCRYPT_CPPFLAGS="$GCRYPT_CPPFLAGS" +GCRYPT_LDFLAGS="$GCRYPT_LDFLAGS" +GCRYPT_LIBS="$GCRYPT_LIBS" +AC_ARG_WITH(libgcrypt, [AS_HELP_STRING([--with-libgcrypt@<:@=PREFIX@:>@], [Path to libgcrypt.])], +[ + if test -f "$withval" && test -x "$withval" + then + with_libgcrypt_config="$withval" + with_libgcrypt="yes" + else if test -f "$withval/bin/gcrypt-config" && test -x "$withval/bin/gcrypt-config" + then + with_libgcrypt_config="$withval/bin/gcrypt-config" + with_libgcrypt="yes" + else if test -d "$withval" + then + GCRYPT_CPPFLAGS="$GCRYPT_CPPFLAGS -I$withval/include" + GCRYPT_LDFLAGS="$GCRYPT_LDFLAGS -L$withval/lib" + with_libgcrypt="yes" + else + with_libgcrypt_config="gcrypt-config" + with_libgcrypt="$withval" + fi; fi; fi +], +[ + with_libgcrypt_config="libgcrypt-config" + with_libgcrypt="yes" +]) + +if test "x$with_libgcrypt" = "xyes" && test "x$with_libgcrypt_config" != "x" +then + if test "x$GCRYPT_CPPFLAGS" = "x" + then + GCRYPT_CPPFLAGS=`"$with_libgcrypt_config" --cflags 2>/dev/null` + fi + + if test "x$GCRYPT_LDFLAGS" = "x" + then + gcrypt_exec_prefix=`"$with_libgcrypt_config" --exec-prefix 2>/dev/null` + GCRYPT_LDFLAGS="-L$gcrypt_exec_prefix/lib" + fi + + if test "x$GCRYPT_LIBS" = "x" + then + GCRYPT_LIBS=`"$with_libgcrypt_config" --libs 2>/dev/null` + fi +fi + +SAVE_CPPFLAGS="$CPPFLAGS" +SAVE_LDFLAGS="$LDFLAGS" +CPPFLAGS="$CPPFLAGS $GCRYPT_CPPFLAGS" +LDFLAGS="$LDFLAGS $GCRYPT_LDFLAGS" + +if test "x$with_libgcrypt" = "xyes" +then + if test "x$GCRYPT_CPPFLAGS" != "x" + then + AC_MSG_NOTICE([gcrypt CPPFLAGS: $GCRYPT_CPPFLAGS]) + fi + AC_CHECK_HEADERS(gcrypt.h, + [with_libgcrypt="yes"], + [with_libgcrypt="no (gcrypt.h not found)"]) +fi + +if test "x$with_libgcrypt" = "xyes" +then + if test "x$GCRYPT_LDFLAGS" != "x" + then + AC_MSG_NOTICE([gcrypt LDFLAGS: $GCRYPT_LDFLAGS]) + fi + AC_CHECK_LIB(gcrypt, gcry_md_hash_buffer, + [with_libgcrypt="yes"], + [with_libgcrypt="no (symbol gcry_md_hash_buffer not found)"]) +fi + +CPPFLAGS="$SAVE_CPPFLAGS" +LDFLAGS="$SAVE_LDFLAGS" + +AC_SUBST(GCRYPT_CPPFLAGS) +AC_SUBST(GCRYPT_LDFLAGS) +AC_SUBST(GCRYPT_LIBS) +AM_CONDITIONAL(BUILD_WITH_LIBGCRYPT, test "x$with_libgcrypt" = "xyes") +# }}} + # --with-libiptc {{{ with_own_libiptc="no" AC_ARG_WITH(libiptc, [AS_HELP_STRING([--with-libiptc@<:@=PREFIX@:>@], [Path to libiptc.])], @@ -2024,8 +2108,9 @@ if test "x$with_libperl" = "xyes" \ then SAVE_CFLAGS=$CFLAGS SAVE_LDFLAGS=$LDFLAGS - PERL_CFLAGS=`$perl_interpreter -MExtUtils::Embed -e ccopts` - PERL_LDFLAGS=`$perl_interpreter -MExtUtils::Embed -e ldopts` +dnl ARCHFLAGS="" -> disable multi -arch on OSX (see Config_heavy.pl:fetch_string) + PERL_CFLAGS=`ARCHFLAGS="" $perl_interpreter -MExtUtils::Embed -e ccopts` + PERL_LDFLAGS=`ARCHFLAGS="" $perl_interpreter -MExtUtils::Embed -e ldopts` CFLAGS="$CFLAGS $PERL_CFLAGS" LDFLAGS="$LDFLAGS $PERL_LDFLAGS" @@ -3067,6 +3152,7 @@ dependency_error="no" plugin_ascent="no" plugin_battery="no" plugin_bind="no" +plugin_conntrack="no" plugin_cpu="no" plugin_cpufreq="no" plugin_df="no" @@ -3100,6 +3186,7 @@ plugin_wireless="no" if test "x$ac_system" = "xLinux" then plugin_battery="yes" + plugin_conntrack="yes" plugin_cpu="yes" plugin_cpufreq="yes" plugin_disk="yes" @@ -3188,6 +3275,7 @@ fi if test "x$have_sysctl" = "xyes" then plugin_cpu="yes" + plugin_memory="yes" plugin_swap="yes" plugin_uptime="yes" fi @@ -3282,6 +3370,7 @@ AC_PLUGIN([apple_sensors], [$with_libiokit], [Apple's hardware sensors]) AC_PLUGIN([ascent], [$plugin_ascent], [AscentEmu player statistics]) AC_PLUGIN([battery], [$plugin_battery], [Battery statistics]) AC_PLUGIN([bind], [$plugin_bind], [ISC Bind nameserver statistics]) +AC_PLUGIN([conntrack], [$plugin_conntrack], [nf_conntrack statistics]) AC_PLUGIN([cpufreq], [$plugin_cpufreq], [CPU frequency statistics]) AC_PLUGIN([cpu], [$plugin_cpu], [CPU usage statistics]) AC_PLUGIN([csv], [yes], [CSV output plugin]) @@ -3563,6 +3652,7 @@ Configuration: ascent . . . . . . . $enable_ascent battery . . . . . . . $enable_battery bind . . . . . . . . $enable_bind + conntrack . . . . . . $enable_conntrack cpu . . . . . . . . . $enable_cpu cpufreq . . . . . . . $enable_cpufreq csv . . . . . . . . . $enable_csv