guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/04: gnu: gnome-weather: Add wrapper to fix runtime failure.


From: guix-commits
Subject: 01/04: gnu: gnome-weather: Add wrapper to fix runtime failure.
Date: Mon, 4 May 2020 10:37:01 -0400 (EDT)

mbakke pushed a commit to branch core-updates
in repository guix.

commit 2b68ba721c153b4a4d2f886142985983dcf92429
Author: Marius Bakke <address@hidden>
AuthorDate: Mon May 4 14:23:58 2020 +0200

    gnu: gnome-weather: Add wrapper to fix runtime failure.
    
    Fixes <https://bugs.gnu.org/41057>.  Reported by sirgazil <address@hidden>.
    
    * gnu/packages/gnome.scm (gnome-weather)[arguments]: Add #:glib-or-gtk?.  
Add
    phase to wrap the executable with GTK+ variables.
---
 gnu/packages/gnome.scm | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm
index cd986af..2c0a862 100644
--- a/gnu/packages/gnome.scm
+++ b/gnu/packages/gnome.scm
@@ -7768,7 +7768,8 @@ associations for GNOME.")
       ("gnome-desktop" ,gnome-desktop)
       ("libgweather" ,libgweather)))
    (arguments
-    `(#:phases
+    `(#:glib-or-gtk? #t
+      #:phases
       (modify-phases %standard-phases
         (add-after 'install 'fix-desktop-file
           ;; FIXME: "gapplication launch org.gnome.Weather" fails for some 
reason.
@@ -7777,7 +7778,16 @@ associations for GNOME.")
             (let* ((out (assoc-ref outputs "out"))
                    (applications (string-append out "/share/applications")))
               (substitute* (string-append applications 
"/org.gnome.Weather.desktop")
-                (("Exec=.*") "Exec=gnome-weather\n"))))))))
+                (("Exec=.*") "Exec=gnome-weather\n"))
+              #t)))
+        (add-after 'install 'wrap
+          (lambda* (#:key inputs outputs #:allow-other-keys)
+            (let ((out               (assoc-ref outputs "out"))
+                  (gi-typelib-path   (getenv "GI_TYPELIB_PATH")))
+              ;; GNOME Weather needs the typelib files of GTK+, Pango etc at 
runtime.
+              (wrap-program (string-append out "/bin/gnome-weather")
+                `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))
+              #t))))))
    (synopsis "Weather monitoring for GNOME desktop")
    (description "GNOME Weather is a small application that allows you to
 monitor the current weather conditions for your city, or anywhere in the



reply via email to

[Prev in Thread] Current Thread [Next in Thread]