summaryrefslogtreecommitdiffstats
path: root/clang/lib/Driver/ToolChains/Gnu.cpp
diff options
context:
space:
mode:
authorMandeep Singh Grang <mgrang@codeaurora.org>2018-07-30 19:44:13 +0000
committerMandeep Singh Grang <mgrang@codeaurora.org>2018-07-30 19:44:13 +0000
commite9ddc44a604318739a27249d267aa7267d13d93b (patch)
tree2b9f67751a0a2e420fcbb56b1135577e54a57fd3 /clang/lib/Driver/ToolChains/Gnu.cpp
parentf78650a8deca216b858827ff430972c114a60a7a (diff)
downloadbcm5719-llvm-e9ddc44a604318739a27249d267aa7267d13d93b.tar.gz
bcm5719-llvm-e9ddc44a604318739a27249d267aa7267d13d93b.zip
[OpenEmbedded] Fix lib paths for OpenEmbedded targets
Summary: The lib paths are not correctly picked up for OpenEmbedded sysroots (like arm-oe-linux-gnueabi) for 2 reasons: 1. OpenEmbedded sysroots are of the form <sysroot>/usr/lib/<triple>/x.y.z. This form is handled in clang but only for Freescale vendor. 2. 64-bit OpenEmbedded sysroots may not have a /usr/lib dir. So they cannot find /usr/lib64 as it is referenced as /usr/lib/../lib64 in clang. This is a follow-up to the llvm patch: D48861 Reviewers: dlj, rengolin, fedor.sergeev, javed.absar, hfinkel, rsmith Reviewed By: rsmith Subscribers: rsmith, kristof.beyls, cfe-commits Differential Revision: https://reviews.llvm.org/D48862 llvm-svn: 338294
Diffstat (limited to 'clang/lib/Driver/ToolChains/Gnu.cpp')
-rw-r--r--clang/lib/Driver/ToolChains/Gnu.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
index 2c83598f3d7..ad702b6d06a 100644
--- a/clang/lib/Driver/ToolChains/Gnu.cpp
+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
@@ -2188,7 +2188,8 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
// this on Freescale triples, though, since some systems put a *lot* of
// files in that location, not just GCC installation data.
{CandidateTriple.str(), "..",
- TargetTriple.getVendor() == llvm::Triple::Freescale},
+ TargetTriple.getVendor() == llvm::Triple::Freescale ||
+ TargetTriple.getVendor() == llvm::Triple::OpenEmbedded},
// Natively multiarch systems sometimes put the GCC triple-specific
// directory within their multiarch lib directory, resulting in the
OpenPOWER on IntegriCloud