Q:

How to install SDL?

I would like to use SDL in my programs, but I can't seem to get it working. I looked around the internet for answer, but all of them were applicable to some IDE, and those are of no help in my case as I am using Notepad++ to edit my code and compile my code using minGW through CMD.
Would someone be nice enough to provide specific steps to install SDL, or should I just give up my way of coding and switch to using IDE?

A:

The SDL documentation on their website brings you to the pre-compiled libraries, on which you find the zip file (you probably can take the newest) that contains the lib files and headers.
Extract the zip file and you get a directory called SDL. Now you can compile your code with MingW linking the libraries:
g++ -I%PROJPATH%/SDL/include -L%PROJPATH%/SDL/lib/win32 -lSDL2 -o yourprog yourcode.cpp

where %PROJPATH% is your project path that includes the SDL directory.

For compiling with external headers and libraries also see:

HOWTO Specify the Header File Include Path for use with MinGW Compilers.
HOWTO Specify the Location of Libraries for use with MinGW.

