Commit 91749258 authored by Peter Collingbourne's avatar Peter Collingbourne Committed by Commit Bot

Move code that strips binaries to package.py.

With this we should hopefully get more useful stack traces on ToT bots.

Bug: 
Change-Id: I6d9f36564d1f2edee3032b55a4f34429d302612d
Reviewed-on: https://chromium-review.googlesource.com/820620Reviewed-by: default avatarHans Wennborg <hans@chromium.org>
Commit-Queue: Peter Collingbourne <pcc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#523280}
parent 659c3676
......@@ -298,6 +298,17 @@ def main():
os.path.splitext(f)[1] in ['.so', '.a']):
subprocess.call([EU_STRIP, '-g', dest])
stripped_binaries = ['clang', 'llvm-symbolizer', 'sancov']
if sys.platform.startswith('linux'):
stripped_binaries.append('lld')
stripped_binaries.append('llvm-ar')
for f in stripped_binaries:
if sys.platform == 'darwin':
# See http://crbug.com/256342
subprocess.call(['strip', '-x', os.path.join(pdir, 'bin', f)])
elif sys.platform.startswith('linux'):
subprocess.call(['strip', os.path.join(pdir, 'bin', f)])
# Set up symlinks.
if sys.platform != 'win32':
os.symlink('clang', os.path.join(pdir, 'bin', 'clang++'))
......
......@@ -695,17 +695,6 @@ def UpdateClang(args):
# If any Chromium tools were built, install those now.
RunCommand(['ninja', 'cr-install'], msvc_arch='x64')
stripped_binaries = ['clang', 'llvm-symbolizer', 'sancov']
if sys.platform.startswith('linux'):
stripped_binaries.append('lld')
stripped_binaries.append('llvm-ar')
for f in stripped_binaries:
if sys.platform == 'darwin':
# See http://crbug.com/256342
RunCommand(['strip', '-x', os.path.join(LLVM_BUILD_DIR, 'bin', f)])
elif sys.platform.startswith('linux'):
RunCommand(['strip', os.path.join(LLVM_BUILD_DIR, 'bin', f)])
VeryifyVersionOfBuiltClangMatchesVERSION()
# Do an out-of-tree build of compiler-rt.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment