From 461c396d624413e65564df24d6863112cc8cfcb5 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 6 Aug 2020 14:28:58 -0400 Subject: [PATCH 34/44] gnu: gnome-photos: Update package definition. * gnu/packages/gnome.scm (gnome-photos): Update package definition. [outputs]: New output "help". [arguements]<#:phases>['skip-gtk-update-icon-cache]: New phase. ['pre-check]: New phase. ['move-help]: New phase. ['wrap-gnome-photos]: Remove phase. [native-inputs]: Add xorg-server-for-tests. Remove gtk+:bin. Move dbus to ... [inputs]: ... here. Add glib. Remove gnome-online-miners, grilo-plugins, rest, python-pygobject and tracker-miners. Change gnome-online-accounts to gnome-online-accounts:lib. [synopsis]: Modify. --- gnu/packages/gnome.scm | 70 +++++++++++++++++++++++++----------------- 1 file changed, 42 insertions(+), 28 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index a9c65f39e9..18efe684ad 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -799,59 +799,73 @@ sysprof.") (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 - (base32 - "06ml5sf8xhpan410msqz085hmfc7082d368pb82yq646y9pcfn9w")))) + (base32 "06ml5sf8xhpan410msqz085hmfc7082d368pb82yq646y9pcfn9w")))) (build-system meson-build-system) + (outputs '("out" "help")) (arguments - `(#:glib-or-gtk? #t + `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas #:configure-flags - (list "-Ddogtail=false" ; Not available - ;; Required for RUNPATH validation. - (string-append "-Dc_link_args=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib/gnome-photos")) + (list + "-Ddogtail=false" + ;; Required for RUNPATH validation. + (string-append "-Dc_link_args=-Wl,-rpath=" + (assoc-ref %outputs "out") + "/lib/gnome-photos")) #:phases (modify-phases %standard-phases - (add-after 'install 'wrap-gnome-photos - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* - ((out (assoc-ref outputs "out"))) - (wrap-program (string-append out "/bin/gnome-photos") - `("GRL_PLUGIN_PATH" = (,(getenv "GRL_PLUGIN_PATH"))))) - #t))))) + (add-before 'configure 'skip-gtk-update-icon-cache + (lambda _ + (substitute* "meson_post_install.py" + (("gtk-update-icon-cache") + "true")) + #t)) + (add-before 'check 'pre-check + (lambda _ + ;; Tests require a running X server. + (system "Xvfb :1 +extension GLX &") + (setenv "DISPLAY" ":1") + ;; For missing '/etc/machine-id'. + (setenv "DBUS_FATAL_WARNINGS" "0") + #t)) + (add-after 'install 'move-help + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (help (assoc-ref outputs "help"))) + (mkdir-p (string-append help "/share")) + (rename-file + (string-append out "/share/help") + (string-append help "/share/help")) + #t)))))) (native-inputs - `(("dbus" ,dbus) - ("desktop-file-utils" ,desktop-file-utils) + `(("desktop-file-utils" ,desktop-file-utils) ("gettext" ,gettext-minimal) ("git" ,git-minimal) ("glib:bin" ,glib "bin") ("gobject-introspection" ,gobject-introspection) - ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) - ("gtk+:bin" ,gtk+ "bin") ("itstool" ,itstool) - ("pkg-config" ,pkg-config))) + ("pkg-config" ,pkg-config) + ("xorg-server" ,xorg-server-for-tests))) (inputs `(("babl" ,babl) ("cairo" ,cairo) + ("dbus" ,dbus) ("gdk-pixbuf" ,gdk-pixbuf+svg) ("gegl" ,gegl) ("geocode-glib" ,geocode-glib) ("gexiv2" ,gexiv2) - ("gnome-online-accounts" ,gnome-online-accounts) - ("gnome-online-miners" ,gnome-online-miners) + ("glib" ,glib) + ("gnome-online-accounts:lib" ,gnome-online-accounts "lib") ("grilo" ,grilo) - ("grilo-plugins" ,grilo-plugins) + ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) ("gtk+" ,gtk+) ("libdazzle" ,libdazzle) ("libgdata" ,libgdata) ("libgfbgraph" ,gfbgraph) ("libjpeg" ,libjpeg-turbo) ("libpng" ,libpng) - ("librest" ,rest) - ("pygobject" ,python-pygobject) - ("tracker" ,tracker) - ("tracker-miners" ,tracker-miners))) - (synopsis "Access, organize and share your photos on GNOME desktop") - (description "GNOME Photos is a simple and elegant replacement for using a + ("tracker" ,tracker))) + (synopsis "Access, organize and share your photos") + (description "GNOME-Photos is a simple and elegant replacement for using a file manager to deal with photos. Enhance, crop and edit in a snap. Seamless cloud integration is offered through GNOME Online Accounts.") (home-page "https://wiki.gnome.org/Apps/Photos") -- 2.28.0