问题
I installed FEDORA and SDL and wish to program graphics in C. on compilation, I am getting lot of undefined references to SDL_MapRGB, SDL_Init etc I searched the file system SDL.dll is missing..
how to solve this problem?
回答1:
Linux does not use .dll files for storing libraries, but .so.
Anyhow, to install SDL in fedora:
sudo yum install SDL*
This will install the complete SDL library with associated devel packages.
You will also probably want to install the Development Tools group of packages (for gcc and other build tools):
sudo yum groupinstall 'Development Tools'
When compiling, you will need to tell GCC which library to link:
gcc mycoolapp.c -o myapp -lSDL -lSDL_mixer
来源:https://stackoverflow.com/questions/8102313/installing-sdl-on-fedora