aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2024-02-19 21:11:04 -0500
committerLudovic Courtès <ludo@gnu.org>2024-08-31 10:44:58 +0200
commit0933b6b86b8e3a1cb6c82c1cce51974dff2a5205 (patch)
tree468e371034ac54455474ab53c8a2dab7507ac0b1
parent47fe24f1c51c959545cf9ea7380e655afcb4d9e7 (diff)
downloadguix-0933b6b86b8e3a1cb6c82c1cce51974dff2a5205.tar.gz
guix-0933b6b86b8e3a1cb6c82c1cce51974dff2a5205.zip
gnu: inkscape: Fix Python support.
* gnu/packages/inkscape.scm (inkscape/stable) [phases]: Wrap with PATH and GI_TYPELIB_PATH. [inputs]: Sort inputs. Add python-appdirs, python-cssselect, python-pygobject and python-requests. (inkscape) [inputs]: Do not append python-cssselect. Fixes: https://issues.guix.gnu.org/63938 Change-Id: I90a39a04a35dbcafe413726107d100c78d173fd0
-rw-r--r--gnu/packages/inkscape.scm19
1 files changed, 15 insertions, 4 deletions
diff --git a/gnu/packages/inkscape.scm b/gnu/packages/inkscape.scm
index 5449bf8d92..aa33a0a4a3 100644
--- a/gnu/packages/inkscape.scm
+++ b/gnu/packages/inkscape.scm
@@ -245,14 +245,19 @@ endif()~%~%"
(assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))
(add-after 'install 'wrap-program
;; Ensure Python is available at runtime.
- (lambda _
+ (lambda* (#:key inputs #:allow-other-keys)
(wrap-program (string-append #$output "/bin/inkscape")
+ `("PATH" prefix
+ (,(dirname (search-input-file inputs "bin/python"))))
`("GUIX_PYTHONPATH" prefix
(,(getenv "GUIX_PYTHONPATH")))
;; Wrapping GDK_PIXBUF_MODULE_FILE allows Inkscape to load
;; its own icons in pure environments.
`("GDK_PIXBUF_MODULE_FILE" =
- (,(getenv "GDK_PIXBUF_MODULE_FILE")))))))))
+ (,(getenv "GDK_PIXBUF_MODULE_FILE")))
+ ;; Ensure GObject Introspection typelibs are found.
+ `("GI_TYPELIB_PATH" ":" prefix
+ (,(getenv "GI_TYPELIB_PATH")))))))))
(inputs
(list (librsvg-for-system) ;for the pixbuf loader
autotrace
@@ -279,9 +284,16 @@ endif()~%~%"
poppler
popt
potrace
+ ;; These Python dependencies are used by the Inkscape extension
+ ;; management system. To verify that it is working, visit the
+ ;; Extensions -> Manage Extensions... menu.
+ python-appdirs
+ python-cssselect
python-lxml
python-numpy
+ python-pygobject
python-pyserial
+ python-requests
python-scour
python-wrapper
readline))
@@ -337,8 +349,7 @@ as the native format.")
`("GDK_PIXBUF_MODULE_FILE" =
(,(getenv "GDK_PIXBUF_MODULE_FILE"))))))))))
(inputs (modify-inputs (package-inputs inkscape/stable)
- (append imagemagick ;for libMagickCore and libMagickWand
- python-cssselect))) ;to render qrcode
+ (append imagemagick))) ;for libMagickCore and libMagickWand
(native-inputs
(modify-inputs (package-native-inputs inkscape/stable)
;; Only use 1 imagemagick across the package build.