forked from OSchip/llvm-project
[Driver] Fix -gz=zlib options for linker also on FreeBSD
ccb4124a41
fixed translating -gz=zlib to --compress-debug-sections for
linker invocation for several ToolChains, but omitted FreeBSD.
Differential Revision: https://reviews.llvm.org/D97752
This commit is contained in:
parent
c0d4b44e6a
commit
462cf39a5c
|
@ -290,6 +290,7 @@ void freebsd::Linker::ConstructJob(Compilation &C, const JobAction &JA,
|
|||
|
||||
bool NeedsSanitizerDeps = addSanitizerRuntimes(ToolChain, Args, CmdArgs);
|
||||
bool NeedsXRayDeps = addXRayRuntime(ToolChain, Args, CmdArgs);
|
||||
addLinkerCompressDebugSectionsOption(ToolChain, Args, CmdArgs);
|
||||
AddLinkerInputs(ToolChain, Inputs, Args, CmdArgs, JA);
|
||||
|
||||
if (!Args.hasArg(options::OPT_nostdlib, options::OPT_nodefaultlibs)) {
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
|
||||
// RUN: %clang -### -target x86_64-unknown-linux-gnu -gz=zlib -x assembler %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_ZLIB %s
|
||||
// RUN: %clang -### -target x86_64-unknown-linux-gnu -gz=zlib %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_ZLIB %s
|
||||
// RUN: %clang -### -target x86_64-unknown-freebsd -gz=zlib %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_ZLIB %s
|
||||
// CHECK-OPT_GZ_EQ_ZLIB: {{.* "-cc1(as)?".* "--compress-debug-sections=zlib"}}
|
||||
// CHECK-OPT_GZ_EQ_ZLIB: "--compress-debug-sections=zlib"
|
||||
|
||||
|
|
Loading…
Reference in New Issue