gnu: Add ocrodjvu.
[jackhill/guix/guix.git] / gnu / packages / glib.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016, 2019 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
5 ;;; Copyright © 2014, 2015, 2016, 2017, 2018 Mark H Weaver <mhw@netris.org>
6 ;;; Copyright © 2016, 2020 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
8 ;;; Copyright © 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2017 Petter <petter@mykolab.ch>
10 ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
12 ;;; Copyright © 2019 Maxim Cournoyer <maxim.cournoyer@gmail.com>
13 ;;; Copyright © 2019 Giacomo Leidi <goodoldpaul@autistici.org>
14 ;;; Copyright © 2019, 2020 Marius Bakke <mbakke@fastmail.com>
15 ;;; Copyright © 2020 Nicolò Balzarotti <nicolo@nixo.xyz>
16 ;;; Copyright © 2020 Arthur Margerit <ruhtra.mar@gmail.com>
17 ;;;
18 ;;; This file is part of GNU Guix.
19 ;;;
20 ;;; GNU Guix is free software; you can redistribute it and/or modify it
21 ;;; under the terms of the GNU General Public License as published by
22 ;;; the Free Software Foundation; either version 3 of the License, or (at
23 ;;; your option) any later version.
24 ;;;
25 ;;; GNU Guix is distributed in the hope that it will be useful, but
26 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
27 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28 ;;; GNU General Public License for more details.
29 ;;;
30 ;;; You should have received a copy of the GNU General Public License
31 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
32
33 (define-module (gnu packages glib)
34 #:use-module (gnu packages)
35 #:use-module (gnu packages backup)
36 #:use-module (gnu packages base)
37 #:use-module (gnu packages bison)
38 #:use-module (gnu packages check)
39 #:use-module (gnu packages compression)
40 #:use-module (gnu packages docbook)
41 #:use-module (gnu packages documentation)
42 #:use-module (gnu packages enlightenment)
43 #:use-module (gnu packages file)
44 #:use-module (gnu packages flex)
45 #:use-module (gnu packages gettext)
46 #:use-module (gnu packages gnome)
47 #:use-module (gnu packages gperf)
48 #:use-module (gnu packages gtk)
49 #:use-module (gnu packages libffi)
50 #:use-module (gnu packages linux)
51 #:use-module (gnu packages m4)
52 #:use-module (gnu packages nettle)
53 #:use-module (gnu packages pcre)
54 #:use-module (gnu packages package-management)
55 #:use-module (gnu packages perl)
56 #:use-module (gnu packages perl-check)
57 #:use-module (gnu packages popt)
58 #:use-module (gnu packages pkg-config)
59 #:use-module (gnu packages python)
60 #:use-module (gnu packages python-xyz)
61 #:use-module (gnu packages selinux)
62 #:use-module (gnu packages web)
63 #:use-module (gnu packages xml)
64 #:use-module (gnu packages xorg)
65 #:use-module (guix build-system gnu)
66 #:use-module (guix build-system cmake)
67 #:use-module (guix build-system meson)
68 #:use-module (guix build-system perl)
69 #:use-module (guix build-system python)
70 #:use-module (guix download)
71 #:use-module ((guix licenses) #:prefix license:)
72 #:use-module (guix packages)
73 #:use-module (guix utils)
74 #:use-module ((srfi srfi-1) #:hide (zip))
75
76 ;; Export variables up-front to allow circular dependency with the 'xorg'
77 ;; module.
78 #:export (dbus
79 glib
80 gobject-introspection
81 dbus-glib
82 intltool
83 itstool
84 libsigc++
85 glibmm
86 telepathy-glib
87 perl-net-dbus
88 perl-net-dbus-glib))
89
90 (define dbus
91 (package
92 (name "dbus")
93 (version "1.12.16")
94 (replacement dbus/fixed)
95 (source (origin
96 (method url-fetch)
97 (uri (string-append
98 "https://dbus.freedesktop.org/releases/dbus/dbus-"
99 version ".tar.gz"))
100 (sha256
101 (base32
102 "107ckxaff1cv4q6kmfdi2fb1nlsv03312a7kf6lb4biglhpjv8jl"))
103 (patches (search-patches "dbus-helper-search-path.patch"))))
104 (build-system gnu-build-system)
105 (arguments
106 '(#:configure-flags
107 (list
108 ;; Install the system bus socket under /var.
109 "--localstatedir=/var"
110
111 ;; Install the session bus socket under /tmp.
112 "--with-session-socket-dir=/tmp"
113
114 ;; Build shared libraries only.
115 "--disable-static"
116
117 ;; Use /etc/dbus-1 for system-wide config.
118 ;; Look for configuration file under
119 ;; /etc/dbus-1. This is notably required by
120 ;; 'dbus-daemon-launch-helper', which looks for
121 ;; the 'system.conf' file in that place,
122 ;; regardless of what '--config-file' was
123 ;; passed to 'dbus-daemon' on the command line;
124 ;; see <https://bugs.freedesktop.org/show_bug.cgi?id=92458>.
125 "--sysconfdir=/etc")
126 #:phases
127 (modify-phases %standard-phases
128 (replace 'install
129 (lambda _
130 ;; Don't try to create /var and /etc.
131 (invoke "make"
132 "localstatedir=/tmp/dummy"
133 "sysconfdir=/tmp/dummy"
134 "install"))))))
135 (native-inputs
136 `(("pkg-config" ,pkg-config)
137 ;; Dependencies to generate the doc.
138 ("docbook-xml" ,docbook-xml-4.4)
139 ("docbook-xsl" ,docbook-xsl)
140 ("doxygen" ,doxygen)
141 ("xmlto" ,xmlto)
142 ("libxml2" ,libxml2) ;for XML_CATALOG_FILES
143 ("libxslt" ,libxslt)
144 ("yelp-tools" ,yelp-tools)))
145 (inputs
146 `(("expat" ,expat)
147 ;; Add a dependency on libx11 so that 'dbus-launch' has support for
148 ;; '--autolaunch'.
149 ("libx11" ,libx11)))
150 (outputs '("out" "doc")) ;22 MiB of HTML doc
151 (home-page "https://www.freedesktop.org/wiki/Software/dbus/")
152 (synopsis "Message bus for inter-process communication (IPC)")
153 (description
154 "D-Bus is a message bus system, a simple way for applications to
155 talk to one another. In addition to interprocess communication, D-Bus
156 helps coordinate process lifecycle; it makes it simple and reliable to
157 code a \"single instance\" application or daemon, and to launch
158 applications and daemons on demand when their services are needed.
159
160 D-Bus supplies both a system daemon (for events such as \"new hardware
161 device added\" or \"printer queue changed\") and a
162 per-user-login-session daemon (for general IPC needs among user
163 applications). Also, the message bus is built on top of a general
164 one-to-one message passing framework, which can be used by any two apps
165 to communicate directly (without going through the message bus
166 daemon). Currently the communicating applications are on one computer,
167 or through unencrypted TCP/IP suitable for use behind a firewall with
168 shared NFS home directories.")
169 (license license:gpl2+))) ; or Academic Free License 2.1
170
171 ;; Replacement package to fix CVE-2020-12049.
172 (define dbus/fixed
173 (package
174 (inherit dbus)
175 (source (origin
176 (inherit (package-source dbus))
177 (patches (append (search-patches "dbus-CVE-2020-12049.patch")
178 (origin-patches (package-source dbus))))))))
179
180 (define glib
181 (package
182 (name "glib")
183 (version "2.62.6")
184 (replacement glib-with-gio-patch)
185 (source (origin
186 (method url-fetch)
187 (uri (string-append "mirror://gnome/sources/"
188 name "/" (string-take version 4) "/"
189 name "-" version ".tar.xz"))
190 (sha256
191 (base32
192 "174bsmbmcvaw69ff9g60q5sx0fn23rkhqcwqz17h5s7sprps4kqh"))
193 (patches (search-patches "glib-tests-timer.patch"))
194 (modules '((guix build utils)))
195 (snippet
196 '(begin
197 (substitute* "tests/spawn-test.c"
198 (("/bin/sh") "sh"))
199 #t))))
200 (build-system meson-build-system)
201 (outputs '("out" ; everything
202 "bin")) ; glib-mkenums, gtester, etc.; depends on Python
203 (propagated-inputs
204 `(("pcre" ,pcre) ; in the Requires.private field of glib-2.0.pc
205 ("libffi" ,libffi) ; in the Requires.private field of gobject-2.0.pc
206 ;; These are in the Requires.private field of gio-2.0.pc
207 ("util-linux" ,util-linux "lib") ;for libmount
208 ("libselinux" ,libselinux)
209 ("zlib" ,zlib)))
210 (native-inputs
211 `(("gettext" ,gettext-minimal)
212 ("m4" ,m4) ; for installing m4 macros
213 ("dbus" ,dbus) ; for GDBus tests
214 ("pkg-config" ,pkg-config)
215 ("python" ,python-wrapper)
216 ("perl" ,perl) ; needed by GIO tests
217 ("tzdata" ,tzdata-for-tests))) ; for tests/gdatetime.c
218 (arguments
219 `(#:disallowed-references (,tzdata-for-tests)
220 #:phases
221 (modify-phases %standard-phases
222 (add-after 'unpack 'patch-dbus-launch-path
223 (lambda* (#:key inputs #:allow-other-keys)
224 (let ((dbus (assoc-ref inputs "dbus")))
225 (substitute* "gio/gdbusaddress.c"
226 (("command_line = g_strdup_printf \\(\"dbus-launch")
227 (string-append "command_line = g_strdup_printf (\""
228 dbus "/bin/dbus-launch")))
229 #t)))
230 (add-after 'unpack 'patch-gio-launch-desktop
231 (lambda* (#:key outputs #:allow-other-keys)
232 (let ((out (assoc-ref outputs "out")))
233 ;; See also <https://gitlab.gnome.org/GNOME/glib/issues/1633>
234 ;; for another future fix.
235 (substitute* "gio/gdesktopappinfo.c"
236 (("gio-launch-desktop")
237 (string-append out "/libexec/gio-launch-desktop")))
238 #t)))
239 (add-before 'build 'pre-build
240 (lambda* (#:key inputs outputs #:allow-other-keys)
241 ;; For tests/gdatetime.c.
242 (setenv "TZDIR"
243 (string-append (assoc-ref inputs "tzdata")
244 "/share/zoneinfo"))
245
246 ;; Some tests want write access there.
247 (setenv "HOME" (getcwd))
248 (setenv "XDG_CACHE_HOME" (getcwd))
249 #t))
250 (add-after 'unpack 'disable-failing-tests
251 (lambda _
252 (let ((disable
253 (lambda (test-file test-paths)
254 (define pattern+procs
255 (map (lambda (test-path)
256 (cons
257 ;; XXX: only works for single line statements.
258 (format #f "g_test_add_func.*\"~a\".*" test-path)
259 (const "")))
260 test-paths))
261 (substitute test-file pattern+procs)))
262 (failing-tests
263 '(("glib/tests/thread.c"
264 (;; prlimit(2) returns ENOSYS on Linux 2.6.32-5-xen-amd64
265 ;; as found on hydra.gnu.org, and strace(1) doesn't
266 ;; recognize it.
267 "/thread/thread4"))
268
269 ;; This tries to find programs in FHS directories.
270 ("glib/tests/utils.c"
271 ("/utils/find-program"))
272
273 ;; This fails because "glib/tests/echo-script" cannot be
274 ;; found.
275 ("glib/tests/spawn-singlethread.c"
276 ("/gthread/spawn-script"))
277
278 ("glib/tests/timer.c"
279 (;; fails if compiler optimizations are enabled, which they
280 ;; are by default.
281 "/timer/stop"))
282
283 ("gio/tests/gapplication.c"
284 (;; XXX: proven to be unreliable. See:
285 ;; <https://bugs.debian.org/756273>
286 ;; <http://bugs.gnu.org/18445>
287 "/gapplication/quit"
288
289 ;; XXX: fails randomly for unknown reason. See:
290 ;; <https://lists.gnu.org/archive/html/guix-devel/2016-04/msg00215.html>
291 "/gapplication/local-actions"))
292
293 ("gio/tests/contenttype.c"
294 (;; XXX: requires shared-mime-info.
295 "/contenttype/guess"
296 "/contenttype/guess_svg_from_data"
297 "/contenttype/subtype"
298 "/contenttype/list"
299 "/contenttype/icon"
300 "/contenttype/symbolic-icon"
301 "/contenttype/tree"))
302
303 ("gio/tests/appinfo.c"
304 (;; XXX: requires update-desktop-database.
305 "/appinfo/associations"))
306
307 ("gio/tests/desktop-app-info.c"
308 (;; XXX: requires update-desktop-database.
309 "/desktop-app-info/delete"
310 "/desktop-app-info/default"
311 "/desktop-app-info/fallback"
312 "/desktop-app-info/lastused"
313 "/desktop-app-info/search"))
314
315 ("gio/tests/gdbus-peer.c"
316 (;; Requires /etc/machine-id.
317 "/gdbus/codegen-peer-to-peer"))
318
319 ("gio/tests/gdbus-address-get-session.c"
320 (;; Requires /etc/machine-id.
321 "/gdbus/x11-autolaunch"))
322
323 ("gio/tests/gsocketclient-slow.c"
324 (;; These tests tries to resolve "localhost", and fails.
325 "/socket-client/happy-eyeballs/slow"
326 "/socket-client/happy-eyeballs/cancellation/delayed"))
327
328 )))
329 (for-each (lambda (x) (apply disable x)) failing-tests)
330 #t)))
331 (replace 'check
332 (lambda _
333 (setenv "MESON_TESTTHREADS"
334 (number->string (parallel-job-count)))
335 ;; Do not run tests marked as "flaky".
336 (invoke "meson" "test" "--no-suite" "flaky")))
337 ;; TODO: meson does not permit the bindir to be outside of prefix.
338 ;; See https://github.com/mesonbuild/meson/issues/2561
339 ;; We can remove this once meson is patched.
340 (add-after 'install 'move-executables
341 (lambda* (#:key outputs #:allow-other-keys)
342 (let ((out (assoc-ref outputs "out"))
343 (bin (assoc-ref outputs "bin")))
344 (mkdir-p bin)
345 (rename-file (string-append out "/bin")
346 (string-append bin "/bin"))
347 ;; This one is an implementation detail of glib.
348 ;; It is wrong that that's in "/bin" in the first place,
349 ;; but that's what upstream is doing right now.
350 ;; See <https://gitlab.gnome.org/GNOME/glib/issues/1633>.
351 (mkdir (string-append out "/libexec"))
352 (rename-file (string-append bin "/bin/gio-launch-desktop")
353 (string-append out "/libexec/gio-launch-desktop"))
354 ;; Do not refer to "bindir", which points to "${prefix}/bin".
355 ;; We don't patch "bindir" to point to "$bin/bin", because that
356 ;; would create a reference cycle between the "out" and "bin"
357 ;; outputs.
358 (substitute* (list (string-append out "/lib/pkgconfig/gio-2.0.pc")
359 (string-append out "/lib/pkgconfig/glib-2.0.pc"))
360 (("bindir=\\$\\{prefix\\}/bin") "")
361 (("=\\$\\{bindir\\}/") "="))
362 #t))))))
363 ;; TODO: see above for explanation.
364 ;; #:configure-flags (list (string-append "--bindir="
365 ;; (assoc-ref %outputs "bin")
366 ;; "/bin"))
367
368 (native-search-paths
369 ;; This variable is not really "owned" by GLib, but several related
370 ;; packages refer to it: gobject-introspection's tools use it as a search
371 ;; path for .gir files, and it's also a search path for schemas produced
372 ;; by 'glib-compile-schemas'.
373 (list (search-path-specification
374 (variable "XDG_DATA_DIRS")
375 (files '("share")))
376 ;; To load extra gio modules from glib-networking, etc.
377 (search-path-specification
378 (variable "GIO_EXTRA_MODULES")
379 (files '("lib/gio/modules")))))
380 (search-paths native-search-paths)
381 (properties '((hidden? . #t)))
382
383 (synopsis "Thread-safe general utility library; basis of GTK+ and GNOME")
384 (description
385 "GLib provides data structure handling for C, portability wrappers,
386 and interfaces for such runtime functionality as an event loop, threads,
387 dynamic loading, and an object system.")
388 (home-page "https://developer.gnome.org/glib/")
389 (license license:lgpl2.1+)))
390
391 (define glib-with-gio-patch
392 ;; GLib with a fix for <https://bugs.gnu.org/35594>.
393 ;; TODO: Fold into 'glib' above in the next rebuild cycle.
394 (package
395 (inherit glib)
396 (source (origin
397 (inherit (package-source glib))
398 (patches (cons (search-patch "glib-appinfo-watch.patch")
399 (origin-patches (package-source glib))))))))
400
401 (define-public glib-with-documentation
402 ;; glib's doc must be built in a separate package since it requires gtk-doc,
403 ;; which in turn depends on glib.
404 (package/inherit glib
405 (properties (alist-delete 'hidden? (package-properties glib)))
406 (outputs (cons "doc" (package-outputs glib))) ; 20 MiB of GTK-Doc reference
407 (native-inputs
408 `(("gtk-doc" ,gtk-doc) ; for the doc
409 ("docbook-xml" ,docbook-xml)
410 ("libxml2" ,libxml2)
411 ,@(package-native-inputs glib)))
412 (arguments
413 (substitute-keyword-arguments (package-arguments glib)
414 ((#:configure-flags flags ''())
415 `(cons "-Dgtk_doc=true" ,flags))
416 ((#:phases phases)
417 `(modify-phases ,phases
418 (add-after 'install 'move-doc
419 (lambda* (#:key outputs #:allow-other-keys)
420 (let ((out (assoc-ref outputs "out"))
421 (doc (assoc-ref outputs "doc"))
422 (html (string-append "/share/gtk-doc")))
423 (copy-recursively (string-append out html)
424 (string-append doc html))
425 (delete-file-recursively (string-append out html))
426 #t)))))))))
427
428 (define gobject-introspection
429 (package
430 (name "gobject-introspection")
431 (version "1.62.0")
432 (source (origin
433 (method url-fetch)
434 (uri (string-append "mirror://gnome/sources/"
435 "gobject-introspection/" (version-major+minor version)
436 "/gobject-introspection-" version ".tar.xz"))
437 (sha256
438 (base32 "18lhglg9v6y83lhqzyifc1z0wrlawzrhzzxx0a3h1g7xaz97xvmi"))
439 (patches (search-patches
440 "gobject-introspection-cc.patch"
441 "gobject-introspection-girepository.patch"
442 "gobject-introspection-absolute-shlib-path.patch"))))
443 (build-system meson-build-system)
444 (arguments
445 `(#:phases
446 (modify-phases %standard-phases
447 (add-after 'unpack 'do-not-use-/usr/bin/env
448 (lambda _
449 (substitute* "tools/g-ir-tool-template.in"
450 (("#!@PYTHON_CMD@")
451 (string-append "#!" (which "python3"))))
452 #t)))))
453 (inputs
454 `(("bison" ,bison)
455 ("flex" ,flex)
456 ("glib" ,glib)
457 ("python" ,python-wrapper)
458 ("zlib" ,zlib)))
459 (native-inputs
460 `(("glib" ,glib "bin")
461 ("pkg-config" ,pkg-config)))
462 (propagated-inputs
463 `(;; In practice, GIR users will need libffi when using
464 ;; gobject-introspection.
465 ("libffi" ,libffi)))
466 (native-search-paths
467 (list (search-path-specification
468 (variable "GI_TYPELIB_PATH")
469 (files '("lib/girepository-1.0")))))
470 (search-paths native-search-paths)
471 (home-page "https://wiki.gnome.org/GObjectIntrospection")
472 (synopsis "Generate interface introspection data for GObject libraries")
473 (description
474 "GObject introspection is a middleware layer between C libraries (using
475 GObject) and language bindings. The C library can be scanned at compile time
476 and generate a metadata file, in addition to the actual native C library. Then
477 at runtime, language bindings can read this metadata and automatically provide
478 bindings to call into the C library.")
479 ; Some bits are distributed under the LGPL2+, others under the GPL2+
480 (license license:gpl2+)))
481
482 (define intltool
483 (package
484 (name "intltool")
485 (version "0.51.0")
486 (source (origin
487 (method url-fetch)
488 (uri (string-append "https://launchpad.net/intltool/trunk/"
489 version "/+download/intltool-"
490 version ".tar.gz"))
491 (patches (search-patches "intltool-perl-compatibility.patch"))
492 (sha256
493 (base32
494 "1karx4sb7bnm2j67q0q74hspkfn6lqprpy5r99vkn5bb36a4viv7"))))
495 (build-system gnu-build-system)
496 (inputs
497 `(("file" ,file)))
498 (propagated-inputs
499 `(;; Propagate gettext because users expect it to be there, and so does
500 ;; the `intltool-update' script.
501 ("gettext" ,gettext-minimal)
502
503 ("perl-xml-parser" ,perl-xml-parser)
504 ("perl" ,perl)))
505 (arguments
506 `(#:phases
507 (modify-phases %standard-phases
508 (add-after 'unpack 'patch-file-references
509 (lambda* (#:key inputs #:allow-other-keys)
510 (let ((file (assoc-ref inputs "file")))
511 (substitute* "intltool-update.in"
512 (("`file") (string-append "`" file "/bin/file")))
513 #t))))))
514 (home-page "https://launchpad.net/intltool/+download")
515 (synopsis "Tools to centralise translations of different file formats")
516 (description
517 "Intltool is a set of tools to centralise translations of many different
518 file formats using GNU gettext-compatible PO files.
519
520 The intltool collection can be used to do these things:
521
522 Extract translatable strings from various source files (.xml.in,
523 glade, .desktop.in, .server.in, .oaf.in).
524
525 Collect the extracted strings together with messages from traditional
526 source files (.c, .h) in po/$(PACKAGE).pot.
527
528 Merge back the translations from .po files into .xml, .desktop and
529 oaf files. This merge step will happen at build resp. installation time.")
530 (license license:gpl2+)))
531
532 (define itstool
533 (package
534 (name "itstool")
535 (version "2.0.6")
536 (source (origin
537 (method url-fetch)
538 (uri (string-append "http://files.itstool.org/itstool/itstool-"
539 version ".tar.bz2"))
540 (sha256
541 (base32
542 "1acjgf8zlyk7qckdk19iqaca4jcmywd7vxjbcs1mm6kaf8icqcv2"))))
543 (build-system gnu-build-system)
544 (inputs
545 `(("libxml2" ,libxml2)
546 ("python-libxml2" ,python-libxml2)
547 ("python" ,python)))
548 (arguments
549 '(#:phases
550 (modify-phases %standard-phases
551 (add-after 'install 'wrap-program
552 (lambda* (#:key outputs #:allow-other-keys)
553 (let ((prog (string-append (assoc-ref outputs "out")
554 "/bin/itstool")))
555 (wrap-program prog
556 `("PYTHONPATH" = (,(getenv "PYTHONPATH"))))
557 #t))))))
558 (home-page "http://www.itstool.org")
559 (synopsis "Tool to translate XML documents with PO files")
560 (description
561 "ITS Tool allows you to translate your XML documents with PO files, using
562 rules from the W3C Internationalization Tag Set (ITS) to determine what to
563 translate and how to separate it into PO file messages.
564
565 PO files are the standard translation format for GNU and other Unix-like
566 systems. They present translatable information as discrete messages, allowing
567 each message to be translated independently. In contrast to whole-page
568 translation, translating with a message-based format like PO means you can
569 easily track changes to the source document down to the paragraph. When new
570 strings are added or existing strings are modified, you only need to update the
571 corresponding messages.
572
573 ITS Tool is designed to make XML documents translatable through PO files by
574 applying standard ITS rules, as well as extension rules specific to ITS Tool.
575 ITS also provides an industry standard way for authors to override translation
576 information in their documents, such as whether a particular element should be
577 translated.")
578 (license license:gpl3+)))
579
580 (define dbus-glib
581 (package
582 (name "dbus-glib")
583 (version "0.110")
584 (source (origin
585 (method url-fetch)
586 (uri
587 (string-append "https://dbus.freedesktop.org/releases/dbus-glib/dbus-glib-"
588 version ".tar.gz"))
589 (sha256
590 (base32
591 "09g8swvc95bk1z6j8sw463p2v0dqmgm2zjfndf7i8sbcyq67dr3w"))))
592 (build-system gnu-build-system)
593 (propagated-inputs ; according to dbus-glib-1.pc
594 `(("dbus" ,dbus)
595 ("glib" ,glib)))
596 (inputs
597 `(("expat" ,expat)))
598 (native-inputs
599 `(("glib" ,glib "bin")
600 ("pkg-config" ,pkg-config)))
601 (home-page "https://dbus.freedesktop.org/doc/dbus-glib/")
602 (synopsis "D-Bus GLib bindings")
603 (description
604 "GLib bindings for D-Bus. The package is obsolete and superseded
605 by GDBus included in Glib.")
606 (license license:gpl2))) ; or Academic Free License 2.1
607
608 (define libsigc++
609 (package
610 (name "libsigc++")
611 (version "2.10.3")
612 (source (origin
613 (method url-fetch)
614 (uri (string-append "mirror://gnome/sources/libsigc++/"
615 (version-major+minor version) "/"
616 name "-" version ".tar.xz"))
617 (sha256
618 (base32
619 "11j7j1jv4z58d9s7jvl42fnqa1dzl4idgil9r45cjv1w673dys0b"))))
620 (build-system gnu-build-system)
621 (native-inputs `(("pkg-config" ,pkg-config)
622 ("m4" ,m4)))
623 (home-page "https://libsigcplusplus.github.io/libsigcplusplus/")
624 (synopsis "Type-safe callback system for standard C++")
625 (description
626 "Libsigc++ implements a type-safe callback system for standard C++. It
627 allows you to define signals and to connect those signals to any callback
628 function, either global or a member function, regardless of whether it is
629 static or virtual.
630
631 It also contains adaptor classes for connection of dissimilar callbacks and
632 has an ease of use unmatched by other C++ callback libraries.")
633 (license license:lgpl2.1+)))
634
635 (define glibmm
636 (package
637 (name "glibmm")
638 (version "2.62.0")
639 (source (origin
640 (method url-fetch)
641 (uri (string-append "mirror://gnome/sources/glibmm/"
642 (version-major+minor version)
643 "/glibmm-" version ".tar.xz"))
644 (sha256
645 (base32
646 "1ziwx6r7k7wbvg4qq1rgrv8zninapgrmhn1hs6926a3krh9ryr9n"))))
647 (build-system gnu-build-system)
648 (arguments
649 `(#:phases
650 (modify-phases %standard-phases
651 (add-before 'build 'pre-build
652 (lambda _
653 ;; This test uses /etc/fstab as an example file to read
654 ;; from; choose a better example.
655 (substitute* "tests/giomm_simple/main.cc"
656 (("/etc/fstab")
657 (string-append (getcwd)
658 "/tests/giomm_simple/main.cc")))
659
660 ;; This test does a DNS lookup, and then expects to be able
661 ;; to open a TLS session; just skip it.
662 (substitute* "tests/giomm_tls_client/main.cc"
663 (("Gio::init.*$")
664 "return 77;\n"))
665 #t)))))
666 (native-inputs `(("pkg-config" ,pkg-config)
667 ("glib" ,glib "bin")))
668 (propagated-inputs
669 `(("libsigc++" ,libsigc++)
670 ("glib" ,glib)))
671 (home-page "https://gtkmm.org/")
672 (synopsis "C++ interface to the GLib library")
673 (description
674 "Glibmm provides a C++ programming interface to the part of GLib that are
675 useful for C++.")
676 (license license:lgpl2.1+)))
677
678 (define-public glibmm-2.64
679 (package
680 (inherit glibmm)
681 (name "glibmm")
682 (version "2.64.2")
683 (source
684 (origin
685 (method url-fetch)
686 (uri
687 (string-append "mirror://gnome/sources/glibmm/"
688 (version-major+minor version)
689 "/glibmm-" version ".tar.xz"))
690 (sha256
691 (base32 "1v6lp23fr2qh4zshcnm28sn29j3nzgsvcqj2nhmrnvamipjq4lm7"))))
692 (propagated-inputs
693 `(("libsigc++" ,libsigc++)
694 ("glib" ,glib)))))
695
696 (define-public python2-pygobject-2
697 (package
698 (name "python2-pygobject")
699 ;; This was the last version to declare the 2.0 platform number, i.e. its
700 ;; pkg-config files were named pygobject-2.0.pc
701 (version "2.28.7")
702 (source
703 (origin
704 (method url-fetch)
705 (uri (string-append "mirror://gnome/sources/pygobject/"
706 (version-major+minor version)
707 "/pygobject-" version ".tar.xz"))
708 (sha256
709 (base32
710 "0nkam61rsn7y3wik3vw46wk5q2cjfh2iph57hl9m39rc8jijb7dv"))
711 (patches (search-patches "python2-pygobject-2-deprecation.patch"))))
712 (build-system gnu-build-system)
713 (native-inputs
714 `(("which" ,which)
715 ("glib-bin" ,glib "bin") ;for tests: glib-compile-schemas
716 ("pkg-config" ,pkg-config)
717 ("dbus" ,dbus))) ;for tests
718 (inputs
719 `(("python" ,python-2)
720 ("glib" ,glib)
721 ("python2-pycairo" ,python2-pycairo)
722 ("gobject-introspection" ,gobject-introspection)))
723 (propagated-inputs
724 `(("libffi" ,libffi))) ;mentioned in pygobject-2.0.pc
725 (arguments
726 `(#:tests? #f ;segfaults during tests
727 #:configure-flags '("LIBS=-lcairo-gobject")))
728 (home-page "https://pypi.org/project/PyGObject/")
729 (synopsis "Python bindings for GObject")
730 (description
731 "Python bindings for GLib, GObject, and GIO.")
732 (license license:lgpl2.1+)))
733
734 (define-public python-pygobject
735 (package
736 (name "python-pygobject")
737 (version "3.34.0")
738 (source
739 (origin
740 (method url-fetch)
741 (uri (string-append "mirror://gnome/sources/pygobject/"
742 (version-major+minor version)
743 "/pygobject-" version ".tar.xz"))
744 (sha256
745 (base32
746 "06i7ynnbvgpz0gw09zsjbvhgcp5qz4yzdifw27qjwdazg2mckql7"))
747 (modules '((guix build utils)))
748 (snippet
749 '(begin
750 ;; We disable these tests in a snippet so that they are inherited
751 ;; by the Python 2 variant which is built differently.
752 (with-directory-excursion "tests"
753 ;; FIXME: These tests require Gdk and/or Gtk 4.
754 (for-each delete-file
755 '("test_atoms.py" "test_overrides_gtk.py"))
756 #t)))))
757 (build-system meson-build-system)
758 (native-inputs
759 `(("glib-bin" ,glib "bin")
760 ("pkg-config" ,pkg-config)
761 ("python-pytest" ,python-pytest)))
762 (inputs
763 `(("python" ,python)
764 ("python-pycairo" ,python-pycairo)
765 ("gobject-introspection" ,gobject-introspection)))
766 (propagated-inputs
767 ;; pygobject-3.0.pc refers to all these.
768 `(("glib" ,glib)
769 ("libffi" ,libffi)))
770 ;; For finding typelib files, since gobject-introscpetion isn't propagated.
771 (native-search-paths (package-native-search-paths gobject-introspection))
772 (home-page "https://live.gnome.org/PyGObject")
773 (synopsis "Python bindings for GObject")
774 (description
775 "Python bindings for GLib, GObject, and GIO.")
776 (license license:lgpl2.1+)
777 (properties `((python2-variant . ,(delay python2-pygobject))))))
778
779 (define-public python2-pygobject
780 (package (inherit (strip-python2-variant python-pygobject))
781 (name "python2-pygobject")
782
783 ;; Note: We use python-build-system here, because Meson only supports
784 ;; Python 3, and needs PYTHONPATH etc set up correctly, which makes it
785 ;; difficult to use for Python 2 projects.
786 (build-system python-build-system)
787 (arguments
788 `(#:python ,python-2
789 #:phases
790 (modify-phases %standard-phases
791 (add-after 'unpack 'delete-broken-tests
792 (lambda _
793 ;; FIXME: this test freezes and times out.
794 (delete-file "tests/test_mainloop.py")
795 ;; FIXME: this test fails with this kind of error:
796 ;; AssertionError: <Handlers.SIG_IGN: 1> != <built-in function default_int_handler
797 (delete-file "tests/test_ossig.py")
798 #t)))))
799 (inputs
800 `(("python-pycairo" ,python2-pycairo)
801 ("gobject-introspection" ,gobject-introspection)))
802 (native-inputs
803 `(("glib-bin" ,glib "bin")
804 ("pkg-config" ,pkg-config)
805 ("python-pytest" ,python2-pytest)))))
806
807 (define-public perl-glib
808 (package
809 (name "perl-glib")
810 (version "1.3292")
811 (source (origin
812 (method url-fetch)
813 (uri (string-append
814 "mirror://cpan/authors/id/X/XA/XAOC/Glib-"
815 version ".tar.gz"))
816 (sha256
817 (base32
818 "1q5075d6v2g5sm675hyzrcpxsrh09z83crfci8b0wl3jwmnz0frg"))))
819 (build-system perl-build-system)
820 (native-inputs
821 `(("perl-extutils-depends" ,perl-extutils-depends)
822 ("perl-extutils-pkgconfig" ,perl-extutils-pkgconfig)))
823 (inputs
824 `(("glib" ,glib)))
825 (home-page "https://metacpan.org/release/Glib")
826 (synopsis "Perl wrappers for the GLib utility and Object libraries")
827 (description "This module provides perl access to GLib and GLib's GObject
828 libraries. GLib is a portability and utility library; GObject provides a
829 generic type system with inheritance and a powerful signal system. Together
830 these libraries are used as the foundation for many of the libraries that make
831 up the Gnome environment, and are used in many unrelated projects.")
832 (license license:lgpl2.1+)))
833
834 (define telepathy-glib
835 (package
836 (name "telepathy-glib")
837 (version "0.24.1")
838 (source
839 (origin
840 (method url-fetch)
841 (uri
842 (string-append
843 "https://telepathy.freedesktop.org/releases/telepathy-glib/"
844 "telepathy-glib-" version ".tar.gz"))
845 (sha256
846 (base32
847 "1symyzbjmxvksn2ifdkk50lafjm2llf2sbmky062gq2pz3cg23cy"))
848 (patches
849 (list
850 (search-patch "telepathy-glib-channel-memory-leak.patch")
851 ;; Don't use the same test name for multiple tests.
852 ;; <https://bugs.freedesktop.org/show_bug.cgi?id=92245>
853 (origin
854 (method url-fetch)
855 (uri "https://bugs.freedesktop.org/attachment.cgi?id=118608")
856 (file-name (string-append "telepathy-glib-duplicate-tests.patch"))
857 (sha256
858 (base32
859 "0z261fwrszxb28ccg3hsg9rizig4s84zvwmx6y31a4pyv7bvs5w3")))))))
860 (build-system gnu-build-system)
861 (arguments
862 '(#:configure-flags '("--enable-vala-bindings")
863
864 ;; '../tools/glib-*.py' generate files but the target dependencies are
865 ;; (presumably) not fully specified in the makefile, leading to
866 ;; parallel build errors like:
867 ;;
868 ;; EOFError: EOF read where object expected
869 ;; make[2]: *** [Makefile:1906: _gen/register-dbus-glib-marshallers-body.h] Error 1
870 #:parallel-build? #f
871 #:phases
872 (modify-phases %standard-phases
873 (add-after 'unpack 'disable-failing-tests
874 (lambda _
875 ;; None of the tests below are able to find the org.gtk.vfs.Daemon
876 ;; service file provided by gvfs.
877 (substitute* "tests/dbus/Makefile.in"
878 (("test-contacts\\$\\(EXEEXT\\)") "")
879 (("test-file-transfer-channel\\$\\(EXEEXT\\)") "")
880 (("test-stream-tube\\$\\(EXEEXT\\)") ""))
881 #t)))))
882 (native-inputs
883 `(("glib" ,glib "bin") ; uses glib-mkenums
884 ("gobject-introspection" ,gobject-introspection)
885 ("pkg-config" ,pkg-config)
886 ("python" ,python-2)
887 ("vala" ,vala)
888 ("xsltproc" ,libxslt)))
889 (propagated-inputs
890 ;; There are all in the Requires.private field of telepathy-glib.pc.
891 `(("dbus" ,dbus)
892 ("dbus-glib" ,dbus-glib)
893 ("glib" ,glib)))
894 (home-page "https://telepathy.freedesktop.org/wiki/")
895 (synopsis "GLib Real-time communications framework over D-Bus")
896 (description "Telepathy is a flexible, modular communications framework
897 that enables real-time communication over D-Bus via pluggable protocol
898 backends. Telepathy is a communications service that can be accessed by
899 many applications simultaneously.
900
901 This package provides the library for GLib applications.")
902 (license license:lgpl2.1+)))
903
904 (define-public dbus-c++
905 (package
906 (name "dbus-c++")
907 (version "0.9.0")
908 (source (origin
909 (method url-fetch)
910 (uri
911 (string-append
912 "mirror://sourceforge/dbus-cplusplus/dbus-c%2B%2B/"
913 version "/libdbus-c%2B%2B-" version ".tar.gz"))
914 (file-name (string-append name "-" version ".tar.gz"))
915 (patches (search-patches "dbus-c++-gcc-compat.patch"
916 "dbus-c++-threading-mutex.patch"))
917 (sha256
918 (base32
919 "0qafmy2i6dzx4n1dqp6pygyy6gjljnb7hwjcj2z11c1wgclsq4dw"))))
920 (build-system gnu-build-system)
921 (propagated-inputs
922 `(("dbus" ,dbus))) ;mentioned in the pkg-config file
923 (inputs
924 `(("efl" ,efl)
925 ("expat" ,expat)
926 ("glib" ,glib)))
927 (native-inputs
928 `(("pkg-config" ,pkg-config)))
929 (arguments
930 `(;; The 'configure' machinery fails to detect that it needs -lpthread.
931 #:configure-flags (list "LDFLAGS=-lpthread")
932 #:phases
933 (modify-phases %standard-phases
934 (add-before 'configure 'add-missing-header
935 (lambda _
936 (substitute* "include/dbus-c++/eventloop-integration.h"
937 (("#include <errno.h>")
938 "#include <errno.h>\n#include <unistd.h>"))
939 #t)))))
940 (synopsis "D-Bus API for C++")
941 (description "This package provides D-Bus client API bindings for the C++
942 programming language. It also contains the utility
943 @command{dbuscxx-xml2cpp}.")
944 (home-page "https://sourceforge.net/projects/dbus-cplusplus/")
945 (license license:lgpl2.1+)))
946
947 (define-public dbus-cxx
948 (package
949 (name "dbus-cxx")
950 (version "0.12.0")
951 (source (origin
952 (method url-fetch)
953 (uri (string-append "mirror://sourceforge/dbus-cxx/dbus-cxx/"
954 version "/dbus-cxx-" version ".tar.gz"))
955 (sha256
956 (base32
957 "1acsgpkd9v7b9jdc79ijmh9dbdfrzgkwkaff518i3zpk7y6g5mzw"))))
958 (build-system cmake-build-system)
959 (arguments
960 `(#:configure-flags '("-DENABLE_TESTS=ON"
961 "-DENABLE_TOOLS=ON"
962 "-DENABLE_GLIBMM=ON")))
963 (inputs `(("dbus" ,dbus)
964 ("libsigc++" ,libsigc++)
965 ("glibmm" ,glibmm)
966 ("python" ,python)
967 ("popt" ,popt)
968 ("expat" ,expat)))
969 (native-inputs `(("pkg-config" ,pkg-config)
970 ("m4" ,m4)))
971 (synopsis "C++ wrapper for dbus")
972 (description "Dbus-cxx is a C++ wrapper for dbus.\n
973 It exposes the C API to allow direct manipulation and
974 relies on sigc++ to provide an Oriented Object interface.\n
975 This package provide 2 utils:
976 @enumerate
977 @item @command{dbus-cxx-xml2cpp} to generate proxy and adapter
978 @item @command{dbus-cxx-introspect} to introspect a dbus interface
979 @end enumerate
980
981 Some codes examples can be find at:
982 @url{https://dbus-cxx.github.io/examples.html}")
983 (home-page "https://dbus-cxx.github.io/")
984 (license license:gpl3)))
985
986 (define-public appstream-glib
987 (package
988 (name "appstream-glib")
989 (version "0.7.18")
990 (source (origin
991 (method url-fetch)
992 (uri (string-append "https://people.freedesktop.org/~hughsient/"
993 "appstream-glib/releases/"
994 "appstream-glib-" version ".tar.xz"))
995 (sha256
996 (base32
997 "00j0kkgf224nzmrha72g8pd72mymhph7vaisj35i4ffy7cpd47na"))))
998 (build-system meson-build-system)
999 (native-inputs
1000 `(("gettext" ,gettext-minimal)
1001 ("glib:bin" ,glib "bin") ; for glib-compile-resources
1002 ("pkg-config" ,pkg-config)))
1003 (propagated-inputs
1004 `(("gcab" ,gcab) ; for .pc file
1005 ("gdk-pixbuf" ,gdk-pixbuf) ; for .pc file
1006 ("libuuid" ,util-linux "lib"))) ; for .pc file
1007 (inputs
1008 `(("glib" ,glib)
1009 ("gperf" ,gperf)
1010 ("gtk+" ,gtk+)
1011 ("json-glib" ,json-glib)
1012 ("libarchive" ,libarchive)
1013 ("libsoup" ,libsoup)))
1014 (arguments
1015 `(#:configure-flags
1016 (list "-Ddep11=false"
1017 "-Dintrospection=false" ; avoid g-ir-scanner dependency
1018 "-Drpm=false"
1019 "-Dstemmer=false")
1020 #:phases
1021 (modify-phases %standard-phases
1022 (add-after 'unpack 'patch-tests
1023 (lambda _
1024 (substitute* "libappstream-glib/as-self-test.c"
1025 (("g_test_add_func.*as_test_store_local_appdata_func);") ""))
1026 #t)))))
1027 (home-page "https://github.com/hughsie/appstream-glib")
1028 (synopsis "Library for reading and writing AppStream metadata")
1029 (description "This library provides objects and helper methods to help
1030 reading and writing @uref{https://www.freedesktop.org/wiki/Distributions/AppStream,AppStream}
1031 metadata.")
1032 (license license:lgpl2.1+)))
1033
1034 (define perl-net-dbus
1035 (package
1036 (name "perl-net-dbus")
1037 (version "1.1.0")
1038 (source
1039 (origin
1040 (method url-fetch)
1041 (uri (string-append "mirror://cpan/authors/id/D/DA/DANBERR/Net-DBus-"
1042 version ".tar.gz"))
1043 (sha256
1044 (base32
1045 "0sg2w147b9r9ykfzjs7y9qxry73xkjnhnk4qf95kfv79p5nnk4c3"))))
1046 (build-system perl-build-system)
1047 (native-inputs
1048 `(("pkg-config" ,pkg-config)
1049 ("perl-test-pod" ,perl-test-pod)
1050 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
1051 (inputs
1052 `(("dbus" ,dbus)))
1053 (propagated-inputs
1054 `(("perl-xml-twig" ,perl-xml-twig)))
1055 (home-page "https://metacpan.org/release/Net-DBus")
1056 (synopsis "Extension for the DBus bindings")
1057 (description "@code{Net::DBus} provides a Perl XS API to the DBus
1058 inter-application messaging system. The Perl API covers the core base level
1059 of the DBus APIs, not concerning itself yet with the GLib or QT wrappers.")
1060 (license license:perl-license)))
1061
1062 (define perl-net-dbus-glib
1063 (package
1064 (name "perl-net-dbus-glib")
1065 (version "0.33.0")
1066 (source
1067 (origin
1068 (method url-fetch)
1069 (uri (string-append "mirror://cpan/authors/id/D/DA/DANBERR/"
1070 "Net-DBus-GLib-" version ".tar.gz"))
1071 (sha256
1072 (base32
1073 "1z4mbv8z0rad604xahijpg5szzi8qak07hbahh230z4jf96fkxvj"))))
1074 (build-system perl-build-system)
1075 (native-inputs
1076 `(("pkg-config" ,pkg-config)))
1077 (inputs
1078 `(("dbus-glib" ,dbus-glib)))
1079 (home-page "https://metacpan.org/release/Net-DBus-GLib")
1080 (synopsis "Perl extension for the DBus GLib bindings")
1081 (description "This package provides an extension to the @code{Net::DBus}
1082 module allowing integration with the GLib mainloop. To integrate with the
1083 main loop, simply get a connection to the bus via the methods in
1084 @code{Net::DBus::GLib} rather than the usual @code{Net::DBus} module. Every
1085 other API remains the same.")
1086 (license license:gpl2+)))
1087
1088 (define-public template-glib
1089 (package
1090 (name "template-glib")
1091 (version "3.34.0")
1092 (source (origin
1093 (method url-fetch)
1094 (uri (string-append "mirror://gnome/sources/" name "/"
1095 (version-major+minor version) "/"
1096 name "-" version ".tar.xz"))
1097 (sha256
1098 (base32
1099 "1z9xkin5fyfh071ma9y045jcw83hgx33dfbjraw6cxk0qdmfysr1"))))
1100 (build-system meson-build-system)
1101 (arguments
1102 `(#:configure-flags '("-D" "enable_gtk_doc=true")))
1103 (inputs
1104 `(("gettext" ,gettext-minimal)
1105 ("glib" ,glib)
1106 ("gobject-introspection" ,gobject-introspection)))
1107 (native-inputs
1108 `(("bison" ,bison)
1109 ("flex" ,flex)
1110 ("glib:bin" ,glib "bin") ;; For glib-mkenums
1111 ("gtk-doc" ,gtk-doc)
1112 ("pkg-config" ,pkg-config)
1113 ("vala" ,vala)))
1114 (home-page "https://gitlab.gnome.org/GNOME/template-glib")
1115 (synopsis "Library for template expansion")
1116 (description
1117 "Template-GLib is a library to help you generate text based on a template and
1118 user defined state. Template-GLib does not use a language runtime, so it is
1119 safe to use from any GObject-Introspectable language.
1120
1121 Template-GLib allows you to access properties on GObjects as well as call
1122 simple methods via GObject-Introspection.")
1123 (license license:lgpl2.1+)))
1124
1125 (define-public xdg-dbus-proxy
1126 (package
1127 (name "xdg-dbus-proxy")
1128 (version "0.1.2")
1129 (source (origin
1130 (method url-fetch)
1131 (uri (string-append "https://github.com/flatpak/xdg-dbus-proxy"
1132 "/releases/download/" version
1133 "/xdg-dbus-proxy-" version ".tar.xz"))
1134 (sha256
1135 (base32
1136 "03sj1h0c2l08xa8phw013fnxr4fgav7l2mkjhzf9xk3dykwxcj8p"))))
1137 (build-system gnu-build-system)
1138 (native-inputs
1139 `(("pkg-config" ,pkg-config)
1140
1141 ;; For tests.
1142 ("dbus" ,dbus)
1143
1144 ;; These are required to build the manual.
1145 ("docbook-xml" ,docbook-xml-4.3)
1146 ("docbook-xsl" ,docbook-xsl)
1147 ("libxml2" ,libxml2)
1148 ("xsltproc" ,libxslt)))
1149 (inputs
1150 `(("glib" ,glib)))
1151 (home-page "https://github.com/flatpak/xdg-dbus-proxy")
1152 (synopsis "D-Bus connection proxy")
1153 (description
1154 "xdg-dbus-proxy is a filtering proxy for D-Bus connections. It can be
1155 used to create D-Bus sockets inside a Linux container that forwards requests
1156 to the host system, optionally with filters applied.")
1157 (license license:lgpl2.1+)))
1158
1159 (define-public dbus-test-runner
1160 (package
1161 (name "dbus-test-runner")
1162 (version "19.04.0")
1163 (source (origin
1164 (method url-fetch)
1165 (uri (string-append
1166 "https://launchpad.net/dbus-test-runner/"
1167 (version-major+minor version) "/" version
1168 "/+download/dbus-test-runner-" version ".tar.gz"))
1169 (sha256
1170 (base32
1171 "0xnbay58xn0hav208mdsg8dd176w57dcpw1q2k0g5fh9v7xk4nk4"))))
1172 (build-system gnu-build-system)
1173 (arguments
1174 `(#:phases
1175 (modify-phases %standard-phases
1176 (add-before 'configure 'fix-test-paths
1177 ;; add missing space
1178 (lambda* (#:key outputs #:allow-other-keys)
1179 (substitute* "Makefile.in"
1180 (("#!/bin/bash") (string-append "#!" (which "bash"))))
1181 (substitute* "tests/Makefile.in"
1182 (("/bin/sh") (which "sh"))
1183 (("#!/bin/bash") (string-append "#!" (which "bash")))
1184 (("echo cat") (string-append "echo " (which "cat")))
1185 (("/bin/true") (which "true")))
1186 #t)))))
1187 (inputs
1188 `(("gtk+" ,gtk+)
1189 ("glib" ,glib)
1190 ("dbus-glib" ,dbus-glib)))
1191 (native-inputs
1192 `(("glib:bin" ,glib "bin")
1193 ("intltool" ,intltool)
1194 ("pkg-config" ,pkg-config)
1195 ;; following used for tests
1196 ("python" ,python)
1197 ("python-dbusmock" ,python-dbusmock)
1198 ("xvfb" ,xorg-server-for-tests)))
1199 (home-page "https://launchpad.net/dbus-test-runner")
1200 (synopsis "Run a executables under a new DBus session for testing")
1201 (description "A small little utility to run a couple of executables under a
1202 new DBus session for testing.")
1203 (license license:gpl3)))