gnu: youtube-dl: Update to 2016.02.22.
[jackhill/guix/guix.git] / gnu / packages / gtk.scm
CommitLineData
3a08a411
AE
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
7ec42f1d 3;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
97f94f5e 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
b38e45d8 5;;; Copyright © 2014 Eric Bavier <bavier@member.fsf.org>
a6035fc1 6;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
136770c9 7;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
dfbce50c 8;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
3bc45449 9;;; Copyright © 2015 Andy Wingo <wingo@igalia.com>
c900f843 10;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
5b003972 11;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
b7807bb2 12;;; Copyright © 2016 Fabian Harfert <fhmgufs@web.de>
3a08a411
AE
13;;;
14;;; This file is part of GNU Guix.
15;;;
16;;; GNU Guix is free software; you can redistribute it and/or modify it
17;;; under the terms of the GNU General Public License as published by
18;;; the Free Software Foundation; either version 3 of the License, or (at
19;;; your option) any later version.
20;;;
21;;; GNU Guix is distributed in the hope that it will be useful, but
22;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24;;; GNU General Public License for more details.
25;;;
26;;; You should have received a copy of the GNU General Public License
27;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28
29(define-module (gnu packages gtk)
b5b73a82 30 #:use-module ((guix licenses) #:prefix license:)
b38e45d8 31 #:use-module (guix utils)
3a08a411
AE
32 #:use-module (guix packages)
33 #:use-module (guix download)
34 #:use-module (guix build-system gnu)
0b96fb2a 35 #:use-module (guix build-system python)
e926ba71 36 #:use-module (guix build-system waf)
b837e658 37 #:use-module (gnu packages)
3bc45449 38 #:use-module (gnu packages algebra)
1a51fe27
LC
39 #:use-module (gnu packages autotools)
40 #:use-module (gnu packages texinfo)
136770c9 41 #:use-module (gnu packages check)
6131c43d 42 #:use-module (gnu packages compression)
3bc45449 43 #:use-module (gnu packages docbook)
6131c43d 44 #:use-module (gnu packages fontutils)
3bc45449 45 #:use-module (gnu packages gettext)
6131c43d 46 #:use-module (gnu packages ghostscript)
31b254a3 47 #:use-module (gnu packages gl)
3a08a411 48 #:use-module (gnu packages glib)
95d439b2 49 #:use-module (gnu packages gnome)
a2609b41 50 #:use-module (gnu packages icu4c)
e55354b8 51 #:use-module (gnu packages image)
6131c43d 52 #:use-module (gnu packages pdf)
8b79a547 53 #:use-module (gnu packages perl)
6131c43d 54 #:use-module (gnu packages pkg-config)
3bc45449 55 #:use-module (gnu packages pretty-print)
6131c43d 56 #:use-module (gnu packages python)
8e70e6d2 57 #:use-module (gnu packages guile)
37cb3a69 58 #:use-module (gnu packages cups)
8e70e6d2 59 #:use-module (gnu packages xml)
6c0e878e
LC
60 #:use-module (gnu packages xorg)
61 #:use-module (gnu packages xdisorg))
3a08a411
AE
62
63(define-public atk
64 (package
65 (name "atk")
492b0e38 66 (version "2.18.0")
3a08a411
AE
67 (source (origin
68 (method url-fetch)
3b8e4347 69 (uri (string-append "mirror://gnome/sources/" name "/"
b38e45d8
EB
70 (version-major+minor version) "/"
71 name "-" version ".tar.xz"))
3a08a411
AE
72 (sha256
73 (base32
492b0e38 74 "0ay9s137x49f0akx658p7kznz0rdapfrd8ym54q0hlgrggblhv6f"))))
3a08a411 75 (build-system gnu-build-system)
cd0466eb
SB
76 (outputs '("out" "doc"))
77 (arguments
78 `(#:configure-flags
79 (list (string-append "--with-html-dir="
80 (assoc-ref %outputs "doc")
81 "/share/gtk-doc/html"))))
13a9e291 82 (propagated-inputs `(("glib" ,glib))) ; required by atk.pc
141aed80
LC
83 (native-inputs
84 `(("pkg-config" ,pkg-config)
426adbe8 85 ("glib" ,glib "bin") ; glib-mkenums, etc.
141aed80 86 ("gobject-introspection" ,gobject-introspection))) ; g-ir-compiler, etc.
c5cc5006 87 (synopsis "GNOME accessibility toolkit")
3a08a411
AE
88 (description
89 "ATK provides the set of accessibility interfaces that are implemented
35b9e423 90by other toolkits and applications. Using the ATK interfaces, accessibility
3a08a411
AE
91tools have full access to view and control running applications.")
92 (license license:lgpl2.0+)
93 (home-page "https://developer.gnome.org/atk/")))
6131c43d
AE
94
95(define-public cairo
96 (package
97 (name "cairo")
d8720c50 98 (version "1.14.2")
6131c43d
AE
99 (source (origin
100 (method url-fetch)
101 (uri (string-append "http://cairographics.org/releases/cairo-"
102 version ".tar.xz"))
103 (sha256
104 (base32
d8720c50 105 "1sycbq0agbwmg1bj9lhkgsf0glmblaf2jrdy9g6vxfxivncxj6f9"))))
6131c43d
AE
106 (build-system gnu-build-system)
107 (propagated-inputs
108 `(("fontconfig" ,fontconfig)
109 ("freetype" ,freetype)
110 ("glib" ,glib)
111 ("libpng" ,libpng)
112 ("libx11" ,libx11)
113 ("libxext" ,libxext)
114 ("libxrender" ,libxrender)
115 ("pixman" ,pixman)))
116 (inputs
117 `(("ghostscript" ,ghostscript)
118 ("libspectre" ,libspectre)
6131c43d 119 ("poppler" ,poppler)
6131c43d
AE
120 ("xextproto" ,xextproto)
121 ("zlib" ,zlib)))
c4c4cc05
JD
122 (native-inputs
123 `(("pkg-config" ,pkg-config)
124 ("python" ,python-wrapper)))
6131c43d 125 (arguments
77888fae
MW
126 `(#:tests? #f ; see http://lists.gnu.org/archive/html/bug-guix/2013-06/msg00085.html
127 #:configure-flags '("--enable-tee"))) ; needed for GNU Icecat
6131c43d
AE
128 (synopsis "2D graphics library")
129 (description
130 "Cairo is a 2D graphics library with support for multiple output devices.
131Currently supported output targets include the X Window System (via both
132Xlib and XCB), Quartz, Win32, image buffers, PostScript, PDF, and SVG file
35b9e423 133output. Experimental backends include OpenGL, BeOS, OS/2, and DirectFB.
6131c43d
AE
134
135Cairo is designed to produce consistent output on all output media while
136taking advantage of display hardware acceleration when available
137eg. through the X Render Extension).
138
139The cairo API provides operations similar to the drawing operators of
35b9e423 140PostScript and PDF. Operations in cairo including stroking and filling cubic
6131c43d 141Bézier splines, transforming and compositing translucent images, and
35b9e423 142antialiased text rendering. All drawing operations can be transformed by any
e881752c 143affine transformation (scale, rotation, shear, etc.).")
6131c43d
AE
144 (license license:lgpl2.1) ; or Mozilla Public License 1.1
145 (home-page "http://cairographics.org/")))
a2609b41
AE
146
147(define-public harfbuzz
148 (package
149 (name "harfbuzz")
202e2e41 150 (version "1.0.6")
a2609b41 151 (source (origin
fd9b3b43 152 (method url-fetch)
5cc3096c 153 (uri (string-append "https://www.freedesktop.org/software/"
fd9b3b43
SB
154 "harfbuzz/release/harfbuzz-"
155 version ".tar.bz2"))
156 (sha256
157 (base32
202e2e41 158 "09ivk5m4y09ar4zi9r6db7gp234cy05h0ach7w22g9kqvkxsf5pn"))))
a2609b41 159 (build-system gnu-build-system)
0a129f39
SB
160 (outputs '("out"
161 "bin")) ; 160K, only hb-view depend on cairo
a2609b41 162 (inputs
fd9b3b43
SB
163 `(("cairo" ,cairo)))
164 (propagated-inputs
165 ;; There are all in the Requires or Requires.private field of '.pc'.
166 `(("glib" ,glib)
27383915 167 ("graphite2" ,graphite2)
c4c4cc05
JD
168 ("icu4c" ,icu4c)))
169 (native-inputs
a30a0455
SB
170 `(("gobject-introspection" ,gobject-introspection)
171 ("pkg-config" ,pkg-config)
ac462e52 172 ("python" ,python-2))) ; incompatible with Python 3 (print syntax)
27383915 173 (arguments
a30a0455 174 `(#:configure-flags `("--with-graphite2"
eb6afbcd
SB
175 "--with-gobject"
176 ,(string-append
177 "--bindir=" (assoc-ref %outputs "bin") "/bin"))))
35b9e423 178 (synopsis "OpenType text shaping engine")
a2609b41
AE
179 (description
180 "HarfBuzz is an OpenType text shaping engine.")
181 (license (license:x11-style "file://COPYING"
182 "See 'COPYING' in the distribution."))
183 (home-page "http://www.freedesktop.org/wiki/Software/HarfBuzz/")))
4b9adff9
AE
184
185(define-public pango
186 (package
187 (name "pango")
e9457878 188 (version "1.38.1")
4b9adff9
AE
189 (source (origin
190 (method url-fetch)
dca1b58d
FB
191 (uri (string-append "mirror://gnome/sources/pango/"
192 (version-major+minor version) "/"
193 name "-" version ".tar.xz"))
4b9adff9
AE
194 (sha256
195 (base32
e9457878 196 "1dsf45m51i4rcyvh5wlxxrjfhvn5b67d5ckjc6vdcxbddjgmc80k"))))
4b9adff9 197 (build-system gnu-build-system)
cf2135ff 198 (propagated-inputs
4b9adff9 199 `(("cairo" ,cairo)
4169a4bc
AE
200 ("harfbuzz" ,harfbuzz)))
201 (inputs
9a5acb54
JL
202 `(("zlib" ,zlib)
203
204 ;; Some packages, such as Openbox, expect Pango to be built with the
205 ;; optional libxft support.
206 ("libxft" ,libxft)))
c4c4cc05 207 (native-inputs
141aed80 208 `(("pkg-config" ,pkg-config)
426adbe8 209 ("glib" ,glib "bin") ; glib-mkenums, etc.
141aed80 210 ("gobject-introspection" ,gobject-introspection))) ; g-ir-compiler, etc.
4b9adff9
AE
211 (synopsis "GNOME text and font handling library")
212 (description
213 "Pango is the core text and font handling library used in GNOME
35b9e423 214applications. It has extensive support for the different writing systems
4b9adff9
AE
215used throughout the world.")
216 (license license:lgpl2.0+)
217 (home-page "https://developer.gnome.org/pango/")))
527e7961 218
5698b8b8
JD
219(define-public pangox-compat
220 (package
221 (name "pangox-compat")
222 (version "0.0.2")
223 (source (origin
224 (method url-fetch)
b38e45d8
EB
225 (uri (string-append "mirror://gnome/sources/" name "/"
226 (version-major+minor version) "/"
227 name "-" version ".tar.xz"))
5698b8b8
JD
228 (sha256
229 (base32
230 "0ip0ziys6mrqqmz4n71ays0kf5cs1xflj1gfpvs4fgy2nsrr482m"))))
231 (build-system gnu-build-system)
232 (inputs
233 `(("glib" ,glib)
234 ("pango" ,pango)))
235 (native-inputs
236 `(("intltool" ,intltool)
237 ("pkg-config" ,pkg-config)))
238 (home-page "https://developer.gnome.org/pango")
35b9e423 239 (synopsis "Obsolete pango functions")
5698b8b8
JD
240 (description "Pangox was a X backend to pango. It is now obsolete and no
241longer provided by recent pango releases. pangox-compat provides the
242functions which were removed.")
243 (license license:lgpl2.0+)))
244
e926ba71
RW
245(define-public ganv
246 (package
247 (name "ganv")
248 (version "1.4.2")
249 (source (origin
250 (method url-fetch)
251 (uri (string-append "http://download.drobilla.net/ganv-"
ea7f3349 252 version ".tar.bz2"))
e926ba71
RW
253 (sha256
254 (base32
255 "0g7s5mp14qgbfjdql0k1s8464r21g47ssn5dws6jazsnw6njhl0l"))))
256 (build-system waf-build-system)
ea7f3349
LC
257 (arguments
258 `(#:phases (alist-cons-before
d8c317df 259 'configure 'set-flags
ea7f3349 260 (lambda* (#:key outputs #:allow-other-keys)
d8c317df
SB
261 ;; Compile with C++11, required by gtkmm.
262 (setenv "CXXFLAGS" "-std=c++11")
ea7f3349
LC
263 ;; Allow 'bin/ganv_bench' to find libganv-1.so.
264 (setenv "LDFLAGS"
265 (string-append "-Wl,-rpath="
266 (assoc-ref outputs "out") "/lib")))
267 %standard-phases)
268 #:tests? #f)) ; no check target
e926ba71
RW
269 (inputs
270 `(("gtk" ,gtk+-2)
271 ("gtkmm" ,gtkmm-2)))
272 (native-inputs
273 `(("glib" ,glib "bin") ; for glib-genmarshal, etc.
274 ("pkg-config" ,pkg-config)))
275 (home-page "http://drobilla.net/software/ganv/")
276 (synopsis "GTK+ widget for interactive graph-like environments")
277 (description
278 "Ganv is an interactive GTK+ widget for interactive “boxes and lines” or
279graph-like environments, e.g. modular synths or finite state machine
280diagrams.")
281 (license license:gpl3+)))
95d439b2 282
c900f843 283(define-public gtksourceview-2
95d439b2
JD
284 (package
285 (name "gtksourceview")
286 (version "2.10.5") ; This is the last version which builds against gtk+2
287 (source (origin
288 (method url-fetch)
b38e45d8
EB
289 (uri (string-append "mirror://gnome/sources/" name "/"
290 (version-major+minor version) "/"
291 name "-" version ".tar.bz2"))
95d439b2
JD
292 (sha256
293 (base32
294 "07hrabhpl6n8ajz10s0d960jdwndxs87szxyn428mpxi8cvpg1f5"))))
295 (build-system gnu-build-system)
296 (inputs
c4c4cc05 297 `(("gtk" ,gtk+-2)
95d439b2
JD
298 ;; These two are needed only to allow the tests to run successfully.
299 ("xorg-server" ,xorg-server)
300 ("shared-mime-info" ,shared-mime-info)))
c4c4cc05 301 (native-inputs
44add1ce 302 `(("intltool" ,intltool)
221ed17a 303 ("glib" ,glib "bin") ; for glib-genmarshal, etc.
c4c4cc05 304 ("pkg-config" ,pkg-config)))
68d85de1
TUBK
305 (propagated-inputs
306 ;; As per the pkg-config file.
307 `(("libxml2" ,libxml2)))
95d439b2
JD
308 (arguments
309 `(#:phases
310 ;; Unfortunately, some of the tests in "make check" are highly dependent
311 ;; on the environment therefore, some black magic is required.
312 (alist-cons-before
313 'check 'start-xserver
314 (lambda* (#:key inputs #:allow-other-keys)
315 (let ((xorg-server (assoc-ref inputs "xorg-server"))
316 (mime (assoc-ref inputs "shared-mime-info")))
317
318 ;; There must be a running X server and make check doesn't start one.
319 ;; Therefore we must do it.
320 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
321 (setenv "DISPLAY" ":1")
322
323 ;; The .lang files must be found in $XDG_DATA_HOME/gtksourceview-2.0
324 (system "ln -s gtksourceview gtksourceview-2.0")
325 (setenv "XDG_DATA_HOME" (getcwd))
326
327 ;; Finally, the mimetypes must be available.
328 (setenv "XDG_DATA_DIRS" (string-append mime "/share/")) ))
329 %standard-phases)))
330 (synopsis "Widget that extends the standard GTK+ 2.x 'GtkTextView' widget")
331 (description
332 "GtkSourceView is a portable C library that extends the standard GTK+
333framework for multiline text editing with support for configurable syntax
334highlighting, unlimited undo/redo, search and replace, a completion framework,
335printing and other features typical of a source code editor.")
336 (license license:lgpl2.0+)
337 (home-page "https://developer.gnome.org/gtksourceview/")))
338
c900f843
DH
339(define-public gtksourceview
340 (package
341 (name "gtksourceview")
7965a94a 342 (version "3.18.2")
c900f843
DH
343 (source (origin
344 (method url-fetch)
345 (uri (string-append "mirror://gnome/sources/" name "/"
346 (version-major+minor version) "/"
347 name "-" version ".tar.xz"))
348 (sha256
349 (base32
7965a94a 350 "1cmplnqbyd1js5bkpi9cfc3gljilyxg5nngwh4i3mq9r02gmmxv0"))))
c900f843
DH
351 (build-system gnu-build-system)
352 (arguments
353 '(#:phases
354 (modify-phases %standard-phases
355 (add-before
356 'check 'pre-check
357 (lambda* (#:key inputs #:allow-other-keys)
358 (let ((xorg-server (assoc-ref inputs "xorg-server")))
359 ;; Tests require a running X server.
360 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
361 (setenv "DISPLAY" ":1")
362 ;; For the missing /etc/machine-id.
363 (setenv "DBUS_FATAL_WARNINGS" "0")
364 #t))))))
365 (native-inputs
366 `(("glib:bin" ,glib "bin") ; for glib-genmarshal, etc.
367 ("intltool" ,intltool)
368 ("itstool", itstool)
369 ("gobject-introspection" ,gobject-introspection)
370 ("pkg-config" ,pkg-config)
371 ("vala" ,vala)
372 ;; For testing.
373 ("xorg-server" ,xorg-server)
374 ("shared-mime-info" ,shared-mime-info)))
375 (propagated-inputs
376 ;; gtksourceview-3.0.pc refers to all these.
377 `(("glib" ,glib)
378 ("gtk+" ,gtk+)
379 ("libxml2" ,libxml2)))
380 (home-page "https://wiki.gnome.org/Projects/GtkSourceView")
381 (synopsis "GNOME source code widget")
382 (description "GtkSourceView is a text widget that extends the standard
383GTK+ text widget GtkTextView. It improves GtkTextView by implementing syntax
384highlighting and other features typical of a source code editor.")
385 (license license:lgpl2.1+)))
386
527e7961
AE
387(define-public gdk-pixbuf
388 (package
389 (name "gdk-pixbuf")
fe08b6e1 390 (version "2.32.3")
527e7961
AE
391 (source (origin
392 (method url-fetch)
b38e45d8
EB
393 (uri (string-append "mirror://gnome/sources/" name "/"
394 (version-major+minor version) "/"
395 name "-" version ".tar.xz"))
527e7961
AE
396 (sha256
397 (base32
fe08b6e1 398 "0cfh87aqyqbfcwpbv1ihgmgfcn66il5q2n8yjyl8gxkjmkqp2rrb"))))
527e7961 399 (build-system gnu-build-system)
48f46dc3 400 (arguments
a63a73dc
SB
401 '(#:configure-flags '("--with-x11")
402 #:phases
403 (modify-phases %standard-phases
404 (add-after
405 'unpack 'disable-failing-tests
406 (lambda _
407 (substitute* "tests/Makefile.in"
fe08b6e1
EF
408 ;; XXX FIXME: This test fails on armhf machines with:
409 ;; SKIP Not enough memory to load bitmap image
410 ;; ERROR: cve-2015-4491 - too few tests run (expected 4, got 2)
a63a73dc
SB
411 (("cve-2015-4491\\$\\(EXEEXT\\) ") "")
412 ;; XXX FIXME: This test fails with:
413 ;; ERROR:pixbuf-jpeg.c:74:test_type9_rotation_exif_tag:
414 ;; assertion failed (error == NULL): Data differ
415 ;; (gdk-pixbuf-error-quark, 0)
416 (("pixbuf-jpeg\\$\\(EXEEXT\\) ") ""))
417 #t)))))
1b5758a6 418 (propagated-inputs ; required by gdk-pixbuf-2.0.pc
527e7961 419 `(("glib" ,glib)
1b5758a6
SB
420 ("libpng" ,libpng)))
421 (inputs
422 `(("libjpeg" ,libjpeg)
48f46dc3
SB
423 ("libtiff" ,libtiff)
424 ("libx11" ,libx11)))
c4c4cc05 425 (native-inputs
141aed80 426 `(("pkg-config" ,pkg-config)
426adbe8 427 ("glib" ,glib "bin") ; glib-mkenums, etc.
141aed80 428 ("gobject-introspection", gobject-introspection))) ; g-ir-compiler, etc.
527e7961
AE
429 (synopsis "GNOME image loading and manipulation library")
430 (description
431 "GdkPixbuf is a library for image loading and manipulation developed
432in the GNOME project.")
433 (license license:lgpl2.0+)
434 (home-page "https://developer.gnome.org/gdk-pixbuf/")))
cf2135ff 435
f3fb92e5
AE
436(define-public at-spi2-core
437 (package
438 (name "at-spi2-core")
f14c0a49 439 (version "2.18.1")
f3fb92e5
AE
440 (source (origin
441 (method url-fetch)
442 (uri (string-append "mirror://gnome/sources/" name "/"
b38e45d8
EB
443 (version-major+minor version) "/"
444 name "-" version ".tar.xz"))
f3fb92e5
AE
445 (sha256
446 (base32
f14c0a49 447 "1kq17w4fm51d49vzmglkxqdm6s0yvjvrpgw78r2hajf69jz5bmap"))))
f3fb92e5 448 (build-system gnu-build-system)
068a53c3 449 (outputs '("out" "doc"))
f3fb92e5 450 (arguments
b19d6805 451 '(#:configure-flags
068a53c3
SB
452 (list (string-append "--with-html-dir="
453 (assoc-ref %outputs "doc")
454 "/share/gtk-doc/html"))
50cc7f41 455 #:phases
af108677 456 (modify-phases %standard-phases
3a4de6b2 457 (replace 'check
af108677
SB
458 ;; Run test-suite under a dbus session.
459 (lambda _
37fe56cf
SB
460 ;; Don't fail on missing '/etc/machine-id'.
461 (setenv "DBUS_FATAL_WARNINGS" "0")
af108677 462 (zero? (system* "dbus-launch" "make" "check")))))))
c6a552da
SB
463 (propagated-inputs
464 ;; atspi-2.pc refers to all these.
465 `(("dbus" ,dbus)
466 ("glib" ,glib)))
467 (inputs
468 `(("libxi" ,libxi)
469 ("libxtst" ,libxtst)))
c4c4cc05 470 (native-inputs
50cc7f41
SB
471 `(("gobject-introspection" ,gobject-introspection)
472 ("intltool" ,intltool)
473 ("pkg-config" ,pkg-config)))
f3fb92e5
AE
474 (synopsis "Assistive Technology Service Provider Interface, core components")
475 (description
476 "The Assistive Technology Service Provider Interface, core components,
477is part of the GNOME accessibility project.")
478 (license license:lgpl2.0+)
479 (home-page "https://projects.gnome.org/accessibility/")))
480
5fda4784
AE
481(define-public at-spi2-atk
482 (package
483 (name "at-spi2-atk")
9fbfb4ec 484 (version "2.18.1")
5fda4784
AE
485 (source (origin
486 (method url-fetch)
487 (uri (string-append "mirror://gnome/sources/" name "/"
b38e45d8
EB
488 (version-major+minor version) "/"
489 name "-" version ".tar.xz"))
5fda4784
AE
490 (sha256
491 (base32
9fbfb4ec 492 "0bf1g5cj84rmx7p1q547vwbc0hlpcs2wrxnmv96lckfkhs9mzcf4"))))
5fda4784 493 (build-system gnu-build-system)
5fda4784 494 (arguments
57fcd224
SB
495 '(#:phases
496 (modify-phases %standard-phases
3a4de6b2 497 (replace 'check
57fcd224
SB
498 ;; Run test-suite under a dbus session.
499 (lambda _
5fba12ec 500 (setenv "DBUS_FATAL_WARNINGS" "0")
57fcd224 501 (zero? (system* "dbus-launch" "make" "check")))))))
6967cc3f
SB
502 (propagated-inputs
503 `(("at-spi2-core" ,at-spi2-core))) ; required by atk-bridge-2.0.pc
504 (inputs
505 `(("atk" ,atk)))
c4c4cc05 506 (native-inputs
6967cc3f
SB
507 `(("dbus" ,dbus) ; for testing
508 ("pkg-config" ,pkg-config)))
5fda4784
AE
509 (synopsis "Assistive Technology Service Provider Interface, ATK bindings")
510 (description
511 "The Assistive Technology Service Provider Interface
512is part of the GNOME accessibility project.")
513 (license license:lgpl2.0+)
514 (home-page "https://projects.gnome.org/accessibility/")))
515
8b79a547 516(define-public gtk+-2
cf2135ff
AE
517 (package
518 (name "gtk+")
62b7015b 519 (version "2.24.28")
cf2135ff
AE
520 (source (origin
521 (method url-fetch)
1c8362a8 522 (uri (string-append "mirror://gnome/sources/" name "/"
b38e45d8
EB
523 (version-major+minor version) "/"
524 name "-" version ".tar.xz"))
cf2135ff
AE
525 (sha256
526 (base32
2a6afac9
RW
527 "0mj6xn40py9r9lvzg633fal81xfwfm89d9mvz7jk4lmwk0g49imj"))
528 (patches (list (search-patch "gtk2-respect-GUIX_GTK2_PATH.patch")))))
cf2135ff 529 (build-system gnu-build-system)
6b1f2388 530 (outputs '("out" "doc"))
4169a4bc 531 (propagated-inputs
cf2135ff 532 `(("atk" ,atk)
cf2135ff 533 ("gdk-pixbuf" ,gdk-pixbuf)
4169a4bc 534 ("pango" ,pango)))
dfbce50c
SB
535 (inputs
536 `(("cups" ,cups)
537 ("libxcomposite" ,libxcomposite)
538 ("libxcursor" ,libxcursor)
539 ("libxdamage" ,libxdamage)
540 ("libxi" ,libxi)
541 ("libxinerama" ,libxinerama)
542 ("libxrandr" ,libxrandr)))
c4c4cc05 543 (native-inputs
1c8362a8 544 `(("perl" ,perl)
dfbce50c 545 ("gettext" ,gnu-gettext)
426adbe8 546 ("glib" ,glib "bin")
9d297fae 547 ("gobject-introspection" ,gobject-introspection)
1c8362a8
AE
548 ("pkg-config" ,pkg-config)
549 ("python-wrapper" ,python-wrapper)))
cf2135ff 550 (arguments
b19d6805 551 `(#:configure-flags
6b1f2388
SB
552 (list "--with-xinput=yes"
553 (string-append "--with-html-dir="
554 (assoc-ref %outputs "doc")
555 "/share/gtk-doc/html"))
9d297fae 556 #:phases
d4bf49b1
EB
557 (alist-cons-before
558 'configure 'disable-tests
559 (lambda _
560 ;; FIXME: re-enable tests requiring an X server
561 (substitute* "gtk/Makefile.in"
562 (("SUBDIRS = theme-bits . tests") "SUBDIRS = theme-bits .")))
2a6afac9
RW
563 %standard-phases)))
564 (native-search-paths
565 (list (search-path-specification
566 (variable "GUIX_GTK2_PATH")
567 (files '("lib/gtk-2.0")))))
0327ced2 568 (synopsis "Cross-platform toolkit for creating graphical user interfaces")
cf2135ff
AE
569 (description
570 "GTK+, or the GIMP Toolkit, is a multi-platform toolkit for creating
35b9e423 571graphical user interfaces. Offering a complete set of widgets, GTK+ is
cf2135ff
AE
572suitable for projects ranging from small one-off tools to complete
573application suites.")
574 (license license:lgpl2.0+)
575 (home-page "http://www.gtk.org/")))
8e70e6d2 576
8b79a547
AE
577(define-public gtk+
578 (package (inherit gtk+-2)
b38e45d8 579 (name "gtk+")
9fe2e17d 580 (version "3.18.2")
8b79a547
AE
581 (source (origin
582 (method url-fetch)
b38e45d8
EB
583 (uri (string-append "mirror://gnome/sources/" name "/"
584 (version-major+minor version) "/"
585 name "-" version ".tar.xz"))
8b79a547
AE
586 (sha256
587 (base32
4828ff91
RW
588 "0lp1hn0qydxx03bianzzr0a4maqzsvylrkzr7c3p0050qihwbgjx"))
589 (patches (list (search-patch "gtk3-respect-GUIX_GTK3_PATH.patch")))))
0e112540 590 (propagated-inputs
8b79a547 591 `(("at-spi2-atk" ,at-spi2-atk)
0e112540
AE
592 ("atk" ,atk)
593 ("gdk-pixbuf" ,gdk-pixbuf)
31b254a3 594 ("libepoxy" ,libepoxy)
a572dca8 595 ("libxcursor" ,libxcursor)
8b79a547
AE
596 ("libxi" ,libxi)
597 ("libxinerama" ,libxinerama)
9e5c0927 598 ("libxdamage" ,libxdamage)
0e112540
AE
599 ("pango" ,pango)))
600 (inputs
52b8beb1
SB
601 `(("librsvg" ,librsvg) ;for gtk-encode-symbolic-svg
602 ("libxml2" ,libxml2)
1cb16f1e
SB
603 ;; XXX: colord depends on mozjs (through polkit), which fails on
604 ;; on non-intel systems now.
605 ;;("colord" ,colord)
a572dca8 606 ("cups" ,cups) ;for printing support
a2651b54
SB
607 ;; XXX: rest depends on p11-kit, which fails on mips64el now.
608 ;;("rest" ,rest)
a572dca8 609 ("json-glib" ,json-glib)))
c4c4cc05 610 (native-inputs
141aed80 611 `(("perl" ,perl)
426adbe8 612 ("glib" ,glib "bin")
31b254a3 613 ("gettext" ,gnu-gettext)
8b79a547 614 ("pkg-config" ,pkg-config)
141aed80 615 ("gobject-introspection" ,gobject-introspection)
8b79a547 616 ("python-wrapper" ,python-wrapper)
97f94f5e 617 ("xorg-server" ,xorg-server)))
8b79a547 618 (arguments
260b07a7
LC
619 `(;; 47 MiB goes to "out" (24 of which is locale data!), and 26 MiB goes
620 ;; to "doc".
621 #:configure-flags (list (string-append "--with-html-dir="
622 (assoc-ref %outputs "doc")
623 "/share/gtk-doc/html"))
624 #:phases
31b254a3
AW
625 (alist-cons-before
626 'configure 'pre-configure
627 (lambda _
628 ;; Disable most tests, failing in the chroot with the message:
629 ;; D-Bus library appears to be incorrectly set up; failed to read
630 ;; machine uuid: Failed to open "/etc/machine-id": No such file or
631 ;; directory.
632 ;; See the manual page for dbus-uuidgen to correct this issue.
633 (substitute* "testsuite/Makefile.in"
634 (("SUBDIRS = gdk gtk a11y css reftests")
635 "SUBDIRS = gdk"))
31b254a3 636 #t)
52b8beb1
SB
637 (alist-cons-after
638 'install 'wrap-gtk-encode-symbolic-svg
639 ;; By using GdkPixbuf, gtk-encode-symbolic-svg needs to know
640 ;; librsvg's loaders.cache to handle SVG files.
641 (lambda* (#:key inputs outputs #:allow-other-keys)
642 (let* ((out (assoc-ref outputs "out"))
643 (prog (string-append out "/bin/gtk-encode-symbolic-svg"))
644 (librsvg (assoc-ref inputs "librsvg"))
645 (loaders.cache (find-files librsvg "^loaders\\.cache$")))
646 (wrap-program prog
647 `("GDK_PIXBUF_MODULE_FILE" = ,loaders.cache))))
4828ff91
RW
648 %standard-phases))))
649 (native-search-paths
650 (list (search-path-specification
651 (variable "GUIX_GTK3_PATH")
652 (files '("lib/gtk-3.0")))))))
5fda4784 653
8e70e6d2
LC
654;;;
655;;; Guile bindings.
656;;;
657
658(define-public guile-cairo
659 (package
660 (name "guile-cairo")
661 (version "1.4.1")
662 (source (origin
663 (method url-fetch)
664 (uri (string-append
665 "http://download.gna.org/guile-cairo/guile-cairo-"
666 version
667 ".tar.gz"))
668 (sha256
669 (base32
670 "1f5nd9n46n6cwfl1byjml02q3y2hgn7nkx98km1czgwarxl7ws3x"))))
671 (build-system gnu-build-system)
672 (arguments
673 '(#:phases (alist-cons-before
674 'configure 'set-module-directory
675 (lambda* (#:key outputs #:allow-other-keys)
676 ;; Install modules under $out/share/guile/site/2.0.
677 (let ((out (assoc-ref outputs "out")))
678 (substitute* "Makefile.in"
679 (("scmdir = ([[:graph:]]+).*" _ value)
680 (string-append "scmdir = " value "/2.0\n")))
681 (substitute* "cairo/Makefile.in"
682 (("moduledir = ([[:graph:]]+).*" _ value)
683 (string-append "moduledir = "
684 "$(prefix)/share/guile/site/2.0/cairo\n'")))))
685 (alist-cons-after
686 'install 'install-missing-file
687 (lambda* (#:key outputs #:allow-other-keys)
688 ;; By default 'vector-types.scm' is not installed, so do
689 ;; it here.
690 (let ((out (assoc-ref outputs "out")))
691 (copy-file "cairo/vector-types.scm"
692 (string-append out "/share/guile/site/2.0"
693 "/cairo/vector-types.scm"))))
694 %standard-phases))))
695 (inputs
696 `(("guile-lib" ,guile-lib)
697 ("expat" ,expat)
8e70e6d2 698 ("guile" ,guile-2.0)))
49710cea
LC
699 (propagated-inputs
700 ;; The .pc file refers to 'cairo'.
701 `(("cairo" ,cairo)))
c4c4cc05
JD
702 (native-inputs
703 `(("pkg-config" ,pkg-config)))
8e70e6d2
LC
704 (home-page "http://www.nongnu.org/guile-cairo/")
705 (synopsis "Cairo bindings for GNU Guile")
706 (description
707 "Guile-Cairo wraps the Cairo graphics library for Guile Scheme.
708Guile-Cairo is complete, wrapping almost all of the Cairo API. It is API
709stable, providing a firm base on which to do graphics work. Finally, and
710importantly, it is pleasant to use. You get a powerful and well-maintained
711graphics library with all of the benefits of Scheme: memory management,
712exceptions, macros, and a dynamic programming environment.")
713 (license license:lgpl3+)))
66663503 714
1a51fe27
LC
715(define-public guile-rsvg
716 (package
717 (name "guile-rsvg")
718 (version "2.18.1")
719 (source (origin
720 (method url-fetch)
721 (uri (string-append "http://wingolog.org/pub/guile-rsvg/"
722 name "-" version ".tar.gz"))
723 (sha256
724 (base32
725 "136f236iw3yrrz6pkkp1ma9c5mrs5icqha6pnawinqpk892r3jh7"))
726 (patches (list (search-patch "guile-rsvg-pkgconfig.patch")))
727 (modules '((guix build utils)))
728 (snippet
729 '(substitute* (find-files "." "Makefile\\.am")
730 (("/share/guile/site")
731 "/share/guile/site/2.0")))))
732 (build-system gnu-build-system)
733 (arguments
734 `(#:phases (modify-phases %standard-phases
735 (add-before 'configure 'bootstrap
736 (lambda _
737 (zero? (system* "autoreconf" "-vfi")))))))
738 (native-inputs `(("pkg-config" ,pkg-config)
739 ("autoconf" ,autoconf)
740 ("automake" ,automake)
741 ("libtool" ,libtool)
742 ("texinfo" ,texinfo)))
743 (inputs `(("guile" ,guile-2.0)
744 ("librsvg" ,librsvg)
745 ("guile-lib" ,guile-lib))) ;for (unit-test)
746 (propagated-inputs `(("guile-cairo" ,guile-cairo)))
747 (synopsis "Render SVG images using Cairo from Guile")
748 (description
749 "Guile-RSVG wraps the RSVG library for Guile, allowing you to render SVG
750images onto Cairo surfaces.")
751 (home-page "http://wingolog.org/projects/guile-rsvg/")
752 (license license:lgpl2.1+)))
7ca0dbc3 753
cdd383e9
LC
754(define-public guile-present
755 (package
756 (name "guile-present")
757 (version "0.3.0")
758 (source (origin
759 (method url-fetch)
760 (uri (string-append "http://wingolog.org/pub/guile-present/"
761 "guile-present-" version ".tar.gz"))
762 (sha256
763 (base32
764 "1qam447m05sxxv6x8dlzg7qnyfc4dh8apjw1idpfhpns671gfr6m"))
765 (patches (list (search-patch "guile-present-coding.patch")))
766 (modules '((guix build utils)))
767 (snippet
768 '(substitute* "Makefile.in"
769 (("godir = .*$")
770 "godir = $(moddir)\n")))))
771 (build-system gnu-build-system)
772 (arguments
773 '(#:phases (alist-cons-after
774 'install 'post-install
775 (lambda* (#:key inputs outputs #:allow-other-keys)
776 (let* ((out (assoc-ref outputs "out"))
777 (bin (string-append out "/bin"))
778 (guile (assoc-ref inputs "guile")))
779 (substitute* (find-files bin ".*")
780 (("guile")
781 (string-append guile "/bin/guile -L "
782 out "/share/guile/site/2.0 -C "
783 out "/share/guile/site/2.0 ")))))
784 %standard-phases)))
785 (native-inputs `(("pkg-config" ,pkg-config)))
786 (inputs `(("guile" ,guile-2.0)))
787 (propagated-inputs
788 ;; These are used by the (present …) modules.
789 `(("guile-lib" ,guile-lib)
790 ("guile-cairo" ,guile-cairo)
791 ("guile-rsvg" ,guile-rsvg)))
792 (home-page "http://wingolog.org/software/guile-present/")
793 (synopsis "Create SVG or PDF presentations in Guile")
794 (description
795 "Guile-Present defines a declarative vocabulary for presentations,
796together with tools to render presentation documents as SVG or PDF.
797Guile-Present can be used to make presentations programmatically, but also
798includes a tools to generate PDF presentations out of Org mode and Texinfo
799documents.")
800 (license license:lgpl3+)))
7ca0dbc3 801
66663503
LC
802;;;
803;;; C++ bindings.
804;;;
805
806(define-public cairomm
807 (package
808 (name "cairomm")
2079087c 809 (version "1.12.0")
66663503 810 (source (origin
2079087c
SB
811 (method url-fetch)
812 (uri (string-append "mirror://gnome/sources/cairomm/"
813 (version-major+minor version) "/"
814 name "-" version ".tar.xz"))
815 (sha256
816 (base32
817 "1rmgs6zjj2vaxh9hsa0944m23fdn1psycqh7bi984qd8jj1xljm5"))))
66663503
LC
818 (build-system gnu-build-system)
819 (arguments
820 ;; The examples lack -lcairo.
821 '(#:make-flags '("LDFLAGS=-lcairo")))
c4c4cc05 822 (native-inputs `(("pkg-config" ,pkg-config)))
66663503
LC
823 (propagated-inputs
824 `(("libsigc++" ,libsigc++)
825 ("freetype" ,freetype)
826 ("fontconfig" ,fontconfig)
827 ("cairo" ,cairo)))
828 (home-page "http://cairographics.org/")
829 (synopsis "C++ bindings to the Cairo 2D graphics library")
830 (description
831 "Cairomm provides a C++ programming interface to the Cairo 2D graphics
832library.")
833 (license license:lgpl2.0+)))
c5cc5006
LC
834
835(define-public pangomm
836 (package
837 (name "pangomm")
256da71f 838 (version "2.38.1")
c5cc5006
LC
839 (source (origin
840 (method url-fetch)
b38e45d8
EB
841 (uri (string-append "mirror://gnome/sources/" name "/"
842 (version-major+minor version) "/"
843 name "-" version ".tar.xz"))
c5cc5006
LC
844 (sha256
845 (base32
256da71f 846 "12xwjvqfxhqblcv7641k0l6r8n3qifnrx8w9571izn1nbd81iyzg"))))
c5cc5006 847 (build-system gnu-build-system)
c4c4cc05 848 (native-inputs `(("pkg-config" ,pkg-config)))
c5cc5006
LC
849 (propagated-inputs
850 `(("cairo" ,cairo)
851 ("cairomm" ,cairomm)
852 ("glibmm" ,glibmm)
853 ("pango" ,pango)))
854 (home-page "http://www.pango.org/")
855 (synopsis "C++ interface to the Pango text rendering library")
856 (description
857 "Pangomm provides a C++ programming interface to the Pango text rendering
858library.")
859 (license license:lgpl2.1+)))
860
861(define-public atkmm
862 (package
863 (name "atkmm")
5b003972 864 (version "2.24.2")
c5cc5006
LC
865 (source (origin
866 (method url-fetch)
b38e45d8
EB
867 (uri (string-append "mirror://gnome/sources/" name "/"
868 (version-major+minor version) "/"
869 name "-" version ".tar.xz"))
c5cc5006
LC
870 (sha256
871 (base32
5b003972 872 "1gaqwhviadsmy0fsr47686yglv1p4mpkamj0in127bz2b5bki5gz"))))
c5cc5006 873 (build-system gnu-build-system)
c4c4cc05 874 (native-inputs `(("pkg-config" ,pkg-config)))
c5cc5006
LC
875 (propagated-inputs
876 `(("glibmm" ,glibmm) ("atk" ,atk)))
877 (home-page "http://www.gtkmm.org")
878 (synopsis "C++ interface to the ATK accessibility library")
879 (description
880 "ATKmm provides a C++ programming interface to the ATK accessibility
881toolkit.")
882 (license license:lgpl2.1+)))
883
884(define-public gtkmm
885 (package
886 (name "gtkmm")
aa382d7e 887 (version "3.18.0")
c5cc5006
LC
888 (source (origin
889 (method url-fetch)
b38e45d8
EB
890 (uri (string-append "mirror://gnome/sources/" name "/"
891 (version-major+minor version) "/"
892 name "-" version ".tar.xz"))
c5cc5006
LC
893 (sha256
894 (base32
aa382d7e 895 "0sxq700invkjpksn790gbnl8px8751kvgwn39663jx7dv89s37w2"))))
c5cc5006 896 (build-system gnu-build-system)
ff5c33fe
LC
897 (native-inputs `(("pkg-config" ,pkg-config)
898 ("glib" ,glib "bin"))) ;for 'glib-compile-resources'
c5cc5006
LC
899 (propagated-inputs
900 `(("pangomm" ,pangomm)
901 ("cairomm" ,cairomm)
902 ("atkmm" ,atkmm)
903 ("gtk+" ,gtk+)
904 ("glibmm" ,glibmm)))
905 (home-page "http://gtkmm.org/")
906 (synopsis
907 "C++ interface to the GTK+ graphical user interface library")
908 (description
909 "gtkmm is the official C++ interface for the popular GUI library GTK+.
910Highlights include typesafe callbacks, and a comprehensive set of widgets that
911are easily extensible via inheritance. You can create user interfaces either
912in code or with the Glade User Interface designer, using libglademm. There's
913extensive documentation, including API reference and a tutorial.")
914 (license license:lgpl2.1+)))
9c086443
JD
915
916
917(define-public gtkmm-2
918 (package (inherit gtkmm)
b38e45d8 919 (name "gtkmm")
f8f63893 920 (version "2.24.4")
9c086443
JD
921 (source (origin
922 (method url-fetch)
b38e45d8
EB
923 (uri (string-append "mirror://gnome/sources/" name "/"
924 (version-major+minor version) "/"
925 name "-" version ".tar.xz"))
9c086443
JD
926 (sha256
927 (base32
f8f63893 928 "1vpmjqv0aqb1ds0xi6nigxnhlr0c74090xzi15b92amlzkrjyfj4"))))
3ad29c9e
SB
929 (arguments
930 '(#:configure-flags '("CPPFLAGS=-std=c++11"))) ; required by libsigc++
ff5c33fe 931 (native-inputs `(("pkg-config" ,pkg-config)))
9c086443
JD
932 (propagated-inputs
933 `(("pangomm" ,pangomm)
934 ("cairomm" ,cairomm)
935 ("atkmm" ,atkmm)
936 ("gtk+" ,gtk+-2)
937 ("glibmm" ,glibmm)))))
fbcfa730
EB
938
939(define-public python-pycairo
940 (package
941 (name "python-pycairo")
942 (version "1.10.0")
943 (source
944 (origin
945 (method url-fetch)
946 (uri (string-append "http://cairographics.org/releases/pycairo-"
947 version ".tar.bz2"))
948 (sha256
949 (base32
b837e658
SB
950 "1gjkf8x6hyx1skq3hhwcbvwifxvrf9qxis5vx8x5igmmgs70g94s"))
951 (patches (list (search-patch "pycairo-wscript.patch")))))
952 (build-system waf-build-system)
fbcfa730 953 (native-inputs
b837e658
SB
954 `(("pkg-config" ,pkg-config)
955 ("python-waf" ,python-waf)))
fbcfa730
EB
956 (propagated-inputs ;pycairo.pc references cairo
957 `(("cairo" ,cairo)))
958 (arguments
959 `(#:tests? #f
b837e658
SB
960 #:phases
961 (modify-phases %standard-phases
962 (add-before
963 'configure 'patch-waf
964 (lambda* (#:key inputs #:allow-other-keys)
965 ;; The bundled `waf' doesn't work with python-3.4.x.
966 (copy-file (assoc-ref %build-inputs "python-waf") "./waf"))))))
fbcfa730
EB
967 (home-page "http://cairographics.org/pycairo/")
968 (synopsis "Python bindings for cairo")
969 (description
970 "Pycairo is a set of Python bindings for the Cairo graphics library.")
7ec42f1d
LC
971 (license license:lgpl3+)
972 (properties `((python2-variant . ,(delay python2-pycairo))))))
fbcfa730 973
7ca0dbc3 974(define-public python2-pycairo
7ec42f1d 975 (package (inherit (strip-python2-variant python-pycairo))
7ca0dbc3 976 (name "python2-pycairo")
fbcfa730
EB
977 (version "1.10.0")
978 (source
979 (origin
980 (method url-fetch)
981 (uri (string-append "http://cairographics.org/releases/py2cairo-"
982 version ".tar.bz2"))
983 (sha256
984 (base32
985 "0cblk919wh6w0pgb45zf48xwxykfif16qk264yga7h9fdkq3j16k"))))
986 (arguments
987 `(#:python ,python-2
b837e658
SB
988 ,@(substitute-keyword-arguments (package-arguments python-pycairo)
989 ((#:phases phases)
990 `(alist-delete 'patch-waf ,phases))
991 ((#:native-inputs native-inputs)
992 `(alist-delete "python-waf" ,native-inputs)))))
fbcfa730 993 ;; Dual-licensed under LGPL 2.1 or Mozilla Public License 1.1
0d6a8339 994 (license (list license:lgpl2.1 license:mpl1.1))))
fbcfa730
EB
995
996(define-public python2-pygtk
997 (package
998 (name "python2-pygtk")
999 (version "2.24.0")
1000 (source
1001 (origin
1002 (method url-fetch)
1003 (uri (string-append "http://ftp.gnome.org/pub/GNOME/sources"
1004 "/pygtk/" (version-major+minor version)
1005 "/pygtk-" version ".tar.bz2"))
1006 (sha256
1007 (base32
1008 "04k942gn8vl95kwf0qskkv6npclfm31d78ljkrkgyqxxcni1w76d"))))
1009 (build-system gnu-build-system)
594e7b47
LC
1010 (outputs '("out"
1011 "doc")) ;13 MiB of gtk-doc HTML
fbcfa730
EB
1012 (native-inputs
1013 `(("pkg-config" ,pkg-config)))
1014 (inputs
1015 `(("python" ,python-2)
1016 ("glib" ,glib)))
1017 (propagated-inputs
7ca0dbc3 1018 `(("python-pycairo" ,python2-pycairo) ;loaded at runtime
fbcfa730
EB
1019 ("python-pygobject" ,python2-pygobject-2) ;referenced in pc file
1020 ("gtk+" ,gtk+-2)))
1021 (arguments
1022 `(#:tests? #f
ae115bc7 1023 #:phases (modify-phases %standard-phases
594e7b47
LC
1024 (add-before 'configure 'set-gtk-doc-directory
1025 (lambda* (#:key outputs #:allow-other-keys)
1026 ;; Install documentation to "doc".
1027 (let ((doc (assoc-ref outputs "doc")))
1028 (substitute* "docs/Makefile.in"
1029 (("TARGET_DIR = \\$\\(datadir\\)")
1030 (string-append "TARGET_DIR = " doc))))))
ae115bc7
LC
1031 (add-after 'configure 'fix-codegen
1032 (lambda* (#:key inputs #:allow-other-keys)
1033 (substitute* "pygtk-codegen-2.0"
1034 (("^prefix=.*$")
1035 (string-append
1036 "prefix="
1037 (assoc-ref inputs "python-pygobject") "\n")))))
1038 (add-after 'install 'install-pth
1039 (lambda* (#:key inputs outputs #:allow-other-keys)
1040 ;; pygtk's modules are stored in a subdirectory of
1041 ;; python's site-packages directory. Add a .pth file so
1042 ;; that python will add that subdirectory to its module
1043 ;; search path.
1044 (let* ((out (assoc-ref outputs "out"))
1045 (site (string-append out "/lib/python"
1046 ,(version-major+minor
1047 (package-version python-2))
1048 "/site-packages")))
1049 (call-with-output-file (string-append site "/pygtk.pth")
1050 (lambda (port)
1051 (format port "gtk-2.0~%")))))))))
fbcfa730
EB
1052 (home-page "http://www.pygtk.org/")
1053 (synopsis "Python bindings for GTK+")
1054 (description
1055 "PyGTK allows you to write full featured GTK programs in Python. It is
1056targetted at GTK 2.x, and can be used in conjunction with gnome-python to
1057write GNOME applications.")
1058 (license license:lgpl2.1+)))
136770c9
PW
1059
1060(define-public girara
1061 (package
1062 (name "girara")
90ab5dd2 1063 (version "0.2.4")
136770c9
PW
1064 (source (origin
1065 (method url-fetch)
1066 (uri
1067 (string-append "https://pwmt.org/projects/girara/download/girara-"
1068 version ".tar.gz"))
1069 (sha256
1070 (base32
90ab5dd2 1071 "0pnfdsg435b5vc4x8l9pgm77aj7ram1q0bzrp9g4a3bh1r64xq1f"))))
136770c9
PW
1072 (native-inputs `(("pkg-config" ,pkg-config)
1073 ("gettext" ,gnu-gettext)))
1074 (inputs `(("gtk+" ,gtk+)
1075 ("check" ,check)))
1076 (arguments
1077 `(#:make-flags
1078 `(,(string-append "PREFIX=" (assoc-ref %outputs "out"))
1079 "COLOR=0" "CC=gcc")
1080 #:test-target "test"
1081 #:tests? #f ; Tests fail with "Gtk cannot open display:"
1082 #:phases
1083 (alist-delete 'configure %standard-phases)))
1084 (build-system gnu-build-system)
1085 (home-page "https://pwmt.org/projects/girara/")
1086 (synopsis "Library for minimalistic gtk+3 user interfaces")
1087 (description "Girara is a library that implements a user interface that
1088focuses on simplicity and minimalism. Currently based on GTK+, a
1089cross-platform widget toolkit, it provides an interface that focuses on three
1090main components: a so-called view widget that represents the actual
1091application, an input bar that is used to execute commands of the
1092application and the status bar which provides the user with current
1093information.")
1094 (license license:zlib)))
3bc45449
AW
1095
1096(define-public gtk-doc
1097 (package
1098 (name "gtk-doc")
1099 (version "1.24")
1100 (source (origin
1101 (method url-fetch)
1102 (uri (string-append "mirror://gnome/sources/" name "/"
1103 (version-major+minor version) "/"
1104 name "-" version ".tar.xz"))
1105 (sha256
1106 (base32
1107 "12xmmcnq4138dlbhmqa45wqza8dky4lf856sp80h6xjwl2g7a85l"))))
1108 (build-system gnu-build-system)
1109 (arguments
1110 `(#:configure-flags
1111 (list (string-append "--with-xml-catalog="
1112 (assoc-ref %build-inputs "docbook-xml")
1113 "/xml/dtd/docbook/catalog.xml"))))
1114 (native-inputs
1115 `(("pkg-config" ,pkg-config)
1116 ("itstool" ,itstool)
1117 ("libxml" ,libxml2)
1118 ("gettext" ,gnu-gettext)
1119 ("bc" ,bc)))
1120 (inputs
1121 `(("perl" ,perl)
1122 ("python" ,python)
1123 ("xsltproc" ,libxslt)
1124 ("dblatex" ,dblatex)
1125 ("docbook-xml" ,docbook-xml-4.3)
1126 ("docbook-xsl" ,docbook-xsl)
1127 ("source-highlight" ,source-highlight)
1128 ("glib" ,glib)))
1129 (home-page "http://www.gtk.org/gtk-doc/")
1130 (synopsis "Documentation generator from C source code")
1131 (description
a124bbd2 1132 "GTK-Doc generates API documentation from comments added to C code. It is
3bc45449
AW
1133typically used to document the public API of GTK+ and GNOME libraries, but it
1134can also be used to document application code.")
1135 (license license:gpl2+)))
9ba5198c
FH
1136
1137(define-public gtk-engines
1138 (package
1139 (name "gtk-engines")
1140 (version "2.20.2")
1141 (source (origin
1142 (method url-fetch)
1143 (uri (string-append "mirror://gnome/sources/" name "/"
1144 (version-major+minor version) "/"
1145 name "-" version ".tar.bz2"))
1146 (sha256
1147 (base32
1148 "1db65pb0j0mijmswrvpgkdabilqd23x22d95hp5kwxvcramq1dhm"))))
1149 (build-system gnu-build-system)
1150 (arguments
1151 `(#:configure-flags
1152 `("--enable-animation")))
1153 (native-inputs
1154 `(("pkg-config" ,pkg-config)
1155 ("intltool" ,intltool)))
1156 (propagated-inputs
1157 `(("gtk+" ,gtk+-2))) ; required by gtk-engines-2.pc
1158 (home-page "http://live.gnome.org/GnomeArt")
1159 (synopsis "Theming engines for GTK+ 2.x")
1160 (description
1161 "This package contains the standard GTK+ 2.x theming engines including
1162Clearlooks, Crux, High Contrast, Industrial, LighthouseBlue, Metal, Mist,
1163Redmond95 and ThinIce.")
1164 (license (list license:gpl2+ license:lgpl2.1+))))
b7807bb2
FH
1165
1166(define-public murrine
1167 (package
1168 (name "murrine")
1169 (version "0.98.2")
1170 (source (origin
1171 (method url-fetch)
1172 (uri (string-append "mirror://gnome/sources/" name "/"
1173 (version-major+minor version) "/"
1174 name "-" version ".tar.xz"))
1175 (sha256
1176 (base32
1177 "129cs5bqw23i76h3nmc29c9mqkm9460iwc8vkl7hs4xr07h8mip9"))))
1178 (build-system gnu-build-system)
1179 (arguments
1180 `(#:configure-flags
1181 `("--enable-animation"
1182 "--enable-animationrtl")))
1183 (native-inputs
1184 `(("pkg-config" ,pkg-config)
1185 ("intltool" ,intltool)))
1186 (propagated-inputs
1187 `(("gtk+" ,gtk+-2)))
1188 (home-page "http://live.gnome.org/GnomeArt")
1189 (synopsis "Cairo-based theming engine for GTK+ 2.x")
1190 (description
1191 "Murrine is a cairo-based GTK+ theming engine. It is named after the
1192glass artworks done by Venicians glass blowers.")
1193 (license license:gpl2+)))