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

Side by Side Diff: buildbot/buildbot_run.py

Issue 245923003: Fix msvs-ninja OutputDirectory path. (Closed) Base URL: http://gyp.googlecode.com/svn/trunk/
Patch Set: Use reg.exe instead of _winreg. Created 6 years, 6 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 | pylib/gyp/generator/msvs.py » ('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 Google Inc. All rights reserved. 2 # Copyright (c) 2012 Google Inc. 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 6
7 """Argument-less script to select what to run on the buildbots.""" 7 """Argument-less script to select what to run on the buildbots."""
8 8
9 9
10 import os 10 import os
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 print '@@@BUILD_STEP Sync Android@@@' 100 print '@@@BUILD_STEP Sync Android@@@'
101 CallSubProcess(['repo', 'sync', '-j4'], cwd=ANDROID_DIR) 101 CallSubProcess(['repo', 'sync', '-j4'], cwd=ANDROID_DIR)
102 102
103 print '@@@BUILD_STEP Build Android@@@' 103 print '@@@BUILD_STEP Build Android@@@'
104 CallSubProcess( 104 CallSubProcess(
105 ['/bin/bash', 105 ['/bin/bash',
106 '-c', 'source build/envsetup.sh && lunch full-eng && make -j4'], 106 '-c', 'source build/envsetup.sh && lunch full-eng && make -j4'],
107 cwd=ANDROID_DIR) 107 cwd=ANDROID_DIR)
108 108
109 109
110 def GypTestFormat(title, format=None, msvs_version=None): 110 def GypTestFormat(title, format=None, msvs_version=None, tests=[]):
111 """Run the gyp tests for a given format, emitting annotator tags. 111 """Run the gyp tests for a given format, emitting annotator tags.
112 112
113 See annotator docs at: 113 See annotator docs at:
114 https://sites.google.com/a/chromium.org/dev/developers/testing/chromium-buil d-infrastructure/buildbot-annotations 114 https://sites.google.com/a/chromium.org/dev/developers/testing/chromium-buil d-infrastructure/buildbot-annotations
115 Args: 115 Args:
116 format: gyp format to test. 116 format: gyp format to test.
117 Returns: 117 Returns:
118 0 for sucesss, 1 for failure. 118 0 for sucesss, 1 for failure.
119 """ 119 """
120 if not format: 120 if not format:
121 format = title 121 format = title
122 122
123 print '@@@BUILD_STEP ' + title + '@@@' 123 print '@@@BUILD_STEP ' + title + '@@@'
124 sys.stdout.flush() 124 sys.stdout.flush()
125 env = os.environ.copy() 125 env = os.environ.copy()
126 if msvs_version: 126 if msvs_version:
127 env['GYP_MSVS_VERSION'] = msvs_version 127 env['GYP_MSVS_VERSION'] = msvs_version
128 command = ' '.join( 128 command = ' '.join(
129 [sys.executable, 'trunk/gyptest.py', 129 [sys.executable, 'trunk/gyptest.py',
130 '--all', 130 '--all',
131 '--passed', 131 '--passed',
132 '--format', format, 132 '--format', format,
133 '--path', CMAKE_BIN_DIR, 133 '--path', CMAKE_BIN_DIR,
134 '--chdir', 'trunk']) 134 '--chdir', 'trunk'] + tests)
135 if format == 'android': 135 if format == 'android':
136 # gyptest needs the environment setup from envsetup/lunch in order to build 136 # gyptest needs the environment setup from envsetup/lunch in order to build
137 # using the 'android' backend, so this is done in a single shell. 137 # using the 'android' backend, so this is done in a single shell.
138 retcode = subprocess.call( 138 retcode = subprocess.call(
139 ['/bin/bash', 139 ['/bin/bash',
140 '-c', 'source build/envsetup.sh && lunch full-eng && cd %s && %s' 140 '-c', 'source build/envsetup.sh && lunch full-eng && cd %s && %s'
141 % (ROOT_DIR, command)], 141 % (ROOT_DIR, command)],
142 cwd=ANDROID_DIR, env=env) 142 cwd=ANDROID_DIR, env=env)
143 else: 143 else:
144 retcode = subprocess.call(command, cwd=ROOT_DIR, env=env, shell=True) 144 retcode = subprocess.call(command, cwd=ROOT_DIR, env=env, shell=True)
(...skipping 21 matching lines...) Expand all
166 retcode += GypTestFormat('make') 166 retcode += GypTestFormat('make')
167 PrepareCmake() 167 PrepareCmake()
168 retcode += GypTestFormat('cmake') 168 retcode += GypTestFormat('cmake')
169 elif sys.platform == 'darwin': 169 elif sys.platform == 'darwin':
170 retcode += GypTestFormat('ninja') 170 retcode += GypTestFormat('ninja')
171 retcode += GypTestFormat('xcode') 171 retcode += GypTestFormat('xcode')
172 retcode += GypTestFormat('make') 172 retcode += GypTestFormat('make')
173 elif sys.platform == 'win32': 173 elif sys.platform == 'win32':
174 retcode += GypTestFormat('ninja') 174 retcode += GypTestFormat('ninja')
175 if os.environ['BUILDBOT_BUILDERNAME'] == 'gyp-win64': 175 if os.environ['BUILDBOT_BUILDERNAME'] == 'gyp-win64':
176 retcode += GypTestFormat('msvs-ninja-2012', format='msvs-ninja',
177 msvs_version='2012',
178 tests=[
179 'test\generator-output\gyptest-actions.py',
180 'test\generator-output\gyptest-relocate.py',
181 'test\generator-output\gyptest-rules.py'])
176 retcode += GypTestFormat('msvs-2010', format='msvs', msvs_version='2010') 182 retcode += GypTestFormat('msvs-2010', format='msvs', msvs_version='2010')
177 retcode += GypTestFormat('msvs-2012', format='msvs', msvs_version='2012') 183 retcode += GypTestFormat('msvs-2012', format='msvs', msvs_version='2012')
178 else: 184 else:
179 raise Exception('Unknown platform') 185 raise Exception('Unknown platform')
180 if retcode: 186 if retcode:
181 # TODO(bradnelson): once the annotator supports a postscript (section for 187 # TODO(bradnelson): once the annotator supports a postscript (section for
182 # after the build proper that could be used for cumulative failures), 188 # after the build proper that could be used for cumulative failures),
183 # use that instead of this. This isolates the final return value so 189 # use that instead of this. This isolates the final return value so
184 # that it isn't misattributed to the last stage. 190 # that it isn't misattributed to the last stage.
185 print '@@@BUILD_STEP failures@@@' 191 print '@@@BUILD_STEP failures@@@'
186 sys.exit(retcode) 192 sys.exit(retcode)
187 193
188 194
189 if __name__ == '__main__': 195 if __name__ == '__main__':
190 GypBuild() 196 GypBuild()
OLDNEW
« no previous file with comments | « no previous file | pylib/gyp/generator/msvs.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698