From 5e1be9374f41c406a2e19ea172cac8f24a516ce8 Mon Sep 17 00:00:00 2001 From: gordonwwang Date: Tue, 23 Jun 2026 20:15:26 +0800 Subject: [PATCH 1/2] Upgrade to 1.96.0 --- 0001-Use-lld-provided-by-system.patch | 20 +++++++++---------- rust.spec | 17 ++++++++++------ rustc-1.76.0-unbundle-sqlite.patch | 28 +++++++++++++-------------- sources | 2 +- 4 files changed, 36 insertions(+), 31 deletions(-) diff --git a/0001-Use-lld-provided-by-system.patch b/0001-Use-lld-provided-by-system.patch index ba02b28..ca74ed4 100644 --- a/0001-Use-lld-provided-by-system.patch +++ b/0001-Use-lld-provided-by-system.patch @@ -1,4 +1,4 @@ -From d8b00ced0429722016cd35c2c5f392cd2b19d440 Mon Sep 17 00:00:00 2001 +From 2f68bbbaa31cef21b912ec4856e3187528ed9679 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Fri, 16 Aug 2024 10:12:58 -0700 Subject: [PATCH] Use lld provided by system @@ -12,10 +12,10 @@ Subject: [PATCH] Use lld provided by system 5 files changed, 4 insertions(+), 4 deletions(-) diff --git a/compiler/rustc_target/src/spec/base/wasm.rs b/compiler/rustc_target/src/spec/base/wasm.rs -index 7ede45766ea..b22362227bb 100644 +index 1f0f564a7790..9173337a1a69 100644 --- a/compiler/rustc_target/src/spec/base/wasm.rs +++ b/compiler/rustc_target/src/spec/base/wasm.rs -@@ -81,8 +81,7 @@ macro_rules! args { +@@ -71,8 +71,7 @@ macro_rules! args { // threaded model which will legalize atomics to normal operations. singlethread: true, @@ -26,19 +26,19 @@ index 7ede45766ea..b22362227bb 100644 pre_link_args, diff --git a/compiler/rustc_target/src/spec/targets/aarch64_unknown_none_softfloat.rs b/compiler/rustc_target/src/spec/targets/aarch64_unknown_none_softfloat.rs -index ad444c139bf..f5f8f18f8b8 100644 +index 05876891ebd7..9f389f9abec7 100644 --- a/compiler/rustc_target/src/spec/targets/aarch64_unknown_none_softfloat.rs +++ b/compiler/rustc_target/src/spec/targets/aarch64_unknown_none_softfloat.rs -@@ -15,7 +15,6 @@ pub(crate) fn target() -> Target { - let opts = TargetOptions { - abi: Abi::SoftFloat, +@@ -16,7 +16,6 @@ pub(crate) fn target() -> Target { + cfg_abi: CfgAbi::SoftFloat, + rustc_abi: Some(RustcAbi::Softfloat), linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes), - linker: Some("rust-lld".into()), features: "+v8a,+strict-align,-neon".into(), relocation_model: RelocModel::Static, disable_redzone: true, diff --git a/compiler/rustc_target/src/spec/targets/aarch64_unknown_uefi.rs b/compiler/rustc_target/src/spec/targets/aarch64_unknown_uefi.rs -index e2c1888e408..4869f85d1e6 100644 +index e2c1888e4084..4869f85d1e6e 100644 --- a/compiler/rustc_target/src/spec/targets/aarch64_unknown_uefi.rs +++ b/compiler/rustc_target/src/spec/targets/aarch64_unknown_uefi.rs @@ -9,6 +9,7 @@ pub(crate) fn target() -> Target { @@ -50,7 +50,7 @@ index e2c1888e408..4869f85d1e6 100644 Target { llvm_target: "aarch64-unknown-windows".into(), diff --git a/compiler/rustc_target/src/spec/targets/x86_64_unknown_none.rs b/compiler/rustc_target/src/spec/targets/x86_64_unknown_none.rs -index 0afe7a0b68b..4671032a437 100644 +index 0afe7a0b68b0..4671032a437c 100644 --- a/compiler/rustc_target/src/spec/targets/x86_64_unknown_none.rs +++ b/compiler/rustc_target/src/spec/targets/x86_64_unknown_none.rs @@ -19,7 +19,7 @@ pub(crate) fn target() -> Target { @@ -63,7 +63,7 @@ index 0afe7a0b68b..4671032a437 100644 features: "-mmx,-sse,-sse2,-sse3,-ssse3,-sse4.1,-sse4.2,-avx,-avx2,+soft-float".into(), supported_sanitizers: SanitizerSet::KCFI | SanitizerSet::KERNELADDRESS, diff --git a/compiler/rustc_target/src/spec/targets/x86_64_unknown_uefi.rs b/compiler/rustc_target/src/spec/targets/x86_64_unknown_uefi.rs -index 333e20bd0ac..16bea38887b 100644 +index 333e20bd0ac1..16bea38887be 100644 --- a/compiler/rustc_target/src/spec/targets/x86_64_unknown_uefi.rs +++ b/compiler/rustc_target/src/spec/targets/x86_64_unknown_uefi.rs @@ -15,6 +15,7 @@ pub(crate) fn target() -> Target { diff --git a/rust.spec b/rust.spec index ebc0343..9ec298e 100644 --- a/rust.spec +++ b/rust.spec @@ -1,7 +1,7 @@ # bootstrap from scratch, set the channel and date from src/stage0.json -%global bootstrap_version 1.94.0 -%global bootstrap_channel 1.94.0 -%global bootstrap_date 2026-03-05 +%global bootstrap_version 1.95.0 +%global bootstrap_channel 1.95.0 +%global bootstrap_date 2026-04-16 # only the specified arch will use the bootstrap binary # run spectool -g rust.spec to get the tarball. @@ -17,8 +17,8 @@ } %global bundled_libgit2_version 1.9.2 -%global min_llvm_version 20.0.0 -%global bundled_llvm_version 21.1.8 +%global min_llvm_version 21.0.0 +%global bundled_llvm_version 22.1.2 %bcond_without bundled_llvm %bcond_with llvm_static # skip upstream tests, because it causes 'No space left on device' @@ -122,7 +122,7 @@ end} Summary: The Rust Programming Language Name: rust -Version: 1.95.0 +Version: 1.96.0 Release: 1%{?dist} License: (ASL 2.0 or MIT) and (BSD and MIT) URL: https://www.rust-lang.org @@ -393,6 +393,7 @@ test -r "%{profiler}" --set build.optimized-compiler-builtins=false \ --set rust.llvm-tools=false \ --set rust.verify-llvm-ir=true \ + --set rust.remap-debuginfo=false \ --enable-extended \ --tools=cargo,clippy,rust-analyzer,rustdoc,rustfmt,src \ --enable-vendor \ @@ -628,6 +629,10 @@ rm -rf "./build/%{rust_triple}/stage2-tools/%{rust_triple}/cit/" %{rustlibdir}/src %changelog +* Wed Jun 24 2026 Wang Guodong - 1.96.0-1 +- [Type] enhancement +- [DESC] Upgrade to 1.96.0 + * Mon Jun 15 2026 Wang Guodong - 1.95.0-1 - [Type] enhancement - [DESC] Upgrade to 1.95.0 diff --git a/rustc-1.76.0-unbundle-sqlite.patch b/rustc-1.76.0-unbundle-sqlite.patch index 53750f4..27c4129 100644 --- a/rustc-1.76.0-unbundle-sqlite.patch +++ b/rustc-1.76.0-unbundle-sqlite.patch @@ -1,23 +1,23 @@ diff -up rustc-beta-src/src/tools/cargo/Cargo.lock.orig rustc-beta-src/src/tools/cargo/Cargo.lock ---- rustc-beta-src/src/tools/cargo/Cargo.lock.orig 2026-03-25 08:58:07.789728719 -0500 -+++ rustc-beta-src/src/tools/cargo/Cargo.lock 2026-03-24 17:34:11.025842497 -0500 -@@ -2824,7 +2824,6 @@ version = "0.36.0" +--- rustc-beta-src/src/tools/cargo/Cargo.lock.orig 2026-04-19 23:11:26.000000000 -0700 ++++ rustc-beta-src/src/tools/cargo/Cargo.lock 2026-04-23 13:19:24.942383499 -0700 +@@ -3152,7 +3152,6 @@ version = "0.37.0" source = "registry+https://github.com/rust-lang/crates.io-index" - checksum = "95b4103cffefa72eb8428cb6b47d6627161e51c2739fc5e3b734584157bc642a" + checksum = "b1f111c8c41e7c61a49cd34e44c7619462967221a6443b0ec299e0ac30cfb9b1" dependencies = [ - "cc", "pkg-config", "vcpkg", ] diff -up rustc-beta-src/src/tools/cargo/Cargo.toml.orig rustc-beta-src/src/tools/cargo/Cargo.toml ---- rustc-beta-src/src/tools/cargo/Cargo.toml.orig 2026-03-25 08:54:36.103702972 -0500 -+++ rustc-beta-src/src/tools/cargo/Cargo.toml 2026-03-25 08:56:07.916420965 -0500 -@@ -83,7 +83,7 @@ proptest = "1.9.0" - pulldown-cmark = { version = "0.13.0", default-features = false, features = ["html"] } - rand = "0.9.2" - regex = "1.12.2" --rusqlite = { version = "0.38.0", features = ["bundled"] } -+rusqlite = { version = "0.38.0", features = [] } - rustc-hash = "2.1.1" +--- rustc-beta-src/src/tools/cargo/Cargo.toml.orig 2026-04-19 23:11:26.000000000 -0700 ++++ rustc-beta-src/src/tools/cargo/Cargo.toml 2026-04-23 13:19:13.141462455 -0700 +@@ -89,7 +89,7 @@ proptest = "1.11.0" + pulldown-cmark = { version = "0.13.3", default-features = false, features = ["html"] } + rand = "0.10.0" + regex = "1.12.3" +-rusqlite = { version = "0.39.0", features = ["bundled"] } ++rusqlite = { version = "0.39.0", features = [] } + rustc-hash = "2.1.2" rustc-stable-hash = "0.1.2" - rustfix = { version = "0.9.5", path = "crates/rustfix" } + rustfix = { version = "0.9.6", path = "crates/rustfix" } diff --git a/sources b/sources index f070408..0aa0399 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rustc-1.95.0-src.tar.xz) = 685912ffff97063e55c85b2d15d06ba734980cef4b6e104caae1ea433958b12a8d651b757eef7b9f5b06dad3c246d819a5ee5574a26e05007ecdd378f0f041d0 +SHA512 (rustc-1.96.0-src.tar.xz) = 4f93df2c8ab5f4c7eb374b96a2dc4be4b134fbe8cf3db777118bd1aad12d3bb0b382c26864fa5d7d7959384701259edc7794a885d710565a91491bbaa337f789 -- Gitee From c71a9f081866b453b08d8357e1c34cd5a16b60ba Mon Sep 17 00:00:00 2001 From: gordonwwang Date: Tue, 23 Jun 2026 20:25:42 +0800 Subject: [PATCH 2/2] use compiler-rt provided by bundled_llvm --- rust.spec | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/rust.spec b/rust.spec index 9ec298e..f6fed35 100644 --- a/rust.spec +++ b/rust.spec @@ -169,7 +169,9 @@ BuildRequires: pkgconfig(openssl) pkgconfig(zlib) BuildRequires: pkgconfig(sqlite3) BuildRequires: pkgconfig(libssh2) BuildRequires: python3 python3-rpm-macros +%if %without bundled_llvm BuildRequires: compiler-rt +%endif BuildRequires: procps-ng gdb glibc-static Requires: %{name}-std-static = %{version}-%{release} Requires: /usr/bin/cc @@ -360,9 +362,14 @@ export CFLAGS_loongarch64_unknown_linux_gnu="-mcmodel=medium" export CXXFLAGS_loongarch64_unknown_linux_gnu="-mcmodel=medium" %endif +%if %with bundled_llvm +# bundled LLVM in-tree compiler-rt, to build profiler +%global profiler true +%else # profiler path is version dependent, and uses LLVM-specific arch names in the filename %define profiler %(echo %{common_libdir}/clang/??/lib/%{_arch}-*-linux-gnu/libclang_rt.profile.a) test -r "%{profiler}" +%endif %configure --disable-option-checking \ --docdir=%{_pkgdocdir} \ -- Gitee