run-swarmed.py: fix error in py3
Change-Id: I917ed07100cd01f853c77c0bed557ca24a38a75e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3439147 Reviewed-by: Nico Weber <thakis@chromium.org> Commit-Queue: Takuto Ikuta <tikuta@chromium.org> Cr-Commit-Position: refs/heads/main@{#967191}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
b4d59a67b9
commit
ed87b35cc4
@ -245,8 +245,11 @@ def main():
|
||||
if 'target_os' in gn_args:
|
||||
args.target_os = gn_args['target_os'].strip('"')
|
||||
else:
|
||||
args.target_os = { 'darwin': 'mac', 'linux2': 'linux', 'win32': 'win' }[
|
||||
sys.platform]
|
||||
args.target_os = {
|
||||
'darwin': 'mac',
|
||||
'linux': 'linux',
|
||||
'win32': 'win'
|
||||
}[sys.platform]
|
||||
|
||||
if args.swarming_os is None:
|
||||
args.swarming_os = {
|
||||
@ -265,7 +268,7 @@ def main():
|
||||
if args.arch == 'detect':
|
||||
if args.target_os not in ('android', 'mac', 'win'):
|
||||
executable_info = subprocess.check_output(
|
||||
['file', os.path.join(args.out_dir, args.target_name)])
|
||||
['file', os.path.join(args.out_dir, args.target_name)], text=True)
|
||||
if 'ARM aarch64' in executable_info:
|
||||
args.arch = 'arm64',
|
||||
else:
|
||||
|
Reference in New Issue
Block a user