From 1dd0a01deb61bd8ec132c5f39943af2eb4b2eaf9 Mon Sep 17 00:00:00 2001 From: Ana Hobden Date: Tue, 7 Oct 2025 13:06:56 -0700 Subject: [PATCH] Fix backtraces with -C panic=abort on qnx; emit unwind tables by default --- compiler/rustc_target/src/spec/base/nto_qnx.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/compiler/rustc_target/src/spec/base/nto_qnx.rs b/compiler/rustc_target/src/spec/base/nto_qnx.rs index 3f35b8b801ab9..6498742917545 100644 --- a/compiler/rustc_target/src/spec/base/nto_qnx.rs +++ b/compiler/rustc_target/src/spec/base/nto_qnx.rs @@ -12,6 +12,9 @@ pub(crate) fn opts() -> TargetOptions { has_thread_local: false, linker: Some("qcc".into()), os: "nto".into(), + // We want backtraces to work by default and they rely on unwind tables + // (regardless of `-C panic` strategy). + default_uwtable: true, position_independent_executables: true, static_position_independent_executables: true, relro_level: RelroLevel::Full,