Compile SDL/OpenGL applications using g++
This is how I compile a C++ program with SDL and the OpenGL libraries GL and GLU.
g++ -o appname opengl.cpp `sdl-config –libs –cflags` -lGL -lGLU
sdl-config –libs –cflags is used to get the library path and include path for SDL. This can be used instead of manually specifying the libraries for SDL.
1 comment