OLD | NEW |
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("//build/config/win/visual_studio_version.gni") | 5 import("//build/config/win/visual_studio_version.gni") |
6 import("//build/toolchain/goma.gni") | 6 import("//build/toolchain/goma.gni") |
7 | 7 |
8 # Should only be running on Windows. | 8 # Should only be running on Windows. |
9 assert(is_win) | 9 assert(is_win) |
10 | 10 |
11 # Setup the Visual Studio state. | 11 # Setup the Visual Studio state. |
12 # | 12 # |
13 # Its arguments are the VS path and the compiler wrapper tool. It will write | 13 # Its arguments are the VS path and the compiler wrapper tool. It will write |
14 # "environment.x86" and "environment.x64" to the build directory and return a | 14 # "environment.x86" and "environment.x64" to the build directory and return a |
15 # list to us. | 15 # list to us. |
16 gyp_win_tool_path = rebase_path("//tools/gyp/pylib/gyp/win_tool.py", | 16 gyp_win_tool_path = rebase_path("//tools/gyp/pylib/gyp/win_tool.py", |
17 root_build_dir) | 17 root_build_dir) |
18 exec_script("setup_toolchain.py", | 18 exec_script("setup_toolchain.py", |
19 [ visual_studio_path, gyp_win_tool_path, windows_sdk_path ]) | 19 [ visual_studio_path, gyp_win_tool_path, windows_sdk_path ]) |
20 | 20 |
| 21 # This value will be inherited in the toolchain below. |
| 22 concurrent_links = exec_script("../get_concurrent_links.py", [], "value") |
| 23 |
21 # Parameters: | 24 # Parameters: |
22 # cpu_arch: cpu_arch to pass as a build arg | 25 # cpu_arch: cpu_arch to pass as a build arg |
23 # environment: File name of environment file. | 26 # environment: File name of environment file. |
24 # force_win64 (optional): value for this build arg. | 27 # force_win64 (optional): value for this build arg. |
25 template("msvc_toolchain") { | 28 template("msvc_toolchain") { |
26 env = invoker.environment | 29 env = invoker.environment |
27 | 30 |
28 toolchain(target_name) { | 31 toolchain(target_name) { |
29 # Make these apply to all tools below. | 32 # Make these apply to all tools below. |
30 lib_switch = "" | 33 lib_switch = "" |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 msvc_toolchain("32") { | 159 msvc_toolchain("32") { |
157 environment = "environment.x86" | 160 environment = "environment.x86" |
158 cpu_arch = "x64" | 161 cpu_arch = "x64" |
159 } | 162 } |
160 | 163 |
161 msvc_toolchain("64") { | 164 msvc_toolchain("64") { |
162 environment = "environment.x64" | 165 environment = "environment.x64" |
163 cpu_arch = "x64" | 166 cpu_arch = "x64" |
164 force_win64 = true | 167 force_win64 = true |
165 } | 168 } |
OLD | NEW |