aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2014-05-28 22:33:06 +0200
committerGerd Hoffmann <kraxel@redhat.com>2014-06-11 14:26:49 +0200
commit0a337ed067ff56165ec952611119e808d442af05 (patch)
tree537716b03c791f8b1f47ed9c48d3bb79f693ceba /configure
parent932f2d7e0f94c144e5e64adb5934922179c1c440 (diff)
gtk: cleanup backend dependencies
Make configure detect gtk x11 backend and link libX11 then. Make gtk backend specific code properly #ifdef'ed on the GTK_WINDOWING_* backends at runtime). Our gtk ui code should build and run fine on any platform now. This also fixes the linker failute due to the new XkbGetKeyboard call added by commit 3158a3482b0093e41f2b2596fba50774ea31ae08. Cc: Richard Henderson <rth@twiddle.net> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure4
1 files changed, 4 insertions, 0 deletions
diff --git a/configure b/configure
index a994f4196f..23514ec258 100755
--- a/configure
+++ b/configure
@@ -1993,6 +1993,7 @@ fi
if test "$gtk" != "no"; then
gtkpackage="gtk+-$gtkabi"
+ gtkx11package="gtk+-x11-$gtkabi"
if test "$gtkabi" = "3.0" ; then
gtkversion="3.0.0"
else
@@ -2001,6 +2002,9 @@ if test "$gtk" != "no"; then
if $pkg_config --exists "$gtkpackage >= $gtkversion"; then
gtk_cflags=`$pkg_config --cflags $gtkpackage`
gtk_libs=`$pkg_config --libs $gtkpackage`
+ if $pkg_config --exists "$gtkx11package >= $gtkversion"; then
+ gtk_libs="$gtk_libs -lX11"
+ fi
libs_softmmu="$gtk_libs $libs_softmmu"
gtk="yes"
elif test "$gtk" = "yes"; then