From c11ff891614efc8b939d906c00ed63b02f807f13 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Mon, 8 Jul 2013 15:06:16 +0200 Subject: [PATCH] configure: Fix check for libnetfilter-conntrack Correct the type to struct nf_conntrack and call a function to prevent the variable from getting optimized away by the compiler and cause a linker call. Also add the proper linker flag. Signed-off-by: Tobias Klauser --- configure | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/configure b/configure index 4bbbaed2..74e1c144 100755 --- a/configure +++ b/configure @@ -208,11 +208,13 @@ check_libnf_ct() void main(void) { - struct nfconntrack *ct; + struct nf_conntrack *ct; + + const uint32_t id = nfct_get_attr_u32(ct, ATTR_ID); } EOF - $CC -o $TMPDIR/nfcttest $TMPDIR/nfcttest.c >> $TMPDIR/config.log 2>&1 + $CC -o $TMPDIR/nfcttest $TMPDIR/nfcttest.c -lnetfilter_conntrack >> $TMPDIR/config.log 2>&1 if [ ! -x $TMPDIR/nfcttest ] ; then echo "[NO]" MISSING_DEFS=1 -- 2.11.4.GIT