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

Unified Diff: scripts/slave/compile.py

Issue 15102003: Set CHROMIUM_BUILD and friends when building with ninja too. (Closed) Base URL: http://src.chromium.org/chrome/trunk/tools/build/
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/slave/compile.py
===================================================================
--- scripts/slave/compile.py (revision 199603)
+++ scripts/slave/compile.py (working copy)
@@ -505,6 +505,16 @@
return codename
+def maybe_set_official_build_envvars(options, env):
+ if options.mode == 'google_chrome' or options.mode == 'official':
+ env['CHROMIUM_BUILD'] = '_google_chrome'
+
+ if options.mode == 'official':
+ # Official builds are always Google Chrome.
+ env['OFFICIAL_BUILD'] = '1'
+ env['CHROME_BUILD_TYPE'] = '_official'
+
+
def common_make_settings(
command, options, env, crosstool=None, compiler=None):
"""
@@ -513,14 +523,8 @@
and for the mac make build.
"""
assert compiler in (None, 'clang', 'goma', 'goma-clang', 'jsonclang')
- if options.mode == 'google_chrome' or options.mode == 'official':
- env['CHROMIUM_BUILD'] = '_google_chrome'
+ maybe_set_official_build_envvars(options, env)
- if options.mode == 'official':
- # Official builds are always Google Chrome.
- env['OFFICIAL_BUILD'] = '1'
- env['CHROME_BUILD_TYPE'] = '_official'
-
# Don't stop at the first error.
command.append('-k')
@@ -733,6 +737,8 @@
command.extend(options.build_args)
command.extend(args)
+ maybe_set_official_build_envvars(options, env)
+
if options.llvm_tsan:
# Do not report thread leaks when running executables compiled with TSan.
# http://dev.chromium.org/developers/testing/threadsanitizer-tsan-v2
@@ -935,14 +941,8 @@
# no goma support yet for this build tool.
assert options.compiler != 'goma'
- if options.mode == 'google_chrome' or options.mode == 'official':
- env['CHROMIUM_BUILD'] = '_google_chrome'
+ maybe_set_official_build_envvars(options, env)
- if options.mode == 'official':
- # Official builds are always Google Chrome.
- env['OFFICIAL_BUILD'] = '1'
- env['CHROME_BUILD_TYPE'] = '_official'
-
if not options.solution:
options.solution = 'all.sln'
« 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