diff options
author | aliguori | 2009-03-03 18:37:21 +0100 |
---|---|---|
committer | aliguori | 2009-03-03 18:37:21 +0100 |
commit | 5368a4228ff5dd5ec95d0416f23bcfc9e556f37b (patch) | |
tree | af903aa7fefee375f864d08b603c2ed5fea77b75 /configure | |
parent | Fix CVE-2008-0928 - insufficient block device address range checking (Anthony... (diff) | |
download | qemu-5368a4228ff5dd5ec95d0416f23bcfc9e556f37b.tar.gz qemu-5368a4228ff5dd5ec95d0416f23bcfc9e556f37b.tar.xz qemu-5368a4228ff5dd5ec95d0416f23bcfc9e556f37b.zip |
Fix SDL on evdev hosts (Anthony Liguori)
This patch corrects SDL support on X11 hosts using evdev. It's losely based
on the previous patch by Dustin Kirkland and the evdev support code in gtk-vnc
written by Daniel Berrange.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6678 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 18 |
1 files changed, 18 insertions, 0 deletions
@@ -187,6 +187,7 @@ kerneldir="" aix="no" blobs="yes" fdt="yes" +sdl_x11="no" # OS specific if check_define __linux__ ; then @@ -805,6 +806,21 @@ else fi fi # -z $sdl +if test "$sdl" = "yes" ; then +cat > $TMPC <<EOF +#include <SDL.h> +#if defined(SDL_VIDEO_DRIVER_X11) +#include <X11/XKBlib.h> +#else +#error No x11 support +#endif +int main(void) { return 0; } +EOF + if $cc $ARCH_CFLAGS -o $TMPE ${OS_CFLAGS} `$sdl_config --cflags 2> /dev/null` $TMPC `$sdl_config --libs 2> /dev/null` > /dev/null 2>&1 ; then + sdl_x11="yes" + fi +fi + ########################################## # VNC TLS detection if test "$vnc_tls" = "yes" ; then @@ -1393,6 +1409,8 @@ if test "$sdl1" = "yes" ; then echo "CONFIG_SDL=yes" >> $config_mak if test "$target_softmmu" = "no" -o "$static" = "yes"; then echo "SDL_LIBS=$sdl_static_libs" >> $config_mak + elif test "$sdl_x11" = "yes" ; then + echo "SDL_LIBS=`$sdl_config --libs` -lX11" >> $config_mak else echo "SDL_LIBS=`$sdl_config --libs`" >> $config_mak fi |