Reputation: 487
After a previous issue, I gave up and blew my installation away to start afresh. Reinstalling MinGW, Code Blocks (with MinGW) and SDL. Following this tutorial (http://lazyfoo.net/tutorials/SDL/01_hello_SDL/windows/codeblocks/index.php) to the letter. And every time I try to compile, no matter if the project is new or not, will suffer from the error message in the topic title.
I have tried this solution ("winapifamily.h: No such file or directory" when compiling SDL in Code::Blocks) and it still prevails. I have blown the installation to start again. I have now run out of options. Can anyone tell me why this is still happening?
I am using the latest versions of MinGW, SDL and Code Blocks.
Upvotes: 3
Views: 20394
Reputation: 51
How about hardcoding the include directory to your project? winapifamily.h should be on C:\Program Files (x86)\Windows Kits\8.0\Include\shared. You can add it to the "search directories" tab in project build options.
Make sure to check the file exist in the location first. If it doesn't, you may need to install windows 8 sdk.
Upvotes: 5
Reputation: 1522
If you go through that answer you posted there is the following option:
Go to your SDL_platform.h file located in the include/SDL2 directory of your library. Replace the code with the updated header file located here
Upvotes: 0