trunk: add gzip build target
authorJo-Philipp Wich <jow@openwrt.org>
Sun, 5 Apr 2009 01:05:01 +0000 (01:05 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Sun, 5 Apr 2009 01:05:01 +0000 (01:05 +0000)
build/module.mk
contrib/package/luci/Makefile

index 8f3964ad6fe2387d5a3995a5a7c743680b05c82f..93f52689cd035631d630809060e88f147318a266 100644 (file)
@@ -37,6 +37,9 @@ luastrip: luasource
 luacompile: luasource
        for i in $$(find dist -name *.lua -not -name debug.lua); do $(LUAC) $(LUAC_OPTIONS) -o $$i $$i; done
 
+luagzip: luacompile
+       for i in $$(find dist -name *.lua -not -name debug.lua); do gzip -9 $$i; done
+
 luaclean:
        rm -rf dist
 
index 044eca6aef1919bb0b4aeb365757d0bcbdba6c6b..ec1a52a177135729c7d85db48d5a4e8d62ca23cb 100644 (file)
@@ -127,6 +127,9 @@ define Package/luci-core/config
        config PACKAGE_luci-core_source
                bool "Full Source"
 
+       config PACKAGE_luci-core_zipped
+               bool "Precompiled and compressed"
+
        endchoice
 endef
 
@@ -138,6 +141,10 @@ ifneq ($(CONFIG_PACKAGE_luci-core_stripped),)
   LUA_TARGET:=strip
 endif
 
+ifneq ($(CONFIG_PACKAGE_luci-core_zipped),)
+  LUA_TARGET:=gzip
+endif
+
 
 ### Libraries ###
 define Package/luci-cbi