1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
4 ;;; Copyright © 2014, 2015, 2016, 2018, 2019 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014, 2015, 2016, 2017, 2018 Eric Bavier <bavier@member.fsf.org>
6 ;;; Copyright © 2015, 2016 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
7 ;;; Copyright © 2015 Alex Sassmannshausen <alex.sassmannshausen@gmail.com>
8 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
9 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
10 ;;; Copyright © 2016 Pjotr Prins <pjotr.guix@thebird.nl>
11 ;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
12 ;;; Copyright © 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
13 ;;; Copyright © 2016 Peter Feigl <peter.feigl@nexoid.at>
14 ;;; Copyright © 2016 John J. Foerch <jjfoerch@earthlink.net>
15 ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
16 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
17 ;;; Copyright © 2016 John Darrington <jmd@gnu.org>
18 ;;; Copyright © 2017 Ben Sturmfels <ben@sturm.com.au>
19 ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
20 ;;; Copyright © 2017 Christopher Allan Webber <cwebber@dustycloud.org>
21 ;;; Copyright © 2017, 2018, 2020 Marius Bakke <mbakke@fastmail.com>
22 ;;; Copyright © 2018, 2019 Arun Isaac <arunisaac@systemreboot.net>
23 ;;; Copyright © 2018 Pierre-Antoine Rouby <pierre-antoine.rouby@inria.fr>
24 ;;; Copyright © 2018 Rutger Helling <rhelling@mykolab.com>
25 ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
26 ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
27 ;;; Copyright © 2019,2020 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
28 ;;; Copyright © 2019 Jakob L. Kreuze <zerodaysfordays@sdf.org>
29 ;;; Copyright © 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
30 ;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
31 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
32 ;;; Copyright © 2019, 2020 Mathieu Othacehe <m.othacehe@gmail.com>
33 ;;; Copyright © 2020 Oleg Pykhalov <go.wigust@gmail.com>
34 ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
35 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
36 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
37 ;;; Copyright © 2020 Morgan Smith <Morgan.J.Smith@outlook.com>
39 ;;; This file is part of GNU Guix.
41 ;;; GNU Guix is free software; you can redistribute it and/or modify it
42 ;;; under the terms of the GNU General Public License as published by
43 ;;; the Free Software Foundation; either version 3 of the License, or (at
44 ;;; your option) any later version.
46 ;;; GNU Guix is distributed in the hope that it will be useful, but
47 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
48 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
49 ;;; GNU General Public License for more details.
51 ;;; You should have received a copy of the GNU General Public License
52 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
54 (define-module (gnu packages admin)
55 #:use-module (guix build-system cmake)
56 #:use-module (guix build-system emacs)
57 #:use-module (guix build-system glib-or-gtk)
58 #:use-module (guix build-system gnu)
59 #:use-module (guix build-system meson)
60 #:use-module (guix build-system perl)
61 #:use-module (guix build-system python)
62 #:use-module (guix build-system ruby)
63 #:use-module (guix build-system trivial)
64 #:use-module (guix download)
65 #:use-module (guix git-download)
66 #:use-module ((guix licenses) #:prefix license:)
67 #:use-module (guix packages)
68 #:use-module (guix utils)
69 #:use-module (gnu packages)
70 #:use-module (gnu packages algebra)
71 #:use-module (gnu packages autogen)
72 #:use-module (gnu packages autotools)
73 #:use-module (gnu packages base)
74 #:use-module (gnu packages bash)
75 #:use-module (gnu packages bison)
76 #:use-module (gnu packages boost)
77 #:use-module (gnu packages c)
78 #:use-module (gnu packages check)
79 #:use-module (gnu packages compression)
80 #:use-module (gnu packages cross-base)
81 #:use-module (gnu packages crypto)
82 #:use-module (gnu packages cryptsetup)
83 #:use-module (gnu packages cyrus-sasl)
84 #:use-module (gnu packages dns)
85 #:use-module (gnu packages elf)
86 #:use-module (gnu packages file)
87 #:use-module (gnu packages flex)
88 #:use-module (gnu packages gettext)
89 #:use-module (gnu packages gl)
90 #:use-module (gnu packages glib)
91 #:use-module (gnu packages gnome)
92 #:use-module (gnu packages gnupg)
93 #:use-module (gnu packages golang)
94 #:use-module (gnu packages groff)
95 #:use-module (gnu packages gtk)
96 #:use-module (gnu packages guile)
97 #:use-module (gnu packages hurd)
98 #:use-module (gnu packages image)
99 #:use-module (gnu packages imagemagick)
100 #:use-module (gnu packages inkscape)
101 #:use-module (gnu packages kerberos)
102 #:use-module (gnu packages libbsd)
103 #:use-module (gnu packages libftdi)
104 #:use-module (gnu packages libunwind)
105 #:use-module (gnu packages libusb)
106 #:use-module (gnu packages linux)
107 #:use-module (gnu packages lua)
108 #:use-module (gnu packages man)
109 #:use-module (gnu packages mcrypt)
110 #:use-module (gnu packages mpi)
111 #:use-module (gnu packages ncurses)
112 #:use-module (gnu packages openldap)
113 #:use-module (gnu packages patchutils)
114 #:use-module (gnu packages pciutils)
115 #:use-module (gnu packages pcre)
116 #:use-module (gnu packages perl)
117 #:use-module (gnu packages perl-check)
118 #:use-module (gnu packages pkg-config)
119 #:use-module (gnu packages popt)
120 #:use-module (gnu packages python)
121 #:use-module (gnu packages python-crypto)
122 #:use-module (gnu packages python-web)
123 #:use-module (gnu packages python-xyz)
124 #:use-module (gnu packages qt)
125 #:use-module (gnu packages readline)
126 #:use-module (gnu packages ruby)
127 #:use-module (gnu packages sphinx)
128 #:use-module (gnu packages tcl)
129 #:use-module (gnu packages terminals)
130 #:use-module (gnu packages texinfo)
131 #:use-module (gnu packages tls)
132 #:use-module (gnu packages version-control)
133 #:use-module (gnu packages web)
134 #:use-module (gnu packages xdisorg)
135 #:use-module (gnu packages xml)
136 #:use-module (gnu packages xorg))
138 ;; This package uses su instead of sudo (because of SpaceFM).
139 (define-public ktsuss
148 (url "https://github.com/nomius/ktsuss.git")
151 (base32 "0q9931f9hp47v1n8scli4bdg2rkjpf5jf8v7jj2gdn83aia1r2hz"))
152 (file-name (git-file-name name version))))
153 (build-system glib-or-gtk-build-system)
156 (modify-phases %standard-phases
157 (add-after 'unpack 'patch-file-names
159 (substitute* "configure.ac"
160 (("supath=`which su 2>/dev/null`")
161 "supath=/run/setuid-programs/su"))
164 `(("autoconf" ,autoconf)
165 ("automake" ,automake)
167 ("pkg-config" ,pkg-config)))
171 (synopsis "Graphical front end for @command{su}")
173 "Ktsuss stands for ``Keep the @command{su} simple, stupid''.
174 It is a graphical version of @command{su} written in C and GTK+ 2, with
175 simplicity in mind.")
176 (home-page "https://github.com/nomius/ktsuss")
177 (license license:bsd-3)))
186 (uri (string-append "https://github.com/aide/aide/releases/download/v"
187 version "/aide-" version ".tar.gz"))
189 (base32 "15xp47sz7kk1ciffw3f5xw2jg2mb2lqrbr3q6p4bkbz5dap9iy8p"))))
190 (build-system gnu-build-system)
195 `(("libgcrypt" ,libgcrypt)
196 ("libgpg-error" ,libgpg-error)
197 ("libmhash" ,libmhash)
198 ("pcre:static" ,pcre "static")
200 ("zlib:static" ,zlib "static")
202 (synopsis "File and directory integrity checker")
204 "AIDE (Advanced Intrusion Detection Environment) is a file and directory
205 integrity checker. It creates a database from the regular expression rules
206 that it finds from its configuration files. Once this database is initialized
207 it can be used to verify the integrity of the files. It has several message
208 digest algorithms that are used to check the integrity of files. All of the
209 usual file attributes can be checked for inconsistencies.")
210 (home-page "https://aide.github.io/")
211 (license license:gpl2+)))
213 (define-public progress
221 (url "https://github.com/Xfennec/progress.git")
222 (commit (string-append "v" version))))
224 (base32 "1lk2v4b767klib93an4g3f7z5qrv9kdk9jf7545vw1immc4kamrl"))
225 (file-name (git-file-name name version))))
226 (build-system gnu-build-system)
228 `(("pkg-config" ,pkg-config)
231 `(("ncurses" ,ncurses)))
233 `(#:tests? #f ; no test suite
234 #:make-flags (list "CC=gcc"
235 (string-append "PREFIX=" (assoc-ref %outputs "out")))
237 (modify-phases %standard-phases
238 (delete 'configure)))) ; no configure script
239 (home-page "https://github.com/Xfennec/progress")
240 (synopsis "Program to view the progress of the coreutils commands")
241 (description "A program that looks for coreutils basic commands (cp, mv,
242 dd, tar, gzip/gunzip, cat, etc.) currently running on your system and displays
243 the percentage of copied data. It can also show estimated time and throughput,
244 and provides a \"top-like\" mode (monitoring).")
245 (license license:gpl3+)))
247 (define-public shepherd
253 (uri (string-append "mirror://gnu/shepherd/shepherd-"
257 "0x9zr0x3xvk4qkb6jnda451d5iyrl06cz1bjzjsm0lxvjj3fabyk"))))
258 (build-system gnu-build-system)
260 '(#:configure-flags '("--localstatedir=/var")))
262 `(("pkg-config" ,pkg-config)
264 ;; This is the Guile we use as a cross-compiler...
265 ("guile" ,guile-3.0)))
267 ;; ... and this is the one that appears in shebangs when cross-compiling.
268 `(("guile" ,guile-3.0)
270 ;; The 'shepherd' command uses Readline when used interactively. It's
271 ;; an unusual use case though, so we don't propagate it.
272 ("guile-readline" ,guile-readline)))
273 (synopsis "System service manager")
275 "The GNU Shepherd is a daemon-managing daemon, meaning that it supervises
276 the execution of system services, replacing similar functionality found in
277 typical init systems. It provides dependency-handling through a convenient
278 interface and is based on GNU Guile.")
279 (license license:gpl3+)
280 (home-page "https://www.gnu.org/software/shepherd/")))
282 (define-public guile2.2-shepherd
285 (name "guile2.2-shepherd")
287 `(("pkg-config" ,pkg-config)
288 ("guile" ,guile-2.2)))
290 `(("guile" ,guile-2.2)))))
292 (define-public guile3.0-shepherd
293 (deprecated-package "guile3.0-shepherd" shepherd))
295 (define-public guile2.0-shepherd
298 (name "guile2.0-shepherd")
300 `(("pkg-config" ,pkg-config)
301 ("guile" ,guile-2.0)))
303 `(("guile" ,guile-2.0)))))
305 (define-public cloud-utils
313 "https://launchpad.net/cloud-utils/trunk/"
314 version "/+download/cloud-utils-" version ".tar.gz"))
317 "07fl3dlqwdzw4xx7mcxhpkks6dnmaxha80zgs9f6wmibgzni8z0r"))))
318 (build-system gnu-build-system)
321 (let ((out (assoc-ref %outputs "out")))
322 (list (string-append "BINDIR=" out "/bin")
323 (string-append "MANDIR=" out "/share/man/man1")
324 (string-append "DOCDIR=" out "/share/doc")))
326 (modify-phases %standard-phases
329 (add-after 'install 'wrap
330 (lambda* (#:key outputs inputs #:allow-other-keys)
331 (let ((growpart (string-append (assoc-ref outputs "out")
333 (wrap-program growpart
334 `("PATH" ":" prefix (,(dirname (which "sfdisk"))
335 ,(dirname (which "readlink"))))))
339 ("util-linux" ,util-linux))) ; contains sfdisk for growpart
340 (home-page "https://launchpad.net/cloud-utils")
341 (synopsis "Set of utilities for cloud computing environments")
343 "This package contains a set of utilities for cloud computing
347 @item @command{cloud-localds} Create a disk for cloud-init to utilize nocloud
348 @item @command{cloud-publish-image} Wrapper for cloud image publishing
349 @item @command{cloud-publish-tarball} Wrapper for publishing cloud tarballs
350 @item @command{cloud-publish-ubuntu} Import a Ubuntu cloud image
351 @item @command{ec2metadata} Query and display @acronym{EC2,Amazon Elastic
352 Compute Cloud} metadata
353 @item @command{growpart} Grow a partition to fill the device
354 @item @command{mount-image-callback} Mount a file and run a command
355 @item @command{resize-part-image} Resize a partition image to a new size
356 @item @command{ubuntu-cloudimg-query} Get the latest Ubuntu
357 @acronym{AMI,Amazon Machine Image}
358 @item @command{ubuntu-ec2-run} Run a @acronym{EC2,Amazon Elastic Compute
359 Cloud} instance using Ubuntu
360 @item @command{vcs-run} Obtain a repository, and run a command
361 @item @command{write-mime-multipart} Handle multipart
362 @acronym{MIME,Multipurpose Internet Mail Extensions} messages
364 (license license:gpl3)))
366 (define-public daemontools
373 "https://cr.yp.to/daemontools/"
374 "daemontools-" version ".tar.gz"))
377 "07scvw88faxkscxi91031pjkpccql6wspk4yrlnsbrrb5c0kamd5"))))
378 (build-system gnu-build-system)
380 `(#:tests? #f ;; No tests as far as I can tell.
382 (modify-phases %standard-phases
383 (add-after 'unpack 'chdir
385 (chdir ,(string-append "daemontools-" version))
388 (add-before 'build 'patch
390 (substitute* "src/error.h"
391 (("extern int errno;")
392 "#include <errno.h>"))
396 (invoke "package/compile")))
398 (lambda* (#:key outputs #:allow-other-keys)
399 (let* ((out (assoc-ref outputs "out"))
400 (bin (string-append out "/bin")))
401 (for-each (lambda (file)
402 (install-file file bin))
403 (find-files "command")))
405 (synopsis "Tools for managing UNIX style services")
407 "@code{daemontools} is a collection of tools for managing UNIX
409 (license license:public-domain)
410 (home-page "https://cr.yp.to/daemontools.html")))
420 "https://projects.gw-computing.net/attachments/download/615/dfc-"
424 "0m1fd7l85ckb7bq4c5c3g257bkjglm8gq7x42pkmpp87fkknc94n"))))
425 (build-system cmake-build-system)
426 (arguments '(#:tests? #f)) ; There are no tests.
427 (native-inputs `(("gettext" ,gettext-minimal)))
428 (home-page "https://projects.gw-computing.net/projects/dfc")
429 (synopsis "Display file system space usage using graphs and colors")
431 "dfc (df color) is a modern version of df. It uses colors, draws pretty
432 graphs and can export its output to different formats.")
433 (license license:bsd-3)))
435 (define-public facter
442 (url "https://github.com/puppetlabs/facter-ng")
444 (file-name (git-file-name name version))
447 "04nbk9rn5lfhbivsx68dggsp05czm7mzfr1i7yv6168bl92d233y"))))
448 (build-system ruby-build-system)
450 `(#:phases (modify-phases %standard-phases
451 (add-after 'unpack 'delete-facter-ng-gemspec
453 ;; XXX: ruby-build-system incorrectly finds
454 ;; facter-ng.gemspec from this directory and tries to
455 ;; build that instead of the proper facter.gemspec.
456 ;; Just delete it as a workaround, as it appears to
457 ;; only exist for backwards-compatibility after the
458 ;; facter-ng->facter rename.
459 (delete-file "agent/facter-ng.gemspec")
461 (add-after 'unpack 'embed-iproute-reference
462 (lambda* (#:key inputs #:allow-other-keys)
463 (let ((iproute (assoc-ref inputs "iproute")))
464 ;; Provide an absolute reference to the 'ip' executable
465 ;; to avoid propagating it.
466 (substitute* "lib/resolvers/networking_linux_resolver.rb"
468 (string-append "execute('" iproute "/sbin/ip")))
471 (add-after 'wrap 'check
472 (lambda* (#:key tests? outputs #:allow-other-keys)
473 ;; XXX: The test suite wants to run Bundler and
474 ;; complains that the gemspec is invalid. For now
475 ;; just make sure that we can run the wrapped
476 ;; executable directly.
478 (invoke (string-append (assoc-ref outputs "out")
480 ;; Many facts depend on /sys, /etc/os-release,
481 ;; etc, so we only run a small sample.
482 "facterversion" "architecture"
483 "kernel" "kernelversion")
484 (format #t "tests disabled~%"))
487 `(("iproute" ,iproute)
488 ("ruby-hocon" ,ruby-hocon)
489 ("ruby-sys-filesystem" ,ruby-sys-filesystem)
490 ("ruby-thor" ,ruby-thor)))
491 (synopsis "Collect and display system facts")
493 "Facter is a tool that gathers basic facts about nodes (systems) such
494 as hardware details, network settings, OS type and version, and more. These
495 facts can be collected on the command line with the @command{facter} command
496 or via the @code{facter} Ruby library.")
497 (home-page "https://github.com/puppetlabs/facter-ng")
498 (license license:expat)))
506 (uri (string-append "http://hisham.hm/htop/releases/"
507 version "/htop-" version ".tar.gz"))
510 "0mrwpb3cpn3ai7ar33m31yklj64c3pp576vh1naqff6f21pq5mnr"))))
511 (build-system gnu-build-system)
513 `(("ncurses" ,ncurses)))
515 `(("python" ,python-wrapper))) ;for scripts/MakeHeader.py
516 (home-page "https://hisham.hm/htop/")
517 (synopsis "Interactive process viewer")
519 "This is htop, an interactive process viewer. It is a text-mode
520 application (for console or X terminals) and requires ncurses.")
521 (license license:gpl2)))
530 (uri (string-append "mirror://gnu/pies/pies-"
534 "14jb4pa4zs26d5j2skxbaypnwhsx2lw8jgj1irrgs03c2dnf7gp6"))))
535 (build-system gnu-build-system)
537 '(#:phases (modify-phases %standard-phases
538 (add-before 'build 'patch-/bin/sh
539 (lambda* (#:key inputs #:allow-other-keys)
540 ;; Use the right shell when executing user-provided
542 (let ((bash (assoc-ref inputs "bash")))
543 (substitute* '("src/progman.c" "src/comp.c")
545 (string-append "\"" bash "/bin/sh\"")))
547 (home-page "https://www.gnu.org.ua/software/pies/")
548 (synopsis "Program invocation and execution supervisor")
550 "GNU pies is a program that supervises the invocation and execution of
551 other programs. It reads the list of programs to be started from its
552 configuration file, executes them, and then monitors their status,
553 re-executing them as necessary.")
554 (license license:gpl3+)))
556 (define-public inetutils
562 (uri (string-append "mirror://gnu/inetutils/inetutils-"
564 (patches (search-patches "inetutils-hurd.patch"))
567 "05n65k4ixl85dc6rxc51b1b732gnmm8xnqi424dy9f1nz7ppb3xy"))))
568 (build-system gnu-build-system)
570 `(#:configure-flags '("--localstatedir=/var"
572 ;; Make sure 'PATH_PROCNET_DEV' gets defined when
573 ;; cross-compiling (by default it does not.)
574 ,@(if (%current-target-system)
575 '("--with-path-procnet-dev=/proc/net/dev")
588 ;; On some systems, 'libls.sh' may fail with an error such as:
589 ;; "Failed to tell switch -a apart from -A".
590 #:parallel-tests? #f))
591 (inputs `(("ncurses" ,ncurses)
592 ("readline" ,readline))) ;for 'ftp'
593 (native-inputs (if (member (%current-system)
594 (package-supported-systems net-tools))
595 `(("netstat" ,net-tools)) ;for tests
597 (home-page "https://www.gnu.org/software/inetutils/")
598 (synopsis "Basic networking utilities")
600 "Inetutils is a collection of common network programs, such as an ftp
601 client and server, a telnet client and server, an rsh client and server, and
603 (license license:gpl3+)))
605 (define-public shadow
612 "https://github.com/shadow-maint/shadow/releases/"
613 "download/" version "/shadow-" version ".tar.xz"))
614 (patches (search-patches "shadow-hurd-pctrl.patch"))
617 "0qmfq50sdhz6xilgxvinblll8j2iqfl7hwk45bq744y4plq4dbd3"))))
618 (build-system gnu-build-system)
620 `(;; Assume System V `setpgrp (void)', which is the default on GNU
621 ;; variants (`AC_FUNC_SETPGRP' is not cross-compilation capable.)
623 '("--with-libpam" "ac_cv_func_setpgrp_void=yes")
626 (modify-phases %standard-phases
627 (add-before 'build 'set-nscd-file-name
628 (lambda* (#:key inputs #:allow-other-keys)
629 ;; Use the right file name for nscd.
630 (let ((libc (assoc-ref inputs
631 ,(if (%current-target-system)
634 (substitute* "lib/nscd.c"
636 (string-append libc "/sbin/nscd")))
638 (add-after 'install 'remove-groups
639 (lambda* (#:key outputs #:allow-other-keys)
640 ;; Remove `groups', which is already provided by Coreutils.
641 (let* ((out (assoc-ref outputs "out"))
642 (bin (string-append out "/bin"))
643 (man (string-append out "/share/man")))
644 (delete-file (string-append bin "/groups"))
645 (for-each delete-file (find-files man "^groups\\."))
648 (inputs `(("linux-pam" ,linux-pam)))
649 (home-page "https://github.com/shadow-maint/shadow")
650 (synopsis "Authentication-related tools such as passwd, su, and login")
652 "Shadow provides a number of authentication-related tools, including:
653 login, passwd, su, groupadd, and useradd.")
655 ;; The `vipw' program is GPLv2+.
656 ;; libmisc/salt.c is public domain.
657 (license license:bsd-3)))
659 (define-public mingetty
665 (uri (string-append "mirror://sourceforge/mingetty/mingetty/"
666 version "/mingetty-" version ".tar.gz"))
669 "05yxrp44ky2kg6qknk1ih0kvwkgbn9fbz77r3vci7agslh5wjm8g"))))
670 (build-system gnu-build-system)
673 (modify-phases %standard-phases
675 (lambda* (#:key inputs outputs target #:allow-other-keys)
676 (let* ((out (assoc-ref outputs "out"))
677 (man8 (string-append out "/share/man/man8"))
678 (sbin (string-append out "/sbin"))
679 (shadow (assoc-ref inputs "shadow"))
680 (login (string-append shadow "/bin/login")))
681 (substitute* "Makefile"
682 ,@(if (%current-target-system)
684 (string-append "CC=" target "-gcc\n")))
687 (string-append "SBINDIR = " out
690 (string-append "MANDIR = " out
691 "/share/man/man8\n")))
693 ;; Pick the right 'login' by default.
694 (substitute* "mingetty.c"
696 (string-append "\"" login "\"")))
701 #:tests? #f)) ; no tests
702 (inputs `(("shadow" ,shadow)))
704 (home-page "https://sourceforge.net/projects/mingetty")
705 (synopsis "Getty for the text console")
707 "Small console getty that is started on the Linux text console,
708 asks for a login name and then transfers over to @code{login}. It is extended
709 to allow automatic login and starting any app.")
710 (license license:gpl2+)))
712 (define-public net-base
719 "mirror://debian/pool/main/n/netbase/netbase_"
723 "12xqjwg3p4rzmmh2iib6sigm9l29y3dgk74mmnw64k84jnbwdxl1"))))
724 (build-system trivial-build-system)
726 `(#:modules ((guix build utils))
728 (use-modules (guix build utils)
731 (let* ((source (assoc-ref %build-inputs "source"))
732 (tar (assoc-ref %build-inputs "tar"))
733 (xz (assoc-ref %build-inputs "xz"))
734 (output (assoc-ref %outputs "out"))
735 (etc (string-append output "/etc")))
736 (setenv "PATH" (string-append xz "/bin"))
737 (invoke (string-append tar "/bin/tar") "xvf"
739 (chdir ,(string-append "netbase-" version))
742 '("etc-services" "etc-protocols" "etc-rpc")
743 (map (cut string-append etc "/" <>)
744 '("services" "protocols" "rpc")))
746 (native-inputs `(("tar" ,tar)
748 (synopsis "IANA protocol, port, and RPC number assignments")
750 "This package provides the /etc/services, /etc/protocols, and /etc/rpc
751 files, which contain information about the IANA-assigned port, protocol, and
753 (home-page "https://packages.debian.org/sid/netbase")
754 (license license:gpl2)))
756 (define-public netcat
762 (uri (string-append "mirror://sourceforge/netcat/netcat/" version
763 "/netcat-" version ".tar.bz2"))
766 "1frjcdkhkpzk0f84hx6hmw5l0ynpmji8vcbaxg8h5k2svyxz0nmm"))))
767 (build-system gnu-build-system)
770 ;; By default, man and info pages are put in PREFIX/{man,info},
771 ;; but we want them in PREFIX/share/{man,info}.
772 (let ((out (assoc-ref %outputs "out")))
773 (list (string-append "--mandir=" out "/share/man")
774 (string-append "--infodir=" out "/share/info")))))
775 (home-page "http://netcat.sourceforge.net")
776 (synopsis "Read and write data over TCP/IP")
778 "Netcat is a featured networking utility which reads and writes data
779 across network connections, using the TCP/IP protocol. It is designed to be a
780 reliable \"back-end\" tool that can be used directly or easily driven by other
781 programs and scripts. At the same time, it is a feature-rich network debugging
782 and exploration tool, since it can create almost any kind of connection you
783 would need and has several interesting built-in capabilities.")
784 (license license:gpl2+)))
786 (define-public netcat-openbsd
788 (name "netcat-openbsd")
793 (url "https://salsa.debian.org/debian/netcat-openbsd.git")
794 (commit (string-append "debian/" version))))
795 (file-name (git-file-name name version))
798 "0kcvi3pav2fdx5c22psjv5dggk4cmrqiaq2cklhqngsk4a7vrjan"))))
799 (build-system gnu-build-system)
801 `(#:tests? #f ; no test suite
805 (modify-phases %standard-phases
807 (add-before 'build 'patch
809 (setenv "QUILT_PATCHES" "debian/patches")
810 (invoke "quilt" "push" "-a")
813 (lambda* (#:key outputs #:allow-other-keys)
814 (let* ((out (assoc-ref outputs "out"))
815 (bin (string-append out "/bin"))
816 (man (string-append out "/share/man/man1"))
817 (doc (string-append out "/share/doc/netcat-openbsd-" ,version))
818 (examples (string-append doc "/examples")))
819 (install-file "nc" bin)
820 (install-file "nc.1" man)
821 (install-file "debian/copyright" doc)
822 (copy-recursively "debian/examples" examples)
824 (inputs `(("libbsd" ,libbsd)))
825 (native-inputs `(("pkg-config" ,pkg-config)
827 (home-page "https://packages.debian.org/sid/netcat-openbsd")
828 (synopsis "Read and write data over TCP/IP")
830 "Netcat is a simple Unix utility which reads and writes data across
831 network connections using TCP or UDP protocol. It is designed to be a reliable
832 \"back-end\" tool that can be used directly or easily driven by other programs
833 and scripts. At the same time it is a feature-rich network debugging and
834 exploration tool, since it can create almost any kind of connection you would
835 need and has several interesting built-in capabilities.
837 This package contains the OpenBSD rewrite of netcat, including support for
838 IPv6, proxies, and Unix sockets.")
839 (license (list license:bsd-3
840 license:bsd-2)))) ; atomicio.*, socks.c
842 (define-public sipcalc
849 (uri (string-append "http://www.routemeister.net/projects"
850 "/sipcalc/files/sipcalc" "-" version ".tar.gz"))
853 "0mv3wndj4z2bsshh2k8d5sy3j8wxzgf8mzmmkvj1k8gpcz37dm6g"))))
854 (build-system gnu-build-system)
855 (home-page "https://www.routemeister.net/projects/sipcalc/")
856 (synopsis "Command-line IP subnet calculator")
858 "Sipcalc is an advanced command-line IP subnet calculator. It can take
859 multiple forms of input (IPv4/IPv6/interface/hostname) and output a multitude
860 of information about a given subnet.
867 @item Retrieving of address information from interfaces.
868 @item Classfull and CIDR output.
869 @item Multiple address and netmask input and output formats (dotted quad, hex,
871 @item Output of broadcast address, network class, Cisco wildcard,
872 hosts/range, network range.
873 @item The ability to split a network based on a smaller netmask, now also with
874 recursive runs on the generated subnets. (also IPv6)
878 @item Compressed and expanded input and output addresses.
879 @item Standard IPv6 network output.
880 @item v4 in v6 output.
881 @item Reverse DNS address generation.
884 (license license:bsd-3)))
892 (uri (string-append "mirror://gnu/alive/alive-"
896 "1vrzg51ai68x9yld7vbgl58sxaw5qpx8rbakwcxn4cqq6vpxj38j"))))
897 (build-system gnu-build-system)
898 (arguments '(#:configure-flags '("alive_cv_nice_ping=yes")))
899 (inputs `(("guile" ,guile-2.0)
900 ("inetutils" ,inetutils)))
901 (home-page "https://www.gnu.org/software/alive/")
902 (synopsis "Autologin and keep-alive daemon")
904 "GNU Alive sends periodic pings to a server, generally to keep a
906 (license license:gpl3+)))
908 (define-public isc-dhcp
909 (let* ((bind-major-version "9")
910 (bind-minor-version "11")
911 (bind-patch-version "18")
912 (bind-release-type "") ; for patch release, use "-P"
913 (bind-release-version "") ; for patch release, e.g. "6"
914 (bind-version (string-append bind-major-version
920 bind-release-version)))
926 (uri (string-append "https://ftp.isc.org/isc/dhcp/"
927 version "/dhcp-" version ".tar.gz"))
930 "08a5003zdxgl41b29zjkxa92h2i40zyjgxg0npvnhpkfl5jcsz0s"))))
931 (build-system gnu-build-system)
933 `(#:parallel-build? #f
934 #:configure-flags '("--with-randomdev=/dev/random")
936 (modify-phases %standard-phases
937 (add-after 'unpack 'replace-bundled-bind
938 (lambda* (#:key inputs native-inputs #:allow-other-keys)
939 (delete-file "bind/bind.tar.gz")
940 (copy-file (assoc-ref inputs "bind-source-tarball")
942 (chmod "bind/bind.tar.gz" #o644)
943 (substitute* "bind/version.tmp"
945 (format #f "MAJORVER=~a\n" ,bind-major-version))
947 (format #f "MINORVER=~a\n" ,bind-minor-version))
949 (format #f "PATCHVER=~a\n" ,bind-patch-version))
951 (format #f "RELEASETYPE=~a\n" ,bind-release-type))
953 (format #f "RELEASEVER=~a\n" ,bind-release-version)))
955 ,@(if (%current-target-system)
956 '((add-before 'configure 'fix-bind-cross-compilation
958 (substitute* "configure"
960 "--host=$host_alias"))
961 ;; BIND needs a native compiler because the DHCP
962 ;; build system uses the built 'gen' executable.
963 (setenv "BUILD_CC" "gcc")
966 (add-after 'configure 'post-configure
967 (lambda* (#:key outputs #:allow-other-keys)
968 ;; Point to the right client script, which will be
969 ;; installed in a later phase.
970 (substitute* "includes/dhcpd.h"
971 (("#define[[:blank:]]+_PATH_DHCLIENT_SCRIPT.*")
972 (let ((out (assoc-ref outputs "out")))
973 (string-append "#define _PATH_DHCLIENT_SCRIPT \""
974 out "/libexec/dhclient-script"
977 ;; During the 'build' phase, 'bind.tar.gz' is extracted, so
978 ;; we must patch shebangs in there and make sure the right
980 (with-directory-excursion "bind"
981 (substitute* "Makefile"
983 (let ((sh (which "sh")))
984 (string-append "./configure CONFIG_SHELL="
985 sh " SHELL=" sh " "))))
987 (let ((bind-directory (string-append "bind-" ,bind-version)))
988 (invoke "tar" "xf" "bind.tar.gz")
989 (for-each patch-shebang
990 (find-files bind-directory ".*"))
991 (substitute* (string-append bind-directory "/configure")
994 (invoke "tar" "cf" "bind.tar.gz"
996 ;; avoid non-determinism in the archive
1000 "--group=root:0")))))
1001 (add-after 'install 'post-install
1002 (lambda* (#:key inputs outputs #:allow-other-keys)
1003 ;; Install the dhclient script for GNU/Linux and make sure
1004 ;; if finds all the programs it needs.
1005 (let* ((out (assoc-ref outputs "out"))
1006 (libexec (string-append out "/libexec"))
1007 (coreutils (assoc-ref inputs "coreutils"))
1008 (inetutils (assoc-ref inputs "inetutils"))
1009 (net-tools (assoc-ref inputs "net-tools"))
1010 (sed (assoc-ref inputs "sed")))
1011 (substitute* "client/scripts/linux"
1013 (string-append (assoc-ref inputs "iproute")
1017 (copy-file "client/scripts/linux"
1018 (string-append libexec "/dhclient-script"))
1021 (string-append libexec "/dhclient-script")
1024 (string-append dir "/bin:"
1026 (list inetutils net-tools coreutils sed))))
1033 (inputs `(("inetutils" ,inetutils)
1034 ,@(if (hurd-target?) '()
1035 `(("net-tools" ,net-tools)
1036 ("iproute" ,iproute)))
1038 ;; isc-dhcp bundles a copy of BIND, which has proved vulnerable
1039 ;; in the past. Use a BIND-VERSION of our choosing instead.
1040 ("bind-source-tarball"
1043 (uri (string-append "https://ftp.isc.org/isc/bind9/"
1045 "/bind-" bind-version ".tar.gz"))
1048 "0vws0zzb39mkphj4hhjrgfj9dzw951lc4pfa6pqg5ll5ma51mbsr"))))
1050 ;; When cross-compiling, we need the cross Coreutils and sed.
1051 ;; Otherwise just use those from %FINAL-INPUTS.
1052 ,@(if (%current-target-system)
1053 `(("coreutils" ,coreutils)
1057 (home-page "https://www.isc.org/products/DHCP/")
1058 (synopsis "Dynamic Host Configuration Protocol (DHCP) tools")
1060 "ISC's Dynamic Host Configuration Protocol (DHCP) distribution provides a
1061 reference implementation of all aspects of DHCP, through a suite of DHCP
1062 tools: server, client, and relay agent.")
1063 (license license:mpl2.0)
1064 (properties '((cpe-name . "dhcp"))))))
1066 (define-public libpcap
1072 (uri (string-append "https://www.tcpdump.org/release/libpcap-"
1076 "153h1378diqyc27jjgz6gg5nxmb4ddk006d9xg69nqavgiikflk3"))))
1077 (build-system gnu-build-system)
1082 ;; There are some tests in testprogs/, but no automated test suite.
1084 (home-page "https://www.tcpdump.org")
1085 (synopsis "Network packet capture library")
1087 "libpcap is an interface for user-level packet capture. It provides a
1088 portable framework for low-level network monitoring. Applications include
1089 network statistics collection, security monitoring, network debugging, etc.")
1090 (license (list license:bsd-4 ; fad-*.c and several other source files
1091 license:bsd-3 ; pcap/, sockutils.* & others
1092 license:bsd-2)))) ; the rest
1094 (define-public tcpdump
1100 (uri (string-append "https://www.tcpdump.org/release/tcpdump-"
1104 "0434vdcnbqaia672rggjzdn4bb8p8dchz559yiszzdk0sjrprm1c"))))
1105 (build-system gnu-build-system)
1106 (inputs `(("libpcap" ,libpcap)
1107 ("openssl" ,openssl)))
1108 (native-inputs `(("perl" ,perl))) ; for tests
1109 (home-page "https://www.tcpdump.org/")
1110 (synopsis "Network packet analyzer")
1112 "Tcpdump is a command-line tool to analyze network traffic passing
1113 through the network interface controller.")
1114 (license license:bsd-3)))
1116 (define-public jnettop
1123 (string-append "https://web.archive.org/web/20161221100811/"
1124 "http://jnettop.kubs.info/dist/jnettop-"
1128 "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9"))))
1129 (build-system gnu-build-system)
1131 `(("pkg-config" ,pkg-config)))
1134 ("ncurses" ,ncurses)
1135 ("libpcap" ,libpcap)))
1137 "https://web.archive.org/web/20160703195221/http://jnettop.kubs.info/wiki/")
1138 (synopsis "Visualize network traffic by bandwidth use")
1140 "Jnettop is a traffic visualiser, which captures traffic going
1141 through the host it is running from and displays streams sorted
1142 by bandwidth they use.")
1143 (license license:gpl2+)))
1145 (define-public clusterssh
1151 (uri (string-append "mirror://sourceforge/clusterssh/"
1152 "2.%20ClusterSSH%20Series%204/"
1153 "App-ClusterSSH-v" version ".tar.gz"))
1156 "0rmk2p3f2wz1h092anidjclh212rv3gxyk0c641qk3frlrjnw6mp"))))
1157 (build-system perl-build-system)
1160 (modify-phases %standard-phases
1161 (add-after 'unpack 'refer-to-inputs
1162 (lambda* (#:key inputs #:allow-other-keys)
1163 (substitute* (list "lib/App/ClusterSSH/Config.pm"
1168 (add-before 'check 'delete-failing-tests
1170 ;; This checks whether all code is nicely formatted. The above
1171 ;; ‘refer-to-inputs’ phase breaks this pedantry, so disable it.
1172 (delete-file "t/perltidy.t")
1173 ;; Update the manifest so t/manifest.t happily passes.
1174 (substitute* "MANIFEST"
1175 (("t/perltidy.t\n") ""))
1177 (add-after 'install 'augment-library-path
1178 (lambda* (#:key inputs outputs #:allow-other-keys)
1179 (let* ((out (assoc-ref outputs "out"))
1180 (bin (string-append out "/bin")))
1181 (with-directory-excursion bin
1184 (wrap-program program
1185 `("PERL5LIB" ":" prefix
1186 ,(map (lambda (file-name)
1187 (string-append file-name
1188 "/lib/perl5/site_perl"))
1190 (map (lambda (input)
1191 (assoc-ref inputs input))
1192 ;; These may be propagated and hence
1193 ;; not explicitly listed as inputs.
1194 (list "perl-class-data-inheritable"
1195 "perl-devel-stacktrace"
1196 "perl-exception-class"
1200 "perl-x11-protocol-other")))))))
1201 (find-files "." ".*")))
1204 `(("perl-cpan-changes" ,perl-cpan-changes)
1205 ("perl-file-slurp" ,perl-file-slurp)
1206 ("perl-file-which" ,perl-file-which)
1207 ("perl-module-build" ,perl-module-build)
1208 ("perl-readonly" ,perl-readonly)
1209 ("perl-test-differences" ,perl-test-differences)
1210 ("perl-test-distmanifest" ,perl-test-distmanifest)
1211 ("perl-test-perltidy" ,perl-test-perltidy)
1212 ("perl-test-pod" ,perl-test-pod)
1213 ("perl-test-pod-coverage" ,perl-test-pod-coverage)
1214 ("perl-test-trap" ,perl-test-trap)
1215 ("perltidy" ,perltidy)))
1217 `(("perl-exception-class" ,perl-exception-class)
1218 ("perl-sort-naturally" ,perl-sort-naturally)
1219 ("perl-tk" ,perl-tk)
1220 ("perl-try-tiny" ,perl-try-tiny)
1221 ("perl-x11-protocol" ,perl-x11-protocol)
1222 ("perl-x11-protocol-other" ,perl-x11-protocol-other)
1224 ;; The clusterssh.sourceforge.net address requires login to view
1225 (home-page "https://sourceforge.net/projects/clusterssh/")
1226 (synopsis "Secure concurrent multi-server terminal control")
1228 "ClusterSSH controls a number of xterm windows via a single graphical
1229 console window to allow commands to be interactively run on multiple servers
1230 over ssh connections.")
1231 (license license:gpl2+)))
1233 (define-public rename
1240 "mirror://cpan/authors/id/R/RM/RMBARKER/File-Rename-"
1244 "137m8s06r4n038ivlr5r1d9a7q9l7shmwpvnyx053r9ndhvbnkh5"))))
1245 (build-system perl-build-system)
1248 (modify-phases %standard-phases
1249 (add-after 'install 'find-itself
1250 ;; Fix run-time 'Can't locate File/Rename.pm in @INC' failure.
1251 (lambda* (#:key outputs #:allow-other-keys)
1252 (let* ((out (assoc-ref outputs "out"))
1253 (bin (string-append out "/bin")))
1254 (with-directory-excursion bin
1257 (wrap-program program
1258 `("PERL5LIB" ":" prefix
1259 (,(string-append out "/lib/perl5/site_perl")))))
1260 (find-files "." ".*")))
1263 `(("perl-module-build" ,perl-module-build)
1264 ("perl-test-pod" ,perl-test-pod)
1265 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
1266 (home-page "https://metacpan.org/pod/distribution/File-Rename/rename.PL")
1267 (synopsis "Perl extension for renaming multiple files")
1269 "This package provides a Perl interface (@code{Perl::Rename}) as well
1270 as a command-line utility (@command{rename}) that can rename multiple files
1271 at once based on a Perl regular expression.")
1272 (license license:perl-license)))
1274 (define-public rottlog
1280 (uri (string-append "mirror://gnu/rottlog/rottlog-"
1284 "0751mb9l2f0jrk3vj6q8ilanifd121dliwk0c34g8k0dlzsv3kd7"))
1285 (modules '((guix build utils)))
1288 (substitute* "Makefile.in"
1289 (("-o \\$\\{LOG_OWN\\} -g \\$\\{LOG_GROUP\\}")
1290 ;; Don't try to chown root.
1292 (("mkdir -p \\$\\(ROTT_STATDIR\\)")
1293 ;; Don't attempt to create /var/lib/rottlog.
1296 (build-system gnu-build-system)
1298 `(#:configure-flags (list "ROTT_ETCDIR=/etc/rottlog" ;rc file location
1299 "--localstatedir=/var")
1301 ;; Install example config files in OUT/etc.
1302 #:make-flags (list (string-append "ROTT_ETCDIR="
1303 (assoc-ref %outputs "out")
1306 #:phases (modify-phases %standard-phases
1307 (add-after 'unpack 'patch-paths
1309 (substitute* "rc/rc"
1310 (("/usr/sbin/sendmail") "sendmail"))
1312 (add-after 'unpack 'fix-configure
1313 (lambda* (#:key inputs native-inputs #:allow-other-keys)
1314 ;; Replace outdated config.sub and config.guess:
1315 (for-each (lambda (file)
1319 (or native-inputs inputs) "automake")
1321 ,(version-major+minor
1322 (package-version automake))
1324 '("config.sub" "config.guess"))
1326 (add-after 'build 'set-packdir
1328 ;; Set a default location for archived logs.
1329 (substitute* "rc/rc"
1331 "packdir=\"/var/log\""))
1333 (add-before 'install 'tweak-rc-weekly
1335 (substitute* "rc/weekly"
1339 ;; The file is called 'syslog.pid' (no 'd').
1342 (add-after 'install 'install-info
1344 (invoke "make" "install-info"))))))
1345 (native-inputs `(("texinfo" ,texinfo)
1346 ("automake" ,automake)
1347 ("util-linux" ,util-linux))) ; for 'cal'
1348 (home-page "https://www.gnu.org/software/rottlog/")
1349 (synopsis "Log rotation and management")
1351 "GNU Rot[t]log is a program for managing log files. It is used to
1352 automatically rotate out log files when they have reached a given size or
1353 according to a given schedule. It can also be used to automatically compress
1354 and archive such logs. Rot[t]log will mail reports of its activity to the
1355 system administrator.")
1356 (license license:gpl3+)))
1365 (list (string-append "https://www.sudo.ws/sudo/dist/sudo-"
1367 (string-append "ftp://ftp.sudo.ws/pub/sudo/OLD/sudo-"
1368 version ".tar.gz")))
1371 "0p7r3cl16pjwbc48ff1gbhjw51lngrghvwblxz5lxpyzqlwi88xb"))
1372 (modules '((guix build utils)))
1375 (delete-file-recursively "lib/zlib")
1377 (build-system gnu-build-system)
1378 (outputs (list "out" "python"))
1381 (list (string-append "--docdir=" (assoc-ref %outputs "out")
1382 "/share/doc/" ,name "-" ,version)
1384 ;; XXX: Disable Python support when cross-compiling because
1385 ;; 'configure' tries to run 'python', which fails.
1386 ,(if (%current-target-system)
1388 "--enable-python") ; for plug-ins written in ~
1390 "--with-logpath=/var/log/sudo.log"
1391 "--with-rundir=/var/run/sudo" ; must be cleaned up at boot time
1392 "--with-vardir=/var/db/sudo"
1393 "--with-iologdir=/var/log/sudo-io"
1395 ;; 'visudo.c' expects _PATH_MV to be defined, but glibc doesn't
1397 (string-append "CPPFLAGS=-D_PATH_MV='\""
1398 (assoc-ref %build-inputs "coreutils")
1401 ;; Avoid non-determinism; see <http://bugs.gnu.org/21918>.
1402 #:parallel-build? #f
1405 (modify-phases %standard-phases
1406 (add-before 'configure 'pre-configure
1408 (substitute* "src/sudo_usage.h.in"
1409 ;; Do not capture 'configure' arguments since we would
1410 ;; unduly retain references, and also because the
1411 ;; CPPFLAGS above would close the string literal
1413 (("@CONFIGURE_ARGS@") "\"\""))
1414 (substitute* (find-files "." "Makefile\\.in")
1415 ;; Allow installation as non-root.
1416 (("-o [[:graph:]]+ -g [[:graph:]]+")
1418 ;; Don't try to create /etc/sudoers.
1419 (("^install: (.*)install-sudoers(.*)" _ before after)
1420 (string-append "install: " before after "\n"))
1421 ;; Don't try to create /run/sudo.
1422 (("\\$\\(DESTDIR\\)\\$\\(rundir\\)")
1424 ;; Install example sudo{,_logsrvd}.conf to the right place.
1425 (("\\$\\(DESTDIR\\)\\$\\(sysconfdir\\)")
1426 "$(DESTDIR)/$(docdir)/examples")
1427 ;; Don't try to create /var/db/sudo.
1428 (("\\$\\(DESTDIR\\)\\$\\(vardir\\)")
1431 ;; ‘Checking existing [/etc/]sudoers file for syntax errors’ is
1432 ;; not the task of the build system, and fails.
1433 (substitute* "plugins/sudoers/Makefile.in"
1434 (("^pre-install:" match)
1435 (string-append match "\ndisabled-" match)))
1437 (add-after 'install 'separate-python-output
1438 (lambda* (#:key target outputs #:allow-other-keys)
1439 (let ((out (assoc-ref outputs "out"))
1440 (out:python (assoc-ref outputs "python")))
1442 (mkdir-p (string-append out:python "/empty"))
1445 (let ((old (string-append out "/" file))
1446 (new (string-append out:python "/" file)))
1447 (mkdir-p (dirname new))
1448 (rename-file old new)))
1449 (list "libexec/sudo/python_plugin.so"
1450 "libexec/sudo/python_plugin.la")))
1453 ;; XXX: The 'testsudoers' test series expects user 'root' to exist, but
1454 ;; the chroot's /etc/passwd doesn't have it. Turn off the tests.
1457 `(("groff" ,groff)))
1459 `(("coreutils" ,coreutils)
1460 ("linux-pam" ,linux-pam)
1461 ,@(if (%current-target-system)
1463 `(("python" ,python)))
1465 (home-page "https://www.sudo.ws/")
1466 (synopsis "Run commands as root")
1468 "Sudo (su \"do\") allows a system administrator to delegate authority to
1469 give certain users (or groups of users) the ability to run some (or all)
1470 commands as root or another user while providing an audit trail of the
1471 commands and their arguments.")
1473 ;; See <http://www.sudo.ws/sudo/license.html>.
1474 (license license:x11)))
1476 (define-public opendoas
1483 (url "https://github.com/Duncaen/OpenDoas.git")
1484 (commit (string-append "v" version))))
1485 (file-name (git-file-name name version))
1488 "07kkc5729p654jrgfsc8zyhiwicgmq38yacmwfvay2b3gmy728zn"))))
1489 (build-system gnu-build-system)
1492 (modify-phases %standard-phases
1494 ;; The configure script doesn't accept most of the default flags.
1495 (lambda* (#:key configure-flags #:allow-other-keys)
1496 ;; The configure script can only be told which compiler to use
1497 ;; through environment variables.
1498 (setenv "CC" ,(cc-for-target))
1499 (apply invoke "./configure" configure-flags)))
1500 (add-before 'install 'fix-makefile
1501 (lambda* (#:key outputs #:allow-other-keys)
1502 (substitute* "bsd.prog.mk"
1503 (("^\tchown.*$") ""))
1506 (list (string-append "--prefix=" (assoc-ref %outputs "out"))
1507 ;; Nothing is done with this value (yet?) but it's supported.
1508 ;; (string-append "--target=" (or ,(%current-target-system) ""))
1510 ;; Compiler choice is not carried over from the configure script.
1512 (list (string-append "CC=" ,(cc-for-target)))
1513 #:tests? #f)) ; no test suite
1515 `(("bison" ,bison)))
1516 (home-page "https://github.com/Duncaen/OpenDoas")
1517 (synopsis "Portable version of OpenBSD's doas command")
1518 (description "Doas is a minimal replacement for the venerable sudo. It was
1519 initially written by Ted Unangst of the OpenBSD project to provide 95% of the
1520 features of sudo with a fraction of the codebase.")
1521 (license (list license:bsd-3 ; libbsd/*
1522 license:isc)))) ; everything else
1524 (define-public wpa-supplicant-minimal
1526 (name "wpa-supplicant-minimal")
1531 "https://w1.fi/releases/wpa_supplicant-"
1535 "05qzak1mssnxcgdrafifxh9w86a4ha69qabkg4bsigk499xyxggw"))
1536 (modules '((guix build utils)))
1539 (substitute* "wpa_supplicant/defconfig"
1540 ;; Disable D-Bus to save ~14MiB on the closure size.
1541 (("^CONFIG_CTRL_IFACE_DBUS" line _)
1542 (string-append "#" line)))
1544 (build-system gnu-build-system)
1547 (modify-phases %standard-phases
1549 (lambda* (#:key outputs #:allow-other-keys)
1550 (chdir "wpa_supplicant")
1551 (copy-file "defconfig" ".config")
1552 (let ((port (open-file ".config" "al")))
1554 CONFIG_DEBUG_SYSLOG=y
1558 CONFIG_DRIVER_NL80211=y
1559 CFLAGS += $(shell pkg-config libnl-3.0 --cflags)
1561 CONFIG_READLINE=y\n" port)
1564 (add-after 'install 'install-documentation
1565 (lambda* (#:key outputs #:allow-other-keys)
1566 (let* ((out (assoc-ref outputs "out"))
1567 (doc (string-append out "/share/doc/wpa-supplicant"))
1568 (man (string-append out "/share/man"))
1569 (man5 (string-append man "/man5"))
1570 (man8 (string-append man "/man8")))
1571 (define (copy-man-page target)
1573 (install-file file target)))
1575 (mkdir-p man5) (mkdir man8)
1576 (for-each (copy-man-page man5)
1577 (find-files "doc/docbook" "\\.5"))
1578 (for-each (copy-man-page man8)
1579 (find-files "doc/docbook" "\\.8"))
1581 ;; wpa_supplicant.conf(5) does not explain all configuration
1582 ;; options but refers to the example config file, so install it
1583 ;; along with READMEs.
1584 (for-each (lambda (file)
1585 (install-file file doc))
1586 '("README" "README-DPP" "README-HS20"
1587 "README-P2P" "README-WPS"
1588 "wpa_supplicant.conf"))
1591 #:make-flags (list "CC=gcc"
1592 (string-append "BINDIR=" (assoc-ref %outputs "out")
1594 (string-append "LIBDIR=" (assoc-ref %outputs "out")
1598 `(("readline" ,readline)
1600 ("openssl" ,openssl)))
1602 `(("pkg-config" ,pkg-config)))
1603 (home-page "https://w1.fi/wpa_supplicant/")
1604 (synopsis "Connecting to WPA and WPA2-protected wireless networks")
1606 "wpa_supplicant is a WPA Supplicant with support for WPA and WPA2 (IEEE
1607 802.11i / RSN). Supplicant is the IEEE 802.1X/WPA component that is used in
1608 the client stations. It implements key negotiation with a WPA Authenticator
1609 and it controls the roaming and IEEE 802.11 authentication/association of the
1612 This package provides the @code{wpa_supplicant} daemon and the @code{wpa_cli}
1615 ;; In practice, this is linked against Readline, which makes it GPLv3+.
1616 (license license:bsd-3)
1618 (properties `((cpe-name . "wpa_supplicant")))))
1620 (define-public wpa-supplicant
1621 (package (inherit wpa-supplicant-minimal)
1622 (name "wpa-supplicant")
1623 (inputs `(("dbus" ,dbus)
1624 ,@(package-inputs wpa-supplicant-minimal)))
1626 (substitute-keyword-arguments (package-arguments wpa-supplicant-minimal)
1628 `(modify-phases ,phases
1629 (add-after 'configure 'configure-for-dbus
1631 (let ((port (open-file ".config" "al")))
1633 CONFIG_CTRL_IFACE_DBUS_NEW=y
1634 CONFIG_CTRL_IFACE_DBUS_INTRO=y\n" port)
1637 (add-after 'install-documentation 'install-dbus-conf
1638 (lambda* (#:key outputs #:allow-other-keys)
1639 (let* ((out (assoc-ref outputs "out"))
1640 (dir (string-append out "/etc/dbus-1/system.d")))
1642 (copy-file "dbus/dbus-wpa_supplicant.conf"
1643 (string-append dir "/wpa_supplicant.conf")))
1646 (define-public wpa-supplicant-gui
1648 (inherit wpa-supplicant)
1649 (name "wpa-supplicant-gui")
1650 (inputs `(("qtbase" ,qtbase)
1652 ,@(package-inputs wpa-supplicant)))
1655 `(("imagemagick" ,imagemagick)
1656 ("inkscape" ,inkscape)
1657 ,@(package-native-inputs wpa-supplicant)))
1659 `(#:phases (modify-phases %standard-phases
1660 (add-after 'unpack 'chdir
1662 (chdir "wpa_supplicant/wpa_gui-qt4")
1667 (invoke "qmake" "wpa_gui.pro")
1668 (invoke "make" "-j" (number->string (parallel-job-count)))
1669 (invoke "make" "-C" "icons")))
1671 (lambda* (#:key inputs outputs #:allow-other-keys)
1672 (let ((out (assoc-ref outputs "out"))
1673 (qt '("qtbase" "qtsvg")))
1674 (install-file "wpa_gui" (string-append out "/bin"))
1675 (install-file "wpa_gui.desktop"
1676 (string-append out "/share/applications"))
1677 (copy-recursively "icons/hicolor"
1678 (string-append out "/share/icons/hicolor"))
1679 (wrap-program (string-append out "/bin/wpa_gui")
1680 `("QT_PLUGIN_PATH" ":" prefix
1681 ,(map (lambda (label)
1682 (string-append (assoc-ref inputs label)
1683 "/lib/qt5/plugins/"))
1686 (synopsis "Graphical user interface for WPA supplicant")))
1688 (define-public hostapd
1694 (uri (string-append "https://w1.fi/releases/hostapd-" version
1698 "1mrbvg4v7vm7mknf0n29mf88k3s4a4qj6r4d51wq8hmjj1m7s7c8"))))
1699 (build-system gnu-build-system)
1702 (modify-phases %standard-phases
1704 (lambda* (#:key outputs #:allow-other-keys)
1705 ;; This is mostly copied from 'wpa-supplicant' above.
1707 (copy-file "defconfig" ".config")
1708 (let ((port (open-file ".config" "al")))
1713 CONFIG_IEEE80211AC=y\n" port)
1716 (add-after 'install 'install-man-pages
1717 (lambda* (#:key outputs #:allow-other-keys)
1718 (let* ((out (assoc-ref outputs "out"))
1719 (man (string-append out "/share/man"))
1720 (man1 (string-append man "/man1"))
1721 (man8 (string-append man "/man8")))
1722 (define (copy-man-page target)
1724 (install-file file target)))
1726 (for-each (copy-man-page man1)
1727 (find-files "." "\\.1"))
1728 (for-each (copy-man-page man8)
1729 (find-files "." "\\.8"))
1732 #:make-flags (list "CC=gcc"
1733 (string-append "BINDIR=" (assoc-ref %outputs "out")
1735 (string-append "LIBDIR=" (assoc-ref %outputs "out")
1738 (native-inputs `(("pkg-config" ,pkg-config)))
1740 ;; There's an optional dependency on SQLite.
1741 (inputs `(("openssl" ,openssl)
1743 (home-page "https://w1.fi/hostapd/")
1744 (synopsis "Daemon for Wi-Fi access points and authentication servers")
1746 "hostapd is a user-space daemon for WiFi access points and authentication
1747 servers. It implements IEEE 802.11 access point management, IEEE
1748 802.1X/WPA/WPA2/EAP Authenticators, RADIUS client, EAP server, and RADIUS
1749 authentication server.")
1751 ;; Same license as wpa_supplicant.
1752 (license license:bsd-3)))
1754 (define-public wakelan
1761 "ftp://ftp.gwdg.de/pub/linux/metalab/system/network/misc/wakelan-"
1765 "0vydqpf44146ir6k87gmqaq6xy66xhc1gkr3nsd7jj3nhy7ypx9x"))))
1766 (build-system gnu-build-system)
1769 (modify-phases %standard-phases
1771 (lambda* (#:key outputs #:allow-other-keys)
1772 (let ((out (assoc-ref outputs "out")))
1773 (mkdir-p (string-append out "/bin"))
1774 (mkdir-p (string-append out "/share/man/man1"))
1776 ;; It's an old configure script that doesn't understand
1777 ;; the extra options we pass.
1778 (setenv "CONFIG_SHELL" (which "bash"))
1779 (invoke "./configure"
1780 (string-append "--prefix=" out)
1781 (string-append "--mandir=" out
1784 (home-page "https://www.kernel.org") ; really, no home page
1785 (synopsis "Send a wake-on-LAN packet")
1787 "WakeLan broadcasts a properly formatted UDP packet across the local area
1788 network, which causes enabled computers to power on.")
1789 (license license:gpl2+)))
1791 (define-public dmidecode
1798 "mirror://savannah/dmidecode/dmidecode-"
1802 "1pcfhcgs2ifdjwp7amnsr3lq95pgxpr150bjhdinvl505px0cw07"))))
1803 (build-system gnu-build-system)
1805 '(#:phases (modify-phases %standard-phases (delete 'configure))
1806 #:tests? #f ; no 'check' target
1807 #:make-flags (list (string-append "prefix="
1808 (assoc-ref %outputs "out")))))
1809 (home-page "https://www.nongnu.org/dmidecode/")
1810 (synopsis "Read hardware information from the BIOS")
1812 "Dmidecode reports information about your system's hardware as described
1813 in your system BIOS according to the SMBIOS/DMI standard. This typically
1814 includes system manufacturer, model name, serial number, BIOS version, asset
1815 tag as well as a lot of other details of varying level of interest and
1816 reliability depending on the manufacturer. This will often include usage
1817 status for the CPU sockets, expansion slots (e.g. AGP, PCI, ISA) and memory
1818 module slots, and the list of I/O ports (e.g. serial, parallel, USB).")
1819 (license license:gpl2+)))
1821 (define-public acpica
1824 (version "20200528")
1828 "https://acpica.org/sites/acpica/files/acpica-unix2-"
1832 "01ajxnz9dpnvdbib7yv20dw21a1yyfgwiw3whg0xi57cf4app2md"))))
1833 (build-system gnu-build-system)
1834 (native-inputs `(("flex" ,flex)
1837 '(#:make-flags (list (string-append "PREFIX=" %output)
1840 "OPT_CFLAGS=-Wall -fno-strict-aliasing")
1841 #:tests? #f ; no 'check' target
1842 #:phases (modify-phases %standard-phases (delete 'configure))))
1843 (home-page "https://acpica.org/")
1844 (synopsis "Tools for the development and debugging of ACPI tables")
1846 "The @acronym{ACPICA, ACPI Component Architecture} project provides an
1847 OS-independent reference implementation of the @acronym{ACPI, Advanced
1848 Configuration and Power Interface} specification. ACPICA code contains those
1849 portions of ACPI meant to be directly integrated into the host OS as a
1850 kernel-resident subsystem, and a small set of tools to assist in developing and
1851 debugging ACPI tables.
1853 This package contains only the user-space tools needed for ACPI table
1854 development, not the kernel implementation of ACPI.")
1855 (license license:gpl2))) ; dual GPLv2/ACPICA Licence
1857 (define-public s-tui
1864 (uri (pypi-uri "s-tui" version))
1866 (base32 "0r5yhlsi5xiy7ii1w4kqkaxz9069v5bbfwi3x3xnxhk51yjfgr8n"))))
1867 (build-system python-build-system)
1869 `(("python-psutil" ,python-psutil)
1870 ("python-urwid" ,python-urwid)))
1871 (home-page "https://github.com/amanusk/s-tui")
1872 (synopsis "Interactive terminal stress test and monitoring tool")
1874 "The Stress Terminal UI displays graphs of the CPU frequency,
1875 utilization, temperature and power.")
1876 (license license:gpl2+)))
1878 (define-public stress
1884 (uri (string-append "mirror://debian/pool/main/s/stress/stress_"
1885 version ".orig.tar.gz"))
1888 "0nw210jajk38m3y7h8s130ps2qsbz7j75wab07hi2r3hlz14yzh5"))))
1889 (build-system gnu-build-system)
1890 (home-page "https://packages.debian.org/sid/stress")
1891 (synopsis "Impose load on and stress test a computer system")
1893 "Stress is a tool that imposes a configurable amount of CPU, memory, I/O,
1894 or disk stress on a POSIX-compliant operating system and reports any errors it
1897 Stress is not a benchmark. It is a tool used by system administrators to
1898 evaluate how well their systems will scale, by kernel programmers to evaluate
1899 perceived performance characteristics, and by systems programmers to expose
1900 the classes of bugs which only or more frequently manifest themselves when the
1901 system is under heavy load.")
1902 (license license:gpl2+)))
1904 (define-public detox
1911 (url "https://github.com/dharple/detox.git")
1912 (commit (string-append "v" version))))
1913 (file-name (git-file-name name version))
1916 "1dd608c7g65s5lj02cddvani3q9kzirddgkjqa22ap9d4f8b9xgr"))))
1917 (build-system gnu-build-system)
1919 `(("autoconf" ,autoconf)
1920 ("automake" ,automake)
1923 `(#:tests? #f ;no 'check' target
1924 #:phases (modify-phases %standard-phases
1925 (add-after 'unpack 'delete-configure
1926 ;; The "configure" script is present, but otherwise the
1927 ;; project is not bootstrapped: missing install-sh and
1928 ;; Makefile.in, so delete it so the bootstrap phase will
1930 (lambda _ (delete-file "configure") #t)))))
1931 (home-page "https://github.com/dharple/detox")
1932 (synopsis "Clean up file names")
1934 "Detox is a program that renames files to make them easier to work with
1935 under Unix and related operating systems. Spaces and various other unsafe
1936 characters (such as \"$\") get replaced with \"_\". ISO 8859-1 (Latin-1)
1937 characters can be replaced as well, as can UTF-8 characters.")
1938 (license license:bsd-3)))
1940 (define-public testdisk
1946 (uri (string-append "https://www.cgsecurity.org/testdisk-"
1947 version ".tar.bz2"))
1950 "1zlh44w67py416hkvw6nrfmjickc2d43v51vcli5p374d5sw84ql"))))
1951 (build-system gnu-build-system)
1953 `(("ntfs-3g" ,ntfs-3g)
1954 ("util-linux" ,util-linux "lib")
1955 ("openssl" ,openssl)
1956 ;; FIXME: add reiserfs.
1958 ("e2fsprogs" ,e2fsprogs)
1959 ("libjpeg" ,libjpeg-turbo)
1960 ("ncurses" ,ncurses)))
1961 (home-page "https://www.cgsecurity.org/wiki/TestDisk")
1962 (synopsis "Data recovery tool")
1964 "TestDisk is a program for data recovery, primarily designed to help
1965 recover lost partitions and/or make non-booting disks bootable again.")
1966 (license license:gpl2+)))
1975 "http://mama.indstate.edu/users/ice/tree/src/tree-"
1978 (base32 "1hmpz6k0mr6salv0nprvm1g0rdjva1kx03bdf1scw8a38d5mspbi"))))
1979 (build-system gnu-build-system)
1981 '(#:phases (modify-phases %standard-phases (delete 'configure))
1982 #:tests? #f ; no check target
1983 #:make-flags (let ((out (assoc-ref %outputs "out")))
1984 (list (string-append "prefix=" out)))))
1985 (synopsis "Recursively list the contents of a directory")
1987 "Tree is a recursive directory listing command that produces a depth
1988 indented listing of files, which is colorized ala dircolors if the LS_COLORS
1989 environment variable is set and output is to tty.")
1990 (home-page "http://mama.indstate.edu/users/ice/tree/")
1991 (license license:gpl2+)))
1993 (define-public direvent
1999 (uri (string-append "mirror://gnu/direvent/direvent-"
2003 "0m9vi01b1km0cpknflyzsjnknbava0s1n6393b2bpjwyvb6j5613"))
2004 (modules '((guix build utils)))
2006 (substitute* "tests/testsuite"
2007 (("#![[:blank:]]?/bin/sh")
2010 (build-system gnu-build-system)
2013 (modify-phases %standard-phases
2014 (add-before 'build 'patch-/bin/sh
2015 (lambda* (#:key inputs #:allow-other-keys)
2016 ;; Use the right shell when executing the watcher and
2017 ;; user-provided shell commands.
2018 (let ((bash (assoc-ref inputs "bash")))
2019 (substitute* '("src/direvent.c" "src/progman.c")
2021 (string-append "\"" bash "/bin/sh\"")))
2023 ;; Adjust the 'shell.at' test accordingly.
2024 (substitute* "tests/testsuite"
2026 (string-append "SHELL=" bash "/bin/sh")))
2029 (home-page "https://www.gnu.org.ua/software/direvent/")
2030 (synopsis "Daemon to monitor directories for events such as file removal")
2032 "A daemon that monitors directories for events, such as creating,
2033 deleting or modifying files. It can monitor different sets of directories for
2034 different events. When an event is detected, direvent calls a specified
2035 external program with information about the event, such as the location
2036 within the file system where it occurred. Thus, \"direvent\" provides an
2037 easy way to react immediately if given files undergo changes, for example, to
2038 track changes in important system configuration files.")
2039 (license license:gpl3+)))
2041 (define-public libcap-ng
2048 "https://people.redhat.com/sgrubb/libcap-ng/libcap-ng-"
2052 "1gzzy12agfa9ddipdf72h9y68zqqnvsjjylv4vnq6hj4w2safk58"))))
2053 (build-system gnu-build-system)
2056 (list "--without-python")))
2057 (home-page "https://people.redhat.com/sgrubb/libcap-ng/")
2058 (synopsis "Library for more easily working with POSIX capabilities")
2060 "The libcap-ng library is intended to make programming with POSIX
2061 capabilities easier than the traditional libcap library. It includes
2062 utilities that can analyse all currently running applications and print out
2063 any capabilities and whether or not it has an open ended bounding set. The
2064 included utilities are designed to let admins and developers spot apps from
2065 various ways that may be running with too much privilege.")
2066 ;; The library is lgpl2.1+, but also ships some utils which are gpl2+.
2067 (license (list license:lgpl2.1+ license:gpl2+))))
2069 (define-public smartmontools
2071 (name "smartmontools")
2076 "mirror://sourceforge/smartmontools/smartmontools/"
2077 version "/smartmontools-" version ".tar.gz"))
2080 "0imqb7ka4ia5573w8rnpck571pjjc9698pdjcapy9cfyk4n4swrz"))))
2081 (build-system gnu-build-system)
2082 (inputs `(("libcap-ng" ,libcap-ng)))
2083 (home-page "https://www.smartmontools.org/")
2084 (synopsis "S.M.A.R.T. harddisk control and monitoring tools")
2086 "The smartmontools package contains utility programs to control and
2087 monitor storage systems using the Self-Monitoring, Analysis and Reporting
2088 Technology System (@dfn{S.M.A.R.T.}) built into most modern ATA and SCSI hard
2089 disks. In many cases, these utilities will provide advanced warning of disk
2090 degradation and failure.")
2091 (license license:gpl2+)))
2093 (define-public fdupes
2101 (url "https://github.com/adrianlopezroche/fdupes.git")
2102 (commit (string-append "v" version))))
2103 (file-name (git-file-name name version))
2105 (base32 "19b6vqblddaw8ccw4sn0qsqzbswlhrz8ia6n4m3hymvcxn8skpz9"))))
2106 (build-system gnu-build-system)
2108 '(#:phases (modify-phases %standard-phases
2109 (delete 'configure))
2110 #:tests? #f ; no 'check' target
2111 #:make-flags (list "CC=gcc"
2112 (string-append "PREFIX="
2113 (assoc-ref %outputs "out")))))
2114 (home-page "https://github.com/adrianlopezroche/fdupes")
2115 (synopsis "Identify duplicate files")
2117 "fdupes is a program for identifying duplicate files residing within
2118 specified directories.")
2119 (license license:expat)))
2121 (define-public graphios
2128 (uri (pypi-uri "graphios" version))
2131 "1h87hvc315wg6lklbf4l7csd3n5pgljwrfli1p3nasdi0izgn66i"))))
2132 (build-system python-build-system)
2134 ;; Be warned: Building with Python 3 succeeds, but the build process
2135 ;; throws a syntax error that is ignored.
2136 `(#:python ,python-2
2138 (modify-phases %standard-phases
2139 (add-before 'build 'fix-setup.py
2140 (lambda* (#:key outputs #:allow-other-keys)
2141 ;; Fix hardcoded, unprefixed file names.
2142 (let ((out (assoc-ref outputs "out")))
2143 (substitute* '("setup.py")
2144 (("/etc") (string-append out "/etc"))
2146 (("distro_ver = .*") "distro_ver = ''"))
2148 (home-page "https://github.com/shawn-sterling/graphios")
2149 (synopsis "Emit Nagios metrics to Graphite, Statsd, and Librato")
2151 "Graphios is a script to emit nagios perfdata to various upstream metrics
2152 processing and time-series systems. It's currently compatible with Graphite,
2153 Statsd, Librato and InfluxDB. Graphios can emit Nagios metrics to any number
2154 of supported upstream metrics systems simultaneously.")
2155 (license license:gpl2+)))
2157 (define-public ansible
2164 (uri (pypi-uri "ansible" version))
2166 (base32 "1l99vwkl48iwr8ffd1ihqia995mz8h8hwk4akm4w0cgiifp88gg8"))))
2167 (build-system python-build-system)
2169 `(("python-bcrypt" ,python-bcrypt)
2170 ("python-pynacl" ,python-pynacl)
2171 ("python-httplib2" ,python-httplib2)
2172 ("python-passlib" ,python-passlib)
2173 ("python-nose" ,python-nose)
2174 ("python-mock" ,python-mock)
2175 ("python-jinja2" ,python-jinja2)
2176 ("python-pyyaml" ,python-pyyaml)
2177 ("python-paramiko" ,python-paramiko)))
2179 `(("python-cryptography" ,python-cryptography)
2180 ("python-jinja2" ,python-jinja2)
2181 ("python-pyyaml" ,python-pyyaml)
2182 ("python-paramiko" ,python-paramiko)))
2185 (modify-phases %standard-phases
2186 ;; Several ansible commands (ansible-config, ansible-console, etc.)
2187 ;; are just symlinks to a single ansible executable. The ansible
2188 ;; executable behaves differently based on the value of
2189 ;; sys.argv[0]. This does not work well with our wrap phase, and
2190 ;; therefore the following two phases are required as a workaround.
2191 (add-after 'unpack 'hide-wrapping
2193 ;; Overwrite sys.argv[0] to hide the wrapper script from it.
2194 (substitute* "bin/ansible"
2195 (("import traceback" all)
2196 (string-append all "
2198 sys.argv[0] = re.sub(r'\\.([^/]*)-real$', r'\\1', sys.argv[0])
2201 (add-after 'install 'replace-symlinks
2202 (lambda* (#:key outputs #:allow-other-keys)
2203 ;; Replace symlinks with duplicate copies of the ansible
2205 (let ((out (assoc-ref outputs "out")))
2207 (lambda (subprogram)
2208 (delete-file (string-append out "/bin/ansible-" subprogram))
2209 (copy-file (string-append out "/bin/ansible")
2210 (string-append out "/bin/ansible-" subprogram)))
2211 (list "config" "console" "doc" "galaxy"
2212 "inventory" "playbook" "pull" "vault")))
2214 (home-page "https://www.ansible.com/")
2215 (synopsis "Radically simple IT automation")
2216 (description "Ansible is a radically simple IT automation system. It
2217 handles configuration management, application deployment, cloud provisioning,
2218 ad hoc task execution, and multinode orchestration---including trivializing
2219 things like zero-downtime rolling updates with load balancers.")
2220 (license license:gpl3+)))
2222 (define-public debops
2230 (url "https://github.com/debops/debops")
2231 (commit (string-append "v" version))))
2232 (file-name (git-file-name name version))
2234 (base32 "052b2dykdn35pdpn9s4prawl6nl6yzih8nyf54hpvhpisvjrm1v5"))
2236 (search-patches "debops-constants-for-external-program-names.patch"
2237 "debops-debops-defaults-fall-back-to-less.patch"))))
2238 (build-system python-build-system)
2242 `(("ansible" ,ansible)
2245 ("util-linux" ,util-linux) ;; for umount
2246 ("findutils" ,findutils)
2250 `(("python-future" ,python-future)
2251 ("python-distro" ,python-distro)))
2255 (modify-phases %standard-phases
2256 (add-after 'unpack 'nuke-debops-update
2258 (chmod "bin/debops-update" #o755) ; FIXME work-around git-fetch issue
2259 (with-output-to-file "bin/debops-update"
2261 (format #t "#!/bin/sh
2262 echo 'debops is installed via guix. guix-update is useless in this case.
2263 Please use `guix package -u debops` instead.'")))
2265 ;; patch shebangs only in actuall scripts, not in files included in
2266 ;; roles (which are to be delivered to the targte systems)
2267 (delete `patch-generated-file-shebangs)
2268 (replace 'patch-source-shebangs
2270 (for-each patch-shebang
2273 ;; Filter out symlinks.
2274 (eq? 'regular (stat:type stat)))
2276 (add-after 'unpack 'fix-paths
2278 (define (substitute-program-names file)
2279 ;; e.g. ANSIBLE_PLAYBOOK = '/gnu/store/…/bin/ansible-playbook'
2282 (let ((varname (string-upcase
2284 (lambda (c) (if (char=? c #\-) #\_ c))
2287 (((string-append "^(" varname " = )'.*'") line prefix)
2288 (string-append prefix "'" (which name) "'")))))
2289 '("ansible-playbook" "encfs" "find" "fusermount"
2290 "umount" "gpg" "ansible" "which")))
2291 (for-each substitute-program-names
2293 "bin/debops-padlock"
2295 "debops/__init__.py"
2296 "debops/cmds/__init__.py"))
2298 (home-page "https://www.debops.org/")
2299 (synopsis "Collection of general-purpose Ansible roles")
2300 (description "The Ansible roles provided by that can be used to manage
2301 Debian or Ubuntu hosts. In addition, a default set of Ansible playbooks can
2302 be used to apply the provided roles in a controlled way, using Ansible
2305 The roles are written with a high customization in mind, which can be done
2306 using Ansible inventory. This way the role and playbook code can be shared
2307 between multiple environments, with different configuration in to each one.
2309 Services can be managed on a single host, or spread between multiple hosts.
2310 DebOps provides support for different SQL and NoSQL databases, web servers,
2311 programming languages and specialized applications useful in a data center
2312 environment or in a cluster. The project can also be used to deploy
2313 virtualization environments using KVM/libvirt, Docker or LXC technologies to
2314 manage virtual machines and/or containers.")
2315 (license license:gpl3+)))
2317 (define-public emacs-ansible-doc
2318 (let ((commit "86083a7bb2ed0468ca64e52076b06441a2f8e9e0"))
2320 (name "emacs-ansible-doc")
2321 (version (git-version "0.4" "1" commit))
2326 (url "https://github.com/lunaryorn/ansible-doc.el")
2328 (file-name (git-file-name name version))
2331 "0lap404ch74w99n3xip176jr42b38xhyzkfnkyqg0g3wk2cd3aq8"))))
2332 (build-system emacs-build-system)
2333 ;; Unmaintained by upstream.
2334 (home-page "https://github.com/lunaryorn/ansible-doc.el")
2335 (synopsis "Ansible documentation for Emacs")
2337 "This package provides an Ansible documentation for GNU Emacs.
2339 @code{ansible-doc} allows you to view the documentation of an Ansible
2340 module and @code{ansible-doc-mode} minor mode adds documentation
2341 lookup to YAML Mode. You could enable the mode with @code{(add-hook
2342 'yaml-mode-hook #'ansible-doc-mode)}.")
2343 (license license:gpl3+))))
2345 (define-public cpulimit
2353 (url "https://github.com/opsengine/cpulimit.git")
2354 (commit (string-append "v" version))))
2355 (file-name (git-file-name name version))
2357 (base32 "1dz045yhcsw1rdamzpz4bk8mw888in7fyqk1q1b3m1yk4pd1ahkh"))))
2358 (build-system gnu-build-system)
2360 `(#:phases (modify-phases %standard-phases
2364 (invoke "make" "CC=gcc" "-Csrc")))
2367 (invoke "make" "CC=gcc" "-Ctests")))
2369 (lambda* (#:key outputs #:allow-other-keys)
2370 (let* ((out (assoc-ref outputs "out"))
2371 (bin (string-append out "/bin")))
2372 (install-file "src/cpulimit" bin))
2374 (home-page "https://github.com/opsengine/cpulimit")
2375 (synopsis "Limit CPU usage")
2377 "Cpulimit limits the CPU usage of a process. It does not change the nice
2378 value or other scheduling priority settings, but the real CPU usage, and is
2379 able to adapt itself dynamically to the overall system load. Children
2380 processes and threads of the specified process may optionally share the same
2382 (license license:gpl2+)))
2384 (define-public autojump
2392 (url "https://github.com/wting/autojump.git")
2393 (commit (string-append "release-v" version))))
2394 (file-name (git-file-name name version))
2396 (base32 "1rgpsh70manr2dydna9da4x7p8ahii7dgdgwir5fka340n1wrcws"))))
2397 (build-system gnu-build-system)
2398 (native-inputs ; for tests
2399 `(("python-mock" ,python-mock)
2400 ("python-pytest" ,python-pytest)))
2402 `(("python" ,python-wrapper)))
2405 (modify-phases %standard-phases
2406 (add-after 'unpack 'make-git-checkout-writable
2407 ;; ‘install.py’ modifies files before installing them.
2409 (for-each make-file-writable (find-files "."))
2415 (invoke "python" "tests/unit/autojump_utils_test.py")))
2417 (lambda* (#:key outputs #:allow-other-keys)
2418 (setenv "SHELL" (which "bash"))
2419 (invoke "python" "install.py"
2420 (string-append "--destdir="
2421 (assoc-ref outputs "out"))))))))
2422 (home-page "https://github.com/wting/autojump")
2423 (synopsis "Shell extension for file system navigation")
2425 "Autojump provides a faster way to navigate your file system, with a \"cd
2426 command that learns\". It works by maintaining a database of the directories
2427 you use the most from the command line and allows you to \"jump\" to
2428 frequently used directories by typing only a small pattern.")
2429 (license license:gpl3+)))
2438 (url "https://github.com/clvv/fasd.git")
2440 (file-name (git-file-name name version))
2443 "1awi71jdv3mhjrmar2d4z1i90kn7apd7aq1w31sh6w4yibz9kiyj"))))
2444 (build-system gnu-build-system)
2446 `(#:phases (modify-phases %standard-phases
2447 (delete 'configure)) ;no configuration
2448 #:tests? #f ;no tests
2449 #:make-flags (list (string-append "PREFIX=" %output))))
2450 (home-page "https://github.com/clvv/fasd")
2451 (synopsis "Quick access to files and directories for shells")
2453 "Fasd (pronounced similar to \"fast\") is a command-line productivity
2454 booster. Fasd offers quick access to files and directories for POSIX shells.
2455 It is inspired by tools like autojump, z, and v. Fasd keeps track of files
2456 and directories you have accessed so that you can quickly reference them in
2458 (license license:x11)))
2460 (define-public iftop
2466 (uri (string-append "http://www.ex-parrot.com/~pdw/iftop/download"
2467 "/iftop-" version ".tar.gz"))
2470 "15sgkdyijb7vbxpxjavh5qm5nvyii3fqcg9mzvw7fx8s6zmfwczp"))))
2471 (build-system gnu-build-system)
2473 `(("libpcap" ,libpcap)
2474 ("ncurses" ,ncurses)))
2475 (synopsis "Monitor network usage")
2476 (description "Iftop does for network usage what @command{top} does
2477 for CPU usage. It listens to network traffic on a named interface and
2478 displays a table of current bandwidth usage by pairs of hosts.")
2479 (home-page "http://www.ex-parrot.com/~pdw/iftop/")
2480 (license license:gpl2+)))
2482 (define-public munge
2488 (uri (string-append "https://github.com/dun/munge/releases/"
2489 "download/munge-" version "/munge-"
2493 "0h06sghb4rqvv1ywyd6mzsmbcgh712v6ygrff0gzm440y4ca41k6"))
2494 (modules '((guix build utils)))
2497 ;; Don't insist on write access to /var.
2498 (substitute* "src/etc/Makefile.in"
2499 (("\\$\\(INSTALL\\)(.*)localstatedir" _ middle)
2500 (string-append "-$(INSTALL)" middle "localstatedir"))
2501 (("\\$\\(MKDIR_P\\) .*(local|run)statedir.*")
2505 `(("openssl" ,openssl)
2506 ("libgcrypt" ,libgcrypt)))
2507 (build-system gnu-build-system)
2510 (list "--localstatedir=/var"
2511 (string-append "--with-pkgconfigdir="
2512 (assoc-ref %outputs "out") "/lib/pkgconfig"))
2514 (modify-phases %standard-phases
2515 ;; XXX Many test series fail. Some might be fixable, others do no-no
2516 ;; things like invoking ‘sudo’.
2517 (add-after 'unpack 'skip-failing-tests
2519 (for-each (lambda (test)
2520 (substitute* "t/Makefile.in"
2521 (((string-append test "\\.t ")) "")))
2522 (list "0100-munged-lock"
2524 "0011-munged-cmdline"
2525 "0012-munge-cmdline"
2526 "0013-unmunge-cmdline"
2527 "0101-munged-security-socket"
2528 "0102-munged-security-keyfile"
2529 "0103-munged-security-logfile"
2530 "0110-munged-origin-addr"))
2532 (home-page "https://dun.github.io/munge/")
2533 (synopsis "Cluster computing authentication service")
2535 "Munge is an authentication service for creating and validating
2536 credentials. It allows a process to authenticate the UID and GID of another
2537 local or remote process within a group of hosts having common users and
2538 groups. These hosts form a security realm that is defined by a shared
2539 cryptographic key. Clients within this security realm can create and validate
2540 credentials without the use of root privileges, reserved ports, or
2541 platform-specific methods.")
2542 (license license:gpl3+)))
2544 (define-public audit
2547 (home-page "https://people.redhat.com/sgrubb/audit/")
2551 (uri (string-append home-page "audit-" version ".tar.gz"))
2554 "1dzcwb2q78q7x41shcachn7f4aksxbxd470yk38zh03fch1l2p8f"))))
2555 (build-system gnu-build-system)
2557 `(#:configure-flags (list "--with-python=no"
2558 "--disable-static")))
2560 `(("openldap" ,openldap)
2562 ("sasl" ,cyrus-sasl)))
2563 (synopsis "User-space component to the Linux auditing system")
2565 "auditd is the user-space component to the Linux auditing system, which
2566 allows logging of system calls made by user-land processes. It's responsible
2567 for writing audit records to the disk. Viewing the logs is done with the
2568 @code{ausearch} or @code{aureport} utilities. Configuring the audit rules is
2569 done with the @code{auditctl} utility.")
2570 (license license:gpl2+)))
2578 (uri (string-append "https://nmap.org/dist/nmap-" version
2582 "1aizfys6l9f9grm82bk878w56mg0zpkfns3spzj157h98875mypw"))
2583 (modules '((guix build utils)))
2586 (for-each delete-file-recursively
2587 ;; Remove bundled lua, pcap, and pcre libraries.
2588 ;; FIXME: Remove bundled liblinear once packaged.
2592 ;; Remove pre-compiled binares.
2595 (build-system gnu-build-system)
2597 `(("openssl" ,openssl)
2598 ("libpcap" ,libpcap)
2601 ("zlib" ,zlib) ;for NSE compression support
2604 ("python" ,python-2)))
2606 ;; TODO Add zenmap output.
2607 (outputs '("out" "ndiff"))
2609 `(#:configure-flags '("--without-zenmap")
2611 (modify-phases %standard-phases
2612 (add-after 'configure 'patch-Makefile
2614 (substitute* "Makefile"
2615 ;; Do not attempt to build lua.
2616 (("build-dnet build-lua") "build-dnet"))
2619 (lambda* (#:key outputs #:allow-other-keys)
2620 (define (make out . args)
2621 (apply invoke "make"
2622 (string-append "prefix=" out)
2624 (define (python-path dir)
2625 (string-append dir "/lib/python"
2626 ,(version-major+minor
2627 (package-version python))
2629 (let ((out (assoc-ref outputs "out"))
2630 (ndiff (assoc-ref outputs "ndiff")))
2631 (for-each mkdir-p (list out ndiff))
2637 (make ndiff "install-ndiff")
2638 (wrap-program (string-append ndiff "/bin/ndiff")
2639 `("PYTHONPATH" prefix
2640 (,(python-path ndiff)))))
2642 ;; These are the tests that do not require network access.
2644 (lambda _ (invoke "make"
2648 ;; Nmap can't cope with out-of-source building.
2649 #:out-of-source? #f))
2650 (home-page "https://nmap.org/")
2651 (synopsis "Network discovery and security auditing tool")
2653 "Nmap (\"Network Mapper\") is a network discovery and security auditing
2654 tool. It is also useful for tasks such as network inventory, managing service
2655 upgrade schedules, and monitoring host or service uptime. It also provides an
2656 advanced netcat implementation (ncat), a utility for comparing scan
2657 results (ndiff), and a packet generation and response analysis tool (nping).")
2658 ;; This package uses nmap's bundled versions of libdnet and liblinear, which
2659 ;; both use a 3-clause BSD license.
2660 (license (list license:nmap license:bsd-3))))
2662 (define-public dstat
2670 (url "https://github.com/dagwieers/dstat.git")
2671 (commit (string-append "v" version))))
2672 (file-name (git-file-name "dstat" version))
2674 (base32 "1qnmkhqmjd1m3if05jj29dvr5hn6kayq9bkkkh881w472c0zhp8v"))
2675 (patches (search-patches "dstat-fix-crash-when-specifying-delay.patch"
2676 "dstat-skip-devices-without-io.patch"))))
2677 (build-system gnu-build-system)
2679 `(#:tests? #f ; no make check
2680 #:make-flags (let ((out (assoc-ref %outputs "out")))
2681 (list (string-append "DESTDIR=" out)
2684 (modify-phases %standard-phases
2685 (add-after 'unpack 'fix-python3-DeprecationWarning
2687 (substitute* "dstat"
2688 (("collections") "collections.abc"))
2690 (delete 'configure) ; no configure script
2691 (add-after 'install 'wrap
2692 (lambda* (#:key outputs #:allow-other-keys)
2693 (let ((out (assoc-ref outputs "out")))
2694 (wrap-program (string-append out "/bin/dstat")
2695 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
2698 `(("python" ,python-wrapper)
2699 ("python-six" ,python-six)))
2700 (synopsis "Versatile resource statistics tool")
2701 (description "Dstat is a versatile replacement for @command{vmstat},
2702 @command{iostat}, @command{netstat}, and @command{ifstat}. Dstat overcomes
2703 some of their limitations and adds some extra features, more counters and
2704 flexibility. Dstat is handy for monitoring systems during performance tuning
2705 tests, benchmarks or troubleshooting.
2707 Dstat allows you to view all of your system resources in real-time, you can,
2708 e.g., compare disk utilization in combination with interrupts from your IDE
2709 controller, or compare the network bandwidth numbers directly with the disk
2710 throughput (in the same interval).")
2711 (home-page "http://dag.wiee.rs/home-made/dstat/")
2712 (license license:gpl2+)))
2714 (define-public thefuck
2722 (url "https://github.com/nvbn/thefuck.git")
2724 (file-name (git-file-name name version))
2726 (base32 "0fnf78956pwhb9cgv1jmgypnkma5xzflkivfrkfiadbgin848yfg"))
2727 (patches (search-patches "thefuck-test-environ.patch"))))
2728 (build-system python-build-system)
2731 (modify-phases %standard-phases
2733 (add-after 'install 'check
2734 (lambda* (#:key inputs outputs #:allow-other-keys)
2735 ;; Tests look for installed package
2736 (add-installed-pythonpath inputs outputs)
2737 ;; Some tests need write access to $HOME.
2738 (setenv "HOME" "/tmp")
2739 (invoke "py.test" "-v")
2742 `(("python-colorama" ,python-colorama)
2743 ("python-decorator" ,python-decorator)
2744 ("python-psutil" ,python-psutil)
2745 ("python-pyte" ,python-pyte)
2746 ("python-six" ,python-six)))
2749 ("python-mock" ,python-mock)
2750 ("python-pytest" ,python-pytest)
2751 ("python-pytest-mock" ,python-pytest-mock)))
2752 (home-page "https://github.com/nvbn/thefuck")
2753 (synopsis "Correct mistyped console command")
2755 "The Fuck tries to match a rule for a previous, mistyped command, creates
2756 a new command using the matched rule, and runs it.")
2757 (license license:x11)))
2766 (uri (string-append "https://gentoo.com/di/di-" version ".tar.gz"))
2768 (base32 "0crvvfsxh8ryc0j19a2x52i9zacvggm8zi6j3kzygkcwnpz4km8r"))))
2769 (build-system gnu-build-system)
2771 `(#:tests? #f ; obscure test failures
2773 (modify-phases %standard-phases
2774 (delete 'configure) ; no configure script
2775 (add-before 'build 'setup-environment
2776 (lambda* (#:key outputs #:allow-other-keys)
2777 (setenv "CC" ,(cc-for-target))
2778 (setenv "prefix" (assoc-ref outputs "out"))
2780 #:make-flags (list "--environment-overrides")))
2781 (home-page "https://gentoo.com/di/")
2782 (synopsis "Advanced df like disk information utility")
2784 "@code{di} is a disk information utility, displaying everything that your
2785 @code{df} command does and more. It features the ability to display your disk
2786 usage in whatever format you prefer. It is designed to be highly portable and
2787 produce uniform output across heterogeneous networks.")
2788 (license license:zlib)))
2790 (define-public cbatticon
2798 (url "https://github.com/valr/cbatticon.git")
2801 (base32 "0ivm2dzhsa9ir25ry418r2qg2llby9j7a6m3arbvq5c3kaj8m9jr"))
2802 (file-name (git-file-name name version))))
2803 (build-system gnu-build-system)
2805 `(#:tests? #f ; no tests
2807 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2810 (modify-phases %standard-phases
2811 (delete 'configure)))) ; no configure script
2814 ("gettext" ,gettext-minimal)
2815 ("libnotify" ,libnotify)))
2817 `(("pkg-config" ,pkg-config)))
2818 (synopsis "Lightweight battery icon for the system tray")
2819 (description "cbatticon is a lightweight battery icon that displays
2820 the status of your battery in the system tray.")
2821 (home-page "https://github.com/valr/cbatticon")
2822 (license license:gpl2+)))
2824 (define-public interrobang
2825 (let ((revision "1")
2826 (commit "896543735e1c99144765fdbd7b6e6b5afbd8b881"))
2828 (name "interrobang")
2829 (version (git-version "0.0.0" revision commit))
2834 (url "https://github.com/TrilbyWhite/interrobang.git")
2836 (file-name (git-file-name name version))
2838 (base32 "1n13m70p1hfba5dy3i8hfclbr6k9q3d9dai3dg4jvhdhmxcpjzdf"))))
2839 (build-system gnu-build-system)
2841 `(#:tests? #f ; no tests
2843 (modify-phases %standard-phases
2844 (delete 'configure)) ; no configure script
2845 #:make-flags (list (string-append "PREFIX="
2846 (assoc-ref %outputs "out")))))
2848 `(("libx11" ,libx11)))
2850 `(("pkg-config" ,pkg-config)))
2851 (synopsis "Scriptable launcher menu")
2852 (description "Interrobang is a scriptable launcher menu with a customizable
2853 shortcut syntax and completion options.")
2854 (home-page "https://github.com/TrilbyWhite/interrobang")
2855 (license license:gpl3+))))
2857 (define-public pam-krb5
2864 "https://archives.eyrie.org/software/kerberos/"
2865 "pam-krb5-" version ".tar.xz"))
2866 (patches (search-patches "pam-krb5-CVE-2020-10595.patch"))
2869 "1qjp8i1s9bz7g6kiqrkzzkxn5pfspa4sy53b6z40fqmdf9przdfb"))))
2870 (build-system gnu-build-system)
2873 (modify-phases %standard-phases
2874 (add-before 'configure 'disable-tests
2876 ;; The build container seems to interfere with some tests.
2877 (substitute* "tests/TESTS"
2878 (("module/basic\n") ""))
2879 (substitute* "tests/TESTS"
2880 (("pam-util/vector\n") ""))
2883 `(("linux-pam" ,linux-pam)
2884 ("mit-krb5" ,mit-krb5)))
2887 ("perl-test-pod" ,perl-test-pod))) ; required for tests
2888 (synopsis "Kerberos PAM module")
2890 "Pam-krb5 is a Kerberos PAM module for either MIT Kerberos or Heimdal.
2891 It supports ticket refreshing by screen savers, configurable
2892 authorization handling, authentication of non-local accounts for network
2893 services, password changing, and password expiration, as well as all the
2894 standard expected PAM features. It works correctly with OpenSSH, even
2895 with @code{ChallengeResponseAuthentication} and @code{PrivilegeSeparation}
2896 enabled, and supports extensive configuration either by PAM options or in
2897 krb5.conf or both. PKINIT is supported with recent versions of both MIT
2898 Kerberos and Heimdal and FAST is supported with recent MIT Kerberos.")
2899 (home-page "https://www.eyrie.org/~eagle/software/pam-krb5")
2900 ;; Dual licenced under a homebrew non-copyleft OR GPL (any version)
2901 ;; However, the tarball does not contain a copy of the GPL, so unless
2902 ;; we put one in, we cannot distribute it under GPL without violating
2903 ;; clause requiring us to give all recipients a copy.
2904 (license license:gpl1+)))
2906 (define (sunxi-tools-source version)
2910 (url "https://github.com/linux-sunxi/sunxi-tools.git")
2911 (commit (string-append "v" version))))
2913 (base32 "04f3jqg8ww4jxsf9c6ddcdgy2xbhkyp0b3l5f1hvvbv94p81rjxd"))
2914 (modules '((guix build utils)))
2916 ;; Remove binaries contained in the tarball which are only for the
2917 ;; target and can be regenerated anyway.
2919 (delete-file-recursively "bin")
2921 (file-name (git-file-name "sunxi-tools" version))))
2923 (define sunxi-target-tools
2925 (name "sunxi-target-tools")
2927 (build-system gnu-build-system)
2929 (sunxi-tools-source version))
2931 `(#:system "armhf-linux"
2933 #:make-flags (list (string-append "PREFIX="
2934 (assoc-ref %outputs "out"))
2935 (string-append "CROSS_COMPILE=")
2938 (modify-phases %standard-phases
2941 (lambda* (#:key make-flags #:allow-other-keys)
2942 (apply invoke "make" "target-tools" make-flags)))
2944 (lambda* (#:key make-flags #:allow-other-keys)
2945 (apply invoke "make" "install-target-tools"
2947 (home-page "https://github.com/linux-sunxi/sunxi-tools")
2948 (synopsis "Hardware management tools for Allwinner computers")
2949 (description "This package contains tools for Allwinner devices:
2951 @item @command{sunxi-meminfo}: Prints memory bus settings.
2953 (license license:gpl2+)))
2955 (define-public sunxi-tools
2957 (name "sunxi-tools")
2960 (sunxi-tools-source version))
2962 `(("sunxi-target-tools" ,sunxi-target-tools)
2963 ("pkg-config" ,pkg-config)))
2965 `(("libusb" ,libusb)))
2966 (build-system gnu-build-system)
2968 `(#:tests? #f ; no tests exist
2969 #:make-flags (list (string-append "PREFIX="
2970 (assoc-ref %outputs "out"))
2971 (string-append "CROSS_COMPILE=disabled")
2974 (modify-phases %standard-phases
2977 (lambda* (#:key make-flags #:allow-other-keys)
2978 (apply invoke "make" "tools" "misc" make-flags)))
2980 (lambda* (#:key inputs outputs make-flags #:allow-other-keys)
2981 ;; Those tools have been built for armhf but are part of the
2982 ;; installation in the upstream package. So do the same
2984 (copy-recursively (assoc-ref inputs "sunxi-target-tools")
2985 (assoc-ref outputs "out"))
2986 (apply invoke "make" "install-tools" "install-misc"
2988 (home-page "https://github.com/linux-sunxi/sunxi-tools")
2989 (synopsis "Hardware management tools for Allwinner computers")
2990 (description "This package contains tools for Allwinner devices:
2992 @item @command{sunxi-fexc}, @command{bin2fex}, @command{fex2bin}: Compile
2993 a textual description of a board (.fex) to a binary representation (.bin).
2994 @item @command{sunxi-fel}: Puts an Allwinner device into FEL mode which
2995 makes it register as a special USB device (rather than USB host).
2996 You can then connect it to another computer and flash it from there.
2997 @item @command{sunxi-nand-part}: Partitions NAND flash.
2998 @item @command{sunxi-bootinfo}: Reads out boot0 and boot1 (Allwinner
2999 bootloader) parameters.
3000 @item @command{sunxi-pio}: Sets GPIO parameters and oscillates a GPIO
3001 in order to be able to find it.
3002 @item @command{sunxi-meminfo}: Prints memory bus settings.
3003 @item @command{sunxi-nand-image-builder}: Prepares raw NAND images.
3005 (license license:gpl2+)))
3007 (define-public sedsed
3015 (url "https://github.com/aureliojargas/sedsed.git")
3016 (commit (string-append "v" version))))
3017 (file-name (git-file-name name version))
3019 (base32 "05cl35mwljdb9ynbbsfa8zx6ig8r0xncbg2cir9vwn5manndjj18"))))
3020 (build-system python-build-system)
3022 `(#:tests? #f ; no tests
3024 (modify-phases %standard-phases
3025 (add-after 'unpack 'patch-sed-in
3027 (substitute* "sedsed.py"
3029 (string-append "sedbin = '" (which "sed") "'")))
3033 (lambda* (#:key outputs #:allow-other-keys)
3034 (let* ((out (assoc-ref outputs "out"))
3035 (bin (string-append out "/bin")))
3036 ;; Just one file to copy around
3037 (install-file "sedsed.py" bin)
3039 (add-after 'wrap 'symlink
3040 ;; Create 'sedsed' symlink to "sedsed.py".
3041 (lambda* (#:key outputs #:allow-other-keys)
3042 (let* ((out (assoc-ref outputs "out"))
3043 (bin (string-append out "/bin"))
3044 (sed (string-append bin "/sedsed"))
3045 (sedpy (string-append bin "/sedsed.py")))
3048 (home-page "https://aurelio.net/projects/sedsed")
3049 (synopsis "Sed sed scripts")
3051 "@code{sedsed} can debug, indent, tokenize and HTMLize your @command{sed}
3054 In debug mode, it reads your script and adds extra commands to it. When
3055 executed you can see the data flow between the commands, revealing all the
3056 magic sed performs on its internal buffers.
3058 In indent mode, your script is reformatted with standard spacing.
3060 In tokenize mode, you can see the elements of every command you use.
3062 In HTMLize mode, your script is converted to a beautiful colored HTML file,
3063 with all the commands and parameters identified for your viewing pleasure.
3065 With sedsed you can master any sed script. No more secrets, no more hidden
3067 (license license:expat)))
3069 (define-public igt-gpu-tools
3071 (name "igt-gpu-tools")
3077 (url "https://gitlab.freedesktop.org/drm/igt-gpu-tools.git")
3078 (commit (string-append "igt-gpu-tools-" version))))
3079 (file-name (git-file-name name version))
3081 (base32 "1gpdjs5aj6vsnzwcjvw5bb120lgffvvshi4202phr0bzw3b92ky8"))))
3082 (build-system gnu-build-system)
3084 `(#:tests? #f)) ; many of the tests try to load kernel modules
3087 ("elfutils" ,elfutils) ; libdw
3092 ("libpciaccess" ,libpciaccess)
3093 ("libunwind" ,libunwind)
3094 ("libxrandr" ,libxrandr)
3095 ("openssl" ,openssl)
3097 ("util-macros" ,util-macros)))
3099 `(("autoconf" ,autoconf)
3100 ("automake" ,automake)
3101 ("libtool" ,libtool)
3102 ("pkg-config" ,pkg-config)))
3103 (home-page "https://gitlab.freedesktop.org/drm/igt-gpu-tools")
3104 (synopsis "Tools for development and testing of the Intel DRM driver")
3105 (description "IGT GPU Tools is a collection of tools for development and
3106 testing of the Intel DRM driver. There are many macro-level test suites that
3107 get used against the driver, including xtest, rendercheck, piglit, and
3108 oglconform, but failures from those can be difficult to track down to kernel
3109 changes, and many require complicated build procedures or specific testing
3110 environments to get useful results. Therefore, IGT GPU Tools includes
3111 low-level tools and tests specifically for development and testing of the
3113 (supported-systems '("i686-linux" "x86_64-linux"))
3114 (license license:expat)))
3116 (define-public fabric
3123 (uri (pypi-uri "Fabric" version))
3126 "1a3ndlpdw6bhn8fcw1jgznl117a8pnr84az9rb5fwnrypf1ph2b6"))))
3127 (build-system python-build-system)
3129 `(#:python ,python-2 ; Python 2 only
3131 (modify-phases %standard-phases
3135 "nosetests" "-v" "tests/"
3136 ;; This test hangs indefinitely when run on a single core VM
3137 ;; (see GNU bug #26647 and Debian bug #850230).
3138 "--exclude=test_nested_execution_with_explicit_ports"
3139 ;; This test randomly fails in certain environments causing too
3140 ;; much noise to be useful (see Debian bug #854686).
3141 "--exclude=test_should_use_sentinel_for_tasks_that_errored"))))))
3143 `(("python2-fudge" ,python2-fudge) ; Requires < 1.0
3144 ("python2-jinja2" ,python2-jinja2) ; Requires < 3.0
3145 ("python2-nose" ,python2-nose) ; Requires < 2.0
3146 ("python2-pynacl" ,python2-pynacl)
3147 ("python2-bcrypt" ,python2-bcrypt)))
3149 `(("python2-paramiko" ,python2-paramiko)))
3150 (home-page "https://www.fabfile.org/")
3151 (synopsis "Simple Pythonic remote execution and deployment tool")
3153 "Fabric is designed to upload files and run shell commands on a number of
3154 servers in parallel or serially. These commands are grouped in tasks (which
3155 are regular Python functions) and specified in a @dfn{fabfile}.
3157 It is similar to Capistrano, except it's implemented in Python and doesn't
3158 expect you to be deploying Rails applications. Fabric is a simple, Pythonic
3159 tool for remote execution and deployment.")
3160 (license license:bsd-2)))
3162 (define-public neofetch
3169 (url "https://github.com/dylanaraps/neofetch")
3171 (file-name (git-file-name name version))
3174 "0xc0fdc7n5bhqirh83agqiy8r14l14zwca07czvj8vgnsnfybslr"))))
3175 (build-system gnu-build-system)
3177 `(#:tests? #f ; there are no tests
3179 (list (string-append "PREFIX=" %output))
3181 (modify-phases %standard-phases
3182 (delete 'configure)))) ; no configure script
3183 (home-page "https://github.com/dylanaraps/neofetch")
3184 (synopsis "System information script")
3185 (description "Neofetch is a command-line system information tool written in
3186 Bash. Neofetch displays information about your system next to an image, your OS
3187 logo, or any ASCII file of your choice. The main purpose of Neofetch is to be
3188 used in screenshots to show other users what operating system or distribution
3189 you are running, what theme or icon set you are using, etc.")
3190 (license license:expat)))
3192 (define-public screenfetch
3194 (name "screenfetch")
3199 (url "https://github.com/KittyKatt/screenFetch")
3200 (commit (string-append "v" version))))
3201 (file-name (git-file-name name version))
3204 "04l8aqr474pb115nagn9f6y48jw92n1qfszgw7dbhgl4mpn95lcr"))))
3205 (build-system trivial-build-system)
3207 `(#:modules ((guix build utils))
3210 (use-modules (guix build utils))
3211 (let ((source (assoc-ref %build-inputs "source"))
3212 (out (assoc-ref %outputs "out")))
3213 (mkdir-p (string-append out "/bin/"))
3214 (copy-file (string-append source "/screenfetch-dev")
3215 (string-append out "/bin/screenfetch"))
3216 (install-file (string-append source "/screenfetch.1")
3217 (string-append out "/man/man1/"))
3218 (install-file (string-append source "/COPYING")
3219 (string-append out "/share/doc/" ,name "-" ,version))
3220 (substitute* (string-append out "/bin/screenfetch")
3221 (("/usr/bin/env bash")
3222 (string-append (assoc-ref %build-inputs "bash")
3225 (string-append out "/bin/screenfetch")
3227 (,(string-append (assoc-ref %build-inputs "bc") "/bin:"
3228 (assoc-ref %build-inputs "scrot") "/bin:"
3229 (assoc-ref %build-inputs "xdpyinfo") "/bin"
3230 (assoc-ref %build-inputs "xprop") "/bin"))))
3231 (substitute* (string-append out "/bin/screenfetch")
3233 (string-append "#!" (assoc-ref %build-inputs "bash")
3239 ("xdpyinfo" ,xdpyinfo)
3241 (home-page "https://github.com/KittyKatt/screenFetch")
3242 (synopsis "System information script")
3243 (description "Bash screenshot information tool which can be used to
3244 generate those nifty terminal theme information and ASCII distribution logos in
3245 everyone's screenshots nowadays.")
3246 (license license:gpl3)))
3255 (uri (string-append "https://github.com/jarun/nnn/releases/download/v"
3256 version "/nnn-v" version ".tar.gz"))
3258 (base32 "1zflz7yj5wzdnl0728g8qrld2z6dqn7sblbmkjvyqlv1fwjd1fsf"))))
3259 (build-system gnu-build-system)
3261 `(("ncurses" ,ncurses)
3262 ("readline" ,readline)))
3264 `(("pkg-config" ,pkg-config)))
3266 '(#:tests? #f ; no tests
3268 (modify-phases %standard-phases
3269 (delete 'configure)) ; no configure script
3272 (string-append "PREFIX="
3273 (assoc-ref %outputs "out"))
3275 (home-page "https://github.com/jarun/nnn")
3276 (synopsis "Terminal file browser")
3277 (description "@command{nnn} is a fork of @command{noice}, a blazing-fast
3278 lightweight terminal file browser with easy keyboard shortcuts for
3279 navigation, opening files and running tasks. There is no config file and
3280 mime associations are hard-coded. The incredible user-friendliness and speed
3281 make it a perfect utility on modern distros.")
3282 (license license:bsd-2)))
3284 (define-public thermald
3292 (url "https://github.com/01org/thermal_daemon")
3293 (commit (string-append "v" version))))
3294 (file-name (git-file-name name version))
3296 (base32 "0iagc3jqpnh6q2fa1gx4wx6r8qg0556j60xr159zqg95djr4dv99"))))
3297 (build-system gnu-build-system)
3300 (let ((out (assoc-ref %outputs "out")))
3301 (list (string-append "--sysconfdir="
3303 (string-append "--with-dbus-sys-dir="
3304 out "/etc/dbus-1/system.d")
3305 "--localstatedir=/var"))))
3307 `(("autoconf" ,autoconf)
3308 ("automake" ,automake)
3309 ("glib" ,glib "bin") ; for glib-genmarshal, etc.
3310 ("pkg-config" ,pkg-config)))
3312 `(("dbus-glib" ,dbus-glib)
3313 ("libxml2" ,libxml2)))
3314 (home-page "https://01.org/linux-thermal-daemon/")
3315 (synopsis "CPU scaling for thermal management")
3316 (description "The Linux Thermal Daemon helps monitor and control temperature
3317 on systems running the Linux kernel.")
3318 ;; arm and aarch64 don't have cpuid.h.
3319 (supported-systems '("i686-linux" "x86_64-linux"))
3320 (license license:gpl2+)))
3322 (define-public masscan
3330 (url "https://github.com/robertdavidgraham/masscan.git")
3332 (file-name (git-file-name name version))
3334 (base32 "0q0c7bsf0pbl8napry1qyg0gl4pd8wn872h4mz9b56dx4rx90vqg"))))
3335 (build-system gnu-build-system)
3337 `(("libpcap" ,libpcap)))
3339 '(#:test-target "regress"
3342 (string-append "PREFIX=" (assoc-ref %outputs "out")))
3344 (modify-phases %standard-phases
3345 (delete 'configure) ; no ./configure script
3346 (add-after 'unpack 'patch-path
3347 (lambda* (#:key outputs inputs #:allow-other-keys)
3348 (let* ((out (assoc-ref outputs "out"))
3349 (pcap (assoc-ref inputs "libpcap")))
3350 (substitute* "src/rawsock-pcap.c"
3351 (("libpcap.so") (string-append pcap "/lib/libpcap.so")))
3353 (synopsis "TCP port scanner")
3354 (description "MASSCAN is an asynchronous TCP port scanner. It can detect
3355 open ports, and also complete the TCP connection and interact with the remote
3356 application, collecting the information received.")
3357 (home-page "https://github.com/robertdavidgraham/masscan")
3358 ;; 'src/siphash24.c' is the SipHash reference implementation, which
3359 ;; bears a CC0 Public Domain Dedication.
3360 (license license:agpl3+)))
3362 (define-public hungrycat
3368 (uri (string-append "https://github.com/jwilk/hungrycat/"
3369 "releases/download/" version "/"
3370 "hungrycat-" version ".tar.gz"))
3373 "03fc1zsrf99lvxa7b4ps6pbi43304wbxh1f6ci4q0vkal370yfwh"))))
3374 (build-system gnu-build-system)
3377 `(("python" ,python-wrapper)
3378 ("python-nose" ,python-nose)))
3380 `(#:test-target "test"))
3381 (synopsis "A single tool that combines @command{cat} & @command{rm}")
3383 "hungrycat prints the contents of a file to standard output, while
3384 simultaneously freeing the disk space it occupied. It is useful if you need
3385 to process a large file, don't have enough space to store both the input and
3386 output files, and don't need the input file afterwards.
3387 While similar in principle to running @command{cat} immediately followed by
3388 @command{rm}, @command{hungrycat} actually frees blocks as soon as they are
3389 printed instead of after the entire file has been read, which is often too
3391 (home-page "https://jwilk.net/software/hungrycat")
3392 (license license:expat)))
3394 (define-public launchmon
3401 "https://github.com/LLNL/LaunchMON/releases/download/v"
3402 version "/launchmon-v" version ".tar.gz"))
3405 "0fm3nd9mydm9v2bf7bh01dbgrfnpwkapxa3dsvy3x1z0rz61qc0x"))
3406 (modules '((guix build utils)))
3409 ;; Fix build failure with GCC 7 due to a conversion error.
3410 ;; Remove for versions > 1.0.2.
3411 (substitute* "launchmon/src/linux/lmon_api/lmon_coloc_spawner.cxx"
3412 ((" lmonpl = '\\\\0'")
3413 " *lmonpl = '\\0'"))
3415 (build-system gnu-build-system)
3421 ("libgcrypt" ,libgcrypt)
3422 ("libgpg-error" ,libgpg-error)))
3423 (synopsis "Infrastructue for large scale tool daemon launching")
3425 "LaunchMON is a software infrastructure that enables HPC run-time
3426 tools to co-locate tool daemons with a parallel job. Its API allows a
3427 tool to identify all the remote processes of a job and to scalably
3428 launch daemons into the relevant nodes.")
3429 (home-page "https://github.com/LLNL/LaunchMON")
3430 (supported-systems '("i686-linux" "x86_64-linux"))
3431 (license license:lgpl2.1)))
3433 (define-public spindle
3438 ;; We use git checkout to avoid github auto-generated tarballs
3441 (url "https://github.com/hpc/Spindle.git")
3442 (commit (string-append "v" version))))
3443 (file-name (git-file-name name version))
3446 "15n3ay0qq81r5v7fif61q1vdjcq44pp2nynkh3fvbzc9fj3c39wd"))))
3447 (build-system gnu-build-system)
3448 (arguments '(#:configure-flags '("--enable-sec-launchmon"
3449 "--enable-sec-munge"
3450 "--enable-sec-none")))
3454 ("launchmon" ,launchmon)
3455 ("libgcrypt" ,libgcrypt)))
3456 (synopsis "Scalable library loading in HPC environments")
3458 "Spindle is a tool for improving the performance of dynamic library and
3459 Python loading in HPC environments.")
3460 (home-page "https://github.com/hpc/Spindle")
3461 ;; This package supports x86_64 and PowerPC64
3462 (supported-systems '("x86_64-linux"))
3463 (license license:lgpl2.1)))
3465 (define-public inxi-minimal
3466 (let ((real-name "inxi"))
3468 (name "inxi-minimal")
3469 (version "3.1.01-1")
3474 (url "https://github.com/smxi/inxi")
3476 (file-name (git-file-name real-name version))
3478 (base32 "0r204w0r06ibdr4dck7yw2nmvj7xq68bjr7xwwiy7liqdml0n0yc"))))
3479 (build-system trivial-build-system)
3481 `(("bash" ,bash-minimal)
3483 ("procps" ,procps)))
3493 (use-modules (guix build utils)
3496 (setenv "PATH" (string-append
3497 (assoc-ref %build-inputs "bash") "/bin" ":"
3498 (assoc-ref %build-inputs "gzip") "/bin" ":"
3499 (assoc-ref %build-inputs "perl") "/bin" ":"))
3500 (copy-recursively (assoc-ref %build-inputs "source")
3501 ,(string-append real-name "-" version))
3502 (with-directory-excursion ,(string-append real-name "-" version)
3503 (with-fluids ((%default-port-encoding #f))
3504 (substitute* "inxi" (("/usr/bin/env perl") (which "perl"))))
3505 (let ((bin (string-append %output "/bin")))
3506 (install-file "inxi" bin)
3507 (wrap-program (string-append bin "/inxi")
3510 ,@(map (lambda (input)
3514 (cut string-append store <>)))
3516 ((member name '("util-linux"))
3517 (string-append (store-append "/bin") ":"
3518 (store-append "/sbin")))
3519 ((member name '("dmidecode" "iproute2"))
3520 (store-append "/sbin"))
3521 (else (store-append "/bin")))))))
3527 (((? (cut string-prefix? "perl-" <>) name) . dir)
3528 (string-append dir "/lib/perl5/site_perl"))
3531 (invoke "gzip" "inxi.1")
3532 (install-file "inxi.1.gz"
3533 (string-append %output "/share/man/man1")))
3535 (home-page "https://smxi.org/docs/inxi.htm")
3536 (synopsis "Full-featured system information script")
3537 (description "Inxi is a system information script that can display
3538 various things about your hardware and software to users in an IRC chatroom or
3539 support forum. It runs with the @code{/exec} command in most IRC clients.")
3540 (license license:gpl3+))))
3544 (inherit inxi-minimal)
3547 `(("dmidecode" ,dmidecode)
3549 ("bind:utils" ,isc-bind "utils") ; dig
3551 ("iproute2" ,iproute) ; ip
3552 ("kmod" ,kmod) ; modinfo
3553 ("lm-sensors" ,lm-sensors)
3554 ("mesa-utils" ,mesa-utils)
3555 ("pciutils" ,pciutils)
3558 ("util-linux" ,util-linux) ; lsblk
3559 ("usbutils" ,usbutils) ; lsusb
3561 ("xdpyinfo" ,xdpyinfo)
3564 ("coreutils" ,coreutils) ; uptime
3565 ("inetutils" ,inetutils) ; ifconfig
3566 ("perl-cpanel-json-xs" ,perl-cpanel-json-xs)
3567 ("perl-http-tiny" ,perl-http-tiny)
3568 ("perl-io-socket-ssl" ,perl-io-socket-ssl)
3569 ("perl-json-xs" ,perl-json-xs)
3570 ("perl-time-hires" ,perl-time-hires)
3571 ;; TODO: Add more inputs:
3576 ,@(package-inputs inxi-minimal)))))
3578 (define-public pscircle
3586 (url "https://gitlab.com/mildlyparallel/pscircle.git")
3587 (commit (string-append "v" version))))
3588 (file-name (git-file-name name version))
3590 (base32 "1sm99423hh90kr4wdjqi9sdrrpk65j2vz2hzj65zcxfxyr6khjci"))))
3591 (build-system meson-build-system)
3593 `(("pkg-config" ,pkg-config)))
3597 ("libx11" ,libx11)))
3598 (home-page "https://gitlab.com/mildlyparallel/pscircle")
3599 (synopsis "Visualize Linux processes in a form of radial tree")
3601 "@code{pscircle} visualizes Linux processes in the form of a radial tree.")
3602 (license license:gpl2+)))
3604 (define-public python-pyudev
3606 (name "python-pyudev")
3611 (uri (pypi-uri "pyudev" version))
3614 "0xmj6l08iih2js9skjqpv4w7y0dhxyg91zmrs6v5aa65gbmipfv9"))))
3615 (build-system python-build-system)
3617 `(#:tests? #f ; Tests require /sys
3619 (modify-phases %standard-phases
3620 (add-after 'unpack 'patch-ctypes-udev
3621 (lambda* (#:key inputs outputs #:allow-other-keys)
3622 (let ((eudev (assoc-ref inputs "eudev")))
3623 (substitute* "src/pyudev/core.py"
3625 (string-append "'" eudev "/lib/libudev.so'")))
3626 (substitute* "src/pyudev/_ctypeslib/utils.py"
3627 ;; Use absolute paths instead of keys.
3628 (("= find_library") "= "))
3631 `(("eudev" ,eudev)))
3633 `(("python-six" ,python-six)))
3635 `(("python-docutils" ,python-docutils)
3636 ("python-hypothesis" ,python-hypothesis)
3637 ("python-mock" ,python-mock)
3638 ("python-pytest" ,python-pytest)
3639 ("python-sphinx" ,python-sphinx)))
3640 (home-page "https://pyudev.readthedocs.io/")
3641 (synopsis "Python udev binding")
3642 (description "This package provides @code{udev} bindings for Python.")
3643 (license license:lgpl2.1)))
3645 (define-public solaar
3652 (url "https://github.com/pwr/Solaar.git")
3654 (file-name (git-file-name name version))
3657 "085mfa13dap3wqik1dqlad0d7kff4rv7j4ljh99c7l8nhczkqgwm"))))
3658 (build-system python-build-system)
3661 (modify-phases %standard-phases
3662 (add-after 'unpack 'fix-prefix-detection
3664 (substitute* "setup.py"
3665 (("'--prefix' in sys\\.argv")
3666 "len([x.startswith('--prefix=') for x in sys.argv]) > 0"))
3670 (invoke "python" "setup.py" "build")))
3671 (add-before 'check 'setenv-PATH
3673 (setenv "PYTHONPATH" (string-append "lib:" (getenv "PYTHONPATH")))
3676 `(("python-pygobject" ,python-pygobject)
3677 ("python-pyudev" ,python-pyudev)))
3678 (home-page "https://smxi.org/docs/inxi.htm")
3679 (synopsis "Linux devices manager for the Logitech Unifying Receiver")
3680 (description "This package provides tools to manage clients of the
3681 Logitech Unifying Receiver.")
3682 (license license:gpl2)))
3684 (define-public lynis
3687 ;; Also update the ‘lynis-sdk’ input to the commit matching this release.
3693 (url "https://github.com/CISOfy/lynis")
3695 (file-name (git-file-name name version))
3697 (base32 "1lkkbvxm0rgrrlx0szaxmf8ghc3d26wal96sgqk84m37mvs1f7p0"))
3698 (modules '((guix build utils)))
3701 ;; Remove proprietary plugins. As of now, all plugins supplied with
3702 ;; lynis are proprietary. In the future, if free plugins are
3703 ;; provided, whitelist them from deletion.
3704 (for-each delete-file (find-files "plugins"))
3706 (build-system gnu-build-system)
3713 (url "https://github.com/CISOfy/lynis-sdk")
3714 (commit "bf1c1d95121da9ca79a9eac5a15ed8d81e34094d")))
3715 (file-name (git-file-name "lynis-sdk" version))
3717 (base32 "1ndz5v0039dqa87cva2dk55a8hkw0fibsw8hh2ddmny9qkr4l3dp"))))))
3720 (modify-phases %standard-phases
3722 (lambda* (#:key inputs outputs #:allow-other-keys)
3723 (substitute* "lynis"
3724 (("/usr/share/lynis")
3725 (string-append (assoc-ref outputs "out") "/share/lynis")))
3726 (substitute* "include/functions"
3727 (("/usr/local/etc/lynis")
3728 (string-append (assoc-ref outputs "out") "/etc/lynis")))
3732 (lambda* (#:key outputs #:allow-other-keys)
3733 (let ((out (assoc-ref outputs "out")))
3734 (install-file "lynis" (string-append out "/bin/"))
3735 (install-file "default.prf" (string-append out "/etc/lynis"))
3738 (copy-recursively dir (string-append out "/share/lynis/" dir)))
3739 (list "db" "include" "plugins"))
3740 (install-file "lynis.8" (string-append out "/share/man/man8"))
3743 (lambda* (#:key inputs #:allow-other-keys)
3744 (copy-recursively (assoc-ref inputs "lynis-sdk") "../lynis-sdk")
3745 (setenv "LANG" "en_US.UTF-8")
3746 (let ((lynis-dir (getcwd)))
3747 (with-directory-excursion "../lynis-sdk"
3748 (substitute* "config"
3749 (("\\.\\./lynis") lynis-dir))
3750 (substitute* "unit-tests/tests-language-translations.sh"
3751 (("\\.\\./lynis") lynis-dir))
3752 (invoke "sh" "lynis-devkit" "run" "unit-tests"))))))))
3753 (home-page "https://cisofy.com/lynis/")
3754 (synopsis "Security auditing tool")
3755 (description "Lynis is a security auditing tool. It performs an in-depth
3756 security scan and runs on the system itself. The primary goal is to test
3757 security defenses and provide tips for further system hardening. It will also
3758 scan for general system information, vulnerable software packages, and
3759 possible configuration issues.")
3760 (license license:gpl3+)))
3762 (define-public ngrep
3770 (url "https://github.com/jpr5/ngrep/")
3771 (commit (string-append "V" (string-replace-substring version "." "_")))))
3772 (file-name (git-file-name name version))
3775 "1x2fyd7wdqlj1r76ilal06cl2wmbz0ws6i3ys204sbjh1cj6dcl7"))))
3776 (build-system gnu-build-system)
3778 `(("libpcap" ,libpcap)))
3780 `(#:tests? #f ;; No tests.
3781 #:configure-flags (list (string-append "--with-pcap-includes="
3782 (assoc-ref %build-inputs "libpcap")
3784 (home-page "https://github.com/jpr5/ngrep/")
3785 (synopsis "Grep-like utility to search for network packets on an interface")
3786 (description "@command{ngrep} is like GNU grep applied to the network
3787 layer. It's a PCAP-based tool that allows you to specify an extended regular
3788 or hexadecimal expression to match against data payloads of packets. It
3789 understands many kinds of protocols, including IPv4/6, TCP, UDP, ICMPv4/6,
3790 IGMP and Raw, across a wide variety of interface types, and understands BPF
3791 filter logic in the same fashion as more common packet sniffing tools, such as
3792 tcpdump and snoop.")
3793 (license license:bsd-3)))
3795 (define-public pam-mount
3802 (uri (string-append "mirror://sourceforge/pam-mount/pam_mount/"
3803 version "/pam_mount-" version ".tar.xz"))
3806 "1rvi4irb7ylsbhvx1cr6islm2xxw1a4b19q6z4a9864ndkm0f0mf"))
3808 ;; Patch adding support for encrypted volumes in LUKS2 format.
3809 ;; It comes from the Gentoo package definition for sys-auth/pam_mount.
3810 (search-patches "pam-mount-luks2-support.patch"))))
3811 (build-system gnu-build-system)
3814 ("pkg-config" ,pkg-config)))
3816 `(("cryptsetup" ,cryptsetup)
3818 ("libxml2" ,libxml2)
3819 ("linux-pam" ,linux-pam)
3821 ("openssl" ,openssl)
3823 ("libmount" ,util-linux "lib")
3824 ("util-linux" ,util-linux)))
3827 (list (string-append "--with-slibdir=" %output "/lib")
3828 (string-append "--with-ssbindir=" %output "/sbin"))
3830 (modify-phases %standard-phases
3831 (add-after 'unpack 'fix-program-paths
3832 (lambda* (#:key inputs outputs #:allow-other-keys)
3833 (let ((util-linux (assoc-ref inputs "util-linux"))
3834 (out (assoc-ref outputs "out")))
3835 (substitute* "src/mtcrypt.c"
3837 (string-append "\"" util-linux "/bin/mount\";"))
3839 (string-append "\"" util-linux "/bin/umount\";"))
3841 (string-append "\"" util-linux "/sbin/fsck\",")))
3842 (substitute* "src/rdconf1.c"
3844 (string-append "\"" util-linux "/bin/mount\", \""))
3846 (string-append "\"" util-linux "/bin/umount\", \""))
3848 (string-append "\"" util-linux "/sbin/fsck\", \""))
3849 (("\"pmvarrun\", \"")
3850 (string-append "\"" out "/sbin/pmvarrun\", \""))))
3852 (home-page "http://pam-mount.sourceforge.net")
3853 (synopsis "PAM module to mount volumes for a user session")
3855 "Pam-mount is a PAM module that can mount volumes when a user logs in.
3856 It supports mounting local filesystems of any kind the normal mount utility
3857 supports. It can also mount encrypted LUKS volumes using the password
3858 supplied by the user when logging in.")
3859 (license (list license:gpl2+ license:lgpl2.1+))))