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