Created attachment 921080 [details] build.log The same thing happens with gcc-15 in bug #945920, so I'm guessing sanitizer_common is shared code. /usr/lib/llvm/20/bin/riscv64-unknown-linux-musl-clang++ -DHAVE_RPC_XDR_H=0 -I/var/lib/portage/tmp/portage/llvm-runtimes/compiler-rt-sanitizers-20.1.0/work/compiler-rt/lib/sanitizer_common/.. -DNDEBUG -O3 -pipe -mabi=lp64d -march=rv64gc -Werror=odr -Werror=strict-aliasing -flto -Wall -Wno-unused-parameter -std=c++17 -fPIC -fno-builtin -fno-exceptions -fomit-frame-pointer -funwind-tables -fno-stack-protector -fno-sanitize=safe-stack -fvisibility=hidden -fno-lto -Wthread-safety -Wthread-safety-reference -Wthread-safety-beta -O3 -gline-tables-only -Wno-gnu -Wno-variadic-macros -Wno-c99-extensions -ftrivial-auto-var-init=pattern -nostdinc++ -Wno-format -fno-rtti -Wframe-larger-than=570 -Wglobal-constructors -MD -MT lib/sanitizer_common/CMakeFiles/RTSanitizerCommonLibc.riscv64.dir/sanitizer_linux_libcdep.cpp.o -MF lib/sanitizer_common/CMakeFiles/RTSanitizerCommonLibc.riscv64.dir/sanitizer_linux_libcdep.cpp.o.d -o lib/sanitizer_common/CMakeFiles/RTSanitizerCommonLibc.riscv64.dir/sanitizer_linux_libcdep.cpp.o -c /var/lib/portage/tmp/portage/llvm-runtimes/compiler-rt-sanitizers-20.1.0/work/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp /var/lib/portage/tmp/portage/llvm-runtimes/compiler-rt-sanitizers-20.1.0/work/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp:627:29: error: use of undeclared identifier 'TlsPreTcbSize' 627 | const uptr pre_tcb_size = TlsPreTcbSize(); | ^ 1 error generated.
Fixed by https://github.com/llvm/llvm-project/pull/120036