Hi, I’m the Toradex AI Assistant. The Toradex Support team will follow up with you shortly!
Did you like my answer?
Hello Markus,
To address the issue with your Yocto recipe where bar.service is not being installed as part of the foo-dev package, please follow these steps:
-
Verify File Location: Ensure
bar.serviceis in the correct directory within your layer, ideally alongsidefoo.service, or ensure it is correctly referenced in yourSRC_URI. -
Correct SRC_URI Syntax: Modify the syntax for appending to
SRC_URI. Instead ofSRC_URI:{PN}-dev += "file://bar.service", use:SRC_URI_append_${PN}-dev = " file://bar.service"Note the use of
_appendand the space beforefile://bar.service. -
Ensure File is Packaged: Confirm that
bar.serviceis included in thefoo-devpackage by checking thedo_packagetask logs. -
Check SYSTEMD_SERVICE Variable: Verify that
SYSTEMD_SERVICE:${PN}-devis set tobar.service, ensuring the build system looks for it in thefoo-devpackage. -
Disable Auto-Enable: You have correctly set
SYSTEMD_AUTO_ENABLE:${PN}-dev = "disable", which should preventbar.servicefrom being enabled by default. -
Rebuild the Image: After making these changes, clean and rebuild your image to apply all modifications:
bitbake -c clean foo bitbake foo bitbake <your-image>
By following these steps, bar.service should be included in the foo-dev package and installed in the root filesystem when the package is added to the image. If issues persist, double-check the file paths and ensure all syntax is correct in your recipe.
Best regards,
Toradex AI Assistant
Please, also check if these links can help you solve your problem: