Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(231)

Side by Side Diff: tools/clang/scripts/update.py

Issue 1777793003: Revert of clang upload.sh: don't download Clang binaries from clang_upload bots. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 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 is used to download prebuilt clang binaries. 6 """This script is used to download prebuilt clang binaries.
7 7
8 It is also used by package.py to build the prebuilt clang binaries.""" 8 It is also used by package.py to build the prebuilt clang binaries."""
9 9
10 import argparse 10 import argparse
(...skipping 704 matching lines...) Expand 10 before | Expand all | Expand 10 after
715 help='select which chrome tools to build', 715 help='select which chrome tools to build',
716 default=['plugins', 'blink_gc_plugin']) 716 default=['plugins', 'blink_gc_plugin'])
717 parser.add_argument('--without-android', action='store_false', 717 parser.add_argument('--without-android', action='store_false',
718 help='don\'t build Android ASan runtime (linux only)', 718 help='don\'t build Android ASan runtime (linux only)',
719 dest='with_android', 719 dest='with_android',
720 default=sys.platform.startswith('linux')) 720 default=sys.platform.startswith('linux'))
721 args = parser.parse_args() 721 args = parser.parse_args()
722 722
723 if args.if_needed: 723 if args.if_needed:
724 is_clang_required = False 724 is_clang_required = False
725 # We don't need to download the toolchain on upload bots during runhooks.
726 if 'LLVM_FORCE_LOCAL_BUILD' in os.environ:
727 print ('Skipping downloading Clang toolchain binaries as '
728 'LLVM_FORCE_LOCAL_BUILD is found in the environment')
729 return 0
730 # clang is always used on Mac and Linux. 725 # clang is always used on Mac and Linux.
731 if sys.platform == 'darwin' or sys.platform.startswith('linux'): 726 if sys.platform == 'darwin' or sys.platform.startswith('linux'):
732 is_clang_required = True 727 is_clang_required = True
733 # clang requested via $GYP_DEFINES. 728 # clang requested via $GYP_DEFINES.
734 if re.search(r'\b(clang|asan|lsan|msan|tsan)=1', 729 if re.search(r'\b(clang|asan|lsan|msan|tsan)=1',
735 os.environ.get('GYP_DEFINES', '')): 730 os.environ.get('GYP_DEFINES', '')):
736 is_clang_required = True 731 is_clang_required = True
737 # clang previously downloaded, keep it up-to-date. 732 # clang previously downloaded, keep it up-to-date.
738 # If you don't want this, delete third_party/llvm-build on your machine. 733 # If you don't want this, delete third_party/llvm-build on your machine.
739 if os.path.isdir(LLVM_BUILD_DIR): 734 if os.path.isdir(LLVM_BUILD_DIR):
(...skipping 30 matching lines...) Expand all
770 args.force_local_build = True 765 args.force_local_build = True
771 if 'OS=android' not in os.environ.get('GYP_DEFINES', ''): 766 if 'OS=android' not in os.environ.get('GYP_DEFINES', ''):
772 # Only build the Android ASan rt on ToT bots when targetting Android. 767 # Only build the Android ASan rt on ToT bots when targetting Android.
773 args.with_android = False 768 args.with_android = False
774 769
775 return UpdateClang(args) 770 return UpdateClang(args)
776 771
777 772
778 if __name__ == '__main__': 773 if __name__ == '__main__':
779 sys.exit(main()) 774 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698