[evolution-data-server] Bug #659756 - Initialize dbus-glib threading for GConf
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] Bug #659756 - Initialize dbus-glib threading for GConf
- Date: Fri, 16 Mar 2012 15:13:03 +0000 (UTC)
commit 990e10860a7a624edcc38241422b7ad39f2cdf45
Author: Milan Crha <mcrha redhat com>
Date: Fri Mar 16 16:12:34 2012 +0100
Bug #659756 - Initialize dbus-glib threading for GConf
configure.ac | 9 +++++++++
services/evolution-addressbook-factory/Makefile.am | 2 ++
.../evolution-addressbook-factory.c | 5 +++++
services/evolution-calendar-factory/Makefile.am | 2 ++
.../evolution-calendar-factory.c | 5 +++++
5 files changed, 23 insertions(+), 0 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index dd99bcb..94e1c1f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -348,6 +348,15 @@ if test x$os_win32 = xno; then
PKG_CHECK_MODULES(GIO_UNIX, [gio-unix-2.0])
fi
+dnl ******************************
+dnl DBus-glib stuff, to initialize thread for GConf, which is using it
+dnl this is returned back only temporarily and wil lbe removed as soon
+dnl as eds will stop using GConf completely
+dnl ******************************
+PKG_CHECK_MODULES(DBUS_GLIB, dbus-glib-1 >= 0.6)
+AC_SUBST(DBUS_GLIB_CFLAGS)
+AC_SUBST(DBUS_GLIB_LIBS)
+
dnl *******************************
dnl Check for GNOME Online Accounts
dnl *******************************
diff --git a/services/evolution-addressbook-factory/Makefile.am b/services/evolution-addressbook-factory/Makefile.am
index ff2416f..99d2d61 100644
--- a/services/evolution-addressbook-factory/Makefile.am
+++ b/services/evolution-addressbook-factory/Makefile.am
@@ -20,6 +20,7 @@ evolution_addressbook_factory_CPPFLAGS = \
-I$(top_builddir)/addressbook \
$(EVOLUTION_ADDRESSBOOK_CFLAGS) \
$(FACTORY_GTK_CFLAGS) \
+ $(DBUS_GLIB_CFLAGS) \
$(GOA_CFLAGS) \
$(NULL)
@@ -34,6 +35,7 @@ evolution_addressbook_factory_LDADD = \
$(top_builddir)/libedataserver/libedataserver-1.2.la \
$(EVOLUTION_ADDRESSBOOK_LIBS) \
$(FACTORY_GTK_LIBS) \
+ $(DBUS_GLIB_LIBS) \
$(GOA_LIBS) \
$(NULL)
diff --git a/services/evolution-addressbook-factory/evolution-addressbook-factory.c b/services/evolution-addressbook-factory/evolution-addressbook-factory.c
index 20b9dd4..aa1080d 100644
--- a/services/evolution-addressbook-factory/evolution-addressbook-factory.c
+++ b/services/evolution-addressbook-factory/evolution-addressbook-factory.c
@@ -21,6 +21,8 @@
#include <stdlib.h>
#include <glib/gi18n.h>
+#include <dbus/dbus-glib.h>
+
#ifdef ENABLE_MAINTAINER_MODE
#include <gtk/gtk.h>
#endif
@@ -104,6 +106,9 @@ main (gint argc,
g_type_init ();
#endif
+ /* this is to initialize threading for dbus-glib used by GConf */
+ dbus_g_thread_init ();
+
context = g_option_context_new (NULL);
g_option_context_add_main_entries (context, entries, GETTEXT_PACKAGE);
g_option_context_parse (context, &argc, &argv, &error);
diff --git a/services/evolution-calendar-factory/Makefile.am b/services/evolution-calendar-factory/Makefile.am
index 39bd5e4..cff7f70 100644
--- a/services/evolution-calendar-factory/Makefile.am
+++ b/services/evolution-calendar-factory/Makefile.am
@@ -20,6 +20,7 @@ evolution_calendar_factory_CPPFLAGS = \
-I$(top_builddir)/calendar \
$(EVOLUTION_CALENDAR_CFLAGS) \
$(FACTORY_GTK_CFLAGS) \
+ $(DBUS_GLIB_CFLAGS) \
$(NULL)
evolution_calendar_factory_SOURCES = \
@@ -33,6 +34,7 @@ evolution_calendar_factory_LDADD = \
$(top_builddir)/libedataserver/libedataserver-1.2.la \
$(EVOLUTION_CALENDAR_LIBS) \
$(FACTORY_GTK_LIBS) \
+ $(DBUS_GLIB_LIBS) \
$(NULL)
-include $(top_srcdir)/git.mk
diff --git a/services/evolution-calendar-factory/evolution-calendar-factory.c b/services/evolution-calendar-factory/evolution-calendar-factory.c
index eca2915..a044e62 100644
--- a/services/evolution-calendar-factory/evolution-calendar-factory.c
+++ b/services/evolution-calendar-factory/evolution-calendar-factory.c
@@ -21,6 +21,8 @@
#include <stdlib.h>
#include <glib/gi18n.h>
+#include <dbus/dbus-glib.h>
+
#ifdef ENABLE_MAINTAINER_MODE
#include <gtk/gtk.h>
#endif
@@ -108,6 +110,9 @@ main (gint argc,
g_type_init ();
#endif
+ /* this is to initialize threading for dbus-glib used by GConf */
+ dbus_g_thread_init ();
+
context = g_option_context_new (NULL);
g_option_context_add_main_entries (context, entries, GETTEXT_PACKAGE);
g_option_context_parse (context, &argc, &argv, &error);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]