summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Borkmann <dborkman@redhat.com>2013-07-08 10:41:25 +0200
committerDaniel Borkmann <dborkman@redhat.com>2013-07-08 10:41:25 +0200
commitb05baa0d26ea0107575336070cee2496c24c8f6a (patch)
tree48d7d46dbd9f8de02dc595c7535a56024def4f46
parent43b65d355ae3b9d2780f7e6998ff25900fe262ab (diff)
config: check for liburcu
Add a configure script extension that checks for liburcu as it is currently needed by flowtop. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
-rwxr-xr-xconfigure24
1 files changed, 24 insertions, 0 deletions
diff --git a/configure b/configure
index a49ed78..4bbbaed 100755
--- a/configure
+++ b/configure
@@ -243,6 +243,29 @@ EOF
fi
}
+check_urcu()
+{
+ echo -n "[*] Checking liburcu ... "
+
+ cat > $TMPDIR/urcutest.c << EOF
+#include <urcu.h>
+
+void main(void)
+{
+ rcu_init();
+ synchronize_rcu();
+}
+EOF
+
+ $CC -o $TMPDIR/urcutest $TMPDIR/urcutest.c -lurcu >> $TMPDIR/config.log 2>&1
+ if [ ! -x $TMPDIR/urcutest ] ; then
+ echo "[NO]"
+ MISSING_DEFS=1
+ else
+ echo "[YES]"
+ fi
+}
+
echo "# This file is autogenerated by the configure script" > Config
check_pkg_config
@@ -259,6 +282,7 @@ check_libnf_ct
check_ncurses
check_libgeoip
check_zlib
+check_urcu
if [ "$MISSING_DEFS" == "1" ] ; then
echo "[!] Some libraries or header definitions are missing or too old."