[gnet-dev] configure.ac -- glib-1.2.x default



I've patched configure.ac so that glib-2.0 is not the default unless the
--enable-glib2 argument is passed to configure.  Patch is attached.

BTW, configure.in is no longer necessary, or even desireable: having
both of them will confuse various tools (like libtool).

M
--- gnet/configure.ac	Wed Dec 12 22:25:32 2001
+++ gnet.work/configure.ac	Wed Dec 12 22:20:48 2001
@@ -76,6 +76,10 @@
 	      [GNET_DEBUG_FLAGS="-DG_DISABLE_ASSERT -DG_DISABLE_CHECKS"])
 AC_SUBST(GNET_DEBUG_FLAGS)
 
+AC_ARG_ENABLE(glib2,
+	      AC_HELP_STRING([--enable-glib2],
+			     [prefer glib 2.0 over glib 1.2]))
+
 ###############################
 # Check for programs
 AC_PROG_CC
@@ -105,8 +109,7 @@
 fi
 AC_SUBST(pthread_libs)
 
-# Try to find glib
-if test "x${PKGCONFIG}" = "xyes"; then
+if test "x${PKGCONFIG}" = "xyes" -a "x${enable_glib2}" = "xyes"; then
 	# Check for 2.0, then 1.2
 	PKG_CHECK_MODULES(GLIB,
 			  [glib-2.0],


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