[network-manager-pptp] build: enhance GTK version choice at configure time



commit 21262c0154b0a405e9f86963946412327db34fe5
Author: Dan Williams <dcbw redhat com>
Date:   Fri Feb 18 15:31:45 2011 -0600

    build: enhance GTK version choice at configure time
    
    Make the choice automatic if not overridden by the configure
    arguments.

 configure.ac |   11 ++++++++++-
 1 files changed, 10 insertions(+), 1 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 5c98eae..e737413 100644
--- a/configure.ac
+++ b/configure.ac
@@ -78,7 +78,16 @@ AC_SUBST(NM_CFLAGS)
 AC_SUBST(NM_LIBS)
 
 if test x"$with_gnome" != xno; then
-	PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.18)
+	AC_ARG_WITH([gtkver], AS_HELP_STRING([--with-gtkver], [The major version of GTK+ to build with]),
+	            with_gtkver="$withval",with_gtkver=3)
+	case "${with_gtkver}" in
+	       2) PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.20)
+	          gtkver=2
+	          ;;
+	       *) PKG_CHECK_MODULES(GTK, gtk+-3.0 >= 2.91.4)
+	          gtkver=3
+	          ;;
+	esac
 	AC_SUBST(GTK_CFLAGS)
 	AC_SUBST(GTK_LIBS)
 



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