diff options
author | Khem Raj <raj.khem@gmail.com> | 2008-08-05 16:08:07 +0000 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2008-08-05 16:08:07 +0000 |
commit | 06f56c824b07049b7ecbe4d896ea4ff43f0a6f79 (patch) | |
tree | ac5023815d89efced05461f419209d42101b4d82 /packages/linux-libc-headers | |
parent | c4c1bcec601b7606971ac8b92a7d410742f038ec (diff) |
include sys/types.h in netfilter headers exported to userspace.
When using 2.6.25 kernel headers iptables fails to compile like below
/scratch/oe/build/eglibc/tmp-omap5912osk/staging/arm-angstrom-linux-gnueabi/usr/include/linux/netfilter.h:40: error: expected specifier-qualifier-list before '__u32'
This patch includes sys/types.h in userspace netfilter headers so __u32 definition is resolved.
Diffstat (limited to 'packages/linux-libc-headers')
-rw-r--r-- | packages/linux-libc-headers/linux-libc-headers-2.6.25/netfilter-include-types_h-in-userspace.patch | 88 | ||||
-rw-r--r-- | packages/linux-libc-headers/linux-libc-headers_2.6.25.bb | 3 |
2 files changed, 90 insertions, 1 deletions
diff --git a/packages/linux-libc-headers/linux-libc-headers-2.6.25/netfilter-include-types_h-in-userspace.patch b/packages/linux-libc-headers/linux-libc-headers-2.6.25/netfilter-include-types_h-in-userspace.patch new file mode 100644 index 0000000000..79eb170c2c --- /dev/null +++ b/packages/linux-libc-headers/linux-libc-headers-2.6.25/netfilter-include-types_h-in-userspace.patch @@ -0,0 +1,88 @@ +commit c8942f1f0a7e2160ebf2e51ba89e50ee5895a1e7 +Author: Patrick McHardy <kaber@trash.net> +Date: Wed May 21 14:08:38 2008 -0700 + + netfilter: Move linux/types.h inclusions outside of #ifdef __KERNEL__ + + Greg Steuck <greg@nest.cx> points out that some of the netfilter + headers can't be used in userspace without including linux/types.h + first. The headers include their own linux/types.h include statements, + these are stripped by make headers-install because they are inside + #ifdef __KERNEL__ however. Move them out to fix this. + + Reported and Tested by Greg Steuck. + + Signed-off-by: Patrick McHardy <kaber@trash.net> + Signed-off-by: David S. Miller <davem@davemloft.net> + +diff --git a/include/linux/netfilter.h b/include/linux/netfilter.h +index e4c6659..0c5eb7e 100644 +--- a/include/linux/netfilter.h ++++ b/include/linux/netfilter.h +@@ -3,7 +3,6 @@ + + #ifdef __KERNEL__ + #include <linux/init.h> +-#include <linux/types.h> + #include <linux/skbuff.h> + #include <linux/net.h> + #include <linux/netdevice.h> +@@ -14,6 +13,7 @@ + #include <linux/list.h> + #include <net/net_namespace.h> + #endif ++#include <linux/types.h> + #include <linux/compiler.h> + + /* Responses from hook functions. */ +diff --git a/include/linux/netfilter_arp/arp_tables.h b/include/linux/netfilter_arp/arp_tables.h +index dd9c97f..590ac3d 100644 +--- a/include/linux/netfilter_arp/arp_tables.h ++++ b/include/linux/netfilter_arp/arp_tables.h +@@ -11,11 +11,11 @@ + + #ifdef __KERNEL__ + #include <linux/if.h> +-#include <linux/types.h> + #include <linux/in.h> + #include <linux/if_arp.h> + #include <linux/skbuff.h> + #endif ++#include <linux/types.h> + #include <linux/compiler.h> + #include <linux/netfilter_arp.h> + +diff --git a/include/linux/netfilter_ipv4/ip_tables.h b/include/linux/netfilter_ipv4/ip_tables.h +index bfc889f..092bd50 100644 +--- a/include/linux/netfilter_ipv4/ip_tables.h ++++ b/include/linux/netfilter_ipv4/ip_tables.h +@@ -17,11 +17,11 @@ + + #ifdef __KERNEL__ + #include <linux/if.h> +-#include <linux/types.h> + #include <linux/in.h> + #include <linux/ip.h> + #include <linux/skbuff.h> + #endif ++#include <linux/types.h> + #include <linux/compiler.h> + #include <linux/netfilter_ipv4.h> + +diff --git a/include/linux/netfilter_ipv6/ip6_tables.h b/include/linux/netfilter_ipv6/ip6_tables.h +index f2507dc..1089e33 100644 +--- a/include/linux/netfilter_ipv6/ip6_tables.h ++++ b/include/linux/netfilter_ipv6/ip6_tables.h +@@ -17,11 +17,11 @@ + + #ifdef __KERNEL__ + #include <linux/if.h> +-#include <linux/types.h> + #include <linux/in6.h> + #include <linux/ipv6.h> + #include <linux/skbuff.h> + #endif ++#include <linux/types.h> + #include <linux/compiler.h> + #include <linux/netfilter_ipv6.h> + diff --git a/packages/linux-libc-headers/linux-libc-headers_2.6.25.bb b/packages/linux-libc-headers/linux-libc-headers_2.6.25.bb index f47fd08091..0d4163693c 100644 --- a/packages/linux-libc-headers/linux-libc-headers_2.6.25.bb +++ b/packages/linux-libc-headers/linux-libc-headers_2.6.25.bb @@ -2,11 +2,12 @@ require linux-libc-headers.inc INHIBIT_DEFAULT_DEPS = "1" DEPENDS += "unifdef-native" -PR = "r1" +PR = "r2" SRC_URI = "${KERNELORG_MIRROR}/pub/linux/kernel/v2.6/linux-${PV}.tar.bz2 \ file://reinstate-a.out.h.patch;patch=1 \ file://fix-kernel-conditionalize-a.out.h.patch;patch=1 \ + file://netfilter-include-types_h-in-userspace.patch;patch=1 \ file://procinfo.h" S = "${WORKDIR}/linux-${PV}" |