aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>2009-06-30 22:57:06 +0800
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>2009-07-01 01:20:49 +0800
commit941d757434d220fec709f30ac4847c7240b3d7d3 (patch)
tree7daa8df7b406bf7262ad159c91d62024411f22af /configure.ac
parent6a1b1c8baf4c30fabd76395e6ff81fd3b7cd621d (diff)
downloadgsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.tar
gsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.tar.gz
gsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.tar.bz2
gsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.tar.lz
gsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.tar.xz
gsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.tar.zst
gsoc2013-empathy-941d757434d220fec709f30ac4847c7240b3d7d3.zip
Optionally use libnm-glib for NetworkManager integration
Previously Empathy use the NM D-Bus interface directly. Unfortunately the d-bus calls used were deprecated and somewhat buggy (if NM wasn't running on empathy startup, it would never detect network changes). Given that NetworkManager isn't a blessed gnome dependency the code has been made optional, but it's expected that every distribution will build with NetworkManager integration anyway. Based on a patch by Tambet Ingo <tambet@novell.com>. Fixes #587446
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac29
1 files changed, 28 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index df6ec7ec0..0dab5e4fc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -40,6 +40,7 @@ LIBCHAMPLAIN_GTK_REQUIRED=0.3.3
CLUTTER_GTK_REQUIRED=0.8.2
GEOCLUE_REQUIRED=0.11
WEBKIT_REQUIRED=1.1.7
+NETWORK_MANAGER_REQUIRED=0.7.0
# Use --enable-maintainer-mode to disabled deprecated symbols
GNOME_MAINTAINER_MODE_DEFINES
@@ -156,6 +157,32 @@ AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[Gettext package name])
AM_GLIB_GNU_GETTEXT
# -----------------------------------------------------------
+# NM integration
+# -----------------------------------------------------------
+AC_ARG_ENABLE(network-manager,
+ AS_HELP_STRING([--enable-network-manager=@<:@no/yes/auto@:>@],
+ [build with network-manager support]), ,
+ enable_webkit=auto)
+
+if test "x$enable_network_manager" != "xno"; then
+ PKG_CHECK_MODULES(NETWORK_MANAGER,
+ [
+ libnm_glib >= $NETWORK_MANAGER_REQUIRED
+ ], have_nm="yes", have_nm="no")
+
+ if test "x$have_nm" = "xyes"; then
+ AC_DEFINE(HAVE_NM, 1, [Define if you have libnm-glib])
+ fi
+else
+ have_nm=no
+fi
+
+if test "x$enable_network_manager" = "xyes" -a "x$have_nm" != "xyes"; then
+ AC_MSG_ERROR([Couldn't find libnm-glib dependencies.])
+fi
+AM_CONDITIONAL(HAVE_NM, test "x$have_NM" = "xyes")
+
+# -----------------------------------------------------------
# Webkit
# -----------------------------------------------------------
AC_ARG_ENABLE(webkit,
@@ -179,7 +206,6 @@ fi
if test "x$enable_webkit" = "xyes" -a "x$have_webkit" != "xyes"; then
AC_MSG_ERROR([Couldn't find webkit dependencies.])
fi
-
AM_CONDITIONAL(HAVE_WEBKIT, test "x$have_webkit" = "xyes")
# -----------------------------------------------------------
@@ -453,6 +479,7 @@ Configure summary:
Display maps (libchamplain).: ${have_libchamplain}
Location awareness (Geoclue): ${have_geoclue}
Adium themes (Webkit).......: ${have_webkit}
+ NetworkManager integration..: ${have_nm}
Extras:
Documentation...............: ${enable_gtk_doc}