If all of the above still don't work, send e-mail to the SDL mailing list with the output from the following commands run from the directory of the software that refuses to build:

If all of the above still don't work, send e-mail to the SDL [[https://discourse.libsdl.org/|mailing list]] with the output from the following commands run from the directory of the software that refuses to build:

If you are using autoconf and automake for your project, you can copy the contents of 'sdl.m4' (sdl2.m4) into your acinclude.m4 file, and then add the following to your configure.in file (for SDL 1.2):

I installed the SDL RPM, but can't compile SDL applications

I'm using nasm 0.98 and getting a crash when linking SDL

There is a bug in the nasm assembler version 0.98 - the version shipped with RedHat 7.1. You should upgrade nasm to at least version 0.98.08. If for some reason you can't upgrade, you can disable the assembly code in SDL by passing "--disable-nasm" to configure when building SDL from source.

I installed SDL from source but can't build or run SDL applications

Edit the file /etc/ld.so.conf, and make sure it contains the line:

/usr/local/lib

As root, run /sbin/ldconfig

Make sure /usr/local/bin is in your execution path:

exportPATH=$PATH:/usr/local/bin/

Make sure that there aren't any other versions of SDL on your system, and that you have removed any file named "config.cache" from the directory of the software that refuses to build.

If all of the above still don't work, send e-mail to the SDL mailing list with the output from the following commands run from the directory of the software that refuses to build:

which sdl-config

sdl-config --version

locate libSDL

tail config.log

I'm running Mandrake or Slackware and applications can't find SDL!

You probably have a version of SDL built with aRts sound support, and the KDE libraries are not installed in a system standard location. You need to add the directory containing libartsc.so.0 to the file /etc/ld.so.conf and then run the command "ldconfig". On newer versions of Mandrake, this directory is: /opt/kde/lib

How do I set an environment variable?

How to set an environment variable depends on your login shell:

For Bourne shell derivatives: (sh, ash, ksh, zsh, bash, etc.)

VARIABLE='value';export VARIABLE

For C shell derivatives: (csh, tcsh, etc.)

setenv VARIABLE 'value'

I get the error: "no video devices available"

SDL doesn't use the X11 video driver if it can't open the X display, and if no other drivers are available, it will report this error. To fix this, set your display environment variable appropriately:

sh:

DISPLAY=:0 ;export DISPLAY

csh:

setenv DISPLAY :0

If you still have problems, try running xhost + localhost Finally, if all those didn't work, and you built SDL from source, make sure that you have the X11 development libraries installed, otherwise you'll get a version of SDL that doesn't include X11 display support. After you install the X development libraries, you need to "make clean" and then rerun the configure and build process.

Some audio drivers don't properly implement select(). I added a hack to approximate the timing using timing functions, and you can enabled this by setting the environment variable SDL_DSP_NOSELECT to "1". You can also use ESounD or aRts as a high-latency sound server.

How do I disable framebuffer console acceleration?

As of SDL 1.0.3, you can set the environment variable SDL_FBACCEL to "0".

How do I enable DMA audio support?

As of SDL 1.0.4, you can set the environment variable SDL_AUDIODRIVER to "dma".

How do I turn off DGA mouse support?

As of SDL 1.0.8, you can set the environment variable SDL_VIDEO_X11_DGAMOUSE to "0".

How do I enable X11 mouse acceleration?

As of SDL 1.0.8, you can set the environment variable SDL_VIDEO_X11_MOUSEACCEL to "X/Y", where 'X' is the numerator and 'Y' is the denomenator of the mouse acceleration. For example, if you wanted to set mouse acceleration to 2, you would set the variable to "2/1". By default SDL does not change the current X11 mouse acceleration.

How do I disable XFree86 XVideo acceleration?

You can disable all YUV hardware acceleration by setting the environment variable SDL_VIDEO_YUV_HWACCEL to "0".

How do I tell SDL to default to AALib?

Building SDL: make distclean; ./configure --enable-video-aalib ; make install Running your app: set the environment variable SDL_VIDEODRIVER to "aalib".

How do I tell SDL to use the DGA 2.0 video driver?

Make sure that you have XFree86 4.01 or newer, run the program as root, set the environment variable SDL_VIDEODRIVER to "dga", and use a video card like the Voodoo 3000, Matrox G400, or any other card with a decent DGA driver.

When I specify SDL_FULLSCREEN in X11, the screen goes black and my window is centered in the middle, instead of covering the whole screen!

X needs to be able to switch to the desired resolution. For this to work, your monitor must support the resolution, and you need to have the resolution listed in your X server configuration.

The following example is taken from my config for XFree86 4.0.1, but 3.3.x is similar. Note that if your monitor isn't capable of using these video modes, the X server will drop these modes from the list of available video modes. Example: