luci-base: move luci.sys.iptparser into separate package
authorJo-Philipp Wich <redacted>
Wed, 10 Oct 2018 11:17:20 +0000 (13:17 +0200)
committerJo-Philipp Wich <redacted>
Wed, 10 Oct 2018 11:19:48 +0000 (13:19 +0200)
Since commit f6bfac211 ("luci-mod-status: rework iptables status page"),
nothing in luci-base depends on the iptparser class anymore, so fold it
out into a separate package and let the few apps that require it depend
on the new library package.

Saves about 10K uncompressed in luci-base while the iptables status
rework enlarged the markup by roughly 5KB, saving roughly 5KB of size
overall.

Signed-off-by: Jo-Philipp Wich <redacted>
applications/luci-app-splash/Makefile
applications/luci-app-statistics/Makefile
libs/luci-lib-iptparser/Makefile [new file with mode: 0644]
libs/luci-lib-iptparser/sys/iptparser.lua [moved from modules/luci-base/luasrc/sys/iptparser.lua with 100% similarity]
libs/luci-lib-iptparser/sys/iptparser.luadoc [moved from modules/luci-base/luasrc/sys/iptparser.luadoc with 100% similarity]

index 5740aa5f7c4364923bbd18b2822bb15204838885..46537248710962768495fe91585823409740d3d0 100644 (file)
@@ -7,7 +7,7 @@
 include $(TOPDIR)/rules.mk
 
 LUCI_TITLE:=Freifunk DHCP-Splash application
-LUCI_DEPENDS:=+luci-lib-nixio +tc +kmod-sched +iptables-mod-nat-extra +iptables-mod-ipopt
+LUCI_DEPENDS:=+luci-lib-nixio +luci-lib-iptparser +tc +kmod-sched +iptables-mod-nat-extra +iptables-mod-ipopt
 
 define Package/luci-app-splash/conffiles
 /etc/config/luci_splash
index 008792a5d018078525e53ea21dc62d0d22fd7e96..b552400fed90db1510361d5649764724ac3dbffb 100644 (file)
@@ -8,6 +8,7 @@ include $(TOPDIR)/rules.mk
 
 LUCI_TITLE:=LuCI Statistics Application
 LUCI_DEPENDS:= \
+       +luci-lib-iptparser \
        +collectd +rrdtool1 +collectd-mod-rrdtool +collectd-mod-iwinfo \
        +collectd-mod-cpu +collectd-mod-memory \
        +collectd-mod-interface +collectd-mod-load +collectd-mod-network
diff --git a/libs/luci-lib-iptparser/Makefile b/libs/luci-lib-iptparser/Makefile
new file mode 100644 (file)
index 0000000..06748ad
--- /dev/null
@@ -0,0 +1,14 @@
+#
+# Copyright (C) 2018 The LuCI Team <luci@lists.subsignal.org>
+#
+# This is free software, licensed under the Apache License, Version 2.0 .
+#
+
+include $(TOPDIR)/rules.mk
+
+LUCI_TITLE:=Iptables listing parser class
+LUCI_DEPENDS:=+luci-base
+
+include ../../luci.mk
+
+# call BuildPackage - OpenWrt buildroot signature
git clone https://git.99rst.org/PROJECT