guix-commits
[Top][All Lists]
Advanced

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

branch master updated: gnu: gimp: Properly handle missing optional ‘dot’


From: guix-commits
Subject: branch master updated: gnu: gimp: Properly handle missing optional ‘dot’.
Date: Mon, 29 Mar 2021 18:43:21 -0400

This is an automated email from the git hooks/post-receive script.

nckx pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new aae012e  gnu: gimp: Properly handle missing optional ‘dot’.
aae012e is described below

commit aae012e91e66e3edcc486db7bd4939fb34ed3b24
Author: Tobias Geerinckx-Rice <me@tobias.gr>
AuthorDate: Mon Mar 29 23:51:04 2021 +0200

    gnu: gimp: Properly handle missing optional ‘dot’.
    
    * gnu/packages/gimp.scm (gimp)[source]: Add a patch to fix a fatal error
    when ‘dot’ is not in $PATH.
    (gegl)[arguments]: Move the 'refer-to-dot phase...
    [inputs]: ...and graphviz...
    (gegl-for-glimpse)[arguments]: ...here, and...
    [inputs]: ...here, respectively.
    (glimpse)[inputs]: Use gegl-for-glimpse gegl variant.
---
 gnu/packages/gimp.scm | 63 +++++++++++++++++++++++++++++++++++----------------
 1 file changed, 43 insertions(+), 20 deletions(-)

diff --git a/gnu/packages/gimp.scm b/gnu/packages/gimp.scm
index 86b42e0..a0f6b7c 100644
--- a/gnu/packages/gimp.scm
+++ b/gnu/packages/gimp.scm
@@ -230,16 +230,6 @@ provided, as well as a framework to add new color models 
and data types.")
        (list "-Dintrospection=false")
        #:phases
        (modify-phases %standard-phases
-         (add-after 'unpack 'refer-to-dot
-           ;; Without ‘dot’ in $PATH, (at least) the GIMP would fail to start
-           ;; with an extremely obtuse ‘GEGL operation missing!’ error.
-           (lambda _
-             (substitute* "gegl/gegl-dot.c"
-               (("\"dot ")
-                (format #f "\"~a " (which "dot"))))
-             (substitute* "operations/common/introspect.c"
-               (("g_find_program_in_path \\(\"dot\"\\)")
-                (format #f "g_strdup (\"~a\")" (which "dot"))))))
          (add-after 'unpack 'extend-test-time-outs
            (lambda _
              ;; Multiply some poorly-chosen time-outs for busy build machines.
@@ -260,7 +250,6 @@ provided, as well as a framework to add new color models 
and data types.")
        ("json-glib" ,json-glib)))
     (inputs
      `(("cairo" ,cairo)
-       ("graphviz" ,graphviz)
        ("pango" ,pango)
        ("libpng" ,libpng)
        ("libjpeg" ,libjpeg-turbo)))
@@ -281,14 +270,25 @@ buffers.")
   (package
     (name "gimp")
     (version "2.10.22")
-    (source (origin
-              (method url-fetch)
-              (uri (string-append "https://download.gimp.org/pub/gimp/v";
-                                  (version-major+minor version)
-                                  "/gimp-" version ".tar.bz2"))
-              (sha256
-               (base32
-                "1fqqyshakvdarf1jipk2n33ibqr23ni22z3d8srq13bpydblpf1d"))))
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://download.gimp.org/pub/gimp/v";
+                           (version-major+minor version)
+                           "/gimp-" version ".tar.bz2"))
+       (sha256
+        (base32 "1fqqyshakvdarf1jipk2n33ibqr23ni22z3d8srq13bpydblpf1d"))
+       (patches
+        (list (origin
+                ;; This upstream patch fixes a mandatory dependency on ‘dot’:
+                ;; <https://github.com/aferrero2707/gimp-appimage/issues/61>.
+                (method url-fetch)
+                (uri (string-append "https://github.com/GNOME/gimp/commit/";
+                                    "2cae9b9acf9da98c4c9990819ffbd5aabe23017e"
+                                    ".patch"))
+                (sha256
+                 (base32
+                  "1xd5lmy1j9p6p1ka7dyj1b9jmfcra1r62rma07vzw2v4vig0khc0")))))))
     (build-system gnu-build-system)
     (outputs '("out"
                "doc"))                            ; 9 MiB of gtk-doc HTML
@@ -556,6 +556,29 @@ healing the border, increasing the resolution while adding 
detail, and
 transferring the style of an image.")
     (license license:gpl3+)))
 
+(define gegl-for-glimpse
+  ;; Remove this when GIMP commit 2cae9b9acf9da98c4c9990819ffbd5aabe23017e
+  ;; makes it into Glimpse.
+  (package
+    (inherit gegl)
+    (arguments
+     (substitute-keyword-arguments (package-arguments gegl)
+       ((#:phases phases)
+        `(modify-phases ,phases
+           (add-after 'unpack 'refer-to-dot
+             ;; XXX Without ‘dot’ in $PATH, Glimpse would fail to start with an
+             ;; extremely obtuse ‘GEGL operation missing!’ error.
+             (lambda _
+               (substitute* "gegl/gegl-dot.c"
+                 (("\"dot ")
+                  (format #f "\"~a " (which "dot"))))
+               (substitute* "operations/common/introspect.c"
+                 (("g_find_program_in_path \\(\"dot\"\\)")
+                  (format #f "g_strdup (\"~a\")" (which "dot"))))))))))
+    (inputs
+     `(,@(package-inputs gegl)
+       ("graphviz" ,graphviz)))))
+
 (define-public glimpse
   (package
     (name "glimpse")
@@ -635,7 +658,7 @@ transferring the style of an image.")
        ("poppler-data" ,poppler-data)
        ("python" ,python-2)             ; optional, Python support
        ("python2-pygtk" ,python2-pygtk) ; optional, Python support
-       ("gegl" ,gegl)))
+       ("gegl" ,gegl-for-glimpse)))     ; XXX see comment in gegl-for-glimpse
     (home-page "https://glimpse-editor.github.io/";)
     (synopsis "Glimpse Image Editor")
     (description "The Glimpse Image Editor is an application for image



reply via email to

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