| 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 | 6 |
| 7 # Compiler setup for the Windows SDK. Applied to all targets. | 7 # Compiler setup for the Windows SDK. Applied to all targets. |
| 8 config("sdk") { | 8 config("sdk") { |
| 9 # The include path is the stuff returned by the script. | 9 # The include path is the stuff returned by the script. |
| 10 #include_dirs = msvc_config[0] TODO(brettw) make this work. | 10 #include_dirs = msvc_config[0] TODO(brettw) make this work. |
| 11 | 11 |
| 12 defines = [ | 12 defines = [ |
| 13 "_ATL_NO_OPENGL", | 13 "_ATL_NO_OPENGL", |
| 14 "_WIN32_WINNT=0x0602", | |
| 15 "_WINDOWS", | 14 "_WINDOWS", |
| 16 "CERT_CHAIN_PARA_HAS_EXTRA_FIELDS", | 15 "CERT_CHAIN_PARA_HAS_EXTRA_FIELDS", |
| 17 "NTDDI_VERSION=0x06020000", | 16 "NTDDI_VERSION=0x06020000", |
| 18 "PSAPI_VERSION=1", | 17 "PSAPI_VERSION=1", |
| 19 "WIN32", | 18 "WIN32", |
| 20 "WINVER=0x0602", | |
| 21 ] | 19 ] |
| 22 | 20 |
| 23 include_dirs = system_include_dirs | 21 include_dirs = system_include_dirs |
| 24 | 22 |
| 25 if (is_visual_studio_express) { | 23 if (is_visual_studio_express) { |
| 26 # https://code.google.com/p/chromium/issues/detail?id=372451#c20 | 24 # https://code.google.com/p/chromium/issues/detail?id=372451#c20 |
| 27 # Warning 4702 ("Unreachable code") should be re-enabled once Express users | 25 # Warning 4702 ("Unreachable code") should be re-enabled once Express users |
| 28 # are updated to VS2013 Update 2. | 26 # are updated to VS2013 Update 2. |
| 29 cflags = [ "/wd4702" ] | 27 cflags = [ "/wd4702" ] |
| 30 } else { | 28 } else { |
| 31 # Only supported on non-Express versions. | 29 # Only supported on non-Express versions. |
| 32 defines += [ "_SECURE_ATL" ] | 30 defines += [ "_SECURE_ATL" ] |
| 33 } | 31 } |
| 34 } | 32 } |
| 35 | 33 |
| 34 # Sets the default Windows build version. This is separated because some |
| 35 # targets need to manually override it for their compiles. |
| 36 config("winver") { |
| 37 defines = [ |
| 38 "_WIN32_WINNT=0x0602", |
| 39 "WINVER=0x0602", |
| 40 ] |
| 41 } |
| 42 |
| 36 # Linker flags for Windows SDK setup, this is applied only to EXEs and DLLs. | 43 # Linker flags for Windows SDK setup, this is applied only to EXEs and DLLs. |
| 37 config("sdk_link") { | 44 config("sdk_link") { |
| 38 if (cpu_arch == "x64") { | 45 if (cpu_arch == "x64") { |
| 39 ldflags = [ "/MACHINE:X64" ] | 46 ldflags = [ "/MACHINE:X64" ] |
| 40 lib_dirs = [ | 47 lib_dirs = [ |
| 41 "$windows_sdk_path\Lib\win8\um\x64", | 48 "$windows_sdk_path\Lib\win8\um\x64", |
| 42 "$visual_studio_path\VC\lib\amd64", | 49 "$visual_studio_path\VC\lib\amd64", |
| 43 "$visual_studio_path\VC\atlmfc\lib\amd64", | 50 "$visual_studio_path\VC\atlmfc\lib\amd64", |
| 44 ] | 51 ] |
| 45 if (is_visual_studio_express) { | 52 if (is_visual_studio_express) { |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 | 159 |
| 153 # Some third party code defines NOMINMAX before including windows.h, which | 160 # Some third party code defines NOMINMAX before including windows.h, which |
| 154 # then causes warnings when it's been previously defined on the command line. | 161 # then causes warnings when it's been previously defined on the command line. |
| 155 # For such targets, this config can be removed. | 162 # For such targets, this config can be removed. |
| 156 | 163 |
| 157 config("nominmax") { | 164 config("nominmax") { |
| 158 defines = [ | 165 defines = [ |
| 159 "NOMINMAX", | 166 "NOMINMAX", |
| 160 ] | 167 ] |
| 161 } | 168 } |
| OLD | NEW |