Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

kbuild: rust: use `-Zdwarf-version` to support DWARFv5

Rust 1.64.0 introduced (unstable) support for the `-Zdwarf-version`
flag, which allows to select DWARFv5, thus use it.

Link: https://github.com/rust-lang/rust/issues/103057
Link: https://github.com/rust-lang/rust/pull/98350
Reviewed-by: Alice Ryhl <aliceryhl@google.com>
Link: https://lore.kernel.org/r/20240217002602.57270-1-ojeda@kernel.org
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>

+6
+6
scripts/Makefile.debug
··· 17 17 DEBUG_CFLAGS += $(debug-flags-y) 18 18 KBUILD_AFLAGS += $(debug-flags-y) 19 19 20 + ifdef CONFIG_DEBUG_INFO_DWARF4 21 + DEBUG_RUSTFLAGS += -Zdwarf-version=4 22 + else ifdef CONFIG_DEBUG_INFO_DWARF5 23 + DEBUG_RUSTFLAGS += -Zdwarf-version=5 24 + endif 25 + 20 26 ifdef CONFIG_DEBUG_INFO_REDUCED 21 27 DEBUG_CFLAGS += -fno-var-tracking 22 28 DEBUG_RUSTFLAGS += -Cdebuginfo=1