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 192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
203 if sys.platform == 'win32': | 203 if sys.platform == 'win32': |
204 want.append('bin/clang-cl.exe') | 204 want.append('bin/clang-cl.exe') |
205 want.append('bin/lld-link.exe') | 205 want.append('bin/lld-link.exe') |
206 else: | 206 else: |
207 so_ext = 'dylib' if sys.platform == 'darwin' else 'so' | 207 so_ext = 'dylib' if sys.platform == 'darwin' else 'so' |
208 want.extend(['bin/clang', | 208 want.extend(['bin/clang', |
209 'lib/libFindBadConstructs.' + so_ext, | 209 'lib/libFindBadConstructs.' + so_ext, |
210 'lib/libBlinkGCPlugin.' + so_ext, | 210 'lib/libBlinkGCPlugin.' + so_ext, |
211 ]) | 211 ]) |
212 if sys.platform == 'darwin': | 212 if sys.platform == 'darwin': |
213 want.extend([# Copy only the OSX (ASan and profile) and iossim (ASan) | 213 want.extend([# Copy only the OSX and iossim (ASan and profile) runtime |
214 # runtime libraries: | 214 # libraries: |
215 'lib/clang/*/lib/darwin/*asan_osx*', | 215 'lib/clang/*/lib/darwin/*asan_osx*', |
216 'lib/clang/*/lib/darwin/*asan_iossim*', | 216 'lib/clang/*/lib/darwin/*asan_iossim*', |
217 'lib/clang/*/lib/darwin/*profile_osx*', | 217 'lib/clang/*/lib/darwin/*profile_osx*', |
| 218 'lib/clang/*/lib/darwin/*profile_iossim*', |
218 ]) | 219 ]) |
219 elif sys.platform.startswith('linux'): | 220 elif sys.platform.startswith('linux'): |
220 # Copy the libstdc++.so.6 we linked Clang against so it can run. | 221 # Copy the libstdc++.so.6 we linked Clang against so it can run. |
221 want.append('lib/libstdc++.so.6') | 222 want.append('lib/libstdc++.so.6') |
222 # Copy only | 223 # Copy only |
223 # lib/clang/*/lib/linux/libclang_rt.{[atm]san,san,ubsan,profile}-*.a , | 224 # lib/clang/*/lib/linux/libclang_rt.{[atm]san,san,ubsan,profile}-*.a , |
224 # but not dfsan. | 225 # but not dfsan. |
225 want.extend(['lib/clang/*/lib/linux/*[atm]san*', | 226 want.extend(['lib/clang/*/lib/linux/*[atm]san*', |
226 'lib/clang/*/lib/linux/*ubsan*', | 227 'lib/clang/*/lib/linux/*ubsan*', |
227 'lib/clang/*/lib/linux/*libclang_rt.san*', | 228 'lib/clang/*/lib/linux/*libclang_rt.san*', |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
286 with tarfile.open(golddir + '.tgz', 'w:gz') as tar: | 287 with tarfile.open(golddir + '.tgz', 'w:gz') as tar: |
287 tar.add(os.path.join(golddir, 'lib'), arcname='lib', | 288 tar.add(os.path.join(golddir, 'lib'), arcname='lib', |
288 filter=PrintTarProgress) | 289 filter=PrintTarProgress) |
289 MaybeUpload(args, golddir, platform) | 290 MaybeUpload(args, golddir, platform) |
290 | 291 |
291 # FIXME: Warn if the file already exists on the server. | 292 # FIXME: Warn if the file already exists on the server. |
292 | 293 |
293 | 294 |
294 if __name__ == '__main__': | 295 if __name__ == '__main__': |
295 sys.exit(main()) | 296 sys.exit(main()) |
OLD | NEW |