Add --disable-detection configure option

Add --disable-detection configure option to compile Suricata with
detection disabled.
pull/796/head
Victor Julien 12 years ago
parent 6a3621f2fe
commit f4872a2f08

@ -392,6 +392,13 @@
])
AM_CONDITIONAL([HAVE_COCCINELLE], [test "x$enable_coccinelle" != "xno"])
# disable detection
AC_ARG_ENABLE(detection,
AS_HELP_STRING([--disable-detection], [Disable Detection Modules])], [enable_detection="$enableval"],[enable_detection=yes])
AS_IF([test "x$enable_detection" = "xno"], [
AC_DEFINE([HAVE_DETECT_DISABLED], [1], [Detection is disabled])]
])
# libraries
AC_MSG_CHECKING([for Mpipe])
@ -1631,6 +1638,7 @@ SURICATA_BUILD_CONF="Suricata Configuration:
DAG enabled: ${enable_dag}
Napatech enabled: ${enable_napatech}
Unix socket enabled: ${enable_unixsocket}
Detection enabled: ${enable_detection}
libnss support: ${enable_nss}
libnspr support: ${enable_nspr}

@ -927,7 +927,11 @@ static void SCInstanceInit(SCInstance *suri)
suri->verbose = 0;
/* use -1 as unknown */
suri->checksum_validation = -1;
suri->disabled_detect = 0;
#if HAVE_DETECT_DISABLED==1
g_detect_disabled = suri->disabled_detect = 1;
#else
g_detect_disabled = suri->disabled_detect = 0;
#endif
}
static TmEcode PrintVersion()

Loading…
Cancel
Save