diff options
author | Ross Burton <ross.burton@intel.com> | 2013-03-05 11:57:00 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-03-26 22:42:37 +0000 |
commit | 2c403979c03898c679c5a1e1092aec784dbeb77c (patch) | |
tree | 491f5ed9717b0fb0d8abc2e3880e62748d636440 /meta/classes/update-rc.d.bbclass | |
parent | cd3c8c9cea560a584178ed831bfc3c014b6663e6 (diff) | |
download | openembedded-core-2c403979c03898c679c5a1e1092aec784dbeb77c.tar.gz openembedded-core-2c403979c03898c679c5a1e1092aec784dbeb77c.tar.bz2 openembedded-core-2c403979c03898c679c5a1e1092aec784dbeb77c.zip |
update-rcd: drop depends to recommends, check for update-rcd in scripts
Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/classes/update-rc.d.bbclass')
-rw-r--r-- | meta/classes/update-rc.d.bbclass | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/meta/classes/update-rc.d.bbclass b/meta/classes/update-rc.d.bbclass index 06b91c10ed..0997702ee9 100644 --- a/meta/classes/update-rc.d.bbclass +++ b/meta/classes/update-rc.d.bbclass @@ -6,7 +6,7 @@ UPDATERCD_virtclass-cross = "" UPDATERCD_class-native = "" UPDATERCD_class-nativesdk = "" -RDEPENDS_${UPDATERCPN}_append = " ${UPDATERCD}" +RRECOMMENDS_${UPDATERCPN}_append = " ${UPDATERCD}" INITSCRIPT_PARAMS ?= "defaults" @@ -18,7 +18,9 @@ if test "x$D" != "x"; then else OPT="-s" fi -update-rc.d $OPT ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS} +if type update-rc.d >/dev/null; then + update-rc.d $OPT ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS} +fi } updatercd_prerm() { @@ -28,10 +30,13 @@ fi } updatercd_postrm() { -if [ "$D" != "" ]; then - update-rc.d -f -r $D ${INITSCRIPT_NAME} remove +if test "$D" != ""; then + OPT="-f -r $D" else - update-rc.d ${INITSCRIPT_NAME} remove + OPT="" +fi +if type update-rc.d >/dev/null; then + update-rc.d $OPT ${INITSCRIPT_NAME} remove fi } |