[evolution-data-server/openismus-work-master: 1/10] 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/openismus-work-master: 1/10] This patch makes google addressbook backend optional
- Date: Wed, 16 Jan 2013 08:12:51 +0000 (UTC)
commit c843e7fb67df468d4aa811648262b3c57490e748
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 911e21f..864d4f6 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])
@@ -1355,10 +1354,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)
+ 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)
@@ -1656,6 +1665,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]