Fix detection and use of netinet/ip6.h on FreeBSD
authorTobias Brunner <tobias@strongswan.org>
Wed, 27 Mar 2013 08:56:48 +0000 (09:56 +0100)
committerTobias Brunner <tobias@strongswan.org>
Wed, 27 Mar 2013 08:56:48 +0000 (09:56 +0100)
configure.in
src/libipsec/ip_packet.c

index d4c35be..9dc510b 100644 (file)
@@ -471,7 +471,11 @@ AC_CHECK_FUNCS(prctl mallinfo getpass closefrom getpwnam_r getgrnam_r getpwuid_r
 
 AC_CHECK_HEADERS(sys/sockio.h glob.h)
 AC_CHECK_HEADERS(net/pfkeyv2.h netipsec/ipsec.h netinet6/ipsec.h linux/udp.h)
-AC_CHECK_HEADERS(netinet/ip6.h)
+AC_CHECK_HEADERS(netinet/ip6.h, [], [],
+[
+       #include <sys/types.h>
+       #include <netinet/in.h>
+])
 
 AC_CHECK_MEMBERS([struct sockaddr.sa_len], [], [],
 [
index 5c8cc2e..d08e090 100644 (file)
@@ -19,6 +19,7 @@
 #include <library.h>
 #include <utils/debug.h>
 
+#include <sys/types.h>
 #include <netinet/in.h>
 #include <netinet/ip.h>
 #ifdef HAVE_NETINET_IP6_H