From 5368a4228ff5dd5ec95d0416f23bcfc9e556f37b Mon Sep 17 00:00:00 2001 From: aliguori Date: Tue, 3 Mar 2009 17:37:21 +0000 Subject: 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 git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6678 c046a42c-6fe2-441c-8c8c-71466251a162 --- configure | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'configure') diff --git a/configure b/configure index 62925d895d..faacb8de09 100755 --- a/configure +++ b/configure @@ -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 < +#if defined(SDL_VIDEO_DRIVER_X11) +#include +#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 -- cgit v1.2.1