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.
This commit is contained in:
parent
02f664a0a3
commit
aae012e91e
1 changed files with 43 additions and 20 deletions
|
@ -230,16 +230,6 @@ provided, as well as a framework to add new color models and data types.")
|
||||||
(list "-Dintrospection=false")
|
(list "-Dintrospection=false")
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-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
|
(add-after 'unpack 'extend-test-time-outs
|
||||||
(lambda _
|
(lambda _
|
||||||
;; Multiply some poorly-chosen time-outs for busy build machines.
|
;; 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)))
|
("json-glib" ,json-glib)))
|
||||||
(inputs
|
(inputs
|
||||||
`(("cairo" ,cairo)
|
`(("cairo" ,cairo)
|
||||||
("graphviz" ,graphviz)
|
|
||||||
("pango" ,pango)
|
("pango" ,pango)
|
||||||
("libpng" ,libpng)
|
("libpng" ,libpng)
|
||||||
("libjpeg" ,libjpeg-turbo)))
|
("libjpeg" ,libjpeg-turbo)))
|
||||||
|
@ -281,14 +270,25 @@ buffers.")
|
||||||
(package
|
(package
|
||||||
(name "gimp")
|
(name "gimp")
|
||||||
(version "2.10.22")
|
(version "2.10.22")
|
||||||
(source (origin
|
(source
|
||||||
(method url-fetch)
|
(origin
|
||||||
(uri (string-append "https://download.gimp.org/pub/gimp/v"
|
(method url-fetch)
|
||||||
(version-major+minor version)
|
(uri (string-append "https://download.gimp.org/pub/gimp/v"
|
||||||
"/gimp-" version ".tar.bz2"))
|
(version-major+minor version)
|
||||||
(sha256
|
"/gimp-" version ".tar.bz2"))
|
||||||
(base32
|
(sha256
|
||||||
"1fqqyshakvdarf1jipk2n33ibqr23ni22z3d8srq13bpydblpf1d"))))
|
(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)
|
(build-system gnu-build-system)
|
||||||
(outputs '("out"
|
(outputs '("out"
|
||||||
"doc")) ; 9 MiB of gtk-doc HTML
|
"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.")
|
transferring the style of an image.")
|
||||||
(license license:gpl3+)))
|
(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
|
(define-public glimpse
|
||||||
(package
|
(package
|
||||||
(name "glimpse")
|
(name "glimpse")
|
||||||
|
@ -635,7 +658,7 @@ transferring the style of an image.")
|
||||||
("poppler-data" ,poppler-data)
|
("poppler-data" ,poppler-data)
|
||||||
("python" ,python-2) ; optional, Python support
|
("python" ,python-2) ; optional, Python support
|
||||||
("python2-pygtk" ,python2-pygtk) ; 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/")
|
(home-page "https://glimpse-editor.github.io/")
|
||||||
(synopsis "Glimpse Image Editor")
|
(synopsis "Glimpse Image Editor")
|
||||||
(description "The Glimpse Image Editor is an application for image
|
(description "The Glimpse Image Editor is an application for image
|
||||||
|
|
Reference in a new issue