mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-11 12:16:07 +00:00
Implement --build-id=none.
Both bfd and gold have this. It allows disabling build-id when it is the default with by adding -Wl,--build-id=none no the clang command line. llvm-svn: 268435
This commit is contained in:
parent
1e4ba37df1
commit
c5b8ed241d
@ -381,11 +381,13 @@ void LinkerDriver::readConfigs(opt::InputArgList &Args) {
|
||||
Config->BuildId = BuildIdKind::Fnv1;
|
||||
if (auto *Arg = Args.getLastArg(OPT_build_id_eq)) {
|
||||
StringRef S = Arg->getValue();
|
||||
if (S == "md5") {
|
||||
if (S == "md5")
|
||||
Config->BuildId = BuildIdKind::Md5;
|
||||
} else if (S == "sha1") {
|
||||
else if (S == "sha1")
|
||||
Config->BuildId = BuildIdKind::Sha1;
|
||||
} else
|
||||
else if (S == "none")
|
||||
Config->BuildId = BuildIdKind::None;
|
||||
else
|
||||
error("unknown --build-id style: " + S);
|
||||
}
|
||||
|
||||
|
@ -9,6 +9,8 @@
|
||||
# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=SHA1 %s
|
||||
# RUN: ld.lld %t -o %t2
|
||||
# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=NONE %s
|
||||
# RUN: ld.lld --build-id=md5 --build-id=none %t -o %t2
|
||||
# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=NONE %s
|
||||
|
||||
.globl _start
|
||||
_start:
|
||||
|
Loading…
x
Reference in New Issue
Block a user