iptables: unbork the 1.3.8 build, merge iptables-utils into iptables.
authorChris Larson <clarson@mvista.com>
Wed, 6 Jan 2010 23:32:40 +0000 (16:32 -0700)
committerChris Larson <clarson@mvista.com>
Fri, 22 Jan 2010 16:39:10 +0000 (09:39 -0700)
In recent iptables versions, the -save and -restore files are just symlinks
pointing to the main, merged binary, so the separate package is a bit
unnecessary.

Signed-off-by: Chris Larson <clarson@mvista.com>
recipes/iptables/files/compile.patch [deleted file]
recipes/iptables/iptables-1.3.8/cross-iptables.diff [moved from recipes/iptables/files/cross-iptables.diff with 100% similarity]
recipes/iptables/iptables-1.3.8/getsockopt-failed.patch [moved from recipes/iptables/files/getsockopt-failed.patch with 100% similarity]
recipes/iptables/iptables-1.3.8/iptables-use-s6_addr32.patch [moved from recipes/iptables/files/iptables-use-s6_addr32.patch with 100% similarity]
recipes/iptables/iptables.inc
recipes/iptables/iptables_1.3.8.bb
recipes/iptables/iptables_1.4.6.bb

diff --git a/recipes/iptables/files/compile.patch b/recipes/iptables/files/compile.patch
deleted file mode 100644 (file)
index 76662d9..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-Index: iptables-1.3.3/extensions/Makefile
-===================================================================
---- iptables-1.3.3.orig/extensions/Makefile
-+++ iptables-1.3.3/extensions/Makefile
-@@ -67,10 +67,10 @@ endif
- ifdef NO_SHARED_LIBS
- extensions/libext.a: $(EXT_OBJS)
--      rm -f $@; ar crv $@ $(EXT_OBJS)
-+      rm -f $@; $(AR) crv $@ $(EXT_OBJS)
- extensions/libext6.a: $(EXT6_OBJS)
--      rm -f $@; ar crv $@ $(EXT6_OBJS)
-+      rm -f $@; $(AR) crv $@ $(EXT6_OBJS)
- extensions/initext.o: extensions/initext.c
- extensions/initext6.o: extensions/initext6.c
index 698c259..c8f70d4 100644 (file)
@@ -10,23 +10,10 @@ INC_PR = "r6"
 
 PARALLEL_MAKE = ""
 
-export COPT_FLAGS = "${CFLAGS}"
-export KERNEL_DIR = "${STAGING_INCDIR}"
-
-inherit autotools
-
-#do_compile () {
-#      oe_runmake DESTDIR=${D} NO_SHARED_LIBS=1
-#}
-
-#do_install () {
-#      oe_runmake DESTDIR=${D} install NO_SHARED_LIBS=1
-#}
-
-PACKAGES =+ "${PN}-utils"
-FILES_${PN}-utils = "${sbindir}/iptables-save ${sbindir}/iptables-restore"
+CFLAGS += "-Du32=__u32"
+RPROVIDES_${PN} += "iptables-utils"
+FILES_${PN}-dbg += "${libexecdir}/xtables/.debug"
 FILES_${PN}-doc += "${mandir}"
-FILES_${PN}-dbg += "${libexecdir}/xtables/.debug/*"
 
 RRECOMMENDS = "\
   kernel-module-ip-tables \
index 47c5564..968f7d9 100644 (file)
@@ -1,5 +1,16 @@
 require iptables.inc
 PR = "${INC_PR}.0"
+EXTRA_OEMAKE = "'COPT_FLAGS=${CFLAGS}' \
+                'KERNEL_DIR=${STAGING_INCDIR}' \
+                'LDFLAGS=${LDFLAGS}' \
+                ${@base_contains('DISTRO_FEATURES', 'ipv6', 'DO_IPV6=1', 'DO_IPV6=0', d)} \
+                \
+                'PREFIX=${prefix}' \
+                'LIBDIR=${libdir}' \
+                'BINDIR=${sbindir}' \
+                'MANDIR=${mandir}' \
+                'INCDIR=${includedir}'"
+CFLAGS[unexport] = "1"
 
 SRC_URI += "\
   file://getsockopt-failed.patch;patch=1 \
@@ -7,3 +18,6 @@ SRC_URI += "\
   file://cross-iptables.diff;patch=1 \
 "
 
+do_install () {
+    oe_runmake 'DESTDIR=${D}' install
+}
index 433114e..bf7bc05 100644 (file)
@@ -1,4 +1,8 @@
 require iptables.inc
+inherit autotools
+EXTRA_OECONF = "--with-kernel=${STAGING_INCDIR} \
+                ${@base_contains('DISTRO_FEATURES', 'ipv6', '', '--disable-ipv6', d)}"
+
 PR = "${INC_PR}.0"
 
 SRC_URI += "\