aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/utils/iptables/Makefile
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2015-05-26 09:16:50 +0000
committerJo-Philipp Wich <jow@openwrt.org>2015-05-26 09:16:50 +0000
commit1c00b6bc7f6e8cb56aedd1ba86e5d1c49a6538f1 (patch)
treebcb2d027036eb3ad6e653388b941c2df239a098b /package/network/utils/iptables/Makefile
parentecb14f4a5da62e9ea4b5020e25ccec37da669f59 (diff)
downloadupstream-1c00b6bc7f6e8cb56aedd1ba86e5d1c49a6538f1.tar.gz
upstream-1c00b6bc7f6e8cb56aedd1ba86e5d1c49a6538f1.tar.bz2
upstream-1c00b6bc7f6e8cb56aedd1ba86e5d1c49a6538f1.zip
iptables: reduce binary size
* drop unused lenient restore patch * instead of statically linking core extensions, build shared libraries for reuse in fw3 * strip outdated match revisions and aliases to trim down library size Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 45758
Diffstat (limited to 'package/network/utils/iptables/Makefile')
-rw-r--r--package/network/utils/iptables/Makefile13
1 files changed, 9 insertions, 4 deletions
diff --git a/package/network/utils/iptables/Makefile b/package/network/utils/iptables/Makefile
index df88639816..626b252761 100644
--- a/package/network/utils/iptables/Makefile
+++ b/package/network/utils/iptables/Makefile
@@ -392,7 +392,7 @@ define Package/libiptc
$(call Package/iptables/Default)
SECTION:=libs
CATEGORY:=Libraries
- DEPENDS:=+libip4tc +libip6tc
+ DEPENDS:=+libip4tc +libip6tc +libxtables
TITLE:=IPv4/IPv6 firewall - shared libiptc library (compatibility stub)
endef
@@ -401,6 +401,7 @@ $(call Package/iptables/Default)
SECTION:=libs
CATEGORY:=Libraries
TITLE:=IPv4 firewall - shared libiptc library
+ DEPENDS:=+libxtables
endef
define Package/libip6tc
@@ -408,6 +409,7 @@ $(call Package/iptables/Default)
SECTION:=libs
CATEGORY:=Libraries
TITLE:=IPv6 firewall - shared libiptc library
+ DEPENDS:=+libxtables
endef
define Package/libxtables
@@ -425,7 +427,8 @@ TARGET_CPPFLAGS := \
TARGET_CFLAGS += \
-I$(PKG_BUILD_DIR)/include \
-I$(LINUX_DIR)/user_headers/include \
- -ffunction-sections -fdata-sections
+ -ffunction-sections -fdata-sections \
+ -DNO_LEGACY
TARGET_LDFLAGS += \
-Wl,--gc-sections
@@ -466,8 +469,7 @@ define Build/InstallDev
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libip*tc.pc $(1)/usr/lib/pkgconfig/
# XXX: needed by firewall3
- $(INSTALL_DIR) $(1)/usr/lib/iptables
- $(CP) $(PKG_BUILD_DIR)/extensions/libext*.a $(1)/usr/lib/iptables/
+ $(CP) $(PKG_BUILD_DIR)/extensions/libiptext*.so $(1)/usr/lib/
endef
define Package/iptables/install
@@ -490,16 +492,19 @@ endef
define Package/libip4tc/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libip4tc.so* $(1)/usr/lib/
+ $(CP) $(PKG_BUILD_DIR)/extensions/libiptext4.so $(1)/usr/lib/
endef
define Package/libip6tc/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libip6tc.so* $(1)/usr/lib/
+ $(CP) $(PKG_BUILD_DIR)/extensions/libiptext6.so $(1)/usr/lib/
endef
define Package/libxtables/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libxtables.so* $(1)/usr/lib/
+ $(CP) $(PKG_BUILD_DIR)/extensions/libiptext.so $(1)/usr/lib/
endef
define BuildPlugin