[clang] 79c8903 - [Clang] Add ENABLE_LINKER_BUILD_ID to Hurd driver.

via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 6 22:10:53 PST 2019


Author: kristina
Date: 2019-11-07T06:10:14Z
New Revision: 79c89033fdf1bfb840744a35d32e7583580b6572

URL: https://github.com/llvm/llvm-project/commit/79c89033fdf1bfb840744a35d32e7583580b6572
DIFF: https://github.com/llvm/llvm-project/commit/79c89033fdf1bfb840744a35d32e7583580b6572.diff

LOG: [Clang] Add ENABLE_LINKER_BUILD_ID to Hurd driver.

This was added for Linux toolchains in rC271692, this
patch extends this to the Hurd toolchain.

Patch by sthibaul (Samuel Thibault)

Differential Revision: https://reviews.llvm.org/D69754

Added: 
    

Modified: 
    clang/lib/Driver/ToolChains/Hurd.cpp

Removed: 
    


################################################################################
diff  --git a/clang/lib/Driver/ToolChains/Hurd.cpp b/clang/lib/Driver/ToolChains/Hurd.cpp
index 92b0a7f2483f..c7b278cff9f0 100644
--- a/clang/lib/Driver/ToolChains/Hurd.cpp
+++ b/clang/lib/Driver/ToolChains/Hurd.cpp
@@ -70,6 +70,10 @@ Hurd::Hurd(const Driver &D, const llvm::Triple &Triple,
   const std::string OSLibDir = getOSLibDir(Triple, Args);
   const std::string MultiarchTriple = getMultiarchTriple(D, Triple, SysRoot);
 
+#ifdef ENABLE_LINKER_BUILD_ID
+  ExtraOpts.push_back("--build-id");
+#endif
+
   // If we are currently running Clang inside of the requested system root, add
   // its parent library paths to those searched.
   // FIXME: It's not clear whether we should use the driver's installed


        


More information about the cfe-commits mailing list