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