411 REFERENCE · Wikibooks
SDL (Simple DirectMedia Layer)/Basics/Getting started in Linux
Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.
Install the development libraries of SDL from the official repositories of your Linux distribution.
Terminal
$ gcc sdl.c -o sdl -lSDL2
The argument -lSDL2 means after compiling sdl.c with gcc, the binary sdl, named using the -o argument, is linked to the SDL 2 runtime libraries.
NOTE: Linking the binary to SDL 1.2 libraries requires the -lSDL argument.
To continue using the terminal to build your source, you can use GNU Make, CMake or a plain Makefile.
Code::Blocks
25%
.
-