[gnome-terminal] Fix gdk target detection on gtk 3



commit 19c67139fbac7a285cf17be438c3859b071dd210
Author: Christian Persch <chpe gnome org>
Date:   Wed Jan 12 22:54:36 2011 +0100

    Fix gdk target detection on gtk 3

 configure.ac |   14 ++++++++++++--
 1 files changed, 12 insertions(+), 2 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index cd7112a..09c8682 100644
--- a/configure.ac
+++ b/configure.ac
@@ -66,11 +66,21 @@ case "$with_gtk" in
        ;;
 esac
 
-GDK_TARGET="$($PKG_CONFIG --variable target gdk-$GTK_API_VERSION)"
+AC_MSG_CHECKING([for GDK target])
+case "$with_gtk" in
+  2.0) GDK_TARGET="$($PKG_CONFIG --variable target gdk-$GTK_API_VERSION)" ;;
+  3.0) for target in $($PKG_CONFIG --variable targets gdk-$GTK_API_VERSION); do
+         GDK_TARGET="$target"
+         break
+       done
+       ;;
+esac
+AC_MSG_RESULT([$GDK_TARGET])
 
 case "$GDK_TARGET" in
   x11) PLATFORM_DEPS="x11" ;;
-  *) PLATFORM_DEPS="" ;;
+  win32|quartz) PLATFORM_DEPS="" ;;
+  *) AC_MSG_ERROR([unknown gdk target]) ;;
 esac
 
 PKG_CHECK_MODULES([TERM],



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]