From b31de37eba0f287e2e827ee0fbfb02a65c898fca Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sat, 12 Sep 2020 14:36:34 +0200 Subject: [PATCH] =?UTF-8?q?deja-dup:=2040.6=20=E2=86=92=2042.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit https://gitlab.gnome.org/World/deja-dup/-/releases#42.4 - Nautilus extension no longer supported (https://gitlab.gnome.org/World/deja-dup/merge_requests/42) --- pkgs/applications/backup/deja-dup/default.nix | 53 ++++--------------- .../backup/deja-dup/hardcode-gsettings.patch | 16 ------ 2 files changed, 9 insertions(+), 60 deletions(-) delete mode 100644 pkgs/applications/backup/deja-dup/hardcode-gsettings.patch diff --git a/pkgs/applications/backup/deja-dup/default.nix b/pkgs/applications/backup/deja-dup/default.nix index d283dc7107d7..5d1d75e31ebc 100644 --- a/pkgs/applications/backup/deja-dup/default.nix +++ b/pkgs/applications/backup/deja-dup/default.nix @@ -3,44 +3,32 @@ , substituteAll , meson , ninja -, pkgconfig +, pkg-config , vala , gettext -, gnome3 -, libnotify , itstool , glib , gtk3 -, libxml2 -, gnome-online-accounts , coreutils , libsoup , libsecret -, pcre -, libxkbcommon +, libhandy , wrapGAppsHook -, libpthreadstubs -, libXdmcp -, epoxy -, at-spi2-core -, dbus , libgpgerror , json-glib -, appstream-glib -, desktop-file-utils , duplicity }: stdenv.mkDerivation rec { pname = "deja-dup"; - version = "40.6"; + version = "42.4"; src = fetchFromGitLab { domain = "gitlab.gnome.org"; owner = "World"; repo = pname; rev = version; - sha256 = "1d4g34g660wv42a4k2511bxrh90z0vdl3v7ahg0m45phijg9n2n1"; + sha256 = "c4E6mHYVb8TWVTVlmHidcLa9ebHJ27iStsNNLJhY8vY="; }; patches = [ @@ -48,54 +36,31 @@ stdenv.mkDerivation rec { src = ./fix-paths.patch; inherit coreutils; }) - - # Hardcode GSettings path for Nautilus extension to avoid crashes from missing schemas - ./hardcode-gsettings.patch ]; - postPatch = '' - # substitute variable from hardcode-gsettings.patch - substituteInPlace deja-dup/nautilus/NautilusExtension.c --subst-var-by DEJA_DUP_GSETTINGS_PATH "${glib.makeSchemaPath (placeholder "out") "${pname}-${version}"}" - ''; - nativeBuildInputs = [ meson ninja - pkgconfig + pkg-config vala gettext itstool - appstream-glib - desktop-file-utils - libxml2 wrapGAppsHook ]; buildInputs = [ - libnotify libsoup glib gtk3 libsecret - pcre - libxkbcommon - libpthreadstubs - libXdmcp - epoxy - gnome3.nautilus - at-spi2-core - dbus - gnome-online-accounts # GOA not used any more, only for transferring legacy keys + libhandy libgpgerror json-glib ]; - # TODO: hard code the path - # https://gitlab.gnome.org/World/deja-dup/merge_requests/32 - propagatedUserEnvPkgs = [ duplicity ]; - - # install nautilus plug-in to correct path - PKG_CONFIG_LIBNAUTILUS_EXTENSION_EXTENSIONDIR = "${placeholder "out"}/lib/nautilus/extensions-3.0"; + mesonFlags = [ + "-Dduplicity_command=${duplicity}/bin/duplicity" + ]; meta = with stdenv.lib; { description = "A simple backup tool"; diff --git a/pkgs/applications/backup/deja-dup/hardcode-gsettings.patch b/pkgs/applications/backup/deja-dup/hardcode-gsettings.patch deleted file mode 100644 index f74dbf73543e..000000000000 --- a/pkgs/applications/backup/deja-dup/hardcode-gsettings.patch +++ /dev/null @@ -1,16 +0,0 @@ ---- a/deja-dup/nautilus/NautilusExtension.c -+++ b/deja-dup/nautilus/NautilusExtension.c -@@ -313,7 +313,12 @@ - bindtextdomain(GETTEXT_PACKAGE, LOCALE_DIR); - bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8"); - -- settings = g_settings_new(APPLICATION_ID); -+ g_autoptr (GSettingsSchemaSource) schema_source = g_settings_schema_source_new_from_directory ("@DEJA_DUP_GSETTINGS_PATH@", -+ g_settings_schema_source_get_default (), TRUE, NULL); -+ -+ g_autoptr (GSettingsSchema) schema = g_settings_schema_source_lookup (schema_source, APPLICATION_ID, FALSE); -+ -+ settings = g_settings_new_full (schema, NULL, NULL); - g_signal_connect(settings, "changed::include-list", - update_include_excludes, NULL); - g_signal_connect(settings, "changed::exclude-list",