How 2 use SDL without installing it into /usr/local/lib?

Hi, there.

I’d really like 2 try coding with SDL. The problem is: I’m not the root
on the system. Can I link the libs from my home dir? If yes, how?

Yes. Where did you install the library files?
Set the variable “SDL” in your Makefile to the directory containing
"include" and “lib” subdirectories which contain the SDL headers and
libraries respectively.

For example, if you have installed SDL in $HOME/SDL, you can add this
line to your Makefile:


This has been added to the FAQ.

-Sam Lantinga				(slouken at

Lead Programmer, Loki Entertainment Software–
Author of Simple DirectMedia Layer -