gnu: ubridge: Update to 0.9.18.
[jackhill/guix/guix.git] / gnu / packages / gtk.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2014, 2015, 2017, 2018, 2019 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014 Eric Bavier <bavier@member.fsf.org>
6 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
7 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
8 ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
9 ;;; Copyright © 2015 Andy Wingo <wingo@igalia.com>
10 ;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
11 ;;; Coypright © 2015, 2016, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
12 ;;; Copyright © 2016, 2017, 2020 Efraim Flashner <efraim@flashner.co.il>
13 ;;; Copyright © 2016 Fabian Harfert <fhmgufs@web.de>
14 ;;; Copyright © 2016 Kei Kebreau <kkebreau@posteo.net>
15 ;;; Copyright © 2016 Patrick Hetu <patrick.hetu@auf.org>
16 ;;; Copyright © 2016 Nikita <nikita@n0.is>
17 ;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
18 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
19 ;;; Copyright © 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
20 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
21 ;;; Copyright © 2018, 2020 Arun Isaac <arunisaac@systemreboot.net>
22 ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
23 ;;; Copyright © 2019 Meiyo Peng <meiyo@riseup.net>
24 ;;; Copyright © 2019 Giacomo Leidi <goodoldpaul@autistici.org>
25 ;;; Copyright © 2020 Brendan Tildesley <mail@brendan.scot>
26 ;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net>
27 ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
28 ;;;
29 ;;; This file is part of GNU Guix.
30 ;;;
31 ;;; GNU Guix is free software; you can redistribute it and/or modify it
32 ;;; under the terms of the GNU General Public License as published by
33 ;;; the Free Software Foundation; either version 3 of the License, or (at
34 ;;; your option) any later version.
35 ;;;
36 ;;; GNU Guix is distributed in the hope that it will be useful, but
37 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
38 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
39 ;;; GNU General Public License for more details.
40 ;;;
41 ;;; You should have received a copy of the GNU General Public License
42 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
43
44 (define-module (gnu packages gtk)
45 #:use-module ((guix licenses) #:prefix license:)
46 #:use-module (guix utils)
47 #:use-module (guix packages)
48 #:use-module (guix download)
49 #:use-module (guix git-download)
50 #:use-module (guix build-system glib-or-gtk)
51 #:use-module (guix build-system gnu)
52 #:use-module (guix build-system meson)
53 #:use-module (guix build-system perl)
54 #:use-module (guix build-system python)
55 #:use-module (guix build-system waf)
56 #:use-module (gnu packages)
57 #:use-module (gnu packages algebra)
58 #:use-module (gnu packages autotools)
59 #:use-module (gnu packages base)
60 #:use-module (gnu packages texinfo)
61 #:use-module (gnu packages check)
62 #:use-module (gnu packages compression)
63 #:use-module (gnu packages docbook)
64 #:use-module (gnu packages enchant)
65 #:use-module (gnu packages fontutils)
66 #:use-module (gnu packages freedesktop)
67 #:use-module (gnu packages fribidi)
68 #:use-module (gnu packages gettext)
69 #:use-module (gnu packages ghostscript)
70 #:use-module (gnu packages gl)
71 #:use-module (gnu packages glib)
72 #:use-module (gnu packages gnome)
73 #:use-module (gnu packages icu4c)
74 #:use-module (gnu packages image)
75 #:use-module (gnu packages libffi)
76 #:use-module (gnu packages linux)
77 #:use-module (gnu packages pdf)
78 #:use-module (gnu packages perl)
79 #:use-module (gnu packages pkg-config)
80 #:use-module (gnu packages pretty-print)
81 #:use-module (gnu packages python)
82 #:use-module (gnu packages python-xyz)
83 #:use-module (gnu packages guile)
84 #:use-module (gnu packages guile-xyz)
85 #:use-module (gnu packages cups)
86 #:use-module (gnu packages xml)
87 #:use-module (gnu packages xorg)
88 #:use-module (gnu packages xdisorg)
89 #:use-module (srfi srfi-1)
90 #:use-module (srfi srfi-26)
91 #:use-module (ice-9 match))
92
93 (define-public atk
94 (package
95 (name "atk")
96 (version "2.34.1")
97 (source (origin
98 (method url-fetch)
99 (uri (string-append "mirror://gnome/sources/" name "/"
100 (version-major+minor version) "/"
101 name "-" version ".tar.xz"))
102 (sha256
103 (base32
104 "1jwp16r6p5z66k4b2v8zlzhyshhwlmyi27ippkrgqr8jsary7w6l"))))
105 (build-system meson-build-system)
106 (propagated-inputs `(("glib" ,glib))) ; required by atk.pc
107 (native-inputs
108 `(("pkg-config" ,pkg-config)
109 ("gettext" ,gettext-minimal)
110 ("glib" ,glib "bin") ; glib-mkenums, etc.
111 ("gobject-introspection" ,gobject-introspection))) ; g-ir-compiler, etc.
112 (synopsis "GNOME accessibility toolkit")
113 (description
114 "ATK provides the set of accessibility interfaces that are implemented
115 by other toolkits and applications. Using the ATK interfaces, accessibility
116 tools have full access to view and control running applications.")
117 (license license:lgpl2.0+)
118 (home-page "https://developer.gnome.org/atk/")))
119
120 (define-public cairo
121 (package
122 (name "cairo")
123 (version "1.16.0")
124 (source (origin
125 (method url-fetch)
126 (uri (string-append "https://cairographics.org/releases/cairo-"
127 version ".tar.xz"))
128 (sha256
129 (base32
130 "0c930mk5xr2bshbdljv005j3j8zr47gqmkry3q6qgvqky6rjjysy"))))
131 (build-system gnu-build-system)
132 (propagated-inputs
133 `(("fontconfig" ,fontconfig)
134 ("freetype" ,freetype)
135 ("glib" ,glib)
136 ("libpng" ,libpng)
137 ("libx11" ,libx11)
138 ("libxext" ,libxext)
139 ("libxrender" ,libxrender)
140 ("pixman" ,pixman)))
141 (inputs
142 `(("ghostscript" ,ghostscript)
143 ("libspectre" ,libspectre)
144 ("poppler" ,poppler)
145 ("xorgproto" ,xorgproto)
146 ("zlib" ,zlib)))
147 (native-inputs
148 `(("pkg-config" ,pkg-config)
149 ("python" ,python-wrapper)))
150 (arguments
151 `(#:tests? #f ; see http://lists.gnu.org/archive/html/bug-guix/2013-06/msg00085.html
152 #:configure-flags '("--enable-tee" ;needed for GNU Icecat
153 "--enable-xml" ;for cairo-xml support
154 "--disable-static")))
155 (synopsis "2D graphics library")
156 (description
157 "Cairo is a 2D graphics library with support for multiple output devices.
158 Currently supported output targets include the X Window System (via both
159 Xlib and XCB), Quartz, Win32, image buffers, PostScript, PDF, and SVG file
160 output. Experimental backends include OpenGL, BeOS, OS/2, and DirectFB.
161
162 Cairo is designed to produce consistent output on all output media while
163 taking advantage of display hardware acceleration when available
164 eg. through the X Render Extension).
165
166 The cairo API provides operations similar to the drawing operators of
167 PostScript and PDF. Operations in cairo including stroking and filling cubic
168 Bézier splines, transforming and compositing translucent images, and
169 antialiased text rendering. All drawing operations can be transformed by any
170 affine transformation (scale, rotation, shear, etc.).")
171 (license license:lgpl2.1) ; or Mozilla Public License 1.1
172 (home-page "https://cairographics.org/")))
173
174 (define-public cairo-xcb
175 (package
176 (inherit cairo)
177 (name "cairo-xcb")
178 (inputs
179 `(("mesa" ,mesa)
180 ,@(package-inputs cairo)))
181 (arguments
182 `(#:tests? #f
183 #:configure-flags
184 '("--enable-xlib-xcb" "--enable-gl" "--enable-egl")))
185 (synopsis "2D graphics library (with X11 support)")))
186
187 (define-public harfbuzz
188 (package
189 (name "harfbuzz")
190 (version "2.6.4")
191 (source (origin
192 (method url-fetch)
193 (uri (string-append "https://www.freedesktop.org/software/"
194 "harfbuzz/release/harfbuzz-"
195 version ".tar.xz"))
196 (sha256
197 (base32
198 "04iwq13w6zkdhljmsxrzgg4fyh04qnwfn57rgrl9kmijc7cvh4wl"))))
199 (build-system gnu-build-system)
200 (outputs '("out"
201 "bin")) ; 160K, only hb-view depend on cairo
202 (inputs
203 `(("cairo" ,cairo)))
204 (propagated-inputs
205 ;; There are all in the Requires or Requires.private field of '.pc'.
206 `(("glib" ,glib)
207 ("graphite2" ,graphite2)
208 ("icu4c" ,icu4c)))
209 (native-inputs
210 `(("glib:bin" ,glib "bin") ;for glib-mkenums
211 ("gobject-introspection" ,gobject-introspection)
212 ("pkg-config" ,pkg-config)
213 ("python" ,python-wrapper)
214 ("which" ,which)))
215 (arguments
216 `(#:configure-flags `("--with-graphite2"
217 "--with-gobject"
218 ,(string-append
219 "--bindir=" (assoc-ref %outputs "bin") "/bin"))))
220 (synopsis "OpenType text shaping engine")
221 (description
222 "HarfBuzz is an OpenType text shaping engine.")
223 (license (license:x11-style "file://COPYING"
224 "See 'COPYING' in the distribution."))
225 (home-page "https://www.freedesktop.org/wiki/Software/HarfBuzz/")))
226
227 (define-public pango
228 (package
229 (name "pango")
230 (version "1.44.7")
231 (source (origin
232 (method url-fetch)
233 (uri (string-append "mirror://gnome/sources/pango/"
234 (version-major+minor version) "/"
235 name "-" version ".tar.xz"))
236 (patches (search-patches "pango-skip-libthai-test.patch"))
237 (sha256
238 (base32
239 "07qvxa2sk90chp1l12han6vxvy098mc37sdqcznyywyv2g6bd9b6"))))
240 (build-system meson-build-system)
241 (arguments
242 '(#:phases (modify-phases %standard-phases
243 (add-after 'unpack 'disable-cantarell-tests
244 (lambda _
245 (substitute* "tests/meson.build"
246 ;; XXX FIXME: These tests require "font-cantarell", but
247 ;; adding it here would introduce a circular dependency.
248 (("\\[ 'test-harfbuzz'.*") "")
249 (("\\[ 'test-itemize'.*") "")
250 (("\\[ 'test-layout'.*") ""))
251 #t)))))
252 (propagated-inputs
253 ;; These are all in Requires or Requires.private of the '.pc' files.
254 `(("cairo" ,cairo)
255 ("fribidi" ,fribidi)
256 ("fontconfig" ,fontconfig)
257 ("freetype" ,freetype)
258 ("glib" ,glib)
259 ("harfbuzz" ,harfbuzz)
260
261 ;; Some packages, such as Openbox, expect Pango to be built with the
262 ;; optional libxft support.
263 ("libxft" ,libxft)))
264 (inputs
265 `(("zlib" ,zlib)))
266 (native-inputs
267 `(("pkg-config" ,pkg-config)
268 ("glib" ,glib "bin") ; glib-mkenums, etc.
269 ("gobject-introspection" ,gobject-introspection))) ; g-ir-compiler, etc.
270 (synopsis "GNOME text and font handling library")
271 (description
272 "Pango is the core text and font handling library used in GNOME
273 applications. It has extensive support for the different writing systems
274 used throughout the world.")
275 (license license:lgpl2.0+)
276 (home-page "https://developer.gnome.org/pango/")))
277
278 (define-public pango-1.42
279 (package
280 (inherit pango)
281 (version "1.42.4")
282 (source (origin
283 (method url-fetch)
284 (uri (string-append "mirror://gnome/sources/pango/"
285 (version-major+minor version) "/"
286 "pango-" version ".tar.xz"))
287 (sha256
288 (base32
289 "17bwb7dgbncrfsmchlib03k9n3xaalirb39g3yb43gg8cg6p8aqx"))))
290 (build-system gnu-build-system)
291 (arguments '())))
292
293 (define-public pangox-compat
294 (package
295 (name "pangox-compat")
296 (version "0.0.2")
297 (source (origin
298 (method url-fetch)
299 (uri (string-append "mirror://gnome/sources/" name "/"
300 (version-major+minor version) "/"
301 name "-" version ".tar.xz"))
302 (sha256
303 (base32
304 "0ip0ziys6mrqqmz4n71ays0kf5cs1xflj1gfpvs4fgy2nsrr482m"))))
305 (build-system gnu-build-system)
306 (inputs
307 `(("glib" ,glib)
308 ("pango" ,pango-1.42)))
309 (native-inputs
310 `(("intltool" ,intltool)
311 ("pkg-config" ,pkg-config)))
312 (home-page "https://developer.gnome.org/pango")
313 (synopsis "Obsolete pango functions")
314 (description "Pangox was a X backend to pango. It is now obsolete and no
315 longer provided by recent pango releases. pangox-compat provides the
316 functions which were removed.")
317 (license license:lgpl2.0+)))
318
319 (define-public ganv
320 (package
321 (name "ganv")
322 (version "1.6.0")
323 (source (origin
324 (method url-fetch)
325 (uri (string-append "https://download.drobilla.net/ganv-"
326 version ".tar.bz2"))
327 (sha256
328 (base32
329 "0pik2d3995z0rjcjhb4hsj5fsph3m8khg6j10k6mx4j2j727aq6l"))))
330 (build-system waf-build-system)
331 (arguments
332 `(#:phases
333 (modify-phases %standard-phases
334 (add-before 'configure 'set-flags
335 (lambda* (#:key outputs #:allow-other-keys)
336 ;; Allow 'bin/ganv_bench' to find libganv-1.so.
337 (setenv "LDFLAGS"
338 (string-append "-Wl,-rpath="
339 (assoc-ref outputs "out") "/lib"))
340 #t)))
341 #:tests? #f)) ; no check target
342 (inputs
343 `(("gtk" ,gtk+-2)
344 ("gtkmm" ,gtkmm-2)))
345 (native-inputs
346 `(("glib" ,glib "bin") ; for glib-genmarshal, etc.
347 ("pkg-config" ,pkg-config)))
348 (home-page "https://drobilla.net/software/ganv/")
349 (synopsis "GTK+ widget for interactive graph-like environments")
350 (description
351 "Ganv is an interactive GTK+ widget for interactive “boxes and lines” or
352 graph-like environments, e.g. modular synths or finite state machine
353 diagrams.")
354 (license license:gpl3+)))
355
356 (define-public ganv-devel
357 (let ((commit "12f7d6b0438c94dd87f773a92eee3453d971846e")
358 (revision "1"))
359 (package
360 (inherit ganv)
361 (name "ganv")
362 (version (string-append "1.5.4-" revision "."
363 (string-take commit 9)))
364 (source (origin
365 (method git-fetch)
366 (uri (git-reference
367 (url "https://git.drobilla.net/ganv.git")
368 (commit commit)))
369 (file-name (git-file-name name version))
370 (sha256
371 (base32
372 "1cr8w02lr6bk9mkxa12j3imq721b2an2yn4bj5wnwmpm91ddn2gi")))))))
373
374 (define-public gtksourceview-2
375 (package
376 (name "gtksourceview")
377 (version "2.10.5") ; This is the last version which builds against gtk+2
378 (source (origin
379 (method url-fetch)
380 (uri (string-append "mirror://gnome/sources/" name "/"
381 (version-major+minor version) "/"
382 name "-" version ".tar.bz2"))
383 (sha256
384 (base32
385 "07hrabhpl6n8ajz10s0d960jdwndxs87szxyn428mpxi8cvpg1f5"))
386 (patches
387 (search-patches
388 "gtksourceview-2-add-default-directory.patch"))))
389 (build-system gnu-build-system)
390 (native-inputs
391 `(("intltool" ,intltool)
392 ("glib" ,glib "bin") ; for glib-genmarshal, etc.
393 ("pkg-config" ,pkg-config)
394 ;; For testing.
395 ("xorg-server" ,xorg-server-for-tests)
396 ("shared-mime-info" ,shared-mime-info)))
397 (propagated-inputs
398 ;; As per the pkg-config file.
399 `(("gtk" ,gtk+-2)
400 ("libxml2" ,libxml2)))
401 (arguments
402 `(#:phases
403 ;; Unfortunately, some of the tests in "make check" are highly dependent
404 ;; on the environment therefore, some black magic is required.
405 (modify-phases %standard-phases
406 (add-before 'check 'start-xserver
407 (lambda* (#:key inputs #:allow-other-keys)
408 (let ((xorg-server (assoc-ref inputs "xorg-server"))
409 (mime (assoc-ref inputs "shared-mime-info")))
410
411 ;; There must be a running X server and make check doesn't start one.
412 ;; Therefore we must do it.
413 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
414 (setenv "DISPLAY" ":1")
415
416 ;; The .lang files must be found in $XDG_DATA_HOME/gtksourceview-2.0
417 (system "ln -s gtksourceview gtksourceview-2.0")
418 (setenv "XDG_DATA_HOME" (getcwd))
419
420 ;; Finally, the mimetypes must be available.
421 (setenv "XDG_DATA_DIRS" (string-append mime "/share/")))
422 #t)))))
423 (synopsis "Widget that extends the standard GTK+ 2.x 'GtkTextView' widget")
424 (description
425 "GtkSourceView is a portable C library that extends the standard GTK+
426 framework for multiline text editing with support for configurable syntax
427 highlighting, unlimited undo/redo, search and replace, a completion framework,
428 printing and other features typical of a source code editor.")
429 (license license:lgpl2.0+)
430 (home-page "https://developer.gnome.org/gtksourceview/")))
431
432 (define-public gtksourceview
433 (package
434 (name "gtksourceview")
435 (version "4.2.0")
436 (source (origin
437 (method url-fetch)
438 (uri (string-append "mirror://gnome/sources/gtksourceview/"
439 (version-major+minor version) "/"
440 "gtksourceview-" version ".tar.xz"))
441 (sha256
442 (base32
443 "0xgnjj7jd56wbl99s76sa1vjq9bkz4mdsxwgwlcphg689liyncf4"))))
444 (build-system gnu-build-system)
445 (arguments
446 '(#:phases
447 (modify-phases %standard-phases
448 (add-before
449 'check 'pre-check
450 (lambda* (#:key inputs #:allow-other-keys)
451 (let ((xorg-server (assoc-ref inputs "xorg-server")))
452 ;; Tests require a running X server.
453 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
454 (setenv "DISPLAY" ":1")
455 ;; For the missing /etc/machine-id.
456 (setenv "DBUS_FATAL_WARNINGS" "0")
457 #t))))))
458 (native-inputs
459 `(("glib:bin" ,glib "bin") ; for glib-genmarshal, etc.
460 ("intltool" ,intltool)
461 ("itstool" ,itstool)
462 ("gobject-introspection" ,gobject-introspection)
463 ("pkg-config" ,pkg-config)
464 ("vala" ,vala)
465 ;; For testing.
466 ("xorg-server" ,xorg-server-for-tests)
467 ("shared-mime-info" ,shared-mime-info)))
468 (propagated-inputs
469 ;; gtksourceview-3.0.pc refers to all these.
470 `(("glib" ,glib)
471 ("gtk+" ,gtk+)
472 ("libxml2" ,libxml2)))
473 (home-page "https://wiki.gnome.org/Projects/GtkSourceView")
474 (synopsis "GNOME source code widget")
475 (description "GtkSourceView is a text widget that extends the standard
476 GTK+ text widget GtkTextView. It improves GtkTextView by implementing syntax
477 highlighting and other features typical of a source code editor.")
478 (license license:lgpl2.1+)))
479
480 (define-public gtksourceview-3
481 (package (inherit gtksourceview)
482 (name "gtksourceview")
483 (version "3.24.10")
484 (source (origin
485 (method url-fetch)
486 (uri (string-append "mirror://gnome/sources/" name "/"
487 (version-major+minor version) "/"
488 name "-" version ".tar.xz"))
489 (sha256
490 (base32
491 "16ym7jwiki4s1pilwr4incx0yg7ll94f1cajrnpndkxxs36hcm5b"))))))
492
493 (define-public gdk-pixbuf
494 (package
495 (name "gdk-pixbuf")
496 (version "2.40.0")
497 (source (origin
498 (method url-fetch)
499 (uri (string-append "mirror://gnome/sources/" name "/"
500 (version-major+minor version) "/"
501 name "-" version ".tar.xz"))
502 (sha256
503 (base32
504 "1rnlx9yfw970maxi2x6niaxmih5la11q1ilr7gzshz2kk585k0hm"))))
505 (build-system meson-build-system)
506 (arguments
507 `(#:configure-flags '("-Dinstalled_tests=false")
508 #:phases
509 (modify-phases %standard-phases
510 (add-after
511 'unpack 'disable-failing-tests
512 (lambda _
513 (substitute* "tests/meson.build"
514 ;; XXX FIXME: This test fails on armhf machines with:
515 ;; SKIP Not enough memory to load bitmap image
516 ;; ERROR: cve-2015-4491 - too few tests run (expected 4, got 2)
517 ((".*'cve-2015-4491'.*") "")
518 ;; XXX FIXME: This test fails with:
519 ;; ERROR:pixbuf-jpeg.c:74:test_type9_rotation_exif_tag:
520 ;; assertion failed (error == NULL): Data differ
521 ;; (gdk-pixbuf-error-quark, 0)
522 ((".*'pixbuf-jpeg'.*") ""))
523 #t))
524 ;; The slow tests take longer than the specified timeout.
525 ,@(if (any (cute string=? <> (%current-system))
526 '("armhf-linux" "aarch64-linux"))
527 '((replace 'check
528 (lambda _
529 (invoke "meson" "test" "--timeout-multiplier" "5"))))
530 '()))))
531 (propagated-inputs
532 `(;; Required by gdk-pixbuf-2.0.pc
533 ("glib" ,glib)
534 ("libpng" ,libpng)
535 ;; Used for testing and required at runtime.
536 ("shared-mime-info" ,shared-mime-info)))
537 (inputs
538 `(("libjpeg" ,libjpeg-turbo)
539 ("libtiff" ,libtiff)
540 ("libx11" ,libx11)))
541 (native-inputs
542 `(("pkg-config" ,pkg-config)
543 ("gettext" ,gettext-minimal)
544 ("glib" ,glib "bin") ; glib-mkenums, etc.
545 ("gobject-introspection" ,gobject-introspection))) ; g-ir-compiler, etc.
546 (synopsis "GNOME image loading and manipulation library")
547 (description
548 "GdkPixbuf is a library for image loading and manipulation developed
549 in the GNOME project.")
550 (license license:lgpl2.0+)
551 (home-page "https://developer.gnome.org/gdk-pixbuf/")))
552
553 ;; To build gdk-pixbuf with SVG support, we need librsvg, and librsvg depends
554 ;; on gdk-pixbuf, so this new varibale. Also, librsvg adds 90MiB to the
555 ;; closure size.
556 (define-public gdk-pixbuf+svg
557 (package (inherit gdk-pixbuf)
558 (name "gdk-pixbuf+svg")
559 (inputs
560 `(("librsvg" ,librsvg)
561 ,@(package-inputs gdk-pixbuf)))
562 (arguments
563 '(#:configure-flags '("-Dinstalled-tests=false")
564 #:tests? #f ; tested by the gdk-pixbuf package already
565 #:phases
566 (modify-phases %standard-phases
567 (add-after 'install 'register-svg-loader
568 (lambda* (#:key inputs outputs #:allow-other-keys)
569 (let* ((out (assoc-ref outputs "out"))
570 (librsvg (assoc-ref inputs "librsvg"))
571 (loaders
572 (append
573 (find-files out "^libpixbufloader-.*\\.so$")
574 (find-files librsvg "^libpixbufloader-.*\\.so$")))
575 (gdk-pixbuf-query-loaders
576 (string-append out "/bin/gdk-pixbuf-query-loaders")))
577 (apply invoke
578 gdk-pixbuf-query-loaders
579 "--update-cache"
580 loaders)))))))
581 (synopsis
582 "GNOME image loading and manipulation library, with SVG support")))
583
584 (define-public at-spi2-core
585 (package
586 (name "at-spi2-core")
587 (version "2.34.0")
588 (source (origin
589 (method url-fetch)
590 (uri (string-append "mirror://gnome/sources/" name "/"
591 (version-major+minor version) "/"
592 name "-" version ".tar.xz"))
593 (sha256
594 (base32
595 "1ihixwhh3c16q6253qj9gf69741rb2pi51822a4rylsfcyywsafn"))))
596 (build-system meson-build-system)
597 (outputs '("out" "doc"))
598 (arguments
599 '(#:configure-flags
600 (list "-Ddocs=true")
601 #:phases
602 (modify-phases %standard-phases
603 (add-after 'unpack 'set-documentation-path
604 (lambda* (#:key outputs #:allow-other-keys)
605 ;; Ensure that the cross-references point to the "doc" output.
606 (substitute* "doc/libatspi/meson.build"
607 (("docpath =.*")
608 (string-append "docpath = '" (assoc-ref outputs "doc") "/share/gtk-doc/html'\n")))
609 #t))
610 (add-before 'install 'prepare-doc-directory
611 (lambda* (#:key outputs #:allow-other-keys)
612 (mkdir-p (string-append (assoc-ref outputs "doc") "/share"))
613 #t))
614 (add-after 'install 'move-documentation
615 (lambda* (#:key outputs #:allow-other-keys)
616 (let ((out (assoc-ref outputs "out"))
617 (doc (assoc-ref outputs "doc")))
618 (copy-recursively
619 (string-append out "/share/gtk-doc")
620 (string-append doc "/share/gtk-doc"))
621 (delete-file-recursively
622 (string-append out "/share/gtk-doc")))
623 #t))
624 (add-after 'install 'check
625 (lambda _
626 (setenv "HOME" (getenv "TMPDIR")) ; xfconfd requires a writable HOME
627 ;; Run test-suite under a dbus session.
628 (setenv "XDG_DATA_DIRS" ; for finding org.xfce.Xfconf.service
629 (string-append %output "/share"))
630 ;; Don't fail on missing '/etc/machine-id'.
631 (setenv "DBUS_FATAL_WARNINGS" "0") ;
632 (invoke "dbus-launch" "ninja" "test")))
633 (delete 'check))))
634 (propagated-inputs
635 ;; atspi-2.pc refers to all these.
636 `(("dbus" ,dbus)
637 ("glib" ,glib)
638 ("libxi" ,libxi)
639 ("libxtst" ,libxtst)))
640 (native-inputs
641 `(("gettext" ,gettext-minimal)
642 ("gobject-introspection" ,gobject-introspection)
643 ("gtk-doc" ,gtk-doc)
644 ("glib" ,glib "bin")
645 ("pkg-config" ,pkg-config)))
646 (synopsis "Assistive Technology Service Provider Interface, core components")
647 (description
648 "The Assistive Technology Service Provider Interface, core components,
649 is part of the GNOME accessibility project.")
650 (license license:lgpl2.0+)
651 (home-page "https://projects.gnome.org/accessibility/")))
652
653 ;;; A minimal variant used to prevent a cycle with Inkscape.
654 (define at-spi2-core-minimal
655 (package
656 (inherit at-spi2-core)
657 (name "at-spi2-core-minimal")
658 (outputs (delete "doc" (package-outputs at-spi2-core)))
659 (arguments
660 (substitute-keyword-arguments (package-arguments at-spi2-core)
661 ((#:configure-flags configure-flags)
662 `(delete "-Ddocs=true" ,configure-flags))
663 ((#:phases phases)
664 `(modify-phases ,phases
665 (delete 'set-documentation-path)
666 (delete 'prepare-doc-directory)
667 (delete 'move-documentation)))))
668 (native-inputs
669 (alist-delete "gtk-doc" (package-native-inputs at-spi2-core)))))
670
671 (define-public at-spi2-atk
672 (package
673 (name "at-spi2-atk")
674 (version "2.34.1")
675 (source (origin
676 (method url-fetch)
677 (uri (string-append "mirror://gnome/sources/" name "/"
678 (version-major+minor version) "/"
679 name "-" version ".tar.xz"))
680 (sha256
681 (base32
682 "05ncp7s5nddjinffs26mcvpbd63vk1m3cv5y530p3plgfhqgjvbp"))))
683 (build-system meson-build-system)
684 (arguments
685 '(#:phases
686 (modify-phases %standard-phases
687 (replace 'check
688 ;; Run test-suite under a dbus session.
689 (lambda _
690 (setenv "DBUS_FATAL_WARNINGS" "0")
691 (invoke "dbus-launch" "meson" "test"))))))
692 (propagated-inputs
693 ;; TODO: Replace by at-spi2-core-minimal in the next staging window, or
694 ;; when Inkscape 0.92 is upgraded to 1.0 to avoid a cycle.
695 `(("at-spi2-core" ,at-spi2-core))) ; required by atk-bridge-2.0.pc
696 (inputs
697 `(("atk" ,atk)))
698 (native-inputs
699 `(("pkg-config" ,pkg-config)
700 ;; For tests.
701 ("dbus" ,dbus)
702 ("libxml2" ,libxml2)))
703 (synopsis "Assistive Technology Service Provider Interface, ATK bindings")
704 (description
705 "The Assistive Technology Service Provider Interface
706 is part of the GNOME accessibility project.")
707 (license license:lgpl2.0+)
708 (home-page "https://projects.gnome.org/accessibility/")))
709
710 (define-public gtk+-2
711 (package
712 (name "gtk+")
713 (version "2.24.32")
714 (source (origin
715 (method url-fetch)
716 (uri (string-append "mirror://gnome/sources/" name "/"
717 (version-major+minor version) "/"
718 name "-" version ".tar.xz"))
719 (sha256
720 (base32
721 "0bjq7ja9gwcv6n5q4qkvdjjx40wsdiikksz1zqxvxsm5vlyskj5n"))
722 (patches (search-patches "gtk2-respect-GUIX_GTK2_PATH.patch"
723 "gtk2-respect-GUIX_GTK2_IM_MODULE_FILE.patch"
724 "gtk2-theme-paths.patch"))))
725 (build-system gnu-build-system)
726 (outputs '("out" "bin" "doc"))
727 (propagated-inputs
728 `(("atk" ,atk)
729 ("gdk-pixbuf" ,gdk-pixbuf+svg)
730 ("pango" ,pango)))
731 (inputs
732 `(("cups" ,cups)
733 ("libxcomposite" ,libxcomposite)
734 ("libxcursor" ,libxcursor)
735 ("libxdamage" ,libxdamage)
736 ("libxi" ,libxi)
737 ("libxinerama" ,libxinerama)
738 ("libxrandr" ,libxrandr)))
739 (native-inputs
740 `(("perl" ,perl)
741 ("gettext" ,gettext-minimal)
742 ("glib" ,glib "bin")
743 ("gobject-introspection" ,gobject-introspection)
744 ("pkg-config" ,pkg-config)
745 ("python-wrapper" ,python-wrapper)))
746 (arguments
747 `(#:configure-flags
748 (list "--with-xinput=yes"
749 (string-append "--with-html-dir="
750 (assoc-ref %outputs "doc")
751 "/share/gtk-doc/html"))
752 #:phases
753 (modify-phases %standard-phases
754 (add-before 'configure 'disable-tests
755 (lambda _
756 ;; FIXME: re-enable tests requiring an X server
757 (substitute* "gtk/Makefile.in"
758 (("SUBDIRS = theme-bits . tests") "SUBDIRS = theme-bits ."))
759 #t))
760 (add-after 'install 'remove-cache
761 (lambda* (#:key outputs #:allow-other-keys)
762 (for-each
763 delete-file
764 (find-files (assoc-ref outputs "out") "immodules.cache"))
765 #t)))))
766 (native-search-paths
767 (list (search-path-specification
768 (variable "GUIX_GTK2_PATH")
769 (files '("lib/gtk-2.0")))))
770 (synopsis "Cross-platform toolkit for creating graphical user interfaces")
771 (description
772 "GTK+, or the GIMP Toolkit, is a multi-platform toolkit for creating
773 graphical user interfaces. Offering a complete set of widgets, GTK+ is
774 suitable for projects ranging from small one-off tools to complete
775 application suites.")
776 (license license:lgpl2.0+)
777 (home-page "https://www.gtk.org/")))
778
779 (define-public gtk+
780 (package (inherit gtk+-2)
781 (name "gtk+")
782 (version "3.24.14")
783 (source (origin
784 (method url-fetch)
785 (uri (string-append "mirror://gnome/sources/" name "/"
786 (version-major+minor version) "/"
787 name "-" version ".tar.xz"))
788 (sha256
789 (base32
790 "120yz5gxqbv7sgdbcy4i0b6ixm8jpjzialdrqs0gv15q7bwnjk8w"))
791 (patches (search-patches "gtk3-respect-GUIX_GTK3_PATH.patch"
792 "gtk3-respect-GUIX_GTK3_IM_MODULE_FILE.patch"))))
793 (propagated-inputs
794 `(("at-spi2-atk" ,at-spi2-atk)
795 ("atk" ,atk)
796 ("gdk-pixbuf" ,gdk-pixbuf+svg)
797 ("libepoxy" ,libepoxy)
798 ("libxcursor" ,libxcursor)
799 ("libxi" ,libxi)
800 ("libxinerama" ,libxinerama)
801 ("libxkbcommon" ,libxkbcommon)
802 ("libxdamage" ,libxdamage)
803 ("libxrandr" ,libxrandr)
804 ("mesa" ,mesa)
805 ("pango" ,pango)
806 ("wayland" ,wayland)
807 ("wayland-protocols" ,wayland-protocols)))
808 (inputs
809 `(("libxml2" ,libxml2)
810 ;; XXX: colord depends on mozjs (through polkit), which fails on
811 ;; on non-intel systems now.
812 ;;("colord" ,colord)
813 ("cups" ,cups) ;for printing support
814 ;; XXX: rest depends on p11-kit, which fails on mips64el now.
815 ;;("rest" ,rest)
816 ("json-glib" ,json-glib)))
817 (native-inputs
818 `(("perl" ,perl)
819 ("glib" ,glib "bin")
820 ("gettext" ,gettext-minimal)
821 ("pkg-config" ,pkg-config)
822 ("gobject-introspection" ,gobject-introspection)
823 ("python-wrapper" ,python-wrapper)
824 ;; By using a special xorg-server for GTK+'s tests, we reduce the impact
825 ;; of updating xorg-server directly on the master branch.
826 ("xorg-server" ,xorg-server-for-tests)))
827 (arguments
828 `(#:disallowed-references (,xorg-server-for-tests)
829 ;; 47 MiB goes to "out" (24 of which is locale data!), and 26 MiB goes
830 ;; to "doc".
831 #:configure-flags (list (string-append "--with-html-dir="
832 (assoc-ref %outputs "doc")
833 "/share/gtk-doc/html")
834 ;; The header file <gdk/gdkwayland.h> is required
835 ;; by gnome-control-center
836 "--enable-wayland-backend"
837 ;; This is necessary to build both backends.
838 "--enable-x11-backend"
839 ;; This enables the HTML5 websocket backend.
840 "--enable-broadway-backend")
841 #:phases (modify-phases %standard-phases
842 (add-before 'configure 'pre-configure
843 (lambda _
844 ;; Disable most tests, failing in the chroot with the message:
845 ;; D-Bus library appears to be incorrectly set up; failed to read
846 ;; machine uuid: Failed to open "/etc/machine-id": No such file or
847 ;; directory.
848 ;; See the manual page for dbus-uuidgen to correct this issue.
849 (substitute* "testsuite/Makefile.in"
850 (("SUBDIRS = gdk gtk a11y css reftests")
851 "SUBDIRS = gdk"))
852 #t))
853 (add-after 'install 'move-desktop-files
854 ;; Move desktop files into 'bin' to avoid cycle references.
855 (lambda* (#:key outputs #:allow-other-keys)
856 (let ((out (assoc-ref outputs "out"))
857 (bin (assoc-ref outputs "bin")))
858 (mkdir-p (string-append bin "/share"))
859 (rename-file (string-append out "/share/applications")
860 (string-append bin "/share/applications"))
861 #t))))))
862 (native-search-paths
863 (list (search-path-specification
864 (variable "GUIX_GTK3_PATH")
865 (files '("lib/gtk-3.0")))))))
866
867 ;;;
868 ;;; Guile bindings.
869 ;;;
870
871 (define-public guile-cairo
872 (package
873 (name "guile-cairo")
874 (version "1.10.0")
875 (source (origin
876 (method url-fetch)
877 (uri (string-append "mirror://savannah/guile-cairo/guile-cairo-"
878 version ".tar.gz"))
879 (sha256
880 (base32
881 "0p6xrhf2k6n5dybn88050za7h90gnd7534n62l53vsca187pwgdf"))
882 (modules '((guix build utils)))
883 (snippet
884 (begin
885 '(begin
886 ;; Install Scheme files in …/guile/site/X.Y.
887 (substitute* (find-files "." "^Makefile\\.in$")
888 (("^(.*)dir = (.*)/guile/site(.*)" _ name prefix suffix)
889 (string-append name "dir = " prefix
890 "/guile/site/@GUILE_EFFECTIVE_VERSION@"
891 suffix)))
892
893 ;; Guile 2.x <libguile.h> used to pull in <string.h> and
894 ;; other headers but this is no longer the case in 3.0.
895 (substitute* (find-files "." "\\.[ch]$")
896 (("^ *# *include.*libguile\\.h.*$")
897 "#include <libguile.h>\n#include <string.h>\n"))
898 #t)))))
899 (build-system gnu-build-system)
900 (arguments
901 ;; Uses of 'scm_t_uint8' & co. are deprecated; don't stop the build
902 ;; because of them.
903 '(#:configure-flags '("--disable-Werror")))
904 (inputs
905 `(("guile-lib" ,guile-lib)
906 ("expat" ,expat)
907 ("guile" ,guile-3.0)))
908 (propagated-inputs
909 ;; The .pc file refers to 'cairo'.
910 `(("cairo" ,cairo)))
911 (native-inputs
912 `(("pkg-config" ,pkg-config)))
913 (home-page "https://www.nongnu.org/guile-cairo/")
914 (synopsis "Cairo bindings for GNU Guile")
915 (description
916 "Guile-Cairo wraps the Cairo graphics library for Guile Scheme.
917 Guile-Cairo is complete, wrapping almost all of the Cairo API. It is API
918 stable, providing a firm base on which to do graphics work. Finally, and
919 importantly, it is pleasant to use. You get a powerful and well-maintained
920 graphics library with all of the benefits of Scheme: memory management,
921 exceptions, macros, and a dynamic programming environment.")
922 (license license:lgpl3+)))
923
924 (define-public guile2.2-cairo
925 (package
926 (inherit guile-cairo)
927 (name "guile2.2-cairo")
928 (inputs
929 `(("guile" ,guile-2.2)
930 ("guile-lib" ,guile2.2-lib)
931 ,@(fold alist-delete (package-inputs guile-cairo)
932 '("guile" "guile-lib"))))))
933
934 (define-public guile3.0-cairo
935 (deprecated-package "guile3.0-cairo" guile-cairo))
936
937 (define-public guile-rsvg
938 ;; Use a recent snapshot that supports Guile 2.2 and beyond.
939 (let ((commit "05c6a2fd67e4fea1a7c3ff776729dc931bae6678")
940 (revision "0"))
941 (package
942 (name "guile-rsvg")
943 (version (string-append "2.18.1-" revision "."
944 (string-take commit 7)))
945 (source (origin
946 (method url-fetch)
947 (uri (string-append "https://gitlab.com/wingo/guile-rsvg/"
948 "repository/archive.tar.gz?ref="
949 commit))
950 (sha256
951 (base32
952 "0vdzjx8l5nc4y2xjqs0g1rqn1zrwfsm30brh5gz00r1x41a2pvv2"))
953 (patches (search-patches "guile-rsvg-pkgconfig.patch"))
954 (modules '((guix build utils)))
955 (snippet
956 '(begin
957 (substitute* (find-files "." "Makefile\\.am")
958 (("/share/guile/site")
959 "/share/guile/site/@GUILE_EFFECTIVE_VERSION@"))
960 #t))
961 (file-name (string-append name "-" version ".tar.gz"))))
962 (build-system gnu-build-system)
963 (arguments
964 `(#:phases (modify-phases %standard-phases
965 (replace 'bootstrap
966 (lambda _
967 (invoke "autoreconf" "-vfi"))))))
968 (native-inputs `(("pkg-config" ,pkg-config)
969 ("autoconf" ,autoconf)
970 ("automake" ,automake)
971 ("libtool" ,libtool)
972 ("texinfo" ,texinfo)))
973 (inputs `(("guile" ,guile-3.0)
974 ("librsvg" ,librsvg)
975 ("guile-lib" ,guile-lib))) ;for (unit-test)
976 (propagated-inputs `(("guile-cairo" ,guile-cairo)))
977 (synopsis "Render SVG images using Cairo from Guile")
978 (description
979 "Guile-RSVG wraps the RSVG library for Guile, allowing you to render SVG
980 images onto Cairo surfaces.")
981 (home-page "https://wingolog.org/projects/guile-rsvg/")
982 (license license:lgpl2.1+))))
983
984 (define-public guile2.2-rsvg
985 (package
986 (inherit guile-rsvg)
987 (name "guile2.2-rsvg")
988 (inputs
989 `(("guile" ,guile-2.2)
990 ("guile-lib" ,guile2.2-lib)
991 ,@(fold alist-delete (package-inputs guile-rsvg)
992 '("guile" "guile-lib"))))
993 (propagated-inputs `(("guile-cairo" ,guile2.2-cairo)))))
994
995 (define-public guile3.0-rsvg
996 (deprecated-package "guile3.0-rsvg" guile-rsvg))
997
998 (define-public guile-present
999 (package
1000 (name "guile-present")
1001 (version "0.3.0")
1002 (source (origin
1003 (method url-fetch)
1004 (uri (string-append "http://wingolog.org/pub/guile-present/"
1005 "guile-present-" version ".tar.gz"))
1006 (sha256
1007 (base32
1008 "1qam447m05sxxv6x8dlzg7qnyfc4dh8apjw1idpfhpns671gfr6m"))
1009 (patches (search-patches "guile-present-coding.patch"))
1010 (modules '((guix build utils)))
1011 (snippet
1012 '(begin
1013 ;; Allow builds with Guile 3.0.
1014 (substitute* "configure"
1015 (("2\\.2 2\\.0")
1016 "3.0 2.2 2.0"))
1017
1018 ;; Install .go files in the right place.
1019 (substitute* "Makefile.in"
1020 (("/ccache") "/site-ccache"))
1021 #t))))
1022 (build-system gnu-build-system)
1023 (arguments
1024 `(#:phases
1025 (modify-phases %standard-phases
1026 (add-after 'install 'post-install
1027 (lambda* (#:key inputs outputs #:allow-other-keys)
1028 (let* ((out (assoc-ref outputs "out"))
1029 (bin (string-append out "/bin"))
1030 (guile (assoc-ref inputs "guile"))
1031 (version
1032 ,(match (assoc "guile" (package-inputs this-package))
1033 (("guile" guile)
1034 (version-major+minor (package-version guile))))))
1035 (substitute* (find-files bin ".*")
1036 (("guile")
1037 (string-append guile "/bin/guile -L "
1038 out "/share/guile/site/" version " -C "
1039 out "/lib/guile/" version "/site-ccache "))))
1040 #t)))))
1041 (native-inputs `(("pkg-config" ,pkg-config)))
1042 (inputs `(("guile" ,guile-3.0)))
1043 (propagated-inputs
1044 ;; These are used by the (present …) modules.
1045 `(("guile-lib" ,guile-lib)
1046 ("guile-cairo" ,guile-cairo)
1047 ("guile-rsvg" ,guile-rsvg)))
1048 (home-page "https://wingolog.org/software/guile-present/")
1049 (synopsis "Create SVG or PDF presentations in Guile")
1050 (description
1051 "Guile-Present defines a declarative vocabulary for presentations,
1052 together with tools to render presentation documents as SVG or PDF.
1053 Guile-Present can be used to make presentations programmatically, but also
1054 includes a tools to generate PDF presentations out of Org mode and Texinfo
1055 documents.")
1056 (license license:lgpl3+)))
1057
1058 (define-public guile2.2-present
1059 (package
1060 (inherit guile-present)
1061 (name "guile2.2-present")
1062 (inputs `(("guile" ,guile-2.2)))
1063 (propagated-inputs
1064 `(("guile-lib" ,guile2.2-lib)
1065 ("guile-cairo" ,guile2.2-cairo)
1066 ("guile-rsvg" ,guile2.2-rsvg)))))
1067
1068 (define-public guile3.0-present
1069 (deprecated-package "guile3.0-present" guile-present))
1070
1071 (define-public guile-gnome
1072 (package
1073 (name "guile-gnome")
1074 (version "2.16.5")
1075 (source (origin
1076 (method url-fetch)
1077 (uri
1078 (string-append "mirror://gnu/" name
1079 "/guile-gnome-platform/guile-gnome-platform-"
1080 version ".tar.gz"))
1081 (sha256
1082 (base32
1083 "1gnf3j96nip5kl99a268i0dy1hj7s1cfs66sps3zwysnkd7qr399"))))
1084 (build-system gnu-build-system)
1085 (native-inputs
1086 `(("pkg-config" ,pkg-config)
1087 ("atk" ,atk)
1088 ;;("corba" ,corba) ; not packaged yet
1089 ("gconf" ,gconf)
1090 ("gobject-introspection" ,gobject-introspection)
1091 ;;("gthread" ,gthread) ; not packaged yet
1092 ("gnome-vfs" ,gnome-vfs)
1093 ("gdk-pixbuf" ,gdk-pixbuf)
1094 ("gtk+" ,gtk+-2)
1095 ("libglade" ,libglade)
1096 ("libgnome" ,libgnome)
1097 ("libgnomecanvas" ,libgnomecanvas)
1098 ("libgnomeui" ,libgnomeui)
1099 ("pango" ,pango)
1100 ("libffi" ,libffi)
1101 ("glib" ,glib)))
1102 (inputs `(("guile" ,guile-2.2)))
1103 (propagated-inputs
1104 `(("guile-cairo" ,guile2.2-cairo)
1105 ("g-wrap" ,g-wrap)
1106 ("guile-lib" ,guile2.2-lib)))
1107 (arguments
1108 `(#:tests? #f ;FIXME
1109 #:phases (modify-phases %standard-phases
1110 (add-before 'configure 'pre-configure
1111 (lambda* (#:key outputs #:allow-other-keys)
1112 (let ((out (assoc-ref outputs "out")))
1113 (substitute* (find-files "." "^Makefile.in$")
1114 (("guilesite :=.*guile/site" all)
1115 (string-append all "/@GUILE_EFFECTIVE_VERSION@")))
1116 #t))))))
1117 (outputs '("out" "debug"))
1118 (synopsis "Guile interface for GTK+ programming for GNOME")
1119 (description
1120 "Includes guile-clutter, guile-gnome-gstreamer,
1121 guile-gnome-platform (GNOME developer libraries), and guile-gtksourceview.")
1122 (home-page "https://www.gnu.org/software/guile-gnome/")
1123 (license license:gpl2+)
1124 (properties '((upstream-name . "guile-gnome-platform")
1125 (ftp-directory . "/gnu/guile-gnome/guile-gnome-platform")))))
1126
1127 ;;;
1128 ;;; C++ bindings.
1129 ;;;
1130
1131 (define-public cairomm
1132 (package
1133 (name "cairomm")
1134 (version "1.12.2")
1135 (source (origin
1136 (method url-fetch)
1137 (uri (string-append "https://www.cairographics.org/releases/"
1138 name "-" version ".tar.gz"))
1139 (sha256
1140 (base32
1141 "16fmigxsaz85c3lgcls7biwyz8zy8c8h3jndfm54cxxas3a7zi25"))))
1142 (build-system gnu-build-system)
1143 (arguments
1144 ;; The examples lack -lcairo.
1145 '(#:make-flags '("LDFLAGS=-lcairo")))
1146 (native-inputs `(("pkg-config" ,pkg-config)))
1147 (propagated-inputs
1148 `(("libsigc++" ,libsigc++)
1149 ("freetype" ,freetype)
1150 ("fontconfig" ,fontconfig)
1151 ("cairo" ,cairo)))
1152 (home-page "https://cairographics.org/")
1153 (synopsis "C++ bindings to the Cairo 2D graphics library")
1154 (description
1155 "Cairomm provides a C++ programming interface to the Cairo 2D graphics
1156 library.")
1157 (license license:lgpl2.0+)))
1158
1159 (define-public pangomm
1160 (package
1161 (name "pangomm")
1162 (version "2.42.0")
1163 (source (origin
1164 (method url-fetch)
1165 (uri (string-append "mirror://gnome/sources/" name "/"
1166 (version-major+minor version) "/"
1167 name "-" version ".tar.xz"))
1168 (sha256
1169 (base32
1170 "0mmzxp3wniaafkxr30sb22mq9x44xckb5d60h1bl99lkzxks0vfa"))))
1171 (build-system gnu-build-system)
1172 (native-inputs `(("pkg-config" ,pkg-config)))
1173 (propagated-inputs
1174 `(("cairo" ,cairo)
1175 ("cairomm" ,cairomm)
1176 ("glibmm" ,glibmm)
1177 ("pango" ,pango)))
1178 (home-page "https://pango.gnome.org//")
1179 (synopsis "C++ interface to the Pango text rendering library")
1180 (description
1181 "Pangomm provides a C++ programming interface to the Pango text rendering
1182 library.")
1183 (license license:lgpl2.1+)))
1184
1185 (define-public atkmm
1186 (package
1187 (name "atkmm")
1188 (version "2.28.0")
1189 (source (origin
1190 (method url-fetch)
1191 (uri (string-append "mirror://gnome/sources/" name "/"
1192 (version-major+minor version) "/"
1193 name "-" version ".tar.xz"))
1194 (sha256
1195 (base32
1196 "0fnxrspxkhhbrjphqrpvl3zjm66n50s4cywrrrwkhbflgy8zqk2c"))))
1197 (build-system gnu-build-system)
1198 (native-inputs `(("pkg-config" ,pkg-config)))
1199 (propagated-inputs
1200 `(("glibmm" ,glibmm) ("atk" ,atk)))
1201 (home-page "https://www.gtkmm.org")
1202 (synopsis "C++ interface to the ATK accessibility library")
1203 (description
1204 "ATKmm provides a C++ programming interface to the ATK accessibility
1205 toolkit.")
1206 (license license:lgpl2.1+)))
1207
1208 (define-public gtkmm
1209 (package
1210 (name "gtkmm")
1211 (version "3.24.2")
1212 (source (origin
1213 (method url-fetch)
1214 (uri (string-append "mirror://gnome/sources/" name "/"
1215 (version-major+minor version) "/"
1216 name "-" version ".tar.xz"))
1217 (sha256
1218 (base32
1219 "1hxdnhavjyvbcpxhd5z17l9fj4182028s66lc0s16qqqrldhjwbd"))))
1220 (build-system gnu-build-system)
1221 (native-inputs `(("pkg-config" ,pkg-config)
1222 ("glib" ,glib "bin") ;for 'glib-compile-resources'
1223 ("xorg-server" ,xorg-server-for-tests)))
1224 (propagated-inputs
1225 `(("pangomm" ,pangomm)
1226 ("cairomm" ,cairomm)
1227 ("atkmm" ,atkmm)
1228 ("gtk+" ,gtk+)
1229 ("glibmm" ,glibmm)))
1230 (arguments
1231 `(#:disallowed-references (,xorg-server-for-tests)
1232 #:phases (modify-phases %standard-phases
1233 (add-before 'check 'run-xvfb
1234 (lambda* (#:key inputs #:allow-other-keys)
1235 (let ((xorg-server (assoc-ref inputs "xorg-server")))
1236 ;; Tests such as 'object_move/test' require a running
1237 ;; X server.
1238 (system (string-append xorg-server "/bin/Xvfb :1 &"))
1239 (setenv "DISPLAY" ":1")
1240 ;; Don't fail because of the missing /etc/machine-id.
1241 (setenv "DBUS_FATAL_WARNINGS" "0")
1242 #t))))))
1243 (home-page "https://gtkmm.org/")
1244 (synopsis
1245 "C++ interface to the GTK+ graphical user interface library")
1246 (description
1247 "gtkmm is the official C++ interface for the popular GUI library GTK+.
1248 Highlights include typesafe callbacks, and a comprehensive set of widgets that
1249 are easily extensible via inheritance. You can create user interfaces either
1250 in code or with the Glade User Interface designer, using libglademm. There's
1251 extensive documentation, including API reference and a tutorial.")
1252 (license license:lgpl2.1+)))
1253
1254
1255 (define-public gtkmm-2
1256 (package (inherit gtkmm)
1257 (name "gtkmm")
1258 (version "2.24.5")
1259 (source (origin
1260 (method url-fetch)
1261 (uri (string-append "mirror://gnome/sources/" name "/"
1262 (version-major+minor version) "/"
1263 name "-" version ".tar.xz"))
1264 (sha256
1265 (base32
1266 "0wkbzvsx4kgw16f6xjdc1dz7f77ldngdila4yi5lw2zrgcxsb006"))))
1267 (arguments '())
1268 (native-inputs `(("pkg-config" ,pkg-config)))
1269 (propagated-inputs
1270 `(("pangomm" ,pangomm)
1271 ("cairomm" ,cairomm)
1272 ("atkmm" ,atkmm)
1273 ("gtk+" ,gtk+-2)
1274 ("glibmm" ,glibmm)))))
1275
1276 (define-public gtksourceviewmm
1277 (package
1278 (name "gtksourceviewmm")
1279 (version "3.18.0")
1280 (source (origin
1281 (method url-fetch)
1282 (uri (string-append "mirror://gnome/sources/" name "/"
1283 (version-major+minor version) "/"
1284 name "-" version ".tar.xz"))
1285 (sha256
1286 (base32 "0fgvmhm4h4qmxig87qvangs6ijw53mi40siz7pixlxbrsgiil22i"))))
1287 (build-system gnu-build-system)
1288 (native-inputs
1289 `(("pkg-config" ,pkg-config)))
1290 (propagated-inputs
1291 ;; In 'Requires' of gtksourceviewmm-3.0.pc.
1292 `(("glibmm" ,glibmm)
1293 ("gtkmm" ,gtkmm)
1294 ("gtksourceview" ,gtksourceview-3)))
1295 (synopsis "C++ interface to the GTK+ 'GtkTextView' widget")
1296 (description
1297 "gtksourceviewmm is a portable C++ library that extends the standard GTK+
1298 framework for multiline text editing with support for configurable syntax
1299 highlighting, unlimited undo/redo, search and replace, a completion framework,
1300 printing and other features typical of a source code editor.")
1301 (license license:lgpl2.1+)
1302 (home-page "https://developer.gnome.org/gtksourceview/")))
1303
1304 ;;;
1305 ;;; Python bindings.
1306 ;;;
1307
1308 (define-public python-pycairo
1309 (package
1310 (name "python-pycairo")
1311 (version "1.19.0")
1312 (source
1313 (origin
1314 (method url-fetch)
1315 (uri (string-append "https://github.com/pygobject/pycairo/releases/download/v"
1316 version "/pycairo-" version ".tar.gz"))
1317 (sha256
1318 (base32
1319 "176i283glkpycka8wwyndwld0zp1yn9xj9rpvllqgja698vsjnsg"))))
1320 (build-system python-build-system)
1321 (native-inputs
1322 `(("pkg-config" ,pkg-config)
1323 ("python-pytest" ,python-pytest)))
1324 (propagated-inputs ;pycairo.pc references cairo
1325 `(("cairo" ,cairo)))
1326 (home-page "https://cairographics.org/pycairo/")
1327 (synopsis "Python bindings for cairo")
1328 (description
1329 "Pycairo is a set of Python bindings for the Cairo graphics library.")
1330 (license license:lgpl3+)
1331 (properties `((python2-variant . ,(delay python2-pycairo))))))
1332
1333 ;; Pycairo no longer supports Python 2 since version 1.19.0, so we stick
1334 ;; with this older version here.
1335 (define-public python2-pycairo
1336 (let ((pycairo (package-with-python2
1337 (strip-python2-variant python-pycairo))))
1338 (package
1339 (inherit pycairo)
1340 (version "1.18.2")
1341 (source (origin
1342 (method url-fetch)
1343 (uri (string-append "https://github.com/pygobject/pycairo/releases"
1344 "/download/v" version "/pycairo-" version ".tar.gz"))
1345 (sha256
1346 (base32
1347 "0cb5n4r4nl0k1g90b1gz9iyk4lp7hi03db98i1p52a870bym7f6w"))))
1348 ;; Dual-licensed under LGPL 2.1 or Mozilla Public License 1.1
1349 (license (list license:lgpl2.1 license:mpl1.1)))))
1350
1351 (define-public python2-pygtk
1352 (package
1353 (name "python2-pygtk")
1354 (version "2.24.0")
1355 (source
1356 (origin
1357 (method url-fetch)
1358 (uri (string-append "mirror://gnome/sources"
1359 "/pygtk/" (version-major+minor version)
1360 "/pygtk-" version ".tar.bz2"))
1361 (sha256
1362 (base32
1363 "04k942gn8vl95kwf0qskkv6npclfm31d78ljkrkgyqxxcni1w76d"))))
1364 (build-system gnu-build-system)
1365 (outputs '("out"
1366 "doc")) ;13 MiB of gtk-doc HTML
1367 (native-inputs
1368 `(("pkg-config" ,pkg-config)))
1369 (inputs
1370 `(("python" ,python-2)
1371
1372 ;; XXX: The package fails to build with the latest Pango (propagated
1373 ;; from GTK+2), so we provide it with this older version.
1374 ("pango" ,pango-1.42)
1375
1376 ("libglade" ,libglade)
1377 ("glib" ,glib)))
1378 (propagated-inputs
1379 `(("python-pycairo" ,python2-pycairo) ;loaded at runtime
1380 ("python-pygobject" ,python2-pygobject-2) ;referenced in pc file
1381 ("gtk+" ,gtk+-2)))
1382 (arguments
1383 `(#:tests? #f
1384 #:phases (modify-phases %standard-phases
1385 (add-before 'configure 'set-gtk-doc-directory
1386 (lambda* (#:key outputs #:allow-other-keys)
1387 ;; Install documentation to "doc".
1388 (let ((doc (assoc-ref outputs "doc")))
1389 (substitute* "docs/Makefile.in"
1390 (("TARGET_DIR = \\$\\(datadir\\)")
1391 (string-append "TARGET_DIR = " doc))))))
1392 (add-after 'configure 'fix-codegen
1393 (lambda* (#:key inputs #:allow-other-keys)
1394 (substitute* "pygtk-codegen-2.0"
1395 (("^prefix=.*$")
1396 (string-append
1397 "prefix="
1398 (assoc-ref inputs "python-pygobject") "\n")))))
1399 (add-after 'install 'install-pth
1400 (lambda* (#:key inputs outputs #:allow-other-keys)
1401 ;; pygtk's modules are stored in a subdirectory of
1402 ;; python's site-packages directory. Add a .pth file so
1403 ;; that python will add that subdirectory to its module
1404 ;; search path.
1405 (let* ((out (assoc-ref outputs "out"))
1406 (site (string-append out "/lib/python"
1407 ,(version-major+minor
1408 (package-version python-2))
1409 "/site-packages")))
1410 (call-with-output-file (string-append site "/pygtk.pth")
1411 (lambda (port)
1412 (format port "gtk-2.0~%")))))))))
1413 (home-page "http://www.pygtk.org/")
1414 (synopsis "Python bindings for GTK+")
1415 (description
1416 "PyGTK allows you to write full featured GTK programs in Python. It is
1417 targeted at GTK 2.x, and can be used in conjunction with gnome-python to
1418 write GNOME applications.")
1419 (license license:lgpl2.1+)))
1420
1421 (define-public perl-cairo
1422 (package
1423 (name "perl-cairo")
1424 (version "1.107")
1425 (source (origin
1426 (method url-fetch)
1427 (uri (string-append
1428 "mirror://cpan/authors/id/X/XA/XAOC/Cairo-"
1429 version ".tar.gz"))
1430 (sha256
1431 (base32
1432 "0sg1gf1f2pjq7pji0zsv4rbi3bzpsx82z98k7yqxafzrvlkf27ay"))))
1433 (build-system perl-build-system)
1434 (native-inputs
1435 `(("perl-extutils-depends" ,perl-extutils-depends)
1436 ("perl-extutils-pkgconfig" ,perl-extutils-pkgconfig)))
1437 (inputs
1438 `(("cairo" ,cairo)))
1439 (home-page "https://metacpan.org/release/Cairo")
1440 (synopsis "Perl interface to the cairo 2d vector graphics library")
1441 (description "Cairo provides Perl bindings for the vector graphics library
1442 cairo. It supports multiple output targets, including PNG, PDF and SVG. Cairo
1443 produces identical output on all those targets.")
1444 (license license:lgpl2.1+)))
1445
1446 (define-public perl-gtk2
1447 (package
1448 (name "perl-gtk2")
1449 (version "1.24993")
1450 (source (origin
1451 (method url-fetch)
1452 (uri (string-append "mirror://cpan/authors/id/X/XA/XAOC/Gtk2-"
1453 version ".tar.gz"))
1454 (sha256
1455 (base32
1456 "0ry9jfvfgdwzalxcvwsgr7plhk3agx7p40l0fqdf3vrf7ds47i29"))))
1457 (build-system perl-build-system)
1458 (native-inputs
1459 `(("perl-extutils-depends" ,perl-extutils-depends)
1460 ("perl-extutils-pkgconfig" ,perl-extutils-pkgconfig)))
1461 (inputs
1462 `(("gtk+" ,gtk+-2)))
1463 (propagated-inputs
1464 `(("perl-pango" ,perl-pango)))
1465 (arguments
1466 `(#:phases
1467 (modify-phases %standard-phases
1468 (add-before 'build 'remove-broken-test
1469 ;; See https://gitlab.gnome.org/GNOME/perl-gtk2/issues/3.
1470 (lambda _
1471 (substitute* "t/GdkPixbuf.t"
1472 (("tests => 112") "tests => 111")
1473 (("ok \\(defined \\$pixbuf, \"Don't crash on partial pixmap data\"\\);")
1474 "# ok (defined $pixbuf, \"Don't crash on partial pixmap data\");")))))))
1475 (home-page "https://metacpan.org/release/Gtk2")
1476 (synopsis "Perl interface to the 2.x series of the Gimp Toolkit library")
1477 (description "Perl bindings to the 2.x series of the Gtk+ widget set.
1478 This module allows you to write graphical user interfaces in a Perlish and
1479 object-oriented way, freeing you from the casting and memory management in C,
1480 yet remaining very close in spirit to original API.")
1481 (license license:lgpl2.1+)))
1482
1483 (define-public perl-pango
1484 (package
1485 (name "perl-pango")
1486 (version "1.227")
1487 (source (origin
1488 (method url-fetch)
1489 (uri (string-append "mirror://cpan/authors/id/X/XA/XAOC/Pango-"
1490 version ".tar.gz"))
1491 (sha256
1492 (base32
1493 "0wdcidnfnb6nm79fzfs39ivawj3x8m98a147fmcxgv1zvwia9c1l"))))
1494 (build-system perl-build-system)
1495 (native-inputs
1496 `(("perl-extutils-depends" ,perl-extutils-depends)
1497 ("perl-extutils-pkgconfig" ,perl-extutils-pkgconfig)))
1498 (inputs
1499 `(("pango" ,pango)))
1500 (propagated-inputs
1501 `(("perl-cairo" ,perl-cairo)
1502 ("perl-glib" ,perl-glib)))
1503 (home-page "https://metacpan.org/release/Pango")
1504 (synopsis "Layout and render international text")
1505 (description "Pango is a library for laying out and rendering text, with an
1506 emphasis on internationalization. Pango can be used anywhere that text layout
1507 is needed, but using Pango in conjunction with Cairo and/or Gtk2 provides a
1508 complete solution with high quality text handling and graphics rendering.
1509
1510 Dynamically loaded modules handle text layout for particular combinations of
1511 script and font backend. Pango provides a wide selection of modules, including
1512 modules for Hebrew, Arabic, Hangul, Thai, and a number of Indic scripts.
1513 Virtually all of the world's major scripts are supported.
1514
1515 In addition to the low level layout rendering routines, Pango includes
1516 @code{Pango::Layout}, a high level driver for laying out entire blocks of text,
1517 and routines to assist in editing internationalized text.")
1518 (license license:lgpl2.1+)))
1519
1520 (define-public girara
1521 (package
1522 (name "girara")
1523 (version "0.3.4")
1524 (source
1525 (origin
1526 (method git-fetch)
1527 (uri (git-reference
1528 (url "https://git.pwmt.org/pwmt/girara")
1529 (commit version)))
1530 (file-name (git-file-name name version))
1531 (sha256
1532 (base32 "08rpw9hkaprm4r853xy1d35i2af1pji8c3mzzl01mmwmyr9p0x8k"))))
1533 (native-inputs `(("pkg-config" ,pkg-config)
1534 ("check" ,check)
1535 ("gettext" ,gettext-minimal)
1536 ("glib:bin" ,glib "bin")
1537 ("xorg-server" ,xorg-server-for-tests)))
1538 ;; Listed in 'Requires.private' of 'girara.pc'.
1539 (propagated-inputs `(("gtk+" ,gtk+)))
1540 (arguments
1541 `(#:phases (modify-phases %standard-phases
1542 (add-before 'check 'start-xserver
1543 ;; Tests require a running X server.
1544 (lambda* (#:key inputs #:allow-other-keys)
1545 (let ((xorg-server (assoc-ref inputs "xorg-server"))
1546 (display ":1"))
1547 (setenv "DISPLAY" display)
1548
1549 ;; On busy machines, tests may take longer than
1550 ;; the default of four seconds.
1551 (setenv "CK_DEFAULT_TIMEOUT" "20")
1552
1553 ;; Don't fail due to missing '/etc/machine-id'.
1554 (setenv "DBUS_FATAL_WARNINGS" "0")
1555 (zero? (system (string-append xorg-server "/bin/Xvfb "
1556 display " &")))))))))
1557 (build-system meson-build-system)
1558 (home-page "https://pwmt.org/projects/girara/")
1559 (synopsis "Library for minimalistic gtk+3 user interfaces")
1560 (description "Girara is a library that implements a user interface that
1561 focuses on simplicity and minimalism. Currently based on GTK+, a
1562 cross-platform widget toolkit, it provides an interface that focuses on three
1563 main components: a so-called view widget that represents the actual
1564 application, an input bar that is used to execute commands of the
1565 application and the status bar which provides the user with current
1566 information.")
1567 (license license:zlib)))
1568
1569 (define-public gtk-doc
1570 (package
1571 (name "gtk-doc")
1572 (version "1.28")
1573 (source (origin
1574 (method url-fetch)
1575 (uri (string-append "mirror://gnome/sources/" name "/"
1576 (version-major+minor version) "/"
1577 name "-" version ".tar.xz"))
1578 (sha256
1579 (base32
1580 "05apmwibkmn1icx05l8aw241lhymcx01zvk5i499cb150bijj7li"))))
1581 (build-system gnu-build-system)
1582 (arguments
1583 `(#:parallel-tests? #f
1584 #:phases
1585 (modify-phases %standard-phases
1586 (add-after 'unpack 'patch-gtk-doc-scan
1587 (lambda* (#:key inputs #:allow-other-keys)
1588 (substitute* "gtk-doc.xsl"
1589 (("http://docbook.sourceforge.net/release/xsl/current/html/chunk.xsl")
1590 (string-append (assoc-ref inputs "docbook-xsl")
1591 "/xml/xsl/docbook-xsl-"
1592 ,(package-version docbook-xsl)
1593 "/html/chunk.xsl"))
1594 (("http://docbook.sourceforge.net/release/xsl/current/common/en.xml")
1595 (string-append (assoc-ref inputs "docbook-xsl")
1596 "/xml/xsl/docbook-xsl-"
1597 ,(package-version docbook-xsl)
1598 "/common/en.xml")))
1599 #t))
1600 (add-after 'patch-gtk-doc-scan 'patch-test-out
1601 (lambda _
1602 ;; sanity.sh counts the number of status lines. Since our
1603 ;; texlive regenerates the fonts every time and the font
1604 ;; generator metafont outputs a lot of extra lines, this
1605 ;; test would always fail. Disable it for now.
1606 (substitute* "tests/Makefile.in"
1607 (("empty.sh sanity.sh") "empty.sh"))
1608 #t))
1609 (add-before 'build 'set-HOME
1610 (lambda _
1611 ;; FIXME: dblatex with texlive-union does not find the built
1612 ;; metafonts, so it tries to generate them in HOME.
1613 (setenv "HOME" "/tmp")
1614 #t))
1615 (add-before 'configure 'fix-docbook
1616 (lambda* (#:key inputs #:allow-other-keys)
1617 (substitute* "configure"
1618 ;; The configure check is overzealous about making sure that
1619 ;; things are in place -- it uses the xmlcatalog tool to make
1620 ;; sure that docbook-xsl is available, but this tool can only
1621 ;; look in one catalog file, unlike the $XML_CATALOG_FILES
1622 ;; variable that Guix defines. Fool the test by using the
1623 ;; docbook-xsl catalog explicitly and get on with life.
1624 (("\"\\$XML_CATALOG_FILE\" \
1625 \"http://docbook.sourceforge.net/release/xsl/")
1626 (string-append (car (find-files (assoc-ref inputs "docbook-xsl")
1627 "^catalog.xml$"))
1628 " \"http://docbook.sourceforge.net/release/xsl/")))
1629 #t))
1630 (add-after 'install 'wrap-executables
1631 (lambda* (#:key outputs #:allow-other-keys)
1632 (let ((out (assoc-ref outputs "out")))
1633 (for-each (lambda (prog)
1634 (wrap-program prog
1635 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))))
1636 (find-files (string-append out "/bin")))
1637 #t))))
1638 #:configure-flags
1639 (list (string-append "--with-xml-catalog="
1640 (assoc-ref %build-inputs "docbook-xml")
1641 "/xml/dtd/docbook/catalog.xml"))))
1642 (native-inputs
1643 `(("pkg-config" ,pkg-config)
1644 ("itstool" ,itstool)
1645 ("libxml" ,libxml2)
1646 ("gettext" ,gettext-minimal)
1647 ("bc" ,bc)))
1648 (inputs
1649 `(("perl" ,perl)
1650 ("python" ,python)
1651 ("xsltproc" ,libxslt)
1652 ("dblatex" ,dblatex)
1653 ("docbook-xml" ,docbook-xml-4.3)
1654 ("docbook-xsl" ,docbook-xsl)
1655 ("source-highlight" ,source-highlight)
1656 ("glib" ,glib)
1657 ("python-six" ,python-six)))
1658 (home-page "https://www.gtk.org/gtk-doc/")
1659 (synopsis "Documentation generator from C source code")
1660 (description
1661 "GTK-Doc generates API documentation from comments added to C code. It is
1662 typically used to document the public API of GTK+ and GNOME libraries, but it
1663 can also be used to document application code.")
1664 (license license:gpl2+)))
1665
1666 (define-public gtk-engines
1667 (package
1668 (name "gtk-engines")
1669 (version "2.20.2")
1670 (source (origin
1671 (method url-fetch)
1672 (uri (string-append "mirror://gnome/sources/" name "/"
1673 (version-major+minor version) "/"
1674 name "-" version ".tar.bz2"))
1675 (sha256
1676 (base32
1677 "1db65pb0j0mijmswrvpgkdabilqd23x22d95hp5kwxvcramq1dhm"))))
1678 (build-system gnu-build-system)
1679 (arguments
1680 `(#:configure-flags
1681 `("--enable-animation")))
1682 (native-inputs
1683 `(("pkg-config" ,pkg-config)
1684 ("intltool" ,intltool)))
1685 (inputs
1686 ;; Don't propagate GTK+ to reduce "profile pollution".
1687 `(("gtk+" ,gtk+-2))) ; required by gtk-engines-2.pc
1688 (home-page "https://live.gnome.org/GnomeArt")
1689 (synopsis "Theming engines for GTK+ 2.x")
1690 (description
1691 "This package contains the standard GTK+ 2.x theming engines including
1692 Clearlooks, Crux, High Contrast, Industrial, LighthouseBlue, Metal, Mist,
1693 Redmond95 and ThinIce.")
1694 (license (list license:gpl2+ license:lgpl2.1+))))
1695
1696 (define-public murrine
1697 (package
1698 (name "murrine")
1699 (version "0.98.2")
1700 (source (origin
1701 (method url-fetch)
1702 (uri (string-append "mirror://gnome/sources/" name "/"
1703 (version-major+minor version) "/"
1704 name "-" version ".tar.xz"))
1705 (sha256
1706 (base32
1707 "129cs5bqw23i76h3nmc29c9mqkm9460iwc8vkl7hs4xr07h8mip9"))))
1708 (build-system gnu-build-system)
1709 (arguments
1710 `(#:configure-flags
1711 `("--enable-animation"
1712 "--enable-animationrtl")))
1713 (native-inputs
1714 `(("pkg-config" ,pkg-config)
1715 ("intltool" ,intltool)))
1716 (propagated-inputs
1717 `(("gtk+" ,gtk+-2)))
1718 (home-page "https://live.gnome.org/GnomeArt")
1719 (synopsis "Cairo-based theming engine for GTK+ 2.x")
1720 (description
1721 "Murrine is a cairo-based GTK+ theming engine. It is named after the
1722 glass artworks done by Venicians glass blowers.")
1723 (license license:gpl2+)))
1724
1725 (define-public gtkspell3
1726 (package
1727 (name "gtkspell3")
1728 (version "3.0.9")
1729 (source (origin
1730 (method url-fetch)
1731 (uri (string-append "mirror://sourceforge/gtkspell/"
1732 version "/" name "-" version ".tar.xz"))
1733 (sha256
1734 (base32
1735 "09jdicmpipmj4v84gnkqwbmj4lh8v0i6pn967rb9jx4zg2ia9x54"))))
1736 (build-system gnu-build-system)
1737 (native-inputs
1738 `(("intltool" ,intltool)
1739 ("pkg-config" ,pkg-config)
1740 ("vala" ,vala)))
1741 (inputs
1742 `(("gobject-introspection" ,gobject-introspection)
1743 ("gtk+" ,gtk+)
1744 ("pango" ,pango)))
1745 (propagated-inputs
1746 `(("enchant" ,enchant-1.6))) ;gtkspell3-3.0.pc refers to it
1747 (home-page "http://gtkspell.sourceforge.net")
1748 (synopsis "Spell-checking addon for GTK's TextView widget")
1749 (description
1750 "GtkSpell provides word-processor-style highlighting and replacement of
1751 misspelled words in a GtkTextView widget.")
1752 (license license:gpl2+)))
1753
1754 (define-public clipit
1755 (package
1756 (name "clipit")
1757 (version "1.4.4")
1758 (source
1759 (origin
1760 (method git-fetch)
1761 (uri (git-reference
1762 (url "https://github.com/CristianHenzel/ClipIt.git")
1763 (commit (string-append "v" version))))
1764 (file-name (git-file-name name version))
1765 (sha256
1766 (base32 "05xi29v2y0rvb33fmvrz7r9j4l858qj7ngwd7dp4pzpkkaybjln0"))))
1767 (build-system gnu-build-system)
1768 (native-inputs
1769 `(("autoconf" ,autoconf)
1770 ("automake" ,automake)
1771 ("intltool" ,intltool)
1772 ("pkg-config" ,pkg-config)))
1773 (inputs
1774 `(("gtk+" ,gtk+-2)))
1775 (home-page "https://github.com/CristianHenzel/ClipIt")
1776 (synopsis "Lightweight GTK+ clipboard manager")
1777 (description
1778 "ClipIt is a clipboard manager with features such as a history, search
1779 thereof, global hotkeys and clipboard item actions. It was forked from
1780 Parcellite and adds bugfixes and features.")
1781 (license license:gpl2+)))
1782
1783 (define-public graphene
1784 (package
1785 (name "graphene")
1786 (version "1.10.0")
1787 (source (origin
1788 (method url-fetch)
1789 (uri (string-append "https://github.com/ebassi/graphene/releases/"
1790 "download/" version
1791 "/graphene-" version ".tar.xz"))
1792 (sha256
1793 (base32 "16b4hz73bnrgv5v8n96dczkd6xp9qc06lrl43zln3jnl3psrfva0"))))
1794 (build-system meson-build-system)
1795 (arguments
1796 `(#:configure-flags '("-Dinstalled_tests=false")))
1797 (native-inputs
1798 `(("gobject-introspection" ,gobject-introspection)
1799 ("pkg-config" ,pkg-config)))
1800 (inputs
1801 `(("python" ,python)
1802 ("glib" ,glib)))
1803 (home-page "https://ebassi.github.io/graphene/")
1804 (synopsis "Thin layer of graphic data types")
1805 (description "This library provides graphic types and their relative API;
1806 it does not deal with windowing system surfaces, drawing, scene graphs, or
1807 input.")
1808 (license license:expat)))
1809
1810 (define-public spread-sheet-widget
1811 (package
1812 (name "spread-sheet-widget")
1813 (version "0.3")
1814 (source
1815 (origin
1816 (method url-fetch)
1817 (uri (string-append "https://alpha.gnu.org/gnu/ssw/"
1818 "spread-sheet-widget-" version ".tar.gz"))
1819 (sha256
1820 (base32 "1h93yyh2by6yrmkwqg38nd5knids05k5nqzcihc1hdwgzg3c4b8y"))))
1821 (build-system gnu-build-system)
1822 (native-inputs
1823 `(("glib" ,glib "bin") ; for glib-genmarshal, etc.
1824 ("pkg-config" ,pkg-config)))
1825 ;; In 'Requires' of spread-sheet-widget.pc.
1826 (propagated-inputs
1827 `(("glib" ,glib)
1828 ("gtk+" ,gtk+)))
1829 (home-page "https://www.gnu.org/software/ssw/")
1830 (synopsis "Gtk+ widget for dealing with 2-D tabular data")
1831 (description
1832 "GNU Spread Sheet Widget is a library for Gtk+ which provides a widget for
1833 viewing and manipulating 2 dimensional tabular data in a manner similar to many
1834 popular spread sheet programs.")
1835 (license license:gpl3+)))
1836
1837 (define-public volumeicon
1838 (package
1839 (name "volumeicon")
1840 (version "0.5.1")
1841 (source
1842 (origin
1843 (method url-fetch)
1844 (uri (string-append "http://nullwise.com/files/volumeicon/volumeicon-"
1845 version ".tar.gz"))
1846 (sha256
1847 (base32 "182xl2w8syv6ky2h2bc9imc6ap8pzh0p7rp63hh8nw0xm38c3f14"))))
1848 (build-system gnu-build-system)
1849 (arguments
1850 `(#:configure-flags
1851 (list "--enable-notify"))) ; optional libnotify support
1852 (native-inputs
1853 `(("intltool" ,intltool)
1854 ("pkg-config" ,pkg-config)))
1855 (inputs
1856 `(("alsa-lib" ,alsa-lib)
1857 ("gtk+" ,gtk+)
1858 ("libnotify" ,libnotify)))
1859 (home-page "http://nullwise.com/volumeicon.html")
1860 (synopsis "System tray volume applet")
1861 (description
1862 "Volume Icon is a volume indicator and control applet for @acronym{the
1863 Advanced Linux Sound Architecture, ALSA}. It sits in the system tray,
1864 independent of your desktop environment, and supports global key bindings.")
1865 (license (list license:expat ; src/{bind.c,keybinder.h}
1866 license:isc ; src/alsa_volume_mapping.c
1867 license:gpl3)))) ; the rest & combined work
1868
1869 (define-public yad
1870 (package
1871 (name "yad")
1872 (version "5.0")
1873 (source
1874 (origin
1875 (method git-fetch)
1876 (uri (git-reference
1877 (url "https://github.com/v1cont/yad.git")
1878 (commit (string-append "v" version))))
1879 (file-name (git-file-name name version))
1880 (sha256
1881 (base32 "07rd61hvilsxxrj7lf8c9k0a8glj07s48m7ya8d45030r90g3lvc"))))
1882 (build-system glib-or-gtk-build-system)
1883 (arguments
1884 `(#:configure-flags
1885 ;; Passing --enable-foo will silently disable foo if prerequisite
1886 ;; inputs are missing, not abort the build as one might expect.
1887 ;; ‘--enable-html’ adds a huge webkitgtk dependency. It was never
1888 ;; present in the past and nobody complained.
1889 '("--enable-icon-browser"
1890 "--enable-spell") ; gspell checking support
1891 #:phases
1892 (modify-phases %standard-phases
1893 (add-after 'bootstrap 'intltoolize
1894 (lambda _
1895 (invoke "intltoolize" "--force" "--automake"))))))
1896 (inputs
1897 `(("gspell" ,gspell)
1898 ("gtk+" ,gtk+)))
1899 (native-inputs
1900 `(("autoconf" ,autoconf)
1901 ("automake" ,automake)
1902 ("intltool" ,intltool)
1903 ("pkg-config" ,pkg-config)))
1904 (home-page "https://sourceforge.net/projects/yad-dialog/")
1905 (synopsis "GTK+ dialog boxes for shell scripts")
1906 (description
1907 "This program allows you to display GTK+ dialog boxes from command line or
1908 shell scripts. Example of how to use @code{yad} can be consulted at
1909 @url{https://sourceforge.net/p/yad-dialog/wiki/browse_pages/}.")
1910 (license license:gpl3+)))
1911
1912 (define-public libdbusmenu
1913 (package
1914 (name "libdbusmenu")
1915 (version "16.04.0")
1916 (source
1917 (origin
1918 (method url-fetch)
1919 (uri (string-append "https://launchpad.net/libdbusmenu/"
1920 (version-major+minor version) "/" version
1921 "/+download/libdbusmenu-" version ".tar.gz"))
1922 (sha256
1923 (base32 "12l7z8dhl917iy9h02sxmpclnhkdjryn08r8i4sr8l3lrlm4mk5r"))))
1924 (build-system gnu-build-system)
1925 (arguments
1926 `(#:configure-flags
1927 '("--sysconfdir=/etc"
1928 "--localstatedir=/var"
1929 ;; The shebang of the generated test files should be patched before
1930 ;; enabling tests.
1931 "--disable-tests")
1932 #:make-flags
1933 `(,(string-append "typelibdir=" (assoc-ref %outputs "out")
1934 "/lib/girepository-1.0"))
1935 #:phases
1936 (modify-phases %standard-phases
1937 (add-before 'configure 'do-not-treat-warnings-as-errors
1938 (lambda _
1939 ;; Prevent the build from failing due to deprecation warnings
1940 ;; from newer GLib and GTK versions.
1941 (substitute* (find-files "." "^Makefile.in$")
1942 ((" -Werror")
1943 ""))
1944 #t))
1945 (add-before 'configure 'set-environment
1946 (lambda _
1947 (setenv "HAVE_VALGRIND_TRUE" "")
1948 (setenv "HAVE_VALGRIND_FALSE" "#")
1949 #t)))))
1950 (inputs
1951 `(("glib" ,glib)
1952 ("gtk+" ,gtk+)
1953 ("gtk+-2" ,gtk+-2)))
1954 (native-inputs
1955 `(("glib:bin" ,glib "bin")
1956 ("gnome-doc-utils" ,gnome-doc-utils)
1957 ("gobject-introspection" ,gobject-introspection)
1958 ("intltool" ,intltool)
1959 ("json-glib" ,json-glib)
1960 ("pkg-config" ,pkg-config)
1961 ("python" ,python-2)
1962 ("vala" ,vala)))
1963 (home-page "https://launchpad.net/libdbusmenu")
1964 (synopsis "Library for passing menus over DBus")
1965 (description "@code{libdbusmenu} passes a menu structure across DBus so
1966 that a program can create a menu simply without worrying about how it is
1967 displayed on the other side of the bus.")
1968
1969 ;; Dual-licensed under either LGPLv2.1 or LGPLv3.
1970 (license (list license:lgpl2.1 license:lgpl3))))
1971
1972 (define-public gtk-layer-shell
1973 (package
1974 (name "gtk-layer-shell")
1975 (version "0.1.0")
1976 (source
1977 (origin
1978 (method url-fetch)
1979 (uri (string-append
1980 "https://github.com/wmww/gtk-layer-shell/releases/download/v"
1981 version "/gtk-layer-shell-" version ".tar.xz"))
1982 (sha256
1983 (base32 "0ncklk3z0fzlz6p76jdcrr1ykyp1f4ykjjch4x2hfp9bwsnl4a3m"))))
1984 (build-system meson-build-system)
1985 (native-inputs `(("pkg-config" ,pkg-config)
1986 ("gobject-introspection" ,gobject-introspection)))
1987 (inputs `(("wayland" ,wayland)
1988 ("gtk+" ,gtk+)))
1989 (home-page "https://github.com/wmww/gtk-layer-shell")
1990 (synopsis "Library to create Wayland desktop components using the Layer
1991 Shell protocol")
1992 (description "Layer Shell is a Wayland protocol for desktop shell
1993 components, such as panels, notifications and wallpapers. It can be used to
1994 anchor windows to a corner or edge of the output, or stretch them across the
1995 entire output. It supports all Layer Shell features including popups and
1996 popovers.")
1997 (license license:expat)))
1998
1999 (define-public goocanvas
2000 (package
2001 (name "goocanvas")
2002 (version "2.0.4")
2003 (source
2004 (origin
2005 (method url-fetch)
2006 (uri (string-append "mirror://gnome/sources/goocanvas/"
2007 (version-major+minor version)
2008 "/goocanvas-" version ".tar.xz"))
2009 (sha256
2010 (base32 "141fm7mbqib0011zmkv3g8vxcjwa7hypmq71ahdyhnj2sjvy4a67"))))
2011 (build-system gnu-build-system)
2012 (native-inputs
2013 `(("gettext" ,gettext-minimal)
2014 ("glib-bin" ,glib "bin")
2015 ("gobject-introspection" ,gobject-introspection)
2016 ("gtk-doc" ,gtk-doc)
2017 ("pkg-config" ,pkg-config)
2018 ("python" ,python)))
2019 (inputs
2020 `(("cairo" ,cairo)
2021 ("glib" ,glib)
2022 ("gtk+" ,gtk+)
2023 ("python-pygobject" ,python-pygobject)))
2024 (arguments
2025 `(#:configure-flags '("--disable-rebuilds"
2026 "--disable-static")
2027 #:phases
2028 (modify-phases %standard-phases
2029 (add-after 'unpack 'fix-install-path
2030 (lambda* (#:key inputs outputs #:allow-other-keys)
2031 (substitute* "configure"
2032 (("\\(gi._overridesdir\\)")
2033 (string-append "((gi._overridesdir).replace(\\\""
2034 (assoc-ref inputs "python-pygobject")
2035 "\\\", \\\""
2036 (assoc-ref outputs "out")
2037 "\\\"))")))
2038 #t)))))
2039 (synopsis "Canvas widget for GTK+")
2040 (description "GooCanvas is a canvas widget for GTK+ that uses the cairo 2D
2041 library for drawing.")
2042 (home-page "https://wiki.gnome.org/GooCanvas")
2043 (license license:lgpl2.0)))
2044
2045 (define-public gtksheet
2046 (package
2047 (name "gtksheet")
2048 (version "4.3.4")
2049 (source
2050 (origin
2051 (method git-fetch)
2052 (uri (git-reference
2053 (url "https://github.com/fpaquet/gtksheet")
2054 (commit (string-append "V" version))))
2055 (file-name (git-file-name name version))
2056 (sha256
2057 (base32
2058 "10qzmdkjkkvkcadxn019cbyhwaahxcfv1apv54lc711bqvh63v8r"))))
2059 (build-system gnu-build-system)
2060 (arguments
2061 `(#:configure-flags (list "--enable-glade"
2062 "--enable-introspection")
2063 #:phases
2064 (modify-phases %standard-phases
2065 ;; The "configure" script is present, but otherwise the project is
2066 ;; not bootstrapped properly. Delete configure so the bootstrap phase
2067 ;; will take over.
2068 (add-after 'unpack 'delete-configure
2069 (lambda _
2070 (delete-file "configure")
2071 #t))
2072 ;; Fix glade install directories.
2073 (add-before 'bootstrap 'configure-glade-directories
2074 (lambda* (#:key outputs #:allow-other-keys)
2075 (substitute* "configure.ac"
2076 (("`\\$PKG_CONFIG --variable=catalogdir gladeui-2.0`")
2077 (string-append (assoc-ref outputs "out") "/share/glade/catalogs"))
2078 (("`\\$PKG_CONFIG --variable=moduledir gladeui-2.0`")
2079 (string-append (assoc-ref outputs "out") "/lib/glade/modules"))
2080 (("`\\$PKG_CONFIG --variable=pixmapdir gladeui-2.0`")
2081 (string-append (assoc-ref outputs "out") "/share/pixmaps")))
2082 #t))
2083 ;; Fix incorrect typelib version. This is a known upstream bug. See
2084 ;; https://github.com/fpaquet/gtksheet/issues/23
2085 (add-after 'install 'fix-typelib-version
2086 (lambda* (#:key outputs #:allow-other-keys)
2087 (with-directory-excursion (string-append (assoc-ref outputs "out")
2088 "/lib/girepository-1.0")
2089 (rename-file "GtkSheet-4.0.typelib"
2090 (string-append "GtkSheet-" ,version ".typelib")))
2091 #t)))))
2092 (inputs
2093 `(("glade" ,glade3)
2094 ("glib" ,glib)
2095 ("gtk+" ,gtk+)
2096 ("libxml2" ,libxml2)))
2097 (native-inputs
2098 `(("autoconf" ,autoconf)
2099 ("automake" ,automake)
2100 ("gobject-introspection" ,gobject-introspection)
2101 ("libtool" ,libtool)
2102 ("pkg-config" ,pkg-config)))
2103 (home-page "https://fpaquet.github.io/gtksheet/")
2104 (synopsis "Spreadsheet widget for GTK+")
2105 (description "GtkSheet is a matrix widget for GTK+. It consists of an
2106 scrollable grid of cells where you can allocate text. Cell contents can be
2107 edited interactively through a specially designed entry, GtkItemEntry. It is
2108 also a container subclass, allowing you to display buttons, images and any
2109 other widget in it. You can also set many attributes such as border,
2110 foreground and background colors, text justification and more.")
2111 (native-search-paths
2112 (list
2113 (search-path-specification
2114 (variable "GLADE_CATALOG_SEARCH_PATH")
2115 (files '("share/glade/catalogs")))
2116 (search-path-specification
2117 (variable "GLADE_MODULE_SEARCH_PATH")
2118 (files '("lib/glade/modules")))))
2119 (license license:lgpl2.0+)))