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

Side by Side Diff: buildbot/cbuildbot_stages.py

Issue 6773013: Add the ability to pass use flags through cbuildbot to build_packages. (Closed) Base URL: http://git.chromium.org/git/chromite.git@master
Patch Set: review changes 1 Created 9 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 | Annotate | Revision Log
« no previous file with comments | « buildbot/cbuildbot_commands.py ('k') | 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 # Copyright (c) 2011 The Chromium OS Authors. All rights reserved. 1 # Copyright (c) 2011 The Chromium OS 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 """Module containing the various stages that a builder runs.""" 5 """Module containing the various stages that a builder runs."""
6 6
7 import os 7 import os
8 import re 8 import re
9 import sys 9 import sys
10 import tempfile 10 import tempfile
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 312
313 class BuildTargetStage(BuilderStage): 313 class BuildTargetStage(BuilderStage):
314 """This stage builds Chromium OS for a target. 314 """This stage builds Chromium OS for a target.
315 315
316 Specifically, we build Chromium OS packages and perform imaging to get 316 Specifically, we build Chromium OS packages and perform imaging to get
317 the images we want per the build spec.""" 317 the images we want per the build spec."""
318 def _PerformStage(self): 318 def _PerformStage(self):
319 BuilderStage.new_binhost = self._GetPortageEnvVar(_FULL_BINHOST) 319 BuilderStage.new_binhost = self._GetPortageEnvVar(_FULL_BINHOST)
320 emptytree = (BuilderStage.old_binhost and 320 emptytree = (BuilderStage.old_binhost and
321 BuilderStage.old_binhost != BuilderStage.new_binhost) 321 BuilderStage.old_binhost != BuilderStage.new_binhost)
322 env=[]
323 if self._build_config['useflags']:
324 env.append('USE="%s"' % ' '.join(self._build_config['useflags']))
322 325
323 commands.Build( 326 commands.Build(
324 self._build_root, emptytree, usepkg=self._build_config['usepkg'], 327 self._build_root, emptytree, usepkg=self._build_config['usepkg'],
325 build_autotest=(self._build_config['vm_tests'] and self._options.tests)) 328 build_autotest=(self._build_config['vm_tests'] and self._options.tests),
329 extra_env=env)
326 330
327 # TODO(sosa): Do this optimization in a better way. 331 # TODO(sosa): Do this optimization in a better way.
328 if self._build_type == 'full': 332 if self._build_type == 'full':
329 commands.UploadPrebuilts( 333 commands.UploadPrebuilts(
330 self._build_root, self._build_config['board'], 334 self._build_root, self._build_config['board'],
331 self._build_config['rev_overlays'], [], self._build_type, 335 self._build_config['rev_overlays'], [], self._build_type,
332 False) 336 False)
333 337
334 commands.BuildImage(self._build_root) 338 commands.BuildImage(self._build_root)
335 339
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 def _PerformStage(self): 396 def _PerformStage(self):
393 if self._build_type in ('preflight', 'chrome'): 397 if self._build_type in ('preflight', 'chrome'):
394 commands.UploadPrebuilts( 398 commands.UploadPrebuilts(
395 self._build_root, self._build_config['board'], 399 self._build_root, self._build_config['board'],
396 self._build_config['rev_overlays'], [BuilderStage.new_binhost], 400 self._build_config['rev_overlays'], [BuilderStage.new_binhost],
397 self._build_type, self._options.chrome_rev) 401 self._build_type, self._options.chrome_rev)
398 402
399 commands.UprevPush(self._build_root, self._options.tracking_branch, 403 commands.UprevPush(self._build_root, self._options.tracking_branch,
400 self._build_config['board'], BuilderStage.push_overlays, 404 self._build_config['board'], BuilderStage.push_overlays,
401 self._options.debug) 405 self._options.debug)
OLDNEW
« no previous file with comments | « buildbot/cbuildbot_commands.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698