Compare commits

...

No commits in common. 'c9' and 'cs10' have entirely different histories.
c9 ... cs10

@ -1 +1 @@
0c5875d6617a7e3a4614494fe2359a8ebb321c4b SOURCES/evolution-data-server-3.40.4.tar.xz
85fd569cd9b2476eda96a70f3efce39aacdc9746 SOURCES/evolution-data-server-3.52.4.tar.xz

2
.gitignore vendored

@ -1 +1 @@
SOURCES/evolution-data-server-3.40.4.tar.xz
SOURCES/evolution-data-server-3.52.4.tar.xz

@ -0,0 +1,659 @@
From 23c40181b44bc536f3c07aafe966167170856e9f Mon Sep 17 00:00:00 2001
From: "Owen W. Taylor" <otaylor@fishsoup.net>
Date: Mon, 20 Nov 2023 12:23:30 -0500
Subject: [PATCH] Make DBUS_SERVICES_PREFIX runtime-configurable
Rather than making DBUS_SERVICES_PREFIX a runtime config option, instead
add a config file $sysconfdir/evolution-data-server/dbus-prefix to set
the prefix and read that file both for the library and on the server
side.
Add a tool in the private libexecdir 'set-dbus-prefix' to write the
config file and edit systemd and D-Bus service files as needed.
Resolves #502
---
CMakeLists.txt | 14 +----
config.h.in | 3 -
data/org.gnome.EvolutionDataServer.Devel.json | 3 +-
src/addressbook/libebook/e-book-client.c | 3 +-
.../libedata-book/e-data-book-factory.c | 4 +-
...evolution-addressbook-factory-subprocess.c | 3 +-
src/calendar/libecal/e-cal-client.c | 3 +-
.../libedata-cal/e-data-cal-factory.c | 4 +-
.../evolution-calendar-factory-subprocess.c | 3 +-
src/libebackend/e-source-registry-server.c | 4 +-
src/libebackend/e-user-prompter-server.c | 3 +-
src/libebackend/e-user-prompter.c | 3 +-
src/libedataserver/CMakeLists.txt | 3 +
src/libedataserver/e-dbus-prefix.c | 55 +++++++++++++++++++
src/libedataserver/e-dbus-prefix.h | 26 +++++++++
src/libedataserver/e-secret-store.c | 9 +--
src/libedataserver/e-source-registry.c | 5 +-
.../e-credentials-prompter-impl-oauth2.c | 3 +-
.../secret-monitor/module-secret-monitor.c | 10 +---
.../evolution-alarm-notify/e-alarm-notify.c | 7 +--
src/tools/CMakeLists.txt | 7 +++
src/tools/oauth2-handler/CMakeLists.txt | 1 +
src/tools/oauth2-handler/oauth2-handler.c | 4 +-
src/tools/set-dbus-prefix.in | 37 +++++++++++++
24 files changed, 168 insertions(+), 49 deletions(-)
create mode 100644 src/libedataserver/e-dbus-prefix.c
create mode 100644 src/libedataserver/e-dbus-prefix.h
create mode 100644 src/tools/set-dbus-prefix.in
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e7d376add..7b77d02f5 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -38,7 +38,7 @@ set(PROJECT_DISTCONFIGURE_PARAMS
# ******************************
# D-Bus versioning
# ******************************
-# Actual name can be modified with DBUS_SERVICES_PREFIX option
+# If adding new services with service files, they also need to be added to src/tools/set-dbus-prefix.in
set(ADDRESS_BOOK_DBUS_SERVICE_NAME "org.gnome.evolution.dataserver.AddressBook10")
set(CALENDAR_DBUS_SERVICE_NAME "org.gnome.evolution.dataserver.Calendar8")
set(SOURCES_DBUS_SERVICE_NAME "org.gnome.evolution.dataserver.Sources5")
@@ -183,18 +183,6 @@ ensure_default_value(LOCALE_INSTALL_DIR "${SHARE_INSTALL_PREFIX}/locale")
ensure_default_value(SYSCONF_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/etc")
ensure_default_value(EXTENSIONS_DIR "${LIBEXEC_INSTALL_DIR}/evolution/extensions")
-add_printable_variable(DBUS_SERVICES_PREFIX "Prefix for D-Bus services, usually left empty, without trailing dot" "")
-
-if(NOT ("${DBUS_SERVICES_PREFIX}" STREQUAL ""))
- set(ADDRESS_BOOK_DBUS_SERVICE_NAME "${DBUS_SERVICES_PREFIX}.${ADDRESS_BOOK_DBUS_SERVICE_NAME}")
- set(CALENDAR_DBUS_SERVICE_NAME "${DBUS_SERVICES_PREFIX}.${CALENDAR_DBUS_SERVICE_NAME}")
- set(SOURCES_DBUS_SERVICE_NAME "${DBUS_SERVICES_PREFIX}.${SOURCES_DBUS_SERVICE_NAME}")
- set(USER_PROMPTER_DBUS_SERVICE_NAME "${DBUS_SERVICES_PREFIX}.${USER_PROMPTER_DBUS_SERVICE_NAME}")
- set(OAUTH2_RESPONSE_DBUS_SERVICE_NAME "${DBUS_SERVICES_PREFIX}.${OAUTH2_RESPONSE_DBUS_SERVICE_NAME}")
-else(NOT ("${DBUS_SERVICES_PREFIX}" STREQUAL ""))
- unset(DBUS_SERVICES_PREFIX)
-endif(NOT ("${DBUS_SERVICES_PREFIX}" STREQUAL ""))
-
# ******************************
# Special directories
# ******************************
diff --git a/config.h.in b/config.h.in
index 064873e2a..b895655a9 100644
--- a/config.h.in
+++ b/config.h.in
@@ -21,9 +21,6 @@
/* Defined to prefix where out-of-tree extensions can be installed */
#cmakedefine EXTENSIONS_DIR "@EXTENSIONS_DIR@"
-/* Defined to prefix used by the D-Bus services (usually when run in Flatpak) */
-#cmakedefine DBUS_SERVICES_PREFIX "@DBUS_SERVICES_PREFIX@"
-
/* D-Bus service name for the address book factory */
#define ADDRESS_BOOK_DBUS_SERVICE_NAME "@ADDRESS_BOOK_DBUS_SERVICE_NAME@"
diff --git a/data/org.gnome.EvolutionDataServer.Devel.json b/data/org.gnome.EvolutionDataServer.Devel.json
index c8136ec20..118e25da3 100644
--- a/data/org.gnome.EvolutionDataServer.Devel.json
+++ b/data/org.gnome.EvolutionDataServer.Devel.json
@@ -277,7 +277,6 @@
"/share/GConf"
],
"config-opts": [
- "-DDBUS_SERVICES_PREFIX=org.gnome.EvolutionDataServer.Devel",
"-DEXTENSIONS_DIR=/app/evolution/extensions",
"-DENABLE_MAINTAINER_MODE=ON",
"-DENABLE_FILE_LOCKING=fcntl",
@@ -304,6 +303,8 @@
}
],
"post-install": [
+ "/app/libexec/evolution-data-server/set-dbus-prefix org.gnome.EvolutionDataServer.Devel",
+ "sed -i s/org.gnome.evolution/org.gnome.EvolutionDataServer.Devel.org.gnome.evolution/ tests/test-server-utils/services/*.service",
"ctest --force-new-ctest-process --output-on-failure"
]
diff --git a/src/addressbook/libebook/e-book-client.c b/src/addressbook/libebook/e-book-client.c
index bd479d8f3..3738d37ce 100644
--- a/src/addressbook/libebook/e-book-client.c
+++ b/src/addressbook/libebook/e-book-client.c
@@ -40,6 +40,7 @@
#include <libedataserver/libedataserver.h>
#include <libedataserver/e-client-private.h>
+#include <libedataserver/e-dbus-prefix.h>
#include <libebackend/libebackend.h>
#include <libedata-book/libedata-book.h>
@@ -1078,7 +1079,7 @@ book_client_init_in_dbus_thread (GSimpleAsyncResult *simple,
factory_proxy = e_dbus_address_book_factory_proxy_new_sync (
connection,
G_DBUS_PROXY_FLAGS_NONE,
- ADDRESS_BOOK_DBUS_SERVICE_NAME,
+ e_dbus_prefix (ADDRESS_BOOK_DBUS_SERVICE_NAME),
"/org/gnome/evolution/dataserver/AddressBookFactory",
cancellable, &local_error);
diff --git a/src/addressbook/libedata-book/e-data-book-factory.c b/src/addressbook/libedata-book/e-data-book-factory.c
index 02adb19b4..a9d89d82e 100644
--- a/src/addressbook/libedata-book/e-data-book-factory.c
+++ b/src/addressbook/libedata-book/e-data-book-factory.c
@@ -41,6 +41,8 @@
#include "e-data-book-factory.h"
#include "e-system-locale-watcher.h"
+#include "libedataserver/e-dbus-prefix.h"
+
#define d(x)
struct _EDataBookFactoryPrivate {
@@ -315,7 +317,7 @@ e_data_book_factory_class_init (EDataBookFactoryClass *class)
object_class->dispose = data_book_factory_dispose;
dbus_server_class = E_DBUS_SERVER_CLASS (class);
- dbus_server_class->bus_name = ADDRESS_BOOK_DBUS_SERVICE_NAME;
+ dbus_server_class->bus_name = e_dbus_prefix (ADDRESS_BOOK_DBUS_SERVICE_NAME);
dbus_server_class->module_directory = modules_directory;
data_factory_class = E_DATA_FACTORY_CLASS (class);
diff --git a/src/addressbook/libedata-book/evolution-addressbook-factory-subprocess.c b/src/addressbook/libedata-book/evolution-addressbook-factory-subprocess.c
index 3897042e6..ef539573d 100644
--- a/src/addressbook/libedata-book/evolution-addressbook-factory-subprocess.c
+++ b/src/addressbook/libedata-book/evolution-addressbook-factory-subprocess.c
@@ -28,6 +28,7 @@
#include <e-dbus-subprocess-backend.h>
#include <libebackend/libebackend.h>
#include <libedataserver/libedataserver.h>
+#include <libedataserver/e-dbus-prefix.h>
#include <libedata-book/libedata-book.h>
typedef struct _SubprocessData SubprocessData;
@@ -198,7 +199,7 @@ main (gint argc,
/* Watch the factory name and close the subprocess if the factory dies/crashes */
watched_id = g_bus_watch_name (
G_BUS_TYPE_SESSION,
- ADDRESS_BOOK_DBUS_SERVICE_NAME,
+ e_dbus_prefix (ADDRESS_BOOK_DBUS_SERVICE_NAME),
G_BUS_NAME_WATCHER_FLAGS_NONE,
NULL,
(GBusNameVanishedCallback) vanished_cb,
diff --git a/src/calendar/libecal/e-cal-client.c b/src/calendar/libecal/e-cal-client.c
index d0414e4c7..fd6665db5 100644
--- a/src/calendar/libecal/e-cal-client.c
+++ b/src/calendar/libecal/e-cal-client.c
@@ -36,6 +36,7 @@
#include <e-dbus-calendar-factory.h>
#include <libedataserver/e-client-private.h>
+#include <libedataserver/e-dbus-prefix.h>
#include "e-cal-client.h"
#include "e-cal-component.h"
@@ -1211,7 +1212,7 @@ cal_client_init_in_dbus_thread (GSimpleAsyncResult *simple,
factory_proxy = e_dbus_calendar_factory_proxy_new_sync (
connection,
G_DBUS_PROXY_FLAGS_NONE,
- CALENDAR_DBUS_SERVICE_NAME,
+ e_dbus_prefix (CALENDAR_DBUS_SERVICE_NAME),
"/org/gnome/evolution/dataserver/CalendarFactory",
cancellable, &local_error);
diff --git a/src/calendar/libedata-cal/e-data-cal-factory.c b/src/calendar/libedata-cal/e-data-cal-factory.c
index e0790e17d..1e4c5e56d 100644
--- a/src/calendar/libedata-cal/e-data-cal-factory.c
+++ b/src/calendar/libedata-cal/e-data-cal-factory.c
@@ -47,6 +47,8 @@
#include "e-data-cal.h"
#include "e-data-cal-factory.h"
+#include "libedataserver/e-dbus-prefix.h"
+
#include <libical-glib/libical-glib.h>
#define d(x)
@@ -270,7 +272,7 @@ e_data_cal_factory_class_init (EDataCalFactoryClass *class)
overwrite_subprocess_cal_path = g_strdup (subprocess_cal_path_env);
dbus_server_class = E_DBUS_SERVER_CLASS (class);
- dbus_server_class->bus_name = CALENDAR_DBUS_SERVICE_NAME;
+ dbus_server_class->bus_name = e_dbus_prefix (CALENDAR_DBUS_SERVICE_NAME);
dbus_server_class->module_directory = modules_directory;
data_factory_class = E_DATA_FACTORY_CLASS (class);
diff --git a/src/calendar/libedata-cal/evolution-calendar-factory-subprocess.c b/src/calendar/libedata-cal/evolution-calendar-factory-subprocess.c
index 29732fc6e..514d50e2e 100644
--- a/src/calendar/libedata-cal/evolution-calendar-factory-subprocess.c
+++ b/src/calendar/libedata-cal/evolution-calendar-factory-subprocess.c
@@ -28,6 +28,7 @@
#include <e-dbus-subprocess-backend.h>
#include <libebackend/libebackend.h>
#include <libedataserver/libedataserver.h>
+#include <libedataserver/e-dbus-prefix.h>
#include <libedata-cal/libedata-cal.h>
typedef struct _SubprocessData SubprocessData;
@@ -198,7 +199,7 @@ main (gint argc,
/* Watch the factory name and close the subprocess if the factory dies/crashes */
watched_id = g_bus_watch_name (
G_BUS_TYPE_SESSION,
- CALENDAR_DBUS_SERVICE_NAME,
+ e_dbus_prefix (CALENDAR_DBUS_SERVICE_NAME),
G_BUS_NAME_WATCHER_FLAGS_NONE,
NULL,
(GBusNameVanishedCallback) vanished_cb,
diff --git a/src/libebackend/e-source-registry-server.c b/src/libebackend/e-source-registry-server.c
index 4fe4759a5..fe34a7921 100644
--- a/src/libebackend/e-source-registry-server.c
+++ b/src/libebackend/e-source-registry-server.c
@@ -36,6 +36,8 @@
#include <string.h>
#include <glib/gi18n-lib.h>
+#include <libedataserver/e-dbus-prefix.h>
+
/* Private D-Bus classes. */
#include "e-dbus-source.h"
#include "e-dbus-source-manager.h"
@@ -1082,7 +1084,7 @@ e_source_registry_server_class_init (ESourceRegistryServerClass *class)
object_class->finalize = source_registry_server_finalize;
dbus_server_class = E_DBUS_SERVER_CLASS (class);
- dbus_server_class->bus_name = SOURCES_DBUS_SERVICE_NAME;
+ dbus_server_class->bus_name = e_dbus_prefix (SOURCES_DBUS_SERVICE_NAME);
dbus_server_class->module_directory = modules_directory;
dbus_server_class->bus_acquired = source_registry_server_bus_acquired;
dbus_server_class->quit_server = source_registry_server_quit_server;
diff --git a/src/libebackend/e-user-prompter-server.c b/src/libebackend/e-user-prompter-server.c
index f9febd77f..4357ebc90 100644
--- a/src/libebackend/e-user-prompter-server.c
+++ b/src/libebackend/e-user-prompter-server.c
@@ -29,6 +29,7 @@
#include <glib/gi18n-lib.h>
#include <libedataserver/libedataserver.h>
+#include <libedataserver/e-dbus-prefix.h>
/* Private D-Bus classes. */
#include "e-dbus-user-prompter.h"
@@ -409,7 +410,7 @@ e_user_prompter_server_class_init (EUserPrompterServerClass *class)
object_class->finalize = user_prompter_server_finalize;
dbus_server_class = E_DBUS_SERVER_CLASS (class);
- dbus_server_class->bus_name = USER_PROMPTER_DBUS_SERVICE_NAME;
+ dbus_server_class->bus_name = e_dbus_prefix (USER_PROMPTER_DBUS_SERVICE_NAME);
dbus_server_class->module_directory = MODULE_DIRECTORY;
dbus_server_class->bus_acquired = user_prompter_server_bus_acquired;
dbus_server_class->quit_server = user_prompter_server_quit_server;
diff --git a/src/libebackend/e-user-prompter.c b/src/libebackend/e-user-prompter.c
index 054a8b44f..3c3cb5761 100644
--- a/src/libebackend/e-user-prompter.c
+++ b/src/libebackend/e-user-prompter.c
@@ -26,6 +26,7 @@
#include "evolution-data-server-config.h"
#include <libedataserver/libedataserver.h>
+#include <libedataserver/e-dbus-prefix.h>
#include "e-dbus-user-prompter.h"
#include "e-user-prompter.h"
@@ -251,7 +252,7 @@ user_prompter_prompt_thread (GSimpleAsyncResult *simple,
dbus_prompter = e_dbus_user_prompter_proxy_new_for_bus_sync (
G_BUS_TYPE_SESSION,
G_DBUS_PROXY_FLAGS_NONE,
- USER_PROMPTER_DBUS_SERVICE_NAME,
+ e_dbus_prefix (USER_PROMPTER_DBUS_SERVICE_NAME),
"/org/gnome/evolution/dataserver/UserPrompter",
cancellable,
&local_error);
diff --git a/src/libedataserver/CMakeLists.txt b/src/libedataserver/CMakeLists.txt
index 5ccb29b56..22e9f0c6d 100644
--- a/src/libedataserver/CMakeLists.txt
+++ b/src/libedataserver/CMakeLists.txt
@@ -53,6 +53,8 @@ set(SOURCES
e-client-private.h
e-collator.c
e-credentials.c
+ e-dbus-prefix.c
+ e-dbus-prefix.h
e-extensible.c
e-extension.c
e-flag.c
@@ -250,6 +252,7 @@ target_compile_definitions(edataserver PRIVATE
-DE_DATA_SERVER_PREFIX=\"${CMAKE_INSTALL_PREFIX}\"
-DE_DATA_SERVER_LOCALEDIR=\"${LOCALE_INSTALL_DIR}\"
-DE_DATA_SERVER_IMAGESDIR=\"${imagesdir}\"
+ -DE_DATA_SERVER_SYSCONFDIR=\"${SYSCONF_INSTALL_DIR}\"
-DE_DATA_SERVER_CREDENTIALMODULEDIR=\"${credentialmoduledir}\"
-DE_DATA_SERVER_UIMODULEDIR=\"${uimoduledir}\"
-DE_DATA_SERVER_PRIVDATADIR=\"${privdatadir}\"
diff --git a/src/libedataserver/e-dbus-prefix.c b/src/libedataserver/e-dbus-prefix.c
new file mode 100644
index 000000000..7018f2396
--- /dev/null
+++ b/src/libedataserver/e-dbus-prefix.c
@@ -0,0 +1,55 @@
+/* Copyright 2023 Red Hat, Inc. (www.redhat.com)
+ *
+ * This library is free software: you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
+ * for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+#include "evolution-data-server-config.h"
+
+#include <glib.h>
+
+#include "e-dbus-prefix.h"
+
+static char *
+read_prefix (gpointer data)
+{
+ char *contents;
+
+ if (g_file_get_contents (E_DATA_SERVER_SYSCONFDIR "/evolution-data-server/dbus-prefix",
+ &contents, NULL, NULL)) {
+ g_strstrip (contents);
+ return contents;
+ } else {
+ return NULL;
+ }
+}
+
+const char *
+e_dbus_prefix (const char *base)
+{
+ static GOnce read_prefix_once = G_ONCE_INIT;
+ const char *prefix;
+
+ g_once (&read_prefix_once, (GThreadFunc)read_prefix, NULL);
+ prefix = read_prefix_once.retval;
+
+ if (prefix) {
+ char *prefixed = g_strconcat (prefix, ".", base, NULL);
+ const char *result = g_intern_string (prefixed);
+ g_free (prefixed);
+
+ return result;
+ } else {
+ return base;
+ }
+}
diff --git a/src/libedataserver/e-dbus-prefix.h b/src/libedataserver/e-dbus-prefix.h
new file mode 100644
index 000000000..e8298b3fd
--- /dev/null
+++ b/src/libedataserver/e-dbus-prefix.h
@@ -0,0 +1,26 @@
+/* Copyright 2023 Red Hat, Inc. (www.redhat.com)
+ *
+ * This library is free software: you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
+ * for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+#ifndef E_DBUS_PREFIX
+#define E_DBUS_PREFIX
+
+G_BEGIN_DECLS
+
+const char *e_dbus_prefix (const char *base);
+
+G_END_DECLS
+
+#endif /* E_DBUS_PREFIX */
diff --git a/src/libedataserver/e-secret-store.c b/src/libedataserver/e-secret-store.c
index e15148227..94c4216e5 100644
--- a/src/libedataserver/e-secret-store.c
+++ b/src/libedataserver/e-secret-store.c
@@ -35,6 +35,7 @@
#include <libsecret/secret.h>
#endif
+#include "e-dbus-prefix.h"
#include "e-data-server-util.h"
#include "e-secret-store.h"
@@ -254,12 +255,6 @@ e_win32_secret_delete_secret_sync (const gchar *uid,
#define KEYRING_ITEM_ATTRIBUTE_UID "e-source-uid"
#define KEYRING_ITEM_ATTRIBUTE_ORIGIN "eds-origin"
-#ifdef DBUS_SERVICES_PREFIX
-#define ORIGIN_KEY DBUS_SERVICES_PREFIX "." PACKAGE
-#else
-#define ORIGIN_KEY PACKAGE
-#endif
-
static SecretSchema password_schema = {
"org.gnome.Evolution.Data.Source",
SECRET_SCHEMA_DONT_MATCH_NAME,
@@ -322,7 +317,7 @@ e_secret_store_store_sync (const gchar *uid,
collection, label, secret,
cancellable, error,
KEYRING_ITEM_ATTRIBUTE_UID, uid,
- KEYRING_ITEM_ATTRIBUTE_ORIGIN, ORIGIN_KEY,
+ KEYRING_ITEM_ATTRIBUTE_ORIGIN, e_dbus_prefix (PACKAGE),
NULL);
#endif
diff --git a/src/libedataserver/e-source-registry.c b/src/libedataserver/e-source-registry.c
index 4a9b398ca..9d1c98b49 100644
--- a/src/libedataserver/e-source-registry.c
+++ b/src/libedataserver/e-source-registry.c
@@ -51,6 +51,7 @@
#include "e-dbus-source-manager.h"
#include "e-data-server-util.h"
+#include "e-dbus-prefix.h"
#include "e-source-collection.h"
#include "e-source-enumtypes.h"
@@ -1091,7 +1092,7 @@ source_registry_object_manager_thread (gpointer data)
object_manager = e_dbus_object_manager_client_new_for_bus_sync (
G_BUS_TYPE_SESSION,
G_DBUS_OBJECT_MANAGER_CLIENT_FLAGS_NONE,
- SOURCES_DBUS_SERVICE_NAME,
+ e_dbus_prefix (SOURCES_DBUS_SERVICE_NAME),
DBUS_OBJECT_PATH,
NULL, &closure->error);
@@ -1472,7 +1473,7 @@ source_registry_initable_init (GInitable *initable,
e_dbus_source_manager_proxy_new_for_bus_sync (
G_BUS_TYPE_SESSION,
G_DBUS_PROXY_FLAGS_NONE,
- SOURCES_DBUS_SERVICE_NAME,
+ e_dbus_prefix (SOURCES_DBUS_SERVICE_NAME),
DBUS_OBJECT_PATH,
cancellable, &local_error);
diff --git a/src/libedataserverui/e-credentials-prompter-impl-oauth2.c b/src/libedataserverui/e-credentials-prompter-impl-oauth2.c
index b82715917..183b6aa27 100644
--- a/src/libedataserverui/e-credentials-prompter-impl-oauth2.c
+++ b/src/libedataserverui/e-credentials-prompter-impl-oauth2.c
@@ -23,6 +23,7 @@
#include <gtk/gtk.h>
#include <libedataserver/libedataserver.h>
+#include <libedataserver/e-dbus-prefix.h>
#include "libedataserverui-private.h"
#include "e-dbus-oauth2-response.h"
@@ -893,7 +894,7 @@ cpi_oauth2_maybe_prepare_oauth2_service (ECredentialsPrompterImplOAuth2 *prompte
prompter_oauth2->priv->bus_owner_id = g_bus_own_name (
G_BUS_TYPE_SESSION,
- OAUTH2_RESPONSE_DBUS_SERVICE_NAME,
+ e_dbus_prefix (OAUTH2_RESPONSE_DBUS_SERVICE_NAME),
G_BUS_NAME_OWNER_FLAGS_DO_NOT_QUEUE,
cpi_oauth2_bus_acquired_cb,
NULL,
diff --git a/src/modules/secret-monitor/module-secret-monitor.c b/src/modules/secret-monitor/module-secret-monitor.c
index 0eb21669d..5ec7e376c 100644
--- a/src/modules/secret-monitor/module-secret-monitor.c
+++ b/src/modules/secret-monitor/module-secret-monitor.c
@@ -24,6 +24,8 @@
#include <libebackend/libebackend.h>
+#include <libedataserver/e-dbus-prefix.h>
+
/* Standard GObject macros */
#define E_TYPE_SECRET_MONITOR \
(e_secret_monitor_get_type ())
@@ -57,12 +59,6 @@ struct _ESecretMonitorClass {
#define KEYRING_ITEM_ATTRIBUTE_ORIGIN "eds-origin"
#define KEYRING_ITEM_DISPLAY_FORMAT "Evolution Data Source '%s'"
-#ifdef DBUS_SERVICES_PREFIX
-#define ORIGIN_KEY DBUS_SERVICES_PREFIX "." PACKAGE
-#else
-#define ORIGIN_KEY PACKAGE
-#endif
-
static SecretSchema password_schema = {
"org.gnome.Evolution.Data.Source",
SECRET_SCHEMA_DONT_MATCH_NAME,
@@ -110,7 +106,7 @@ secret_monitor_scan_secrets_thread (gpointer user_data)
server = E_SOURCE_REGISTRY_SERVER (user_data);
attributes = g_hash_table_new (g_str_hash, g_str_equal);
- g_hash_table_insert (attributes, (gpointer) KEYRING_ITEM_ATTRIBUTE_ORIGIN, (gpointer) ORIGIN_KEY);
+ g_hash_table_insert (attributes, (gpointer) KEYRING_ITEM_ATTRIBUTE_ORIGIN, (gpointer) e_dbus_prefix (PACKAGE));
/* List all items under our custom SecretSchema. */
list = secret_service_search_sync (
diff --git a/src/services/evolution-alarm-notify/e-alarm-notify.c b/src/services/evolution-alarm-notify/e-alarm-notify.c
index a1116ec9b..1fa205366 100644
--- a/src/services/evolution-alarm-notify/e-alarm-notify.c
+++ b/src/services/evolution-alarm-notify/e-alarm-notify.c
@@ -31,14 +31,11 @@
#include "libecal/libecal.h"
#include "libedataserverui/libedataserverui.h"
+#include "libedataserver/e-dbus-prefix.h"
#include "e-alarm-notify.h"
-#ifdef DBUS_SERVICES_PREFIX
-#define APPLICATION_ID DBUS_SERVICES_PREFIX "." "org.gnome.Evolution-alarm-notify"
-#else
#define APPLICATION_ID "org.gnome.Evolution-alarm-notify"
-#endif
struct _EAlarmNotifyPrivate {
ESourceRegistry *registry;
@@ -1272,7 +1269,7 @@ e_alarm_notify_new (GCancellable *cancellable,
{
return g_initable_new (
E_TYPE_ALARM_NOTIFY, cancellable, error,
- "application-id", APPLICATION_ID,
+ "application-id", e_dbus_prefix (APPLICATION_ID),
#if GLIB_CHECK_VERSION(2, 60, 0)
"flags", G_APPLICATION_ALLOW_REPLACEMENT,
#endif
diff --git a/src/tools/CMakeLists.txt b/src/tools/CMakeLists.txt
index e8c70b298..cdcd4971d 100644
--- a/src/tools/CMakeLists.txt
+++ b/src/tools/CMakeLists.txt
@@ -1,3 +1,10 @@
add_subdirectory(addressbook-export)
add_subdirectory(list-sources)
add_subdirectory(oauth2-handler)
+
+configure_file(set-dbus-prefix.in set-dbus-prefix @ONLY)
+
+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/set-dbus-prefix
+ DESTINATION ${privlibexecdir}
+ PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
+)
diff --git a/src/tools/oauth2-handler/CMakeLists.txt b/src/tools/oauth2-handler/CMakeLists.txt
index 643733d89..0f154c9d0 100644
--- a/src/tools/oauth2-handler/CMakeLists.txt
+++ b/src/tools/oauth2-handler/CMakeLists.txt
@@ -1,4 +1,5 @@
set(DEPENDENCIES
+ edataserver
edbus-private
)
diff --git a/src/tools/oauth2-handler/oauth2-handler.c b/src/tools/oauth2-handler/oauth2-handler.c
index 952d16fb1..7622293c7 100644
--- a/src/tools/oauth2-handler/oauth2-handler.c
+++ b/src/tools/oauth2-handler/oauth2-handler.c
@@ -9,6 +9,8 @@
#include <glib.h>
#include <gio/gio.h>
+#include <libedataserver/e-dbus-prefix.h>
+
#include "e-dbus-oauth2-response.h"
static const gchar *glob_uri = NULL;
@@ -73,7 +75,7 @@ got_bus_cb (GObject *source_object,
G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES |
G_DBUS_PROXY_FLAGS_DO_NOT_CONNECT_SIGNALS |
G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START,
- OAUTH2_RESPONSE_DBUS_SERVICE_NAME,
+ e_dbus_prefix (OAUTH2_RESPONSE_DBUS_SERVICE_NAME),
"/org/gnome/evolution/dataserver/OAuth2Response",
NULL,
proxy_created_cb,
diff --git a/src/tools/set-dbus-prefix.in b/src/tools/set-dbus-prefix.in
new file mode 100644
index 000000000..2e79e4855
--- /dev/null
+++ b/src/tools/set-dbus-prefix.in
@@ -0,0 +1,37 @@
+#!/bin/sh
+
+set -ex
+
+dbus_services_prefix="$1"
+
+mkdir -p "@SYSCONF_INSTALL_DIR@/evolution-data-server"
+echo "$dbus_services_prefix" > "@SYSCONF_INSTALL_DIR@/evolution-data-server/dbus-prefix"
+
+edit_file() {
+ sed "s/org.gnome.evolution/${dbus_services_prefix}.org.gnome.evolution/" "$1" > "$1.new" && mv "$1.new" "$1"
+}
+
+SYSTEMD_SERVICE_FILES="
+evolution-addressbook-factory.service
+evolution-calendar-factory.service
+evolution-source-registry.service
+evolution-user-prompter.service
+"
+
+if [ "@WITH_SYSTEMD_USER_UNITS@" = ON ] ; then
+ for f in $SYSTEMD_SERVICE_FILES ; do
+ edit_file "@WITH_SYSTEMDUSERUNITDIR@/$f"
+ done
+fi
+
+DBUS_SERVICE_FILES="
+@ADDRESS_BOOK_DBUS_SERVICE_NAME@.service
+@CALENDAR_DBUS_SERVICE_NAME@.service
+@SOURCES_DBUS_SERVICE_NAME@.service
+@USER_PROMPTER_DBUS_SERVICE_NAME@.service
+"
+
+for f in $DBUS_SERVICE_FILES ; do
+ edit_file "@WITH_DBUS_SERVICE_DIR@/$f"
+ mv "@WITH_DBUS_SERVICE_DIR@/$f" "@WITH_DBUS_SERVICE_DIR@/${dbus_services_prefix}.$f"
+done
--
2.41.0

@ -1,36 +0,0 @@
From ad616bafcf7df22d265f7254c82ec285252bf1e7 Mon Sep 17 00:00:00 2001
From: Milan Crha <mcrha@redhat.com>
Date: Tue, 24 May 2022 18:27:09 +0200
Subject: [PATCH] I#359 - CalDAV: Crash on calendar update
Closes https://gitlab.gnome.org/GNOME/evolution-data-server/-/issues/359
---
src/calendar/backends/caldav/e-cal-backend-caldav.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/calendar/backends/caldav/e-cal-backend-caldav.c b/src/calendar/backends/caldav/e-cal-backend-caldav.c
index c8aeb8205..2aeed3c91 100644
--- a/src/calendar/backends/caldav/e-cal-backend-caldav.c
+++ b/src/calendar/backends/caldav/e-cal-backend-caldav.c
@@ -545,7 +545,8 @@ ecb_caldav_multiget_from_sets_sync (ECalBackendCalDAV *cbdav,
link = *in_link;
while (link && left_to_go > 0) {
- ECalMetaBackendInfo *nfo = link->data;
+ GSList *nfo_link = link;
+ ECalMetaBackendInfo *nfo = nfo_link->data;
link = g_slist_next (link);
if (!link) {
@@ -635,7 +636,7 @@ ecb_caldav_multiget_from_sets_sync (ECalBackendCalDAV *cbdav,
else
e_cal_meta_backend_info_free (nfo);
- link->data = NULL;
+ nfo_link->data = NULL;
g_clear_error (&local_error);
continue;
} else if (local_error) {
--
2.35.1

@ -1,116 +0,0 @@
From 08ec37272bb945625daed7e6ae7ed2bd663cdabd Mon Sep 17 00:00:00 2001
From: Milan Crha <mcrha@redhat.com>
Date: Wed, 4 May 2022 15:30:49 +0200
Subject: [PATCH] I#388 - Google OAuth out-of-band (oob) flow will be
deprecated
Closes https://gitlab.gnome.org/GNOME/evolution-data-server/-/issues/388
---
src/libedataserver/e-oauth2-service-google.c | 62 +++++++++++++++++---
1 file changed, 55 insertions(+), 7 deletions(-)
diff --git a/src/libedataserver/e-oauth2-service-google.c b/src/libedataserver/e-oauth2-service-google.c
index 4d262d32f..93af1cb0b 100644
--- a/src/libedataserver/e-oauth2-service-google.c
+++ b/src/libedataserver/e-oauth2-service-google.c
@@ -24,6 +24,7 @@
#include "e-oauth2-service-google.h"
/* https://developers.google.com/identity/protocols/OAuth2InstalledApp */
+/* https://developers.google.com/identity/protocols/oauth2/native-app */
/* Forward Declarations */
static void e_oauth2_service_google_oauth2_service_init (EOAuth2ServiceInterface *iface);
@@ -122,14 +123,60 @@ static const gchar *
eos_google_get_authentication_uri (EOAuth2Service *service,
ESource *source)
{
- return "https://accounts.google.com/o/oauth2/auth";
+ return "https://accounts.google.com/o/oauth2/v2/auth";
}
static const gchar *
eos_google_get_refresh_uri (EOAuth2Service *service,
ESource *source)
{
- return "https://www.googleapis.com/oauth2/v3/token";
+ return "https://oauth2.googleapis.com/token";
+}
+
+static const gchar *
+eos_google_get_redirect_uri (EOAuth2Service *service,
+ ESource *source)
+{
+ G_LOCK_DEFINE_STATIC (redirect_uri);
+ const gchar *key_name = "oauth2-google-redirect-uri";
+ gchar *value;
+
+ G_LOCK (redirect_uri);
+
+ value = g_object_get_data (G_OBJECT (service), key_name);
+ if (!value) {
+ const gchar *client_id = eos_google_get_client_id (service, source);
+
+ if (client_id) {
+ GPtrArray *array;
+ gchar **strv;
+ gchar *joinstr;
+ guint ii;
+
+ strv = g_strsplit (client_id, ".", -1);
+ array = g_ptr_array_new ();
+
+ for (ii = 0; strv[ii]; ii++) {
+ g_ptr_array_insert (array, 0, strv[ii]);
+ }
+
+ g_ptr_array_add (array, NULL);
+
+ joinstr = g_strjoinv (".", (gchar **) array->pdata);
+ /* Use reverse-DNS of the client ID with the below path */
+ value = g_strconcat (joinstr, ":/oauth2redirect", NULL);
+
+ g_ptr_array_free (array, TRUE);
+ g_strfreev (strv);
+ g_free (joinstr);
+
+ g_object_set_data_full (G_OBJECT (service), key_name, value, g_free);
+ }
+ }
+
+ G_UNLOCK (redirect_uri);
+
+ return value;
}
static void
@@ -191,13 +238,13 @@ eos_google_extract_authorization_code (EOAuth2Service *service,
params = soup_form_decode (query);
if (params) {
- const gchar *response;
+ const gchar *code;
- response = g_hash_table_lookup (params, "response");
- if (response && g_ascii_strncasecmp (response, "code=", 5) == 0) {
- *out_authorization_code = g_strdup (response + 5);
+ code = g_hash_table_lookup (params, "code");
+ if (code && *code) {
+ *out_authorization_code = g_strdup (code);
known = TRUE;
- } else if (response && g_ascii_strncasecmp (response, "error", 5) == 0) {
+ } else if (g_hash_table_lookup (params, "error")) {
known = TRUE;
}
@@ -225,6 +272,7 @@ e_oauth2_service_google_oauth2_service_init (EOAuth2ServiceInterface *iface)
iface->get_client_secret = eos_google_get_client_secret;
iface->get_authentication_uri = eos_google_get_authentication_uri;
iface->get_refresh_uri = eos_google_get_refresh_uri;
+ iface->get_redirect_uri = eos_google_get_redirect_uri;
iface->prepare_authentication_uri_query = eos_google_prepare_authentication_uri_query;
iface->extract_authorization_code = eos_google_extract_authorization_code;
}
--
2.35.1

@ -1,49 +0,0 @@
diff --git a/src/calendar/backends/file/e-cal-backend-file.c b/src/calendar/backends/file/e-cal-backend-file.c
index f40bf807c..79ae53632 100644
--- a/src/calendar/backends/file/e-cal-backend-file.c
+++ b/src/calendar/backends/file/e-cal-backend-file.c
@@ -904,6 +904,7 @@ scan_vcalendar (ECalBackendFile *cbfile)
if (e_cal_component_set_icalcomponent (comp, icomp)) {
/* Thus it's not freed while being used in the 'comp' */
g_object_ref (icomp);
+ i_cal_object_set_owner (I_CAL_OBJECT (icomp), G_OBJECT (priv->vcalendar));
check_dup_uid (cbfile, comp);
diff --git a/src/calendar/backends/http/e-cal-backend-http.c b/src/calendar/backends/http/e-cal-backend-http.c
index a7e930ca0..bfe9b4554 100644
--- a/src/calendar/backends/http/e-cal-backend-http.c
+++ b/src/calendar/backends/http/e-cal-backend-http.c
@@ -477,13 +477,18 @@ ecb_http_get_changes_sync (ECalMetaBackend *meta_backend,
} else {
iter = i_cal_component_begin_component (maincomp, I_CAL_VCALENDAR_COMPONENT);
subcomp = i_cal_comp_iter_deref (iter);
+ if (subcomp)
+ i_cal_object_set_owner (I_CAL_OBJECT (subcomp), G_OBJECT (maincomp));
}
while (subcomp && success) {
ICalComponent *next_subcomp = NULL;
- if (iter)
+ if (iter) {
next_subcomp = i_cal_comp_iter_next (iter);
+ if (next_subcomp)
+ i_cal_object_set_owner (I_CAL_OBJECT (next_subcomp), G_OBJECT (maincomp));
+ }
if (i_cal_component_isa (subcomp) == I_CAL_VCALENDAR_COMPONENT) {
success = e_cal_meta_backend_gather_timezones_sync (meta_backend, subcomp, TRUE, cancellable, error);
diff --git a/src/calendar/libecal/e-cal-component.c b/src/calendar/libecal/e-cal-component.c
index a3dddcc8f..c7629813a 100644
--- a/src/calendar/libecal/e-cal-component.c
+++ b/src/calendar/libecal/e-cal-component.c
@@ -95,6 +95,8 @@ foreach_subcomponent (ICalComponent *icalcomp,
while (subcomp) {
ICalComponent *next_subcomp;
+ i_cal_object_set_owner (I_CAL_OBJECT (subcomp), G_OBJECT (icalcomp));
+
next_subcomp = i_cal_comp_iter_next (iter);
if (!func (icalcomp, subcomp, user_data)) {

@ -1,21 +0,0 @@
diff -up evolution-data-server-3.28.5/src/modules/secret-monitor/module-secret-monitor.c.secret-monitor-warnings evolution-data-server-3.28.5/src/modules/secret-monitor/module-secret-monitor.c
--- evolution-data-server-3.28.5/src/modules/secret-monitor/module-secret-monitor.c.secret-monitor-warnings 2018-07-30 15:17:06.000000000 +0200
+++ evolution-data-server-3.28.5/src/modules/secret-monitor/module-secret-monitor.c 2021-11-22 12:52:08.683986536 +0100
@@ -167,7 +167,7 @@ secret_monitor_scan_secrets_thread (gpoi
g_list_free_full (list, (GDestroyNotify) g_object_unref);
if (local_error != NULL) {
- g_warning ("%s: %s", G_STRFUNC, local_error->message);
+ e_source_registry_debug_print ("%s: %s", G_STRFUNC, local_error->message);
g_error_free (local_error);
}
@@ -206,7 +206,7 @@ secret_monitor_scan_secrets_timeout_cb (
g_thread_unref (thread);
if (local_error != NULL) {
- g_warning ("%s: %s", G_STRFUNC, local_error->message);
+ e_source_registry_debug_print ("%s: %s", G_STRFUNC, local_error->message);
g_error_free (local_error);
g_object_unref (server);
}

@ -5,8 +5,13 @@
%define krb5_support 1
%define largefile_support 1
# disable for i686, because libphonenumber 8.12.57 is not built for it
%ifarch i686
%global phonenum_support 0
%else
# enabled only for Fedora
%global phonenum_support 0%{?fedora}
%endif
# Coverity scan can override this to 0, to skip checking in gtk-doc generated code
%{!?with_docs: %global with_docs 1}
@ -15,20 +20,21 @@
%global with_docs 0
%endif
%define glib2_version 2.46
%define gtk3_version 3.16
%define gcr_version 3.4
%{!?with_webkitgtk: %global with_webkitgtk (%{undefined rhel} || 0%{?rhel} < 10)}
%define glib2_version 2.68
%define gtk3_version 3.20
%define gtk4_version 4.4
%define gtk_doc_version 1.9
%define goa_version 3.8
%define intltool_version 0.35.5
%define libsecret_version 0.5
%define libgdata_version 0.15.1
%define libgweather_version 3.10
%define libical_version 3.0.7
%define libsoup_version 2.58
%define libgweather_version 4.0
%define libical_version 3.0.16
%define libsoup_version 3.1.1
%define nss_version 3.14
%define sqlite_version 3.7.17
%define webkit2gtk_version 2.28.0
%define webkit2gtk_version 2.34.0
%define webkit2gtk4_version 2.36.0
%define json_glib_version 1.0.4
%define credential_modules_dir %{_libdir}/evolution-data-server/credential-modules
@ -43,28 +49,21 @@
%global dbus_service_name_sources org.gnome.evolution.dataserver.Sources5
%global dbus_service_name_user_prompter org.gnome.evolution.dataserver.UserPrompter0
%if "%{?_eds_dbus_services_prefix}" != ""
%global dbus_service_name_address_book %{?_eds_dbus_services_prefix}.%{dbus_service_name_address_book}
%global dbus_service_name_calendar %{?_eds_dbus_services_prefix}.%{dbus_service_name_calendar}
%global dbus_service_name_sources %{?_eds_dbus_services_prefix}.%{dbus_service_name_sources}
%global dbus_service_name_user_prompter %{?_eds_dbus_services_prefix}.%{dbus_service_name_user_prompter}
%endif
### Abstract ###
Name: evolution-data-server
Version: 3.40.4
Release: 6%{?dist}
Version: 3.52.4
Release: 2%{?dist}
Summary: Backend data server for Evolution
License: LGPLv2+
URL: https://wiki.gnome.org/Apps/Evolution
Source: http://download.gnome.org/sources/%{name}/3.40/%{name}-%{version}.tar.xz
License: LGPL-2.0-or-later
URL: https://gitlab.gnome.org/GNOME/evolution/-/wikis/home
Source: http://download.gnome.org/sources/%{name}/3.52/%{name}-%{version}.tar.xz
Patch01: evolution-data-server-3.40.4-icalcompiter.patch
Patch02: evolution-data-server-3.40.4-secret-monitor-warnings.patch
Patch03: evolution-data-server-3.40.4-google-contacts-to-carddav.patch
Patch04: evolution-data-server-3.40.4-google-oauth2.patch
Patch05: evolution-data-server-3.40.4-caldav-crash.patch
# 0-99: General patches
# 100-199: Flatpak-specific patches
# https://gitlab.gnome.org/GNOME/evolution-data-server/-/merge_requests/144
Patch100: Make-DBUS_SERVICES_PREFIX-runtime-configurable.patch
Provides: evolution-webcal = %{version}
Obsoletes: evolution-webcal < 2.24.0
@ -91,29 +90,29 @@ BuildRequires: gperf
%if %{with_docs}
BuildRequires: gtk-doc >= %{gtk_doc_version}
%endif
BuildRequires: intltool >= %{intltool_version}
BuildRequires: make
BuildRequires: ninja-build
BuildRequires: vala
BuildRequires: systemd
BuildRequires: pkgconfig(gcr-3) >= %{gcr_version}
BuildRequires: pkgconfig(gcr-base-3) >= %{gcr_version}
BuildRequires: pkgconfig(gio-2.0) >= %{glib2_version}
BuildRequires: pkgconfig(gio-unix-2.0) >= %{glib2_version}
BuildRequires: pkgconfig(gmodule-2.0) >= %{glib2_version}
BuildRequires: pkgconfig(icu-i18n)
BuildRequires: pkgconfig(gtk+-3.0) >= %{gtk3_version}
BuildRequires: pkgconfig(gtk4) >= %{gtk4_version}
BuildRequires: pkgconfig(goa-1.0) >= %{goa_version}
BuildRequires: pkgconfig(libgdata) >= %{libgdata_version}
BuildRequires: pkgconfig(gweather-3.0) >= %{libgweather_version}
BuildRequires: pkgconfig(gweather4) >= %{libgweather_version}
BuildRequires: pkgconfig(libical-glib) >= %{libical_version}
BuildRequires: pkgconfig(libsecret-unstable) >= %{libsecret_version}
BuildRequires: pkgconfig(libsoup-2.4) >= %{libsoup_version}
BuildRequires: pkgconfig(libsoup-3.0) >= %{libsoup_version}
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(nspr)
BuildRequires: pkgconfig(nss) >= %{nss_version}
BuildRequires: pkgconfig(sqlite3) >= %{sqlite_version}
BuildRequires: pkgconfig(webkit2gtk-4.0) >= %{webkit2gtk_version}
%if %{with_webkitgtk}
BuildRequires: pkgconfig(webkit2gtk-4.1) >= %{webkit2gtk_version}
BuildRequires: pkgconfig(webkitgtk-6.0) >= %{webkit2gtk4_version}
%endif
BuildRequires: pkgconfig(json-glib-1.0) >= %{json_glib_version}
BuildRequires: pkgconfig(libcanberra-gtk3)
@ -132,8 +131,12 @@ BuildRequires: krb5-devel >= 1.11
BuildRequires: libphonenumber-devel
BuildRequires: protobuf-devel
BuildRequires: boost-devel
BuildRequires: abseil-cpp-devel
%endif
# libical 3.0.16 added new API, this ensures to bring it in
Requires: libical-glib >= %{libical_version}
%description
The %{name} package provides a unified backend for programs that work
with contacts, tasks, and calendar information.
@ -146,13 +149,15 @@ Summary: Development files for building against %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: pkgconfig(goa-1.0) >= %{goa_version}
Requires: pkgconfig(libgdata) >= %{libgdata_version}
Requires: pkgconfig(gweather-3.0) >= %{libgweather_version}
Requires: pkgconfig(gweather4) >= %{libgweather_version}
Requires: pkgconfig(libical-glib) >= %{libical_version}
Requires: pkgconfig(libsecret-unstable) >= %{libsecret_version}
Requires: pkgconfig(libsoup-2.4) >= %{libsoup_version}
Requires: pkgconfig(libsoup-3.0) >= %{libsoup_version}
Requires: pkgconfig(sqlite3) >= %{sqlite_version}
Requires: pkgconfig(webkit2gtk-4.0) >= %{webkit2gtk_version}
%if %{with_webkitgtk}
Requires: pkgconfig(webkit2gtk-4.1) >= %{webkit2gtk_version}
Requires: pkgconfig(webkitgtk-6.0) >= %{webkit2gtk4_version}
%endif
Requires: pkgconfig(json-glib-1.0) >= %{json_glib_version}
%description devel
@ -195,7 +200,15 @@ The %{name}-tests package contains tests that can be used to verify
the functionality of the installed %{name} package.
%prep
%autosetup -p1 -S gendiff
%autosetup -p1 -S gendiff -N
# General patches
%autopatch -p1 -m 0 -M 99
# Flatpak-specific patches
%if 0%{?flatpak}
%autopatch -p1 -m 100 -M 199
%endif
%build
@ -251,6 +264,12 @@ fi
%define gtkdoc_flags -DENABLE_GTK_DOC=OFF
%endif
%if %{with_webkitgtk}
%define webkitgtk_flags -DENABLE_OAUTH2_WEBKITGTK=ON -DENABLE_OAUTH2_WEBKITGTK4=ON
%else
%define webkitgtk_flags -DENABLE_OAUTH2_WEBKITGTK=OFF -DENABLE_OAUTH2_WEBKITGTK4=OFF
%endif
if ! pkg-config --exists nss; then
echo "Unable to find suitable version of nss to use!"
exit 1
@ -259,19 +278,16 @@ fi
export CPPFLAGS="-I%{_includedir}/et"
export CFLAGS="$RPM_OPT_FLAGS -DLDAP_DEPRECATED -fPIC -I%{_includedir}/et -Wno-deprecated-declarations"
%cmake -G "Unix Makefiles" \
%cmake -G Ninja \
-DENABLE_MAINTAINER_MODE=OFF \
-DWITH_LIBDB=OFF \
-DENABLE_FILE_LOCKING=fcntl \
-DENABLE_DOT_LOCKING=OFF \
-DENABLE_INTROSPECTION=ON \
-DENABLE_VALA_BINDINGS=ON \
-DENABLE_INSTALLED_TESTS=ON \
-DWITH_LIBDB=OFF \
-DWITH_SYSTEMDUSERUNITDIR=%{_userunitdir} \
%if "%{?_eds_dbus_services_prefix}" != ""
-DDBUS_SERVICES_PREFIX=%{?_eds_dbus_services_prefix} \
%endif
%ldap_flags %krb5_flags %ssl_flags \
%ldap_flags %krb5_flags %ssl_flags %webkitgtk_flags \
%largefile_flags %gtkdoc_flags %phonenum_flags \
%{nil}
@ -282,6 +298,7 @@ export CFLAGS="$RPM_OPT_FLAGS -DLDAP_DEPRECATED -fPIC -I%{_includedir}/et -Wno-d
# make sure the directory exists, because it's owned by eds
mkdir $RPM_BUILD_ROOT/%{uimodules_dir} || :
mkdir $RPM_BUILD_ROOT/%{credential_modules_dir} || :
# give the libraries some executable bits
find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
@ -291,24 +308,26 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%files
%license COPYING
%doc README ChangeLog NEWS
%{_libdir}/libcamel-1.2.so.62
%{_libdir}/libcamel-1.2.so.62.0.0
%{_libdir}/libebackend-1.2.so.10
%{_libdir}/libebackend-1.2.so.10.0.0
%{_libdir}/libebook-1.2.so.20
%{_libdir}/libebook-1.2.so.20.1.3
%{_libdir}/libebook-contacts-1.2.so.3
%{_libdir}/libebook-contacts-1.2.so.3.0.0
%{_libdir}/libecal-2.0.so.1
%{_libdir}/libecal-2.0.so.1.0.0
%{_libdir}/libedata-book-1.2.so.26
%{_libdir}/libedata-book-1.2.so.26.0.0
%{_libdir}/libedata-cal-2.0.so.1
%{_libdir}/libedata-cal-2.0.so.1.0.0
%{_libdir}/libedataserver-1.2.so.26
%{_libdir}/libedataserver-1.2.so.26.0.0
%{_libdir}/libedataserverui-1.2.so.3
%{_libdir}/libedataserverui-1.2.so.3.0.0
%{_libdir}/libcamel-1.2.so.64
%{_libdir}/libcamel-1.2.so.64.0.0
%{_libdir}/libebackend-1.2.so.11
%{_libdir}/libebackend-1.2.so.11.0.0
%{_libdir}/libebook-1.2.so.21
%{_libdir}/libebook-1.2.so.21.1.3
%{_libdir}/libebook-contacts-1.2.so.4
%{_libdir}/libebook-contacts-1.2.so.4.0.0
%{_libdir}/libecal-2.0.so.3
%{_libdir}/libecal-2.0.so.3.0.0
%{_libdir}/libedata-book-1.2.so.27
%{_libdir}/libedata-book-1.2.so.27.0.0
%{_libdir}/libedata-cal-2.0.so.2
%{_libdir}/libedata-cal-2.0.so.2.0.0
%{_libdir}/libedataserver-1.2.so.27
%{_libdir}/libedataserver-1.2.so.27.0.0
%{_libdir}/libedataserverui-1.2.so.4
%{_libdir}/libedataserverui-1.2.so.4.0.0
%{_libdir}/libedataserverui4-1.0.so.0
%{_libdir}/libedataserverui4-1.0.so.0.0.0
%{_libdir}/girepository-1.0/Camel-1.2.typelib
%{_libdir}/girepository-1.0/EBackend-1.2.typelib
@ -319,6 +338,7 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_libdir}/girepository-1.0/EDataCal-2.0.typelib
%{_libdir}/girepository-1.0/EDataServer-1.2.typelib
%{_libdir}/girepository-1.0/EDataServerUI-1.2.typelib
%{_libdir}/girepository-1.0/EDataServerUI4-1.0.typelib
%{_libexecdir}/camel-gpg-photo-saver
%{_libexecdir}/camel-index-control-1.2
@ -334,10 +354,15 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%dir %{_libexecdir}/evolution-data-server
%{_libexecdir}/evolution-data-server/addressbook-export
%{_libexecdir}/evolution-data-server/evolution-alarm-notify
%{_libexecdir}/evolution-data-server/evolution-oauth2-handler
%{_libexecdir}/evolution-data-server/list-sources
%if 0%{?flatpak}
%{_libexecdir}/evolution-data-server/set-dbus-prefix
%endif
%{_sysconfdir}/xdg/autostart/org.gnome.Evolution-alarm-notify.desktop
%{_datadir}/applications/org.gnome.Evolution-alarm-notify.desktop
%{_datadir}/applications/org.gnome.evolution-data-server.OAuth2-handler.desktop
# GSettings schemas:
%{_datadir}/GConf/gsettings/evolution-data-server.convert
@ -354,6 +379,7 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_datadir}/dbus-1/services/%{dbus_service_name_sources}.service
%{_datadir}/dbus-1/services/%{dbus_service_name_user_prompter}.service
%{_datadir}/pixmaps/evolution-data-server
%{_datadir}/icons/hicolor/scalable/apps/org.gnome.Evolution-alarm-notify.svg
%{_userunitdir}/evolution-addressbook-factory.service
%{_userunitdir}/evolution-calendar-factory.service
@ -422,6 +448,7 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_libdir}/libedata-cal-2.0.so
%{_libdir}/libedataserver-1.2.so
%{_libdir}/libedataserverui-1.2.so
%{_libdir}/libedataserverui4-1.0.so
%{_libdir}/pkgconfig/camel-1.2.pc
%{_libdir}/pkgconfig/evolution-data-server-1.2.pc
%{_libdir}/pkgconfig/libebackend-1.2.pc
@ -432,6 +459,7 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_libdir}/pkgconfig/libedata-cal-2.0.pc
%{_libdir}/pkgconfig/libedataserver-1.2.pc
%{_libdir}/pkgconfig/libedataserverui-1.2.pc
%{_libdir}/pkgconfig/libedataserverui4-1.0.pc
%{_datadir}/gir-1.0/Camel-1.2.gir
%{_datadir}/gir-1.0/EBackend-1.2.gir
%{_datadir}/gir-1.0/EBook-1.2.gir
@ -441,6 +469,7 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_datadir}/gir-1.0/EDataCal-2.0.gir
%{_datadir}/gir-1.0/EDataServer-1.2.gir
%{_datadir}/gir-1.0/EDataServerUI-1.2.gir
%{_datadir}/gir-1.0/EDataServerUI4-1.0.gir
%{_datadir}/vala/vapi/camel-1.2.deps
%{_datadir}/vala/vapi/camel-1.2.vapi
%{_datadir}/vala/vapi/libebackend-1.2.deps
@ -459,6 +488,8 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_datadir}/vala/vapi/libedataserver-1.2.vapi
%{_datadir}/vala/vapi/libedataserverui-1.2.deps
%{_datadir}/vala/vapi/libedataserverui-1.2.vapi
%{_datadir}/vala/vapi/libedataserverui4-1.0.deps
%{_datadir}/vala/vapi/libedataserverui4-1.0.vapi
%files langpacks -f %{name}.lang
@ -480,36 +511,211 @@ find $RPM_BUILD_ROOT -name '*.so.*' -exec chmod +x {} \;
%{_datadir}/installed-tests
%changelog
* Tue May 24 2022 Milan Crha <mcrha@redhat.com> - 3.40.4-6
- Resolves: #2089902 (CalDAV: Crash on calendar update)
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 3.52.4-2
- Bump release for October 2024 mass rebuild:
Resolves: RHEL-64018
* Mon Aug 19 2024 Milan Crha <mcrha@redhat.com> - 3.52.4-1
- Resolves: RHEL-52806 (Update to 3.52.4)
* Mon Jul 01 2024 Milan Crha <mcrha@redhat.com> - 3.52.3-1
- Resolves: RHEL-45599 (Update to 3.52.3)
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 3.52.2-2
- Bump release for June 2024 mass rebuild
* Tue May 28 2024 Milan Crha <mcrha@redhat.com> - 3.52.2-1
- Resolves: RHEL-38639 (Update to 3.52.2)
* Mon Apr 22 2024 Milan Crha <mcrha@redhat.com> - 3.52.1-1
- Resolves: RHEL-33592 (Backport Fedora 40 changes)
- Update to 3.52.1
* Mon Mar 25 2024 Milan Crha <mcrha@redhat.com> - 3.52.0-1
- Resolves: RHEL-30204 (Backport Fedora 40 changes)
- Update to 3.52.0
- Add patch to allow reconfiguring the dbus-prefix without rebuilding;
this is needed to make EDS work with the new Flatpak infrastructure.
- Remove support _eds_dbus_services_prefix - this was only used by
F38 and earlier Flatpak builds.
* Fri Feb 09 2024 Milan Crha <mcrha@redhat.com> - 3.51.2-1
- Update to 3.51.2
* Wed Jan 31 2024 Pete Walter <pwalter@fedoraproject.org> - 3.51.1-4
- Rebuild for ICU 74
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.51.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.51.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 05 2024 Milan Crha <mcrha@redhat.com> - 3.51.1-1
- Update to 3.51.1
* Tue Dec 19 2023 Florian Weimer <fweimer@redhat.com> - 3.50.2-2
- Backport upstream patch to fix C issue in CMake probing
* Fri Dec 01 2023 Milan Crha <mcrha@redhat.com> - 3.50.2-1
- Update to 3.50.2
* Fri Oct 20 2023 Milan Crha <mcrha@redhat.com> - 3.50.1-1
- Update to 3.50.1
* Fri Sep 15 2023 Milan Crha <mcrha@redhat.com> - 3.50.0-1
- Update to 3.50.0
* Fri Sep 01 2023 Milan Crha <mcrha@redhat.com> - 3.49.3-1
- Update to 3.49.3
* Fri Aug 04 2023 Milan Crha <mcrha@redhat.com> - 3.49.2-1
- Update to 3.49.2
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 3.49.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Tue Jul 11 2023 František Zatloukal <fzatlouk@redhat.com> - 3.49.1-2
- Rebuilt for ICU 73.2
* Wed May 04 2022 Milan Crha <mcrha@redhat.com> - 3.40.4-5
- Resolves: #2081747 (Backport patch for Google OAuth2 change)
* Fri Jun 30 2023 Milan Crha <mcrha@redhat.com> - 3.49.1-1
- Update to 3.49.1
* Tue Apr 05 2022 Milan Crha <mcrha@redhat.com> - 3.40.4-4
- Resolves: #2071893 (Addressbook: Switch from GData Contacts API to CardDAV API for Google books)
* Fri Jun 02 2023 Milan Crha <mcrha@redhat.com> - 3.48.3-1
- Update to 3.48.3
* Mon Nov 22 2021 Milan Crha <mcrha@redhat.com> - 3.40.4-3
- Resolves: #2025480 (secret-monitor: Turn runtime warnings into debug prints)
* Fri May 26 2023 Milan Crha <mcrha@redhat.com> - 3.48.2-1
- Update to 3.48.2
* Mon Nov 08 2021 Milan Crha <mcrha@redhat.com> - 3.40.4-2
- Resolves: #2021055 (Add patch to correct ICalCompIter component's usage)
* Wed May 17 2023 Sérgio Basto <sergio@serjux.com> - 3.48.1-2
- Rebuild for libphonenumber-8.13.x
* Fri Aug 13 2021 Milan Crha <mcrha@redhat.com> - 3.40.4-1
- Related: #1992450 (Update to 3.40.4)
* Fri Apr 21 2023 Milan Crha <mcrha@redhat.com> - 3.48.1-1
- Update to 3.48.1
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 3.40.3-2
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Fri Mar 17 2023 Milan Crha <mcrha@redhat.com> - 3.48.0-1
- Update to 3.48.0
* Mon Jul 12 2021 Milan Crha <mcrha@redhat.com> - 3.40.3-1
- Related: #1981215 (Update to 3.40.3)
* Thu Mar 09 2023 Michael Catanzaro <mcatanzaro@redhat.com> - 3.47.3-2
- Build against WebKitGTK 2.39.91
* Fri Mar 03 2023 Milan Crha <mcrha@redhat.com> - 3.47.3-1
- Update to 3.47.3
* Wed Feb 22 2023 Michael Catanzaro <mcatanzaro@redhat.com> - 3.47.2-2
- Build against WebKitGTK 2.39.90
* Fri Feb 10 2023 Milan Crha <mcrha@redhat.com> - 3.47.2-1
- Update to 3.47.2
* Wed Feb 01 2023 Michael Catanzaro <mcatanzaro@redhat.com> - 3.47.1-4
- Build against WebKitGTK 2.39.6
* Fri Jan 20 2023 Michael Catanzaro <mcatanzaro@redhat.com> - 3.47.1-3
- Build against WebKitGTK 2.39.5
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 3.47.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Fri Jan 06 2023 Milan Crha <mcrha@redhat.com> - 3.47.1-1
- Update to 3.47.1
- Require libical 3.0.16 for added new API
* Sat Dec 31 2022 Pete Walter <pwalter@fedoraproject.org> - 3.46.2-3
- Rebuild for ICU 72
* Mon Dec 05 2022 Michael Catanzaro <mcatanzaro@redhat.com> - 3.46.2-2
- Build against webkitgtk-6.0
* Fri Dec 02 2022 Milan Crha <mcrha@redhat.com> - 3.46.2-1
- Update to 3.46.2
* Fri Oct 21 2022 Milan Crha <mcrha@redhat.com> - 3.46.1-1
- Update to 3.46.1
* Fri Sep 16 2022 Milan Crha <mcrha@redhat.com> - 3.46.0-1
- Update to 3.46.0
* Fri Sep 02 2022 Milan Crha <mcrha@redhat.com> - 3.45.3-1
- Update to 3.45.3
* Fri Aug 05 2022 Milan Crha <mcrha@redhat.com> - 3.45.2-1
- Update to 3.45.2
* Mon Aug 01 2022 Frantisek Zatloukal <fzatlouk@redhat.com> - 3.45.1-3
- Rebuilt for ICU 71.1
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 3.45.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Tue Jul 19 2022 Milan Crha <mcrha@redhat.com> - 3.45.1-1
- Update to 3.45.1
* Mon Jul 18 2022 Milan Crha <mcrha@redhat.com> - 3.44.3-2
- Add patch for RH bug #2107751 (glib2's G_TLS_CERTIFICATE_FLAGS_NONE causes infinite loop)
* Fri Jul 01 2022 Milan Crha <mcrha@redhat.com> - 3.44.3-1
- Update to 3.44.3
* Fri May 27 2022 Milan Crha <mcrha@redhat.com> - 3.44.2-1
- Update to 3.44.2
* Fri Apr 22 2022 Milan Crha <mcrha@redhat.com> - 3.44.1-1
- Update to 3.44.1
* Fri Mar 18 2022 Milan Crha <mcrha@redhat.com> - 3.44.0-1
- Update to 3.44.0
* Fri Mar 04 2022 Milan Crha <mcrha@redhat.com> - 3.43.3-1
- Update to 3.43.3
* Fri Feb 11 2022 Milan Crha <mcrha@redhat.com> - 3.43.2-1
- Update to 3.43.2
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 3.43.1.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Fri Jan 07 2022 Milan Crha <mcrha@redhat.com> - 3.43.1.1-1
- Update to 3.43.1.1
* Fri Dec 03 2021 Milan Crha <mcrha@redhat.com> - 3.42.2-1
- Update to 3.42.2
* Sat Nov 06 2021 Adrian Reber <adrian@lisas.de> - 3.42.1-3
- Rebuilt for protobuf 3.19.0
* Fri Nov 05 2021 Milan Crha <mcrha@redhat.com> - 3.42.1-2
- Add patch to correct ICalCompIter component's usage
* Fri Oct 29 2021 Milan Crha <mcrha@redhat.com> - 3.42.1-1
- Update to 3.42.1
* Thu Oct 28 2021 Adam Williamson <awilliam@redhat.com> - 3.42.0-2
- Rebuild with newer protobuf and libphonenumber
* Fri Sep 17 2021 Milan Crha <mcrha@redhat.com> - 3.42.0-1
- Update to 3.42.0
* Fri Sep 03 2021 Milan Crha <mcrha@redhat.com> - 3.41.3-1
- Update to 3.41.3
* Fri Aug 13 2021 Milan Crha <mcrha@redhat.com> - 3.41.2-1
- Update to 3.41.2
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.41.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Fri Jul 09 2021 Milan Crha <mcrha@redhat.com> - 3.41.1-1
- Update to 3.41.1
* Fri Jun 04 2021 Milan Crha <mcrha@redhat.com> - 3.40.2-1
- Related: #1967855 (Update to 3.40.2)
- Update to 3.40.2
* Wed May 19 2021 Pete Walter <pwalter@fedoraproject.org> - 3.40.1-2
- Rebuild for ICU 69
* Thu Apr 15 2021 Mohan Boddu <mboddu@redhat.com> - 3.40.0-4
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Fri Apr 30 2021 Milan Crha <mcrha@redhat.com> - 3.40.1-1
- Update to 3.40.1
* Mon Mar 29 2021 Milan Crha <mcrha@redhat.com> - 3.40.0-3
- Resolves: #1943818 (ESourceWebDAV: Fallback to SHA1 on SSL trust verification if needed)

Loading…
Cancel
Save