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

Side by Side Diff: slave/skia_slave_scripts/build_step.py

Issue 219763003: reland "make bots call android_ninja instead of android_make" (Closed) Base URL: https://skia.googlesource.com/buildbot.git@master
Patch Set: fixes Created 6 years, 8 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 | slave/skia_slave_scripts/flavor_utils/android_build_step_utils.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 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """Base class for all slave-side build steps. """ 5 """Base class for all slave-side build steps. """
6 6
7 import config 7 import config
8 # pylint: disable=W0611 8 # pylint: disable=W0611
9 import flavor_utils 9 import flavor_utils
10 import imp 10 import imp
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 self._autogen_svn_password_file = '.autogen_svn_password' 184 self._autogen_svn_password_file = '.autogen_svn_password'
185 self._make_flags = shlex.split(args['make_flags'].replace('"', '')) 185 self._make_flags = shlex.split(args['make_flags'].replace('"', ''))
186 self._test_args = shlex.split(args['test_args'].replace('"', '')) 186 self._test_args = shlex.split(args['test_args'].replace('"', ''))
187 self._gm_args = shlex.split(args['gm_args'].replace('"', '')) 187 self._gm_args = shlex.split(args['gm_args'].replace('"', ''))
188 self._gm_args.append('--serialize') 188 self._gm_args.append('--serialize')
189 self._bench_args = shlex.split(args['bench_args'].replace('"', '')) 189 self._bench_args = shlex.split(args['bench_args'].replace('"', ''))
190 self._is_try = args['is_try'] == 'True' 190 self._is_try = args['is_try'] == 'True'
191 191
192 if os.name == 'nt': 192 if os.name == 'nt':
193 self._default_make_flags = [] 193 self._default_make_flags = []
194 self._default_ninja_flags = []
194 else: 195 else:
195 # Set the jobs limit to 4, since we have multiple slaves running on each 196 # Set the jobs limit to 4, since we have multiple slaves running on each
196 # machine. 197 # machine.
197 self._default_make_flags = ['--jobs', '4', '--max-load=4.0'] 198 self._default_make_flags = ['--jobs', '4', '--max-load=4.0']
199 self._default_ninja_flags = ['-j', '4', '-l', '4.0']
198 200
199 # Adding the playback directory transfer objects. 201 # Adding the playback directory transfer objects.
200 self._local_playback_dirs = LocalSkpPlaybackDirs( 202 self._local_playback_dirs = LocalSkpPlaybackDirs(
201 self._builder_name, 203 self._builder_name,
202 None if args['perf_output_basedir'] == 'None' 204 None if args['perf_output_basedir'] == 'None'
203 else args['perf_output_basedir']) 205 else args['perf_output_basedir'])
204 self._storage_playback_dirs = StorageSkpPlaybackDirs( 206 self._storage_playback_dirs = StorageSkpPlaybackDirs(
205 self._builder_name, 207 self._builder_name,
206 None if args['perf_output_basedir'] == 'None' 208 None if args['perf_output_basedir'] == 'None'
207 else args['perf_output_basedir']) 209 else args['perf_output_basedir'])
(...skipping 29 matching lines...) Expand all
237 return self._configuration 239 return self._configuration
238 240
239 @property 241 @property
240 def builder_name(self): 242 def builder_name(self):
241 return self._builder_name 243 return self._builder_name
242 244
243 @property 245 @property
244 def args(self): 246 def args(self):
245 return self._args 247 return self._args
246 248
249 # TODO(epoger): remove default_make_flags property once all builds use ninja
247 @property 250 @property
248 def default_make_flags(self): 251 def default_make_flags(self):
249 return self._default_make_flags 252 return self._default_make_flags
250 253
251 @property 254 @property
255 def default_ninja_flags(self):
256 return self._default_ninja_flags
257
258 @property
252 def make_flags(self): 259 def make_flags(self):
253 return self._make_flags 260 return self._make_flags
254 261
255 @property 262 @property
256 def perf_data_dir(self): 263 def perf_data_dir(self):
257 return self._perf_data_dir 264 return self._perf_data_dir
258 265
259 @property 266 @property
260 def resource_dir(self): 267 def resource_dir(self):
261 return self._resource_dir 268 return self._resource_dir
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
379 else: 386 else:
380 raise BuildStepFailure('Build step failed.') 387 raise BuildStepFailure('Build step failed.')
381 except Exception: 388 except Exception:
382 print traceback.format_exc() 389 print traceback.format_exc()
383 if attempt + 1 >= step.attempts: 390 if attempt + 1 >= step.attempts:
384 raise 391 raise
385 # pylint: disable=W0212 392 # pylint: disable=W0212
386 step._WaitFunc(attempt) 393 step._WaitFunc(attempt)
387 attempt += 1 394 attempt += 1
388 print '**** %s, attempt %d ****' % (StepType.__name__, attempt + 1) 395 print '**** %s, attempt %d ****' % (StepType.__name__, attempt + 1)
OLDNEW
« no previous file with comments | « no previous file | slave/skia_slave_scripts/flavor_utils/android_build_step_utils.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698