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

Side by Side Diff: build/toolchain/win/setup_toolchain.py

Issue 932813002: Move description of win/setup_toolchain.py before import. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium 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 import errno
6 import os
7 import re
8 import subprocess
9 import sys
10
11 # Copies the given "win tool" (which the toolchain uses to wrap compiler 5 # Copies the given "win tool" (which the toolchain uses to wrap compiler
12 # invocations) and the environment blocks for the 32-bit and 64-bit builds on 6 # invocations) and the environment blocks for the 32-bit and 64-bit builds on
13 # Windows to the build directory. 7 # Windows to the build directory.
14 # 8 #
15 # The arguments are the visual studio install location and the location of the 9 # The arguments are the visual studio install location and the location of the
16 # win tool. The script assumes that the root build directory is the current dir 10 # win tool. The script assumes that the root build directory is the current dir
17 # and the files will be written to the current directory. 11 # and the files will be written to the current directory.
18 12
13 import errno
14 import os
15 import re
16 import subprocess
17 import sys
18
19 19
20 def _ExtractImportantEnvironment(output_of_set): 20 def _ExtractImportantEnvironment(output_of_set):
21 """Extracts environment variables required for the toolchain to run from 21 """Extracts environment variables required for the toolchain to run from
22 a textual dump output by the cmd.exe 'set' command.""" 22 a textual dump output by the cmd.exe 'set' command."""
23 envvars_to_save = ( 23 envvars_to_save = (
24 'goma_.*', # TODO(scottmg): This is ugly, but needed for goma. 24 'goma_.*', # TODO(scottmg): This is ugly, but needed for goma.
25 'include', 25 'include',
26 'lib', 26 'lib',
27 'libpath', 27 'libpath',
28 'path', 28 'path',
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 env_block = _FormatAsEnvironmentBlock(env) 145 env_block = _FormatAsEnvironmentBlock(env)
146 with open('environment.' + arch, 'wb') as f: 146 with open('environment.' + arch, 'wb') as f:
147 f.write(env_block) 147 f.write(env_block)
148 148
149 assert vc_bin_dir 149 assert vc_bin_dir
150 print 'vc_bin_dir = "%s"' % vc_bin_dir 150 print 'vc_bin_dir = "%s"' % vc_bin_dir
151 151
152 152
153 if __name__ == '__main__': 153 if __name__ == '__main__':
154 main() 154 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