[PATCH] D70306: clang: Exherbo multiarch ajustments

Saleem Abdulrasool via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 18 14:28:23 PST 2019


compnerd requested changes to this revision.
compnerd added a comment.
This revision now requires changes to proceed.

The test adjustments are incorrect.  They should optionally accept the triple in the path.



================
Comment at: clang/lib/Driver/ToolChains/Linux.cpp:360
+      addPathIfExists(D,
+                      LibPath + "/../../" + GCCTriple.str() + "/lib/../" +
+                          OSLibDir + SelectedMultilib.osSuffix(),
----------------
Could you use `llvm::sys::path::stem` please?


================
Comment at: clang/lib/Driver/ToolChains/Linux.cpp:889
+      break;
+    }
+  }
----------------
Why not just always construct the path?  `"/usr/" + getTriple.str() + "/include"` is always going to be the path that we have for exherbo


================
Comment at: clang/lib/Driver/ToolChains/Linux.cpp:984
+  if (Distro == Distro::Exherbo &&
+      addLibStdCXXIncludePaths(
+          LibDir.str() + "/../../" + TripleStr + "/include",
----------------
Why is this part of the `if`?  This should be part of the code executed conditionally.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D70306/new/

https://reviews.llvm.org/D70306





More information about the cfe-commits mailing list