[SOLVED] I have installed SDL2; now, how to build against it?
by maschelsea from LinuxQuestions.org on (#56T0B)
I installed SDL2 from sbopkg. However, I can't seem to build against it. I updatedb and locate SDL.h and I see it in /usr/include. It's been awhile since I've set up a Linux programming environment, but I think that I should be able to use all the files under /usr/include, shouldn't I? I went into my root tab, and began making symbolic links to the files under /usr/include within /usr/include. I've run into a problem that I cannot fix this way:
Code:michael@caitlyn 1 $ make
g++ Hello_SDL.cpp -w -lSDL2 -o Hello_SDL
In file included from /usr/include/SDL_config.h:32:0,
from /usr/include/SDL_stdinc.h:31,
from /usr/include/SDL_main.h:25,
from /usr/include/SDL.h:32,
from Hello_SDL.cpp:2:
/usr/include/SDL_platform.h:179:24: fatal error: begin_code.h: No such file or directory
compilation terminated.
Makefile:19: recipe for target 'all' failed
make: *** [all] Error 1What should I do?


Code:michael@caitlyn 1 $ make
g++ Hello_SDL.cpp -w -lSDL2 -o Hello_SDL
In file included from /usr/include/SDL_config.h:32:0,
from /usr/include/SDL_stdinc.h:31,
from /usr/include/SDL_main.h:25,
from /usr/include/SDL.h:32,
from Hello_SDL.cpp:2:
/usr/include/SDL_platform.h:179:24: fatal error: begin_code.h: No such file or directory
compilation terminated.
Makefile:19: recipe for target 'all' failed
make: *** [all] Error 1What should I do?