summaryrefslogtreecommitdiffstats
path: root/debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-19 09:26:37 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-19 09:26:37 +0000
commit1c69ecb2dd463a5cd922e872386381e1cc17147e (patch)
treed49e9c5086b704151975474cb9ae68509ffa4787 /debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch
parentMerging upstream version 1.76.0+dfsg1. (diff)
downloadrustc-1c69ecb2dd463a5cd922e872386381e1cc17147e.tar.xz
rustc-1c69ecb2dd463a5cd922e872386381e1cc17147e.zip
Merging debian version 1.76.0+dfsg1-1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch')
-rw-r--r--debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch120
1 files changed, 120 insertions, 0 deletions
diff --git a/debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch b/debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch
new file mode 100644
index 000000000..ced256d18
--- /dev/null
+++ b/debian/patches/upstream/u-riscv-disable-unpacked-split-debuginfo.patch
@@ -0,0 +1,120 @@
+From: kxxt <rsworktech@outlook.com>
+Date: Wed, 31 Jan 2024 09:02:18 +0800
+Subject: [PATCH] riscv only supports split_debuginfo=off for now
+
+Disable packed/unpacked options for riscv linux/android.
+Other riscv targets already only have the off option.
+
+The packed/unpacked options might be supported in the future.
+See upstream issue for more details:
+https://github.com/llvm/llvm-project/issues/56642
+
+Bug: https://github.com/rust-lang/rust/issues/110224
+---
+ .../rustc_target/src/spec/targets/riscv32gc_unknown_linux_gnu.rs | 5 ++++-
+ .../rustc_target/src/spec/targets/riscv32gc_unknown_linux_musl.rs | 5 ++++-
+ compiler/rustc_target/src/spec/targets/riscv64_linux_android.rs | 5 ++++-
+ .../rustc_target/src/spec/targets/riscv64gc_unknown_linux_gnu.rs | 5 ++++-
+ .../rustc_target/src/spec/targets/riscv64gc_unknown_linux_musl.rs | 5 ++++-
+ 5 files changed, 20 insertions(+), 5 deletions(-)
+
+diff --git a/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_gnu.rs b/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_gnu.rs
+index 06e8f18..0be32cb 100644
+--- a/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_gnu.rs
++++ b/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_gnu.rs
+@@ -1,4 +1,6 @@
+-use crate::spec::{base, CodeModel, Target, TargetOptions};
++use std::borrow::Cow;
++
++use crate::spec::{base, CodeModel, SplitDebuginfo, Target, TargetOptions};
+
+ pub fn target() -> Target {
+ Target {
+@@ -12,6 +14,7 @@ pub fn target() -> Target {
+ features: "+m,+a,+f,+d,+c".into(),
+ llvm_abiname: "ilp32d".into(),
+ max_atomic_width: Some(32),
++ supported_split_debuginfo: Cow::Borrowed(&[SplitDebuginfo::Off]),
+ ..base::linux_gnu::opts()
+ },
+ }
+diff --git a/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_musl.rs b/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_musl.rs
+index 722703d..cfa9990 100644
+--- a/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_musl.rs
++++ b/compiler/rustc_target/src/spec/targets/riscv32gc_unknown_linux_musl.rs
+@@ -1,4 +1,6 @@
+-use crate::spec::{base, CodeModel, Target, TargetOptions};
++use std::borrow::Cow;
++
++use crate::spec::{base, CodeModel, SplitDebuginfo, Target, TargetOptions};
+
+ pub fn target() -> Target {
+ Target {
+@@ -12,6 +14,7 @@ pub fn target() -> Target {
+ features: "+m,+a,+f,+d,+c".into(),
+ llvm_abiname: "ilp32d".into(),
+ max_atomic_width: Some(32),
++ supported_split_debuginfo: Cow::Borrowed(&[SplitDebuginfo::Off]),
+ ..base::linux_musl::opts()
+ },
+ }
+diff --git a/compiler/rustc_target/src/spec/targets/riscv64_linux_android.rs b/compiler/rustc_target/src/spec/targets/riscv64_linux_android.rs
+index 40e447d..762197d 100644
+--- a/compiler/rustc_target/src/spec/targets/riscv64_linux_android.rs
++++ b/compiler/rustc_target/src/spec/targets/riscv64_linux_android.rs
+@@ -1,4 +1,6 @@
+-use crate::spec::{base, CodeModel, SanitizerSet, Target, TargetOptions};
++use std::borrow::Cow;
++
++use crate::spec::{base, CodeModel, SanitizerSet, SplitDebuginfo, Target, TargetOptions};
+
+ pub fn target() -> Target {
+ Target {
+@@ -13,6 +15,7 @@ pub fn target() -> Target {
+ llvm_abiname: "lp64d".into(),
+ supported_sanitizers: SanitizerSet::ADDRESS,
+ max_atomic_width: Some(64),
++ supported_split_debuginfo: Cow::Borrowed(&[SplitDebuginfo::Off]),
+ ..base::android::opts()
+ },
+ }
+diff --git a/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_gnu.rs b/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_gnu.rs
+index c0969d4..e71929a 100644
+--- a/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_gnu.rs
++++ b/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_gnu.rs
+@@ -1,4 +1,6 @@
+-use crate::spec::{base, CodeModel, Target, TargetOptions};
++use std::borrow::Cow;
++
++use crate::spec::{base, CodeModel, SplitDebuginfo, Target, TargetOptions};
+
+ pub fn target() -> Target {
+ Target {
+@@ -12,6 +14,7 @@ pub fn target() -> Target {
+ features: "+m,+a,+f,+d,+c".into(),
+ llvm_abiname: "lp64d".into(),
+ max_atomic_width: Some(64),
++ supported_split_debuginfo: Cow::Borrowed(&[SplitDebuginfo::Off]),
+ ..base::linux_gnu::opts()
+ },
+ }
+diff --git a/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_musl.rs b/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_musl.rs
+index 656e260..8ea28d6 100644
+--- a/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_musl.rs
++++ b/compiler/rustc_target/src/spec/targets/riscv64gc_unknown_linux_musl.rs
+@@ -1,4 +1,6 @@
+-use crate::spec::{base, CodeModel, Target, TargetOptions};
++use std::borrow::Cow;
++
++use crate::spec::{base, CodeModel, SplitDebuginfo, Target, TargetOptions};
+
+ pub fn target() -> Target {
+ Target {
+@@ -12,6 +14,7 @@ pub fn target() -> Target {
+ features: "+m,+a,+f,+d,+c".into(),
+ llvm_abiname: "lp64d".into(),
+ max_atomic_width: Some(64),
++ supported_split_debuginfo: Cow::Borrowed(&[SplitDebuginfo::Off]),
+ ..base::linux_musl::opts()
+ },
+ }