aboutsummaryrefslogtreecommitdiffstats
path: root/framework/src/suricata/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'framework/src/suricata/configure.ac')
-rw-r--r--framework/src/suricata/configure.ac58
1 files changed, 58 insertions, 0 deletions
diff --git a/framework/src/suricata/configure.ac b/framework/src/suricata/configure.ac
index ea819f4a..9e139383 100644
--- a/framework/src/suricata/configure.ac
+++ b/framework/src/suricata/configure.ac
@@ -1113,6 +1113,12 @@
AC_ARG_ENABLE(non-bundled-htp,
AS_HELP_STRING([--enable-non-bundled-htp], [Enable the use of an already installed version of htp]),,[enable_non_bundled_htp=no])
AS_IF([test "x$enable_non_bundled_htp" = "xyes"], [
+ PKG_CHECK_MODULES([libhtp], htp,, [with_pkgconfig_htp=no])
+ if test "$with_pkgconfig_htp" != "no"; then
+ CPPFLAGS="${CPPFLAGS} ${libhtp_CFLAGS}"
+ LIBS="${LIBS} ${libhtp_LIBS}"
+ fi
+
AC_ARG_WITH(libhtp_includes,
[ --with-libhtp-includes=DIR libhtp include directory],
[with_libhtp_includes="$withval"],[with_libhtp_includes=no])
@@ -1687,6 +1693,56 @@
enable_geoip="yes"
fi
+ # Position Independent Executable
+ AC_ARG_ENABLE(pie,
+ AS_HELP_STRING([--enable-pie],[Enable compiling as a position independent executable]),
+ [ enable_pie="yes"],
+ [ enable_pie="no"])
+ if test "$enable_pie" = "yes"; then
+ CPPFLAGS="${CPPFLAGS} -fPIC"
+ LDFLAGS="${LDFLAGS} -pie"
+ fi
+
+# libhiredis
+ AC_ARG_ENABLE(hiredis,
+ AS_HELP_STRING([--enable-hiredis],[Enable Redis support]),
+ [ enable_hiredis="yes"],
+ [ enable_hiredis="no"])
+ AC_ARG_WITH(libhiredis_includes,
+ [ --with-libhiredis-includes=DIR libhiredis include directory],
+ [with_libhiredis_includes="$withval"],[with_libhiredis_includes="no"])
+ AC_ARG_WITH(libhiredis_libraries,
+ [ --with-libhiredis-libraries=DIR libhiredis library directory],
+ [with_libhiredis_libraries="$withval"],[with_libhiredis_libraries="no"])
+
+ if test "$enable_hiredis" = "yes"; then
+ if test "$with_libhiredis_includes" != "no"; then
+ CPPFLAGS="${CPPFLAGS} -I${with_libhiredis_includes}"
+ fi
+
+ AC_CHECK_HEADER("hiredis/hiredis.h",HIREDIS="yes",HIREDIS="no")
+ if test "$HIREDIS" = "yes"; then
+ if test "$with_libhiredis_libraries" != "no"; then
+ LDFLAGS="${LDFLAGS} -L${with_libhiredis_libraries}"
+ fi
+ AC_CHECK_LIB(hiredis, redisConnect,, HIREDIS="no")
+ fi
+ if test "$HIREDIS" = "no"; then
+ echo
+ echo " ERROR! libhiredis library not found, go get it"
+ echo " from https://github.com/redis/hiredis or your distribution:"
+ echo
+ echo " Ubuntu: apt-get install libhiredis-dev"
+ echo " Fedora: yum install libhiredis-devel"
+ echo
+ exit 1
+ fi
+ if test "$HIREDIS" = "yes"; then
+ AC_DEFINE([HAVE_LIBHIREDIS],[1],[libhiredis available])
+ enable_hiredis="yes"
+ fi
+ fi
+
# get cache line size
AC_PATH_PROG(HAVE_GETCONF_CMD, getconf, "no")
if test "$HAVE_GETCONF_CMD" != "no"; then
@@ -1794,6 +1850,7 @@ SURICATA_BUILD_CONF="Suricata Configuration:
libnss support: ${enable_nss}
libnspr support: ${enable_nspr}
libjansson support: ${enable_jansson}
+ hiredis support: ${enable_hiredis}
Prelude support: ${enable_prelude}
PCRE jit: ${pcre_jit_available}
LUA support: ${enable_lua}
@@ -1826,6 +1883,7 @@ Generic build parameters:
GCC Protect enabled: ${enable_gccprotect}
GCC march native enabled: ${enable_gccmarch_native}
GCC Profile enabled: ${enable_gccprofile}
+ Position Independent Executable enabled: ${enable_pie}
CFLAGS ${CFLAGS}
PCAP_CFLAGS ${PCAP_CFLAGS}
SECCFLAGS ${SECCFLAGS}"