gnu: gnome-todo: Update to 41.0 and enable tests.

* gnu/packages/patches/gnome-todo-libportal.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register it.
* gnu/packages/gnome.scm (gnome-todo): Update to 41.0.
[source]: Apply patch.
[arguments]: Use G-exp.
[tests?]: Delete field, enabling tests.
[phases]: Move check phase after install phase.
{pre-check}: Add phase.
[native-inputs]: Re-style.
[inputs]: Likewise.
[description]: Re-indent.
This commit is contained in:
Maxim Cournoyer 2022-01-22 01:11:51 -05:00
parent 2b77a66edb
commit ef451d9164
No known key found for this signature in database
GPG key ID: 1260E46482E63562
3 changed files with 94 additions and 33 deletions

View file

@ -1187,6 +1187,7 @@ dist_patch_DATA = \
%D%/packages/patches/gnome-screenshot-meson-0.60.patch \ %D%/packages/patches/gnome-screenshot-meson-0.60.patch \
%D%/packages/patches/gnome-settings-daemon-gc.patch \ %D%/packages/patches/gnome-settings-daemon-gc.patch \
%D%/packages/patches/gnome-session-support-elogind.patch \ %D%/packages/patches/gnome-session-support-elogind.patch \
%D%/packages/patches/gnome-todo-libportal.patch \
%D%/packages/patches/gnome-tweaks-search-paths.patch \ %D%/packages/patches/gnome-tweaks-search-paths.patch \
%D%/packages/patches/gnupg-default-pinentry.patch \ %D%/packages/patches/gnupg-default-pinentry.patch \
%D%/packages/patches/gnupg-1-build-with-gcc10.patch \ %D%/packages/patches/gnupg-1-build-with-gcc10.patch \

View file

@ -9803,7 +9803,7 @@ (define-public gnome-calendar
(define-public gnome-todo (define-public gnome-todo
(package (package
(name "gnome-todo") (name "gnome-todo")
(version "40.1") (version "41.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://gnome/sources/" name "/" (uri (string-append "mirror://gnome/sources/" name "/"
@ -9811,44 +9811,50 @@ (define-public gnome-todo
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1r1fb3zgjvkhx93by24j8cg1w1g3zvwr49vqkscjn261vqs44jq3")))) "1r94880d4khbjhhfnhaba3y3d4hv2bri82rzfzxn27s5iybpqras"))
(patches (search-patches "gnome-todo-libportal.patch"))))
(build-system meson-build-system) (build-system meson-build-system)
(arguments (arguments
`(#:glib-or-gtk? #t (list
;; XXX: Some tests fail with the following error: #:glib-or-gtk? #t
;; Settings schema 'org.gnome.todo' is not installed. #:phases
#:tests? #f #~(modify-phases %standard-phases
#:phases (add-after 'unpack 'skip-gtk-update-icon-cache
(modify-phases %standard-phases (lambda _
(add-after 'unpack 'skip-gtk-update-icon-cache (substitute* "build-aux/meson/meson_post_install.py"
;; Don't create 'icon-theme.cache'. (("gtk-update-icon-cache") "true"))))
(lambda _ (delete 'check)
(substitute* "build-aux/meson/meson_post_install.py" (add-after 'install 'check
(("gtk-update-icon-cache") "true"))))))) (assoc-ref %standard-phases
'check))
(add-before 'check 'pre-check
(lambda _
(setenv "GSETTINGS_SCHEMA_DIR"
(string-append #$output "/share/glib-2.0/schemas")))))))
(native-inputs (native-inputs
`(("gettext" ,gettext-minimal) (list gettext-minimal
("gobject-introspection" ,gobject-introspection) gobject-introspection
("glib:bin" ,glib "bin") ; For glib-compile-resources `(,glib "bin") ;for glib-compile-resources
("gtk-bin" ,gtk "bin") ; For gtk-update-icon-cache `(,gtk "bin") ;for gtk-update-icon-cache
("pkg-config" ,pkg-config))) itstool
pkg-config))
(inputs (inputs
`(("rest" ,rest) ; For Todoist plugin (list rest ;for Todoist plugin
("gtk" ,gtk) gtk
("json-glib" ,json-glib) ; For Todoist plugin json-glib ;for Todoist plugin
("libadwaita" ,libadwaita) libadwaita
("libedataserverui" ,evolution-data-server) evolution-data-server
("libical" ,libical) libical
("libpeas" ,libpeas) libpeas
("libportal" ,libportal) libportal
("python-pygobject" ,python-pygobject) python-pygobject
("evolution-data-server" ,evolution-data-server) evolution-data-server
("gnome-online-accounts:lib" ,gnome-online-accounts "lib") `(,gnome-online-accounts "lib")
("gsettings-desktop-schemas" ,gsettings-desktop-schemas))) gsettings-desktop-schemas))
(home-page "https://wiki.gnome.org/Apps/Todo") (home-page "https://wiki.gnome.org/Apps/Todo")
(synopsis "GNOME's ToDo Application") (synopsis "GNOME's ToDo Application")
(description (description "GNOME To Do is a simplistic personal task manager designed
"GNOME To Do is a simplistic personal task manager designed to perfectly to perfectly fit the GNOME desktop.")
fit the GNOME desktop.")
(license license:gpl3+))) (license license:gpl3+)))
(define-public gnome-dictionary (define-public gnome-dictionary

View file

@ -0,0 +1,54 @@
From 3e1f4da8c0e536c09ffaf3b43fe2eb5dc17cc23e Mon Sep 17 00:00:00 2001
From: Georges Basile Stavracas Neto <georges.stavracas@gmail.com>
Date: Thu, 18 Nov 2021 19:46:13 -0300
Subject: [PATCH] flatpak: Adjust to libportal changes
---
build-aux/flatpak/org.gnome.Todo.json | 3 +++
src/plugins/background/gtd-plugin-background.c | 2 +-
src/plugins/background/meson.build | 2 +-
3 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/build-aux/flatpak/org.gnome.Todo.json b/build-aux/flatpak/org.gnome.Todo.json
index 034e200c..44b83d66 100644
--- a/build-aux/flatpak/org.gnome.Todo.json
+++ b/build-aux/flatpak/org.gnome.Todo.json
@@ -143,6 +143,9 @@
{
"name" : "libportal",
"buildsystem" : "meson",
+ "config-opts" : [
+ "-Dbackends=gtk4"
+ ],
"sources" : [
{
"type" : "git",
diff --git a/src/plugins/background/gtd-plugin-background.c b/src/plugins/background/gtd-plugin-background.c
index cf48786c..f64d07aa 100644
--- a/src/plugins/background/gtd-plugin-background.c
+++ b/src/plugins/background/gtd-plugin-background.c
@@ -28,7 +28,7 @@
#include <gtk/gtk.h>
#include <libportal/portal.h>
-#include <libportal/portal-gtk4.h>
+#include <libportal-gtk4/portal-gtk4.h>
#define AUTOSTART_NOTIFICATION_ID "Gtd::BackgroundPlugin::autostart_notification"
#define AUTOSTART_NOTIFICATION_TIMEOUT 3 /* seconds */
diff --git a/src/plugins/background/meson.build b/src/plugins/background/meson.build
index a671a4f3..59d3635f 100644
--- a/src/plugins/background/meson.build
+++ b/src/plugins/background/meson.build
@@ -1,7 +1,7 @@
plugins_ldflags += ['-Wl,--undefined=gtd_plugin_background_register_types']
plugins_deps += [
- dependency('libportal'),
+ dependency('libportal-gtk4'),
]
plugins_sources += files(
--
GitLab