summaryrefslogtreecommitdiff
path: root/lib/replace/system
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2011-02-02 10:40:06 +0100
committerAndreas Schneider <asn@cryptomilk.org>2011-02-02 11:57:04 +0100
commitc2207e9b2cdec9cd4c32184c668a2c469edb7148 (patch)
tree0102182a361fcfe83fe715ccf636fc8ce3e12427 /lib/replace/system
parentda3a2c68b0a789685f051a21579cafa71651618d (diff)
downloadsamba-c2207e9b2cdec9cd4c32184c668a2c469edb7148.tar.gz
samba-c2207e9b2cdec9cd4c32184c668a2c469edb7148.tar.bz2
samba-c2207e9b2cdec9cd4c32184c668a2c469edb7148.zip
replace: Try to fix broken sys/capabilites.h on Linux.
As this is more or less a broken header we need to include linux/types.h before sys/capabilities.h to avoid redefinitions. Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Wed Feb 2 11:57:04 CET 2011 on sn-devel-104
Diffstat (limited to 'lib/replace/system')
-rw-r--r--lib/replace/system/capability.h4
-rw-r--r--lib/replace/system/config.m41
2 files changed, 5 insertions, 0 deletions
diff --git a/lib/replace/system/capability.h b/lib/replace/system/capability.h
index a7b78f0275..832bc29152 100644
--- a/lib/replace/system/capability.h
+++ b/lib/replace/system/capability.h
@@ -37,6 +37,10 @@
#define BROKEN_RHEL5_SYS_CAP_HEADER_WORKAROUND
#endif
+#ifdef HAVE_LINUX_TYPES_H
+#include <linux/types.h>
+#endif
+
#include <sys/capability.h>
#ifdef BROKEN_RHEL5_SYS_CAP_HEADER_WORKAROUND
diff --git a/lib/replace/system/config.m4 b/lib/replace/system/config.m4
index 04364bc3a1..71d3d53c3d 100644
--- a/lib/replace/system/config.m4
+++ b/lib/replace/system/config.m4
@@ -25,6 +25,7 @@ fi
AC_HEADER_SYS_WAIT
# capability
+AC_CHECK_HEADERS(linux/types.h)
AC_CHECK_HEADERS(sys/capability.h)
case "$host_os" in