1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012, 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
5 ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
6 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
7 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
8 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
9 ;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
10 ;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
12 ;;; Copyright © 2016 Raymond Nicholson <rain1@openmailbox.org>
13 ;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org>
14 ;;; Copyright © 2016 Nicolas Goaziou <mail@nicolasgoaziou.fr>
15 ;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
16 ;;; Copyright © 2016 David Craven <david@craven.ch>
17 ;;; Copyright © 2016 John Darrington <jmd@gnu.org>
18 ;;; Copyright © 2016 Rene Saavedra <rennes@openmailbox.org>
20 ;;; This file is part of GNU Guix.
22 ;;; GNU Guix is free software; you can redistribute it and/or modify it
23 ;;; under the terms of the GNU General Public License as published by
24 ;;; the Free Software Foundation; either version 3 of the License, or (at
25 ;;; your option) any later version.
27 ;;; GNU Guix is distributed in the hope that it will be useful, but
28 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
29 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 ;;; GNU General Public License for more details.
32 ;;; You should have received a copy of the GNU General Public License
33 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
35 (define-module (gnu packages linux)
36 #:use-module (gnu packages)
37 #:use-module (gnu packages acl)
38 #:use-module (gnu packages admin)
39 #:use-module (gnu packages algebra)
40 #:use-module (gnu packages attr)
41 #:use-module (gnu packages autotools)
42 #:use-module (gnu packages base)
43 #:use-module (gnu packages bison)
44 #:use-module (gnu packages calendar)
45 #:use-module (gnu packages check)
46 #:use-module (gnu packages crypto)
47 #:use-module (gnu packages compression)
48 #:use-module (gnu packages databases)
49 #:use-module (gnu packages docbook)
50 #:use-module (gnu packages documentation)
51 #:use-module (gnu packages elf)
52 #:use-module (gnu packages flex)
53 #:use-module (gnu packages freedesktop)
54 #:use-module (gnu packages gcc)
55 #:use-module (gnu packages gettext)
56 #:use-module (gnu packages glib)
57 #:use-module (gnu packages gnuzilla)
58 #:use-module (gnu packages gperf)
59 #:use-module (gnu packages gtk)
60 #:use-module (gnu packages libusb)
61 #:use-module (gnu packages maths)
62 #:use-module (gnu packages ncurses)
63 #:use-module (gnu packages perl)
64 #:use-module (gnu packages pciutils)
65 #:use-module (gnu packages pkg-config)
66 #:use-module (gnu packages pulseaudio)
67 #:use-module (gnu packages python)
68 #:use-module (gnu packages readline)
69 #:use-module (gnu packages rrdtool)
70 #:use-module (gnu packages slang)
71 #:use-module (gnu packages texinfo)
72 #:use-module (gnu packages tls)
73 #:use-module (gnu packages xml)
74 #:use-module (guix build-system cmake)
75 #:use-module (guix build-system gnu)
76 #:use-module (guix build-system python)
77 #:use-module (guix build-system trivial)
78 #:use-module (guix download)
79 #:use-module ((guix licenses) #:prefix license:)
80 #:use-module (guix packages)
81 #:use-module (guix utils)
82 #:use-module (srfi srfi-1)
83 #:use-module (srfi srfi-2)
84 #:use-module (srfi srfi-26)
85 #:use-module (ice-9 match))
87 (define-public (system->linux-architecture arch)
88 "Return the Linux architecture name for ARCH, a Guix system name such as
89 \"x86_64-linux\" or a target triplet such as \"arm-linux-gnueabihf\"."
90 (let ((arch (car (string-split arch #\-))))
91 (cond ((string=? arch "i686") "i386")
92 ((string-prefix? "mips" arch) "mips")
93 ((string-prefix? "arm" arch) "arm")
94 ((string-prefix? "aarch64" arch) "arm64")
97 (define (linux-libre-urls version)
98 "Return a list of URLs for Linux-Libre VERSION."
100 "http://linux-libre.fsfla.org/pub/linux-libre/releases/"
101 version "-gnu/linux-libre-" version "-gnu.tar.xz")
103 ;; XXX: Work around <http://bugs.gnu.org/14851>.
105 "ftp://alpha.gnu.org/gnu/guix/mirror/linux-libre-"
106 version "-gnu.tar.xz")
108 ;; Maybe this URL will become valid eventually.
110 "mirror://gnu/linux-libre/" version "-gnu/linux-libre-"
111 version "-gnu.tar.xz")))
113 (define-public linux-libre-headers
115 (name "linux-libre-headers")
119 (uri (linux-libre-urls version))
122 "0k8k17in7dkjd9d8zg3i8l1ax466dba6bxw28flxizzyq8znljps"))))
123 (build-system gnu-build-system)
124 (native-inputs `(("perl" ,perl)))
126 `(#:modules ((guix build gnu-build-system)
130 (modify-phases %standard-phases
134 (let ((arch ,(system->linux-architecture
135 (or (%current-target-system)
136 (%current-system)))))
138 (format #t "`ARCH' set to `~a'~%" (getenv "ARCH"))
140 (and (zero? (system* "make" "defconfig"))
141 (zero? (system* "make" "mrproper" "headers_check"))))))
143 (lambda* (#:key outputs #:allow-other-keys)
144 (let ((out (assoc-ref outputs "out")))
145 (and (zero? (system* "make"
146 (string-append "INSTALL_HDR_PATH=" out)
149 (mkdir (string-append out "/include/config"))
150 (call-with-output-file
152 "/include/config/kernel.release")
154 (format p "~a-default~%" ,version)))
156 ;; Remove the '.install' and '..install.cmd' files; the
157 ;; latter contains store paths, which pulls in bootstrap
158 ;; binaries in the build environment, and prevents bit
159 ;; reproducibility for the bootstrap binaries.
160 (for-each delete-file (find-files out "\\.install"))
163 #:allowed-references ()
165 (home-page "http://www.gnu.org/software/linux-libre")
166 (synopsis "GNU Linux-Libre kernel headers")
167 (description "Headers of the Linux-Libre kernel.")
168 (license license:gpl2)))
170 (define %boot-logo-patch
171 ;; Linux-Libre boot logo featuring Freedo and a gnu.
174 (uri (string-append "http://www.fsfla.org/svn/fsfla/software/linux-libre/"
175 "lemote/gnewsense/branches/3.16/100gnu+freedo.patch"))
178 "1hk9swxxc80bmn2zd2qr5ccrjrk28xkypwhl4z0qx4hbivj7qm06"))))
180 (define* (kernel-config arch #:key variant)
181 "Return the absolute file name of the Linux-Libre build configuration file
182 for ARCH and optionally VARIANT, or #f if there is no such configuration."
183 (let* ((name (string-append "linux-libre-"
184 (if variant (string-append variant "-") "")
185 (if (string=? "i386" arch) "i686" arch) ".conf"))
186 (file (string-append "gnu/packages/" name)))
187 (search-path %load-path file)))
189 (define %default-extra-linux-options
190 `(;; https://lists.gnu.org/archive/html/guix-devel/2014-04/msg00039.html
191 ("CONFIG_DEVPTS_MULTIPLE_INSTANCES" . #t)
192 ;; Modules required for initrd:
193 ("CONFIG_NET_9P" . m)
194 ("CONFIG_NET_9P_VIRTIO" . m)
195 ("CONFIG_VIRTIO_BLK" . m)
196 ("CONFIG_VIRTIO_NET" . m)
197 ("CONFIG_VIRTIO_PCI" . m)
198 ("CONFIG_VIRTIO_BALLOON" . m)
199 ("CONFIG_VIRTIO_MMIO" . m)
200 ("CONFIG_FUSE_FS" . m)
202 ("CONFIG_9P_FS" . m)))
204 (define (config->string options)
205 (string-join (map (match-lambda
207 (string-append option "=m"))
209 (string-append option "=y"))
211 (string-append option "=n")))
215 (define* (make-linux-libre version hash supported-systems
217 ;; A function that takes an arch and a variant.
218 ;; See kernel-config for an example.
220 (configuration-file #f)
221 (defconfig "defconfig")
222 (extra-options %default-extra-linux-options)
223 (patches (list %boot-logo-patch)))
225 (name (if extra-version
226 (string-append "linux-libre-" extra-version)
231 (uri (linux-libre-urls version))
232 (sha256 (base32 hash))
234 (supported-systems supported-systems)
235 (build-system gnu-build-system)
241 ,@(if configuration-file
242 `(("kconfig" ,(configuration-file
243 (system->linux-architecture
244 (or (%current-target-system)
246 #:variant (version-major+minor version))))
249 `(#:modules ((guix build gnu-build-system)
254 (modify-phases %standard-phases
256 (lambda* (#:key inputs native-inputs target #:allow-other-keys)
257 ;; Avoid introducing timestamps
258 (setenv "KCONFIG_NOTIMESTAMP" "1")
259 (setenv "KBUILD_BUILD_TIMESTAMP" (getenv "SOURCE_DATE_EPOCH"))
261 ;; Set ARCH and CROSS_COMPILE
262 (let ((arch ,(system->linux-architecture
263 (or (%current-target-system)
264 (%current-system)))))
266 (format #t "`ARCH' set to `~a'~%" (getenv "ARCH"))
269 (setenv "CROSS_COMPILE" (string-append target "-"))
270 (format #t "`CROSS_COMPILE' set to `~a'~%"
271 (getenv "CROSS_COMPILE"))))
273 (setenv "EXTRA_VERSION" ,extra-version)
275 (let ((build (assoc-ref %standard-phases 'build))
276 (config (assoc-ref inputs "kconfig")))
278 ;; Use a custom kernel configuration file or a default
279 ;; configuration file.
282 (copy-file config ".config")
283 (chmod ".config" #o666))
284 (system* "make" ,defconfig))
286 ;; Appending works even when the option wasn't in the
287 ;; file. The last one prevails if duplicated.
288 (let ((port (open-file ".config" "a"))
289 (extra-configuration ,(config->string extra-options)))
290 (display extra-configuration port)
293 (zero? (system* "make" "oldconfig")))))
295 (lambda* (#:key inputs native-inputs outputs #:allow-other-keys)
296 (let* ((out (assoc-ref outputs "out"))
297 (moddir (string-append out "/lib/modules"))
298 (dtbdir (string-append out "/lib/dtbs"))
299 (kmod (assoc-ref (or native-inputs inputs) "kmod")))
300 ;; Install kernel image, kernel configuration and link map.
301 (for-each (lambda (file) (install-file file out))
302 (find-files "." "^(\\.config|bzImage|zImage|vmlinuz|System\\.map)$"))
303 ;; Install device tree files
304 (for-each (lambda (file) (install-file file dtbdir))
305 (find-files "." "\\.dtb$"))
306 ;; Install kernel modules
308 (zero? (system* "make"
309 (string-append "DEPMOD=" kmod "/bin/depmod")
310 (string-append "MODULE_DIR=" moddir)
311 (string-append "INSTALL_PATH=" out)
312 (string-append "INSTALL_MOD_PATH=" out)
313 "INSTALL_MOD_STRIP=1"
314 "modules_install"))))))
316 (home-page "http://www.gnu.org/software/linux-libre/")
317 (synopsis "100% free redistribution of a cleaned Linux kernel")
319 "GNU Linux-Libre is a free (as in freedom) variant of the Linux kernel.
320 It has been modified to remove all non-free binary blobs.")
321 (license license:gpl2)))
323 (define %intel-compatible-systems '("x86_64-linux" "i686-linux"))
325 (define-public linux-libre
326 (make-linux-libre "4.8.4"
327 "06fb2b1y7w0ixq4savn3hddp326mmzmg3400dpr8lyg919bwck3x"
328 %intel-compatible-systems
329 #:configuration-file kernel-config))
331 (define-public linux-libre-4.4
332 (make-linux-libre "4.4.27"
333 "07g0y8zbspw8d65386llcsnqlbv2s24dxvvbwm9kwm87rk3vin1r"
334 %intel-compatible-systems
335 #:configuration-file kernel-config))
337 (define-public linux-libre-4.1
338 (make-linux-libre "4.1.35"
339 "05zvrld1digqwf9kqf5pxx0mxqmwpr5kamhnks6y4yfy7x7jynyk"
340 %intel-compatible-systems
341 #:configuration-file kernel-config))
343 ;; Avoid rebuilding kernel variants when there is a minor version bump.
344 (define %linux-libre-version "4.8.4")
345 (define %linux-libre-hash "06fb2b1y7w0ixq4savn3hddp326mmzmg3400dpr8lyg919bwck3x")
347 (define-public linux-libre-arm-generic
348 (make-linux-libre %linux-libre-version
351 #:defconfig "multi_v7_defconfig"
352 #:extra-version "arm-generic"))
356 ;;; Pluggable authentication modules (PAM).
359 (define-public linux-pam
367 "http://www.linux-pam.org/library/"
368 "Linux-PAM-" version ".tar.bz2"))
371 "1fyi04d5nsh8ivd0rn2y0z83ylgc0licz7kifbb6xxi2ylgfs6i4"))
372 (patches (search-patches "linux-pam-no-setfsuid.patch"))))
374 (build-system gnu-build-system)
378 ;; TODO: optional dependencies
379 ;; ("libxcrypt" ,libxcrypt)
380 ;; ("cracklib" ,cracklib)
383 '(;; Most users, such as `shadow', expect the headers to be under
385 #:configure-flags (list (string-append "--includedir="
386 (assoc-ref %outputs "out")
387 "/include/security"))
389 ;; XXX: Tests won't run in chroot, presumably because /etc/pam.d
392 (home-page "http://www.linux-pam.org/")
393 (synopsis "Pluggable authentication modules for Linux")
395 "A *Free* project to implement OSF's RFC 86.0.
396 Pluggable authentication modules are small shared object files that can
397 be used through the PAM API to perform tasks, like authenticating a user
398 at login. Local and dynamic reconfiguration are its key features.")
399 (license license:bsd-3)))
401 (define-public linux-pam-1.2
409 "http://www.linux-pam.org/library/"
410 "Linux-PAM-" version ".tar.bz2"))
413 "1n9lnf9gjs72kbj1g354v1xhi2j27aqaah15vykh7cnkq08i4arl"))
414 (patches (search-patches "linux-pam-no-setfsuid.patch"))))))
421 (define-public psmisc
428 (uri (string-append "mirror://sourceforge/psmisc/psmisc/psmisc-"
432 "052mfraykmxnavpi8s78aljx8w87hyvpx8mvzsgpjsjz73i28wmi"))))
433 (build-system gnu-build-system)
434 (inputs `(("ncurses" ,ncurses)))
435 (home-page "http://psmisc.sourceforge.net/")
437 "Small utilities that use the proc file system")
439 "This PSmisc package is a set of some small useful utilities that
440 use the proc file system. We're not about changing the world, but
441 providing the system administrator with some help in common tasks.")
442 (license license:gpl2+)))
444 (define-public util-linux
450 (uri (string-append "mirror://kernel.org/linux/utils/"
451 name "/v" (version-major+minor version) "/"
452 name "-" version ".tar.xz"))
455 "03xnaw3c7pavxvvh1vnimcr44hlhhf25whawiyv8dxsflfj4xkiy"))
456 (patches (search-patches "util-linux-tests.patch"))
457 (modules '((guix build utils)))
459 ;; We take the 'logger' program from GNU Inetutils and 'kill'
460 ;; from GNU Coreutils.
462 (substitute* "configure"
463 (("build_logger=yes") "build_logger=no")
464 (("build_kill=yes") "build_kill=no"))
466 (build-system gnu-build-system)
468 "static")) ; >2 MiB of static .a libraries
470 `(#:configure-flags (list "--disable-use-tty-group"
472 ;; Install completions where our
473 ;; bash-completion package expects them.
474 (string-append "--with-bashcompletiondir="
475 (assoc-ref %outputs "out")
476 "/etc/bash_completion.d"))
477 #:phases (modify-phases %standard-phases
479 'build 'set-umount-file-name
480 (lambda* (#:key outputs #:allow-other-keys)
481 ;; Tell 'eject' the right file name of 'umount'.
482 (let ((out (assoc-ref outputs "out")))
483 (substitute* "sys-utils/eject.c"
485 (string-append "\"" out "/bin/umount\"")))
489 (lambda* (#:key inputs outputs #:allow-other-keys)
490 (let ((out (assoc-ref outputs "out"))
491 (net (assoc-ref inputs "net-base")))
492 ;; Change the test to refer to the right file.
493 (substitute* "tests/ts/misc/mcookie"
495 (string-append net "/etc/services")))
498 'install 'move-static-libraries
499 (lambda* (#:key outputs #:allow-other-keys)
500 (let ((out (assoc-ref outputs "out"))
501 (static (assoc-ref outputs "static")))
502 (mkdir-p (string-append static "/lib"))
503 (with-directory-excursion out
504 (for-each (lambda (file)
506 (string-append static "/"
508 (find-files "lib" "\\.a$")))
510 (inputs `(("zlib" ,zlib)
511 ("ncurses" ,ncurses)))
514 ("net-base" ,net-base))) ;for tests
515 (home-page "https://www.kernel.org/pub/linux/utils/util-linux/")
516 (synopsis "Collection of utilities for the Linux kernel")
517 (description "Util-linux is a diverse collection of Linux kernel
518 utilities. It provides dmesg and includes tools for working with file systems,
519 block devices, UUIDs, TTYs, and many other tools.")
521 ;; Note that util-linux doesn't use the same license for all the
522 ;; code. GPLv2+ is the default license for a code without an
523 ;; explicitly defined license.
524 (license (list license:gpl3+ license:gpl2+ license:gpl2 license:lgpl2.0+
525 license:bsd-4 license:public-domain))))
527 (define-public procps
533 (uri (string-append "mirror://sourceforge/procps-ng/Production/"
534 "procps-ng-" version ".tar.xz"))
537 "1m57w6jmry84njd5sgk5afycbglql0al80grx027kwqqcfw5mmkf"))))
538 (build-system gnu-build-system)
540 '(#:modules ((guix build utils)
541 (guix build gnu-build-system)
545 (modify-phases %standard-phases
546 (add-before 'check 'disable-strtod-test
548 ;; Disable the 'strtod' test, which fails on 32-bit systems.
549 ;; This is what upstream does:
550 ;; <https://gitlab.com/procps-ng/procps/commit/100afbc1491be388f1429021ff65d969f4b1e08f>.
551 (substitute* "Makefile"
552 (("^(TESTS|check_PROGRAMS) = .*$" all)
553 (string-append "# " all "\n")))
556 'install 'post-install
557 ;; Remove commands and man pages redudant with
559 (lambda* (#:key outputs #:allow-other-keys)
560 (let* ((out (assoc-ref outputs "out"))
561 (dup (append-map (cut find-files out <>)
562 '("^kill" "^uptime"))))
563 (for-each delete-file dup)
565 (inputs `(("ncurses" ,ncurses)))
566 (home-page "https://gitlab.com/procps-ng/procps/")
567 (synopsis "Utilities that give information about processes")
569 "Procps is the package that has a bunch of small useful utilities
570 that give information about processes using the Linux /proc file system.
571 The package includes the programs ps, top, vmstat, w, kill, free,
572 slabtop, and skill.")
573 (license license:gpl2)))
575 (define-public usbutils
582 (uri (string-append "mirror://kernel.org/linux/utils/usb/usbutils/"
583 "usbutils-" version ".tar.xz"))
586 "03pd57vv8c6x0hgjqcbrxnzi14h8hcghmapg89p8k5zpwpkvbdfr"))))
587 (build-system gnu-build-system)
589 `(("libusb" ,libusb)))
591 `(("pkg-config" ,pkg-config)))
592 (home-page "http://www.linux-usb.org/")
594 "Tools for working with USB devices, such as lsusb")
596 "Tools for working with USB devices, such as lsusb.")
597 (license license:gpl2+)))
599 (define-public e2fsprogs
606 "mirror://kernel.org/linux/kernel/people/tytso/"
607 name "/v" version "/"
608 name "-" version ".tar.xz"))
611 "1ix0b83zgw5n0p2grh2961c6796m92yr2jqc2sbr23x3lfsp8r71"))
612 (modules '((guix build utils)))
614 '(substitute* "MCONFIG.in"
615 (("INSTALL_SYMLINK = /bin/sh")
616 "INSTALL_SYMLINK = sh")))))
617 (build-system gnu-build-system)
618 (inputs `(("util-linux" ,util-linux)))
619 (native-inputs `(("pkg-config" ,pkg-config)
620 ("texinfo" ,texinfo))) ;for the libext2fs Info manual
622 '(;; Parallel building reliably yields a failure like this:
623 ;; "make[2]: *** No rule to make target '../lib/libss.so', needed by
626 ;; util-linux is the preferred source for some of the libraries and
627 ;; commands, so disable them (see, e.g.,
628 ;; <http://git.buildroot.net/buildroot/commit/?id=e1ffc2f791b33633>.)
629 #:configure-flags '("--disable-libblkid"
630 "--disable-libuuid" "--disable-uuidd"
633 ;; Install libext2fs et al.
634 "--enable-elf-shlibs")
636 #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
637 (assoc-ref %outputs "out")
640 #:phases (alist-cons-before
641 'configure 'patch-shells
643 (substitute* "configure"
644 (("/bin/sh (.*)parse-types.sh" _ dir)
645 (string-append (which "sh") " " dir
647 (substitute* (find-files "." "^Makefile.in$")
649 (string-append "#!" (which "sh")))))
651 'install 'install-libs
652 (lambda* (#:key outputs #:allow-other-keys)
653 (let* ((out (assoc-ref outputs "out"))
654 (lib (string-append out "/lib")))
655 (and (zero? (system* "make" "install-libs"))
657 ;; Make the .a writable so that 'strip' works.
658 ;; Failing to do that, due to debug symbols, we
659 ;; retain a reference to the final
660 ;; linux-libre-headers, which refer to the
661 ;; bootstrap binaries.
662 (let ((archives (find-files lib "\\.a$")))
663 (for-each (lambda (file)
669 ;; FIXME: Tests work by comparing the stdout/stderr of programs, that
670 ;; they fail because we get an extra line that says "Can't check if
671 ;; file system is mounted due to missing mtab file".
673 (home-page "http://e2fsprogs.sourceforge.net/")
674 (synopsis "Creating and checking ext2/ext3/ext4 file systems")
676 "This package provides tools for manipulating ext2/ext3/ext4 file systems.")
677 (license (list license:gpl2 ;programs
678 license:lgpl2.0 ;libext2fs
679 license:x11)))) ;libuuid
681 (define e2fsprogs/static
683 (package (inherit e2fsprogs)
685 ;; Do not build shared libraries.
686 (substitute-keyword-arguments (package-arguments e2fsprogs)
687 ((#:configure-flags _)
688 '(list "--disable-blkid"))
692 (define-public e2fsck/static
694 (name "e2fsck-static")
695 (version (package-version e2fsprogs))
696 (build-system trivial-build-system)
699 `(#:modules ((guix build utils))
702 (use-modules (guix build utils)
706 (let ((source (string-append (assoc-ref %build-inputs "e2fsprogs")
708 (bin (string-append (assoc-ref %outputs "out") "/sbin")))
710 (with-directory-excursion bin
711 (for-each (lambda (file)
712 (copy-file (string-append source "/" file)
714 (remove-store-references file)
716 (scandir source (cut string-prefix? "fsck." <>))))))))
717 (inputs `(("e2fsprogs" ,e2fsprogs/static)))
718 (synopsis "Statically-linked fsck.* commands from e2fsprogs")
720 "This package provides statically-linked command of fsck.ext[234] taken
721 from the e2fsprogs package. It is meant to be used in initrds.")
722 (home-page (package-home-page e2fsprogs))
723 (license (package-license e2fsprogs))))
725 (define-public extundelete
731 (uri (string-append "mirror://sourceforge/extundelete/"
732 "extundelete/" version "/extundelete-"
736 "1x0r7ylxlp9lbj3d7sqf6j2a222dwy2nfpff05jd6mkh4ihxvyd1"))))
737 (build-system gnu-build-system)
738 (inputs `(("e2fsprogs" ,e2fsprogs)))
739 (home-page "http://extundelete.sourceforge.net/")
740 (synopsis "Recover deleted files from ext2/3/4 partitions")
742 "Extundelete is a set of tools that can recover deleted files from an
743 ext3 or ext4 partition.")
744 (license license:gpl2)))
746 (define-public zerofree
750 (home-page "http://intgat.tigress.co.uk/rmy/uml/")
753 (uri (string-append home-page name "-" version
757 "1xncw3dn2cp922ly42m96p6fh7jv8ysg6bwqbk5xvw701f3dmkrs"))))
758 (build-system gnu-build-system)
760 '(#:phases (alist-replace
762 (lambda* (#:key outputs #:allow-other-keys)
763 (let* ((out (assoc-ref outputs "out"))
764 (bin (string-append out "/bin")))
766 (copy-file "zerofree"
767 (string-append bin "/zerofree"))
768 (chmod (string-append bin "/zerofree")
771 (alist-delete 'configure %standard-phases))
772 #:tests? #f)) ;no tests
773 (inputs `(("libext2fs" ,e2fsprogs)))
774 (synopsis "Zero non-allocated regions in ext2/ext3/ext4 file systems")
776 "The zerofree command scans the free blocks in an ext2 file system and
777 fills any non-zero blocks with zeroes. This is a useful way to make disk
778 images more compressible.")
779 (license license:gpl2)))
781 (define-public strace
787 (uri (string-append "mirror://sourceforge/strace/strace/" version
788 "/strace-" version ".tar.xz"))
791 "158iwk0pl2mfw93m1843xb7a2zb8p6lh0qim07rca6f1ff4dk764"))))
792 (build-system gnu-build-system)
793 (native-inputs `(("perl" ,perl)))
794 (home-page "http://strace.sourceforge.net/")
795 (synopsis "System call tracer for Linux")
797 "strace is a system call tracer, i.e. a debugging tool which prints out a
798 trace of all the system calls made by a another process/program.")
799 (license license:bsd-3)))
801 (define-public ltrace
807 (uri (string-append "http://www.ltrace.org/ltrace_" version
811 "00wmbdghqbz6x95m1mcdd3wd46l6hgcr4wggdp049dbifh3qqvqf"))))
812 (build-system gnu-build-system)
813 (inputs `(("libelf" ,libelf)))
815 ;; Compilation uses -Werror by default, but it fails.
816 '(#:configure-flags '("--disable-werror")))
817 (home-page "http://www.ltrace.org/")
818 (synopsis "Library call tracer for Linux")
820 "ltrace intercepts and records dynamic library calls which are called by
821 an executed process and the signals received by that process. It can also
822 intercept and print the system calls executed by the program.")
823 (license license:gpl2+)))
825 (define-public alsa-lib
832 "ftp://ftp.alsa-project.org/pub/lib/alsa-lib-"
836 "0fx057746dj7rjdi0jnvx2m9b0y1lgdkh1hks87d8w32xyihf3k9"))
837 (patches (search-patches "alsa-lib-mips-atomic-fix.patch"))))
838 (build-system gnu-build-system)
839 (home-page "http://www.alsa-project.org/")
840 (synopsis "The Advanced Linux Sound Architecture libraries")
842 "The Advanced Linux Sound Architecture (ALSA) provides audio and
843 MIDI functionality to the Linux-based operating system.")
844 (license license:lgpl2.1+)))
846 (define-public alsa-utils
852 (uri (string-append "ftp://ftp.alsa-project.org/pub/utils/"
853 name "-" version ".tar.bz2"))
856 "0wcha78c2sm8qqk5r3w83cvm8fp6fb1zpd35kmcm24kxhz007xks"))))
857 (build-system gnu-build-system)
859 ;; XXX: Disable man page creation until we have DocBook.
860 '(#:configure-flags (list "--disable-xmlto"
862 ;; The udev rule is responsible for restoring
864 (string-append "--with-udev-rules-dir="
865 (assoc-ref %outputs "out")
866 "/lib/udev/rules.d"))
868 (modify-phases %standard-phases
870 'install 'pre-install
872 ;; Don't try to mkdir /var/lib/alsa.
873 (substitute* "Makefile"
874 (("\\$\\(MKDIR_P\\) .*ASOUND_STATE_DIR.*")
877 `(("libsamplerate" ,libsamplerate)
879 ("alsa-lib" ,alsa-lib)
881 ("gettext" ,gettext-minimal)))
882 (home-page "http://www.alsa-project.org/")
883 (synopsis "Utilities for the Advanced Linux Sound Architecture (ALSA)")
885 "The Advanced Linux Sound Architecture (ALSA) provides audio and
886 MIDI functionality to the Linux-based operating system.")
888 ;; This is mostly GPLv2+ but a few files such as 'alsactl.c' are
890 (license license:gpl2)))
892 (define-public iptables
899 "http://www.netfilter.org/projects/iptables/files/iptables-"
903 "1q6kg7sf0pgpq0qhab6sywl23cngxxfzc9zdzscsba8x09l4q02j"))))
904 (build-system gnu-build-system)
906 '(#:tests? #f ; no test suite
907 #:configure-flags ; add $libdir to the RUNPATH of executables
908 (list (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib"))))
909 (home-page "http://www.netfilter.org/projects/iptables/index.html")
910 (synopsis "Program to configure the Linux IP packet filtering rules")
912 "iptables is the userspace command line program used to configure the
913 Linux 2.4.x and later IPv4 packet filtering ruleset (firewall). It is targeted at
914 system administrators. Since Network Address Translation is also configured
915 from the packet filter ruleset, iptables is used for this, too. The iptables
916 package also includes ip6tables. ip6tables is used for configuring the IPv6
918 (license license:gpl2+)))
920 (define-public iproute
927 "mirror://kernel.org/linux/utils/net/iproute2/iproute2-"
931 "05351m4m0whsivlblvs3m0nz5q9v6r06ik80z27gf6ca51kw74dw"))))
932 (build-system gnu-build-system)
934 `(#:tests? #f ; no test suite
935 #:make-flags (let ((out (assoc-ref %outputs "out")))
937 (string-append "LIBDIR=" out "/lib")
938 (string-append "SBINDIR=" out "/sbin")
939 (string-append "CONFDIR=" out "/etc")
940 (string-append "DOCDIR=" out "/share/doc/"
942 (string-append "MANDIR=" out "/share/man")))
943 #:phases (modify-phases %standard-phases
944 (add-before 'install 'pre-install
946 ;; Don't attempt to create /var/lib/arpd.
947 (substitute* "Makefile"
948 (("^.*ARPDDIR.*$") "")))))))
950 `(("iptables" ,iptables)
953 `(("pkg-config" ,pkg-config)
957 "http://www.linuxfoundation.org/collaborate/workgroups/networking/iproute2")
959 "Utilities for controlling TCP/IP networking and traffic in Linux")
961 "Iproute2 is a collection of utilities for controlling TCP/IP
962 networking and traffic with the Linux kernel.
964 Most network configuration manuals still refer to ifconfig and route as the
965 primary network configuration tools, but ifconfig is known to behave
966 inadequately in modern network environments. They should be deprecated, but
967 most distros still include them. Most network configuration systems make use
968 of ifconfig and thus provide a limited feature set. The /etc/net project aims
969 to support most modern network technologies, as it doesn't use ifconfig and
970 allows a system administrator to make use of all iproute2 features, including
973 iproute2 is usually shipped in a package called iproute or iproute2 and
974 consists of several tools, of which the most important are ip and tc. ip
975 controls IPv4 and IPv6 configuration and tc stands for traffic control. Both
976 tools print detailed usage messages and are accompanied by a set of
978 (license license:gpl2+)))
980 (define-public net-tools
981 ;; XXX: This package is basically unmaintained, but it provides a few
982 ;; commands not yet provided by Inetutils, such as 'route', so we have to
987 (home-page "http://net-tools.sourceforge.net/")
990 (uri (list (string-append
991 "mirror://sourceforge/net-tools/net-tools-"
994 "http://distro.ibiblio.org/rootlinux/rootlinux-ports"
995 "/base/net-tools/net-tools-1.60.tar.bz2")))
998 "0yvxrzk0mzmspr7sa34hm1anw6sif39gyn85w4c5ywfn8inxvr3s"))
999 (patches (search-patches "net-tools-bitrot.patch"))))
1000 (build-system gnu-build-system)
1002 '(#:modules ((guix build gnu-build-system)
1006 #:phases (alist-cons-after
1008 (lambda* (#:key inputs #:allow-other-keys)
1009 (define (apply-patch file)
1010 (zero? (system* "patch" "-p1" "--force"
1013 (let ((patch.gz (assoc-ref inputs "patch")))
1014 (format #t "applying Debian patch set '~a'...~%"
1016 (system (string-append "gunzip < " patch.gz " > the-patch"))
1017 (and (apply-patch "the-patch")
1018 (for-each apply-patch
1019 (find-files "debian/patches"
1023 (lambda* (#:key outputs #:allow-other-keys)
1024 (let ((out (assoc-ref outputs "out")))
1025 (mkdir-p (string-append out "/bin"))
1026 (mkdir-p (string-append out "/sbin"))
1028 ;; Pretend we have everything...
1029 (system "yes | make config")
1031 ;; ... except for the things we don't have.
1032 ;; HAVE_AFDECnet requires libdnet, which we don't have.
1033 ;; HAVE_HWSTRIP and HAVE_HWTR require kernel headers
1034 ;; that have been removed.
1035 (substitute* '("config.make" "config.h")
1036 (("^.*HAVE_(AFDECnet|HWSTRIP|HWTR)[ =]1.*$") ""))))
1038 'install 'remove-redundant-commands
1039 (lambda* (#:key outputs #:allow-other-keys)
1040 ;; Remove commands and man pages redundant with
1042 (let* ((out (assoc-ref outputs "out"))
1043 (dup (append-map (cut find-files out <>)
1045 "^(yp|nis|dns)?domainname"))))
1046 (for-each delete-file dup)
1050 ;; Binaries that depend on libnet-tools.a don't declare that
1051 ;; dependency, making it parallel-unsafe.
1052 #:parallel-build? #f
1054 #:tests? #f ; no test suite
1055 #:make-flags (let ((out (assoc-ref %outputs "out")))
1057 (string-append "BASEDIR=" out)
1058 (string-append "INSTALLNLSDIR=" out "/share/locale")
1059 (string-append "mandir=/share/man")))))
1061 ;; Use the big Debian patch set (the thing does not even compile out of
1063 (inputs `(("patch" ,(origin
1066 "http://ftp.de.debian.org/debian/pool/main/n/net-tools/net-tools_1.60-24.2.diff.gz")
1069 "0p93lsqx23v5fv4hpbrydmfvw1ha2rgqpn2zqbs2jhxkzhjc030p"))))))
1070 (native-inputs `(("gettext" ,gettext-minimal)))
1072 (synopsis "Tools for controlling the network subsystem in Linux")
1074 "This package includes the important tools for controlling the network
1075 subsystem of the Linux kernel. This includes arp, hostname, ifconfig,
1076 netstat, rarp and route. Additionally, this package contains utilities
1077 relating to particular network hardware types (plipconfig, slattach) and
1078 advanced aspects of IP configuration (iptunnel, ipmaddr).")
1079 (license license:gpl2+)))
1081 (define-public libcap
1088 "mirror://kernel.org/linux/libs/security/linux-privs/"
1089 "libcap2/libcap-" version ".tar.xz"))
1092 "0rbc9qbqs5bp9am9s9g83wxj5k4ixps2agy9dxr1v1fwg27mdr6f"))))
1093 (build-system gnu-build-system)
1094 (arguments '(#:phases
1095 (modify-phases %standard-phases
1097 ;; Add $libdir to the RUNPATH of executables.
1099 (substitute* "Make.Rules"
1101 (string-append "LDFLAGS := -Wl,-rpath="
1102 %output "/lib"))))))
1103 #:tests? #f ; no 'check' target
1104 #:make-flags (list "lib=lib"
1105 (string-append "prefix="
1106 (assoc-ref %outputs "out"))
1107 "RAISE_SETFCAP=no")))
1108 (native-inputs `(("perl" ,perl)))
1109 (inputs `(("attr" ,attr)))
1110 (home-page "https://sites.google.com/site/fullycapable/")
1111 (synopsis "Library for working with POSIX capabilities")
1113 "Libcap2 provides a programming interface to POSIX capabilities on
1114 Linux-based operating systems.")
1116 ;; License is BSD-3 or GPLv2, at the user's choice.
1117 (license license:gpl2)))
1119 (define-public bridge-utils
1121 (name "bridge-utils")
1125 (uri (string-append "mirror://sourceforge/bridge/bridge/"
1126 "bridge-utils-" version ".tar.gz"))
1129 "12367cwqmi0yqphi6j8rkx97q8hw52yq2fx4k0xfclkcizxybya2"))))
1130 (build-system gnu-build-system)
1132 ;; The tarball lacks all the generated files.
1133 (native-inputs `(("autoconf" ,autoconf)
1134 ("automake" ,automake)))
1136 '(#:phases (alist-cons-after
1139 ;; Fix "field ‘ip6’ has incomplete type" errors.
1140 (substitute* "libbridge/libbridge.h"
1141 (("#include <linux/if_bridge.h>")
1142 "#include <linux/in6.h>\n#include <linux/if_bridge.h>"))
1144 ;; Ensure that the entire build fails if one of the
1145 ;; sub-Makefiles fails.
1146 (substitute* "Makefile.in"
1147 (("\\$\\(MAKE\\) \\$\\(MFLAGS\\) -C \\$\\$x ;")
1148 "$(MAKE) $(MFLAGS) -C $$x || exit 1;"))
1150 (zero? (system* "autoreconf" "-vf")))
1152 #:tests? #f)) ; no 'check' target
1155 "http://www.linuxfoundation.org/collaborate/workgroups/networking/bridge")
1156 (synopsis "Manipulate Ethernet bridges")
1158 "Utilities for Linux's Ethernet bridging facilities. A bridge is a way
1159 to connect two Ethernet segments together in a protocol independent way.
1160 Packets are forwarded based on Ethernet address, rather than IP address (like
1161 a router). Since forwarding is done at Layer 2, all protocols can go
1162 transparently through a bridge.")
1163 (license license:gpl2+)))
1165 (define-public libnl
1172 "http://www.infradead.org/~tgr/libnl/files/libnl-"
1176 "1icfrv8yihcb74as1gcgmp0wfpdq632q2zvbvqqvjms9cy87bswb"))))
1177 (build-system gnu-build-system)
1178 (native-inputs `(("flex" ,flex) ("bison" ,bison)))
1179 (home-page "http://www.infradead.org/~tgr/libnl/")
1180 (synopsis "NetLink protocol library suite")
1182 "The libnl suite is a collection of libraries providing APIs to netlink
1183 protocol based Linux kernel interfaces. Netlink is an IPC mechanism primarily
1184 between the kernel and user space processes. It was designed to be a more
1185 flexible successor to ioctl to provide mainly networking related kernel
1186 configuration and monitoring interfaces.")
1188 ;; Most files are LGPLv2.1-only, but some are GPLv2-only (like
1189 ;; 'nl-addr-add.c'), so the result is GPLv2-only.
1190 (license license:gpl2)))
1199 "mirror://kernel.org/software/network/iw/iw-"
1203 "085jyvrxzarvn5jl0fk618jjxy50nqx7ifngszc4jxk6a4ddibd6"))))
1204 (build-system gnu-build-system)
1205 (native-inputs `(("pkg-config" ,pkg-config)))
1206 (inputs `(("libnl" ,libnl)))
1208 `(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
1210 #:phases (alist-delete 'configure %standard-phases)))
1211 (home-page "https://wireless.wiki.kernel.org/")
1212 (synopsis "Tool for configuring wireless devices")
1214 "iw is a new nl80211 based CLI configuration utility for wireless
1215 devices. It replaces @code{iwconfig}, which is deprecated.")
1216 (license license:isc)))
1218 (define-public powertop
1226 "https://01.org/sites/default/files/downloads/powertop/powertop-"
1230 "0nlwazxbnn0k6q5f5b09wdhw0f194lpzkp3l7vxansqhfczmcyx8"))))
1231 (build-system gnu-build-system)
1234 (modify-phases %standard-phases
1235 ;; TODO: Patch some hardcoded "wlan0" in calibrate/calibrate.cpp to
1236 ;; allow calibrating the network interface in GuixSD.
1237 (add-after 'unpack 'patch-absolute-file-names
1238 (lambda* (#:key inputs #:allow-other-keys)
1239 (let ((kmod (assoc-ref inputs "kmod")))
1240 (substitute* (find-files "src" "\\.cpp$")
1241 ;; Give the right 'modprobe' file name so that essential
1242 ;; modules such as msr.ko can be loaded.
1243 (("/sbin/modprobe") (string-append kmod "/bin/modprobe"))
1244 ;; These programs are only needed to calibrate, so using
1245 ;; relative file names avoids adding extra inputs. When they
1246 ;; are missing powertop gracefully handles it.
1247 (("/usr/bin/hcitool") "hcitool")
1248 (("/usr/bin/xset") "xset")
1249 (("/usr/sbin/hciconfig") "hciconfig"))
1254 ("ncurses" ,ncurses)
1255 ("pciutils" ,pciutils)
1258 `(("pkg-config" ,pkg-config)))
1259 (home-page "https://01.org/powertop/")
1260 (synopsis "Analyze power consumption on Intel-based laptops")
1262 "PowerTOP is a Linux tool to diagnose issues with power consumption and
1263 power management. In addition to being a diagnostic tool, PowerTOP also has
1264 an interactive mode where the user can experiment various power management
1265 settings for cases where the operating system has not enabled these
1267 (license license:gpl2)))
1269 (define-public aumix
1276 "http://www.jpj.net/~trevor/aumix/releases/aumix-"
1277 version ".tar.bz2"))
1280 "0a8fwyxnc5qdxff8sl2sfsbnvgh6pkij4yafiln0fxgg6bal7knj"))))
1281 (build-system gnu-build-system)
1282 (inputs `(("ncurses" ,ncurses)))
1283 (home-page "http://www.jpj.net/~trevor/aumix.html")
1284 (synopsis "Audio mixer for X and the console")
1286 "Aumix adjusts an audio mixer from X, the console, a terminal,
1287 the command line or a script.")
1288 (license license:gpl2+)))
1290 (define-public iotop
1297 (uri (string-append "http://guichaz.free.fr/iotop/files/iotop-"
1300 "1kp8mqg2pbxq4xzpianypadfxcsyfgwcaqgqia6h9fsq6zyh4z0s"))))
1301 (build-system python-build-system)
1303 ;; The setup.py script expects python-2.
1304 `(#:python ,python-2
1305 ;; There are currently no checks in the package.
1307 (native-inputs `(("python" ,python-2)))
1308 (home-page "http://guichaz.free.fr/iotop/")
1310 "Displays the IO activity of running processes")
1312 "Iotop is a Python program with a top like user interface to show the
1313 processes currently causing I/O.")
1314 (license license:gpl2+)))
1322 (uri (string-append "https://github.com/libfuse/libfuse/releases/"
1323 "download/fuse-" version
1324 "/fuse-" version ".tar.gz"))
1327 "0szi2vlsjxg03y4ji51jks34p269jqj5ify6l0ajsqq6f6y8pd0c"))))
1328 (build-system gnu-build-system)
1329 (inputs `(("util-linux" ,util-linux)))
1331 '(#:configure-flags (list (string-append "MOUNT_FUSE_PATH="
1332 (assoc-ref %outputs "out")
1334 (string-append "INIT_D_PATH="
1335 (assoc-ref %outputs "out")
1338 ;; The rule makes /dev/fuse 666.
1339 (string-append "UDEV_RULES_PATH="
1340 (assoc-ref %outputs "out")
1341 "/lib/udev/rules.d"))
1342 #:phases (alist-cons-before
1343 'build 'set-file-names
1344 (lambda* (#:key inputs #:allow-other-keys)
1345 ;; libfuse calls out to mount(8) and umount(8). Make sure
1346 ;; it refers to the right ones.
1347 (substitute* '("lib/mount_util.c" "util/mount_util.c")
1348 (("/bin/(u?)mount" _ maybe-u)
1349 (string-append (assoc-ref inputs "util-linux")
1350 "/bin/" maybe-u "mount")))
1351 (substitute* '("util/mount.fuse.c")
1355 ;; This hack leads libfuse to search for 'fusermount' in
1356 ;; $PATH, where it may find a setuid-root binary, instead of
1357 ;; trying solely $out/sbin/fusermount and failing because
1359 (substitute* "lib/Makefile"
1360 (("-DFUSERMOUNT_DIR=[[:graph:]]+")
1361 "-DFUSERMOUNT_DIR=\\\"/var/empty\\\"")))
1363 (home-page "https://github.com/libfuse/libfuse")
1364 (synopsis "Support file systems implemented in user space")
1366 "As a consequence of its monolithic design, file system code for Linux
1367 normally goes into the kernel itself---which is not only a robustness issue,
1368 but also an impediment to system extensibility. FUSE, for \"file systems in
1369 user space\", is a kernel module and user-space library that tries to address
1370 part of this problem by allowing users to run file system implementations as
1371 user-space processes.")
1372 (license (list license:lgpl2.1 ;library
1373 license:gpl2+)))) ;command-line utilities
1375 (define-public unionfs-fuse
1377 (name "unionfs-fuse")
1382 "http://podgorny.cz/unionfs-fuse/releases/unionfs-fuse-"
1386 "0qpnr4czgc62vsfnmv933w62nq3xwcbnvqch72qakfgca75rsp4d"))))
1387 (build-system cmake-build-system)
1388 (inputs `(("fuse" ,fuse)))
1389 (arguments '(#:tests? #f)) ; no tests
1390 (home-page "http://podgorny.cz/moin/UnionFsFuse")
1391 (synopsis "User-space union file system")
1393 "UnionFS-FUSE is a flexible union file system implementation in user
1394 space, using the FUSE library. Mounting a union file system allows you to
1395 \"aggregate\" the contents of several directories into a single mount point.
1396 UnionFS-FUSE additionally supports copy-on-write.")
1397 (license license:bsd-3)))
1400 (package (inherit fuse)
1401 (name "fuse-static")
1402 (source (origin (inherit (package-source fuse))
1403 (modules '((guix build utils)))
1405 ;; Normally libfuse invokes mount(8) so that /etc/mtab is
1406 ;; updated. Change calls to 'mtab_needs_update' to 0 so that
1407 ;; it doesn't do that, allowing us to remove the dependency on
1408 ;; util-linux (something that is useful in initrds.)
1409 '(substitute* '("lib/mount_util.c"
1410 "util/mount_util.c")
1411 (("mtab_needs_update[[:blank:]]*\\([a-z_]+\\)")
1416 (define-public unionfs-fuse/static
1417 (package (inherit unionfs-fuse)
1418 (synopsis "User-space union file system (statically linked)")
1419 (name (string-append (package-name unionfs-fuse) "-static"))
1420 (source (origin (inherit (package-source unionfs-fuse))
1421 (modules '((guix build utils)))
1423 ;; Add -ldl to the libraries, because libfuse.a needs that.
1424 '(substitute* "src/CMakeLists.txt"
1425 (("target_link_libraries(.*)\\)" _ libs)
1426 (string-append "target_link_libraries"
1430 #:configure-flags '("-DCMAKE_EXE_LINKER_FLAGS=-static")
1431 #:phases (alist-cons-after
1432 'install 'post-install
1433 (lambda* (#:key outputs #:allow-other-keys)
1434 (let* ((out (assoc-ref outputs "out"))
1435 (exe (string-append out "/bin/unionfs")))
1436 ;; By default, 'unionfs' keeps references to
1437 ;; $glibc/share/locale and similar stuff. Remove them.
1438 (remove-store-references exe)))
1440 (inputs `(("fuse" ,fuse-static)))))
1442 (define-public sshfs-fuse
1448 (uri (string-append "https://github.com/libfuse/sshfs/releases/"
1449 "download/sshfs_" version
1450 "/sshfs-" version ".tar.gz"))
1453 "08mdd4rs7yys7hmyig6i08qlid76p17xlvrh64k7wsrfs1s92s3z"))))
1454 (build-system gnu-build-system)
1459 `(("pkg-config" ,pkg-config)))
1460 (home-page "http://fuse.sourceforge.net/sshfs.html")
1461 (synopsis "Mount remote file systems over SSH")
1463 "This is a file system client based on the SSH File Transfer Protocol.
1464 Since most SSH servers already support this protocol it is very easy to set
1465 up: on the server side there's nothing to do; on the client side mounting the
1466 file system is as easy as logging into the server with an SSH client.")
1467 (license license:gpl2+)))
1469 (define-public numactl
1476 "ftp://oss.sgi.com/www/projects/libnuma/download/numactl-"
1481 "0qbqa9gac2vlahrngi553hws2mqgqdwv2lc69a3yx4gq6l90j325"))))
1482 (build-system gnu-build-system)
1484 '(;; There's a 'test' target, but it requires NUMA support in the kernel
1485 ;; to run, which we can't assume to have.
1488 ;; NUMA is apparently not supported on armhf, see
1489 ;; http://www.spinics.net/lists/linux-numa/msg01157.html
1490 (supported-systems (delete "armhf-linux" %supported-systems))
1491 (home-page "http://oss.sgi.com/projects/libnuma/")
1492 (synopsis "Tools for non-uniform memory access (NUMA) machines")
1494 "NUMA stands for Non-Uniform Memory Access, in other words a system whose
1495 memory is not all in one place. The numactl program allows you to run your
1496 application program on specific CPU's and memory nodes. It does this by
1497 supplying a NUMA memory policy to the operating system before running your
1500 The package contains other commands, such as numademo, numastat and memhog.
1501 The numademo command provides a quick overview of NUMA performance on your
1503 (license (list license:gpl2 ;programs
1504 license:lgpl2.1)))) ;library
1512 (uri (string-append "mirror://kernel.org/linux/utils/kbd/kbd-"
1516 "0ppv953gn2zylcagr4z6zg5y2x93dxrml29plypg6xgbq3hrv2bs"))
1517 (modules '((guix build utils)))
1520 (substitute* "tests/Makefile.in"
1521 ;; The '%: %.in' rule incorrectly uses @VERSION@.
1524 (substitute* '("src/unicode_start" "src/unicode_stop")
1525 ;; Assume the Coreutils are in $PATH.
1528 (build-system gnu-build-system)
1531 (modify-phases %standard-phases
1532 (add-before 'build 'pre-build
1533 (lambda* (#:key inputs #:allow-other-keys)
1534 (let ((gzip (assoc-ref %build-inputs "gzip"))
1535 (bzip2 (assoc-ref %build-inputs "bzip2")))
1536 (substitute* "src/libkeymap/findfile.c"
1538 (string-append gzip "/bin/gzip"))
1540 (string-append bzip2 "/bin/bzip2"))))))
1541 (add-after 'install 'post-install
1542 (lambda* (#:key outputs #:allow-other-keys)
1543 ;; Make sure these programs find their comrades.
1544 (let* ((out (assoc-ref outputs "out"))
1545 (bin (string-append out "/bin")))
1546 (for-each (lambda (prog)
1547 (wrap-program (string-append bin "/" prog)
1548 `("PATH" ":" prefix (,bin))))
1549 '("unicode_start" "unicode_stop"))))))))
1550 (inputs `(("check" ,check)
1553 ("pam" ,linux-pam)))
1554 (native-inputs `(("pkg-config" ,pkg-config)))
1555 (home-page "ftp://ftp.kernel.org/pub/linux/utils/kbd/")
1556 (synopsis "Linux keyboard utilities and keyboard maps")
1558 "This package contains keytable files and keyboard utilities compatible
1559 for systems using the Linux kernel. This includes commands such as
1560 'loadkeys', 'setfont', 'kbdinfo', and 'chvt'.")
1561 (license license:gpl2+)))
1563 (define-public inotify-tools
1565 (name "inotify-tools")
1570 "mirror://sourceforge/inotify-tools/inotify-tools/"
1571 version "/inotify-tools-" version ".tar.gz"))
1574 "0icl4bx041axd5dvhg89kilfkysjj86hjakc7bk8n49cxjn4cha6"))))
1575 (build-system gnu-build-system)
1576 (home-page "http://inotify-tools.sourceforge.net/")
1577 (synopsis "Monitor file accesses")
1579 "The inotify-tools packages provides a C library and command-line tools
1580 to use Linux' inotify mechanism, which allows file accesses to be monitored.")
1581 (license license:gpl2+)))
1590 (string-append "mirror://kernel.org/linux/utils/kernel/kmod/"
1591 "kmod-" version ".tar.xz"))
1594 "10lzfkmnpq6a43a3gkx7x633njh216w0bjwz31rv8a1jlgg1sfxs"))
1595 (patches (search-patches "kmod-module-directory.patch"))))
1596 (build-system gnu-build-system)
1598 `(("pkg-config" ,pkg-config)))
1603 `(#:tests? #f ; FIXME: Investigate test failures
1604 #:configure-flags '("--with-xz" "--with-zlib")
1605 #:phases (alist-cons-after
1606 'install 'install-modprobe&co
1607 (lambda* (#:key outputs #:allow-other-keys)
1608 (let* ((out (assoc-ref outputs "out"))
1609 (bin (string-append out "/bin")))
1610 (for-each (lambda (tool)
1612 (string-append bin "/" tool)))
1613 '("insmod" "rmmod" "lsmod" "modprobe"
1614 "modinfo" "depmod"))))
1616 (home-page "https://www.kernel.org/")
1617 (synopsis "Kernel module tools")
1618 (description "Kmod is a set of tools to handle common tasks with Linux
1619 kernel modules like insert, remove, list, check properties, resolve
1620 dependencies and aliases.
1622 These tools are designed on top of libkmod, a library that is shipped with
1623 kmod. The aim is to be compatible with tools, configurations and indices
1624 from the module-init-tools project.")
1625 (license license:gpl2+))) ; library under lgpl2.1+
1627 (define-public eudev
1628 ;; The post-systemd fork, maintained by Gentoo.
1635 "http://dev.gentoo.org/~blueness/eudev/eudev-"
1639 "099w62ncq78nxpxizf910mx18hc8x4qvzw3azjd00fir89wmyjnq"))
1640 (patches (search-patches "eudev-rules-directory.patch"))))
1641 (build-system gnu-build-system)
1643 `(("pkg-config" ,pkg-config)
1647 ;; When linked against libblkid, eudev can populate /dev/disk/by-label
1648 ;; and similar; it also installs the '60-persistent-storage.rules' file,
1649 ;; which contains the rules to do that.
1650 `(("util-linux" ,util-linux) ;for blkid
1652 (home-page "https://wiki.gentoo.org/wiki/Project:Eudev")
1653 (synopsis "Userspace device management")
1654 (description "Udev is a daemon which dynamically creates and removes
1655 device nodes from /dev/, handles hotplug events and loads drivers at boot
1657 (license license:gpl2+)))
1662 (version "2.02.166")
1665 (uri (string-append "ftp://sources.redhat.com/pub/lvm2/releases/LVM2."
1669 "150v0mawd2swdvypcmkjd3h3s4n5i1220h6sxx94a8jvp1kb0871"))
1670 (modules '((guix build utils)))
1673 (use-modules (guix build utils))
1675 ;; Honor sysconfdir.
1676 (substitute* "make.tmpl.in"
1678 "confdir = @sysconfdir@\n")
1679 (("DEFAULT_SYS_DIR = @DEFAULT_SYS_DIR@")
1680 "DEFAULT_SYS_DIR = @sysconfdir@"))))))
1681 (build-system gnu-build-system)
1683 `(("pkg-config" ,pkg-config)
1684 ("procps" ,procps))) ;tests use 'pgrep'
1689 (modify-phases %standard-phases
1690 (add-after 'configure 'set-makefile-shell
1692 ;; Use 'sh', not 'bash', so that '. lib/utils.sh' works as
1694 (setenv "SHELL" (which "sh"))
1696 ;; Replace /bin/sh with the right file name.
1697 (patch-makefile-SHELL "make.tmpl")
1699 (add-before 'strip 'make-objects-writable
1700 (lambda* (#:key outputs #:allow-other-keys)
1701 ;; Make compiled objects writable so they can be stripped.
1702 (let ((out (assoc-ref outputs "out")))
1703 (for-each (lambda (file)
1706 (find-files (string-append out "/lib"))
1707 (find-files (string-append out "/sbin"))))
1710 #:configure-flags (list (string-append "--sysconfdir="
1711 (assoc-ref %outputs "out")
1713 "--enable-udev_sync"
1714 "--enable-udev_rules"
1716 ;; Make sure programs such as 'dmsetup' can
1717 ;; find libdevmapper.so.
1718 (string-append "LDFLAGS=-Wl,-rpath="
1719 (assoc-ref %outputs "out")
1722 ;; The tests use 'mknod', which requires root access.
1724 (home-page "http://sourceware.org/lvm2/")
1725 (synopsis "Logical volume management for Linux")
1727 "LVM2 is the logical volume management tool set for Linux-based systems.
1728 This package includes the user-space libraries and tools, including the device
1729 mapper. Kernel components are part of Linux-libre.")
1731 ;; Libraries (liblvm2, libdevmapper) are LGPLv2.1.
1732 ;; Command-line tools are GPLv2.
1733 (license (list license:gpl2 license:lgpl2.1))))
1735 (define-public wireless-tools
1737 (name "wireless-tools")
1741 (uri (string-append "http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/wireless_tools."
1745 "0qscyd44jmhs4k32ggp107hlym1pcyjzihiai48xs7xzib4wbndb"))
1748 ;; Remove the older header files that are not free software.
1749 (for-each (lambda (n)
1750 (delete-file (format #f "wireless.~a.h" n)))
1751 '(10 11 12 13 14 15 16 17 18 19 20))
1753 (build-system gnu-build-system)
1756 (list (string-append "PREFIX=" %output)
1757 (string-append "INSTALL_MAN=" %output "/share/man")
1758 (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib")
1760 #:phases (modify-phases %standard-phases
1761 (delete 'configure))
1763 (synopsis "Tools for manipulating Linux Wireless Extensions")
1764 (description "Wireless Tools are used to manipulate the now-deprecated
1765 Linux Wireless Extensions; consider using 'iw' instead. The Wireless
1766 Extension was an interface allowing you to set Wireless LAN specific
1767 parameters and get the specific stats. It is deprecated in favor the nl80211
1769 (home-page "http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/Tools.html")
1770 ;; wireless.21.h and wireless.22.h are distributed under lgpl2.1+, the
1771 ;; other files are distributed under gpl2.
1772 (license (list license:gpl2 license:lgpl2.1+))))
1780 (uri (string-append "mirror://kernel.org/software/network/crda/"
1781 "crda-" version ".tar.xz"))
1784 "1gydiqgb08d9gbx4l6gv98zg3pljc984m50hmn3ysxcbkxkvkz23"))
1785 (patches (search-patches "crda-optional-gcrypt.patch"))))
1786 (build-system gnu-build-system)
1788 '(#:phases (modify-phases %standard-phases
1791 'build 'no-werror-no-ldconfig
1793 (substitute* "Makefile"
1795 (("ldconfig") "true"))
1798 'build 'set-regulator-db-file-name
1799 (lambda* (#:key inputs #:allow-other-keys)
1800 ;; Tell CRDA where to find our database.
1801 (let ((regdb (assoc-ref inputs "wireless-regdb")))
1802 (substitute* "crda.c"
1803 (("\"/lib/crda/regulatory.bin\"")
1804 (string-append "\"" regdb
1805 "/lib/crda/regulatory.bin\"")))
1807 #:test-target "verify"
1808 #:make-flags (let ((out (assoc-ref %outputs "out"))
1809 (regdb (assoc-ref %build-inputs "wireless-regdb")))
1810 (list "CC=gcc" "V=1"
1812 ;; Disable signature-checking on 'regulatory.bin'.
1813 ;; The reason is that this simplifies maintenance
1814 ;; on our side (no need to manage a distro key
1815 ;; pair), and we can guarantee integrity of
1816 ;; 'regulatory.bin' by other means anyway, such as
1817 ;; 'guix gc --verify'. See
1818 ;; <https://wireless.wiki.kernel.org/en/developers/regulatory/wireless-regdb>
1822 (string-append "PREFIX=" out)
1823 (string-append "SBINDIR=" out "/sbin/")
1824 (string-append "UDEV_RULE_DIR="
1825 out "/lib/udev/rules.d")
1826 (string-append "LDFLAGS=-Wl,-rpath="
1828 (string-append "REG_BIN=" regdb
1829 "/lib/crda/regulatory.bin")))))
1830 (native-inputs `(("pkg-config" ,pkg-config)
1831 ("python" ,python-2)
1832 ("wireless-regdb" ,wireless-regdb)))
1833 (inputs `(("libnl" ,libnl)))
1835 "https://wireless.wiki.kernel.org/en/developers/Regulatory/CRDA")
1836 (synopsis "Central regulatory domain agent (CRDA) for WiFi")
1838 "The Central Regulatory Domain Agent (CRDA) acts as the udev helper for
1839 communication between the kernel Linux and user space for regulatory
1841 (license license:copyleft-next)))
1843 (define-public wireless-regdb
1845 (name "wireless-regdb")
1846 (version "2016.05.02")
1850 "mirror://kernel.org/software/network/wireless-regdb/"
1851 "wireless-regdb-" version ".tar.xz"))
1854 "07n6gcwfbddz3awbdflv3dhxjszsqq2lrdwih0a0ahcliac4qry9"))
1856 ;; We're building 'regulatory.bin' by ourselves.
1857 (snippet '(delete-file "regulatory.bin"))))
1858 (build-system gnu-build-system)
1860 '(#:phases (modify-phases %standard-phases
1861 (delete 'configure))
1863 ;; The 'all' target of the makefile depends on $(REGDB_CHANGED), which
1864 ;; is computed and can be equal to 'maintainer-clean'; when that
1865 ;; happens, we can end up deleting the 'regulatory.bin' file that we
1866 ;; just built. Thus, build things sequentially.
1867 #:parallel-build? #f
1869 #:tests? #f ;no tests
1870 #:make-flags (let ((out (assoc-ref %outputs "out")))
1871 (list (string-append "PREFIX=" out)
1872 (string-append "LSB_ID=GuixSD")
1873 (string-append "DISTRO_PUBKEY=/dev/null")
1874 (string-append "DISTRO_PRIVKEY=/dev/null")
1875 (string-append "REGDB_PUBKEY=/dev/null")
1877 ;; Leave that empty so that db2bin.py doesn't try
1878 ;; to sign 'regulatory.bin'. This allows us to
1879 ;; avoid managing a key pair for the whole distro.
1880 (string-append "REGDB_PRIVKEY=")))))
1881 (native-inputs `(("python" ,python-2)))
1883 "https://wireless.wiki.kernel.org/en/developers/regulatory/wireless-regdb")
1884 (synopsis "Wireless regulatory database")
1886 "This package contains the wireless regulatory database Central
1887 Regulatory Database Agent (CRDA) daemon. The database contains information on
1888 country-specific regulations for the wireless spectrum.")
1889 (license license:isc)))
1891 (define-public lm-sensors
1897 (uri (list (string-append
1898 "https://github.com/groeck/lm-sensors/archive/V"
1899 (string-join (string-split version #\.) "-")
1903 "0knb09s9lvx0wzfsaizx3xq58q6kllqf7nkbwvir0wkgn31c2d73"))
1904 (patches (search-patches "lm-sensors-hwmon-attrs.patch"))))
1905 (build-system gnu-build-system)
1906 (inputs `(("rrdtool" ,rrdtool)
1909 ("gnuplot" ,gnuplot)))
1910 (native-inputs `(("pkg-config" ,pkg-config)
1915 `(#:tests? #f ; no 'check' target
1916 #:make-flags (list (string-append "PREFIX=" %output)
1917 (string-append "ETCDIR=" %output "/etc")
1918 (string-append "MANDIR=" %output "/share/man"))
1923 'build 'patch-exec-paths
1924 (lambda* (#:key inputs outputs #:allow-other-keys)
1925 (substitute* "prog/detect/sensors-detect"
1927 (string-append "`" (assoc-ref inputs "coreutils")
1929 (("(`|\")modprobe" all open-quote)
1930 (string-append open-quote
1931 (assoc-ref inputs "kmod")
1933 (substitute* '("prog/pwm/pwmconfig"
1934 "prog/pwm/fancontrol")
1936 (string-append (assoc-ref inputs "gnuplot")
1939 (string-append (assoc-ref inputs "coreutils")
1942 (string-append (assoc-ref inputs "grep")
1945 (string-append (assoc-ref inputs "sed")
1948 (string-append (assoc-ref inputs "coreutils")
1951 (string-append (assoc-ref inputs "coreutils")
1954 (string-append (assoc-ref inputs "coreutils")
1955 "/bin/readlink -f"))))
1956 %standard-phases))))
1957 (home-page "http://jdelvare.nerim.net/devel.html#lmsensors")
1958 (synopsis "Utilities to read temperature/voltage/fan sensors")
1960 "Lm-sensors is a hardware health monitoring package for Linux. It allows
1961 you to access information from temperature, voltage, and fan speed sensors.
1962 It works with most newer systems.")
1963 (license license:gpl2+)))
1965 (define-public i2c-tools
1972 "http://jdelvare.nerim.net/mirror/i2c-tools/i2c-tools-"
1973 version ".tar.bz2"))
1976 "000pvg995qy1b15ks59gd0klri55hb33kqpg5czy84hw1pbdgm0l"))))
1977 (build-system gnu-build-system)
1979 `(#:tests? #f ; no 'check' target
1980 #:make-flags (list (string-append "prefix=" %output)
1982 ;; no configure script
1983 #:phases (alist-delete 'configure %standard-phases)))
1986 (home-page "http://jdelvare.nerim.net/devel.html#i2ctools")
1987 (synopsis "I2C tools for Linux")
1989 "The i2c-tools package contains a heterogeneous set of I2C tools for
1990 Linux: a bus probing tool, a chip dumper, register-level SMBus access helpers,
1991 EEPROM decoding scripts, EEPROM programming tools, and a python module for
1993 (license license:gpl2+)))
1995 (define-public xsensors
2002 "http://www.linuxhardware.org/xsensors/xsensors-"
2006 "1siplsfgvcxamyqf44h71jx6jdfmvhfm7mh0y1q8ps4zs6pj2zwh"))))
2007 (build-system gnu-build-system)
2008 (inputs `(("lm-sensors" ,lm-sensors)
2010 (native-inputs `(("pkg-config" ,pkg-config)))
2012 `(#:phases (alist-cons-before
2013 'configure 'enable-deprecated
2015 (substitute* "src/Makefile.in"
2016 (("-DGDK_DISABLE_DEPRECATED") "")
2017 (("-DGTK_DISABLE_DEPRECATED") "")))
2019 'configure 'remove-Werror
2021 (substitute* '("configure" "src/Makefile.in")
2023 %standard-phases))))
2024 (home-page "http://www.linuxhardware.org/xsensors/")
2025 (synopsis "Hardware health information viewer")
2027 "Xsensors reads data from the libsensors library regarding hardware
2028 health such as temperature, voltage and fan speed and displays the information
2029 in a digital read-out.")
2030 (license license:gpl2+)))
2035 (version (package-version linux-libre))
2036 (source (package-source linux-libre))
2037 (build-system gnu-build-system)
2039 '(#:phases (alist-replace
2041 (lambda* (#:key inputs #:allow-other-keys)
2042 (setenv "SHELL_PATH" (which "bash"))
2043 (chdir "tools/perf"))
2045 #:make-flags (list (string-append "DESTDIR="
2046 (assoc-ref %outputs "out"))
2049 ;; By default, 'config/Makefile' uses lib64 on
2050 ;; x86_64. Work around that.
2052 #:tests? #f)) ;no tests
2054 `(("pkg-config" ,pkg-config)
2058 ;; There are build scripts written in these languages.
2060 ("python" ,python-2)))
2062 `(("slang" ,slang) ;for the interactive TUI
2064 ("python" ,python-2) ;'perf' links against libpython
2065 ("elfutils" ,elfutils)
2068 ("libxml2" ,libxml2) ;for $XML_CATALOG_FILES
2069 ("libxslt" ,libxslt)
2070 ("docbook-xml" ,docbook-xml)
2071 ("docbook-xsl" ,docbook-xsl)
2073 ("asciidoc" ,asciidoc)))
2074 (home-page "https://perf.wiki.kernel.org/")
2075 (synopsis "Linux profiling with performance counters")
2077 "perf is a tool suite for profiling using hardware performance counters,
2078 with support in the Linux kernel. perf can instrument CPU performance
2079 counters, tracepoints, kprobes, and uprobes (dynamic tracing). It is capable
2080 of lightweight profiling. This package contains the user-land tools and in
2081 particular the 'perf' command.")
2082 (license (package-license linux-libre))))
2084 (define-public pflask
2090 (uri (string-append "https://github.com/ghedo/pflask/archive/v"
2092 (file-name (string-append name "-" version ".tar.gz"))
2095 "1g8fjj67dfkc2s0852l9vqi1pm61gp4rxbpzbzg780f5s5hd1fys"))))
2096 (build-system cmake-build-system)
2098 '(#:tests? #f)) ; no tests
2099 (home-page "http://ghedo.github.io/pflask/")
2100 (synopsis "Simple tool for creating Linux namespace containers")
2101 (description "pflask is a simple tool for creating Linux namespace
2102 containers. It can be used for running a command or even booting an OS inside
2103 an isolated container, created with the help of Linux namespaces. It is
2104 similar in functionality to chroot, although pflask provides better isolation
2105 thanks to the use of namespaces.")
2106 (license license:bsd-2)))
2108 (define-public hdparm
2114 (uri (string-append "mirror://sourceforge/" name "/" name "/"
2115 name "-" version ".tar.gz"))
2118 "0sc6yf3k6sd7n6a2ig2my9fjlqpak3znlyw7jw4cz5d9asm1rc13"))))
2119 (build-system gnu-build-system)
2121 `(#:make-flags (let ((out (assoc-ref %outputs "out")))
2122 (list (string-append "binprefix=" out)
2123 (string-append "manprefix=" out)
2125 #:phases (alist-delete 'configure %standard-phases)
2126 #:tests? #f)) ; no test suite
2127 (home-page "http://sourceforge.net/projects/hdparm/")
2128 (synopsis "Tune hard disk parameters for high performance")
2130 "Get/set device parameters for Linux SATA/IDE drives. It's primary use
2131 is for enabling irq-unmasking and IDE multiple-mode.")
2132 (license (license:non-copyleft "file://LICENSE.TXT"))))
2134 (define-public rfkill
2140 (uri (string-append "mirror://kernel.org/software/network/"
2141 name "/" name "-" version ".tar.xz"))
2144 "0snqj5h0y991lszbigbyyqb8swj0hxajc1vfqg2scfay44231bp0"))))
2145 (build-system gnu-build-system)
2147 `(#:make-flags (list "CC=gcc"
2148 (string-append "PREFIX=" %output))
2149 #:phases (modify-phases %standard-phases
2150 (delete 'configure))
2152 (home-page "https://wireless.wiki.kernel.org/en/users/Documentation/rfkill")
2153 (synopsis "Tool for enabling and disabling wireless devices")
2155 "rfkill is a simple tool for accessing the rfkill device interface,
2156 which is used to enable and disable wireless networking devices, typically
2157 WLAN, Bluetooth and mobile broadband.")
2158 (license (license:non-copyleft "file://COPYING"
2159 "See COPYING in the distribution."))))
2167 (uri (string-append "mirror://sourceforge/acpiclient/acpiclient/"
2168 version "/" name "-" version ".tar.gz"))
2171 "01ahldvf0gc29dmbd5zi4rrnrw2i1ajnf30sx2vyaski3jv099fp"))))
2172 (build-system gnu-build-system)
2173 (home-page "http://acpiclient.sourceforge.net")
2174 (synopsis "Display information on ACPI devices")
2175 (description "@code{acpi} attempts to replicate the functionality of the
2176 \"old\" @code{apm} command on ACPI systems, including battery and thermal
2177 information. It does not support ACPI suspending, only displays information
2178 about ACPI devices.")
2179 (license license:gpl2+)))
2181 (define-public acpid
2187 (uri (string-append "mirror://sourceforge/acpid2/acpid-"
2191 "1vl7c6vc724v4jwki17czgj6lnrknnj1a6llm8gkl32i2gnam5j3"))))
2192 (build-system gnu-build-system)
2193 (home-page "http://sourceforge.net/projects/acpid2/")
2194 (synopsis "Daemon for delivering ACPI events to user-space programs")
2196 "acpid is designed to notify user-space programs of Advanced
2197 Configuration and Power Interface (ACPI) events. acpid should be started
2198 during the system boot, and will run as a background process. When an ACPI
2199 event is received from the kernel, acpid will examine the list of rules
2200 specified in /etc/acpi/events and execute the rules that match the event.")
2201 (license license:gpl2+)))
2203 (define-public sysfsutils
2212 "mirror://sourceforge/linux-diag/sysfsutils/" version "/sysfsutils-"
2215 (base32 "12i0ip11xbfcjzxz4r10cvz7mbzgq1hfcdn97w6zz7sm3wndwrg8"))))
2216 (build-system gnu-build-system)
2217 (home-page "http://linux-diag.sourceforge.net/Sysfsutils.html")
2218 (synopsis "System utilities based on Linux sysfs")
2220 "These are a set of utilities built upon sysfs, a virtual file system in
2221 Linux kernel versions 2.5+ that exposes a system's device tree. The package
2222 also contains the libsysfs library.")
2223 ;; The library is under lgpl2.1+ (all files say "or any later version").
2224 ;; The rest is mostly gpl2, with a few files indicating gpl2+.
2225 (license (list license:gpl2 license:gpl2+ license:lgpl2.1+))))
2227 (define-public sysfsutils-1
2229 (inherit sysfsutils)
2236 "mirror://sourceforge/linux-diag/sysfsutils/sysfsutils-" version
2237 "/sysfsutils-" version ".tar.gz"))
2239 (base32 "0kdhs07fm8263pxwd5blwn2x211cg4fk63fyf9ijcdkvzmwxrqq3"))
2240 (modules '((guix build utils)))
2243 (substitute* "Makefile.in"
2244 (("includedir = /usr/include/sysfs")
2245 "includedir = @includedir@"))
2246 (substitute* "configure"
2247 (("includedir='(\\$\\{prefix\\}/include)'" all orig)
2248 (string-append "includedir='" orig "/sysfs'")))))))
2249 (synopsis "System utilities based on Linux sysfs (version 1.x)")))
2251 (define-public cpufrequtils
2253 (name "cpufrequtils")
2260 "https://www.kernel.org/pub/linux/utils/kernel/cpufreq/cpufrequtils-"
2263 (base32 "0qfqv7nqmjfr3p0bwrdlxkiqwqr7vmx053cadaa548ybqbghxmvm"))
2264 (patches (search-patches "cpufrequtils-fix-aclocal.patch"))))
2265 (build-system gnu-build-system)
2267 `(("sysfsutils" ,sysfsutils-1)))
2269 '(#:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
2270 (assoc-ref %outputs "out") "/lib"))))
2271 (home-page "https://www.kernel.org/pub/linux/utils/kernel/cpufreq/")
2272 (synopsis "Utilities to get and set CPU frequency on Linux")
2274 "The cpufrequtils suite contains utilities to retrieve CPU frequency
2275 information, and set the CPU frequency if supported, using the cpufreq
2276 capabilities of the Linux kernel.")
2277 (license license:gpl2)))
2279 (define-public libraw1394
2286 "mirror://kernel.org/linux/libs/ieee1394/"
2287 name "-" version ".tar.xz"))
2290 "0kwnf4ha45c04mhc4yla672aqmvqqihxix1gvblns5cd2pc2cc8b"))))
2291 (build-system gnu-build-system)
2292 (home-page "https://ieee1394.wiki.kernel.org/index.php/Main_Page")
2293 (synopsis "Interface library for the Linux IEEE1394 drivers")
2295 "Libraw1394 is the only supported interface to the kernel side raw1394 of
2296 the Linux IEEE-1394 subsystem, which provides direct access to the connected
2297 1394 buses to user space. Through libraw1394/raw1394, applications can directly
2298 send to and receive from other nodes without requiring a kernel driver for the
2299 protocol in question.")
2300 (license license:lgpl2.1+)))
2302 (define-public libavc1394
2308 (uri (string-append "mirror://sourceforge/libavc1394/libavc1394/"
2309 name "-" version ".tar.gz"))
2312 "0lsv46jdqvdx5hx92v0z2cz3yh6212pz9gk0k3513sbaa04zzcbw"))))
2313 (build-system gnu-build-system)
2315 `(("pkg-config" ,pkg-config)))
2317 `(("libraw1394" ,libraw1394))) ; required by libavc1394.pc
2318 (home-page "http://sourceforge.net/projects/libavc1394/")
2319 (synopsis "AV/C protocol library for IEEE 1394")
2321 "Libavc1394 is a programming interface to the AV/C specification from
2322 the 1394 Trade Association. AV/C stands for Audio/Video Control.")
2323 (license license:lgpl2.1+)))
2325 (define-public libiec61883
2327 (name "libiec61883")
2332 "mirror://kernel.org/linux/libs/ieee1394/"
2333 name "-" version ".tar.xz"))
2336 "17ph458zya2l8dr2xwqnzy195qd9swrir31g78qkgb3g4xz2rq6i"))))
2337 (build-system gnu-build-system)
2339 `(("pkg-config" ,pkg-config)))
2341 `(("libraw1394" ,libraw1394))) ; required by libiec61883.pc
2342 (home-page "https://ieee1394.wiki.kernel.org/index.php/Main_Page")
2343 (synopsis "Isochronous streaming media library for IEEE 1394")
2345 "The libiec61883 library provides a higher level API for streaming DV,
2346 MPEG-2 and audio over Linux IEEE 1394.")
2347 (license license:lgpl2.1+)))
2349 (define-public mdadm
2356 "mirror://kernel.org/linux/utils/raid/mdadm/mdadm-"
2360 "0248v9f28mrbwabl94ck22gfim29sqhkf70wrpfi52nk4x3bxl17"))))
2361 (build-system gnu-build-system)
2365 `(#:make-flags (let ((out (assoc-ref %outputs "out")))
2366 (list "INSTALL=install"
2368 ;; TODO: tell it where to find 'sendmail'
2369 ;; (string-append "MAILCMD=" <???> "/sbin/sendmail")
2370 (string-append "BINDIR=" out "/sbin")
2371 (string-append "MANDIR=" out "/share/man")
2372 (string-append "UDEVDIR=" out "/lib/udev")))
2373 #:phases (alist-cons-before
2374 'build 'patch-program-paths
2375 (lambda* (#:key inputs #:allow-other-keys)
2376 (let ((coreutils (assoc-ref inputs "coreutils")))
2377 (substitute* "udev-md-raid-arrays.rules"
2378 (("/usr/bin/(readlink|basename)" all program)
2379 (string-append coreutils "/bin/" program)))))
2381 'build 'remove-W-error
2383 ;; We cannot build with -Werror on i686 due to a
2384 ;; 'sign-compare' warning in util.c.
2385 (substitute* "Makefile"
2388 (alist-delete 'configure %standard-phases)))
2389 ;;tests must be done as root
2391 (home-page "http://neil.brown.name/blog/mdadm")
2392 (synopsis "Tool for managing Linux Software RAID arrays")
2394 "mdadm is a tool for managing Linux Software RAID arrays. It can create,
2395 assemble, report on, and monitor arrays. It can also move spares between raid
2396 arrays when needed.")
2397 (license license:gpl2+)))
2399 (define-public libaio
2406 (string-append "mirror://debian/pool/main/liba/libaio/"
2407 name "_" version ".orig.tar.gz")
2408 (string-append "https://fedorahosted.org/releases/l/i/libaio/"
2409 name "-" version ".tar.gz")))
2412 "0zjzfkwd1kdvq6zpawhzisv7qbq1ffs343i5fs9p498pcf7046g0"))))
2413 (build-system gnu-build-system)
2416 (list "CC=gcc" (string-append "prefix=" %output))
2417 #:test-target "partcheck" ; need root for a full 'check'
2419 (alist-delete 'configure %standard-phases))) ; no configure script
2420 (home-page "http://lse.sourceforge.net/io/aio.html")
2421 (synopsis "Linux-native asynchronous I/O access library")
2423 "This library enables userspace to use Linux kernel asynchronous I/O
2424 system calls, important for the performance of databases and other advanced
2426 (license license:lgpl2.1+)))
2434 (uri (string-append "https://www.kernel.org/pub/linux/bluetooth/"
2435 name "-" version ".tar.xz"))
2438 "02ckd2z51z0h85qgv7x8vv8ybp5czm9if1z78411j53gaz7j4476"))))
2439 (build-system gnu-build-system)
2441 `(("libsndfile" ,libsndfile)))
2443 `(("pkg-config" ,pkg-config)))
2444 (home-page "https://www.kernel.org/pub/linux/bluetooth/")
2445 (synopsis "Bluetooth subband audio codec")
2447 "The SBC is a digital audio encoder and decoder used to transfer data to
2448 Bluetooth audio output devices like headphones or loudspeakers.")
2449 (license license:gpl2+)))
2451 (define-public bluez
2458 "mirror://kernel.org/linux/bluetooth/bluez-"
2462 "09ywk3lvgis0nbi0d5z8d4qp5r33lzwnd6bdakacmbsm420qpnns"))))
2463 (build-system gnu-build-system)
2466 (let ((out (assoc-ref %outputs "out")))
2467 (list "--sysconfdir=/etc"
2468 "--localstatedir=/var"
2471 ;; Install dbus/udev files to the correct location.
2472 (string-append "--with-dbusconfdir=" out "/etc")
2473 (string-append "--with-udevdir=" out "/lib/udev")))
2475 (modify-phases %standard-phases
2476 (add-after 'install 'post-install
2477 (lambda* (#:key inputs outputs #:allow-other-keys)
2478 (let* ((out (assoc-ref outputs "out"))
2479 (servicedir (string-append out "/share/dbus-1/services"))
2480 (service "obexd/src/org.bluez.obex.service")
2481 (rule (string-append
2482 out "/lib/udev/rules.d/97-hid2hci.rules")))
2483 ;; Install the obex dbus service file.
2484 (substitute* service
2486 (string-append out "/libexec/bluetooth/obexd")))
2487 (install-file service servicedir)
2488 ;; Fix paths in the udev rule.
2490 (("hid2hci --method")
2491 (string-append out "/lib/udev/hid2hci --method"))
2493 (string-append (assoc-ref inputs "eudev") "/bin/udevadm")))
2496 `(("pkg-config" ,pkg-config)
2497 ("gettext" ,gettext-minimal)))
2502 ("libical" ,libical)
2503 ("readline" ,readline)))
2504 (home-page "http://www.bluez.org/")
2505 (synopsis "Linux Bluetooth protocol stack")
2507 "BlueZ provides support for the core Bluetooth layers and protocols. It
2508 is flexible, efficient and uses a modular implementation.")
2509 (license license:gpl2+)))
2511 (define-public fuse-exfat
2517 (uri "https://docs.google.com/uc?export=download&\
2518 id=0B7CLI-REKbE3VTdaa0EzTkhYdU0")
2521 "0glmgwrf0nv09am54i6s35ksbvrywrwc51w6q32mv5by8475530r"))
2522 (file-name (string-append name "-" version ".tar.gz"))))
2523 (build-system gnu-build-system)
2526 ("pkg-config" ,pkg-config)))
2530 '(#:tests? #f ;no test suite
2532 ;; XXX: Factorize with 'exfat-utils'.
2533 #:phases (modify-phases %standard-phases
2535 (add-after 'unpack 'scons-propagate-environment
2537 ;; Modify the SConstruct file to arrange for
2538 ;; environment variables to be propagated.
2539 (substitute* "SConstruct"
2540 (("^env = Environment\\(")
2541 "env = Environment(ENV=os.environ, "))))
2544 (zero? (system* "scons"))))
2546 (lambda* (#:key outputs #:allow-other-keys)
2547 (let* ((out (assoc-ref outputs "out"))
2548 (bin (string-append out "/bin"))
2549 (man8 (string-append out
2550 "/share/man/man8")))
2553 (for-each (lambda (file)
2556 (string-append man8 "/"
2558 (find-files "." "\\.8$"))
2559 (zero? (system* "scons" "install"
2560 (string-append "DESTDIR="
2562 (home-page "http://code.google.com/p/exfat/")
2563 (synopsis "Mount exFAT file systems")
2565 "This package provides a FUSE-based file system that provides read and
2566 write access to exFAT devices.")
2567 (license license:gpl2+)))
2576 "http://www.nico.schottelius.org/software/gpm/archives/gpm-"
2577 version ".tar.bz2"))
2580 "13d426a8h403ckpc8zyf7s2p5rql0lqbg2bv0454x0pvgbfbf4gh"))))
2581 (build-system gnu-build-system)
2583 '(#:phases (modify-phases %standard-phases
2584 (add-before 'configure 'bootstrap
2586 ;; The tarball was not generated with 'make dist' so we
2587 ;; need to bootstrap things ourselves.
2588 (and (zero? (system* "./autogen.sh"))
2590 (patch-makefile-SHELL "Makefile.include.in")
2593 ;; Make sure programs find libgpm.so.
2594 #:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath="
2595 (assoc-ref %outputs "out")
2598 `(("texinfo" ,texinfo)
2601 ("autoconf" ,autoconf)
2602 ("automake" ,automake)
2603 ("libtool" ,libtool)))
2604 (home-page "http://www.nico.schottelius.org/software/gpm/")
2605 (synopsis "Mouse support for the Linux console")
2607 "The GPM (general-purpose mouse) daemon is a mouse server for
2608 applications running on the Linux console. It allows users to select items
2609 and copy/paste text in the console and in xterm.")
2610 (license license:gpl2+)))
2612 (define-public btrfs-progs
2614 (name "btrfs-progs")
2618 (uri (string-append "mirror://kernel.org/linux/kernel/"
2619 "people/kdave/btrfs-progs/"
2620 "btrfs-progs-v" version ".tar.xz"))
2623 "10yv823g92jbd6iq8d70y0bvs716jv956bq7khqmbhdzg9q6svl3"))))
2624 (build-system gnu-build-system)
2626 "static")) ; static versions of binaries in "out" (~16MiB!)
2628 '(#:phases (modify-phases %standard-phases
2629 (add-after 'build 'build-static
2630 (lambda _ (zero? (system* "make" "static"))))
2631 (add-after 'install 'install-static
2632 (let ((staticbin (string-append (assoc-ref %outputs "static")
2635 (zero? (system* "make"
2636 (string-append "bindir=" staticbin)
2637 "install-static"))))))
2638 #:test-target "test"
2639 #:parallel-tests? #f)) ; tests fail when run in parallel
2640 (inputs `(("e2fsprogs" ,e2fsprogs)
2641 ("libblkid" ,util-linux)
2642 ("libblkid:static" ,util-linux "static")
2643 ("libuuid" ,util-linux)
2644 ("libuuid:static" ,util-linux "static")
2647 (native-inputs `(("pkg-config" ,pkg-config)
2648 ("asciidoc" ,asciidoc)
2650 ;; For building documentation
2651 ("libxml2" ,libxml2)
2652 ("docbook-xml" ,docbook-xml)
2653 ("docbook-xsl" ,docbook-xsl)
2656 (home-page "https://btrfs.wiki.kernel.org/")
2657 (synopsis "Create and manage btrfs copy-on-write file systems")
2658 (description "Btrfs is a copy-on-write (CoW) file system for Linux aimed at
2659 implementing advanced features while focusing on fault tolerance, repair and
2660 easy administration.")
2661 ;; GPL2+: crc32.c, radix-tree.c, raid6.c, rbtree.c.
2662 ;; GPL2: Everything else.
2663 (license (list license:gpl2 license:gpl2+))))
2665 (define-public freefall
2668 (version (package-version linux-libre))
2669 (source (package-source linux-libre))
2670 (build-system gnu-build-system)
2672 '(#:phases (modify-phases %standard-phases
2673 (add-after 'unpack 'enter-subdirectory
2675 (chdir "tools/laptop/freefall")))
2677 (add-before 'build 'increase-timeout
2679 ;; The default of 2 seconds is too low: it assumes an
2680 ;; open lid and AC power without actually checking.
2681 (substitute* "freefall.c"
2682 (("alarm\\(2\\)") "alarm(5)")))))
2683 #:make-flags (list (string-append "PREFIX="
2684 (assoc-ref %outputs "out")))
2685 #:tests? #f)) ;no tests
2686 (home-page (package-home-page linux-libre))
2687 (synopsis "Free-fall protection for spinning laptop hard drives")
2689 "Prevents shock damage to the internal spinning hard drive(s) of some
2690 HP and Dell laptops. When sudden movement is detected, all input/output
2691 operations on the drive are suspended and its heads are parked on the ramp,
2692 where they are less likely to cause damage to the spinning disc. Requires a
2693 drive that supports the ATA/ATAPI-7 IDLE IMMEDIATE command with unload
2694 feature, and a laptop with an accelerometer. It has no effect on SSDs.")
2695 (license license:gpl2)))
2697 (define-public thinkfan
2703 (uri (string-append "mirror://sourceforge/thinkfan/"
2704 "/thinkfan-" version ".tar.gz"))
2707 "0nz4c48f0i0dljpk5y33c188dnnwg8gz82s4grfl8l64jr4n675n"))
2708 (modules '((guix build utils)))
2709 ;; Fix erroneous man page location in Makefile leading to
2710 ;; a compilation failure.
2712 '(substitute* "CMakeLists.txt"
2713 (("thinkfan\\.1") "src/thinkfan.1")))))
2714 (build-system cmake-build-system)
2716 `(#:modules ((guix build cmake-build-system)
2719 #:tests? #f ;no test target
2721 ;; Enable reading temperatures from hard disks via S.M.A.R.T.
2722 `("-DUSE_ATASMART:BOOL=ON")
2724 (modify-phases %standard-phases
2725 ;; Install scripts for various foreign init systems. Also fix
2726 ;; hard-coded path for daemon.
2727 (add-after 'install 'install-rc-scripts
2728 (lambda* (#:key outputs #:allow-other-keys)
2729 (let ((out (assoc-ref outputs "out"))
2731 (string-append "../thinkfan-" ,version "/rcscripts")
2734 (("/usr/sbin/(\\$NAME|thinkfan)" _ name)
2735 (string-append out "/sbin/" name)))
2736 (for-each (cute install-file <>
2737 (string-append out "/share/thinkfan"))
2741 `(("libatasmart" ,libatasmart)))
2742 (home-page "http://thinkfan.sourceforge.net/")
2743 (synopsis "Simple fan control program")
2745 "Thinkfan is a simple fan control program. It reads temperatures,
2746 checks them against configured limits and switches to appropriate (also
2747 pre-configured) fan level. It requires a working @code{thinkpad_acpi} or any
2748 other @code{hwmon} driver that enables temperature reading and fan control
2750 (license license:gpl3+)))
2752 (define-public ntfs-3g
2755 (version "2016.2.22")
2758 (uri (string-append "https://tuxera.com/opensource/"
2759 "ntfs-3g_ntfsprogs-" version ".tgz"))
2762 "180y5y09h30ryf2vim8j30a2npwz1iv9ly5yjmh3wjdkwh2jrdyp"))
2763 (modules '((guix build utils)))
2765 ;; Install under $prefix.
2766 '(substitute* '("src/Makefile.in" "ntfsprogs/Makefile.in")
2769 (build-system gnu-build-system)
2770 (inputs `(("util-linux" ,util-linux)
2771 ("fuse" ,fuse))) ;libuuid
2772 (native-inputs `(("pkg-config" ,pkg-config)))
2774 '(#:configure-flags (list "--exec-prefix=${prefix}"
2775 "--with-fuse=external" ;use our own FUSE
2776 "--enable-mount-helper"
2777 "--enable-posix-acls"
2778 "--enable-xattr-mappings")))
2779 (home-page "http://www.tuxera.com/community/open-source-ntfs-3g/")
2780 (synopsis "Read-write access to NTFS file systems")
2782 "NTFS-3G provides read-write access to NTFS file systems, which are
2783 commonly found on Microsoft Windows. It is implemented as a FUSE file system.
2784 The package provides additional NTFS tools.")
2785 (license license:gpl2+)))
2787 (define-public rng-tools
2794 "http://downloads.sourceforge.net/sourceforge/gkernel/"
2795 "rng-tools-" version ".tar.gz"))
2798 "13h7lc8wl9khhvkr0i3bl5j9bapf8anhqis1lcnwxg1vc2v058b0"))))
2799 (build-system gnu-build-system)
2800 (synopsis "Random number generator daemon")
2802 "Monitor a hardware random number generator, and supply entropy
2803 from that to the system kernel's @file{/dev/random} machinery.")
2804 (home-page "http://sourceforge.net/projects/gkernel")
2805 ;; The source package is offered under the GPL2+, but the files
2806 ;; 'rngd_rdrand.c' and 'rdrand_asm.S' are only available under the GPL2.
2807 (license (list license:gpl2 license:gpl2+))))
2809 (define-public cpupower
2812 (version (package-version linux-libre))
2813 (source (package-source linux-libre))
2814 (build-system gnu-build-system)
2816 '(#:phases (modify-phases %standard-phases
2817 (add-after 'unpack 'enter-subdirectory
2819 (chdir "tools/power/cpupower")))
2821 (add-before 'build 'fix-makefiles
2823 (substitute* "Makefile"
2825 (("/bin/(install|pwd)" _ command) command))
2826 (substitute* "bench/Makefile"
2827 (("\\$\\(CC\\) -o") "$(CC) $(LDFLAGS) -o")))))
2828 #:make-flags (let ((out (assoc-ref %outputs "out")))
2829 (list (string-append "DESTDIR=" out)
2830 (string-append "LDFLAGS=-Wl,-rpath=" out "/lib")
2831 "docdir=/share/doc/cpupower"
2832 "confdir=$(docdir)/examples"
2833 ;; The Makefile recommends the following changes
2835 "PACKAGE_BUGREPORT=bug-guix@gnu.org"))
2836 #:tests? #f)) ;no tests
2837 (native-inputs `(("gettext" ,gettext-minimal)))
2838 (inputs `(("pciutils" ,pciutils)))
2839 (home-page (package-home-page linux-libre))
2840 (synopsis "CPU frequency and voltage scaling tools for Linux")
2842 "cpupower is a set of user-space tools that use the cpufreq feature of the
2843 Linux kernel to retrieve and control processor features related to power saving,
2844 such as frequency and voltage scaling.")
2845 (license license:gpl2)))
2847 (define-public haveged
2854 (uri (string-append "http://www.issihosts.com/haveged/haveged-"
2858 "059pxlfd4l5dqhd6r3lynzfz4wby2f17294fy17pi9j2jpnn68ww"))))
2859 (build-system gnu-build-system)
2860 (home-page "http://www.issihosts.com/haveged")
2861 (synopsis "Entropy source for the Linux random number generator")
2863 "haveged generates an unpredictable stream of random numbers for use by
2864 Linux's @file{/dev/random} and @file{/dev/urandom} devices. The kernel's
2865 standard mechanisms for filling the entropy pool may not be sufficient for
2866 systems with high needs or limited user interaction, such as headless servers.
2867 @command{haveged} runs as a privileged daemon, harvesting randomness from the
2868 indirect effects of hardware events on hidden processor state using the HArdware
2869 Volatile Entropy Gathering and Expansion (HAVEGE) algorithm. It tunes itself to
2870 its environment and provides the same built-in test suite for the output stream
2871 as used on certified hardware security devices.")
2872 (license (list (license:non-copyleft "file://nist/mconf.h")
2873 (license:non-copyleft "file://nist/packtest.c")
2874 license:public-domain ; nist/dfft.c
2875 license:gpl3+)))) ; everything else
2877 (define-public ecryptfs-utils
2879 (name "ecryptfs-utils")
2884 (uri (string-append "https://launchpad.net/ecryptfs/trunk/"
2885 version "/+download/ecryptfs-utils_"
2886 version ".orig.tar.gz"))
2889 "0zwq19siiwf09h7lwa7n7mgmrr8cxifp45lmwgcfr8c1gviv6b0i"))))
2890 (build-system gnu-build-system)
2892 `(#:configure-flags (list "--disable-pywrap")))
2894 `(("intltool" ,intltool)
2895 ("perl" ,perl) ; for pod2man
2896 ("pkg-config" ,pkg-config)))
2898 `(("keyutils" ,keyutils)
2899 ("linux-pam" ,linux-pam)
2901 (home-page "http://ecryptfs.org/")
2902 (synopsis "eCryptfs cryptographic file system utilities")
2904 "eCryptfs is a POSIX-compliant stacked cryptographic file system for Linux.
2905 Each file's cryptographic meta-data is stored inside the file itself, along
2906 with the encrypted contents. This allows individual encrypted files to be
2907 copied between hosts and still be decrypted with the proper key. eCryptfs is a
2908 native Linux file system, and has been part of the Linux kernel since version
2909 2.6.19. This package contains the userland utilities to manage it.")
2910 ;; The files src/key_mod/ecryptfs_key_mod_{openssl,pkcs11_helper,tspi}.c
2911 ;; grant additional permission to link with OpenSSL.
2912 (license license:gpl2+)))
2914 (define-public libnfsidmap
2916 (name "libnfsidmap")
2921 "http://www.citi.umich.edu/projects/nfsv4/linux/"
2922 name "/" name "-" version ".tar.gz"))
2925 "1kzgwxzh83qi97rblcm9qj80cdvnv8kml2plz0q103j0hifj8vb5"))))
2926 (build-system gnu-build-system)
2928 `(#:configure-flags (list
2929 (string-append "--with-pluginpath="
2930 (assoc-ref %outputs "out")
2931 "/lib/libnfsidmap"))))
2933 "http://www.citi.umich.edu/projects/nfsv4/crossrealm/libnfsidmap_config.html")
2935 "NFSv4 support library for name/ID mapping")
2936 (description "Libnfsidmap is a library holding mulitiple methods of
2937 mapping names to ids and visa versa, mainly for NFSv4. It provides an
2938 extensible array of mapping functions, currently consisting of two choices:
2939 the default @code{nsswitch} and the experimental @code{umich_ldap}.")
2940 (license (license:non-copyleft "file://COPYING"
2941 "See COPYING in the distribution."))))
2943 (define-public module-init-tools
2945 (name "module-init-tools")
2950 "mirror://kernel.org/linux/utils/kernel/module-init-tools/"
2951 "module-init-tools-" version ".tar.bz2"))
2954 "0jxnz9ahfic79rp93l5wxcbgh4pkv85mwnjlbv1gz3jawv5cvwp1"))
2955 (patches (search-patches "module-init-tools-moduledir.patch"))))
2956 (build-system gnu-build-system)
2958 ;; FIXME: The upstream tarball lacks man pages, and building them would
2959 ;; require DocBook & co. We used to use Gentoo's pre-built man pages,
2960 ;; but they vanished. In the meantime, fake it.
2961 '(#:phases (alist-cons-before
2962 'configure 'fake-docbook
2964 (substitute* "Makefile.in"
2965 (("^DOCBOOKTOMAN.*$")
2966 "DOCBOOKTOMAN = true\n")))
2968 (home-page "http://www.kernel.org/pub/linux/utils/kernel/module-init-tools/")
2969 (synopsis "Tools for loading and managing Linux kernel modules")
2971 "Tools for loading and managing Linux kernel modules, such as `modprobe',
2972 `insmod', `lsmod', and more.")
2973 (license license:gpl2+)))
2975 (define-public mcelog
2981 (uri (string-append "https://git.kernel.org/cgit/utils/cpu/mce/"
2982 "mcelog.git/snapshot/v" version ".tar.gz"))
2985 "1mn5i1d6ybfxqgr6smlpxcx1wb53h0r2rp90ild7919b9yqxpk0x"))
2986 (file-name (string-append name "-" version ".tar.gz"))
2987 (modules '((guix build utils)))
2989 ;; The snapshots lack a .git directory, breaking ‘git describe’.
2990 `(substitute* "Makefile"
2991 (("\"unknown\"") (string-append "\"v" ,version "\""))))))
2992 (build-system gnu-build-system)
2994 `(#:phases (modify-phases %standard-phases
2995 (delete 'configure)) ; no configure script
2996 #:make-flags (let ((out (assoc-ref %outputs "out")))
2998 (string-append "prefix=" out)
2999 (string-append "DOCDIR=" out "/share/doc/mcelog")
3000 "etcprefix=$(DOCDIR)/examples"))
3001 ;; The tests will only run as root on certain supported CPU models.
3003 (supported-systems (list "i686-linux" "x86_64-linux"))
3004 (home-page "http://mcelog.org/")
3005 (synopsis "Machine check monitor for x86 Linux systems")
3007 "The mcelog daemon is required by the Linux kernel to log memory, I/O, CPU,
3008 and other hardware errors on x86 systems. It can also perform user-defined
3009 tasks, such as bringing bad pages off-line, when configurable error thresholds
3011 (license license:gpl2)))
3013 (define-public mtd-utils
3020 "ftp://ftp.infradead.org/pub/mtd-utils/"
3021 "mtd-utils-" version ".tar.bz2"))
3024 "007lhsd8yb34l899r4m37whhzdw815cz4fnjbpnblfha524p7dax"))))
3027 ("libuuid" ,util-linux)
3030 (build-system gnu-build-system)
3032 `(#:test-target "tests"
3033 #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
3034 #:phases (modify-phases %standard-phases
3035 (delete 'configure))))
3036 (synopsis "MTD Flash Storage Utilities")
3037 (description "This package provides utilities for testing, partitioning, etc
3039 (home-page "http://www.linux-mtd.infradead.org/")
3041 (list license:gpl2 ; Almost everything is gpl2 or gpl2+
3042 license:mpl1.1 ; All ftl* files
3043 license:expat)))) ; libiniparser
3045 (define-public libseccomp
3051 (uri (string-append "https://github.com/seccomp/libseccomp/"
3052 "releases/download/v" version
3053 "/libseccomp-" version ".tar.gz"))
3056 "0asnlkzqms520r0dra08dzcz5hh6hs7lkajfw9wij3vrd0hxsnzz"))))
3057 (build-system gnu-build-system)
3059 `(("which" ,which)))
3060 (synopsis "Interface to Linux's seccomp syscall filtering mechanism")
3061 (description "The libseccomp library provides an easy to use, platform
3062 independent, interface to the Linux Kernel's syscall filtering mechanism. The
3063 libseccomp API is designed to abstract away the underlying BPF based syscall
3064 filter language and present a more conventional function-call based filtering
3065 interface that should be familiar to, and easily adopted by, application
3067 (home-page "https://github.com/seccomp/libseccomp")
3068 (license license:lgpl2.1)))