diff options
author | Jonathan Reams <jbreams@mongodb.com> | 2016-07-11 09:56:33 -0400 |
---|---|---|
committer | Jonathan Reams <jbreams@mongodb.com> | 2016-07-12 10:19:27 -0400 |
commit | 51c85731b8ff1bfd356eadda6998523798fa7f6f (patch) | |
tree | aa095d9cbd8c68995f418ffaa18f898d23867bfb /SConstruct | |
parent | dd937158a397478de66b079f3c27be13b2165785 (diff) | |
download | mongo-51c85731b8ff1bfd356eadda6998523798fa7f6f.tar.gz |
SERVER-13956 Enable build-id on all clang/gcc versions that support it
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/SConstruct b/SConstruct index 9963c67b489..7e800f18d7e 100644 --- a/SConstruct +++ b/SConstruct @@ -2294,11 +2294,14 @@ def doConfigure(myenv): # myenv.Append( CCFLAGS=["/Zc:inline"]) - # This tells clang/gcc to use the gold linker if it is available - we prefer the gold linker - # because it is much faster. if myenv.ToolchainIs('gcc', 'clang'): + # This tells clang/gcc to use the gold linker if it is available - we prefer the gold linker + # because it is much faster. AddToLINKFLAGSIfSupported(myenv, '-fuse-ld=gold') + # Explicitly enable GNU build id's if the linker supports it. + AddToLINKFLAGSIfSupported(myenv, '-Wl,--build-id') + # Disallow an executable stack. Also, issue a warning if any files are found that would # cause the stack to become executable if the noexecstack flag was not in play, so that we # can find them and fix them. We do this here after we check for ld.gold because the |