Commit 1768309c authored by thakis's avatar thakis Committed by Commit bot

win: Move NTDDI_VERSION into winver, stop setting it for usrsctp

If people want to change WINVER, they likely want to change NTDDI_VERSION as
well, so it make sense to have both in the same config.

The one other use of :winver, usrsctp, didn't change NTDDI_VERSION, but
it looks like it doesn't need to change WINVER anymore anyhow (it did that for
XP support), so drop it there.

No intended behavior change.

BUG=639853

Review-Url: https://codereview.chromium.org/2265013003
Cr-Commit-Position: refs/heads/master@{#413480}
parent cc178692
...@@ -180,7 +180,6 @@ config("runtime_library") { ...@@ -180,7 +180,6 @@ config("runtime_library") {
"_ATL_NO_OPENGL", "_ATL_NO_OPENGL",
"_WINDOWS", "_WINDOWS",
"CERT_CHAIN_PARA_HAS_EXTRA_FIELDS", "CERT_CHAIN_PARA_HAS_EXTRA_FIELDS",
"NTDDI_VERSION=0x0A000000",
"PSAPI_VERSION=1", "PSAPI_VERSION=1",
"WIN32", "WIN32",
"_SECURE_ATL", "_SECURE_ATL",
...@@ -224,6 +223,7 @@ config("runtime_library") { ...@@ -224,6 +223,7 @@ config("runtime_library") {
# targets need to manually override it for their compiles. # targets need to manually override it for their compiles.
config("winver") { config("winver") {
defines = [ defines = [
"NTDDI_VERSION=0x0A000000",
"_WIN32_WINNT=0x0A00", "_WIN32_WINNT=0x0A00",
"WINVER=0x0A00", "WINVER=0x0A00",
] ]
......
...@@ -123,16 +123,7 @@ static_library("usrsctp") { ...@@ -123,16 +123,7 @@ static_library("usrsctp") {
} }
if (is_win) { if (is_win) {
defines += [ defines += [ "__Userspace_os_Windows" ]
"__Userspace_os_Windows",
# Manually setting WINVER and _WIN32_WINNT is needed because Chrome
# sets WINVER to a newer version of windows. But compiling usrsctp
# this way would is incompatible with windows XP.
"WINVER=0x0502",
"_WIN32_WINNT=0x0502",
]
configs -= [ "//build/config/win:winver" ]
} else { } else {
defines += [ "NON_WINDOWS_DEFINE" ] defines += [ "NON_WINDOWS_DEFINE" ]
} }
......
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
['OS=="linux" or OS=="android"', { ['OS=="linux" or OS=="android"', {
'defines': [ 'defines': [
'__Userspace_os_Linux', '__Userspace_os_Linux',
'_GNU_SOURCE' '_GNU_SOURCE'
], ],
'cflags!': [ '-Werror', '-Wall' ], 'cflags!': [ '-Werror', '-Wall' ],
'cflags': [ '-w' ], 'cflags': [ '-w' ],
...@@ -130,16 +130,6 @@ ...@@ -130,16 +130,6 @@
['OS=="win"', { ['OS=="win"', {
'defines': [ 'defines': [
'__Userspace_os_Windows', '__Userspace_os_Windows',
# Manually setting WINVER and _WIN32_WINNT is needed because Chrome
# sets WINVER to a newer version of Windows. But compiling usrsctp
# this way would be incompatible with Windows XP.
'WINVER=0x0502',
'_WIN32_WINNT=0x0502',
],
'defines!': [
# Remove Chrome's WINVER defines to avoid redefinition warnings.
'WINVER=0x0A00',
'_WIN32_WINNT=0x0A00',
], ],
'cflags!': [ '/W3', '/WX' ], 'cflags!': [ '/W3', '/WX' ],
'cflags': [ '/w' ], 'cflags': [ '/w' ],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment