mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-23 04:41:11 +00:00
Bug 1834964 - Use the same logic for {llvm-,$toolchain-prefix-,}strip as for many other tools. r=firefox-build-system-reviewers,sergesanspaille
Whatever was making things fail with llvm-strip back when using llvm-strip was made a possibility, doesn't seem to happen anymore, even with the clang version we were using back then (clang 13). Differential Revision: https://phabricator.services.mozilla.com/D179040
This commit is contained in:
parent
cf6909d677
commit
023322c911
@ -867,19 +867,6 @@ def strip_flags(flags, profiling, target):
|
||||
set_config("STRIP_FLAGS", strip_flags)
|
||||
|
||||
|
||||
@depends(llvm_tool("llvm-strip"), toolchain_prefix, target)
|
||||
def strip(llvm_strip, toolchain_prefix, target):
|
||||
commands = ["strip"]
|
||||
for prefix in toolchain_prefix or ():
|
||||
commands.insert(0, "%sstrip" % prefix)
|
||||
# llvm-strip causes some problems on macos targets.
|
||||
if target.kernel == "Darwin":
|
||||
commands.append(llvm_strip[0])
|
||||
else:
|
||||
commands.insert(0, llvm_strip[0])
|
||||
return tuple(commands)
|
||||
|
||||
|
||||
def validate_strip(path):
|
||||
if "llvm-strip" not in path:
|
||||
return True
|
||||
@ -895,7 +882,7 @@ def strip_when(compile_env, target, host):
|
||||
|
||||
check_prog(
|
||||
"STRIP",
|
||||
strip,
|
||||
plain_llvm_or_prefixed("strip"),
|
||||
when=strip_when,
|
||||
paths=clang_search_path,
|
||||
validate=validate_strip,
|
||||
|
Loading…
Reference in New Issue
Block a user