From fbc9da450d917ec140e3616ad0d9363cb58ffa22 Mon Sep 17 00:00:00 2001 From: Jason Ish Date: Fri, 7 Aug 2020 08:57:04 -0600 Subject: [PATCH] configure: fix detection of netfilter_queue with older headers Define _GNU_SOURCE and include sys/types.h so older netfilter_queue headers can be detected properly, as they are using u_int_xx style integers. --- configure.ac | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 62564b9dbf..93cfc27673 100644 --- a/configure.ac +++ b/configure.ac @@ -1079,7 +1079,13 @@ return 0; CPPFLAGS="${CPPFLAGS} -I${with_libnetfilter_queue_includes}" fi - AC_CHECK_HEADER(libnetfilter_queue/libnetfilter_queue.h,,[AC_MSG_ERROR(libnetfilter_queue/libnetfilter_queue.h not found ...)]) + AC_CHECK_HEADER(libnetfilter_queue/libnetfilter_queue.h,, + [AC_MSG_ERROR(libnetfilter_queue/libnetfilter_queue.h not found ...)], + [ + #define _GNU_SOURCE + #include + #include + ]) if test "$with_libnetfilter_queue_libraries" != "no"; then LDFLAGS="${LDFLAGS} -L${with_libnetfilter_queue_libraries}" @@ -1103,6 +1109,9 @@ return 0; AC_COMPILE_IFELSE( [AC_LANG_PROGRAM( [ + #define _GNU_SOURCE + #include + #include #include #include ],