summaryrefslogtreecommitdiffstats
path: root/documentation
diff options
context:
space:
mode:
authorOvidiu Panait <ovidiu.panait@windriver.com>2025-11-11 00:27:10 +0200
committerSteve Sakoman <steve@sakoman.com>2025-11-26 07:50:35 -0800
commitee521bb17cdec4e5295efc18acfdbf26d09cc683 (patch)
treed5bc411cbff56de8ae5c0d43b4e9b66f4b09f1ed /documentation
parent681244152cf213ace022f922f6070dc86462bcdf (diff)
downloadpoky-ee521bb17cdec4e5295efc18acfdbf26d09cc683.tar.gz
rust-target-config: fix nativesdk-libstd-rs build with baremetal
If TCLIBC='baremetal' is set in local.conf, nativesdk-libstd-rs build fails with: | error[E0412]: cannot find type `c_char` in the crate root | --> /usr/src/debug/libstd-rs/1.75.0/rustc-1.75.0-src/vendor/libc/src/unix/mod.rs:56:29 | | | 6 | pub type c_schar = i8; | | ---------------------- similarly named type alias `c_schar` defined here | ... | 56 | pub gr_name: *mut ::c_char, | | ^^^^^^ This happens because rust_gen_target() sets os="none" when TCLIBC is 'baremetal' - even for nativesdk targets. However, nativesdk packages are built against glibc, so the correct 'os' value should be "linux". Fix this by setting the os field based on {TARGET,HOST,BUILD}_OS variables, as it is already done in rust_base_triple(), instead of relying on TCLIBC. (From OE-Core rev: 4c3f321304f2aa8b75cb58699b59fea80a23690c) Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (master rev: 3eaf2cd5647585a1e6df03fc20e2753da27bb692) -- backport Signed-off-by: Stefan Ghinea <stefan.ghinea@windriver.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'documentation')
0 files changed, 0 insertions, 0 deletions