From: LLVM Packaging Team Date: Mon, 23 Sep 2024 11:23:31 +0000 (+0200) Subject: D148945-revert X-Git-Tag: archive/raspbian/1%18.1.8-12+rpi1~13 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=258862096d027195b1e8f06166fd56c6ae1de399;p=llvm-toolchain-18.git D148945-revert Restore that for now, we're not GenToo ... https://reviews.llvm.org/D148945 https://reviews.llvm.org/D122444 Gbp-Pq: Name D148945-revert.diff --- diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp index aaba988ed1..15c6cf2be1 100644 --- a/clang/lib/Driver/ToolChains/Linux.cpp +++ b/clang/lib/Driver/ToolChains/Linux.cpp @@ -337,6 +337,13 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args) Generic_GCC::AddMultiarchPaths(D, SysRoot, OSLibDir, Paths); + // The deprecated -DLLVM_ENABLE_PROJECTS=libcxx configuration installs + // libc++.so in D.Dir+"/../lib/". Detect this path. + // TODO Remove once LLVM_ENABLE_PROJECTS=libcxx is unsupported. + if (StringRef(D.Dir).startswith(SysRoot) && + D.getVFS().exists(D.Dir + "/../lib/libc++.so")) + addPathIfExists(D, D.Dir + "/../lib", Paths); + addPathIfExists(D, concat(SysRoot, "/lib"), Paths); addPathIfExists(D, concat(SysRoot, "/usr/lib"), Paths); }