OLD | NEW |
---|---|
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright 2014 The Chromium Authors. All rights reserved. | 2 # Copyright 2014 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import glob | 6 import glob |
7 import json | 7 import json |
8 import os | 8 import os |
9 import pipes | 9 import pipes |
10 import platform | 10 import platform |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
298 runtime_dir = x64_runtime if target_cpu == 'x64' else x86_runtime | 298 runtime_dir = x64_runtime if target_cpu == 'x64' else x86_runtime |
299 _CopyRuntime(target_dir, runtime_dir, target_cpu, debug=False) | 299 _CopyRuntime(target_dir, runtime_dir, target_cpu, debug=False) |
300 if configuration == 'Debug': | 300 if configuration == 'Debug': |
301 _CopyRuntime(target_dir, runtime_dir, target_cpu, debug=True) | 301 _CopyRuntime(target_dir, runtime_dir, target_cpu, debug=True) |
302 | 302 |
303 | 303 |
304 def _GetDesiredVsToolchainHashes(): | 304 def _GetDesiredVsToolchainHashes(): |
305 """Load a list of SHA1s corresponding to the toolchains that we want installed | 305 """Load a list of SHA1s corresponding to the toolchains that we want installed |
306 to build with.""" | 306 to build with.""" |
307 if GetVisualStudioVersion() == '2015': | 307 if GetVisualStudioVersion() == '2015': |
308 # Update 3 final with patches with 10.0.10586.0 SDK. | 308 if bool(int(os.environ.get('DEPOT_TOOLS_WIN_SDK_PRERELEASE', '0'))): |
309 return ['d5dc33b15d1b2c086f2f6632e2fd15882f80dbd3'] | 309 # Update 3 final with patches with 10.0.14393 SDK. |
310 return ['d3cb0e37bdd120ad0ac4650b674b09e81be45616'] | |
311 else: | |
312 # Update 3 final with patches with 10.0.10586.0 SDK. | |
313 return ['d5dc33b15d1b2c086f2f6632e2fd15882f80dbd3'] | |
310 else: | 314 else: |
scottmg
2016/11/10 01:30:01
Maybe delete the 2013 hash while you're at it.
| |
311 return ['03a4e939cd325d6bc5216af41b92d02dda1366a6'] | 315 return ['03a4e939cd325d6bc5216af41b92d02dda1366a6'] |
312 | 316 |
313 | 317 |
314 def ShouldUpdateToolchain(): | 318 def ShouldUpdateToolchain(): |
315 """Check if the toolchain should be upgraded.""" | 319 """Check if the toolchain should be upgraded.""" |
316 if not os.path.exists(json_data_file): | 320 if not os.path.exists(json_data_file): |
317 return True | 321 return True |
318 with open(json_data_file, 'r') as tempf: | 322 with open(json_data_file, 'r') as tempf: |
319 toolchain_data = json.load(tempf) | 323 toolchain_data = json.load(tempf) |
320 version = toolchain_data['version'] | 324 version = toolchain_data['version'] |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
395 'copy_dlls': CopyDlls, | 399 'copy_dlls': CopyDlls, |
396 } | 400 } |
397 if len(sys.argv) < 2 or sys.argv[1] not in commands: | 401 if len(sys.argv) < 2 or sys.argv[1] not in commands: |
398 print >>sys.stderr, 'Expected one of: %s' % ', '.join(commands) | 402 print >>sys.stderr, 'Expected one of: %s' % ', '.join(commands) |
399 return 1 | 403 return 1 |
400 return commands[sys.argv[1]](*sys.argv[2:]) | 404 return commands[sys.argv[1]](*sys.argv[2:]) |
401 | 405 |
402 | 406 |
403 if __name__ == '__main__': | 407 if __name__ == '__main__': |
404 sys.exit(main()) | 408 sys.exit(main()) |
OLD | NEW |