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

Side by Side Diff: infra/bots/common.py

Issue 1743353002: Fix Swarming compile out dir (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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 | 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/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2016 Google Inc. 3 # Copyright 2016 Google Inc.
4 # 4 #
5 # Use of this source code is governed by a BSD-style license that can be 5 # Use of this source code is governed by a BSD-style license that can be
6 # found in the LICENSE file. 6 # found in the LICENSE file.
7 7
8 8
9 import contextlib 9 import contextlib
10 import math 10 import math
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 self.name = bot_name 148 self.name = bot_name
149 self.skia_dir = os.path.abspath(os.path.join( 149 self.skia_dir = os.path.abspath(os.path.join(
150 os.path.dirname(os.path.realpath(__file__)), 150 os.path.dirname(os.path.realpath(__file__)),
151 os.pardir, os.pardir)) 151 os.pardir, os.pardir))
152 self.swarm_out_dir = swarm_out_dir 152 self.swarm_out_dir = swarm_out_dir
153 os.chdir(self.skia_dir) 153 os.chdir(self.skia_dir)
154 self.build_dir = os.path.abspath(os.path.join(self.skia_dir, os.pardir)) 154 self.build_dir = os.path.abspath(os.path.join(self.skia_dir, os.pardir))
155 self.spec = self.get_bot_spec(bot_name) 155 self.spec = self.get_bot_spec(bot_name)
156 self.bot_cfg = self.spec['builder_cfg'] 156 self.bot_cfg = self.spec['builder_cfg']
157 if self.bot_cfg['role'] == 'Build': 157 if self.bot_cfg['role'] == 'Build':
158 self.out_dir = os.path.join(swarm_out_dir, 'out') 158 self.out_dir = swarm_out_dir
159 else: 159 else:
160 self.out_dir = 'out' 160 self.out_dir = 'out'
161 self.configuration = self.spec['configuration'] 161 self.configuration = self.spec['configuration']
162 self.default_env = { 162 self.default_env = {
163 'SKIA_OUT': self.out_dir, 163 'SKIA_OUT': self.out_dir,
164 'BUILDTYPE': self.configuration, 164 'BUILDTYPE': self.configuration,
165 'PATH': os.environ['PATH'], 165 'PATH': os.environ['PATH'],
166 } 166 }
167 self.default_env.update(self.spec['env']) 167 self.default_env.update(self.spec['env'])
168 self.build_targets = [str(t) for t in self.spec['build_targets']] 168 self.build_targets = [str(t) for t in self.spec['build_targets']]
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 361
362 # See skia:2789. 362 # See skia:2789.
363 if ('Valgrind' in self.name and 363 if ('Valgrind' in self.name and
364 self.builder_cfg.get('cpu_or_gpu') == 'GPU'): 364 self.builder_cfg.get('cpu_or_gpu') == 'GPU'):
365 abandonGpuContext = list(args) 365 abandonGpuContext = list(args)
366 abandonGpuContext.append('--abandonGpuContext') 366 abandonGpuContext.append('--abandonGpuContext')
367 self.flavor.run(abandonGpuContext) 367 self.flavor.run(abandonGpuContext)
368 preAbandonGpuContext = list(args) 368 preAbandonGpuContext = list(args)
369 preAbandonGpuContext.append('--preAbandonGpuContext') 369 preAbandonGpuContext.append('--preAbandonGpuContext')
370 self.flavor.run(preAbandonGpuContext) 370 self.flavor.run(preAbandonGpuContext)
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