diff --git a/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix b/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix index 5c2eae883cfc..078145e1231f 100644 --- a/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix +++ b/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix @@ -2,7 +2,7 @@ , intltool, libsoup, libxml2, libsecret, icu, sqlite, tzdata, libcanberra-gtk3, gcr , p11-kit, db, nspr, nss, libical, gperf, wrapGAppsHook, glib-networking, pcre , vala, cmake, ninja, kerberos, openldap, webkitgtk, libaccounts-glib, json-glib -, glib, gtk3, gnome-online-accounts, libgweather, libgdata }: +, glib, gtk3, gnome-online-accounts, libgweather, libgdata, gsettings-desktop-schemas }: stdenv.mkDerivation rec { name = "evolution-data-server-${version}"; @@ -20,9 +20,14 @@ stdenv.mkDerivation rec { src = ./fix-paths.patch; inherit tzdata; }) - ./hardcode-gsettings.patch ]; + prePatch = '' + substitute ${./hardcode-gsettings.patch} hardcode-gsettings.patch --subst-var-by ESD_GSETTINGS_PATH $out/share/gsettings-schemas/${name}/glib-2.0/schemas \ + --subst-var-by GDS_GSETTINGS_PATH "${gsettings-desktop-schemas}/share/gsettings-schemas/${gsettings-desktop-schemas.name}/glib-2.0/schemas" + patches="$patches $PWD/hardcode-gsettings.patch" + ''; + nativeBuildInputs = [ cmake ninja pkgconfig intltool python3 gperf wrapGAppsHook gobject-introspection vala ]; @@ -43,11 +48,6 @@ stdenv.mkDerivation rec { "-DINCLUDE_INSTALL_DIR=${placeholder "dev"}/include" ]; - postPatch = '' - substituteInPlace src/libedataserver/e-source-registry.c --subst-var-by ESD_GSETTINGS_PATH $out/share/gsettings-schemas/${name}/glib-2.0/schemas - ''; - - passthru = { updateScript = gnome3.updateScript { packageName = "evolution-data-server"; diff --git a/pkgs/desktops/gnome-3/core/evolution-data-server/hardcode-gsettings.patch b/pkgs/desktops/gnome-3/core/evolution-data-server/hardcode-gsettings.patch index adc0ba6746f9..c499bac4552c 100644 --- a/pkgs/desktops/gnome-3/core/evolution-data-server/hardcode-gsettings.patch +++ b/pkgs/desktops/gnome-3/core/evolution-data-server/hardcode-gsettings.patch @@ -377,7 +377,7 @@ index 883379a60..989353494 100644 + { + GSettingsSchemaSource *schema_source; + GSettingsSchema *schema; -+ schema_source = g_settings_schema_source_new_from_directory("@ESD_GSETTINGS_PATH@", ++ schema_source = g_settings_schema_source_new_from_directory("@GDS_GSETTINGS_PATH@", + g_settings_schema_source_get_default(), + TRUE, + NULL);