diff --git a/Quake/Makefile.w32 b/Quake/Makefile.w32 index ba8686af..a2f28de7 100644 --- a/Quake/Makefile.w32 +++ b/Quake/Makefile.w32 @@ -68,6 +68,8 @@ endif ifeq ($(USE_SDL2),1) CFLAGS += -DUSE_SDL2 +# for compatibility with old sdks +CFLAGS += -DNO_WINSDKVER_H endif # default to our local SDL[2] for build diff --git a/Quake/Makefile.w64 b/Quake/Makefile.w64 index 58282506..35ebfb87 100644 --- a/Quake/Makefile.w64 +++ b/Quake/Makefile.w64 @@ -66,6 +66,8 @@ endif ifeq ($(USE_SDL2),1) CFLAGS += -DUSE_SDL2 +# for compatibility with old sdks +CFLAGS += -DNO_WINSDKVER_H endif # default to our local SDL[2] for build diff --git a/Quake/Makefile.wat b/Quake/Makefile.wat index f581882c..ba408bd9 100644 --- a/Quake/Makefile.wat +++ b/Quake/Makefile.wat @@ -38,6 +38,7 @@ SDL_LIBS = ../Windows/SDL/watcom/SDL.lib SDL_CFLAGS = -I../Windows/SDL2/include SDL_LIBS = ../Windows/SDL2/watcom/SDL2.lib CFLAGS += -DUSE_SDL2 +CFLAGS += -DNO_WINSDKVER_H !endif !ifeq WINSOCK2 1 @@ -128,7 +129,7 @@ all: quakespasm.exe SDL_win32_main.obj: ../Windows/SDL/main/SDL_win32_main.c wcc386 $(CFLAGS_BASE) $(SDL_CFLAGS) -fo=$^@ $< SDL_windows_main.obj: ../Windows/SDL2/main/SDL_windows_main.c - wcc386 $(CFLAGS_BASE) $(SDL_CFLAGS) -I../Windows/SDL2/main -fo=$^@ $< + wcc386 $(CFLAGS_BASE) $(SDL_CFLAGS) -DNO_WINSDKVER_H -I../Windows/SDL2/main -fo=$^@ $< quakespasm.res: ../Windows/QuakeSpasm.rc wrc -q -r -bt=nt -I../Windows -fo=$^@ $< diff --git a/Windows/CodeBlocks/QuakeSpasm-SDL2.cbp b/Windows/CodeBlocks/QuakeSpasm-SDL2.cbp index 643cc803..66441ae0 100644 --- a/Windows/CodeBlocks/QuakeSpasm-SDL2.cbp +++ b/Windows/CodeBlocks/QuakeSpasm-SDL2.cbp @@ -33,6 +33,7 @@ + diff --git a/Windows/VisualStudio/quakespasm-sdl2.vcproj b/Windows/VisualStudio/quakespasm-sdl2.vcproj index 2c61dd10..f3c561ec 100644 --- a/Windows/VisualStudio/quakespasm-sdl2.vcproj +++ b/Windows/VisualStudio/quakespasm-sdl2.vcproj @@ -41,7 +41,7 @@ Name="VCCLCompilerTool" Optimization="0" AdditionalIncludeDirectories="..\SDL2\include;..\codecs\include;..\misc\include;..\..\Quake" - PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" + PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;NO_WINSDKVER_H;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" MinimalRebuild="true" BasicRuntimeChecks="3" RuntimeLibrary="3" @@ -117,7 +117,7 @@ Optimization="2" EnableIntrinsicFunctions="true" AdditionalIncludeDirectories="..\SDL2\include;..\codecs\include;..\misc\include;..\..\Quake" - PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" + PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;NO_WINSDKVER_H;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" RuntimeLibrary="2" EnableFunctionLevelLinking="true" UsePrecompiledHeader="0" @@ -192,7 +192,7 @@ Name="VCCLCompilerTool" Optimization="0" AdditionalIncludeDirectories="..\SDL2\include;..\codecs\include;..\misc\include;..\..\Quake" - PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USE_WINSOCK2;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" + PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USE_WINSOCK2;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;NO_WINSDKVER_H;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" MinimalRebuild="true" BasicRuntimeChecks="3" RuntimeLibrary="3" @@ -269,7 +269,7 @@ Optimization="2" EnableIntrinsicFunctions="true" AdditionalIncludeDirectories="..\SDL2\include;..\codecs\include;..\misc\include;..\..\Quake" - PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USE_WINSOCK2;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" + PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USE_WINSOCK2;_CRT_NONSTDC_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;USE_SDL2;NO_WINSDKVER_H;USE_CODEC_MP3;USE_CODEC_VORBIS;USE_CODEC_WAVE;USE_CODEC_FLAC;USE_CODEC_OPUS;USE_CODEC_MIKMOD;USE_CODEC_UMX" RuntimeLibrary="2" EnableFunctionLevelLinking="true" UsePrecompiledHeader="0"