Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

allow for choice of lua or not combined with the net-snmp dep

  • Loading branch information...
commit 6a5a1cf66615c2c09772f64273bc2ba39f46a3ca 1 parent aec8901
@postwait postwait authored
Showing with 22 additions and 5 deletions.
  1. +21 −4 configure.in
  2. +1 −1  src/modules/Makefile.in
View
25 configure.in
@@ -18,6 +18,12 @@ AC_ARG_ENABLE(strict,
enable_strict="$enableval",
enable_strict=no)
+AC_ARG_ENABLE(lua,
+ [AC_HELP_STRING([--enable-lua],
+ [Choose a lua implementation: (no, yes)])],
+ enable_lua="$enableval",
+ enable_lua=yes)
+
AC_PROG_CC
AC_C_INLINE
AC_C_BIGENDIAN
@@ -158,6 +164,12 @@ AC_SUBST(ATOMIC_OBJS)
AC_DEFINE_UNQUOTED(MODULEEXT, "$MODULEEXT", [module extension])
AC_MSG_CHECKING([enable build/install of the Java IEP and Jezebel bits])
+LUA_MODULE=lua.$MODULEEXT
+if test "$enable_lua" = "no"; then
+ LUA_MODULE=
+fi
+
+
if test -z "$ac_cv_path_JAVA" \
-o -z "$ac_cv_path_JAVAC" \
-o -z "$ac_cv_path_JAR" ; then
@@ -301,20 +313,23 @@ fi
########
# Should we build snmp checks?
+HAS_NETSNMP="no"
AC_CHECK_HEADERS(net-snmp/net-snmp-config.h)
if test "$ac_cv_header_net_snmp_net_snmp_config_h" = "yes" ; then
SAVELIBS="$LIBS"
AC_CHECK_LIB(netsnmp, snmp_sess_open,
[
BUILD_MODULES="$BUILD_MODULES snmp.$MODULEEXT"
- ],
- [
- AC_MSG_WARN([No libnetsnmp, skipping snmp module])
+ HAS_NETSNMP="yes"
]
)
LIBS="$SAVELIBS"
-else
+fi
+if test "x$HAS_NETSNMP" = "xno"; then
AC_MSG_WARN([No libnetsnmp, skipping snmp module])
+ if test -n "$LUA_MODULE"; then
+ AC_MSG_ERROR([*** lua specified, but no SNMP ***])
+ fi
fi
# Should we build ssh2 checks?
@@ -683,6 +698,8 @@ if test "x$ac_cv_have_ssize_t" = "xyes" ; then
AC_DEFINE(HAVE_SSIZE_T)
fi
+BUILD_MODULES="$BUILD_MODULES $LUA_MODULE"
+
AC_SUBST(BUILD_MODULES)
AC_SUBST(BUILD_SMODULES)
View
2  src/modules/Makefile.in
@@ -25,7 +25,7 @@ XML2H=@top_srcdir@/buildtools/xml2h
top_srcdir=@top_srcdir@
MODULES=check_test.@MODULEEXT@ ping_icmp.@MODULEEXT@ postgres.@MODULEEXT@ \
- lua.@MODULEEXT@ dns.@MODULEEXT@ selfcheck.@MODULEEXT@ \
+ dns.@MODULEEXT@ selfcheck.@MODULEEXT@ \
external.@MODULEEXT@ collectd.@MODULEEXT@ httptrap.@MODULEEXT@ \
ip_acl.@MODULEEXT@ statsd.@MODULEEXT@ \
@BUILD_MODULES@
Please sign in to comment.
Something went wrong with that request. Please try again.