r361504 - [Driver] Try normalized triple when looking for C++ libraries
Petr Hosek via cfe-commits
cfe-commits at lists.llvm.org
Thu May 23 08:23:16 PDT 2019
Author: phosek
Date: Thu May 23 08:23:16 2019
New Revision: 361504
URL: http://llvm.org/viewvc/llvm-project?rev=361504&view=rev
Log:
[Driver] Try normalized triple when looking for C++ libraries
This addresses the issue introduced in r361432 where we would only
try effective triple but not the normalized one as we do for other
runtimes.
Differential Revision: https://reviews.llvm.org/D62286
Modified:
cfe/trunk/lib/Driver/ToolChain.cpp
Modified: cfe/trunk/lib/Driver/ToolChain.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChain.cpp?rev=361504&r1=361503&r2=361504&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChain.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChain.cpp Thu May 23 08:23:16 2019
@@ -80,6 +80,11 @@ ToolChain::ToolChain(const Driver &D, co
llvm::sys::path::append(P, "..", "lib", D.getTargetTriple(), "c++");
if (getVFS().exists(P))
getLibraryPaths().push_back(P.str());
+
+ P.assign(D.Dir);
+ llvm::sys::path::append(P, "..", "lib", Triple.str(), "c++");
+ if (getVFS().exists(P))
+ getLibraryPaths().push_back(P.str());
}
P.assign(D.ResourceDir);
More information about the cfe-commits
mailing list