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

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

Issue 1128733002: Update from https://crrev.com/328418 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 7 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 | « tools/clang/plugins/tests/warn_only.txt ('k') | tools/clang/scripts/update.sh » ('j') | 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 """Windows can't run .sh files, so this is a Python implementation of 6 """Windows can't run .sh files, so this is a Python implementation of
7 update.sh. This script should replace update.sh on all platforms eventually.""" 7 update.sh. This script should replace update.sh on all platforms eventually."""
8 8
9 import argparse 9 import argparse
10 import os 10 import os
11 import re 11 import re
12 import shutil 12 import shutil
13 import subprocess 13 import subprocess
14 import stat 14 import stat
15 import sys 15 import sys
16 import time 16 import time
17 17
18 # Do NOT CHANGE this if you don't know what you're doing -- see 18 # Do NOT CHANGE this if you don't know what you're doing -- see
19 # https://code.google.com/p/chromium/wiki/UpdatingClang 19 # https://code.google.com/p/chromium/wiki/UpdatingClang
20 # Reverting problematic clang rolls is safe, though. 20 # Reverting problematic clang rolls is safe, though.
21 # Note: this revision is only used for Windows. Other platforms use update.sh. 21 # Note: this revision is only used for Windows. Other platforms use update.sh.
22 LLVM_WIN_REVISION = 'HEAD' 22 LLVM_WIN_REVISION = 'HEAD'
23 23
24 # ASan on Windows is useful enough to use it even while the clang/win is still 24 # ASan on Windows is useful enough to use it even while the clang/win is still
25 # in bringup. Use a pinned revision to make it slightly more stable. 25 # in bringup. Use a pinned revision to make it slightly more stable.
26 if (re.search(r'\b(asan)=1', os.environ.get('GYP_DEFINES', '')) and 26 if (re.search(r'\b(asan)=1', os.environ.get('GYP_DEFINES', '')) and
27 not 'LLVM_FORCE_HEAD_REVISION' in os.environ): 27 not 'LLVM_FORCE_HEAD_REVISION' in os.environ):
28 LLVM_WIN_REVISION = '235793' 28 LLVM_WIN_REVISION = '235968'
29 29
30 # Path constants. (All of these should be absolute paths.) 30 # Path constants. (All of these should be absolute paths.)
31 THIS_DIR = os.path.abspath(os.path.dirname(__file__)) 31 THIS_DIR = os.path.abspath(os.path.dirname(__file__))
32 CHROMIUM_DIR = os.path.abspath(os.path.join(THIS_DIR, '..', '..', '..')) 32 CHROMIUM_DIR = os.path.abspath(os.path.join(THIS_DIR, '..', '..', '..'))
33 LLVM_DIR = os.path.join(CHROMIUM_DIR, 'third_party', 'llvm') 33 LLVM_DIR = os.path.join(CHROMIUM_DIR, 'third_party', 'llvm')
34 CHROME_TOOLS_SHIM_DIR = os.path.join(LLVM_DIR, 'tools', 'chrometools') 34 CHROME_TOOLS_SHIM_DIR = os.path.join(LLVM_DIR, 'tools', 'chrometools')
35 LLVM_BUILD_DIR = os.path.join(CHROMIUM_DIR, 'third_party', 'llvm-build', 35 LLVM_BUILD_DIR = os.path.join(CHROMIUM_DIR, 'third_party', 'llvm-build',
36 'Release+Asserts') 36 'Release+Asserts')
37 COMPILER_RT_BUILD_DIR = os.path.join(LLVM_BUILD_DIR, '32bit-compiler-rt') 37 COMPILER_RT_BUILD_DIR = os.path.join(LLVM_BUILD_DIR, '32bit-compiler-rt')
38 CLANG_DIR = os.path.join(LLVM_DIR, 'tools', 'clang') 38 CLANG_DIR = os.path.join(LLVM_DIR, 'tools', 'clang')
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 parser.add_argument('--no-clobber', dest='clobber', action='store_false') 315 parser.add_argument('--no-clobber', dest='clobber', action='store_false')
316 parser.add_argument('--tools', nargs='*', default=['plugins']) 316 parser.add_argument('--tools', nargs='*', default=['plugins'])
317 # For now, this flag is only used for the non-Windows flow, but argparser gets 317 # For now, this flag is only used for the non-Windows flow, but argparser gets
318 # mad if it sees a flag it doesn't recognize. 318 # mad if it sees a flag it doesn't recognize.
319 parser.add_argument('--if-needed', action='store_true') 319 parser.add_argument('--if-needed', action='store_true')
320 return UpdateClang(parser.parse_args()) 320 return UpdateClang(parser.parse_args())
321 321
322 322
323 if __name__ == '__main__': 323 if __name__ == '__main__':
324 sys.exit(main()) 324 sys.exit(main())
OLDNEW
« no previous file with comments | « tools/clang/plugins/tests/warn_only.txt ('k') | tools/clang/scripts/update.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698