]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
Fix configuring Prelude with -Werror
authorKen Steele <ken@tilera.com>
Tue, 19 Nov 2013 15:22:40 +0000 (10:22 -0500)
committerVictor Julien <victor@inliniac.net>
Wed, 11 Dec 2013 10:50:00 +0000 (11:50 +0100)
Running with:

CFLAGS="-Werror" ./configure

would fail when configuring libprelude because of an unused-result
warning. Ignore that one warning.

configure.ac

index 0b29eeb277379d2793b8daca76c6d80fc7da9b84..51a56f667d16a9680236556a6512dd274528eb49 100644 (file)
   # prelude
     AC_ARG_ENABLE(prelude,
             AS_HELP_STRING([--enable-prelude], [Enable Prelude support for alerts]),,[enable_prelude=no])
+    # Prelude doesn't work with -Werror
+    STORECFLAGS="${CFLAGS}"
+    CFLAGS="${CFLAGS} -Wno-error=unused-result"
+
     AS_IF([test "x$enable_prelude" = "xyes"], [
         CFLAGS="$CFLAGS -DPRELUDE"
         AM_PATH_LIBPRELUDE(0.9.9, , AC_MSG_ERROR(Cannot find libprelude: Is libprelude-config in the path?), no)
             LDFLAGS="${LDFLAGS} ${LIBPRELUDE_LIBS}"
         fi
     ])
+    CFLAGS="${STORECFLAGS}"
+
 
   # libnet
     AC_ARG_WITH(libnet_includes,