X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=configure.ac;h=7a14e01bcf4c4573513083da564938f26bb29b80;hb=e9c6bf25649bb8ead1bf383e51426b6552f08251;hp=77451f3e44dd5c88efb78b9181f7e39bc4c80116;hpb=4367c421fc62bbbb685d491415fe0cca6c990041;p=collectd.git diff --git a/configure.ac b/configure.ac index 77451f3e..7a14e01b 100644 --- a/configure.ac +++ b/configure.ac @@ -767,6 +767,8 @@ AC_FUNC_STRERROR_R SAVE_CFLAGS="$CFLAGS" CFLAGS="-Wall -Werror" +SAVE_LDFAGS="$LDFLAGS" +LDFLAGS="" AC_CACHE_CHECK([for strtok_r], [c_cv_have_strtok_r_default], @@ -839,6 +841,7 @@ if test "x$c_cv_have_strtok_r_default" = "xno"; then fi CFLAGS="$SAVE_CFLAGS" +LDFLAGS="$SAVE_LDFLAGS" if test "x$c_cv_have_strtok_r_reentrant" = "xyes"; then CFLAGS="$CFLAGS -D_REENTRANT=1" fi @@ -3844,7 +3847,7 @@ if test "x$with_libnetsnmp" = "xyes"; then AC_CACHE_CHECK([whether netsnmp library has old API], [c_cv_have_netsnmp_old_api], [ - AC_COMPILE_IFELSE( + AC_LINK_IFELSE( [ AC_LANG_PROGRAM( [[ @@ -3852,9 +3855,9 @@ if test "x$with_libnetsnmp" = "xyes"; then #include ]], [[ - netsnmp_variable_list *key; + netsnmp_variable_list *key = SNMP_MALLOC_TYPEDEF(netsnmp_variable_list);; int val; - u_char type; + u_char type = ASN_INTEGER; snmp_set_var_value(key, &val, sizeof(val)); snmp_set_var_typed_value(key, type, &val, sizeof(val)); return 0;