changes for stats and snmp

This commit is contained in:
whottgen
2004-11-04 21:36:19 +00:00
parent f24c18bb4a
commit cafbf37771
14 changed files with 657 additions and 54 deletions

View File

@ -75,6 +75,37 @@ AC_ARG_WITH(djbdns-inc-dir,
esac ]
)
WITHOUT_NETSNMP=0
AC_ARG_WITH(netsnmp-lib-dir,
[AC_HELP_STRING(--with-netsnmp-lib-dir, [
Directory for Net-SNMP library files])],
[ case "$withval" in
no)
WITHOUT_NETSNMP=1
;;
yes)
;;
*)
LDFLAGS="$LDFLAGS -L$withval -R$withval"
;;
esac ]
)
AC_ARG_WITH(netsnmp-inc-dir,
[AC_HELP_STRING(--with-netsnmp-inc-dir, [
Directory for Net-SNMP include files])],
[ case "$withval" in
no)
WITHOUT_NETSNMP=1
;;
yes)
;;
*)
CPPFLAGS="$CPPFLAGS -I$withval"
;;
esac ]
)
ENABLE_VERIFY_CACHE=1
dnl AC_ARG_ENABLE(verify-cache,
@ -110,7 +141,15 @@ dnl (default=no)])],
dnl cyrus_BUILD=libcyrus_worker.la
dnl )
ENABLE_STATS=0
AC_ARG_ENABLE(stats,
[AC_HELP_STRING(--enable-stats, [
Enables statistics collection.
(default=no)])],
if test "x$enableval" = xyes; then ENABLE_STATS=1; fi
if test "x$enableval" = xno; then ENABLE_STATS=0; fi
)
# Checks for programs.
AC_PROG_CC
@ -138,6 +177,12 @@ if test "x$WITHOUT_DJBDNS" = "x0"; then
AC_CHECK_LIB([djbdns], [dns_transmit_start])
fi
if test "x$WITHOUT_NETSNMP" = "x0"; then
NETSNMP_LIBS=`net-snmp-config --netsnmp-agent-libs`
LIBS="$LIBS $NETSNMP_LIBS"
HAVE_LIBSNMP=1
fi
# Checks for header files.
@ -189,6 +234,8 @@ if test "x$BDB_NOT_FOUND" = "x1"; then
fi
AC_DEFINE_UNQUOTED(ENABLE_VERIFY_CACHE, ${ENABLE_VERIFY_CACHE}, [enable verify cache])
AC_DEFINE_UNQUOTED(ENABLE_STATS, ${ENABLE_STATS}, [enable stats])
AC_DEFINE_UNQUOTED(HAVE_LIBSNMP, ${HAVE_LIBSNMP}, [have libsnmp])