From: Vincent Bernat Date: Sun, 22 Jan 2012 11:08:22 +0000 (+0100) Subject: configure: fix an issue with netsnmp_enable_subagent detection X-Git-Tag: 0.5.7~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=314e1fe612f8b4a96bd7fcc5b5897d9b2439d153;p=thirdparty%2Flldpd.git configure: fix an issue with netsnmp_enable_subagent detection --- diff --git a/m4/snmp.m4 b/m4/snmp.m4 index c1cf0749..95e4786a 100644 --- a/m4/snmp.m4 +++ b/m4/snmp.m4 @@ -10,9 +10,9 @@ AC_DEFUN([lldp_CHECK_SNMP], [ NETSNMP_CFLAGS="`${NETSNMP_CONFIG} --base-cflags` -DNETSNMP_NO_INLINE" _save_flags="$CFLAGS" - _save_ldflags="$LDFLAGS" + _save_libs="$LIBS" CFLAGS="$CFLAGS ${NETSNMP_CFLAGS}" - LDFLAGS="$LDFLAGS ${NETSNMP_LIBS}" + LIBS="$LIBS ${NETSNMP_LIBS}" AC_MSG_CHECKING([whether C compiler supports flag "${NETSNMP_CFLAGS} ${NETSNMP_LIBS}" from Net-SNMP]) AC_LINK_IFELSE([AC_LANG_PROGRAM([ int main(void); @@ -52,5 +52,5 @@ AC_MSG_ERROR([*** incorrect CFLAGS from net-snmp-config])]) ]) CFLAGS="$_save_flags" - LDFLAGS="$_save_ldflags" + LIBS="$_save_libs" ])