OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 declare_args() { | 5 declare_args() { |
6 # Path to Visual Studio. If empty, the default is used which is to use the | 6 # Path to Visual Studio. If empty, the default is used which is to use the |
7 # automatic toolchain in depot_tools. If set, you must also set the | 7 # automatic toolchain in depot_tools. If set, you must also set the |
8 # visual_studio_version and wdk_path. | 8 # visual_studio_version and wdk_path. |
9 visual_studio_path = "" | 9 visual_studio_path = "" |
10 | 10 |
11 # Version of Visual Studio pointed to by the visual_studio_path. | 11 # Version of Visual Studio pointed to by the visual_studio_path. |
12 # Use "2013" for Visual Studio 2013, or "2013e" for the Express version. | 12 # Use "2013" for Visual Studio 2013, or "2013e" for the Express version. |
13 visual_studio_version = "" | 13 visual_studio_version = "" |
14 | 14 |
| 15 # Path to the actual binary directory for the Visual Studio toolchains. |
| 16 vc_bin_dir = "" |
| 17 |
15 # Directory of the Windows driver kit. If visual_studio_path is empty, this | 18 # Directory of the Windows driver kit. If visual_studio_path is empty, this |
16 # will be auto-filled. | 19 # will be auto-filled. |
17 wdk_path = "" | 20 wdk_path = "" |
18 | 21 |
19 # Full path to the Windows SDK, not including a backslash at the end. | 22 # Full path to the Windows SDK, not including a backslash at the end. |
20 # This value is the default location, override if you have a different | 23 # This value is the default location, override if you have a different |
21 # installation location. | 24 # installation location. |
22 windows_sdk_path = "C:\Program Files (x86)\Windows Kits\8.1" | 25 windows_sdk_path = "C:\Program Files (x86)\Windows Kits\8.1" |
23 | 26 |
24 # The list of include directories that are treated as "system" include | 27 # The list of include directories that are treated as "system" include |
25 # directories. TODO(scottmg): These are incorrectly put on the command line | 28 # directories. TODO(scottmg): These are incorrectly put on the command line |
26 # in GN, they should really be stored into %INCLUDE%. | 29 # in GN, they should really be stored into %INCLUDE%. |
27 system_include_dirs = [] | 30 system_include_dirs = [] |
28 } | 31 } |
29 | 32 |
30 if (visual_studio_path == "") { | 33 if (visual_studio_path == "") { |
31 toolchain_data = | 34 toolchain_data = |
32 exec_script("../../vs_toolchain.py", [ "get_toolchain_dir" ], "scope") | 35 exec_script("../../vs_toolchain.py", |
| 36 [ "get_toolchain_dir", cpu_arch ], "scope") |
33 visual_studio_path = toolchain_data.vs_path | 37 visual_studio_path = toolchain_data.vs_path |
34 windows_sdk_path = toolchain_data.sdk_path | 38 windows_sdk_path = toolchain_data.sdk_path |
35 visual_studio_version = toolchain_data.vs_version | 39 visual_studio_version = toolchain_data.vs_version |
36 wdk_path = toolchain_data.wdk_dir | 40 wdk_path = toolchain_data.wdk_dir |
37 visual_studio_runtime_dirs = toolchain_data.runtime_dirs | 41 visual_studio_runtime_dirs = toolchain_data.runtime_dirs |
| 42 vc_bin_dir = toolchain_data.vc_bin_dir |
38 } else { | 43 } else { |
39 assert(visual_studio_version != "", | 44 assert(visual_studio_version != "", |
40 "You must set the visual_studio_version if you set the path") | 45 "You must set the visual_studio_version if you set the path") |
41 assert(wdk_path != "", | 46 assert(wdk_path != "", |
42 "You must set the wdk_path if you set the visual studio path") | 47 "You must set the wdk_path if you set the visual studio path") |
43 visual_studio_runtime_dirs = [] | 48 visual_studio_runtime_dirs = [] |
44 } | 49 } |
45 | 50 |
46 # The Windows SDK include directories must be first. They both have a sal.h, | 51 # The Windows SDK include directories must be first. They both have a sal.h, |
47 # and the SDK one is newer and the SDK uses some newer features from it not | 52 # and the SDK one is newer and the SDK uses some newer features from it not |
48 # present in the Visual Studio one. | 53 # present in the Visual Studio one. |
49 system_include_dirs = [ | 54 system_include_dirs = [ |
50 "$windows_sdk_path\Include\shared", | 55 "$windows_sdk_path\Include\shared", |
51 "$windows_sdk_path\Include\um", | 56 "$windows_sdk_path\Include\um", |
52 "$windows_sdk_path\Include\winrt", | 57 "$windows_sdk_path\Include\winrt", |
53 "$visual_studio_path\VC\include", | 58 "$visual_studio_path\VC\include", |
54 "$visual_studio_path\VC\atlmfc\include", | 59 "$visual_studio_path\VC\atlmfc\include", |
55 ] | 60 ] |
OLD | NEW |