[evolution-data-server] This patch makes google addressbook backend optional
- From: Tristan Van Berkom <tvb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] This patch makes google addressbook backend optional
- Date: Thu, 17 Jan 2013 01:42:28 +0000 (UTC)
commit 4149336e72fc86be82f1e2df3e77a3aefdf1b8df
Author: Tristan Van Berkom <tristanvb openismus com>
Date: Mon Dec 17 19:51:21 2012 +0900
This patch makes google addressbook backend optional
Adds a configure option to avoid building the google backend,
making libgdata an optional dependency.
addressbook/backends/Makefile.am | 8 +++++++-
configure.ac | 22 ++++++++++++++++------
2 files changed, 23 insertions(+), 7 deletions(-)
---
diff --git a/addressbook/backends/Makefile.am b/addressbook/backends/Makefile.am
index f98bd2e..fe72ec0 100644
--- a/addressbook/backends/Makefile.am
+++ b/addressbook/backends/Makefile.am
@@ -4,6 +4,12 @@ else
LDAP_SUBDIR =
endif
-SUBDIRS = file $(LDAP_SUBDIR) google webdav
+if HAVE_GOOGLE
+GOOGLE_SUBDIR = google
+else
+GOOGLE_SUBDIR =
+endif
+
+SUBDIRS = file $(LDAP_SUBDIR) $(GOOGLE_SUBDIR) webdav
-include $(top_srcdir)/git.mk
diff --git a/configure.ac b/configure.ac
index 4423aac..675caca 100644
--- a/configure.ac
+++ b/configure.ac
@@ -364,8 +364,7 @@ PKG_CHECK_MODULES(GNOME_PLATFORM,
gmodule-2.0 >= glib_minimum_version
gtk+-3.0 >= gdk_minimum_version
libxml-2.0 >= libxml_minimum_version
- libsoup-2.4 >= soup_minimum_version
- libgdata >= libgdata_minimum_version])
+ libsoup-2.4 >= soup_minimum_version])
if test x$os_win32 = xno; then
PKG_CHECK_MODULES(GIO_UNIX, [gio-unix-2.0])
@@ -1348,10 +1347,20 @@ dnl Google flags
dnl ******************************
LIBGDATA_REQUIRED=libgdata_minimum_version
AC_SUBST(LIBGDATA_REQUIRED)
-
-EVO_SET_COMPILE_FLAGS(GDATA, libgdata)
-AC_SUBST(GDATA_CFLAGS)
-AC_SUBST(GDATA_LIBS)
+AC_ARG_ENABLE([google],
+ [AS_HELP_STRING([--enable-google],
+ [enable Google Contacts support (default=yes)])],
+ [enable_google=$enableval], [enable_google=yes])
+AC_MSG_CHECKING([if Google Contacts support is enabled])
+AC_MSG_RESULT([$enable_google])
+if test "x$enable_google" = xyes; then
+ EVO_SET_COMPILE_FLAGS(GDATA, libgdata >= libgdata_minimum_version)
+ AC_SUBST(GDATA_CFLAGS)
+ AC_SUBST(GDATA_LIBS)
+
+ AC_DEFINE(HAVE_GOOGLE, 1, [Define to 1 if you have the google-1.0 package.])
+fi
+AM_CONDITIONAL(HAVE_GOOGLE, [test x$enable_google = xyes])
EVO_SET_COMPILE_FLAGS(SOUP, libsoup-2.4)
AC_SUBST(SOUP_CFLAGS)
@@ -1649,6 +1658,7 @@ echo "
Introspection: $enable_introspection
Vala bindings: $enable_vala_bindings
GNOME Online Accounts $enable_goa
+ Google Contacts $enable_google
Code coverage (gcov): $enable_code_coverage
Strict building: $enable_strict
"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]