aboutsummaryrefslogtreecommitdiffstats
path: root/package/base-files/files
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2014-09-16 11:56:19 +0000
committerJohn Crispin <blogic@openwrt.org>2014-09-16 11:56:19 +0000
commita0bbe0d6ce12fd8ca7d60061ed6756c247fc45d9 (patch)
tree5b8926dfc465868bbff96e7e131d2e4122bff9c9 /package/base-files/files
parent420eec3ba8ff272511d476381734a65335999510 (diff)
downloadmaster-187ad058-a0bbe0d6ce12fd8ca7d60061ed6756c247fc45d9.tar.gz
master-187ad058-a0bbe0d6ce12fd8ca7d60061ed6756c247fc45d9.tar.bz2
master-187ad058-a0bbe0d6ce12fd8ca7d60061ed6756c247fc45d9.zip
postinst trigger: the new postinst trigger broke IB
Signed-off-by: John Crispin <blogic@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@42571 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/base-files/files')
-rwxr-xr-xpackage/base-files/files/lib/functions.sh9
1 files changed, 6 insertions, 3 deletions
diff --git a/package/base-files/files/lib/functions.sh b/package/base-files/files/lib/functions.sh
index 67f4a046e5..fafb7a340f 100755
--- a/package/base-files/files/lib/functions.sh
+++ b/package/base-files/files/lib/functions.sh
@@ -197,9 +197,12 @@ default_postinst() {
done
done
}
- [ -n "${IPKG_INSTROOT}" -o "$PKG_UPGRADE" = "1" ] || for i in `cat /usr/lib/opkg/info/${name}.list | grep "^/etc/init.d/"`; do
- $i enable
- $i start
+ [ "$PKG_UPGRADE" = "1" ] || for i in `cat ${IPKG_INSTROOT}/usr/lib/opkg/info/${name}.list | grep "^/etc/init.d/"`; do
+ [ -n "${IPKG_INSTROOT}" ] && $(which bash) ${IPKG_INSTROOT}/etc/rc.common ${IPKG_INSTROOT}$i enable; \
+ [ -n "${IPKG_INSTROOT}" ] || {
+ $i enable
+ $i start
+ }
done
return 0
}