gnu: python2-testpath: Remove package.
[jackhill/guix/guix.git] / gnu / packages / gimp.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2016, 2018 Ricardo Wurmus <rekado@elephly.net>
4 ;;; Copyright © 2016, 2017, 2018, 2020 Efraim Flashner <efraim@flashner.co.il>
5 ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
6 ;;; Copyright © 2018, 2020 Leo Famulari <leo@famulari.name>
7 ;;; Copyright © 2018 Thorsten Wilms <t_w_@freenet.de>
8 ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
9 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
10 ;;;
11 ;;; This file is part of GNU Guix.
12 ;;;
13 ;;; GNU Guix is free software; you can redistribute it and/or modify it
14 ;;; under the terms of the GNU General Public License as published by
15 ;;; the Free Software Foundation; either version 3 of the License, or (at
16 ;;; your option) any later version.
17 ;;;
18 ;;; GNU Guix is distributed in the hope that it will be useful, but
19 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
20 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ;;; GNU General Public License for more details.
22 ;;;
23 ;;; You should have received a copy of the GNU General Public License
24 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
25
26 (define-module (gnu packages gimp)
27 #:use-module (guix packages)
28 #:use-module (guix download)
29 #:use-module (guix git-download)
30 #:use-module (guix utils)
31 #:use-module ((guix licenses) #:prefix license:)
32 #:use-module (guix build-system gnu)
33 #:use-module (guix build-system glib-or-gtk)
34 #:use-module (guix build-system meson)
35 #:use-module (gnu packages)
36 #:use-module (gnu packages algebra)
37 #:use-module (gnu packages autotools)
38 #:use-module (gnu packages base)
39 #:use-module (gnu packages build-tools)
40 #:use-module (gnu packages documentation)
41 #:use-module (gnu packages graphviz)
42 #:use-module (gnu packages pkg-config)
43 #:use-module (gnu packages glib)
44 #:use-module (gnu packages gtk)
45 #:use-module (gnu packages gnome)
46 #:use-module (gnu packages graphics)
47 #:use-module (gnu packages image)
48 #:use-module (gnu packages ghostscript)
49 #:use-module (gnu packages compression)
50 #:use-module (gnu packages xml)
51 #:use-module (gnu packages linux)
52 #:use-module (gnu packages ncurses)
53 #:use-module (gnu packages patchutils)
54 #:use-module (gnu packages pdf)
55 #:use-module (gnu packages photo)
56 #:use-module (gnu packages python)
57 #:use-module (gnu packages web)
58 #:use-module (gnu packages xorg))
59
60 (define-public poly2tri-c
61 (package
62 (name "poly2tri-c")
63 (version "0.1.0")
64 (source
65 (origin
66 (method url-fetch)
67 (uri
68 (string-append "https://storage.googleapis.com/"
69 "google-code-archive-source/v2/code.google.com/"
70 "poly2tri-c/source-archive.zip"))
71 (file-name
72 (string-append name "-" version ".zip"))
73 (sha256
74 (base32 "17cw0zhbnf2gb59jm26z0wcarqgdwir9jr1fpi3v9lcvyb2s3mqj"))))
75 (build-system glib-or-gtk-build-system)
76 (outputs '("out" "doc"))
77 (arguments
78 `(#:configure-flags
79 (list
80 "--disable-static")
81 #:phases
82 (modify-phases %standard-phases
83 (add-after 'unpack 'disable-strict-rules
84 (lambda _
85 (substitute* "configure.ac"
86 (("\\$CFLAGS -Wall -ansi -pedantic")
87 "$CFLAGS")
88 (("\\$CFLAGS -Werror")
89 "$CFLAGS"))
90 #t))
91 (add-after 'disable-strict-rules 'fix-build-errors
92 (lambda _
93 (substitute* "poly2tri-c/refine/Makefile.am"
94 (("cdt.c")
95 "rcdt.c")
96 (("cdt.h")
97 "rcdt.h")
98 (("utils.c")
99 "rutils.c")
100 (("utils.h")
101 "rutils.h"))
102 #t))
103 (add-before 'bootstrap 'configure-later
104 (lambda _
105 (setenv "NOCONFIGURE" "set")
106 #t))
107 (add-after 'build 'generate-doc
108 (lambda _
109 (invoke "doxygen")
110 #t))
111 (add-after 'install 'install-doc
112 (lambda* (#:key outputs #:allow-other-keys)
113 (let* ((out (assoc-ref outputs "out"))
114 (doc (assoc-ref outputs "doc")))
115 (copy-recursively
116 "doc"
117 (string-append doc "/share/doc/poly2tri-c"))
118 #t))))))
119 (native-inputs
120 `(("autoconf" ,autoconf)
121 ("automake" ,automake)
122 ("doxygen" ,doxygen)
123 ("libtool" ,libtool)
124 ("pkg-config" ,pkg-config)
125 ("unzip" ,unzip)
126 ("which" ,which)))
127 (propagated-inputs
128 `(("glib" ,glib)))
129 (synopsis "2D constrained Delaunay triangulation library")
130 (description "Poly2Tri-C is a library for generating, refining and rendering
131 2-Dimensional Constrained Delaunay Triangulations.")
132 (home-page "https://code.google.com/archive/p/poly2tri-c/")
133 (license license:bsd-3)))
134
135 (define-public mrg
136 (package
137 (name "mrg")
138 (version "0.1.4")
139 (source
140 (origin
141 (method git-fetch)
142 (uri
143 (git-reference
144 (url "https://github.com/hodefoting/mrg")
145 (commit version)))
146 (file-name
147 (git-file-name name version))
148 (sha256
149 (base32 "106qhh0c11576cc5kh90ds0ram72d3r6n9sadw0y4krnhap6dvwk"))))
150 (build-system meson-build-system)
151 (arguments
152 `(#:glib-or-gtk? #t)) ; To wrap binaries and/or compile schemas
153 (native-inputs
154 `(("pkg-config" ,pkg-config)))
155 (propagated-inputs
156 `(("alsa" ,alsa-lib)
157 ("cairo" ,cairo)
158 ("gtk+" ,gtk+)
159 ("mmm" ,mmm)
160 ("x11" ,libx11)))
161 (synopsis "Microraptor GUI")
162 (description "MrG is is a C API for creating user interfaces. It can be
163 used as an application writing environment or as an interactive canvas for part
164 of a larger interface.")
165 (home-page "https://github.com/hodefoting/mrg")
166 (license license:lgpl2.0+)))
167
168 (define-public babl
169 (package
170 (name "babl")
171 (version "0.1.86")
172 (source (origin
173 (method url-fetch)
174 (uri (list (string-append "https://download.gimp.org/pub/babl/"
175 (version-major+minor version)
176 "/babl-" version ".tar.xz")
177 (string-append "https://ftp.gtk.org/pub/babl/"
178 (version-major+minor version)
179 "/babl-" version ".tar.xz")
180 (string-append "ftp://ftp.gtk.org/pub/babl/"
181 (version-major+minor version)
182 "/babl-" version ".tar.xz")))
183 (sha256
184 (base32
185 "1w68h81kqkqnziixrx21qs0gfv2z79651h19sxn226xdb58mjgqb"))))
186 (build-system meson-build-system)
187 (arguments
188 `(#:meson ,meson-0.55
189 #:configure-flags
190 (list "-Denable-gir=false")))
191 (native-inputs
192 `(("pkg-config" ,pkg-config)))
193 (propagated-inputs
194 ;; Propagated to satisfy ‘babl.pc’.
195 `(("lcms" ,lcms)))
196 (home-page "https://gegl.org/babl/")
197 (synopsis "Image pixel format conversion library")
198 (description
199 "Babl is a dynamic, any-to-any pixel format translation library.
200 It allows converting between different methods of storing pixels, known as
201 @dfn{pixel formats}, that have different bit depths and other data
202 representations, color models, and component permutations.
203
204 A vocabulary to formulate new pixel formats from existing primitives is
205 provided, as well as a framework to add new color models and data types.")
206 (license license:lgpl3+)))
207
208 (define-public gegl
209 (package
210 (name "gegl")
211 (version "0.4.30")
212 (source (origin
213 (method url-fetch)
214 (uri (list (string-append "https://download.gimp.org/pub/gegl/"
215 (string-take version 3)
216 "/gegl-" version ".tar.xz")
217 (string-append "https://ftp.gtk.org/pub/gegl/"
218 (version-major+minor version)
219 "/gegl-" version ".tar.xz")
220 (string-append "ftp://ftp.gtk.org/pub/gegl/"
221 (version-major+minor version)
222 "/gegl-" version ".tar.xz")))
223 (sha256
224 (base32
225 "1pd8xkx70k0fsi1hrzrmaify7112wjmxzk0p6bi6js89yhn7h4n1"))))
226 (build-system meson-build-system)
227 (arguments
228 `(#:meson ,meson-0.55
229 #:configure-flags
230 (list "-Dintrospection=false")
231 #:phases
232 (modify-phases %standard-phases
233 (add-after 'unpack 'extend-test-time-outs
234 (lambda _
235 ;; Multiply some poorly-chosen time-outs for busy build machines.
236 (substitute* "tests/simple/test-node-exponential.c"
237 (("G_TIME_SPAN_SECOND" match)
238 (string-append "10 * " match)))
239 (substitute* "tests/simple/test-buffer-sharing.c"
240 (("g_timeout_add_seconds\\([0-9]+" match)
241 (string-append match "0")))
242 (substitute* (find-files "tests" "^meson\\.build$")
243 (("timeout ?: [0-9]+" match)
244 (string-append match "0")))
245 #t)))))
246 ;; These are propagated to satisfy 'gegl-0.4.pc'.
247 (propagated-inputs
248 `(("babl" ,babl)
249 ("glib" ,glib)
250 ("json-glib" ,json-glib)))
251 (inputs
252 `(("cairo" ,cairo)
253 ("pango" ,pango)
254 ("libpng" ,libpng)
255 ("libjpeg" ,libjpeg-turbo)))
256 (native-inputs
257 `(("pkg-config" ,pkg-config)
258 ("glib" ,glib "bin") ; for gtester
259 ("intltool" ,intltool)))
260 (home-page "https://gegl.org")
261 (synopsis "Graph based image processing framework")
262 (description "GEGL (Generic Graphics Library) provides infrastructure to
263 do demand based cached non destructive image editing on larger than RAM
264 buffers.")
265 ;; The library itself is licensed under LGPL while the sample commandline
266 ;; application and GUI binary gegl is licensed under GPL.
267 (license (list license:lgpl3+ license:gpl3+))))
268
269 (define-public gimp
270 (package
271 (name "gimp")
272 (version "2.10.24")
273 (source
274 (origin
275 (method url-fetch)
276 (uri (string-append "https://download.gimp.org/pub/gimp/v"
277 (version-major+minor version)
278 "/gimp-" version ".tar.bz2"))
279 (sha256
280 (base32 "17lq6ns5qhspd171zqh76yf98xnn5n0hcl7hbhbx63cc6ribf6xx"))))
281 (build-system gnu-build-system)
282 (outputs '("out"
283 "doc")) ; 9 MiB of gtk-doc HTML
284 (arguments
285 '(#:configure-flags
286 (list (string-append "--with-html-dir="
287 (assoc-ref %outputs "doc")
288 "/share/gtk-doc/html")
289
290 ;; Prevent the build system from running 'gtk-update-icon-cache'
291 ;; which is not needed during the build because Guix runs it at
292 ;; profile creation time.
293 "ac_cv_path_GTK_UPDATE_ICON_CACHE=true"
294
295 ;; Disable automatic network request on startup to check for
296 ;; version updates.
297 "--disable-check-update"
298
299 ;; ./configure requests not to annoy upstream with packaging bugs.
300 "--with-bug-report-url=https://bugs.gnu.org/guix")
301 #:phases
302 (modify-phases %standard-phases
303 (add-after 'install 'install-sitecustomize.py
304 ;; Install 'sitecustomize.py' into gimp's python directory to
305 ;; add pygobject and pygtk to pygimp's search path.
306 (lambda* (#:key outputs #:allow-other-keys)
307 (let* ((pythonpath (getenv "PYTHONPATH"))
308 (out (assoc-ref outputs "out"))
309 (sitecustomize.py
310 (string-append
311 out "/lib/gimp/2.0/python/sitecustomize.py")))
312 (call-with-output-file sitecustomize.py
313 (lambda (port)
314 (format port "import site~%")
315 (format port "for dir in '~a'.split(':'):~%" pythonpath)
316 (format port " site.addsitedir(dir)~%")))))))))
317 (inputs
318 `(("babl" ,babl)
319 ("glib" ,glib)
320 ("glib-networking" ,glib-networking)
321 ("libtiff" ,libtiff)
322 ("libwebp" ,libwebp)
323 ("libjpeg" ,libjpeg-turbo)
324 ("atk" ,atk)
325 ("gexiv2" ,gexiv2)
326 ("gtk+" ,gtk+-2)
327 ("libmypaint" ,libmypaint)
328 ("mypaint-brushes" ,mypaint-brushes-1.3)
329 ("exif" ,libexif) ; optional, EXIF + XMP support
330 ("lcms" ,lcms) ; optional, color management
331 ("librsvg" ,librsvg) ; optional, SVG support
332 ("libxcursor" ,libxcursor) ; optional, Mouse Cursor support
333 ("poppler" ,poppler) ; optional, PDF support
334 ("poppler-data" ,poppler-data)
335 ("python" ,python-2) ; optional, Python support
336 ("python2-pygtk" ,python2-pygtk) ; optional, Python support
337 ("gegl" ,gegl)))
338 (native-inputs
339 `(("glib:bin" ,glib "bin") ; for glib-compile-resources and gdbus-codegen
340 ("pkg-config" ,pkg-config)
341 ("intltool" ,intltool)))
342 (home-page "https://www.gimp.org")
343 (synopsis "GNU Image Manipulation Program")
344 (description
345 "GIMP is an application for image manipulation tasks such as photo
346 retouching, composition and authoring. It supports all common image formats
347 as well as specialized ones. It features a highly customizable interface
348 that is extensible via a plugin system.")
349 (license license:gpl3+))) ; some files are lgplv3
350
351 (define-public gimp-fourier
352 (package
353 (name "gimp-fourier")
354 (version "0.4.3-2")
355 (source (origin
356 (method url-fetch)
357 (uri (string-append "http://registry.gimp.org/files/fourier-"
358 version ".tar.gz"))
359 (sha256
360 (base32
361 "1rpacyad678lqgxa3hh2n0zpg4azs8dpa8q079bqsl12812k9184"))))
362 (build-system gnu-build-system)
363 (arguments
364 `(#:tests? #f ;no tests
365 #:phases
366 (modify-phases %standard-phases
367 ;; FIXME: The gegl package only installs "gegl-0.4.pc", but
368 ;; "gimp-2.0.pc" requires "gegl-0.3.pc", so we just copy it.
369 (replace 'configure
370 (lambda* (#:key inputs #:allow-other-keys)
371 (mkdir-p "tmppkgconfig")
372 (copy-file (string-append (assoc-ref inputs "gegl")
373 "/lib/pkgconfig/gegl-0.4.pc")
374 "tmppkgconfig/gegl-0.3.pc")
375 (setenv "PKG_CONFIG_PATH"
376 (string-append "tmppkgconfig:"
377 (or (getenv "PKG_CONFIG_PATH") "")))
378 #t))
379 (add-after 'unpack 'set-prefix
380 (lambda* (#:key outputs #:allow-other-keys)
381 ;; gimptool-2.0 does not allow us to install to any target
382 ;; directory.
383 (let ((target (string-append (assoc-ref outputs "out")
384 "/lib/gimp/"
385 (car (string-split ,(package-version gimp) #\.))
386 ".0/plug-ins")))
387 (substitute* "Makefile"
388 (("\\$\\(PLUGIN_INSTALL\\) fourier")
389 (string-append "cp fourier " target)))
390 (mkdir-p target))
391 #t)))))
392 (inputs
393 `(("fftw" ,fftw)
394 ("gimp" ,gimp)
395 ;; needed by gimp-2.0.pc
396 ("gdk-pixbuf" ,gdk-pixbuf)
397 ("gegl" ,gegl)
398 ("cairo" ,cairo)
399 ("glib" ,glib)
400 ;; needed by gimpui-2.0.pc
401 ("gtk+" ,gtk+-2)))
402 (native-inputs
403 `(("pkg-config" ,pkg-config)))
404 (home-page "https://www.lprp.fr/gimp_plugin_en/#fourier")
405 (synopsis "GIMP plug-in to edit image in fourier space")
406 (description
407 "This package provides a simple plug-in to apply the fourier transform on
408 an image, allowing you to work with the transformed image inside GIMP. You
409 can draw or apply filters in fourier space and get the modified image with an
410 inverse fourier transform.")
411 (license license:gpl3+)))
412
413 (define-public libmypaint
414 (package
415 (name "libmypaint")
416 (version "1.6.1")
417 (source (origin
418 (method url-fetch)
419 (uri (string-append "https://github.com/mypaint/libmypaint/"
420 "releases/download/v" version "/libmypaint-"
421 version ".tar.xz"))
422 (sha256
423 (base32
424 "0priwpmc7dizccqvn21ig6d649bprl3xl1hmjj7nddznjgr585vl"))))
425 (build-system gnu-build-system)
426 (native-inputs
427 `(("intltool" ,intltool)
428 ("pkg-config" ,pkg-config)))
429 ;; As needed by 'libmypaint.pc'.
430 (propagated-inputs
431 `(("json-c" ,json-c)
432 ("gobject-introspection" ,gobject-introspection)))
433 (inputs
434 `(("glib" ,glib)))
435 (synopsis "Artistic brushes library")
436 (description "Libmypaint, also called \"brushlib\", is a library for making
437 brushstrokes which is used by MyPaint and GIMP.")
438 (home-page "http://mypaint.org")
439 (license license:isc)))
440
441 (define-public mypaint-brushes
442 (package
443 (name "mypaint-brushes")
444 (version "2.0.2")
445 (source
446 (origin
447 (method git-fetch)
448 (uri (git-reference
449 (url "https://github.com/mypaint/mypaint-brushes")
450 (commit (string-append "v" version))))
451 (file-name (git-file-name name version))
452 (sha256
453 (base32 "0kcqz13vzpy24dhmrx9hbs6s7hqb8y305vciznm15h277sabpmw9"))))
454 (build-system gnu-build-system)
455 (native-inputs
456 `(("autoconf" ,autoconf)
457 ("automake" ,automake)))
458 (synopsis "Default brushes for MyPaint")
459 (description "This package provides the default set of brushes for
460 MyPaint.")
461 (home-page "https://github.com/mypaint/mypaint-brushes/")
462 ;; Scripts are distributed under GPL2+ terms, brushes are provided as
463 ;; public domain or under CC0 terms.
464 (license (list license:gpl2+ license:cc0 license:public-domain))))
465
466 (define-public mypaint-brushes-1.3
467 (package
468 (inherit mypaint-brushes)
469 (name "mypaint-brushes")
470 (version "1.3.1")
471 (source
472 (origin
473 (method git-fetch)
474 (uri (git-reference
475 (url "https://github.com/mypaint/mypaint-brushes")
476 (commit (string-append "v" version))))
477 (file-name (git-file-name name version))
478 (sha256
479 (base32 "1c95l1vfz7sbrdlzrbz7h1p6s1k113kyjfd9wfnxlm0p6562cz3j"))))))
480
481 (define-public gimp-resynthesizer
482 ;; GIMP does not respect any plugin search path environment variable, so after
483 ;; installation users have to edit their GIMP settings to include
484 ;; "$HOME/.guix-profile/lib/gimp/2.0/plug-ins/" in
485 ;; “Edit->Preferences->Folders->Plug Ins”.
486 (package
487 (name "gimp-resynthesizer")
488 (version "2.0.3")
489 (source
490 (origin
491 (method git-fetch)
492 (uri (git-reference
493 (url "https://github.com/bootchk/resynthesizer")
494 (commit (string-append "v" version))))
495 (sha256
496 (base32
497 "1jwc8bhhm21xhrgw56nzbma6fwg59gc8anlmyns7jdiw83y0zx3j"))
498 (file-name (git-file-name name version))))
499 (build-system gnu-build-system)
500 (arguments
501 `( ;; Turn off tests to avoid:
502 ;; make[1]: *** No rule to make target '../src/resynth-gui.c', needed by 'resynthesizer.pot'. Stop.
503 #:tests? #f
504 #:phases
505 (modify-phases %standard-phases
506 (add-after 'unpack 'set-env
507 (lambda _
508 (setenv "CONFIG_SHELL" (which "sh"))
509 #t))
510 (add-after 'configure 'set-prefix
511 ;; Install plugin under $prefix, not under GIMP's libdir.
512 (lambda* (#:key outputs #:allow-other-keys)
513 (let ((target (string-append (assoc-ref outputs "out")
514 "/lib/gimp/"
515 ,(version-major
516 (package-version gimp))
517 ".0")))
518 (substitute* (list "src/resynthesizer/Makefile"
519 "src/resynthesizer-gui/Makefile")
520 (("GIMP_LIBDIR = .*")
521 (string-append "GIMP_LIBDIR = " target "\n")))
522 (mkdir-p target)
523 #t))))))
524 (native-inputs
525 ;; avoid ./autogen.sh: ./configure: /bin/sh: bad interpreter:
526 ;; No such file or directory
527 `(("autoconf" ,autoconf-wrapper)
528 ("automake" ,automake)
529 ("glib" ,glib "bin") ; glib-gettextize
530 ("intltool" ,intltool)
531 ("pkg-config" ,pkg-config)))
532 (inputs
533 `(("gimp" ,gimp)
534 ("gdk-pixbuf" ,gdk-pixbuf) ; needed by gimp-2.0.pc
535 ("cairo" ,cairo)
536 ("gegl" ,gegl)
537 ("gtk+" ,gtk+-2) ; needed by gimpui-2.0.pc
538 ("glib" ,glib)))
539 (home-page "https://github.com/bootchk/resynthesizer")
540 (synopsis "GIMP plugins for texture synthesis")
541 (description
542 "This package provides resynthesizer plugins for GIMP, which encompasses
543 tools for healing selections (content-aware fill), enlarging the canvas and
544 healing the border, increasing the resolution while adding detail, and
545 transferring the style of an image.")
546 (license license:gpl3+)))
547
548 (define gegl-for-glimpse
549 ;; Remove this when GIMP commit 2cae9b9acf9da98c4c9990819ffbd5aabe23017e
550 ;; makes it into Glimpse.
551 (package
552 (inherit gegl)
553 (arguments
554 (substitute-keyword-arguments (package-arguments gegl)
555 ((#:phases phases)
556 `(modify-phases ,phases
557 (add-after 'unpack 'refer-to-dot
558 ;; XXX Without ‘dot’ in $PATH, Glimpse would fail to start with an
559 ;; extremely obtuse ‘GEGL operation missing!’ error.
560 (lambda _
561 (substitute* "gegl/gegl-dot.c"
562 (("\"dot ")
563 (format #f "\"~a " (which "dot"))))
564 (substitute* "operations/common/introspect.c"
565 (("g_find_program_in_path \\(\"dot\"\\)")
566 (format #f "g_strdup (\"~a\")" (which "dot"))))))))))
567 (inputs
568 `(,@(package-inputs gegl)
569 ("graphviz" ,graphviz)))))
570
571 (define-public glimpse
572 (package
573 (name "glimpse")
574 (version "0.2.0")
575 (source (origin
576 (method git-fetch)
577 (uri (git-reference
578 (url "https://github.com/glimpse-editor/Glimpse")
579 (commit (string-append "v" version))))
580 (file-name (git-file-name name version))
581 (sha256
582 (base32
583 "0drngj2xqzxfaag6pc4xjffiw003n4y43x5rb5bf4ziv1ac51dm9"))))
584 (build-system gnu-build-system)
585 (outputs '("out"
586 "doc")) ; 9 MiB of gtk-doc HTML
587 (arguments
588 '(#:configure-flags
589 (list (string-append "--with-html-dir="
590 (assoc-ref %outputs "doc")
591 "/share/gtk-doc/html")
592 "--enable-gtk-doc"
593
594 ;; Prevent the build system from running 'gtk-update-icon-cache'
595 ;; which is not needed during the build because Guix runs it at
596 ;; profile creation time.
597 "ac_cv_path_GTK_UPDATE_ICON_CACHE=true"
598
599 ;; Disable automatic network request on startup to check for
600 ;; version updates.
601 "--disable-check-update"
602
603 ;; ./configure requests not to annoy upstream with packaging bugs.
604 "--with-bug-report-url=https://bugs.gnu.org/guix")
605 #:phases
606 (modify-phases %standard-phases
607 (add-after 'install 'install-sitecustomize.py
608 ;; Install 'sitecustomize.py' into glimpse's python directory to
609 ;; add pygobject and pygtk to pygimp's search path.
610 (lambda* (#:key outputs #:allow-other-keys)
611 (let* ((pythonpath (getenv "PYTHONPATH"))
612 (out (assoc-ref outputs "out"))
613 (sitecustomize.py
614 (string-append
615 out "/lib/glimpse/2.0/python/sitecustomize.py")))
616 (call-with-output-file sitecustomize.py
617 (lambda (port)
618 (format port "import site~%")
619 (format port "for dir in '~a'.split(':'):~%" pythonpath)
620 (format port " site.addsitedir(dir)~%")))))))))
621 (native-inputs
622 `(("autoconf" ,autoconf)
623 ("automake" ,automake)
624 ("gtk-doc" ,gtk-doc)
625 ("intltool" ,intltool)
626 ("libtool" ,libtool)
627 ("libxslt" ,libxslt) ; for xsltproc
628 ("pkg-config" ,pkg-config)
629 ("glib:bin" ,glib "bin"))) ; for gdbus-codegen
630 (inputs
631 `(("babl" ,babl)
632 ("glib" ,glib)
633 ("glib-networking" ,glib-networking)
634 ("libtiff" ,libtiff)
635 ("libwebp" ,libwebp)
636 ("libjpeg" ,libjpeg-turbo)
637 ("atk" ,atk)
638 ("gexiv2" ,gexiv2)
639 ("gtk+" ,gtk+-2)
640 ("libmypaint" ,libmypaint)
641 ("mypaint-brushes" ,mypaint-brushes-1.3)
642 ("exif" ,libexif) ; optional, EXIF + XMP support
643 ("lcms" ,lcms) ; optional, color management
644 ("librsvg" ,librsvg) ; optional, SVG support
645 ("libxcursor" ,libxcursor) ; optional, Mouse Cursor support
646 ("poppler" ,poppler) ; optional, PDF support
647 ("poppler-data" ,poppler-data)
648 ("python" ,python-2) ; optional, Python support
649 ("python2-pygtk" ,python2-pygtk) ; optional, Python support
650 ("gegl" ,gegl-for-glimpse))) ; XXX see comment in gegl-for-glimpse
651 (home-page "https://glimpse-editor.github.io/")
652 (synopsis "Glimpse Image Editor")
653 (description "The Glimpse Image Editor is an application for image
654 manipulation tasks such as photo retouching, composition and authoring.
655 It supports all common image formats as well as specialized ones. It
656 features a highly customizable interface that is extensible via a plugin
657 system. It was forked from the GNU Image Manipulation Program.")
658 (license license:gpl3+)))