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

Side by Side Diff: tools/utils.py

Issue 2873613004: [infra] Stop console spam from utils.py on a cross-build (Closed)
Patch Set: Created 3 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 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 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 # for details. All rights reserved. Use of this source code is governed by a 2 # for details. All rights reserved. Use of this source code is governed by a
3 # BSD-style license that can be found in the LICENSE file. 3 # BSD-style license that can be found in the LICENSE file.
4 4
5 # This file contains a set of utilities functions used by other Python-based 5 # This file contains a set of utilities functions used by other Python-based
6 # scripts. 6 # scripts.
7 7
8 import commands 8 import commands
9 import contextlib 9 import contextlib
10 import datetime 10 import datetime
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 (target_os != GuessOS())) 287 (target_os != GuessOS()))
288 288
289 def GetBuildConf(mode, arch, conf_os=None): 289 def GetBuildConf(mode, arch, conf_os=None):
290 if conf_os == 'android': 290 if conf_os == 'android':
291 return '%s%s%s' % (GetBuildMode(mode), conf_os.title(), arch.upper()) 291 return '%s%s%s' % (GetBuildMode(mode), conf_os.title(), arch.upper())
292 else: 292 else:
293 # Ask for a cross build if the host and target architectures don't match. 293 # Ask for a cross build if the host and target architectures don't match.
294 host_arch = ARCH_GUESS 294 host_arch = ARCH_GUESS
295 cross_build = '' 295 cross_build = ''
296 if GetArchFamily(host_arch) != GetArchFamily(arch): 296 if GetArchFamily(host_arch) != GetArchFamily(arch):
297 print "GetBuildConf: Cross-build of %s on %s\n" % (arch, host_arch)
298 cross_build = 'X' 297 cross_build = 'X'
299 return '%s%s%s' % (GetBuildMode(mode), cross_build, arch.upper()) 298 return '%s%s%s' % (GetBuildMode(mode), cross_build, arch.upper())
300 299
301 def GetBuildDir(host_os): 300 def GetBuildDir(host_os):
302 return BUILD_ROOT[host_os] 301 return BUILD_ROOT[host_os]
303 302
304 def GetBuildRoot(host_os, mode=None, arch=None, target_os=None): 303 def GetBuildRoot(host_os, mode=None, arch=None, target_os=None):
305 build_root = GetBuildDir(host_os) 304 build_root = GetBuildDir(host_os)
306 if mode: 305 if mode:
307 build_root = os.path.join(build_root, GetBuildConf(mode, arch, target_os)) 306 build_root = os.path.join(build_root, GetBuildConf(mode, arch, target_os))
(...skipping 736 matching lines...) Expand 10 before | Expand all | Expand 10 after
1044 return contextlib.nested(WindowsCoreDumpEnabler(), 1043 return contextlib.nested(WindowsCoreDumpEnabler(),
1045 WindowsCoreDumpArchiver()) 1044 WindowsCoreDumpArchiver())
1046 else: 1045 else:
1047 # We don't have support for MacOS yet. 1046 # We don't have support for MacOS yet.
1048 assert osname == 'macos' 1047 assert osname == 'macos'
1049 return NooptCoreDumpArchiver() 1048 return NooptCoreDumpArchiver()
1050 1049
1051 if __name__ == "__main__": 1050 if __name__ == "__main__":
1052 import sys 1051 import sys
1053 Main() 1052 Main()
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