diff options
| author | Hal Finkel <hfinkel@anl.gov> | 2012-09-18 22:25:07 +0000 |
|---|---|---|
| committer | Hal Finkel <hfinkel@anl.gov> | 2012-09-18 22:25:07 +0000 |
| commit | f358791e270797cae3284955012223c8d767022b (patch) | |
| tree | 12f15f567af2a1593ed8f6ef0ce375d57c0ef82a /clang/lib/Driver | |
| parent | f6d6cb0218b3d76c779260f23ade744edccb0c79 (diff) | |
| download | bcm5719-llvm-f358791e270797cae3284955012223c8d767022b.tar.gz bcm5719-llvm-f358791e270797cae3284955012223c8d767022b.zip | |
Add C/C++ header locations for the Freescale SDK.
The Freescale SDK is based on OpenEmbedded, and this might be useful
for other OpenEmbedded-based configurations as well.
With minor modifications, patch by Tobias von Koch!
llvm-svn: 164177
Diffstat (limited to 'clang/lib/Driver')
| -rw-r--r-- | clang/lib/Driver/ToolChains.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/clang/lib/Driver/ToolChains.cpp b/clang/lib/Driver/ToolChains.cpp index 0fd52028403..2517b3093f8 100644 --- a/clang/lib/Driver/ToolChains.cpp +++ b/clang/lib/Driver/ToolChains.cpp @@ -1291,6 +1291,10 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple( "/gcc/" + CandidateTriple.str(), "/" + CandidateTriple.str() + "/gcc/" + CandidateTriple.str(), + // The Freescale PPC SDK has the gcc libraries in + // <sysroot>/usr/lib/<triple>/x.y.z so have a look there as well. + "/" + CandidateTriple.str(), + // Ubuntu has a strange mis-matched pair of triples that this happens to // match. // FIXME: It may be worthwhile to generalize this and look for a second @@ -1300,6 +1304,7 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple( const std::string InstallSuffixes[] = { "/../../..", "/../../../..", + "/../..", "/../../../.." }; // Only look at the final, weird Ubuntu suffix for i386-linux-gnu. @@ -2374,6 +2379,9 @@ void Linux::AddClangCXXStdlibIncludeArgs(const ArgList &DriverArgs, InstallDir.str() + "/include/g++-v4", // Android standalone toolchain has C++ headers in yet another place. LibDir.str() + "/../" + TripleStr.str() + "/include/c++/" + Version.str(), + // Freescale SDK C++ headers are directly in <sysroot>/usr/include/c++, + // without a subdirectory corresponding to the gcc version. + LibDir.str() + "/../include/c++", }; for (unsigned i = 0; i < llvm::array_lengthof(IncludePathCandidates); ++i) { |

