OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2015 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2015 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 """This script will check out llvm and clang, and then package the results up | 6 """This script will check out llvm and clang, and then package the results up |
7 to a tgz file.""" | 7 to a tgz file.""" |
8 | 8 |
9 import argparse | 9 import argparse |
10 import fnmatch | 10 import fnmatch |
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
204 if sys.platform == 'win32': | 204 if sys.platform == 'win32': |
205 want.append('bin/clang-cl.exe') | 205 want.append('bin/clang-cl.exe') |
206 want.append('bin/lld-link.exe') | 206 want.append('bin/lld-link.exe') |
207 else: | 207 else: |
208 so_ext = 'dylib' if sys.platform == 'darwin' else 'so' | 208 so_ext = 'dylib' if sys.platform == 'darwin' else 'so' |
209 want.extend(['bin/clang', | 209 want.extend(['bin/clang', |
210 'lib/libFindBadConstructs.' + so_ext, | 210 'lib/libFindBadConstructs.' + so_ext, |
211 'lib/libBlinkGCPlugin.' + so_ext, | 211 'lib/libBlinkGCPlugin.' + so_ext, |
212 ]) | 212 ]) |
213 if sys.platform == 'darwin': | 213 if sys.platform == 'darwin': |
214 want.extend([# Copy only the OSX (ASan and profile) and iossim (ASan) | 214 want.extend([# Copy only the OSX and iossim (ASan and profile) runtime |
215 # runtime libraries: | 215 # libraries: |
216 'lib/clang/*/lib/darwin/*asan_osx*', | 216 'lib/clang/*/lib/darwin/*asan_osx*', |
217 'lib/clang/*/lib/darwin/*asan_iossim*', | 217 'lib/clang/*/lib/darwin/*asan_iossim*', |
218 'lib/clang/*/lib/darwin/*profile_osx*', | 218 'lib/clang/*/lib/darwin/*profile_osx*', |
| 219 'lib/clang/*/lib/darwin/*profile_iossim*', |
219 ]) | 220 ]) |
220 elif sys.platform.startswith('linux'): | 221 elif sys.platform.startswith('linux'): |
221 # Copy the libstdc++.so.6 we linked Clang against so it can run. | 222 # Copy the libstdc++.so.6 we linked Clang against so it can run. |
222 want.append('lib/libstdc++.so.6') | 223 want.append('lib/libstdc++.so.6') |
223 # Copy only | 224 # Copy only |
224 # lib/clang/*/lib/linux/libclang_rt.{[atm]san,san,ubsan,profile}-*.a , | 225 # lib/clang/*/lib/linux/libclang_rt.{[atm]san,san,ubsan,profile}-*.a , |
225 # but not dfsan. | 226 # but not dfsan. |
226 want.extend(['lib/clang/*/lib/linux/*[atm]san*', | 227 want.extend(['lib/clang/*/lib/linux/*[atm]san*', |
227 'lib/clang/*/lib/linux/*ubsan*', | 228 'lib/clang/*/lib/linux/*ubsan*', |
228 'lib/clang/*/lib/linux/*libclang_rt.san*', | 229 'lib/clang/*/lib/linux/*libclang_rt.san*', |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 with tarfile.open(objdumpdir + '.tgz', 'w:gz') as tar: | 299 with tarfile.open(objdumpdir + '.tgz', 'w:gz') as tar: |
299 tar.add(os.path.join(objdumpdir, 'bin'), arcname='bin', | 300 tar.add(os.path.join(objdumpdir, 'bin'), arcname='bin', |
300 filter=PrintTarProgress) | 301 filter=PrintTarProgress) |
301 MaybeUpload(args, objdumpdir, platform) | 302 MaybeUpload(args, objdumpdir, platform) |
302 | 303 |
303 # FIXME: Warn if the file already exists on the server. | 304 # FIXME: Warn if the file already exists on the server. |
304 | 305 |
305 | 306 |
306 if __name__ == '__main__': | 307 if __name__ == '__main__': |
307 sys.exit(main()) | 308 sys.exit(main()) |
OLD | NEW |