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