aboutsummaryrefslogtreecommitdiff
path: root/drivers/unix/ip_unix.cpp
diff options
context:
space:
mode:
authorRémi Verschelde2017-01-08 20:41:11 +0100
committerRémi Verschelde2017-01-12 19:15:30 +0100
commitd66740175eef6f67f2edb364533fa71eaad5ceb7 (patch)
treeb4daa3744d7c39a9366344b63e4bd53840903293 /drivers/unix/ip_unix.cpp
parent5672852351d9d47c848bafad14bb031f176b8558 (diff)
downloadgodot-d66740175eef6f67f2edb364533fa71eaad5ceb7.tar.gz
godot-d66740175eef6f67f2edb364533fa71eaad5ceb7.tar.zst
godot-d66740175eef6f67f2edb364533fa71eaad5ceb7.zip
Windows: Define _WIN32_WINRT to 0x0600 (Vista)
Passed as a compiler define to be sure it is always define before windows.h is loaded. This means that Godot officially requires Vista API or later, it will not work on Windows XP or earlier. Also fix a bogus check for Windows 7 API. (cherry picked from commit 6323779596dea0db7f58afef7d3d3d5588ef20cb)
Diffstat (limited to 'drivers/unix/ip_unix.cpp')
-rw-r--r--drivers/unix/ip_unix.cpp12
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/unix/ip_unix.cpp b/drivers/unix/ip_unix.cpp
index 200eb1dd2..ed11c0686 100644
--- a/drivers/unix/ip_unix.cpp
+++ b/drivers/unix/ip_unix.cpp
@@ -37,19 +37,13 @@
#ifndef AI_ADDRCONFIG
#define AI_ADDRCONFIG 0x00000400
#endif
- #ifdef WINRT_ENABLED
#include <ws2tcpip.h>
#include <winsock2.h>
#include <windows.h>
#include <stdio.h>
- #else
- #define WINVER 0x0600
- #include <ws2tcpip.h>
- #include <winsock2.h>
- #include <windows.h>
- #include <stdio.h>
- #include <iphlpapi.h>
- #endif
+ #ifndef WINRT_ENABLED
+ #include <iphlpapi.h>
+ #endif
#else
#include <netdb.h>
#ifdef ANDROID_ENABLED