The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
Compiled SDL2.0.3 with VS2010, got "Cannot open dxsdkve
BobHick


Joined: 26 Aug 2015
Posts: 3
I downloaded SDL2-2.0.3, opened SDL2-2.0.3\VisualC\SDL_VS2010.sln, tried to compile it, and got this error:

Error 1 error C1083: Cannot open include file: 'dxsdkver.h': No such file or directory c:\mydir\sdl2-2.0.3\src\audio\xaudio2\sdl_xaudio2.c 68 1 SDL2

How to compile it?

What is the difference between SDL_VS2010.sln and SDL_VS2010EE.sln?
BobHick


Joined: 26 Aug 2015
Posts: 3
...I guess I have to install DirectX sdk? Actually I'm trying to compile it only to see how to use winapi and gdi functions, for now I don't care about directx.
BobHick


Joined: 26 Aug 2015
Posts: 3
Ok, I just commented this include out, and surprisingly it worked.

By the way, I had to edit Loopwave.c a bit for it to work. I changed
if (argc >= 1)
to
if (argc >= 2)
in the function "main". First parameter is always the full path of .exe itself. You probably should edit this too. Maybe my source is outdated? I downloaded it from site, https://www.libsdl.org/download-2.0.php , one named SDL2-2.0.3.zip.

Also, it still didn't run for me even after that, because he couldn't find sample.wav, because visual studio sets it's working dir to the project folder. I don't know how to fix this, I just executed .exe myself, without studio. But you probably should edit solution and project files somehow.

I'm still curious, what is the difference between SDL_VS2010.sln and SDL_VS2010EE.sln?