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>
22 ;;; This file is part of GNU Guix.
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.
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.
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/>.
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))
95 (define-public xdg-utils
103 "https://portland.freedesktop.org/download/xdg-utils-"
107 "1nai806smz3zcb2l5iny4x7li0fak0rzmjg6vlyhdqm8z25b166p"))))
108 (build-system gnu-build-system)
110 `(("docbook-xsl" ,docbook-xsl)
111 ("docbook-xml" ,docbook-xml-4.1.2)
117 ("coreutils" ,coreutils)
119 ("inetutils" ,inetutils) ; xdg-screensaver uses `hostname'
120 ("perl-file-mimeinfo" ,perl-file-mimeinfo) ; for mimeopen fallback
122 ("xprop" ,xprop) ; for Xfce detecting
123 ("xset" ,xset))) ; for xdg-screensaver
125 `(#:tests? #f ; no check target
126 #:modules ((srfi srfi-26)
127 ,@%gnu-build-system-modules)
129 (modify-phases %standard-phases
130 (add-after 'unpack 'patch-hardcoded-paths
132 (substitute* "scripts/xdg-mime.in"
133 (("/usr/bin/file") (which "file")))
134 (substitute* "scripts/xdg-open.in"
135 (("/usr/bin/printf") (which "printf")))
137 (add-before 'build 'locate-catalog-files
138 (lambda* (#:key inputs #:allow-other-keys)
139 (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml")
141 (xsldoc (string-append (assoc-ref inputs "docbook-xsl")
142 "/xml/xsl/docbook-xsl-"
143 ,(package-version docbook-xsl))))
144 (for-each (lambda (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")))
158 (string-append xsldoc "/html/docbook.xsl"))
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")
165 (map (cute string-append <> "/bin")
167 (map (cute assoc-ref inputs <>)
168 '("awk" "coreutils" "grep" "inetutils"
169 "perl-file-mimeinfo" "sed" "xprop"
171 (for-each (cute wrap-program <>
172 `("PATH" ":" prefix ,path-ext))
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)))
182 (define-public libinput
183 ;; Updating this will rebuild over 700 packages through libinput-minimal.
189 (uri (string-append "https://freedesktop.org/software/libinput/"
190 "libinput-" version ".tar.xz"))
193 "0ivpb4sghl80cs7jg3xrs53kckif6wy81cny3a8mry94nszky74p"))))
194 (build-system meson-build-system)
196 `(#:configure-flags '("-Ddocumentation=false")
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"))
204 ("pkg-config" ,pkg-config)))
209 ("libevdev" ,libevdev)
210 ("libwacom" ,libwacom)
213 `(;; libinput.h requires <libudev.h>, so propagate it.
215 (home-page "https://www.freedesktop.org/wiki/Software/libinput/")
216 (synopsis "Input devices handling library")
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)))
222 (define-public libinput-minimal
223 (package (inherit libinput)
224 (name "libinput-minimal")
226 (fold alist-delete (package-inputs libinput)
227 '("cairo" "glib" "gtk+" "libwacom")))
229 (substitute-keyword-arguments (package-arguments libinput)
230 ((#:configure-flags flags ''())
231 `(cons* "-Dlibwacom=false"
232 "-Ddebug-gui=false" ;requires gtk+@3
235 (define-public libxdg-basedir
237 (name "libxdg-basedir")
242 (url "https://github.com/devnev/libxdg-basedir")
243 (commit (string-append name "-" version))))
244 (file-name (git-file-name name version))
247 "12yz53ny5bi2dii3zwcr6b9ay0yy1g1xv13jg097k7gjligcq11m"))))
248 (build-system gnu-build-system)
251 (modify-phases %standard-phases
252 (add-after 'unpack 'patch-autogen
254 ;; Run 'configure' in its own phase, not now.
255 (substitute* "autogen.sh"
256 (("^.*\\./configure.*") ""))
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")
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)))
269 (define-public elogind
276 (url "https://github.com/elogind/elogind")
277 (commit (string-append "v" version))))
278 (file-name (git-file-name name version))
281 "141frvgyk4fafcxsix94qc0d9ffrwksld8lqq4hq6xsgjlvv0mrs"))))
282 (build-system meson-build-system)
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")))
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"
310 ;; Disable some tests.
311 "-Dslow-tests=false"))
313 (modify-phases %standard-phases
314 (add-after 'unpack 'fix-pkttyagent-path
316 (substitute* "meson.build"
317 (("join_paths\\(bindir, 'pkttyagent'\\)")
318 "'\"/run/current-system/profile/bin/pkttyagent\"'"))
320 (add-after 'unpack 'adjust-dbus-socket-address
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"))
328 (add-after 'unpack 'adjust-tests
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")
336 ;; Use a shebang that works in the build container.
337 (substitute* "src/test/test-exec-util.c"
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"
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\\)")
349 ;; This test expects that /sys is available.
350 (substitute* "src/test/test-mountpoint-util.c"
351 (("assert_se\\(path_is_mount_point\\(\"/sys.*")
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.*")
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.*")
368 (add-after 'unpack 'change-pid-file-path
370 (substitute* "src/login/elogind.c"
371 (("\"/run/elogind.pid\"") "\"/run/systemd/elogind.pid\""))
374 `(("docbook-xml" ,docbook-xml)
375 ("docbook-xml-4.2" ,docbook-xml-4.2)
376 ("docbook-xsl" ,docbook-xsl)
377 ("gettext" ,gettext-minimal)
379 ("libxml2" ,libxml2) ;for XML_CATALOG_FILES
381 ("pkg-config" ,pkg-config)
383 ("xsltproc" ,libxslt)))
385 `(("linux-pam" ,linux-pam)
387 ("shadow" ,shadow) ;for 'nologin'
388 ("shepherd" ,shepherd) ;for 'halt' and 'reboot', invoked
389 ;when pressing the power button
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+)))
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.
410 (url "https://github.com/systemd/systemd")
411 (commit (string-append "v" version))))
414 "0sy91flzbhpq58k7v0294pa2gxpr0bk27rcnxlbhk2fi6nc51d28"))
415 (file-name (git-file-name name version))
416 (modules '((guix build utils)))
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"))
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"
432 (patches (search-patches "localed-xorg-keyboard.patch"))))
433 (build-system meson-build-system)
435 ;; Try to build as little as possible (list of components taken from the
436 ;; top-level 'meson.build' file.)
437 (let ((components '("utmp"
469 `(#:configure-flags ',(map (lambda (component)
470 (string-append "-D" component "=false"))
471 (delete "localed" components))
473 ;; It doesn't make sense to test all of systemd.
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")))
492 (lambda* (#:key outputs #:allow-other-keys)
493 ;; Install 'localed', the D-Bus and polkit files, and
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)))
510 (copy-file "systemd-localed"
511 (string-append libexec "/localed"))
512 (install-file "localectl" bin)
514 (let ((service-file (source-file
515 "\\.locale1\\.service$")))
516 (substitute* service-file
518 (string-append "Exec=" libexec "/localed\n")))
519 (install-file service-file dbus))
520 (install-file (source-file "\\.locale1\\.policy$")
522 (install-file (source-file "\\.locale1\\.conf$")
524 (for-each (lambda (file)
525 (install-file file lib))
526 (find-files "src/shared"
527 "libsystemd-shared.*\\.so"))
529 (for-each (lambda (map)
530 (install-file map data))
531 (find-files ".." "^(kbd-model-map|language-fallback-map)$"))
533 (native-inputs (package-native-inputs elogind))
534 (inputs `(("libmount" ,util-linux "lib")
535 ("xkeyboard-config" ,xkeyboard-config)
537 ,@(package-inputs elogind)))
538 (home-page "https://www.freedesktop.org/wiki/Software/systemd/localed/")
539 (synopsis "Control the system locale and keyboard layout")
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+)))
547 (define-public packagekit
554 "https://www.freedesktop.org/software/"
555 "PackageKit/releases/"
556 "PackageKit-" version ".tar.xz"))
559 "1dr1laic65ld95abp2yxbwvijnngh0dwyb1x49x4wjm5rhq43dl8"))))
560 (build-system gnu-build-system)
563 #:make-flags (list (string-append "BASH_COMPLETIONS_DIR="
564 %output "/etc/bash_completion.d"))
566 '("--disable-systemd")))
568 `(("intltool" ,intltool)
569 ("pkg-config" ,pkg-config)
570 ("python" ,python-wrapper)
571 ("glib:bin" ,glib "bin")))
574 ("bash-completion" ,bash-completion)
577 `(("sqlite" ,sqlite)))
578 (home-page "https://www.freedesktop.org/software/PackageKit/")
579 (synopsis "API for package management, through D-Bus")
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+)))
587 (define-public python-pyxdg
589 (name "python-pyxdg")
594 (uri (pypi-uri "pyxdg" version))
597 "179767h8m634ydlm4v8lnz01ba42gckfp684id764zaip7h87s41"))))
598 (build-system python-build-system)
601 (modify-phases %standard-phases
603 (lambda* (#:key inputs #:allow-other-keys)
604 (setenv "XDG_DATA_DIRS"
605 (string-append (assoc-ref inputs "shared-mime-info")
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
613 (("theme.validate\\(\\)") "#"))
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"))))))
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")
628 "PyXDG is a collection of implementations of freedesktop.org standards in
630 (license license:lgpl2.0)))
632 (define-public python2-pyxdg
633 (package-with-python2 python-pyxdg))
635 (define-public wayland
641 (uri (string-append "https://wayland.freedesktop.org/releases/"
642 name "-" version ".tar.xz"))
645 "194ibzwpdcn6fvk4xngr4bf5axpciwg2bj82fdvz88kfmjw13akj"))))
646 (build-system gnu-build-system)
648 `(#:parallel-tests? #f))
650 `(("doxygen" ,doxygen)
651 ("graphviz" ,graphviz)
652 ("pkg-config" ,pkg-config)
654 ("xsltproc" ,libxslt)))
656 `(("docbook-xml" ,docbook-xml)
657 ("docbook-xsl" ,docbook-xsl)
660 ("libxml2" ,libxml2))) ; for XML_CATALOG_FILES
661 (home-page "https://wayland.freedesktop.org/")
662 (synopsis "Display server protocol")
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)))
671 (define-public wayland-protocols
673 (name "wayland-protocols")
678 "https://wayland.freedesktop.org/releases/"
679 "wayland-protocols-" version ".tar.xz"))
682 "1cvl93h83ymbfhb567jv5gzyq08181w7c46rsw4xqqqpcvkvfwrx"))))
683 (build-system gnu-build-system)
685 `(("wayland" ,wayland)))
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)))
693 (define-public waylandpp
697 (home-page "https://github.com/NilsBrause/waylandpp")
700 (uri (git-reference (url home-page) (commit version)))
701 (file-name (git-file-name name version))
704 "16h57hzd688664qcyznzhjp3hxipdkzgv46x82yhkww24av8b55n"))))
705 (build-system cmake-build-system)
707 `(#:tests? #f)) ;no tests
709 `(("pkg-config" ,pkg-config)))
712 ("pugixml" ,pugixml)))
714 `(;; In Requires of the .pc files.
715 ("wayland" ,wayland)))
716 (synopsis "Wayland C++ bindings")
718 "This package provides C++ bindings for the Wayland display protocol.")
719 (license license:bsd-2)))
721 (define-public weston
728 "https://wayland.freedesktop.org/releases/"
729 "weston-" version ".tar.xz"))
732 "1d2m658ll8x7prlsfk71qgw89c7dz6y7d6nndfxwl49fmrd6sbxz"))))
733 (build-system meson-build-system)
735 `(("pkg-config" ,pkg-config)
736 ("xorg-server" ,xorg-server)))
738 `(("cairo" ,cairo-xcb)
743 ("libevdev" ,libevdev)
744 ("libinput" ,libinput-minimal)
745 ("libjpeg" ,libjpeg-turbo)
746 ("libunwind" ,libunwind)
749 ("libxcursor" ,libxcursor)
750 ("libxkbcommon" ,libxkbcommon)
754 ("linux-pam" ,linux-pam)
757 ("wayland-protocols" ,wayland-protocols)
758 ("xorg-server-xwayland" ,xorg-server-xwayland)))
761 (list "-Dbackend-rdp=false" ; TODO: Enable.
762 "-Dremoting=false" ; TODO: Enable.
763 "-Dsimple-dmabuf-drm=auto"
765 (string-append "-Dxwayland-path="
766 (assoc-ref %build-inputs "xorg-server-xwayland")
768 #:parallel-tests? #f ; Parallel tests cause failures.
770 (modify-phases %standard-phases
771 (add-before 'configure 'use-elogind
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>"))
781 (add-after 'configure 'patch-confdefs.h
783 (system "echo \"#define HAVE_SYSTEMD_LOGIN_209 1\" >> confdefs.h")
785 (add-before 'check 'setup
787 (setenv "HOME" (getcwd))
788 (setenv "XDG_RUNTIME_DIR" (getcwd))
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")
795 (setenv "DISPLAY" ":1")
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.
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)))
809 ;; There simple tool has no version or release yet.
810 (let ((commit "cee3dfb2a8b40ee303611018c68ae182d84a7f46"))
813 (version (string-append "2020-02-06-" (string-take commit 8)))
817 (url "https://git.sr.ht/~sircmpwn/wev")
819 (file-name (git-file-name name version))
822 "0l71v3fzgiiv6xkk365q1l08qvaymxd4kpaya6r2g8yzkr7i2hms"))))
823 (build-system gnu-build-system)
825 `(#:tests? #f ; no tests
827 (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))
829 (modify-phases %standard-phases
830 (delete 'configure))))
832 `(("pkg-config" ,pkg-config)
835 `(("libxkbcommon" ,libxkbcommon)
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
843 (license license:expat))))
845 (define-public exempi
852 "https://libopenraw.freedesktop.org/download/"
853 name "-" version ".tar.bz2"))
856 "1j4vx054l1c2cggw4aka4iw48jkcf68qk5y064pbqw1k3ddks2qh"))))
857 (build-system gnu-build-system)
859 `(#:configure-flags (list (string-append "--with-boost="
860 (assoc-ref %build-inputs "boost")))))
862 `(("boost" ,boost))) ; tests
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
871 (license license:bsd-3)))
873 (define-public libatasmart
879 (uri (string-append "http://0pointer.de/public/"
880 name "-" version ".tar.xz"))
883 "138gvgdwk6h4ljrjsr09pxk1nrki4b155hqdzyr8mlk3bwsfmw31"))))
884 (build-system gnu-build-system)
886 `(("pkg-config" ,pkg-config)))
889 (home-page "http://0pointer.de/blog/projects/being-smart.html")
890 (synopsis "ATA S.M.A.R.T. reading and parsing library")
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+)))
896 (define-public udisks
903 "https://github.com/storaged-project/udisks/releases/download/udisks-"
904 version "/udisks-" version ".tar.bz2"))
907 "1dnlxqgy9v0mjdknv3b1s64szdykyk3hk0rxj3chwhpd415lrwgs"))))
908 (build-system gnu-build-system)
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)
916 ("intltool" ,intltool)
917 ("pkg-config" ,pkg-config)
918 ("xsltproc" ,libxslt)))
920 `(("glib" ,glib))) ; required by udisks2.pc
923 ("cryptsetup" ,cryptsetup)
924 ("libatasmart" ,libatasmart)
925 ("libblockdev" ,libblockdev)
926 ("libgudev" ,libgudev)
928 ("util-linux" ,util-linux)))
930 "doc")) ;5 MiB of gtk-doc HTML
932 `(#:tests? #f ; requiring system message dbus
933 #:disallowed-references ("doc") ;enforce separation of "doc"
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"))
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")
951 docbook-xsl-name-version
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)))
960 (modify-phases %standard-phases
962 'configure 'fix-girdir
964 ;; Install introspection data to its own output.
965 (substitute* "udisks/Makefile.in"
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")
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")))
986 (home-page "https://www.freedesktop.org/wiki/Software/udisks/")
987 (synopsis "Disk manager service")
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
993 ;; The dynamic library are under LGPLv2+, others are GPLv2+.
994 (license (list license:gpl2+ license:lgpl2.0+))))
996 (define-public accountsservice
998 (name "accountsservice")
1003 (uri (string-append "https://www.freedesktop.org/software/"
1004 "accountsservice/accountsservice-" version ".tar.xz"))
1006 (base32 "0jn7vg1z4vxnna0hl33hbcb4bb3zpilxc2vyclh24vx4vvsjhn83"))))
1007 (build-system gnu-build-system)
1009 '(#:tests? #f ; XXX: tests require DocBook 4.1.2
1011 '("--localstatedir=/var"
1015 (modify-phases %standard-phases
1016 (add-after 'unpack 'patch-/bin/cat
1018 (substitute* "src/user.c"
1019 (("/bin/cat") (which "cat")))
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"))))
1036 `(("glib:bin" ,glib "bin") ; for gdbus-codegen, etc.
1037 ("gobject-introspection" ,gobject-introspection)
1038 ("intltool" ,intltool)
1039 ("pkg-config" ,pkg-config)))
1041 `(("elogind" ,elogind)
1043 ("shadow" ,shadow)))
1044 (home-page "https://www.freedesktop.org/wiki/Software/AccountsService/")
1045 (synopsis "D-Bus interface for user account query and manipulation")
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+)))
1052 (define-public libmbim
1059 "https://www.freedesktop.org/software/libmbim/"
1060 "libmbim-" version ".tar.xz"))
1063 "16q550sy84izi5ic3sbbhjnnka2fwhj8vvdrirpn9xspbsgbc3sm"))))
1064 (build-system gnu-build-system)
1066 `(("glib:bin" ,glib "bin") ; for glib-mkenums
1067 ("pkg-config" ,pkg-config)
1068 ("python" ,python-wrapper)))
1070 `(("glib" ,glib))) ; required by mbim-glib.pc
1072 `(("libgudev" ,libgudev)))
1073 (synopsis "Library to communicate with MBIM-powered modems")
1074 (home-page "https://www.freedesktop.org/wiki/Software/libmbim/")
1076 "Libmbim is a GLib-based library for talking to WWAN modems and devices
1077 which speak the Mobile Interface Broadband Model (MBIM) protocol.")
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+))))
1083 (define-public libqmi
1090 "https://www.freedesktop.org/software/libqmi/"
1091 "libqmi-" version ".tar.xz"))
1094 "12licfsszr6qxpg9b2b04qm2glk8d42fcy32zr8jzwrgr7gbl5h3"))))
1095 (build-system gnu-build-system)
1097 `(("libgudev" ,libgudev)))
1099 `(("glib:bin" ,glib "bin") ; for glib-mkenums
1100 ("pkg-config" ,pkg-config)
1101 ("python" ,python-wrapper)))
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/")
1107 "Libqmi is a GLib-based library for talking to WWAN modems and devices
1108 which speak the Qualcomm MSM Interface (QMI) protocol.")
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+))))
1114 (define-public modem-manager
1116 (name "modem-manager")
1121 "https://www.freedesktop.org/software/ModemManager/"
1122 "ModemManager-" version ".tar.xz"))
1125 "16hnl0sdriqgv4v30mfs64mdl9rw7lsh802zlm3ggwxxil3p9qfb"))))
1126 (build-system gnu-build-system)
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")))
1135 `(("glib:bin" ,glib "bin") ; for glib-mkenums
1136 ("gobject-introspection" ,gobject-introspection)
1137 ("intltool" ,intltool)
1138 ("pkg-config" ,pkg-config)
1143 `(("glib" ,glib))) ; required by mm-glib.pc
1145 `(("libgudev" ,libgudev)
1146 ("libmbim" ,libmbim)
1148 ("polkit" ,polkit)))
1149 (synopsis "Mobile broadband modems manager")
1150 (home-page "https://www.freedesktop.org/wiki/Software/ModemManager/")
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+)))
1159 (define-public telepathy-logger
1161 (name "telepathy-logger")
1165 (uri (string-append "https://telepathy.freedesktop.org/releases/"
1166 name "/" name "-" version ".tar.bz2"))
1169 "1bjx85k7jyfi5pvl765fzc7q2iz9va51anrc2djv7caksqsdbjlg"))))
1170 (build-system gnu-build-system)
1172 '(#:parallel-tests? #f
1174 (modify-phases %standard-phases
1175 (add-before 'check 'pre-check
1177 (setenv "HOME" (getenv "TMPDIR"))
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)))
1187 ;; telepathy-logger-0.2.pc refers to all these.
1188 `(("libxml2" ,libxml2)
1190 ("telepathy-glib" ,telepathy-glib)))
1191 (synopsis "Telepathy logger library")
1192 (home-page "https://telepathy.freedesktop.org/")
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+)))
1199 (define-public telepathy-idle
1201 (name "telepathy-idle")
1205 (uri (string-append "https://telepathy.freedesktop.org/releases/"
1206 name "/" name "-" version ".tar.bz2"))
1209 "1argdzbif1vdmwp5vqbgkadq9ancjmgdm2ncp0qfckni715ss4rh"))))
1210 (build-system gnu-build-system)
1212 `(("pkg-config" ,pkg-config)))
1214 `(("xsltproc" ,libxslt)
1215 ("python" ,python-2)
1216 ("python-dbus" ,python2-dbus)))
1218 `(("telepathy-glib" ,telepathy-glib)))
1219 (home-page "https://telepathy.freedesktop.org/")
1220 (synopsis "Telepathy IRC connection manager")
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+))))
1227 (define-public telepathy-mission-control
1229 (name "telepathy-mission-control")
1234 (uri (string-append "https://telepathy.freedesktop.org/releases/"
1235 "telepathy-mission-control/"
1236 "telepathy-mission-control-" version ".tar.gz"))
1238 (base32 "00xxv38cfdirnfvgyd56m60j0nkmsv5fz6p2ydyzsychicxl6ssc"))))
1239 (build-system gnu-build-system)
1241 `(("glib:bin" ,glib "bin") ; for glib-compile-schemas, etc.
1242 ("pkg-config" ,pkg-config)))
1245 ("gtk-doc" ,gtk-doc)
1246 ("libgnome-keyring" ,libgnome-keyring)
1247 ("python" ,python-2)
1248 ("xsltproc" ,libxslt)))
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")
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)))
1259 (define-public colord-gtk
1265 (uri (string-append "https://www.freedesktop.org/software/colord"
1266 "/releases/" name "-" version ".tar.xz"))
1269 "0i9y3bb5apj6a0f8cx36l6mjzs7xc0k7nf0magmf58vy2mzhpl18"))))
1270 (build-system gnu-build-system)
1271 (arguments '(#:tests? #f)) ; require the colord system service
1273 `(("gobject-introspection" ,gobject-introspection)
1274 ("intltool" ,intltool)
1275 ("pkg-config" ,pkg-config)
1278 ;; colord-gtk.pc refers to all these.
1279 `(("colord" ,colord)
1281 (synopsis "GTK integration for libcolord")
1282 (home-page "https://www.freedesktop.org/software/colord/")
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+)))
1289 (define-public libfprint
1297 (url "https://gitlab.freedesktop.org/libfprint/libfprint")
1298 (commit (string-append "v" version))))
1299 (file-name (git-file-name name version))
1301 (base32 "0fdaak7qjr9b4482g7fhhqpyfdqpxq5kpmyzkp7f5i7qq2ynb78a"))))
1302 (build-system meson-build-system)
1305 (list (string-append "-Dudev_rules_dir=" (assoc-ref %outputs "out")
1306 "/lib/udev/rules.d"))))
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)))
1316 ("nss" ,nss) ; for the URU4x00 driver
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")
1324 "libfprint is a library designed to make it easy for application
1325 developers to add support for consumer fingerprint readers to their
1327 (license license:lgpl2.1+)))
1329 (define-public fprintd
1337 (url "https://gitlab.freedesktop.org/libfprint/fprintd")
1339 (file-name (git-file-name name version))
1341 (base32 "0mbzk263x7f58i9cxhs44mrngs7zw5wkm62j5r6xlcidhmfn03cg"))))
1342 (build-system meson-build-system)
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")
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")))
1366 (add-before 'configure 'patch-mistake
1368 (substitute* "meson.build"
1369 (("(storage_path = )(get_option\\('prefix'\\))(.*)"
1370 _ set mistake value)
1371 (string-append set "''" value "\n")))
1373 (add-before 'configure 'patch-systemd-dependencies
1375 (substitute* "meson.build"
1376 (("'(libsystemd|systemd)'") "'libelogind'"))
1378 (add-before 'configure 'ignore-test-dependencies
1380 (substitute* "meson.build"
1381 (("pam_wrapper_dep .*") "")
1382 ((".*'(cairo|dbus|dbusmock|gi|pypamtest)': .*,.*") ""))
1384 (add-before 'install 'no-polkit-magic
1385 ;; Meson ‘magically’ invokes pkexec, which fails (not setuid).
1387 (setenv "PKEXEC_UID" "something")
1389 #:tests? #f)) ; XXX depend on unpackaged packages
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)))
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)
1404 `(("dbus-glib" ,dbus-glib)
1405 ("elogind" ,elogind)
1406 ("libfprint" ,libfprint)
1407 ("linux-pam" ,linux-pam)
1410 ;; XXX These are in libfprint's Requires.private. Meson refuses to grant
1411 ;; the ‘libfprint-2’ dependency if they are not provided here.
1414 ("pixman" ,pixman)))
1415 (home-page "https://fprint.freedesktop.org/")
1416 (synopsis "D-Bus daemon that exposes fingerprint reader functionality")
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+)))
1424 (define-public desktop-file-utils
1426 (name "desktop-file-utils")
1430 (uri (string-append "https://www.freedesktop.org/software/"
1431 "desktop-file-utils/releases/"
1432 "desktop-file-utils-" version ".tar.xz"))
1435 "1nc3bwjdrpcrkbdmzvhckq0yngbcxspwj2n1r7jr3gmx1jk5vpm1"))))
1436 (build-system gnu-build-system)
1438 `(("pkg-config" ,pkg-config)))
1441 (home-page "https://www.freedesktop.org/wiki/Software/desktop-file-utils/")
1442 (synopsis "Utilities for working with desktop entries")
1444 "This package contains a few command line utilities for working with
1447 desktop-file-validate: validates a desktop file and prints warnings/errors
1448 about desktop entry specification violations.
1450 desktop-file-install: installs a desktop file to the applications directory,
1451 optionally munging it a bit in transit.
1453 update-desktop-database: updates the database containing a cache of MIME types
1454 handled by desktop files.")
1455 (license license:gpl2+)))
1457 (define-public xdg-user-dirs
1459 (name "xdg-user-dirs")
1463 (uri (string-append "http://user-dirs.freedesktop.org/releases/"
1464 name "-" version ".tar.gz"))
1466 (base32 "13216b8rfkzak5k6bvpx6jvqv3cnbgpijnjwj8a8d3kq4cl0a1ra"))))
1467 (build-system gnu-build-system)
1469 `(("gettext" ,gettext-minimal)
1470 ("docbook-xsl" ,docbook-xsl)
1471 ("docbook-xml" ,docbook-xml-4.3)
1472 ("xsltproc" ,libxslt)))
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)
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")))
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)))
1501 (define-public perl-file-basedir
1503 (name "perl-file-basedir")
1508 (uri (string-append "mirror://cpan/authors/id/K/KI/KIMRYAN/"
1509 "File-BaseDir-" version ".tar.gz"))
1512 "1qq5ag9zffx8zc5i9b4z03ar80pqj4drgk3vjdlyfapjwb9zqrf0"))))
1513 (build-system perl-build-system)
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)))
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")
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)))
1531 (define-public perl-file-desktopentry
1533 (name "perl-file-desktopentry")
1538 (uri (string-append "mirror://cpan/authors/id/M/MI/MICHIELB/"
1539 "File-DesktopEntry-" version ".tar.gz"))
1542 "1f1maqix2kbfg2rf008m7mqnvv6nvcf9y6pcgdv2kxp2vbih370n"))))
1543 (build-system perl-build-system)
1545 `(("perl-test-pod" ,perl-test-pod)
1546 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
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")
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)))
1558 (define-public perl-file-mimeinfo
1560 (name "perl-file-mimeinfo")
1565 (uri (string-append "mirror://cpan/authors/id/M/MI/MICHIELB/"
1566 "File-MimeInfo-" version ".tar.gz"))
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.
1574 `(("shared-mime-info" ,shared-mime-info)
1575 ("perl-file-desktopentry" ,perl-file-desktopentry)))
1577 ;; Some tests fail due to requiring the mimetype of perl files to be
1578 ;; text/plain when they are actually application/x-perl.
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")))
1592 (home-page "https://metacpan.org/release/File-MimeInfo")
1593 (synopsis "Determine file type from the file name")
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
1599 This package also contains two related utilities:
1602 @item @command{mimetype} determines a file's MIME type;
1603 @item @command{mimeopen} opens files in an appropriate program according to
1606 (license license:perl-license)))
1608 (define-public uchardet
1615 (uri (string-append "https://www.freedesktop.org/software/"
1616 name "/releases/" name "-" version ".tar.xz"))
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.")
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+)))
1631 (define-public udiskie
1638 (uri (pypi-uri "udiskie" version))
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)
1647 `(("asciidoc" ,asciidoc)
1648 ("gettext" ,gettext-minimal)
1649 ("gobject-introspection" ,gobject-introspection)))
1651 `(("gobject-introspection" ,gobject-introspection)
1653 ("libnotify" ,libnotify)
1654 ("udisks" ,udisks)))
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)))
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))))
1671 (home-page "https://github.com/coldfix/udiskie")
1672 (synopsis "Automounter for removable media")
1674 "The @command{udiskie} program is a udisks2 front-end that
1675 manages removable media such as CDs or flash drives from userspace.
1677 Its features include:
1680 @item automount removable media,
1681 @item notifications,
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.
1690 (license license:expat)))