diff options
Diffstat (limited to 'meta/recipes-devtools/run-postinsts')
-rwxr-xr-x | meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts b/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts index c94c3e92ec..11141ec71f 100755 --- a/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts +++ b/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts | |||
@@ -16,7 +16,16 @@ for pm in rpm deb ipk; do | |||
16 | fi | 16 | fi |
17 | done | 17 | done |
18 | 18 | ||
19 | [ -z "$pi_dir" ] && exit 0 | 19 | remove_rcsd_link () { |
20 | if [ -n "`which update-rc.d`" ]; then | ||
21 | update-rc.d -f run-postinsts remove | ||
22 | fi | ||
23 | } | ||
24 | |||
25 | if [ -z "$pi_dir" ]; then | ||
26 | remove_rcsd_link | ||
27 | exit 0 | ||
28 | fi | ||
20 | 29 | ||
21 | [ -e #SYSCONFDIR#/default/postinst ] && . #SYSCONFDIR#/default/postinst | 30 | [ -e #SYSCONFDIR#/default/postinst ] && . #SYSCONFDIR#/default/postinst |
22 | 31 | ||
@@ -43,7 +52,5 @@ done | |||
43 | # and the rcS.d link | 52 | # and the rcS.d link |
44 | if [ $remove_pi_dir = 1 ]; then | 53 | if [ $remove_pi_dir = 1 ]; then |
45 | rm -rf $pi_dir | 54 | rm -rf $pi_dir |
46 | if [ -n "`which update-rc.d`" ]; then | 55 | remove_rcsd_link |
47 | update-rc.d -f run-postinsts remove | ||
48 | fi | ||
49 | fi | 56 | fi |