mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-01 02:36:02 +00:00
Rust fixes for v6.12 (3nd)
Toolchain and infrastructure: - Avoid build errors with old 'rustc's without LLVM patch version (important since it impacts people that do not even enable Rust). - Update LLVM version for 'HAVE_CFI_ICALL_NORMALIZE_INTEGERS' in 'depends on' condition (the fix was eventually backported rather than land in LLVM 19). -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEPjU5OPd5QIZ9jqqOGXyLc2htIW0FAmclMkUACgkQGXyLc2ht IW1bEBAAhra1dISkhwf5ZBwp3v8mK3k8sx3tacg1ps3suzPjBBFxiqisZ6ikePHr f8fRuXT7/hks01pZug7o3NSx0EwQ4ipoBywJpc3EIsyVHQJvXeZeiuBJM3aEFNYQ QgPN9cgZooyQS7+qej0F1lGBbQ7xHEV4GzHmlMq76KpCMXAvmyxuX7W4knyuGa9v YonVIdcWy1XrDyq9+XmVHQ8DhtwBJeIE1sjbMB5xSWHSk7MppX6sYAgBljDqpTtM IVNfyHfi2sizbEgYK9kmUZKWycobNEu8zSoH+MRQ8CGtJ0+wuKG5GKYAflgSFiOx fKbL8bmymFWm7l8c4m3VydAgp9TcZs1CNekcMAUABTdOi0Dux+MuTOYwurNWyqNH 3rXMCew/UeYuqkqdDzH/gMdMPGLpDvi6jv5HQhMx/VW021tPoFEiln2b8N+FO0xs p2WHixYwwTEJwqMzBsP6B4TaoOLbjHtHFhd7cANohaHllgolKLlACGNrfB3G0xxw kX4J71D8ki/MPcyoXydQVlQ14fZcI2ET1dY4tATVoEYKhLT2MXbMsSfsRLOkM7h3 vqvT7JgprSQb+1Eu/g0K920HcBPlq3Crmr8ZEI5u49e02CBUfuhcAQgaHW8jtqcp eqOclzzQ1hbg9SYjzIQf2ryBvNZAdKuUkPAwKRyZybbENcLxDPc= =v/R+ -----END PGP SIGNATURE----- Merge tag 'rust-fixes-6.12-3' of https://github.com/Rust-for-Linux/linux Pull rust fixes from Miguel Ojeda: "Toolchain and infrastructure: - Avoid build errors with old 'rustc's without LLVM patch version (important since it impacts people that do not even enable Rust) - Update LLVM version for 'HAVE_CFI_ICALL_NORMALIZE_INTEGERS' in 'depends on' condition (the fix was eventually backported rather than land in LLVM 19)" * tag 'rust-fixes-6.12-3' of https://github.com/Rust-for-Linux/linux: cfi: tweak llvm version for HAVE_CFI_ICALL_NORMALIZE_INTEGERS kbuild: rust: avoid errors with old `rustc`s without LLVM patch version
This commit is contained in:
commit
f7292c0934
@ -855,14 +855,14 @@ config HAVE_CFI_ICALL_NORMALIZE_INTEGERS_CLANG
|
||||
def_bool y
|
||||
depends on $(cc-option,-fsanitize=kcfi -fsanitize-cfi-icall-experimental-normalize-integers)
|
||||
# With GCOV/KASAN we need this fix: https://github.com/llvm/llvm-project/pull/104826
|
||||
depends on CLANG_VERSION >= 190000 || (!GCOV_KERNEL && !KASAN_GENERIC && !KASAN_SW_TAGS)
|
||||
depends on CLANG_VERSION >= 190103 || (!GCOV_KERNEL && !KASAN_GENERIC && !KASAN_SW_TAGS)
|
||||
|
||||
config HAVE_CFI_ICALL_NORMALIZE_INTEGERS_RUSTC
|
||||
def_bool y
|
||||
depends on HAVE_CFI_ICALL_NORMALIZE_INTEGERS_CLANG
|
||||
depends on RUSTC_VERSION >= 107900
|
||||
# With GCOV/KASAN we need this fix: https://github.com/rust-lang/rust/pull/129373
|
||||
depends on (RUSTC_LLVM_VERSION >= 190000 && RUSTC_VERSION >= 108200) || \
|
||||
depends on (RUSTC_LLVM_VERSION >= 190103 && RUSTC_VERSION >= 108200) || \
|
||||
(!GCOV_KERNEL && !KASAN_GENERIC && !KASAN_SW_TAGS)
|
||||
|
||||
config CFI_PERMISSIVE
|
||||
|
@ -13,7 +13,7 @@ get_canonical_version()
|
||||
echo $((10000 * $1 + 100 * $2 + $3))
|
||||
}
|
||||
|
||||
if output=$("$@" --version --verbose 2>/dev/null | grep LLVM); then
|
||||
if output=$("$@" --version --verbose 2>/dev/null | grep -E 'LLVM.*[0-9]+\.[0-9]+\.[0-9]+'); then
|
||||
set -- $output
|
||||
get_canonical_version $3
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user