better way to disable snmp

This commit is contained in:
whottgen
2004-11-05 09:19:30 +00:00
parent 9de6cf1de0
commit 2d4e3ffaf6
2 changed files with 75 additions and 30 deletions

View File

@ -75,7 +75,25 @@ AC_ARG_WITH(djbdns-inc-dir,
esac ]
)
WITHOUT_NETSNMP=0
WITHOUT_NETSNMP=1
AC_ARG_WITH(netsnmp,
[AC_HELP_STRING(--with-netsnmp, [
With Net-SNMP])],
[ case "$withval" in
no)
WITHOUT_NETSNMP=1
;;
yes)
;;
*)
WITHOUT_NETSNMP=0
;;
esac ]
)
AC_ARG_WITH(netsnmp-lib-dir,
[AC_HELP_STRING(--with-netsnmp-lib-dir, [
Directory for Net-SNMP library files])],
@ -86,6 +104,7 @@ AC_ARG_WITH(netsnmp-lib-dir,
yes)
;;
*)
WITHOUT_NETSNMP=0
LDFLAGS="$LDFLAGS -L$withval -R$withval"
;;
esac ]
@ -101,6 +120,7 @@ AC_ARG_WITH(netsnmp-inc-dir,
yes)
;;
*)
WITHOUT_NETSNMP=0
CPPFLAGS="$CPPFLAGS -I$withval"
;;
esac ]
@ -177,6 +197,7 @@ if test "x$WITHOUT_DJBDNS" = "x0"; then
AC_CHECK_LIB([djbdns], [dns_transmit_start])
fi
HAVE_LIBSNMP=0
if test "x$WITHOUT_NETSNMP" = "x0"; then
NETSNMP_LIBS=`net-snmp-config --netsnmp-agent-libs`
LIBS="$LIBS $NETSNMP_LIBS"