guix-commits
[Top][All Lists]
Advanced

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

02/07: gnu: gnome-tweaks: Set the python path.


From: guix-commits
Subject: 02/07: gnu: gnome-tweaks: Set the python path.
Date: Mon, 15 Nov 2021 06:11:34 -0500 (EST)

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

commit 7978b6454bdb4636807caa30681b62de9880e344
Author: Vivien Kraus <vivien@planete-kraus.eu>
AuthorDate: Tue Nov 9 22:57:13 2021 +0000

    gnu: gnome-tweaks: Set the python path.
    
    gnu/packages/gnome.scm (gnome-tweaks)[phase wrap-gi-typelib-and-python]:
    Also wrap with GUIX_PYTHONPATH.
    
    Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
 gnu/packages/gnome.scm | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm
index 0bce8f2..9d1a1c2 100644
--- a/gnu/packages/gnome.scm
+++ b/gnu/packages/gnome.scm
@@ -9860,12 +9860,18 @@ existing databases over the internet.")
                (("gtk-update-icon-cache") "true"))))
          (add-after 'install 'wrap
            (@@ (guix build python-build-system) wrap))
-         (add-after 'wrap 'wrap-gi-typelib
+         (add-after 'wrap 'wrap-gi-typelib-and-python
            (lambda* (#:key inputs outputs #:allow-other-keys)
              (let ((out               (assoc-ref outputs "out"))
                    (gi-typelib-path   (getenv "GI_TYPELIB_PATH")))
-               (wrap-program (string-append out "/bin/gnome-tweaks")
-                 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))))))))
+               (let ((python-path
+                      (string-append out "/lib/python"
+                                     ,(version-major+minor
+                                       (package-version python))
+                                     "/site-packages")))
+                 (wrap-program (string-append out "/bin/gnome-tweaks")
+                   `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))
+                   `("GUIX_PYTHONPATH" ":" prefix (,python-path))))))))))
     (native-inputs
      `(("glib:bin" ,glib "bin") ; for glib-compile-resources, etc.
        ("intltool" ,intltool)



reply via email to

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