We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 3207

Summary: CMAKE: windows 8+sdk includes directx headers and doesn't have dxerr.lib
Product: SDL Reporter: Martin Gerhardy <martin.gerhardy>
Component: buildAssignee: Ryan C. Gordon <icculus>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2 CC: icculus
Version: HG 2.1   
Hardware: All   
OS: Windows 8   

Description Martin Gerhardy 2015-12-14 16:15:26 UTC
see http://msdn.microsoft.com/en-us/library/windows/desktop/ee663275.aspx

With VS 2011 and Windows 8 SDK, the DirectX SDK is included as part of the Windows SDK.

something like this is needed to implement switched between the versions to make sdl compile with never msvc versions:


if (DEFINED MSVC_VERSION AND NOT ${MSVC_VERSION} LESS 1700)
   set (USE_WINSDK_DIRECTX TRUE)
endif ()
Comment 1 Martin Gerhardy 2015-12-14 16:53:14 UTC
also the mingw build should most likely link against dxerr9 instead of dxerr8. At least direct3d9 is used, not 8 - but i am not sure here - just trying to get things to compile and link properly...
Comment 2 Martin Gerhardy 2015-12-16 08:01:14 UTC
Here is how I fixed this in my local repo of my game:

https://github.com/mgerhardy/caveexpress/commit/d09fa479f0d59b9da3676b7898d0767ae4d8b564
Comment 3 Ryan C. Gordon 2015-12-29 05:04:37 UTC

This patch is now https://hg.libsdl.org/SDL/rev/e3d651c5fe31, thanks!

--ryan.