luci.mk: move /tmp/luci-modulecache remove to package postinst script 3631/head
authorFlorian Eckert <fe@dev.tdt.de>
Fri, 14 Feb 2020 08:12:31 +0000 (09:12 +0100)
committerFlorian Eckert <fe@dev.tdt.de>
Fri, 14 Feb 2020 08:20:48 +0000 (09:20 +0100)
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
applications/luci-app-advanced-reboot/root/etc/uci-defaults/40_luci-advanced-reboot [deleted file]
applications/luci-app-attendedsysupgrade/root/etc/uci-defaults/40_luci-attendedsysupgrade
applications/luci-app-https-dns-proxy/root/etc/uci-defaults/40_luci-https-dns-proxy [deleted file]
applications/luci-app-vpn-policy-routing/root/etc/uci-defaults/40_luci-vpn-policy-routing [deleted file]
luci.mk

diff --git a/applications/luci-app-advanced-reboot/root/etc/uci-defaults/40_luci-advanced-reboot b/applications/luci-app-advanced-reboot/root/etc/uci-defaults/40_luci-advanced-reboot
deleted file mode 100644 (file)
index afe6973..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-
-rm -rf /var/luci-modulecache/;
-exit 0
index ceebc6630ffb0fa0dc42ad353b4ffda6d34da58f..48ae4cc54dc0ed860bbc0200add8dfb54e3c9842 100755 (executable)
@@ -1,6 +1,5 @@
 #!/bin/sh
 
-rm -rf /tmp/luci-modulecache/
 /etc/init.d/uhttpd restart
 /etc/init.d/rpcd reload
 
diff --git a/applications/luci-app-https-dns-proxy/root/etc/uci-defaults/40_luci-https-dns-proxy b/applications/luci-app-https-dns-proxy/root/etc/uci-defaults/40_luci-https-dns-proxy
deleted file mode 100644 (file)
index 2a2f1e7..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh
-rm -rf /var/luci-modulecache/
-exit 0
diff --git a/applications/luci-app-vpn-policy-routing/root/etc/uci-defaults/40_luci-vpn-policy-routing b/applications/luci-app-vpn-policy-routing/root/etc/uci-defaults/40_luci-vpn-policy-routing
deleted file mode 100644 (file)
index afe3de8..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh
-rm -rf /var/luci-modulecache/;
-exit 0
diff --git a/luci.mk b/luci.mk
index fc02e84f7e1fa294ae752ff5d430e8e93d44efb7..2745797c1f3448a67306abfd35f51fbaa221c0fd 100644 (file)
--- a/luci.mk
+++ b/luci.mk
@@ -226,6 +226,7 @@ define Package/$(PKG_NAME)/postinst
 [ -n "$${IPKG_INSTROOT}" ] || {$(foreach script,$(LUCI_DEFAULTS),
        (. /etc/uci-defaults/$(script)) && rm -f /etc/uci-defaults/$(script))
        rm -f /tmp/luci-indexcache
+       rm -rf /tmp/luci-modulecache/
        exit 0
 }
 endef
@@ -233,6 +234,7 @@ else
 define Package/$(PKG_NAME)/postinst
 [ -n "$${IPKG_INSTROOT}" ] || {
        rm -f /tmp/luci-indexcache
+       rm -rf /tmp/luci-modulecache/
        exit 0
 }
 endef