[Scummvm-git-logs] scummvm master -> 378531d779d373e2a61b0fd0e02222f2d6cba35d

lephilousophe noreply at scummvm.org
Sun Apr 28 18:11:50 UTC 2024


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
378531d779 WIN32: Ensure that _WIN32_WINNT is set high enough for required defines


Commit: 378531d779d373e2a61b0fd0e02222f2d6cba35d
    https://github.com/scummvm/scummvm/commit/378531d779d373e2a61b0fd0e02222f2d6cba35d
Author: Cameron Cawley (ccawley2011 at gmail.com)
Date: 2024-04-28T20:11:47+02:00

Commit Message:
WIN32: Ensure that _WIN32_WINNT is set high enough for required defines

Changed paths:
    backends/platform/sdl/win32/win32_wrapper.cpp


diff --git a/backends/platform/sdl/win32/win32_wrapper.cpp b/backends/platform/sdl/win32/win32_wrapper.cpp
index f92399eab10..b38a5d06664 100644
--- a/backends/platform/sdl/win32/win32_wrapper.cpp
+++ b/backends/platform/sdl/win32/win32_wrapper.cpp
@@ -23,12 +23,20 @@
 #define FORBIDDEN_SYMBOL_EXCEPTION_strcat
 
 #define WIN32_LEAN_AND_MEAN
-#include <windows.h>
-#include <shellapi.h> // for CommandLineToArgvW()
-#if defined(__GNUC__) && defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR)
+#include <sdkddkver.h>
+#if !defined(_WIN32_IE) || (_WIN32_IE < 0x500)
  // required for SHGetSpecialFolderPath and SHGFP_TYPE_CURRENT in shlobj.h
+#undef _WIN32_IE
 #define _WIN32_IE 0x500
 #endif
+#if !defined(_WIN32_WINNT) || (_WIN32_WINNT < 0x500)
+ // required for VER_MAJORVERSION, VER_MINORVERSION and VER_GREATER_EQUAL in winnt.h
+ // set to Windows 2000 which is the minimum needed for these constants
+#undef _WIN32_WINNT
+#define _WIN32_WINNT 0x500
+#endif
+#include <windows.h>
+#include <shellapi.h> // for CommandLineToArgvW()
 #include <shlobj.h>
 #include <tchar.h>
 




More information about the Scummvm-git-logs mailing list