too long lines were shrinked: 213 | _LIBCPP_NODISCARD_AFTER_CXX17 _LIBCPP_OVERRIDABLE_FUNC_VIS void* operator new(std::size_t __sz) _THROW_BAD_ALLOC; | ^~~~~~~~ [1094/1117] : && /usr/bin/x86_64-pc-linux-gnu-g++ -m32 -mfpmath=sse -fPIC -O2 -pipe -march=native -fno-diagnostics-color -fvisibility-inlines-hidden -Werror=date-time -fno-lifetime-dse -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -Wimplicit-fallthro FAILED: lib/libc++.so.1.0 : && /usr/bin/x86_64-pc-linux-gnu-g++ -m32 -mfpmath=sse -fPIC -O2 -pipe -march=native -fno-diagnostics-color -fvisibility-inlines-hidden -Werror=date-time -fno-lifetime-dse -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -Wimplicit-fallthrough -Wno-non /usr/lib/gcc/x86_64-pc-linux-gnu/14/../../../../x86_64-pc-linux-gnu/bin/ld: libcxx/src/CMakeFiles/cxx_shared.dir/filesystem/path.cpp.o: in function `std::__1::__fs::filesystem::path::begin() const [clone .cold]': path.cpp:(.text.unlikely+0x680): undefined reference to `__cxa_call_terminate' /usr/lib/gcc/x86_64-pc-linux-gnu/14/../../../../x86_64-pc-linux-gnu/bin/ld: libcxx/src/CMakeFiles/cxx_shared.dir/filesystem/path.cpp.o: in function `std::__1::__fs::filesystem::path::iterator::__increment() [clone .cold]': path.cpp:(.text.unlikely+0x6d7): undefined reference to `__cxa_call_terminate' ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 17.1_desktop_gnome_systemd-20231123-162118 ------------------------------------------------------------------- gcc-config -l: [1] x86_64-pc-linux-gnu-14 * clang/llvm (if any): clang version 17.0.5 Target: x86_64-pc-linux-gnu Thread model: posix InstalledDir: /usr/lib/llvm/17/bin Configuration file: /etc/clang/x86_64-pc-linux-gnu-clang.cfg /usr/lib/llvm/17 17.0.5 Python 3.11.6 Available Ruby profiles: [1] ruby31 (with Rubygems) * Available Rust versions: [1] rust-bin-1.73.0 * The following VMs are available for generation-2: *) Eclipse Temurin JDK 21.0.1_p12 [openjdk-bin-21] Available Java Virtual Machines: [1] openjdk-bin-21 system-vm The Glorious Glasgow Haskell Compilation System, version 9.2.8 php cli (if any): [1] php8.2 * go version go1.21.4 linux/amd64 HEAD of ::gentoo commit d5434e6e3690f912587c8d17c7668b8c47624332 Author: Repository mirror & CI <repomirrorci@gentoo.org> Date: Sat Nov 25 21:02:03 2023 +0000 2023-11-25 21:02:02 UTC emerge -qpvO sys-libs/libcxx [ebuild N ] sys-libs/libcxx-17.0.5 USE="(libcxxabi) static-libs -clang -test -verify-sig" ABI_X86="32 (64) (-x32)"
Created attachment 875674 [details] emerge-info.txt
Created attachment 875675 [details] emerge-history.txt
Created attachment 875676 [details] environment
Created attachment 875677 [details] etc.clang.tar.xz
Created attachment 875678 [details] etc.portage.tar.xz
Created attachment 875679 [details] qlist-info.txt
Created attachment 875680 [details] sys-libs:libcxx-17.0.5:20231125-221814.log.xz
Created attachment 875681 [details] temp.tar.xz
I get the same error emerging sys-devel/clang-18.1.8. My system is Asus TinkerBoard S (arm cortex A17). My llvm was built with cross-emerge on a x86, because the board doesn't have enough memory to build llvm even with -j1. [811/1286] : && /usr/lib/ccache/bin/armv7a-unknown-linux-musleabihf-g++ -O2 -pipe -fomit-frame-pointer -march=armv7ve+neon-vfpv3 -mcpu=cortex-a17 -mfpu=neon-vfpv3 -mfloat-abi=hard -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -fno-lifetime-dse -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -Wimplicit-fallthrough -Wno-nonnull -Wno-class-memaccess -Wno-redundant-move -Wno-pessimizing-move -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wsuggest-override -Wno-comment -Wno-misleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -fno-common -Woverloaded-virtual -fno-strict-aliasing -pedantic -Wno-long-long -Wl,-O1 -Wl,--as-needed -Wl,-rpath-link,/var/tmp2/portage/portage/sys-devel/clang-18.1.8/work/x/y/clang-.arm/./lib -Wl,--gc-sections lib/Tooling/DumpTool/CMakeFiles/clang-ast-dump.dir/ASTSrcLocProcessor.cpp.o lib/Tooling/DumpTool/CMakeFiles/clang-ast-dump.dir/ClangSrcLocDump.cpp.o -o bin/clang-ast-dump -L/usr/lib/llvm/18/lib -Wl,-rpath,"\$ORIGIN/../lib:/usr/lib/llvm/18/lib" lib/libclangAST.a lib/libclangASTMatchers.a lib/libclangBasic.a lib/libclangDriver.a lib/libclangFrontend.a lib/libclangSerialization.a lib/libclangToolingCore.a lib/libclangDriver.a lib/libclangParse.a lib/libclangSema.a lib/libclangAPINotes.a lib/libclangEdit.a lib/libclangAnalysis.a lib/libclangASTMatchers.a lib/libclangAST.a lib/libclangSupport.a lib/libclangRewrite.a lib/libclangLex.a lib/libclangBasic.a /usr/lib/llvm/18/lib/libLLVM.so.18.1 && : FAILED: bin/clang-ast-dump : && /usr/lib/ccache/bin/armv7a-unknown-linux-musleabihf-g++ -O2 -pipe -fomit-frame-pointer -march=armv7ve+neon-vfpv3 -mcpu=cortex-a17 -mfpu=neon-vfpv3 -mfloat-abi=hard -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -fno-lifetime-dse -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -Wimplicit-fallthrough -Wno-nonnull -Wno-class-memaccess -Wno-redundant-move -Wno-pessimizing-move -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wsuggest-override -Wno-comment -Wno-misleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -fno-common -Woverloaded-virtual -fno-strict-aliasing -pedantic -Wno-long-long -Wl,-O1 -Wl,--as-needed -Wl,-rpath-link,/var/tmp2/portage/portage/sys-devel/clang-18.1.8/work/x/y/clang-.arm/./lib -Wl,--gc-sections lib/Tooling/DumpTool/CMakeFiles/clang-ast-dump.dir/ASTSrcLocProcessor.cpp.o lib/Tooling/DumpTool/CMakeFiles/clang-ast-dump.dir/ClangSrcLocDump.cpp.o -o bin/clang-ast-dump -L/usr/lib/llvm/18/lib -Wl,-rpath,"\$ORIGIN/../lib:/usr/lib/llvm/18/lib" lib/libclangAST.a lib/libclangASTMatchers.a lib/libclangBasic.a lib/libclangDriver.a lib/libclangFrontend.a lib/libclangSerialization.a lib/libclangToolingCore.a lib/libclangDriver.a lib/libclangParse.a lib/libclangSema.a lib/libclangAPINotes.a lib/libclangEdit.a lib/libclangAnalysis.a lib/libclangASTMatchers.a lib/libclangAST.a lib/libclangSupport.a lib/libclangRewrite.a lib/libclangLex.a lib/libclangBasic.a /usr/lib/llvm/18/lib/libLLVM.so.18.1 && : /usr/lib/gcc/armv7a-unknown-linux-musleabihf/13/../../../../armv7a-unknown-linux-musleabihf/bin/ld: /usr/lib/llvm/18/lib/libLLVM.so.18.1: undefined reference to `__cxa_call_terminate@CXXABI_1.3.15'
Also happens for me with 18.1.8 on x64 machine.
I realized that this problem happens only package is compiled by GCC. Adding back recommended USE="+clang" (which instead compiles it by CLANG) make it working fine.