Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

classes/rust_bin-common: avoid failing when os does not match #202

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

antznin
Copy link

@antznin antznin commented Feb 19, 2025

The rust_bin-common defines rust_target(), a function called at parsing time by bitbake. Calling bb.fatal() in a multiconfig context builds is problematic, because the alternate config might not build for Linux. For example when building a baremetal companion firmware.

Yet, our multiconfig recipes are still evaluated during parsing, and in this case, it makes more sense skipping the recipe rather than producing an error. Use bb.parse.SkipRecipe() instead of bb.fatal().


This can be easily reproduced by trying to build with meta-rust-bin and the beagleplay machine in the meta-ti-bsp layer. The multiconfig build (k3r5) will trigger hundreds of errors.

The rust_bin-common defines rust_target(), a function called at parsing
time by bitbake. Calling bb.fatal() in a multiconfig context builds is
problematic, because the alternate config might not build for Linux. For
example when building a baremetal companion firmware.

Yet, our multiconfig recipes are still evaluated during parsing, and in
this case, it makes more sense skipping the recipe rather than producing
an error. Use bb.parse.SkipRecipe() instead of bb.fatal().

Signed-off-by: Antonin Godard <[email protected]>
@ernstp-se
Copy link

Does my PR help with this also in any way? #201

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants