rust: Upgrade 1.91.1 -> 1.92.0
PATCH 1/2 rust: Upgrade 1.91.1 -> 1.92.0
From: Hemanth Kumar M D <[email protected]>
https://blog.rust-lang.org/2025/12/11/Rust-1.92.0/
Rust changes: https://github.com/rust-lang/rust/releases/tag/1.92.0
Cargo changes: https://doc.rust-lang.org/nightly/cargo/CHANGELOG.html#cargo-192-2025-12-11
Test results summary:
rust v1.92.0
+-----------+--------+---------+ | Machine | Passed | Ignored | +-----------+--------+---------+ | arm-32 | 30,317 | 1,687 | | arm-64 | 30,426 | 1,617 | | x86-32 | 30,335 | 1,664 | | x86-64 | 30,587 | 1,414 | | riscv-64 | 30,426 | 1,617 | +-----------+--------+---------+
Test results difference (1.92.0-1.91.1):
+-----------+--------+---------+ | Machine | Passed | Ignored | +-----------+--------+---------+ | arm-32 | +349 | +177 | | arm-64 | +516 | +170 | | x86-32 | +264 | +217 | | x86-64 | +358 | +167 | | riscv-64 | +281 | +145 | +-----------+--------+---------+
Note: The increase in ignored tests is not due to any additional ignores added in OE. These are primarily upstream-defined ignores introduced in Rust 1.92.0, likely due to architecture-specific constraints or target configuration differences. The only OE-side ignore added is for the no_std simple-runs test on 32-bit ARM, limited to a known upstream issue (rust-lang/rust#146996) and can be reverted once the issue is resolved.
---
meta/conf/distro/include/tcmode-default.inc | 2 +-
.../rust/{cargo_1.91.1.bb => cargo_1.92.0.bb} | 0
...ibstd-rs_1.91.1.bb => libstd-rs_1.92.0.bb} | 0
....91.1.bb => rust-cross-canadian_1.92.0.bb} | 0
meta/recipes-devtools/rust/rust-snapshot.inc | 78 +++++++++----------
meta/recipes-devtools/rust/rust-source.inc | 2 +-
.../rust/{rust_1.91.1.bb => rust_1.92.0.bb} | 0
7 files changed, 41 insertions(+), 41 deletions(-)
rename meta/recipes-devtools/rust/{cargo_1.91.1.bb => cargo_1.92.0.bb} (100%)
rename meta/recipes-devtools/rust/{libstd-rs_1.91.1.bb => libstd-rs_1.92.0.bb} (100%)
rename meta/recipes-devtools/rust/{rust-cross-canadian_1.91.1.bb => rust-cross-canadian_1.92.0.bb} (100%)
rename meta/recipes-devtools/rust/{rust_1.91.1.bb => rust_1.92.0.bb} (100%)meta/conf/distro/include/tcmode-default.inc +1 -1
@@ -12,7 +12,7 @@ PREFERRED_PROVIDER_virtual/gettext ??= "gettext" GCCVERSION ?= "15.%" SDKGCCVERSION ?= "${GCCVERSION}" GLIBCVERSION ?= "2.42%" -RUSTVERSION ?= "1.91.1%" +RUSTVERSION ?= "1.92.0%" PREFERRED_VERSION_gcc ?= "${GCCVERSION}" PREFERRED_VERSION_gcc-cross-${TARGET_ARCH} ?= "${GCCVERSION}"
meta/recipes-devtools/rust/cargo_1.92.0.bb renamed from meta/recipes-devtools/rust/cargo_1.91.1.bb +0 -0
meta/recipes-devtools/rust/libstd-rs_1.92.0.bb renamed from meta/recipes-devtools/rust/libstd-rs_1.91.1.bb +0 -0
meta/recipes-devtools/rust/rust-cross-canadian_1.92.0.bb renamed from meta/recipes-devtools/rust/rust-cross-canadian_1.91.1.bb +0 -0
meta/recipes-devtools/rust/rust-snapshot.inc +39 -39
95 lines not on this page · raw message
meta/recipes-devtools/rust/rust-source.inc +1 -1
@@ -9,7 +9,7 @@ SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n file://revert-link-std-statically-in-rustc_driver-feature.patch;patchdir=${RUSTSRC} \ file://0001-riscv32-Define-plain-syscalls-as-their-time64-varian.patch;patchdir=${RUSTSRC} \ " -SRC_URI[rust.sha256sum] = "66401bb815e236cc6b2aacbbe23b61b286c1fe27a67902e7c0222cfe77b3dbab" +SRC_URI[rust.sha256sum] = "ebee170bfe4c4dfc59521a101de651e5534f4dae889756a5c97ca9ea40d0c307" RUSTSRC = "${UNPACKDIR}/rustc-${RUST_VERSION}-src"
meta/recipes-devtools/rust/rust_1.92.0.bb renamed from meta/recipes-devtools/rust/rust_1.91.1.bb +0 -0
Signature · 1 line
2.49.0
PATCH 2/2 rust: enable default uwtable and ignore arm no_std test
From: Hemanth Kumar M D <[email protected]>
Rust 1.92.0 adds new test that require unwind table support to be enabled by default. Set default-uwtable = true in the generated target spec to match upstream behavior.
ref:https://github.com/rust-lang/rust/commit/fe66eaa67acc47525db6f13cf97d54780d87b805
Also ignore the no_std simple-runs UI test on ARM targets. The test fails with panic=abort due to a known unwind table issue on 32-bit ARM
https://github.com/rust-lang/rust/issues/146996
--- meta/classes-recipe/rust-target-config.bbclass | 1 + .../rust/files/rust-oe-selftest.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+)
meta/classes-recipe/rust-target-config.bbclass +1 -0
@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch): tspec['llvm-floatabi'] = "soft" elif fpu == "hard": tspec['llvm-floatabi'] = "hard" + tspec['default-uwtable'] = True tspec['dynamic-linking'] = True tspec['executables'] = True tspec['linker-is-gnu'] = True
meta/recipes-devtools/rust/files/rust-oe-selftest.patch +12 -0
@@ -254,3 +254,15 @@ index a3562f2fd93..d4e52ed91be 100644 fn linux_hwcap2_aarch64() { let file = concat!(env!("CARGO_MANIFEST_DIR"), "/src/detect/test_data/linux-hwcap2-aarch64.auxv"); +diff --git a/tests/ui/no_std/simple-runs.rs b/tests/ui/no_std/simple-runs.rs +index af44dfe..e6674e5 100644 +--- a/tests/ui/no_std/simple-runs.rs ++++ b/tests/ui/no_std/simple-runs.rs +@@ -2,6 +2,7 @@ + + //@ run-pass + //@ compile-flags: -Cpanic=abort ++//@ ignore-arm FIXME(#146996) + //@ ignore-wasm different `main` convention + + #![feature(lang_items)]
Signature · 1 line
2.49.0
Re: [PATCH 2/2] rust: enable default uwtable and ignore arm no_std test
Quoted 6 lines · On 2025-12-22 4:38 a.m., [email protected] wrote:
From: Hemanth Kumar M D<[email protected]>
Rust 1.92.0 adds new test that require unwind table support to be enabled by default. Set
default-uwtable = truein the generated target spec to match upstream behavior.
Quoted 6 lines
ref:https://github.com/rust-lang/rust/commit/fe66eaa67acc47525db6f13cf97d54780d87b805
Also ignore the
no_stdsimple-runs UI test on ARM targets. The test fails with panic=abort due to a known unwind table issue on 32-bit ARM
Okay and I'm glad to see the upstream issues linked.
Should we make some of these tspec decisions set-able by well-informed users?
Maybe they can already do that using this horridly named "FEATURES" variable. (rename to RUST_FEATURES maybe ?)
For example, this bug:
Unable to produce a Rust static binary with TCLIBC=musl (oe-core/master)
https://bugzilla.yoctoproject.org/show_bug.cgi?id=16076
seems to be due to hard-coding dynamic-linking to True below just after your:
+ tspec['default-uwtable'] = True
change.
I've CCed Nick in case you guys have a quick work-around to enable static linking.
../Randy
Quoted 40 lines
Signed-off-by Hemanth Kumar M D<[email protected]>Signed-off-by Yash Shinde<[email protected]>--- meta/classes-recipe/rust-target-config.bbclass | 1 + .../rust/files/rust-oe-selftest.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+)meta/classes-recipe/rust-target-config.bbclass +1
-0@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch): tspec['llvm-floatabi'] = "soft" elif fpu == "hard": tspec['llvm-floatabi'] = "hard" + tspec['default-uwtable'] = True tspec['dynamic-linking'] = True tspec['executables'] = True tspec['linker-is-gnu'] = Truemeta/recipes-devtools/rust/files/rust-oe-selftest.patch +12
-0@@ -254,3 +254,15 @@ index a3562f2fd93..d4e52ed91be 100644 fn linux_hwcap2_aarch64() { let file = concat!(env!("CARGO_MANIFEST_DIR"), "/src/detect/test_data/linux-hwcap2-aarch64.auxv"); +diff --git a/tests/ui/no_std/simple-runs.rs b/tests/ui/no_std/simple-runs.rs +index af44dfe..e6674e5 100644 +--- a/tests/ui/no_std/simple-runs.rs ++++ b/tests/ui/no_std/simple-runs.rs +@@ -2,6 +2,7 @@ + + //@ run-pass + //@ compile-flags: -Cpanic=abort ++//@ ignore-arm FIXME(#146996) + //@ ignore-wasm different `main` convention + + #![feature(lang_items)]
Signature · 2 lines
# Randy MacLeod # Wind River Linux
Re: [PATCH 2/2] rust: enable default uwtable and ignore arm no_std test
Quoted 12 lines · Randy MacLeod
Quoted 11 lines · On 2025-12-22 4:38 a.m., [email protected] wrote:
From: Hemanth Kumar M D<[email protected]>
Rust 1.92.0 adds new test that require unwind table support to be enabled by default. Set
default-uwtable = truein the generated target spec to match upstream behavior.ref:https://github.com/rust-lang/rust/commit/fe66eaa67acc47525db6f13cf97d54780d87b805
Also ignore the
no_stdsimple-runs UI test on ARM targets. The test fails with panic=abort due to a known unwind table issue on 32-bit ARM
Quoted 9 lines
Quoted 1 line
Okay and I'm glad to see the upstream issues linked.
Should we make some of these tspec decisions set-able by well-informed users?
Maybe they can already do that using this horridly named "FEATURES" variable. (rename to
RUST_FEATURESmaybe ?)
Most of the tspec features are set explicitly here.
We are analyzing on the possibility to check and set them using FEATURES to make user-configurable.
Regards,
Yash
Quoted 61 lines
For example, this bug:
Unable to produce a Rust static binary with TCLIBC=musl (oe-core/master)
https://bugzilla.yoctoproject.org/show_bug.cgi?id=16076seems to be due to hard-coding dynamic-linking to True below just after your:
+ tspec['default-uwtable'] = True
change.
I've CCed Nick in case you guys have a quick work-around to enable static linking.
../Randy
Quoted 39 lines
Signed-off-by Hemanth Kumar M D<[email protected]>Signed-off-by Yash Shinde<[email protected]>--- meta/classes-recipe/rust-target-config.bbclass | 1 + .../rust/files/rust-oe-selftest.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+)meta/classes-recipe/rust-target-config.bbclass +1
-0@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch): tspec['llvm-floatabi'] = "soft" elif fpu == "hard": tspec['llvm-floatabi'] = "hard" + tspec['default-uwtable'] = True tspec['dynamic-linking'] = True tspec['executables'] = True tspec['linker-is-gnu'] = Truemeta/recipes-devtools/rust/files/rust-oe-selftest.patch +12
-0@@ -254,3 +254,15 @@ index a3562f2fd93..d4e52ed91be 100644 fn linux_hwcap2_aarch64() { let file = concat!(env!("CARGO_MANIFEST_DIR"), "/src/detect/test_data/linux-hwcap2-aarch64.auxv"); +diff --git a/tests/ui/no_std/simple-runs.rs b/tests/ui/no_std/simple-runs.rs +index af44dfe..e6674e5 100644 +--- a/tests/ui/no_std/simple-runs.rs ++++ b/tests/ui/no_std/simple-runs.rs +@@ -2,6 +2,7 @@ + + //@ run-pass + //@ compile-flags: -Cpanic=abort ++//@ ignore-arm FIXME(#146996) + //@ ignore-wasm different `main` convention + + #![feature(lang_items)]Signature · 2 lines
# Randy MacLeod # Wind River Linux
Signature · 2 lines
Regards, Yash Shinde
Re: [PATCH 2/2] rust: enable default uwtable and ignore arm no_std test
In reply to Randy MacLeodHi Randy,
Quoted 12 lines · Randy MacLeod
Quoted 11 lines · On 2025-12-22 4:38 a.m., [email protected] wrote:
From: Hemanth Kumar M D<[email protected]>
Rust 1.92.0 adds new test that require unwind table support to be enabled by default. Set
default-uwtable = truein the generated target spec to match upstream behavior.ref:https://github.com/rust-lang/rust/commit/fe66eaa67acc47525db6f13cf97d54780d87b805
Also ignore the
no_stdsimple-runs UI test on ARM targets. The test fails with panic=abort due to a known unwind table issue on 32-bit ARM
Quoted 9 lines
Quoted 1 line
Okay and I'm glad to see the upstream issues linked.
Should we make some of these tspec decisions set-able by well-informed users?
Maybe they can already do that using this horridly named "FEATURES" variable. (rename to
RUST_FEATURESmaybe ?)
The existing FEATURES variables in the .bbclass is currently used for low-level CPU instructions. As you suggested, RUST_FEATURE variable will allow us to keep H/W tuning separate from high-level compiler policy. I will discuss with team.
Quoted 7 lines
For example, this bug:
Unable to produce a Rust static binary with TCLIBC=musl (oe-core/master)
https://bugzilla.yoctoproject.org/show_bug.cgi?id=16076
Although the bug report did not include a specific recipe, I used ripgrep as a reference to validate the issue and was able to build a fully static musl binary.
I found that changing *tspec['dynamic-linking']* from *true *to *false *in the .bbclass alone was not enough to produce static binary. The problem had two parts.
First, at the target specification level, rust-target-config.bbclass forces dynamic-linking to true. Because of this, the compiler assumes the target is dynamic and ignores requests for static linking. As a result, it still produces a dynamic PIE binary that depends on the musl dynamic loader (ld-musl.so).
Second, at the linker wrapper level, *target-rust-ccld* enforces dynamic linking by default. It automatically adds flags such as*-Wl,-Bdynamic* and *-pie*. This conflicts with the compiler’s static intent and causes it to pick shared libraries from the sysroot, which leads to the error
“*attempted static linking of dynamic object*”.
To work around this and meet static musl requirements, I applied recipe-specific changes to bypass the wrapper’s enforcement and handle circular dependencies and crate-level leakage.
With these adjustments, the final link correctly uses static archives instead of falling back to shared objects.
I will update the bug report with these findings.
Quoted 57 lines
seems to be due to hard-coding dynamic-linking to True below just after your:
+ tspec['default-uwtable'] = True
change.
I've CCed Nick in case you guys have a quick work-around to enable static linking.
../Randy
Quoted 39 lines
Signed-off-by Hemanth Kumar M D<[email protected]>Signed-off-by Yash Shinde<[email protected]>--- meta/classes-recipe/rust-target-config.bbclass | 1 + .../rust/files/rust-oe-selftest.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+)meta/classes-recipe/rust-target-config.bbclass +1
-0@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch): tspec['llvm-floatabi'] = "soft" elif fpu == "hard": tspec['llvm-floatabi'] = "hard" + tspec['default-uwtable'] = True tspec['dynamic-linking'] = True tspec['executables'] = True tspec['linker-is-gnu'] = Truemeta/recipes-devtools/rust/files/rust-oe-selftest.patch +12
-0@@ -254,3 +254,15 @@ index a3562f2fd93..d4e52ed91be 100644 fn linux_hwcap2_aarch64() { let file = concat!(env!("CARGO_MANIFEST_DIR"), "/src/detect/test_data/linux-hwcap2-aarch64.auxv"); +diff --git a/tests/ui/no_std/simple-runs.rs b/tests/ui/no_std/simple-runs.rs +index af44dfe..e6674e5 100644 +--- a/tests/ui/no_std/simple-runs.rs ++++ b/tests/ui/no_std/simple-runs.rs +@@ -2,6 +2,7 @@ + + //@ run-pass + //@ compile-flags: -Cpanic=abort ++//@ ignore-arm FIXME(#146996) + //@ ignore-wasm different `main` convention + + #![feature(lang_items)]Signature · 2 lines
# Randy MacLeod # Wind River Linux