Merge branch 'master' into staging
[jackhill/guix/guix.git] / gnu / packages / freedesktop.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
4 ;;; Copyright © 2015, 2017 Andy Wingo <wingo@pobox.com>
5 ;;; Copyright © 2015, 2016, 2017, 2019 Ludovic Courtès <ludo@gnu.org>
6 ;;; Copyright © 2015, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
7 ;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
8 ;;; Copyright © 2016, 2017, 2019 Efraim Flashner <efraim@flashner.co.il>
9 ;;; Copyright © 2016 Kei Kebreau <kkebreau@posteo.net>
10 ;;; Copyright © 2017 Nikita <nikita@n0.is>
11 ;;; Copyright © 2017, 2018 Mark H Weaver <mhw@netris.org>
12 ;;; Copyright © 2017, 2018, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
13 ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com>
14 ;;; Copyright © 2017, 2020 Brendan Tildesley <mail@brendan.scot>
15 ;;; Copyright © 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
16 ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
17 ;;; Copyright © 2018 Stefan Stefanović <stefanx2ovic@gmail.com>
18 ;;; Copyright © 2019 Reza Alizadeh Majd <r.majd@pantherx.org>
19 ;;; Copyright © 2019, 2020 Guillaume Le Vaillant <glv@posteo.net>
20 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
21 ;;; Copyright © 2020 Rene Saavedra <pacoon@protonmail.com>
22 ;;; Copyright © 2020 Nicolò Balzarotti <nicolo@nixo.xyz>
23 ;;;
24 ;;; This file is part of GNU Guix.
25 ;;;
26 ;;; GNU Guix is free software; you can redistribute it and/or modify it
27 ;;; under the terms of the GNU General Public License as published by
28 ;;; the Free Software Foundation; either version 3 of the License, or (at
29 ;;; your option) any later version.
30 ;;;
31 ;;; GNU Guix is distributed in the hope that it will be useful, but
32 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
33 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
34 ;;; GNU General Public License for more details.
35 ;;;
36 ;;; You should have received a copy of the GNU General Public License
37 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
38
39 (define-module (gnu packages freedesktop)
40 #:use-module ((guix licenses) #:prefix license:)
41 #:use-module (guix utils)
42 #:use-module (guix packages)
43 #:use-module (guix download)
44 #:use-module (guix git-download)
45 #:use-module (guix build-system cmake)
46 #:use-module (guix build-system gnu)
47 #:use-module (guix build-system meson)
48 #:use-module (guix build-system perl)
49 #:use-module (guix build-system python)
50 #:use-module (gnu packages)
51 #:use-module (gnu packages acl)
52 #:use-module (gnu packages admin)
53 #:use-module (gnu packages autotools)
54 #:use-module (gnu packages base)
55 #:use-module (gnu packages bash)
56 #:use-module (gnu packages boost)
57 #:use-module (gnu packages check)
58 #:use-module (gnu packages compression)
59 #:use-module (gnu packages cryptsetup)
60 #:use-module (gnu packages disk)
61 #:use-module (gnu packages docbook)
62 #:use-module (gnu packages documentation)
63 #:use-module (gnu packages gawk)
64 #:use-module (gnu packages gettext)
65 #:use-module (gnu packages ghostscript)
66 #:use-module (gnu packages gl)
67 #:use-module (gnu packages glib) ;intltool
68 #:use-module (gnu packages gnome)
69 #:use-module (gnu packages gperf)
70 #:use-module (gnu packages graphviz)
71 #:use-module (gnu packages gtk)
72 #:use-module (gnu packages image)
73 #:use-module (gnu packages libffi)
74 #:use-module (gnu packages libunwind)
75 #:use-module (gnu packages libusb)
76 #:use-module (gnu packages linux)
77 #:use-module (gnu packages man)
78 #:use-module (gnu packages m4)
79 #:use-module (gnu packages nss)
80 #:use-module (gnu packages perl)
81 #:use-module (gnu packages perl-check)
82 #:use-module (gnu packages pkg-config)
83 #:use-module (gnu packages polkit)
84 #:use-module (gnu packages python)
85 #:use-module (gnu packages python-crypto)
86 #:use-module (gnu packages python-xyz)
87 #:use-module (gnu packages sqlite)
88 #:use-module (gnu packages valgrind)
89 #:use-module (gnu packages video)
90 #:use-module (gnu packages w3m)
91 #:use-module (gnu packages web)
92 #:use-module (gnu packages xdisorg)
93 #:use-module (gnu packages xml)
94 #:use-module (gnu packages xorg)
95 #:use-module (srfi srfi-1))
96
97 (define-public xdg-utils
98 (package
99 (name "xdg-utils")
100 (version "1.1.3")
101 (source
102 (origin
103 (method url-fetch)
104 (uri (string-append
105 "https://portland.freedesktop.org/download/xdg-utils-"
106 version ".tar.gz"))
107 (sha256
108 (base32
109 "1nai806smz3zcb2l5iny4x7li0fak0rzmjg6vlyhdqm8z25b166p"))))
110 (build-system gnu-build-system)
111 (native-inputs
112 `(("docbook-xsl" ,docbook-xsl)
113 ("docbook-xml" ,docbook-xml-4.1.2)
114 ("libxslt" ,libxslt)
115 ("w3m" ,w3m)
116 ("xmlto" ,xmlto)))
117 (inputs
118 `(("awk" ,gawk)
119 ("coreutils" ,coreutils)
120 ("grep" ,grep)
121 ("inetutils" ,inetutils) ; xdg-screensaver uses `hostname'
122 ("perl-file-mimeinfo" ,perl-file-mimeinfo) ; for mimeopen fallback
123 ("sed" ,sed)
124 ("xprop" ,xprop) ; for Xfce detecting
125 ("xset" ,xset))) ; for xdg-screensaver
126 (arguments
127 `(#:tests? #f ; no check target
128 #:modules ((srfi srfi-26)
129 ,@%gnu-build-system-modules)
130 #:phases
131 (modify-phases %standard-phases
132 (add-after 'unpack 'patch-hardcoded-paths
133 (lambda _
134 (substitute* "scripts/xdg-mime.in"
135 (("/usr/bin/file") (which "file")))
136 (substitute* "scripts/xdg-open.in"
137 (("/usr/bin/printf") (which "printf")))
138 #t))
139 (add-before 'build 'locate-catalog-files
140 (lambda* (#:key inputs #:allow-other-keys)
141 (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml")
142 "/xml/dtd/docbook"))
143 (xsldoc (string-append (assoc-ref inputs "docbook-xsl")
144 "/xml/xsl/docbook-xsl-"
145 ,(package-version docbook-xsl))))
146 (for-each (lambda (file)
147 (substitute* file
148 (("http://.*/docbookx\\.dtd")
149 (string-append xmldoc "/docbookx.dtd"))))
150 (find-files "scripts/desc" "\\.xml$"))
151 (substitute* "scripts/Makefile"
152 ;; Apparently `xmlto' does not bother to looks up the stylesheets
153 ;; specified in the XML, unlike the above substitition. Instead it
154 ;; uses a hard-coded URL. Work around it here, but if this is
155 ;; common perhaps we should hardcode this path in xmlto itself.
156 (("\\$\\(XMLTO\\) man")
157 (string-append "$(XMLTO) -x " xsldoc
158 "/manpages/docbook.xsl man")))
159 (setenv "STYLESHEET"
160 (string-append xsldoc "/html/docbook.xsl"))
161 #t)))
162 (add-after 'install 'wrap-executables
163 (lambda* (#:key inputs outputs #:allow-other-keys)
164 (let ((out (assoc-ref outputs "out")))
165 (with-directory-excursion (string-append out "/bin")
166 (let ((path-ext
167 (map (cute string-append <> "/bin")
168 (cons out
169 (map (cute assoc-ref inputs <>)
170 '("awk" "coreutils" "grep" "inetutils"
171 "perl-file-mimeinfo" "sed" "xprop"
172 "xset"))))))
173 (for-each (cute wrap-program <>
174 `("PATH" ":" prefix ,path-ext))
175 (find-files "."))))
176 #t))))))
177 (home-page "https://www.freedesktop.org/wiki/Software/xdg-utils/")
178 (synopsis "Freedesktop.org scripts for desktop integration")
179 (description "The xdg-utils package is a set of simple scripts that
180 provide basic desktop integration functions in the framework of the
181 freedesktop.org project.")
182 (license license:expat)))
183
184 (define-public libinput
185 ;; Updating this will rebuild over 700 packages through libinput-minimal.
186 (package
187 (name "libinput")
188 (version "1.15.5")
189 (source (origin
190 (method url-fetch)
191 (uri (string-append "https://freedesktop.org/software/libinput/"
192 "libinput-" version ".tar.xz"))
193 (sha256
194 (base32
195 "15ww4jl3lcxyi8m8idg8canklbqv729gnwpkz7r98c1w8a7zq3m9"))))
196 (build-system meson-build-system)
197 (arguments
198 `(#:configure-flags '("-Ddocumentation=false")
199
200 ;; XXX: Using 'debug' or 'debugoptimized' pulls in an additional test that
201 ;; hangs, and the comments around it suggests that we should be using this
202 ;; Meson target anyway.
203 #:build-type "release"))
204 (native-inputs
205 `(("check" ,check)
206 ("pkg-config" ,pkg-config)))
207 (inputs
208 `(("cairo" ,cairo)
209 ("glib" ,glib)
210 ("gtk+" ,gtk+)
211 ("libevdev" ,libevdev)
212 ("libwacom" ,libwacom)
213 ("mtdev" ,mtdev)))
214 (propagated-inputs
215 `(;; libinput.h requires <libudev.h>, so propagate it.
216 ("udev" ,eudev)))
217 (home-page "https://www.freedesktop.org/wiki/Software/libinput/")
218 (synopsis "Input devices handling library")
219 (description
220 "Libinput is a library to handle input devices for display servers and
221 other applications that need to directly deal with input devices.")
222 (license license:x11)))
223
224 (define-public libinput-minimal
225 (package (inherit libinput)
226 (name "libinput-minimal")
227 (inputs
228 (fold alist-delete (package-inputs libinput)
229 '("cairo" "glib" "gtk+" "libwacom")))
230 (arguments
231 (substitute-keyword-arguments (package-arguments libinput)
232 ((#:configure-flags flags ''())
233 `(cons* "-Dlibwacom=false"
234 "-Ddebug-gui=false" ;requires gtk+@3
235 ,flags))))))
236
237 (define-public libxdg-basedir
238 (package
239 (name "libxdg-basedir")
240 (version "1.2.0")
241 (source (origin
242 (method git-fetch)
243 (uri (git-reference
244 (url "https://github.com/devnev/libxdg-basedir")
245 (commit (string-append name "-" version))))
246 (file-name (git-file-name name version))
247 (sha256
248 (base32
249 "12yz53ny5bi2dii3zwcr6b9ay0yy1g1xv13jg097k7gjligcq11m"))))
250 (build-system gnu-build-system)
251 (arguments
252 '(#:phases
253 (modify-phases %standard-phases
254 (add-after 'unpack 'patch-autogen
255 (lambda _
256 ;; Run 'configure' in its own phase, not now.
257 (substitute* "autogen.sh"
258 (("^.*\\./configure.*") ""))
259 #t)))))
260 (native-inputs
261 `(("autoconf" ,autoconf)
262 ("automake" ,automake)
263 ("libtool" ,libtool)))
264 (home-page "https://github.com/devnev/libxdg-basedir")
265 (synopsis "Implementation of the XDG Base Directory specification")
266 (description
267 "libxdg-basedir is a C library providing some functions to use with
268 the freedesktop.org XDG Base Directory specification.")
269 (license license:expat)))
270
271 (define-public elogind
272 (package
273 (name "elogind")
274 (version "243.4")
275 (source (origin
276 (method git-fetch)
277 (uri (git-reference
278 (url "https://github.com/elogind/elogind")
279 (commit (string-append "v" version))))
280 (file-name (git-file-name name version))
281 (sha256
282 (base32
283 "141frvgyk4fafcxsix94qc0d9ffrwksld8lqq4hq6xsgjlvv0mrs"))))
284 (build-system meson-build-system)
285 (arguments
286 `(#:configure-flags
287 (let* ((out (assoc-ref %outputs "out"))
288 (sysconf (string-append out "/etc"))
289 (libexec (string-append out "/libexec/elogind"))
290 (dbuspolicy (string-append out "/etc/dbus-1/system.d"))
291 (shadow (assoc-ref %build-inputs "shadow"))
292 (shepherd (assoc-ref %build-inputs "shepherd"))
293 (halt-path (string-append shepherd "/sbin/halt"))
294 (kexec-path "") ;not available in Guix yet
295 (nologin-path (string-append shadow "/sbin/nologin"))
296 (poweroff-path (string-append shepherd "/sbin/shutdown"))
297 (reboot-path (string-append shepherd "/sbin/reboot")))
298 (list
299 (string-append "-Drootprefix=" out)
300 (string-append "-Dsysconfdir=" sysconf)
301 (string-append "-Drootlibexecdir=" libexec)
302 (string-append "-Ddbuspolicydir=" dbuspolicy)
303 (string-append "-Dc_link_args=-Wl,-rpath=" libexec)
304 (string-append "-Dcpp_link_args=-Wl,-rpath=" libexec)
305 (string-append "-Dhalt-path=" halt-path)
306 (string-append "-Dkexec-path=" kexec-path)
307 (string-append "-Dpoweroff-path=" poweroff-path)
308 (string-append "-Dreboot-path=" reboot-path)
309 (string-append "-Dnologin-path=" nologin-path)
310 "-Dcgroup-controller=elogind"
311 "-Dman=true"
312 ;; Disable some tests.
313 "-Dslow-tests=false"))
314 #:phases
315 (modify-phases %standard-phases
316 (add-after 'unpack 'fix-pkttyagent-path
317 (lambda _
318 (substitute* "meson.build"
319 (("join_paths\\(bindir, 'pkttyagent'\\)")
320 "'\"/run/current-system/profile/bin/pkttyagent\"'"))
321 #t))
322 (add-after 'unpack 'adjust-dbus-socket-address
323 (lambda _
324 ;; Look for the D-Bus socket in /var/run instead of /run. Remove
325 ;; this for versions > 243.4.
326 (substitute* "src/libelogind/sd-bus/bus-internal.h"
327 (("=/run/dbus/system_bus_socket")
328 "=/var/run/dbus/system_bus_socket"))
329 #t))
330 (add-after 'unpack 'adjust-tests
331 (lambda _
332 ;; This test tries to copy some bytes from /usr/lib/os-release,
333 ;; which does not exist in the build container. Choose something
334 ;; more likely to be available.
335 (substitute* "src/test/test-copy.c"
336 (("/usr/lib/os-release")
337 "/etc/passwd"))
338 ;; Use a shebang that works in the build container.
339 (substitute* "src/test/test-exec-util.c"
340 (("#!/bin/sh")
341 (string-append "#!" (which "sh"))))
342 ;; Do not look for files or directories that do not exist.
343 (substitute* "src/test/test-fs-util.c"
344 (("usr") "etc")
345 (("/etc/machine-id") "/etc/passwd"))
346 ;; FIXME: Why is sd_id128_get_machine_app_specific failing.
347 ;; Disable for now by hooking into the kernel support check.
348 (substitute* "src/test/test-id128.c"
349 (("if \\(r == -EOPNOTSUPP\\)")
350 "if (1)"))
351 ;; This test expects that /sys is available.
352 (substitute* "src/test/test-mountpoint-util.c"
353 (("assert_se\\(path_is_mount_point\\(\"/sys.*")
354 ""))
355 ;; /bin/sh does not exist in the build container.
356 (substitute* "src/test/test-path-util.c"
357 (("/bin/sh") (which "sh")))
358 ;; This test uses sd_device_new_from_syspath to allocate a
359 ;; loopback device, but that fails because /sys is unavailable.
360 (substitute* "src/libelogind/sd-device/test-sd-device-thread.c"
361 ((".*sd_device_new_from_syspath.*/sys/class/net/lo.*")
362 "return 77;"))
363 ;; Most of these tests require cgroups or an actual live
364 ;; logind system so that it can flicker the monitor, etc.
365 ;; Just skip it until a more narrow selection can be made.
366 (substitute* "src/libelogind/sd-login/test-login.c"
367 (("r = sd_pid_get_slice.*")
368 "return 77;"))
369 #t))
370 (add-after 'unpack 'change-pid-file-path
371 (lambda _
372 (substitute* "src/login/elogind.c"
373 (("\"/run/elogind.pid\"") "\"/run/systemd/elogind.pid\""))
374 #t)))))
375 (native-inputs
376 `(("docbook-xml" ,docbook-xml)
377 ("docbook-xml-4.2" ,docbook-xml-4.2)
378 ("docbook-xsl" ,docbook-xsl)
379 ("gettext" ,gettext-minimal)
380 ("gperf" ,gperf)
381 ("libxml2" ,libxml2) ;for XML_CATALOG_FILES
382 ("m4" ,m4)
383 ("pkg-config" ,pkg-config)
384 ("python" ,python)
385 ("xsltproc" ,libxslt)))
386 (inputs
387 `(("linux-pam" ,linux-pam)
388 ("libcap" ,libcap)
389 ("shadow" ,shadow) ;for 'nologin'
390 ("shepherd" ,shepherd) ;for 'halt' and 'reboot', invoked
391 ;when pressing the power button
392 ("dbus" ,dbus)
393 ("eudev" ,eudev)
394 ("acl" ,acl))) ;to add individual users to ACLs on /dev nodes
395 (home-page "https://github.com/elogind/elogind")
396 (synopsis "User, seat, and session management service")
397 (description "Elogind is the systemd project's \"logind\" service,
398 extracted out as a separate project. Elogind integrates with PAM to provide
399 the org.freedesktop.login1 interface over the system bus, allowing other parts
400 of a the system to know what users are logged in, and where.")
401 (license license:lgpl2.1+)))
402
403 (define-public localed
404 ;; XXX: This package is extracted from systemd but we retain so little of it
405 ;; that it would make more sense to maintain a fork of the bits we need.
406 (package
407 (name "localed")
408 (version "241")
409 (source (origin
410 (method git-fetch)
411 (uri (git-reference
412 (url "https://github.com/systemd/systemd")
413 (commit (string-append "v" version))))
414 (sha256
415 (base32
416 "0sy91flzbhpq58k7v0294pa2gxpr0bk27rcnxlbhk2fi6nc51d28"))
417 (file-name (git-file-name name version))
418 (modules '((guix build utils)))
419 (snippet
420 '(begin
421 ;; Connect to the right location for our D-Bus daemon.
422 (substitute* '("src/basic/def.h"
423 "src/libsystemd/sd-bus/sd-bus.c"
424 "src/stdio-bridge/stdio-bridge.c")
425 (("/run/dbus/system_bus_socket")
426 "/var/run/dbus/system_bus_socket"))
427
428 ;; Don't insist on having systemd as PID 1 (otherwise
429 ;; 'localectl' would exit without doing anything.)
430 (substitute* "src/shared/bus-util.c"
431 (("sd_booted\\(\\)")
432 "(1)"))
433 #t))
434 (patches (search-patches "localed-xorg-keyboard.patch"))))
435 (build-system meson-build-system)
436 (arguments
437 ;; Try to build as little as possible (list of components taken from the
438 ;; top-level 'meson.build' file.)
439 (let ((components '("utmp"
440 "hibernate"
441 "environment-d"
442 "binfmt"
443 "coredump"
444 "resolve"
445 "logind"
446 "hostnamed"
447 "localed"
448 "machined"
449 "portabled"
450 "networkd"
451 "timedated"
452 "timesyncd"
453 "firstboot"
454 "randomseed"
455 "backlight"
456 "vconsole"
457 "quotacheck"
458 "sysusers"
459 "tmpfiles"
460 "hwdb"
461 "rfkill"
462 "ldconfig"
463 "efi"
464 "tpm"
465 "ima"
466 "smack"
467 "gshadow"
468 "idn"
469 "nss-myhostname"
470 "nss-systemd")))
471 `(#:configure-flags ',(map (lambda (component)
472 (string-append "-D" component "=false"))
473 (delete "localed" components))
474
475 ;; It doesn't make sense to test all of systemd.
476 #:tests? #f
477
478 #:phases (modify-phases %standard-phases
479 (add-after 'unpack 'set-xkeyboard-config-file-name
480 (lambda* (#:key inputs #:allow-other-keys)
481 ;; Set the file name to xkeyboard-config and kbd.
482 ;; This is used by 'localectl list-x11-keymap-layouts'
483 ;; and similar functions.
484 (let ((xkb (assoc-ref inputs "xkeyboard-config"))
485 (kbd (assoc-ref inputs "kbd")))
486 (substitute* "src/locale/localectl.c"
487 (("/usr/share/X11/xkb/rules")
488 (string-append xkb "/share/X11/xkb/rules")))
489 (substitute* "src/basic/def.h"
490 (("/usr/share/keymaps")
491 (string-append kbd "/share/keymaps")))
492 #t)))
493 (replace 'install
494 (lambda* (#:key outputs #:allow-other-keys)
495 ;; Install 'localed', the D-Bus and polkit files, and
496 ;; 'localectl'.
497 (let* ((out (assoc-ref outputs "out"))
498 (libexec (string-append out "/libexec/localed"))
499 (bin (string-append out "/bin"))
500 (lib (string-append out "/lib"))
501 (dbus (string-append out
502 "/share/dbus-1/system-services"))
503 (conf (string-append out
504 "/etc/dbus-1/system.d/"))
505 (polkit (string-append out
506 "/share/polkit-1/actions"))
507 (data (string-append out "/share/systemd")))
508 (define (source-file regexp)
509 (car (find-files ".." regexp)))
510
511 (mkdir-p libexec)
512 (copy-file "systemd-localed"
513 (string-append libexec "/localed"))
514 (install-file "localectl" bin)
515
516 (let ((service-file (source-file
517 "\\.locale1\\.service$")))
518 (substitute* service-file
519 (("^Exec=.*$")
520 (string-append "Exec=" libexec "/localed\n")))
521 (install-file service-file dbus))
522 (install-file (source-file "\\.locale1\\.policy$")
523 polkit)
524 (install-file (source-file "\\.locale1\\.conf$")
525 conf)
526 (for-each (lambda (file)
527 (install-file file lib))
528 (find-files "src/shared"
529 "libsystemd-shared.*\\.so"))
530
531 (for-each (lambda (map)
532 (install-file map data))
533 (find-files ".." "^(kbd-model-map|language-fallback-map)$"))
534 #t)))))))
535 (native-inputs (package-native-inputs elogind))
536 (inputs `(("libmount" ,util-linux "lib")
537 ("xkeyboard-config" ,xkeyboard-config)
538 ("kbd" ,kbd)
539 ,@(package-inputs elogind)))
540 (home-page "https://www.freedesktop.org/wiki/Software/systemd/localed/")
541 (synopsis "Control the system locale and keyboard layout")
542 (description
543 "Localed is a tiny daemon that can be used to control the system locale
544 and keyboard mapping from user programs. It is used among other things by the
545 GNOME Shell. The @command{localectl} command-line tool allows you to interact
546 with localed. This package is extracted from the broader systemd package.")
547 (license license:lgpl2.1+)))
548
549 (define-public packagekit
550 (package
551 (name "packagekit")
552 (version "1.1.13")
553 (source (origin
554 (method url-fetch)
555 (uri (string-append
556 "https://www.freedesktop.org/software/"
557 "PackageKit/releases/"
558 "PackageKit-" version ".tar.xz"))
559 (sha256
560 (base32
561 "1dr1laic65ld95abp2yxbwvijnngh0dwyb1x49x4wjm5rhq43dl8"))))
562 (build-system gnu-build-system)
563 (arguments
564 `(#:tests? #f
565 #:make-flags (list (string-append "BASH_COMPLETIONS_DIR="
566 %output "/etc/bash_completion.d"))
567 #:configure-flags
568 '("--disable-systemd")))
569 (native-inputs
570 `(("intltool" ,intltool)
571 ("pkg-config" ,pkg-config)
572 ("python" ,python-wrapper)
573 ("glib:bin" ,glib "bin")))
574 (inputs
575 `(("glib" ,glib)
576 ("bash-completion" ,bash-completion)
577 ("polkit" ,polkit)))
578 (propagated-inputs
579 `(("sqlite" ,sqlite)))
580 (home-page "https://www.freedesktop.org/software/PackageKit/")
581 (synopsis "API for package management, through D-Bus")
582 (description
583 "PackageKit provides a way of performing package management tasks,
584 e.g. updating, removing and installing software. Through supporting many
585 backends, PackageKit can perform these tasks using the appropriate package
586 manager for the current system.")
587 (license license:gpl2+)))
588
589 (define-public python-pyxdg
590 (package
591 (name "python-pyxdg")
592 (version "0.25")
593 (source
594 (origin
595 (method url-fetch)
596 (uri (pypi-uri "pyxdg" version))
597 (sha256
598 (base32
599 "179767h8m634ydlm4v8lnz01ba42gckfp684id764zaip7h87s41"))))
600 (build-system python-build-system)
601 (arguments
602 '(#:phases
603 (modify-phases %standard-phases
604 (replace 'check
605 (lambda* (#:key inputs #:allow-other-keys)
606 (setenv "XDG_DATA_DIRS"
607 (string-append (assoc-ref inputs "shared-mime-info")
608 "/share/"))
609 (substitute* "test/test-icon.py"
610 (("/usr/share/icons/hicolor/index.theme")
611 (string-append (assoc-ref inputs "hicolor-icon-theme")
612 "/share/icons/hicolor/index.theme"))
613 ;; FIXME: This test fails because the theme contains the unknown
614 ;; key "Scale".
615 (("theme.validate\\(\\)") "#"))
616
617 ;; One test fails with:
618 ;; AssertionError: 'x-apple-ios-png' != 'png'
619 (substitute* "test/test-mime.py"
620 (("self.check_mimetype\\(imgpng, 'image', 'png'\\)") "#"))
621 (invoke "nosetests" "-v"))))))
622 (native-inputs
623 ;; For tests.
624 `(("shared-mime-info" ,shared-mime-info)
625 ("hicolor-icon-theme" ,hicolor-icon-theme)
626 ("python-nose" ,python-nose)))
627 (home-page "https://www.freedesktop.org/wiki/Software/pyxdg")
628 (synopsis "Implementations of freedesktop.org standards in Python")
629 (description
630 "PyXDG is a collection of implementations of freedesktop.org standards in
631 Python.")
632 (license license:lgpl2.0)))
633
634 (define-public python2-pyxdg
635 (package-with-python2 python-pyxdg))
636
637 (define-public wayland
638 (package
639 (name "wayland")
640 (version "1.17.0")
641 (source (origin
642 (method url-fetch)
643 (uri (string-append "https://wayland.freedesktop.org/releases/"
644 name "-" version ".tar.xz"))
645 (sha256
646 (base32
647 "194ibzwpdcn6fvk4xngr4bf5axpciwg2bj82fdvz88kfmjw13akj"))))
648 (build-system gnu-build-system)
649 (arguments
650 `(#:parallel-tests? #f))
651 (native-inputs
652 `(("doxygen" ,doxygen)
653 ("graphviz" ,graphviz)
654 ("pkg-config" ,pkg-config)
655 ("xmlto" ,xmlto)
656 ("xsltproc" ,libxslt)))
657 (inputs
658 `(("docbook-xml" ,docbook-xml)
659 ("docbook-xsl" ,docbook-xsl)
660 ("expat" ,expat)
661 ("libffi" ,libffi)
662 ("libxml2" ,libxml2))) ; for XML_CATALOG_FILES
663 (home-page "https://wayland.freedesktop.org/")
664 (synopsis "Display server protocol")
665 (description
666 "Wayland is a protocol for a compositor to talk to its clients as well as
667 a C library implementation of that protocol. The compositor can be a standalone
668 display server running on Linux kernel modesetting and evdev input devices, an X
669 application, or a wayland client itself. The clients can be traditional
670 applications, X servers (rootless or fullscreen) or other display servers.")
671 (license license:x11)))
672
673 (define-public wayland-protocols
674 (package
675 (name "wayland-protocols")
676 (version "1.18")
677 (source (origin
678 (method url-fetch)
679 (uri (string-append
680 "https://wayland.freedesktop.org/releases/"
681 "wayland-protocols-" version ".tar.xz"))
682 (sha256
683 (base32
684 "1cvl93h83ymbfhb567jv5gzyq08181w7c46rsw4xqqqpcvkvfwrx"))))
685 (build-system gnu-build-system)
686 (inputs
687 `(("wayland" ,wayland)))
688 (native-inputs
689 `(("pkg-config" ,pkg-config)))
690 (synopsis "Wayland protocols")
691 (description "This package contains XML definitions of the Wayland protocols.")
692 (home-page "https://wayland.freedesktop.org")
693 (license license:expat)))
694
695 (define-public waylandpp
696 (package
697 (name "waylandpp")
698 (version "0.2.7")
699 (home-page "https://github.com/NilsBrause/waylandpp")
700 (source (origin
701 (method git-fetch)
702 (uri (git-reference (url home-page) (commit version)))
703 (file-name (git-file-name name version))
704 (sha256
705 (base32
706 "1r4m0xhvwpcqxrqvp3hz1bzlkxqj2jiymd5r6hj8xjzz536hyprz"))))
707 (build-system cmake-build-system)
708 (arguments
709 `(#:tests? #f)) ;no tests
710 (native-inputs
711 `(("pkg-config" ,pkg-config)))
712 (inputs
713 `(("mesa" ,mesa)
714 ("pugixml" ,pugixml)))
715 (propagated-inputs
716 `(;; In Requires of the .pc files.
717 ("wayland" ,wayland)))
718 (synopsis "Wayland C++ bindings")
719 (description
720 "This package provides C++ bindings for the Wayland display protocol.")
721 (license license:bsd-2)))
722
723 (define-public weston
724 (package
725 (name "weston")
726 (version "6.0.1")
727 (source (origin
728 (method url-fetch)
729 (uri (string-append
730 "https://wayland.freedesktop.org/releases/"
731 "weston-" version ".tar.xz"))
732 (sha256
733 (base32
734 "1d2m658ll8x7prlsfk71qgw89c7dz6y7d6nndfxwl49fmrd6sbxz"))))
735 (build-system meson-build-system)
736 (native-inputs
737 `(("pkg-config" ,pkg-config)
738 ("xorg-server" ,xorg-server)))
739 (inputs
740 `(("cairo" ,cairo-xcb)
741 ("colord" ,colord)
742 ("dbus" ,dbus)
743 ("elogind" ,elogind)
744 ("lcms" ,lcms)
745 ("libevdev" ,libevdev)
746 ("libinput" ,libinput-minimal)
747 ("libjpeg" ,libjpeg-turbo)
748 ("libunwind" ,libunwind)
749 ("libva" ,libva)
750 ("libwebp" ,libwebp)
751 ("libxcursor" ,libxcursor)
752 ("libxkbcommon" ,libxkbcommon)
753 ("libxml2" ,libxml2)
754 ("mesa" ,mesa)
755 ("mtdev" ,mtdev)
756 ("linux-pam" ,linux-pam)
757 ("pango" ,pango)
758 ("wayland" ,wayland)
759 ("wayland-protocols" ,wayland-protocols)
760 ("xorg-server-xwayland" ,xorg-server-xwayland)))
761 (arguments
762 `(#:configure-flags
763 (list "-Dbackend-rdp=false" ; TODO: Enable.
764 "-Dremoting=false" ; TODO: Enable.
765 "-Dsimple-dmabuf-drm=auto"
766 "-Dsystemd=false"
767 (string-append "-Dxwayland-path="
768 (assoc-ref %build-inputs "xorg-server-xwayland")
769 "/bin/Xwayland"))
770 #:parallel-tests? #f ; Parallel tests cause failures.
771 #:phases
772 (modify-phases %standard-phases
773 (add-before 'configure 'use-elogind
774 (lambda _
775 ;; Use elogind instead of systemd
776 (substitute* "libweston/meson.build"
777 (("libsystemd-login") "libelogind"))
778 (substitute* '("libweston/launcher-logind.c"
779 "libweston/weston-launch.c")
780 (("#include <systemd/sd-login.h>")
781 "#include <elogind/sd-login.h>"))
782 #t))
783 (add-after 'configure 'patch-confdefs.h
784 (lambda _
785 (system "echo \"#define HAVE_SYSTEMD_LOGIN_209 1\" >> confdefs.h")
786 #t))
787 (add-before 'check 'setup
788 (lambda _
789 (setenv "HOME" (getcwd))
790 (setenv "XDG_RUNTIME_DIR" (getcwd))
791 #t))
792 (add-before 'check 'start-xorg-server
793 (lambda* (#:key inputs #:allow-other-keys)
794 ;; The test suite requires a running X server.
795 (system (string-append (assoc-ref inputs "xorg-server")
796 "/bin/Xvfb :1 &"))
797 (setenv "DISPLAY" ":1")
798 #t)))))
799 (home-page "https://wayland.freedesktop.org")
800 (synopsis "Reference implementation of a Wayland compositor")
801 (description "Weston is the reference implementation of a Wayland
802 compositor, and a useful compositor in its own right.
803
804 A Wayland compositor allows applications to render to a shared offscreen
805 buffer using OpenGL ES. The compositor then culls the hidden parts and
806 composes the final output. A Wayland compositor is essentially a
807 multiplexer to the KMS/DRM Linux kernel devices.")
808 (license license:expat)))
809
810 (define-public wev
811 ;; There simple tool has no version or release yet.
812 (let ((commit "cee3dfb2a8b40ee303611018c68ae182d84a7f46"))
813 (package
814 (name "wev")
815 (version (string-append "2020-02-06-" (string-take commit 8)))
816 (source (origin
817 (method git-fetch)
818 (uri (git-reference
819 (url "https://git.sr.ht/~sircmpwn/wev")
820 (commit commit)))
821 (file-name (git-file-name name version))
822 (sha256
823 (base32
824 "0l71v3fzgiiv6xkk365q1l08qvaymxd4kpaya6r2g8yzkr7i2hms"))))
825 (build-system gnu-build-system)
826 (arguments
827 `(#:tests? #f ; no tests
828 #:make-flags
829 (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))
830 #:phases
831 (modify-phases %standard-phases
832 (delete 'configure))))
833 (native-inputs
834 `(("pkg-config" ,pkg-config)
835 ("scdoc" ,scdoc)))
836 (inputs
837 `(("libxkbcommon" ,libxkbcommon)
838 ("wayland" ,wayland)
839 ("wayland-protocols" ,wayland-protocols)))
840 (home-page "https://git.sr.ht/~sircmpwn/wev")
841 (synopsis "Wayland event viewer")
842 (description "Wev is a tool that opens a window, printing all events
843 sent to a Wayland window, such as key presses. It is analogous to the X11 tool
844 XEv.")
845 (license license:expat))))
846
847 (define-public exempi
848 (package
849 (name "exempi")
850 (version "2.5.1")
851 (source (origin
852 (method url-fetch)
853 (uri (string-append
854 "https://libopenraw.freedesktop.org/download/"
855 name "-" version ".tar.bz2"))
856 (sha256
857 (base32
858 "1j4vx054l1c2cggw4aka4iw48jkcf68qk5y064pbqw1k3ddks2qh"))))
859 (build-system gnu-build-system)
860 (arguments
861 `(#:configure-flags (list (string-append "--with-boost="
862 (assoc-ref %build-inputs "boost")))))
863 (native-inputs
864 `(("boost" ,boost))) ; tests
865 (inputs
866 `(("expat" ,expat)
867 ("zlib" ,zlib)))
868 (home-page "https://libopenraw.freedesktop.org/exempi/")
869 (synopsis "XMP metadata handling library")
870 (description "Exempi is an implementation of the Extensible Metadata
871 Platform (@dfn{XMP}), which enables embedding metadata in PDF and image
872 formats.")
873 (license license:bsd-3)))
874
875 (define-public libatasmart
876 (package
877 (name "libatasmart")
878 (version "0.19")
879 (source (origin
880 (method url-fetch)
881 (uri (string-append "http://0pointer.de/public/"
882 name "-" version ".tar.xz"))
883 (sha256
884 (base32
885 "138gvgdwk6h4ljrjsr09pxk1nrki4b155hqdzyr8mlk3bwsfmw31"))))
886 (build-system gnu-build-system)
887 (native-inputs
888 `(("pkg-config" ,pkg-config)))
889 (inputs
890 `(("udev" ,eudev)))
891 (home-page "http://0pointer.de/blog/projects/being-smart.html")
892 (synopsis "ATA S.M.A.R.T. reading and parsing library")
893 (description
894 "This library supports a subset of the ATA S.M.A.R.T. (Self-Monitoring,
895 Analysis and Reporting Technology) functionality.")
896 (license license:lgpl2.1+)))
897
898 (define-public udisks
899 (package
900 (name "udisks")
901 (version "2.8.4")
902 (source (origin
903 (method url-fetch)
904 (uri (string-append
905 "https://github.com/storaged-project/udisks/releases/download/udisks-"
906 version "/udisks-" version ".tar.bz2"))
907 (sha256
908 (base32
909 "06cq52kp1nyy15qzylywy9s7hhhqc45k0s3y68crf0zsmjyng0yj"))))
910 (build-system gnu-build-system)
911 (native-inputs
912 `(("docbook-xml" ,docbook-xml-4.3) ; to build the manpages
913 ("docbook-xsl" ,docbook-xsl)
914 ("glib:bin" ,glib "bin") ; for glib-mkenums
915 ("gnome-common" ,gnome-common) ; TODO: Why is this needed?
916 ("gobject-introspection" ,gobject-introspection)
917 ("gtk-doc" ,gtk-doc)
918 ("intltool" ,intltool)
919 ("pkg-config" ,pkg-config)
920 ("xsltproc" ,libxslt)))
921 (propagated-inputs
922 `(("glib" ,glib))) ; required by udisks2.pc
923 (inputs
924 `(("acl" ,acl)
925 ("cryptsetup" ,cryptsetup)
926 ("libatasmart" ,libatasmart)
927 ("libblockdev" ,libblockdev)
928 ("libgudev" ,libgudev)
929 ("polkit" ,polkit)
930 ("util-linux" ,util-linux)))
931 (outputs '("out"
932 "doc")) ;5 MiB of gtk-doc HTML
933 (arguments
934 `(#:tests? #f ; requiring system message dbus
935 #:disallowed-references ("doc") ;enforce separation of "doc"
936 #:configure-flags
937 (list "--enable-man"
938 "--enable-available-modules" ; Such as lvm2, btrfs, etc.
939 "--localstatedir=/var"
940 "--enable-fhs-media" ;mount devices in /media, not /run/media
941 (string-append "--with-html-dir="
942 (assoc-ref %outputs "doc")
943 "/share/doc/udisks/html")
944 (string-append "--with-udevdir=" %output "/lib/udev"))
945 #:make-flags
946 (let* ((docbook-xsl-name-version ,(string-append
947 (package-name docbook-xsl) "-"
948 (package-version docbook-xsl)))
949 (docbook-xsl-catalog-file (string-append
950 (assoc-ref %build-inputs "docbook-xsl")
951 "/xml/xsl/"
952 docbook-xsl-name-version
953 "/catalog.xml"))
954 (docbook-xml-catalog-file (string-append
955 (assoc-ref %build-inputs "docbook-xml")
956 "/xml/dtd/docbook/catalog.xml")))
957 ;; Reference the catalog files required to build the manpages.
958 (list (string-append "XML_CATALOG_FILES=" docbook-xsl-catalog-file " "
959 docbook-xml-catalog-file)))
960 #:phases
961 (modify-phases %standard-phases
962 (add-before
963 'configure 'fix-girdir
964 (lambda _
965 ;; Install introspection data to its own output.
966 (substitute* "udisks/Makefile.in"
967 (("girdir = .*")
968 "girdir = $(datadir)/gir-1.0\n")
969 (("typelibsdir = .*")
970 "typelibsdir = $(libdir)/girepository-1.0\n"))))
971 (add-after 'install 'wrap-udisksd
972 (lambda* (#:key outputs inputs #:allow-other-keys)
973 ;; Tell 'udisksd' where to find the 'mount' command.
974 (let ((out (assoc-ref outputs "out"))
975 (utils (assoc-ref inputs "util-linux"))
976 (cryptsetup (assoc-ref inputs "cryptsetup"))
977 (parted (assoc-ref inputs "parted")))
978 (wrap-program (string-append out "/libexec/udisks2/udisksd")
979 `("PATH" ":" prefix
980 (,(string-append utils "/bin") ;for 'mount'
981 ;; cryptsetup is required for setting encrypted
982 ;; partitions, e.g. in gnome-disks
983 ,(string-append cryptsetup "/sbin")
984 "/run/current-system/profile/bin"
985 "/run/current-system/profile/sbin")))
986 #t))))))
987 (home-page "https://www.freedesktop.org/wiki/Software/udisks/")
988 (synopsis "Disk manager service")
989 (description
990 "UDisks provides interfaces to enumerate and perform operations on disks
991 and storage devices. Any application (including unprivileged ones) can access
992 the udisksd(8) daemon via the name org.freedesktop.UDisks2 on the system
993 message bus.")
994 ;; The dynamic library are under LGPLv2+, others are GPLv2+.
995 (license (list license:gpl2+ license:lgpl2.0+))))
996
997 (define-public accountsservice
998 (package
999 (name "accountsservice")
1000 (version "0.6.50")
1001 (source
1002 (origin
1003 (method url-fetch)
1004 (uri (string-append "https://www.freedesktop.org/software/"
1005 "accountsservice/accountsservice-" version ".tar.xz"))
1006 (sha256
1007 (base32 "0jn7vg1z4vxnna0hl33hbcb4bb3zpilxc2vyclh24vx4vvsjhn83"))))
1008 (build-system gnu-build-system)
1009 (arguments
1010 '(#:tests? #f ; XXX: tests require DocBook 4.1.2
1011 #:configure-flags
1012 '("--localstatedir=/var"
1013 "--disable-systemd"
1014 "--enable-elogind")
1015 #:phases
1016 (modify-phases %standard-phases
1017 (add-after 'unpack 'patch-/bin/cat
1018 (lambda _
1019 (substitute* "src/user.c"
1020 (("/bin/cat") (which "cat")))
1021 #t))
1022 (add-before
1023 'configure 'pre-configure
1024 (lambda* (#:key inputs #:allow-other-keys)
1025 ;; Don't try to create /var/lib/AccountsService.
1026 (substitute* "src/Makefile.in"
1027 (("\\$\\(MKDIR_P\\).*/lib/AccountsService.*") "true"))
1028 (let ((shadow (assoc-ref inputs "shadow")))
1029 (substitute* '("src/user.c" "src/daemon.c")
1030 (("/usr/sbin/usermod") (string-append shadow "/sbin/usermod"))
1031 (("/usr/sbin/useradd") (string-append shadow "/sbin/useradd"))
1032 (("/usr/sbin/userdel") (string-append shadow "/sbin/userdel"))
1033 (("/usr/bin/passwd") (string-append shadow "/bin/passwd"))
1034 (("/usr/bin/chage") (string-append shadow "/bin/chage"))))
1035 #t)))))
1036 (native-inputs
1037 `(("glib:bin" ,glib "bin") ; for gdbus-codegen, etc.
1038 ("gobject-introspection" ,gobject-introspection)
1039 ("intltool" ,intltool)
1040 ("pkg-config" ,pkg-config)))
1041 (inputs
1042 `(("elogind" ,elogind)
1043 ("polkit" ,polkit)
1044 ("shadow" ,shadow)))
1045 (home-page "https://www.freedesktop.org/wiki/Software/AccountsService/")
1046 (synopsis "D-Bus interface for user account query and manipulation")
1047 (description
1048 "The AccountService project provides a set of D-Bus interfaces for querying
1049 and manipulating user account information and an implementation of these
1050 interfaces, based on the useradd, usermod and userdel commands.")
1051 (license license:gpl3+)))
1052
1053 (define-public libmbim
1054 (package
1055 (name "libmbim")
1056 (version "1.20.2")
1057 (source (origin
1058 (method url-fetch)
1059 (uri (string-append
1060 "https://www.freedesktop.org/software/libmbim/"
1061 "libmbim-" version ".tar.xz"))
1062 (sha256
1063 (base32
1064 "16q550sy84izi5ic3sbbhjnnka2fwhj8vvdrirpn9xspbsgbc3sm"))))
1065 (build-system gnu-build-system)
1066 (native-inputs
1067 `(("glib:bin" ,glib "bin") ; for glib-mkenums
1068 ("pkg-config" ,pkg-config)
1069 ("python" ,python-wrapper)))
1070 (propagated-inputs
1071 `(("glib" ,glib))) ; required by mbim-glib.pc
1072 (inputs
1073 `(("libgudev" ,libgudev)))
1074 (synopsis "Library to communicate with MBIM-powered modems")
1075 (home-page "https://www.freedesktop.org/wiki/Software/libmbim/")
1076 (description
1077 "Libmbim is a GLib-based library for talking to WWAN modems and devices
1078 which speak the Mobile Interface Broadband Model (MBIM) protocol.")
1079 (license
1080 ;; The libmbim-glib library is released under the LGPLv2+ license.
1081 ;; The mbimcli tool is released under the GPLv2+ license.
1082 (list license:lgpl2.0+ license:gpl2+))))
1083
1084 (define-public libqmi
1085 (package
1086 (name "libqmi")
1087 (version "1.24.14")
1088 (source (origin
1089 (method url-fetch)
1090 (uri (string-append
1091 "https://www.freedesktop.org/software/libqmi/"
1092 "libqmi-" version ".tar.xz"))
1093 (sha256
1094 (base32
1095 "0zshxqbm9ldybgrzh7pjmwmfjvvvfd0xh8qhgl8xiqdb9ply73r0"))))
1096 (build-system gnu-build-system)
1097 (inputs
1098 `(("libgudev" ,libgudev)))
1099 (native-inputs
1100 `(("glib:bin" ,glib "bin") ; for glib-mkenums
1101 ("pkg-config" ,pkg-config)
1102 ("python" ,python-wrapper)))
1103 (propagated-inputs
1104 `(("glib" ,glib))) ; required by qmi-glib.pc
1105 (synopsis "Library to communicate with QMI-powered modems")
1106 (home-page "https://www.freedesktop.org/wiki/Software/libqmi/")
1107 (description
1108 "Libqmi is a GLib-based library for talking to WWAN modems and devices
1109 which speak the Qualcomm MSM Interface (QMI) protocol.")
1110 (license
1111 ;; The libqmi-glib library is released under the LGPLv2+ license.
1112 ;; The qmicli tool is released under the GPLv2+ license.
1113 (list license:lgpl2.0+ license:gpl2+))))
1114
1115 (define-public modem-manager
1116 (package
1117 (name "modem-manager")
1118 (version "1.12.10")
1119 (source (origin
1120 (method url-fetch)
1121 (uri (string-append
1122 "https://www.freedesktop.org/software/ModemManager/"
1123 "ModemManager-" version ".tar.xz"))
1124 (sha256
1125 (base32
1126 "1apq9camys2gaw6y6ic1ld20cncfwpmxnzvh4j5zkbbjpf5hbcxj"))))
1127 (build-system gnu-build-system)
1128 (arguments
1129 '(#:configure-flags
1130 `(,(string-append "--with-udev-base-dir=" %output "/lib/udev"))))
1131 (native-inputs
1132 `(("glib:bin" ,glib "bin") ; for glib-mkenums
1133 ("gobject-introspection" ,gobject-introspection)
1134 ("intltool" ,intltool)
1135 ("pkg-config" ,pkg-config)
1136 ("vala" ,vala)
1137 ;; For testing.
1138 ("dbus" ,dbus)))
1139 (propagated-inputs
1140 `(("glib" ,glib))) ; required by mm-glib.pc
1141 (inputs
1142 `(("libgudev" ,libgudev)
1143 ("libmbim" ,libmbim)
1144 ("libqmi" ,libqmi)
1145 ("polkit" ,polkit)))
1146 (synopsis "Mobile broadband modems manager")
1147 (home-page "https://www.freedesktop.org/wiki/Software/ModemManager/")
1148 (description
1149 "ModemManager is a DBus-activated daemon which controls mobile
1150 broadband (2G/3G/4G) devices and connections. Whether built-in devices, USB
1151 dongles, bluetooth-paired telephones, or professional RS232/USB devices with
1152 external power supplies, ModemManager is able to prepare and configure the
1153 modems and setup connections with them.")
1154 (license license:gpl2+)))
1155
1156 (define-public telepathy-logger
1157 (package
1158 (name "telepathy-logger")
1159 (version "0.8.2")
1160 (source (origin
1161 (method url-fetch)
1162 (uri (string-append "https://telepathy.freedesktop.org/releases/"
1163 name "/" name "-" version ".tar.bz2"))
1164 (sha256
1165 (base32
1166 "1bjx85k7jyfi5pvl765fzc7q2iz9va51anrc2djv7caksqsdbjlg"))))
1167 (build-system gnu-build-system)
1168 (arguments
1169 '(#:parallel-tests? #f
1170 #:phases
1171 (modify-phases %standard-phases
1172 (add-before 'check 'pre-check
1173 (lambda _
1174 (setenv "HOME" (getenv "TMPDIR"))
1175 #t)))))
1176 (native-inputs
1177 `(("glib:bin" ,glib "bin") ; for glib-genmarshal, etc.
1178 ("gobject-introspection" ,gobject-introspection)
1179 ("intltool" ,intltool)
1180 ("pkg-config" ,pkg-config)
1181 ("python" ,python-2)
1182 ("xsltproc" ,libxslt)))
1183 (propagated-inputs
1184 ;; telepathy-logger-0.2.pc refers to all these.
1185 `(("libxml2" ,libxml2)
1186 ("sqlite" ,sqlite)
1187 ("telepathy-glib" ,telepathy-glib)))
1188 (synopsis "Telepathy logger library")
1189 (home-page "https://telepathy.freedesktop.org/")
1190 (description
1191 "Telepathy logger is a headless observer client that logs information
1192 received by the Telepathy framework. It features pluggable backends to log
1193 different sorts of messages in different formats.")
1194 (license license:lgpl2.1+)))
1195
1196 (define-public telepathy-idle
1197 (package
1198 (name "telepathy-idle")
1199 (version "0.2.0")
1200 (source (origin
1201 (method url-fetch)
1202 (uri (string-append "https://telepathy.freedesktop.org/releases/"
1203 name "/" name "-" version ".tar.bz2"))
1204 (sha256
1205 (base32
1206 "1argdzbif1vdmwp5vqbgkadq9ancjmgdm2ncp0qfckni715ss4rh"))))
1207 (build-system gnu-build-system)
1208 (native-inputs
1209 `(("pkg-config" ,pkg-config)))
1210 (inputs
1211 `(("xsltproc" ,libxslt)
1212 ("python" ,python-2)
1213 ("python-dbus" ,python2-dbus)))
1214 (propagated-inputs
1215 `(("telepathy-glib" ,telepathy-glib)))
1216 (home-page "https://telepathy.freedesktop.org/")
1217 (synopsis "Telepathy IRC connection manager")
1218 (description
1219 "Idle is an IRC connection manager for the Telepathy framework. This
1220 package enables usage of IRC channels and private messages in Telepathy instant
1221 messaging clients such as Empathy, GNOME Shell or KDE Telepathy.")
1222 (license (list license:lgpl2.1 license:lgpl2.1+))))
1223
1224 (define-public telepathy-mission-control
1225 (package
1226 (name "telepathy-mission-control")
1227 (version "5.16.5")
1228 (source
1229 (origin
1230 (method url-fetch)
1231 (uri (string-append "https://telepathy.freedesktop.org/releases/"
1232 "telepathy-mission-control/"
1233 "telepathy-mission-control-" version ".tar.gz"))
1234 (sha256
1235 (base32 "00xxv38cfdirnfvgyd56m60j0nkmsv5fz6p2ydyzsychicxl6ssc"))))
1236 (build-system gnu-build-system)
1237 (native-inputs
1238 `(("glib:bin" ,glib "bin") ; for glib-compile-schemas, etc.
1239 ("pkg-config" ,pkg-config)))
1240 (inputs
1241 `(("dconf" ,dconf)
1242 ("gtk-doc" ,gtk-doc)
1243 ("libgnome-keyring" ,libgnome-keyring)
1244 ("python" ,python-2)
1245 ("xsltproc" ,libxslt)))
1246 (propagated-inputs
1247 `(("telepathy-glib" ,telepathy-glib)))
1248 (home-page "https://telepathy.freedesktop.org/wiki/Components/Mission_Control/")
1249 (synopsis "Telepathy real-time communication framework management daemon")
1250 (description
1251 "Telepathy Mission Control 5 is an account manager and channel dispatcher
1252 for the Telepathy framework, allowing user interfaces and other clients to
1253 share connections to real-time communication services without conflicting.")
1254 (license license:lgpl2.1)))
1255
1256 (define-public colord-gtk
1257 (package
1258 (name "colord-gtk")
1259 (version "0.1.26")
1260 (source (origin
1261 (method url-fetch)
1262 (uri (string-append "https://www.freedesktop.org/software/colord"
1263 "/releases/" name "-" version ".tar.xz"))
1264 (sha256
1265 (base32
1266 "0i9y3bb5apj6a0f8cx36l6mjzs7xc0k7nf0magmf58vy2mzhpl18"))))
1267 (build-system gnu-build-system)
1268 (arguments '(#:tests? #f)) ; require the colord system service
1269 (native-inputs
1270 `(("gobject-introspection" ,gobject-introspection)
1271 ("intltool" ,intltool)
1272 ("pkg-config" ,pkg-config)
1273 ("vala" ,vala)))
1274 (propagated-inputs
1275 ;; colord-gtk.pc refers to all these.
1276 `(("colord" ,colord)
1277 ("gtk+" ,gtk+)))
1278 (synopsis "GTK integration for libcolord")
1279 (home-page "https://www.freedesktop.org/software/colord/")
1280 (description
1281 "This is a GTK+ convenience library for interacting with colord. It is
1282 useful for both applications which need colour management and applications that
1283 wish to perform colour calibration.")
1284 (license license:lgpl2.1+)))
1285
1286 (define-public libfprint
1287 (package
1288 (name "libfprint")
1289 (version "1.90.1")
1290 (source
1291 (origin
1292 (method git-fetch)
1293 (uri (git-reference
1294 (url "https://gitlab.freedesktop.org/libfprint/libfprint")
1295 (commit (string-append "v" version))))
1296 (file-name (git-file-name name version))
1297 (sha256
1298 (base32 "0fdaak7qjr9b4482g7fhhqpyfdqpxq5kpmyzkp7f5i7qq2ynb78a"))))
1299 (build-system meson-build-system)
1300 (arguments
1301 '(#:configure-flags
1302 (list (string-append "-Dudev_rules_dir=" (assoc-ref %outputs "out")
1303 "/lib/udev/rules.d"))))
1304 (native-inputs
1305 `(("eudev" ,eudev)
1306 ("glib:bin" ,glib "bin") ; for {glib-,}mkenums
1307 ("gobject-introspection" ,gobject-introspection)
1308 ("gtk-doc" ,gtk-doc) ; for 88 KiB of API documentation
1309 ("pkg-config" ,pkg-config)))
1310 (inputs
1311 `(("glib" ,glib)
1312 ("gusb" ,gusb)
1313 ("nss" ,nss) ; for the URU4x00 driver
1314
1315 ;; Replacing this with cairo works but just results in a reference
1316 ;; (only) to pixman in the end.
1317 ("pixman" ,pixman)))
1318 (home-page "https://fprint.freedesktop.org/")
1319 (synopsis "Library to access fingerprint readers")
1320 (description
1321 "libfprint is a library designed to make it easy for application
1322 developers to add support for consumer fingerprint readers to their
1323 software.")
1324 (license license:lgpl2.1+)))
1325
1326 (define-public fprintd
1327 (package
1328 (name "fprintd")
1329 (version "1.90.1")
1330 (source
1331 (origin
1332 (method git-fetch)
1333 (uri (git-reference
1334 (url "https://gitlab.freedesktop.org/libfprint/fprintd")
1335 (commit version)))
1336 (file-name (git-file-name name version))
1337 (sha256
1338 (base32 "0mbzk263x7f58i9cxhs44mrngs7zw5wkm62j5r6xlcidhmfn03cg"))))
1339 (build-system meson-build-system)
1340 (arguments
1341 `(#:configure-flags
1342 (list "-Dsystemd_system_unit_dir=/tmp"
1343 (string-append "-Ddbus_service_dir=" (assoc-ref %outputs "out")
1344 "/share/dbus-1/system-services")
1345 (string-append "-Dpam_modules_dir=" (assoc-ref %outputs "out")
1346 "/lib/security"))
1347 #:phases
1348 (modify-phases %standard-phases
1349 (add-before 'configure 'patch-output-directories
1350 ;; Install files to our output, not that of the ‘owner’ package.
1351 ;; These are not exposed as Meson options and must be patched.
1352 (lambda* (#:key outputs #:allow-other-keys)
1353 (let ((out (assoc-ref outputs "out")))
1354 (substitute* "meson.build"
1355 (("(dbus_interfaces_dir = ).*" _ set)
1356 (string-append set "'" out "/share/dbus-1/interfaces'\n"))
1357 (("(polkit_policy_directory = ).*" _ set)
1358 (string-append set "'" out "/share/polkit-1/actions/'\n"))
1359 (("(dbus_data_dir = ).*" _ set)
1360 (string-append set "get_option('prefix')"
1361 " / get_option('datadir')\n")))
1362 #t)))
1363 (add-before 'configure 'patch-mistake
1364 (lambda _
1365 (substitute* "meson.build"
1366 (("(storage_path = )(get_option\\('prefix'\\))(.*)"
1367 _ set mistake value)
1368 (string-append set "''" value "\n")))
1369 #t))
1370 (add-before 'configure 'patch-systemd-dependencies
1371 (lambda _
1372 (substitute* "meson.build"
1373 (("'(libsystemd|systemd)'") "'libelogind'"))
1374 #t))
1375 (add-before 'configure 'ignore-test-dependencies
1376 (lambda _
1377 (substitute* "meson.build"
1378 (("pam_wrapper_dep .*") "")
1379 ((".*'(cairo|dbus|dbusmock|gi|pypamtest)': .*,.*") ""))
1380 #t))
1381 (add-before 'install 'no-polkit-magic
1382 ;; Meson ‘magically’ invokes pkexec, which fails (not setuid).
1383 (lambda _
1384 (setenv "PKEXEC_UID" "something")
1385 #t)))
1386 #:tests? #f)) ; XXX depend on unpackaged packages
1387 (native-inputs
1388 `(("gettext" ,gettext-minimal)
1389 ("glib:bin" ,glib "bin") ; for glib-genmarshal
1390 ("libxslt" ,libxslt) ; for xsltproc
1391 ("perl" ,perl) ; for pod2man
1392 ("pkg-config" ,pkg-config)))
1393 ;; For tests.
1394 ;;("pam_wrapper" ,pam_wrapper)
1395 ;;("python-pycairo" ,python-pycairo)
1396 ;;("python-dbus" ,python-dbus)
1397 ;;("python-dbusmock" ,python-dbusmock)
1398 ;;("python-pygobject" ,python-pygobject)
1399 ;;("python-pypamtest" ,python-pypamtest)
1400 (inputs
1401 `(("dbus-glib" ,dbus-glib)
1402 ("elogind" ,elogind)
1403 ("libfprint" ,libfprint)
1404 ("linux-pam" ,linux-pam)
1405 ("polkit" ,polkit)
1406
1407 ;; XXX These are in libfprint's Requires.private. Meson refuses to grant
1408 ;; the ‘libfprint-2’ dependency if they are not provided here.
1409 ("gusb" ,gusb)
1410 ("nss" ,nss)
1411 ("pixman" ,pixman)))
1412 (home-page "https://fprint.freedesktop.org/")
1413 (synopsis "D-Bus daemon that exposes fingerprint reader functionality")
1414 (description
1415 "fprintd is a D-Bus daemon that offers functionality of libfprint, a
1416 library to access fingerprint readers, over the D-Bus interprocess
1417 communication bus. This daemon layer above libfprint solves problems related
1418 to applications simultaneously competing for fingerprint readers.")
1419 (license license:gpl2+)))
1420
1421 (define-public desktop-file-utils
1422 (package
1423 (name "desktop-file-utils")
1424 (version "0.24")
1425 (source (origin
1426 (method url-fetch)
1427 (uri (string-append "https://www.freedesktop.org/software/"
1428 "desktop-file-utils/releases/"
1429 "desktop-file-utils-" version ".tar.xz"))
1430 (sha256
1431 (base32
1432 "1nc3bwjdrpcrkbdmzvhckq0yngbcxspwj2n1r7jr3gmx1jk5vpm1"))))
1433 (build-system gnu-build-system)
1434 (native-inputs
1435 `(("pkg-config" ,pkg-config)))
1436 (inputs
1437 `(("glib" ,glib)))
1438 (home-page "https://www.freedesktop.org/wiki/Software/desktop-file-utils/")
1439 (synopsis "Utilities for working with desktop entries")
1440 (description
1441 "This package contains a few command line utilities for working with
1442 desktop entries:
1443
1444 desktop-file-validate: validates a desktop file and prints warnings/errors
1445 about desktop entry specification violations.
1446
1447 desktop-file-install: installs a desktop file to the applications directory,
1448 optionally munging it a bit in transit.
1449
1450 update-desktop-database: updates the database containing a cache of MIME types
1451 handled by desktop files.")
1452 (license license:gpl2+)))
1453
1454 (define-public xdg-user-dirs
1455 (package
1456 (name "xdg-user-dirs")
1457 (version "0.17")
1458 (source (origin
1459 (method url-fetch)
1460 (uri (string-append "http://user-dirs.freedesktop.org/releases/"
1461 name "-" version ".tar.gz"))
1462 (sha256
1463 (base32 "13216b8rfkzak5k6bvpx6jvqv3cnbgpijnjwj8a8d3kq4cl0a1ra"))))
1464 (build-system gnu-build-system)
1465 (native-inputs
1466 `(("gettext" ,gettext-minimal)
1467 ("docbook-xsl" ,docbook-xsl)
1468 ("docbook-xml" ,docbook-xml-4.3)
1469 ("xsltproc" ,libxslt)))
1470 (arguments
1471 `(#:phases
1472 (modify-phases %standard-phases
1473 (add-before 'build 'locate-catalog-files
1474 (lambda* (#:key inputs #:allow-other-keys)
1475 (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml")
1476 "/xml/dtd/docbook"))
1477 (xsldoc (string-append (assoc-ref inputs "docbook-xsl")
1478 "/xml/xsl/docbook-xsl-"
1479 ,(package-version docbook-xsl))))
1480 (for-each (lambda (file)
1481 (substitute* file
1482 (("http://.*/docbookx\\.dtd")
1483 (string-append xmldoc "/docbookx.dtd"))))
1484 (find-files "man" "\\.xml$"))
1485 (substitute* "man/Makefile"
1486 (("http://.*/docbook\\.xsl")
1487 (string-append xsldoc "/manpages/docbook.xsl")))
1488 #t))))))
1489 (home-page "https://www.freedesktop.org/wiki/Software/xdg-user-dirs/")
1490 (synopsis "Tool to help manage \"well known\" user directories")
1491 (description "xdg-user-dirs is a tool to help manage \"well known\" user
1492 directories, such as the desktop folder or the music folder. It also handles
1493 localization (i.e. translation) of the file names. Designed to be
1494 automatically run when a user logs in, xdg-user-dirs can also be run
1495 manually by a user.")
1496 (license license:gpl2)))
1497
1498 (define-public perl-file-basedir
1499 (package
1500 (name "perl-file-basedir")
1501 (version "0.08")
1502 (source
1503 (origin
1504 (method url-fetch)
1505 (uri (string-append "mirror://cpan/authors/id/K/KI/KIMRYAN/"
1506 "File-BaseDir-" version ".tar.gz"))
1507 (sha256
1508 (base32
1509 "1qq5ag9zffx8zc5i9b4z03ar80pqj4drgk3vjdlyfapjwb9zqrf0"))))
1510 (build-system perl-build-system)
1511 (native-inputs
1512 `(("perl-module-build" ,perl-module-build)
1513 ("perl-file-which" ,perl-file-which)
1514 ("perl-test-pod" ,perl-test-pod)
1515 ("perl-test-pod-coverage" ,perl-test-pod-coverage)
1516 ("xdg-user-dirs" ,xdg-user-dirs)))
1517 (propagated-inputs
1518 `(("perl-ipc-system-simple" ,perl-ipc-system-simple)))
1519 (home-page "https://metacpan.org/release/File-BaseDir")
1520 (synopsis "Use the Freedesktop.org base directory specification")
1521 (description
1522 "@code{File::Basedir} can be used to find directories and files as
1523 specified by the Freedesktop.org Base Directory Specification. This
1524 specifications gives a mechanism to locate directories for configuration,
1525 application data and cache data.")
1526 (license license:perl-license)))
1527
1528 (define-public perl-file-desktopentry
1529 (package
1530 (name "perl-file-desktopentry")
1531 (version "0.22")
1532 (source
1533 (origin
1534 (method url-fetch)
1535 (uri (string-append "mirror://cpan/authors/id/M/MI/MICHIELB/"
1536 "File-DesktopEntry-" version ".tar.gz"))
1537 (sha256
1538 (base32
1539 "1f1maqix2kbfg2rf008m7mqnvv6nvcf9y6pcgdv2kxp2vbih370n"))))
1540 (build-system perl-build-system)
1541 (native-inputs
1542 `(("perl-test-pod" ,perl-test-pod)
1543 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
1544 (propagated-inputs
1545 `(("perl-file-basedir" ,perl-file-basedir)
1546 ("perl-uri" ,perl-uri)))
1547 (home-page "https://metacpan.org/release/File-DesktopEntry")
1548 (synopsis "Handle @file{.desktop} files")
1549 (description
1550 "@code{File::DesktopEntry} parses @file{.desktop} files defined by the
1551 Freedesktop.org @dfn{Desktop Entry} specification. It can also run the
1552 applications define in those files.")
1553 (license license:perl-license)))
1554
1555 (define-public perl-file-mimeinfo
1556 (package
1557 (name "perl-file-mimeinfo")
1558 (version "0.29")
1559 (source
1560 (origin
1561 (method url-fetch)
1562 (uri (string-append "mirror://cpan/authors/id/M/MI/MICHIELB/"
1563 "File-MimeInfo-" version ".tar.gz"))
1564 (sha256
1565 (base32
1566 "1sh8r6vczyz08zm8vfsjmkg6a165wch54akjdrd1vbifcmwjg5pi"))))
1567 (build-system perl-build-system)
1568 ;; If the tests are fixed, add perl-test-pod, perl-test-pod-coverage, and
1569 ;; perl-test-tiny as native-inputs.
1570 (propagated-inputs
1571 `(("shared-mime-info" ,shared-mime-info)
1572 ("perl-file-desktopentry" ,perl-file-desktopentry)))
1573 (arguments
1574 ;; Some tests fail due to requiring the mimetype of perl files to be
1575 ;; text/plain when they are actually application/x-perl.
1576 `(#:tests? #f
1577 #:phases
1578 (modify-phases %standard-phases
1579 (add-after 'install 'wrap-programs
1580 (lambda* (#:key outputs #:allow-other-keys)
1581 (let ((out (assoc-ref outputs "out")))
1582 (for-each (lambda (prog)
1583 (wrap-program (string-append out "/bin/" prog)
1584 `("PERL5LIB" ":" prefix
1585 (,(string-append (getenv "PERL5LIB") ":" out
1586 "/lib/perl5/site_perl")))))
1587 '("mimeopen" "mimetype")))
1588 #t)))))
1589 (home-page "https://metacpan.org/release/File-MimeInfo")
1590 (synopsis "Determine file type from the file name")
1591 (description
1592 "@code{File::Mimeinfo} can be used to determine the MIME type of a file.
1593 It tries to implement the Freedesktop specification for a shared MIME
1594 database.
1595
1596 This package also contains two related utilities:
1597
1598 @itemize
1599 @item @command{mimetype} determines a file's MIME type;
1600 @item @command{mimeopen} opens files in an appropriate program according to
1601 their MIME type.
1602 @end itemize")
1603 (license license:perl-license)))
1604
1605 (define-public uchardet
1606 (package
1607 (name "uchardet")
1608 (version "0.0.6")
1609 (source
1610 (origin
1611 (method url-fetch)
1612 (uri (string-append "https://www.freedesktop.org/software/"
1613 name "/releases/" name "-" version ".tar.xz"))
1614 (sha256
1615 (base32 "0q9c02b6nmw41yfsiqsnphgc3f0yg3fj31wkccp47cmwvy634lc3"))))
1616 (build-system cmake-build-system)
1617 (home-page "https://www.freedesktop.org/wiki/Software/uchardet/")
1618 (synopsis "Encoding detector library")
1619 (description "uchardet is an encoding detector library, which takes a
1620 sequence of bytes in an unknown character encoding without any additional
1621 information, and attempts to determine the encoding of the text. Returned
1622 encoding names are iconv-compatible.")
1623
1624 ;; This combines code under MPL 1.1, LGPL 2.1+, and GPL 2.0+, so the
1625 ;; combination is GPL 2.0+.
1626 (license license:gpl2+)))
1627
1628 (define-public udiskie
1629 (package
1630 (name "udiskie")
1631 (version "2.1.0")
1632 (source
1633 (origin
1634 (method url-fetch)
1635 (uri (pypi-uri "udiskie" version))
1636 (sha256
1637 (base32
1638 "0smib8vbs9q37n7ynhzyw97q16fgdkcdw7fw69lci0xvyq00v1dz"))
1639 ;; Remove support for the libappindicator library of the
1640 ;; Unity desktop environment which is not in Guix.
1641 (patches (search-patches "udiskie-no-appindicator.patch"))))
1642 (build-system python-build-system)
1643 (native-inputs
1644 `(("asciidoc" ,asciidoc)
1645 ("gettext" ,gettext-minimal)
1646 ("gobject-introspection" ,gobject-introspection)))
1647 (inputs
1648 `(("gobject-introspection" ,gobject-introspection)
1649 ("gtk+" ,gtk+)
1650 ("libnotify" ,libnotify)
1651 ("udisks" ,udisks)))
1652 (propagated-inputs
1653 `(("python-docopt" ,python-docopt)
1654 ("python-pygobject" ,python-pygobject)
1655 ("python-keyutils" ,python-keyutils)
1656 ("python-pyxdg" ,python-pyxdg)
1657 ("python-pyyaml" ,python-pyyaml)))
1658 (arguments
1659 `(#:phases
1660 (modify-phases %standard-phases
1661 (add-after 'install 'wrap-gi-typelib
1662 (lambda* (#:key outputs #:allow-other-keys)
1663 (let ((out (assoc-ref outputs "out"))
1664 (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
1665 (wrap-program (string-append out "/bin/udiskie")
1666 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))))
1667 #t)))))
1668 (home-page "https://github.com/coldfix/udiskie")
1669 (synopsis "Automounter for removable media")
1670 (description
1671 "The @command{udiskie} program is a udisks2 front-end that
1672 manages removable media such as CDs or flash drives from userspace.
1673
1674 Its features include:
1675
1676 @itemize
1677 @item automount removable media,
1678 @item notifications,
1679 @item tray icon,
1680 @item command line tools for manual (un)mounting,
1681 @item LUKS encrypted devices,
1682 @item unlocking with keyfiles,
1683 @item loop devices (mounting ISO archives),
1684 @item password caching.
1685 @end itemize
1686 ")
1687 (license license:expat)))
1688
1689 (define-public plymouth
1690 (package
1691 (name "plymouth")
1692 (version "0.9.4")
1693 (source
1694 (origin
1695 (method url-fetch)
1696 (uri (string-append "https://www.freedesktop.org/software/"
1697 "plymouth/releases/" name "-" version ".tar.xz"))
1698 (sha256
1699 (base32
1700 "0l8kg7b2vfxgz9gnrn0v2w4jvysj2cirp0nxads5sy05397pl6aa"))))
1701 (build-system gnu-build-system)
1702 (arguments
1703 `(#:configure-flags
1704 (list (string-append "--with-logo="
1705 "/etc/plymouth/logo.png")
1706 (string-append "--with-background-color="
1707 "0x00ff00")
1708 (string-append "--with-background-start-color-stop="
1709 "0xff0000")
1710 (string-append "--with-background-end-color-stop="
1711 "0x0000ff")
1712 "--localstatedir=/var"
1713 "--with-boot-tty=/dev/console"
1714 "--without-system-root-install"
1715 "--without-rhgb-compat-link"
1716 "--enable-drm"
1717 "--disable-systemd-integration"
1718 ;; Disable GTK to dramatically reduce the closure
1719 ;; size from ~800 MiB to a little more than 200 MiB
1720 "--disable-gtk")
1721 #:phases
1722 (modify-phases %standard-phases
1723 (add-after 'unpack 'make-reproducible
1724 (lambda _
1725 (substitute* "src/main.c"
1726 (("__DATE__") "\"guix\""))
1727 #t))
1728 (add-before 'configure 'fix-docbook
1729 (lambda* (#:key inputs #:allow-other-keys)
1730 (substitute* "docs/Makefile.in"
1731 (("http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl")
1732 (string-append (assoc-ref inputs "docbook-xsl")
1733 "/xml/xsl/docbook-xsl-"
1734 ,(package-version docbook-xsl)
1735 "/manpages/docbook.xsl")))
1736 (setenv "XML_CATALOG_FILES"
1737 (string-append (assoc-ref inputs "docbook-xml")
1738 "/xml/dtd/docbook/catalog.xml"))
1739 #t)))))
1740 (inputs
1741 `(("glib" ,glib)
1742 ("pango" ,pango)
1743 ("libdrm" ,libdrm)
1744 ("libpng" ,libpng)
1745 ("eudev" ,eudev)))
1746 (native-inputs
1747 `(("pkg-config" ,pkg-config)
1748 ("libxslt" ,libxslt)
1749 ("docbook-xsl" ,docbook-xsl)
1750 ("docbook-xml" ,docbook-xml)))
1751 (synopsis "Graphical boot animation (splash) and logger")
1752 (home-page "https://www.freedesktop.org/wiki/Software/Plymouth/")
1753 (description
1754 "Plymouth is an application that runs very early in the boot process and
1755 that provides a graphical boot animation while the boot process happens in the
1756 background. You are not supposed to install this on your own, it is only
1757 useful with system integration.")
1758 (license license:gpl2+)))
1759
1760 (define-public libindicator
1761 (package
1762 (name "libindicator")
1763 (version "12.10.1")
1764 (source
1765 (origin
1766 (method url-fetch)
1767 (uri (string-append
1768 "https://launchpad.net/libindicator/"
1769 (version-major+minor version) "/" version
1770 "/+download/libindicator-" version ".tar.gz"))
1771 (sha256
1772 (base32
1773 "0zs4z7l9b57jldwz0ban77f3c2zq43ambd0dssf5qg9i216f9lmj"))))
1774 (build-system gnu-build-system)
1775 (native-inputs
1776 `(("dbus-test-runner" ,dbus-test-runner)
1777 ("glib:bin" ,glib "bin")
1778 ("pkg-config" ,pkg-config)
1779 ("xvfb" ,xorg-server-for-tests)))
1780 (inputs
1781 `(("gtk+" ,gtk+)
1782 ("glib" ,glib)))
1783 (arguments
1784 `(#:make-flags '("CFLAGS=-Wno-error")
1785 #:phases
1786 (modify-phases %standard-phases
1787 (add-before 'configure 'fix-missing-space-for-libm
1788 (lambda* (#:key outputs #:allow-other-keys)
1789 (substitute* "configure"
1790 (("LIBM=\"-lm\"") "LIBM=\" -lm\""))
1791 #t))
1792 (add-before 'configure 'fix-test-paths
1793 (lambda* (#:key inputs #:allow-other-keys)
1794 (substitute* "tests/Makefile.in"
1795 (("/bin/sh") (which "sh"))
1796 (("#!/bin/bash") (string-append "#!" (which "bash")))
1797 (("/usr/share")
1798 (string-append (assoc-ref inputs "dbus-test-runner") "/share")))
1799 #t)))))
1800 (home-page "https://launchpad.net/libindicator")
1801 (synopsis "Ayatana indicators symbols and functions")
1802 (description "A set of symbols and convenience functions for Ayatana indicators.")
1803 (license license:gpl3)))
1804
1805 (define-public libappindicator
1806 (package
1807 (name "libappindicator")
1808 (version "12.10.0")
1809 (source
1810 (origin
1811 (method url-fetch)
1812 (uri (string-append
1813 "https://launchpad.net/libappindicator/"
1814 (version-major+minor version) "/" version
1815 "/+download/libappindicator-" version ".tar.gz"))
1816 (sha256
1817 (base32
1818 "17xlqd60v0zllrxp8bgq3k5a1jkj0svkqn8rzllcyjh8k0gpr46m"))))
1819 (build-system gnu-build-system)
1820 (native-inputs
1821 `(("dbus-test-runner" ,dbus-test-runner)
1822 ("glib:bin" ,glib "bin")
1823 ("gobject-introspection" ,gobject-introspection)
1824 ("pkg-config" ,pkg-config)
1825 ("xvfb" ,xorg-server-for-tests)))
1826 (inputs
1827 `(("dbus-glib" ,dbus-glib)
1828 ("gtk+" ,gtk+)
1829 ("libdbusmenu" ,libdbusmenu)
1830 ("libindicator" ,libindicator)
1831 ("python@2" ,python-2)
1832 ("python2-pygtk" ,python2-pygtk)
1833 ("python2-pygobject-2" ,python2-pygobject-2)
1834 ;; ("mono" ,mono) ; requires non-packaged gapi
1835 ("vala" ,vala)))
1836 (arguments
1837 ;; FIXME: do not hardcode gtk version
1838 `(#:configure-flags '("--with-gtk=3")
1839 #:make-flags '("CFLAGS=-Wno-error")
1840 #:tests? #f ; One test does not pass (it succeeds when it should fail).
1841 #:phases
1842 (modify-phases %standard-phases
1843 (add-before 'configure 'fix-paths
1844 (lambda* (#:key inputs #:allow-other-keys)
1845 (substitute* "docs/reference/Makefile.in"
1846 (("/bin/sh") (which "sh")))
1847 (substitute* "tests/Makefile.in"
1848 (("/bin/sh") (which "sh"))
1849 (("#!/bin/bash") (string-append "#!" (which "bash")))
1850 (("/usr") (string-append (assoc-ref inputs "dbus-test-runner"))))
1851 (substitute* "bindings/python/Makefile.in"
1852 (("-lappindicator") "-lappindicator3"))
1853 #t))
1854 (add-after 'unpack 'fix-codegen-path
1855 (lambda _
1856 (substitute* "configure"
1857 (("PYGTK_CODEGEN=.*") "PYGTK_CODEGEN=pygtk-codegen-2.0\n"))
1858 #t))
1859 (add-after 'build 'build-bindings
1860 (lambda _
1861 (invoke "make" "-C" "bindings/python")
1862 #t))
1863 (add-after 'install 'install-bindings
1864 (lambda _
1865 (invoke "make" "-C" "bindings/python" "install")
1866 #t)))))
1867 (home-page "https://launchpad.net/libappindicator")
1868 (synopsis "Allow applications to export a menu into the Unity menu bar")
1869 (description "A library to allow applications to export a menu, originally
1870 into the Unity menu bar. Based on KSNI, it also works in KDE and will
1871 fallback to generic Systray support if none of those are available.")
1872 (license license:lgpl2.1+)))