[yocto] Missing service file

Maciej Pijanowski maciej.pijanowski at 3mdeb.com
Thu Jul 18 03:19:13 PDT 2019


On 18.07.2019 12:01, JH wrote:
> Hi,
>
> I set up a service file at following myapp.bb file, but that service
> file was not installed to /lib/systemd/system. What could I be wrong
> here?
Not installed means it's not in the final image on the target? Which
package gets installed into the
image? I guess the ${PN} package.

Have you inspected the recipe
work/YOUR_TARGET/RECIPE_NAME/RECIPE_VERSION/image dir?
Maybe it is present there, but not in the package you are installing
(check the content of the pacakges-split dir as well).

You may use the:

FILES_${PN} += "/lib/systemd/system/${PN}.service

to force packaging the file into the ${PN} package.
>
>
> SYSTEMD_SERVICE_${PN} = "${PN}.service"
> SYSTEMD_AUTO_ENABLE_${PN} = "enable"
>
> do_install() {
> ......
> install -m 0644 ${S}/lib/systemd/system/${PN}.service
> ${D}/${systemd_system_unitdir}
> }
>
> Thank you.
>
> Kind regards,
>
> - jh

-- 
Maciej Pijanowski
Embedded Systems Engineer
https://3mdeb.com | @3mdeb_com


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: OpenPGP digital signature
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20190718/7dca6936/attachment.pgp>


More information about the yocto mailing list