[yocto] How to install a service generated by update-rc.d?

S.Jaritz at esa-grimma.de S.Jaritz at esa-grimma.de
Wed Jul 6 03:01:32 PDT 2016


Yes - The installation of the can_if into /etc/init.d was missing.

By adding:

do_install () {
        install -d ${D}${sysconfdir}/init.d
        cat ${WORKDIR}/can_if | \
          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/can_if
        chmod a+x ${D}${sysconfdir}/init.d/can_if
}

It was solved!

Merci & Regards!

Stefan Jaritz

------------------------------------------------------------
ESA Elektroschaltanlagen Grimma GmbH
Broner Ring 30
04668 Grimma
Telefon: +49 3437 9211 176
Telefax: +49 3437 9211 26
E-Mail: s.jaritz at esa-grimma.de
Internet: www.esa-grimma.de


Geschäftsführer:
Dipl.-Ing. Jörg Gaitzsch
Jörg Reinker

Sitz der Gesellschaft: Grimma
Ust.-ID: DE 141784437
Amtsgericht: Leipzig, HRB 5159
Steuernummer: 238/108/00755


Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte 
Informationen. 
Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich 
erhalten 
haben, informieren Sie bitte sofort den Absender und löschen Sie diese 
Nachricht. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser 
Mail 
ist nicht gestattet.

This e-mail may contain confidential and/or privileged information. If you 
are 
not the intended recipient (or have received this e-mail in error) please 
notify the sender immediately and destroy this e-mail. Any unauthorized 
copying, disclosure or distribution of the material in this e-mail is 
strictly 
forbidden.



Von:    Anders Darander <anders at chargestorm.se>
An:     yocto at yoctoproject.org
Datum:  06.07.2016 11:40
Betreff:        Re: [yocto] How to install a service generated by 
update-rc.d?
Gesendet von:   yocto-bounces at yoctoproject.org



* S.Jaritz at esa-grimma.de <S.Jaritz at esa-grimma.de> [160706 11:22]:
> I want to start a service that generates Sockets for the CAN Modules. 
> Manually configuring the system is no problem, but I like to have it 
done 
> by yocto. Below I give the code of my recipe (socketcan.bb):

> SUMMARY = "the config for the can socket interface"
> SECTION = "CAN"
> LICENSE = "CLOSED"

> inherit update-rc.d

> RDEPENDS_${PN} = "initscripts"

> DEPENDS = "iproute2"

> SRC_URI = "file://can_if"

> INITSCRIPT_PARAMS = "start 02 2 3 4 5 . stop 01 0 1 6 ."
> INITSCRIPT_NAME = "can_if"

> CONFFILES_${PN} += "${sysconfdir}/init.d/can_if"

If this is the complete recipe, you never install can_if...

Cheers,
Anders

-- 
Anders Darander, Senior System Architect
ChargeStorm AB / eStorm AB
-- 
_______________________________________________
yocto mailing list
yocto at yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20160706/8315e368/attachment.html>


More information about the yocto mailing list