summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rust/files/hardcodepaths.patch
diff options
context:
space:
mode:
authorDeepesh Varatharajan <Deepesh.Varatharajan@windriver.com>2025-01-13 04:08:08 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2025-01-14 11:57:52 +0000
commite51f98d5ff41c72590c63acc96da4d8d68d1c8f0 (patch)
tree92584601c8cf0756258aa8a986721df674bdaecf /meta/recipes-devtools/rust/files/hardcodepaths.patch
parent3805214ecfc683cce6cdc9cf00b0ebad2a69b875 (diff)
downloadpoky-e51f98d5ff41c72590c63acc96da4d8d68d1c8f0.tar.gz
rust: Upgrade 1.80.1->1.81.0
https://blog.rust-lang.org/2024/09/05/Rust-1.81.0.html Drop the following backported patches which is addressed with rust v1.81.0 upgrade. 0001-cargo-do-not-write-host-information-into-compilation.patch https://github.com/rust-lang/cargo/commit/2db0bab16139d094f689587b73539aae386a1919 hardcodepaths.patch https://github.com/rust-lang/rust/commit/28503d69ac204ff208d115aea30dc09d6fca8728 (From OE-Core rev: 611ec9ffbac974f472a828277ba7f3e344e99ca3) Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/rust/files/hardcodepaths.patch')
-rw-r--r--meta/recipes-devtools/rust/files/hardcodepaths.patch46
1 files changed, 0 insertions, 46 deletions
diff --git a/meta/recipes-devtools/rust/files/hardcodepaths.patch b/meta/recipes-devtools/rust/files/hardcodepaths.patch
deleted file mode 100644
index 696654227e..0000000000
--- a/meta/recipes-devtools/rust/files/hardcodepaths.patch
+++ /dev/null
@@ -1,46 +0,0 @@
1When building for the target, some build paths end up embedded in the binaries.
2These changes remove that. Further investigation is needed to work out the way
3to resolve these issues properly upstream.
4
5Upstream-Status: Inappropriate [patches need rework]
6Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
7Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
8
9diff --git a/compiler/rustc_codegen_llvm/src/context.rs b/compiler/rustc_codegen_llvm/src/context.rs
10index b4b2ab1e1f8a..8bb3e3f0557c 100644
11--- a/compiler/rustc_codegen_llvm/src/context.rs
12+++ b/compiler/rustc_codegen_llvm/src/context.rs
13@@ -34,7 +34,6 @@
14 use smallvec::SmallVec;
15
16 use libc::c_uint;
17-use std::borrow::Borrow;
18 use std::cell::{Cell, RefCell};
19 use std::ffi::CStr;
20 use std::str;
21@@ -155,25 +154,6 @@
22 }
23 }
24
25- // Ensure the data-layout values hardcoded remain the defaults.
26- {
27- let tm = crate::back::write::create_informational_target_machine(tcx.sess);
28- llvm::LLVMRustSetDataLayoutFromTargetMachine(llmod, &tm);
29-
30- let llvm_data_layout = llvm::LLVMGetDataLayoutStr(llmod);
31- let llvm_data_layout = str::from_utf8(CStr::from_ptr(llvm_data_layout).to_bytes())
32- .expect("got a non-UTF8 data-layout from LLVM");
33-
34- if target_data_layout != llvm_data_layout {
35- tcx.dcx().emit_err(crate::errors::MismatchedDataLayout {
36- rustc_target: sess.opts.target_triple.to_string().as_str(),
37- rustc_layout: target_data_layout.as_str(),
38- llvm_target: sess.target.llvm_target.borrow(),
39- llvm_layout: llvm_data_layout,
40- });
41- }
42- }
43-
44 let data_layout = SmallCStr::new(&target_data_layout);
45 llvm::LLVMSetDataLayout(llmod, data_layout.as_ptr());
46