I follow this tutorial (https://www.youtube.com/watch?v=fWGoPJKf97o&list=PLYokS5qr7lSsvgemrTwMSrQsdk4BRqJU6&index=3) to learn c language. Am at the end and when i complile my code i got this error 'SDL2/SDL2.h' : No such file or directory every time the \mygame\engine-from-scratch\src\engine\render/render.h file is call. my directory : and the other part :
In my main.c file #include <SDL2/SLD.h>
work but not in the render.h.
This is my linker (build.bat) :
set files=src\glad.c src\main.c src\engine\global.c src\engine\render\render.c src\engine\render_init.c
set libs=..\lib\SDL2main.lib ..\lib\SDL2.lib ..\lib\freetype.lib
CL /Zi /I ..\include %files% /link %libs% /OUT:mygame.exe
If someone have an idea why my render.h file doesn't detect my include.
The header is called SDL2/SDL.h
.
Hence, it seems you need to change
#include <SDL2/SDL2.h>
to
#include <SDL2/SDL.h>
in render.h
.