From e94c6d60ff454bbad6509d5ea1fd6caf479b0dd3 Mon Sep 17 00:00:00 2001 From: David Abdurachmanov Date: Thu, 14 Nov 2024 15:13:35 +0200 Subject: [PATCH] Compile with f16 and f128 disabled Signed-off-by: David Abdurachmanov --- ...mpiler_builtins-disable-f16-and-f128.patch | 29 +++++++++++++++++++ rust.spec | 6 +++- 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 0001-compiler_builtins-disable-f16-and-f128.patch diff --git a/0001-compiler_builtins-disable-f16-and-f128.patch b/0001-compiler_builtins-disable-f16-and-f128.patch new file mode 100644 index 0000000..7a03566 --- /dev/null +++ b/0001-compiler_builtins-disable-f16-and-f128.patch @@ -0,0 +1,29 @@ +From 0d289c6b0bbb50f62e3ca388124c29aa9127e6b9 Mon Sep 17 00:00:00 2001 +From: David Abdurachmanov +Date: Thu, 14 Nov 2024 13:10:26 +0000 +Subject: [PATCH] compiler_builtins: disable f16 and f128 + +This is needed to get 1.82.0 compiled. 1.81.0 as a boostrap compiler +will fail as-is. + +Signed-off-by: David Abdurachmanov +--- + library/alloc/Cargo.toml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/library/alloc/Cargo.toml b/library/alloc/Cargo.toml +index 4365bcc4a..7849d463b 100644 +--- a/library/alloc/Cargo.toml ++++ b/library/alloc/Cargo.toml +@@ -10,7 +10,7 @@ edition = "2021" + + [dependencies] + core = { path = "../core" } +-compiler_builtins = { version = "0.1.123", features = ['rustc-dep-of-std'] } ++compiler_builtins = { version = "0.1.123", features = ['rustc-dep-of-std', 'no-f16-f128'] } + + [dev-dependencies] + rand = { version = "0.8.5", default-features = false, features = ["alloc"] } +-- +2.47.0 + diff --git a/rust.spec b/rust.spec index f67def5..0a30433 100644 --- a/rust.spec +++ b/rust.spec @@ -1,6 +1,6 @@ Name: rust Version: 1.82.0 -Release: %autorelease +Release: %autorelease -e 0.riscv64 Summary: The Rust Programming Language License: (Apache-2.0 OR MIT) AND (Artistic-2.0 AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0 AND Unicode-DFS-2016) # ^ written as: (rust itself) and (bundled libraries) @@ -164,6 +164,10 @@ Patch6: rustc-1.82.0-unbundle-sqlite.patch # https://github.com/rust-lang/rust/pull/130034 Patch7: 0001-Fix-enabling-wasm-component-ld-to-match-other-tools.patch +https://github.com/felixonmars/archriscv-packages/pull/4243 +https://github.com/rust-lang/rust/issues/129268#issuecomment-2430520140 +Patch9: 0001-compiler_builtins-disable-f16-and-f128.patch + ### RHEL-specific patches below ### # Simple rpm macros for rust-toolset (as opposed to full rust-packaging)