gnome-session r5179 - trunk



Author: lucasr
Date: Thu Jan  8 01:41:37 2009
New Revision: 5179
URL: http://svn.gnome.org/viewvc/gnome-session?rev=5179&view=rev

Log:
2009-01-08  Lucas Rocha  <lucasr gnome org>

	Bug 551766 â Automagic dependency on PolicyKit in configure.in

	* configure.in: added support for explicit --enable-polkit and
	--disable-polkit. The default (if nothing is specified) is auto.
	Patch by Nirbheek Chauhan.

Modified:
   trunk/ChangeLog
   trunk/configure.in

Modified: trunk/configure.in
==============================================================================
--- trunk/configure.in	(original)
+++ trunk/configure.in	Thu Jan  8 01:41:37 2009
@@ -88,9 +88,19 @@
 
 PKG_CHECK_MODULES(EGG_SMCLIENT, gtk+-2.0)
 
-PKG_CHECK_MODULES(POLKIT_GNOME, polkit-gnome >= $POLKIT_GNOME_REQUIRED, have_polkit=yes, have_polkit=no)
+have_polkit=no
+AC_ARG_ENABLE([polkit],
+  AC_HELP_STRING([--enable-polkit], [Enable PolicyKit support (default auto)]),
+  enable_polkit=$enableval,
+  enable_polkit=auto)
+if test "x$enable_polkit" != "xno"; then
+  PKG_CHECK_MODULES(POLKIT_GNOME, polkit-gnome >= $POLKIT_GNOME_REQUIRED, have_polkit=yes, have_polkit=no)
+  if test "x$enable_polkit" = "xyes" -a "x$have_polkit" = "xno"; then
+    AC_MSG_ERROR([PolicyKit support explicitly requested but dependencies not found])
+  fi
+fi
 
-if test "$have_polkit" = "yes"; then
+if test "x$have_polkit" = "xyes"; then
   AC_DEFINE(HAVE_POLKIT_GNOME, [1], [whether PolKit GNOME was found])
 fi
 



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