cargo/rust from meta-rust-bin in eSDK of yocto 4.x
Hello everyone,
I am currently testing the eSDK and have encountered a problem with cargo/rust. To make some of our projects written in rust work I had to use the meta-rust-bin layer (meta-rust does not work with yocto 4.x). This also works fine with the images or the standard SDK. However, when I want to build the eSDK, I get the following error message.
do_sdk_depends: The file /usr/bin/cargo is installed by both cargo-native and cargo-bin-cross-aarch64, aborting
How can I prevent the outdated cargo/rust from being in the eSDK and use the one from meta-rust-bin instead? Many thanks in advance.
When working with non-standard Rust versions from whatever other layers, I found it makes my life easier when I add the not-used recipes to BBMASK from oe-core, something like
BBMASK += "poky/meta/recipes-devtools/rust"
If there is anything that depends on it explicitly, it should fail loudly during next build, so it can be fixed. Otherwise bitbake will ignore these recipes completely, so it shouldn't clash with the new ones.
Many thanks, I'll try it out.
Hi Sandro,
Recently, I also faced the similar issue as follows:
Quoted 6 lines
ERROR: libstd-rs-1.86.0-r0
do_prepare_recipe_sysroot: The file/usr/bin/cargois installed by both rust-native and cargo-native, aborting
Could you please explain how you resolved this issue? I tried adding BBMASK in the recipe but it didn't seem to work. Also, I noticed that BBMASK isn't widely used in other recipes.
Is there any better solution than using BBMASK?
Regards,
Yash
Hi Yash,
Unfortunately I could not solve the problem and went a different way. I now use ostree to provide the SDK.
Regards,
Sandro