From 668ae67a4fa15e65e26d1c5f480061fe07e4b9db Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Mon, 16 Nov 2009 22:00:22 +0000 Subject: update-rc.d: Add native version, add native dependency to class, convert staging function Signed-off-by: Richard Purdie --- meta/classes/update-rc.d.bbclass | 2 +- meta/packages/update-rc.d/files/add-verbose.patch | 47 ---------------------- .../update-rc.d/update-rc.d/add-verbose.patch | 47 ++++++++++++++++++++++ meta/packages/update-rc.d/update-rc.d_0.7.bb | 7 ++-- 4 files changed, 51 insertions(+), 52 deletions(-) delete mode 100644 meta/packages/update-rc.d/files/add-verbose.patch create mode 100644 meta/packages/update-rc.d/update-rc.d/add-verbose.patch (limited to 'meta') diff --git a/meta/classes/update-rc.d.bbclass b/meta/classes/update-rc.d.bbclass index 5a8062cc7..0c648edb4 100644 --- a/meta/classes/update-rc.d.bbclass +++ b/meta/classes/update-rc.d.bbclass @@ -1,4 +1,4 @@ -DEPENDS_append = " update-rc.d" +DEPENDS_append = " update-rc.d-native" RDEPENDS_${PN}_append = " update-rc.d" INITSCRIPT_PARAMS ?= "defaults" diff --git a/meta/packages/update-rc.d/files/add-verbose.patch b/meta/packages/update-rc.d/files/add-verbose.patch deleted file mode 100644 index 0f068308f..000000000 --- a/meta/packages/update-rc.d/files/add-verbose.patch +++ /dev/null @@ -1,47 +0,0 @@ ---- update-rc.d/update-rc.d.org 2005-01-03 00:30:47.000000000 +0200 -+++ update-rc.d/update-rc.d 2007-12-01 19:41:08.000000000 +0200 -@@ -19,6 +19,7 @@ - notreally=0 - force=0 - dostart=0 -+verbose=0 - - usage() - { -@@ -28,6 +29,7 @@ - update-rc.d [-n] [-r ] [-s] start|stop NN runlvl [runlvl] [...] . - -n: not really - -f: force -+ -v: verbose - -r: alternate root path (default is /) - -s: invoke start methods if appropriate to current runlevel - EOF -@@ -69,7 +71,7 @@ - lev=`echo $2 | cut -d/ -f1` - nn=`echo $2 | cut -d/ -f2` - fn="${etcd}${lev}.d/${startstop}${nn}${bn}" -- echo " $fn -> ../init.d/$bn" -+ [ $verbose -eq 1 ] && echo " $fn -> ../init.d/$bn" - if [ $notreally -eq 0 ]; then - mkdir -p `dirname $fn` - ln -s ../init.d/$bn $fn -@@ -89,7 +91,7 @@ - exit 0 - fi - -- echo " Adding system startup for $initd/$bn ..." -+ echo " Adding system startup for $initd/$bn." - - for i in $startlinks; do - dolink S $i -@@ -105,6 +107,10 @@ - shift - continue - ;; -+ -v) verbose=1 -+ shift -+ continue -+ ;; - -f) force=1 - shift - continue diff --git a/meta/packages/update-rc.d/update-rc.d/add-verbose.patch b/meta/packages/update-rc.d/update-rc.d/add-verbose.patch new file mode 100644 index 000000000..0f068308f --- /dev/null +++ b/meta/packages/update-rc.d/update-rc.d/add-verbose.patch @@ -0,0 +1,47 @@ +--- update-rc.d/update-rc.d.org 2005-01-03 00:30:47.000000000 +0200 ++++ update-rc.d/update-rc.d 2007-12-01 19:41:08.000000000 +0200 +@@ -19,6 +19,7 @@ + notreally=0 + force=0 + dostart=0 ++verbose=0 + + usage() + { +@@ -28,6 +29,7 @@ + update-rc.d [-n] [-r ] [-s] start|stop NN runlvl [runlvl] [...] . + -n: not really + -f: force ++ -v: verbose + -r: alternate root path (default is /) + -s: invoke start methods if appropriate to current runlevel + EOF +@@ -69,7 +71,7 @@ + lev=`echo $2 | cut -d/ -f1` + nn=`echo $2 | cut -d/ -f2` + fn="${etcd}${lev}.d/${startstop}${nn}${bn}" +- echo " $fn -> ../init.d/$bn" ++ [ $verbose -eq 1 ] && echo " $fn -> ../init.d/$bn" + if [ $notreally -eq 0 ]; then + mkdir -p `dirname $fn` + ln -s ../init.d/$bn $fn +@@ -89,7 +91,7 @@ + exit 0 + fi + +- echo " Adding system startup for $initd/$bn ..." ++ echo " Adding system startup for $initd/$bn." + + for i in $startlinks; do + dolink S $i +@@ -105,6 +107,10 @@ + shift + continue + ;; ++ -v) verbose=1 ++ shift ++ continue ++ ;; + -f) force=1 + shift + continue diff --git a/meta/packages/update-rc.d/update-rc.d_0.7.bb b/meta/packages/update-rc.d/update-rc.d_0.7.bb index dd370e6ff..362f8603c 100644 --- a/meta/packages/update-rc.d/update-rc.d_0.7.bb +++ b/meta/packages/update-rc.d/update-rc.d_0.7.bb @@ -13,11 +13,10 @@ PACKAGE_ARCH = "all" do_compile() { } -do_stage() { - install -m 0755 ${S}/update-rc.d ${STAGING_BINDIR_NATIVE}/ -} - +NATIVE_INSTALL_WORKS = "1" do_install() { install -d ${D}${sbindir} install -m 0755 ${S}/update-rc.d ${D}${sbindir}/update-rc.d } + +BBCLASSEXTEND = "native" \ No newline at end of file -- cgit v1.2.3