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