[PATCH] D18360: Add AIX Target/ToolChain to Clang Driver

David Majnemer via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 18 14:59:22 PDT 2016


majnemer added a comment.

Could you please attach a diff with additional context?


================
Comment at: lib/Driver/ToolChains.cpp:3717-3735
@@ -3678,1 +3716,21 @@
 
+  // We need a detected GCC installation on Linux to provide libstdc++'s
+  // headers. We handled the libc++ case above.
+  if (!GCCInstallation.isValid())
+    return;
+
+  // By default, look for the C++ headers in an include directory adjacent to
+  // the lib directory of the GCC installation. Note that this is expect to be
+  // equivalent to '/usr/include/c++/X.Y' in almost all cases.
+  StringRef LibDir = GCCInstallation.getParentLibPath();
+  StringRef TripleStr = GCCInstallation.getTriple().str();
+  const Multilib &Multilib = GCCInstallation.getMultilib();
+  const GCCVersion &Version = GCCInstallation.getVersion();
+
+  // The primary search for libstdc++ supports multiarch variants.
+  addLibStdCXXIncludePaths(LibDir.str() + "/../include",
+                           "/c++/" + Version.Text, TripleStr,
+                           /*GCCMultiarchTriple*/ "",
+                           /*TargetMultiarchTriple*/ "",
+                           Multilib.includeSuffix(), DriverArgs, CC1Args);
+}
----------------
If I am not mistaken, this change seem unrelated.


https://reviews.llvm.org/D18360





More information about the cfe-commits mailing list