From 02226ef653e1e871be6004a51f08b74c0c9dd8e4 Mon Sep 17 00:00:00 2001 From: Ray Molenkamp Date: Wed, 5 Feb 2020 20:03:06 -0700 Subject: Code_Cleanup_Day/Windows: Clean-up windows API Level. Not sure when this happened but apparently the lower bar is now windows 7 [1] This patch bumps to API version to 0x0601 (Win7) and cleans up any uses that worked around the globally set API version. [1] https://www.blender.org/download/requirements/ Reviewed By: brecht Differential Revision: https://developer.blender.org/D6758 --- build_files/cmake/platform/platform_win32.cmake | 4 ++-- intern/cycles/device/device_optix.cpp | 3 --- source/blender/blenlib/intern/dynlib.c | 3 --- source/blender/blenlib/intern/time.c | 3 --- 4 files changed, 2 insertions(+), 11 deletions(-) diff --git a/build_files/cmake/platform/platform_win32.cmake b/build_files/cmake/platform/platform_win32.cmake index b228930bfb1..04e5848dcfe 100644 --- a/build_files/cmake/platform/platform_win32.cmake +++ b/build_files/cmake/platform/platform_win32.cmake @@ -131,8 +131,8 @@ add_definitions( # MSVC11 needs _ALLOW_KEYWORD_MACROS to build add_definitions(-D_ALLOW_KEYWORD_MACROS) -# We want to support Vista level ABI -add_definitions(-D_WIN32_WINNT=0x600) +# We want to support Windows 7 level ABI +add_definitions(-D_WIN32_WINNT=0x601) include(build_files/cmake/platform/platform_win32_bundle_crt.cmake) remove_cc_flag("/MDd" "/MD") diff --git a/intern/cycles/device/device_optix.cpp b/intern/cycles/device/device_optix.cpp index c1106b367ca..f479cbd7414 100644 --- a/intern/cycles/device/device_optix.cpp +++ b/intern/cycles/device/device_optix.cpp @@ -31,9 +31,6 @@ # include "util/util_debug.h" # include "util/util_logging.h" -# undef _WIN32_WINNT // Need minimum API support for Windows 7 -# define _WIN32_WINNT _WIN32_WINNT_WIN7 - # ifdef WITH_CUDA_DYNLOAD # include // Do not use CUDA SDK headers when using CUEW diff --git a/source/blender/blenlib/intern/dynlib.c b/source/blender/blenlib/intern/dynlib.c index c648a212fef..2aceff45b3e 100644 --- a/source/blender/blenlib/intern/dynlib.c +++ b/source/blender/blenlib/intern/dynlib.c @@ -34,9 +34,6 @@ struct DynamicLibrary { }; #ifdef WIN32 -# ifndef _WIN32_WINNT -# define _WIN32_WINNT 0x501 /* Windows XP or newer */ -# endif # define WIN32_LEAN_AND_MEAN # include # include "utf_winfunc.h" diff --git a/source/blender/blenlib/intern/time.c b/source/blender/blenlib/intern/time.c index f7bcf303b4b..81b079a1f77 100644 --- a/source/blender/blenlib/intern/time.c +++ b/source/blender/blenlib/intern/time.c @@ -24,9 +24,6 @@ #include "PIL_time.h" #ifdef WIN32 -# ifndef _WIN32_WINNT -# define _WIN32_WINNT 0x501 /* Windows XP or newer */ -# endif # define WIN32_LEAN_AND_MEAN # include -- cgit v1.2.3