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