diff options
author | Yunzhong Gao <Yunzhong_Gao@playstation.sony.com> | 2014-02-19 19:06:58 +0000 |
---|---|---|
committer | Yunzhong Gao <Yunzhong_Gao@playstation.sony.com> | 2014-02-19 19:06:58 +0000 |
commit | e3f902c32a5a92fee5b263b4f79e8ac93bfae0c8 (patch) | |
tree | 1b3fe532a7c70488133b37d5829a576503d8aa1a | |
parent | c30e7649424d7a497e1a8d05a2d2c3e5a07434db (diff) | |
download | bcm5719-llvm-e3f902c32a5a92fee5b263b4f79e8ac93bfae0c8.tar.gz bcm5719-llvm-e3f902c32a5a92fee5b263b4f79e8ac93bfae0c8.zip |
Only print the selected multilib when something is actually found on the host.
llvm-svn: 201709
-rw-r--r-- | clang/include/clang/Driver/Multilib.h | 4 | ||||
-rw-r--r-- | clang/lib/Driver/ToolChains.cpp | 8 |
2 files changed, 10 insertions, 2 deletions
diff --git a/clang/include/clang/Driver/Multilib.h b/clang/include/clang/Driver/Multilib.h index ad59d8a57fb..6c3738a9cc0 100644 --- a/clang/include/clang/Driver/Multilib.h +++ b/clang/include/clang/Driver/Multilib.h @@ -82,6 +82,10 @@ public: /// Check whether any of the 'against' flags contradict the 'for' flags. bool isValid() const; + /// Check whether the default is selected + bool isDefault() const + { return GCCSuffix.empty() && OSSuffix.empty() && IncludeSuffix.empty(); } + bool operator==(const Multilib &Other) const; }; diff --git a/clang/lib/Driver/ToolChains.cpp b/clang/lib/Driver/ToolChains.cpp index 8d17ab10f2e..bd557b749bc 100644 --- a/clang/lib/Driver/ToolChains.cpp +++ b/clang/lib/Driver/ToolChains.cpp @@ -1263,12 +1263,16 @@ void Generic_GCC::GCCInstallationDetector::print(raw_ostream &OS) const { I != E; ++I) OS << "Found candidate GCC installation: " << *I << "\n"; - OS << "Selected GCC installation: " << GCCInstallPath << "\n"; + if (!GCCInstallPath.empty()) + OS << "Selected GCC installation: " << GCCInstallPath << "\n"; + for (MultilibSet::const_iterator I = Multilibs.begin(), E = Multilibs.end(); I != E; ++I) { OS << "Candidate multiilb: " << *I << "\n"; } - OS << "Selected multilib: " << SelectedMultilib << "\n"; + + if (Multilibs.size() != 0 || !SelectedMultilib.isDefault()) + OS << "Selected multilib: " << SelectedMultilib << "\n"; } bool Generic_GCC::GCCInstallationDetector::getBiarchSibling(Multilib &M) const { |