summaryrefslogtreecommitdiff
path: root/services
diff options
context:
space:
mode:
authorTristan Van Berkom <tristanvb@openismus.com>2013-01-16 18:02:40 +0900
committerTristan Van Berkom <tristanvb@openismus.com>2013-01-17 10:47:24 +0900
commitaca5a321fd5ec0d05a72cb54ae931f2691ad6c8d (patch)
tree5e35d97877bdc61beee339cc2c86ea0a7360c7ce /services
parent4149336e72fc86be82f1e2df3e77a3aefdf1b8df (diff)
downloadevolution-data-server-aca5a321fd5ec0d05a72cb54ae931f2691ad6c8d.tar.gz
Make GTK+ a soft dependancy
This patch disables building of the user-prompter service and trust-prompt module if GTK+ is not available, allowing alternative implementations of the user prompter service to be installed on platforms where GTK+ is not available.
Diffstat (limited to 'services')
-rw-r--r--services/Makefile.am6
-rw-r--r--services/evolution-addressbook-factory/evolution-addressbook-factory.c4
-rw-r--r--services/evolution-calendar-factory/evolution-calendar-factory.c4
-rw-r--r--services/evolution-source-registry/evolution-source-registry.c4
-rw-r--r--services/evolution-user-prompter/Makefile.am12
5 files changed, 14 insertions, 16 deletions
diff --git a/services/Makefile.am b/services/Makefile.am
index f3c8447bb..affc7c9ec 100644
--- a/services/Makefile.am
+++ b/services/Makefile.am
@@ -1,10 +1,14 @@
NULL =
+if HAVE_GTK
+USER_PROMPTER_DIR = evolution-user-prompter
+endif
+
SUBDIRS = \
evolution-addressbook-factory \
evolution-calendar-factory \
evolution-source-registry \
- evolution-user-prompter \
+ $(USER_PROMPTER_DIR) \
$(NULL)
-include $(top_srcdir)/git.mk
diff --git a/services/evolution-addressbook-factory/evolution-addressbook-factory.c b/services/evolution-addressbook-factory/evolution-addressbook-factory.c
index ffb69b700..959095b66 100644
--- a/services/evolution-addressbook-factory/evolution-addressbook-factory.c
+++ b/services/evolution-addressbook-factory/evolution-addressbook-factory.c
@@ -21,7 +21,7 @@
#include <stdlib.h>
#include <glib/gi18n.h>
-#ifdef ENABLE_MAINTAINER_MODE
+#if defined (ENABLE_MAINTAINER_MODE) && defined (HAVE_GTK)
#include <gtk/gtk.h>
#endif
@@ -92,7 +92,7 @@ main (gint argc,
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
-#ifdef ENABLE_MAINTAINER_MODE
+#if defined (ENABLE_MAINTAINER_MODE) && defined (HAVE_GTK)
/* This is only to load gtk-modules, like
* bug-buddy's gnomesegvhandler, if possible */
gtk_init_check (&argc, &argv);
diff --git a/services/evolution-calendar-factory/evolution-calendar-factory.c b/services/evolution-calendar-factory/evolution-calendar-factory.c
index a80731bb3..ee40da712 100644
--- a/services/evolution-calendar-factory/evolution-calendar-factory.c
+++ b/services/evolution-calendar-factory/evolution-calendar-factory.c
@@ -21,7 +21,7 @@
#include <stdlib.h>
#include <glib/gi18n.h>
-#ifdef ENABLE_MAINTAINER_MODE
+#if defined (ENABLE_MAINTAINER_MODE) && defined (HAVE_GTK)
#include <gtk/gtk.h>
#endif
@@ -96,7 +96,7 @@ main (gint argc,
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
-#ifdef ENABLE_MAINTAINER_MODE
+#if defined (ENABLE_MAINTAINER_MODE) && defined (HAVE_GTK)
/* This is only to load gtk-modules, like
* bug-buddy's gnomesegvhandler, if possible. */
gtk_init_check (&argc, &argv);
diff --git a/services/evolution-source-registry/evolution-source-registry.c b/services/evolution-source-registry/evolution-source-registry.c
index 567052cc4..d4cc15c48 100644
--- a/services/evolution-source-registry/evolution-source-registry.c
+++ b/services/evolution-source-registry/evolution-source-registry.c
@@ -21,7 +21,7 @@
#include <stdlib.h>
#include <glib/gi18n.h>
-#ifdef ENABLE_MAINTAINER_MODE
+#if defined (ENABLE_MAINTAINER_MODE) && defined (HAVE_GTK)
#include <gtk/gtk.h>
#endif
@@ -48,7 +48,7 @@ main (gint argc,
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
-#ifdef ENABLE_MAINTAINER_MODE
+#if defined (ENABLE_MAINTAINER_MODE) && defined (HAVE_GTK)
/* This is only to load gtk-modules, like
* bug-buddy's gnomesegvhandler, if possible */
gtk_init_check (&argc, &argv);
diff --git a/services/evolution-user-prompter/Makefile.am b/services/evolution-user-prompter/Makefile.am
index 8f865cf85..941b7a4f2 100644
--- a/services/evolution-user-prompter/Makefile.am
+++ b/services/evolution-user-prompter/Makefile.am
@@ -8,15 +8,9 @@ service_DATA = $(service_in_files:.service.in=.service)
CLEANFILES = $(service_DATA)
EXTRA_DIST = $(service_in_files)
-#if USE_GTK
- PROMPT_USER_SOURCES = prompt-user-gtk.c
- PROMPT_USER_CFLAGS = $(GNOME_PLATFORM_CFLAGS)
- PROMPT_USER_LIBS = $(GNOME_PLATFORM_LIBS)
-#else
-# PROMPT_USER_SOURCES = prompt-user-.c
-# PROMPT_USER_CFLAGS = $()
-# PROMPT_USER_LIBS = $()
-#endif
+PROMPT_USER_SOURCES = prompt-user-gtk.c
+PROMPT_USER_CFLAGS = $(GNOME_PLATFORM_CFLAGS) $(GTK_CFLAGS)
+PROMPT_USER_LIBS = $(GNOME_PLATFORM_LIBS) $(GTK_LIBS)
libexec_PROGRAMS = evolution-user-prompter