From d9ac50894e55b780aaab43b96536e0ce678ff8f7 Mon Sep 17 00:00:00 2001 From: Darren Hart Date: Sat, 12 Mar 2011 00:15:41 -0800 Subject: n450: replace n450-audio with a proper init script Rewrite n450-audio based on /etc/init.d/skeleton. Update the install to rewrite all the system paths. Signed-off-by: Darren Hart --- meta-n450/recipes-bsp/n450-audio/n450-audio.bb | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'meta-n450/recipes-bsp/n450-audio/n450-audio.bb') diff --git a/meta-n450/recipes-bsp/n450-audio/n450-audio.bb b/meta-n450/recipes-bsp/n450-audio/n450-audio.bb index 20e3a9ad..90ec267b 100644 --- a/meta-n450/recipes-bsp/n450-audio/n450-audio.bb +++ b/meta-n450/recipes-bsp/n450-audio/n450-audio.bb @@ -4,7 +4,7 @@ SECTION = "base" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${POKYBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58" -PR = "r3" +PR = "r4" inherit update-rc.d @@ -16,8 +16,15 @@ INITSCRIPT_NAME = "n450-audio" INITSCRIPT_PARAMS = "defaults 90" do_install() { - install -d ${D}${sysconfdir} \ - ${D}${sysconfdir}/init.d + install -d ${D}${sysconfdir} \ + ${D}${sysconfdir}/init.d install -m 0755 ${WORKDIR}/n450-audio ${D}${sysconfdir}/init.d + cat ${WORKDIR}/${INITSCRIPT_NAME} | \ + sed -e 's,/etc,${sysconfdir},g' \ + -e 's,/usr/sbin,${sbindir},g' \ + -e 's,/var,${localstatedir},g' \ + -e 's,/usr/bin,${bindir},g' \ + -e 's,/usr,${prefix},g' > ${D}${sysconfdir}/init.d/${INITSCRIPT_NAME} + chmod 755 ${D}${sysconfdir}/init.d/${INITSCRIPT_NAME} } -- cgit v1.2.3-54-g00ecf