summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2017-11-03 14:09:45 +1100
committerDarren Tucker <dtucker@zip.com.au>2017-11-03 14:09:45 +1100
commitfa1b834cce41a1ce3e6a8d57fb67ef18c9dd803f (patch)
tree51458d0ce753d655b5cfdef9516c168afb73e49f /configure.ac
parent41bff4da21fcd8a7c6a83a7e0f92b018f904f6fb (diff)
Add headers for sys/sysctl.h and net/route.h
On at least older OpenBSDs, sys/sysctl.h and net/route.h require sys/types and, in the case of sys/sysctl.h, sys/param.h for MAXLOGNAME.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac10
1 files changed, 7 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index e919dee3..a739bd55 100644
--- a/configure.ac
+++ b/configure.ac
@@ -404,7 +404,6 @@ AC_CHECK_HEADERS([ \
sys/strtio.h \
sys/statvfs.h \
sys/sysmacros.h \
- sys/sysctl.h \
sys/time.h \
sys/timers.h \
time.h \
@@ -428,8 +427,13 @@ AC_CHECK_HEADERS([sys/capsicum.h], [], [], [
#endif
])
-# net/route.h requires sys/socket.h
-AC_CHECK_HEADERS([net/route.h], [], [], [
+# net/route.h requires sys/socket.h and sys/types.h.
+# sys/sysctl.h also requires sys/param.h
+AC_CHECK_HEADERS([net/route.h sys/sysctl.h], [], [], [
+#ifdef HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+#include <sys/param.h>
#include <sys/socket.h>
])