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

Side by Side Diff: build/scripts/slave/compile.py

Issue 7471028: Set CC.host and CXX.host to clang as well on the clang bots. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/
Patch Set: Created 9 years, 5 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 | Annotate | Revision Log
« 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/python 1 #!/usr/bin/python
2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2011 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 """A tool to build chrome, executed by buildbot. 6 """A tool to build chrome, executed by buildbot.
7 7
8 When this is run, the current directory (cwd) should be the outer build 8 When this is run, the current directory (cwd) should be the outer build
9 directory (e.g., chrome-release/build/). 9 directory (e.g., chrome-release/build/).
10 10
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
234 goma_jobs = 100 234 goma_jobs = 100
235 if jobs < goma_jobs: 235 if jobs < goma_jobs:
236 jobs = goma_jobs 236 jobs = goma_jobs
237 command.append('-j%d' % jobs) 237 command.append('-j%d' % jobs)
238 return 238 return
239 239
240 if compiler == 'clang': 240 if compiler == 'clang':
241 clang_dir = os.path.abspath(os.path.join( 241 clang_dir = os.path.abspath(os.path.join(
242 slave_utils.SlaveBaseDir(options.build_dir), 'build', 'src', 242 slave_utils.SlaveBaseDir(options.build_dir), 'build', 'src',
243 'third_party', 'llvm-build', 'Release+Asserts', 'bin')) 243 'third_party', 'llvm-build', 'Release+Asserts', 'bin'))
244 env['CC'] = os.path.join(clang_dir, 'clang') 244 env['CC.host'] = env['CC'] = os.path.join(clang_dir, 'clang')
245 env['CXX'] = os.path.join(clang_dir, 'clang++') 245 env['CXX.host'] = env['CXX'] = os.path.join(clang_dir, 'clang++')
246 246
247 # We intentionally don't reuse the ccache/distcc modifications, 247 # We intentionally don't reuse the ccache/distcc modifications,
248 # as they don't work with clang. 248 # as they don't work with clang.
249 command.append('-j%d' % jobs) 249 command.append('-j%d' % jobs)
250 command.append('-r') 250 command.append('-r')
251 return 251 return
252 252
253 # Use gcc and g++ by default. 253 # Use gcc and g++ by default.
254 cc = 'gcc' 254 cc = 'gcc'
255 cpp = 'g++' 255 cpp = 'g++'
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after
697 main = build_tool_map.get(options.build_tool) 697 main = build_tool_map.get(options.build_tool)
698 if not main: 698 if not main:
699 sys.stderr.write('Unknown build tool %s.\n' % repr(options.build_tool)) 699 sys.stderr.write('Unknown build tool %s.\n' % repr(options.build_tool))
700 return 2 700 return 2
701 701
702 return main(options, args) 702 return main(options, args)
703 703
704 704
705 if '__main__' == __name__: 705 if '__main__' == __name__:
706 sys.exit(real_main()) 706 sys.exit(real_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