gnu: pies: Update home page URI.
[jackhill/guix/guix.git] / gnu / packages / admin.scm
CommitLineData
233e7676 1;;; GNU Guix --- Functional package management for GNU
139a9887 2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
340c7033 3;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
f7780fdf 4;;; Copyright © 2014, 2015, 2016, 2018, 2019 Mark H Weaver <mhw@netris.org>
2468ca04 5;;; Copyright © 2014, 2015, 2016, 2017, 2018 Eric Bavier <bavier@member.fsf.org>
d0457553 6;;; Copyright © 2015, 2016 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
15926aec 7;;; Copyright © 2015 Alex Sassmannshausen <alex.sassmannshausen@gmail.com>
8d801045 8;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
d7c64ad5 9;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
f1957fc1 10;;; Copyright © 2016 Pjotr Prins <pjotr.guix@thebird.nl>
d10fa5c7 11;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
a49bbaa6 12;;; Copyright © 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
1a0346f0 13;;; Copyright © 2016 Peter Feigl <peter.feigl@nexoid.at>
61402398 14;;; Copyright © 2016 John J. Foerch <jjfoerch@earthlink.net>
47956fa0 15;;; Copyright © 2016, 2017 ng0 <ng0@n0.is>
54b87d69 16;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
1b5b24c9
BS
17;;; Copyright © 2016 John Darrington <jmd@gnu.org>
18;;; Copyright © 2017 Ben Sturmfels <ben@sturm.com.au>
6e75ea48 19;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
58989684 20;;; Copyright © 2017 Christopher Allan Webber <cwebber@dustycloud.org>
050e5756 21;;; Copyright © 2017, 2018 Marius Bakke <mbakke@fastmail.com>
ba8551ec 22;;; Copyright © 2018, 2019 Arun Isaac <arunisaac@systemreboot.net>
3ebf2c29 23;;; Copyright © 2018 Pierre-Antoine Rouby <pierre-antoine.rouby@inria.fr>
abde01f2 24;;; Copyright © 2018 Rutger Helling <rhelling@mykolab.com>
ce3fef9f 25;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
4b3ff362 26;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
a20ede32 27;;; Copyright © 2019,2020 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
e8134442 28;;; Copyright © 2019 Jakob L. Kreuze <zerodaysfordays@sdf.org>
6eb1d20b 29;;; Copyright © 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
37760623 30;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
cd2ce8ab 31;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
445013b6 32;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
73656471 33;;; Copyright © 2020 Oleg Pykhalov <go.wigust@gmail.com>
1df895b0 34;;;
233e7676 35;;; This file is part of GNU Guix.
1df895b0 36;;;
233e7676 37;;; GNU Guix is free software; you can redistribute it and/or modify it
1df895b0
LC
38;;; under the terms of the GNU General Public License as published by
39;;; the Free Software Foundation; either version 3 of the License, or (at
40;;; your option) any later version.
41;;;
233e7676 42;;; GNU Guix is distributed in the hope that it will be useful, but
1df895b0
LC
43;;; WITHOUT ANY WARRANTY; without even the implied warranty of
44;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
45;;; GNU General Public License for more details.
46;;;
47;;; You should have received a copy of the GNU General Public License
233e7676 48;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
1df895b0 49
4aeea896 50(define-module (gnu packages admin)
f61e0e79 51 #:use-module ((guix licenses) #:prefix license:)
1df895b0 52 #:use-module (guix packages)
4fb7e0de 53 #:use-module (guix utils)
1df895b0 54 #:use-module (guix download)
aaff68ee 55 #:use-module (guix git-download)
fbc1a58f 56 #:use-module (guix build-system cmake)
2b6164f0 57 #:use-module (guix build-system emacs)
1df895b0 58 #:use-module (guix build-system gnu)
b19f3337 59 #:use-module (guix build-system meson)
d1ce1125 60 #:use-module (guix build-system perl)
4ecfbda7 61 #:use-module (guix build-system python)
c773aba8 62 #:use-module (guix build-system trivial)
59a43334 63 #:use-module (gnu packages)
67648704 64 #:use-module (gnu packages algebra)
c73d4c92 65 #:use-module (gnu packages base)
bbc94ed0 66 #:use-module (gnu packages bash)
cd2ce8ab 67 #:use-module (gnu packages c)
ac257f12 68 #:use-module (gnu packages check)
6eb1d20b 69 #:use-module (gnu packages crypto)
cd2ce8ab 70 #:use-module (gnu packages cryptsetup)
3d7a157c 71 #:use-module (gnu packages cyrus-sasl)
bbc94ed0
PN
72 #:use-module (gnu packages dns)
73 #:use-module (gnu packages file)
9a9e72d5 74 #:use-module (gnu packages ncurses)
9927622f 75 #:use-module (gnu packages readline)
37760623 76 #:use-module (gnu packages libbsd)
f15164e7 77 #:use-module (gnu packages linux)
d0457553 78 #:use-module (gnu packages lua)
f15164e7 79 #:use-module (gnu packages guile)
1dba6407 80 #:use-module (gnu packages gettext)
050e5756
MB
81 #:use-module (gnu packages imagemagick)
82 #:use-module (gnu packages inkscape)
d0457553 83 #:use-module (gnu packages pcre)
c73d4c92 84 #:use-module (gnu packages perl)
5ccde207 85 #:use-module (gnu packages perl-check)
87216303 86 #:use-module (gnu packages tcl)
f61e0e79 87 #:use-module (gnu packages compression)
faa6bdf8 88 #:use-module (gnu packages cross-base)
a7fd7b68 89 #:use-module (gnu packages tls)
61bdd0d8 90 #:use-module (gnu packages gnupg)
02c86a5e
LC
91 #:use-module (gnu packages bison)
92 #:use-module (gnu packages flex)
bbc94ed0 93 #:use-module (gnu packages gl)
02c86a5e 94 #:use-module (gnu packages glib)
3d7a157c 95 #:use-module (gnu packages openldap)
c1f73569 96 #:use-module (gnu packages mcrypt)
37760623 97 #:use-module (gnu packages patchutils)
87216303 98 #:use-module (gnu packages pkg-config)
b36fcf95 99 #:use-module (gnu packages popt)
1a0346f0 100 #:use-module (gnu packages python)
cc6f4912 101 #:use-module (gnu packages python-crypto)
1b2f753d 102 #:use-module (gnu packages python-web)
44d10b1f 103 #:use-module (gnu packages python-xyz)
050e5756 104 #:use-module (gnu packages qt)
9d0c291e 105 #:use-module (gnu packages sphinx)
2468ca04 106 #:use-module (gnu packages terminals)
fccf2fe0 107 #:use-module (gnu packages texinfo)
e1485c7b 108 #:use-module (gnu packages groff)
42dc3af5 109 #:use-module (gnu packages pciutils)
d10fa5c7 110 #:use-module (gnu packages libunwind)
42dc3af5
MW
111 #:use-module (gnu packages libusb)
112 #:use-module (gnu packages libftdi)
c4492a16 113 #:use-module (gnu packages image)
da6c3749 114 #:use-module (gnu packages xorg)
d10fa5c7 115 #:use-module (gnu packages xdisorg)
e932d371 116 #:use-module (gnu packages man)
5ec8b02d 117 #:use-module (gnu packages autotools)
118 #:use-module (gnu packages gnome)
89e34644 119 #:use-module (gnu packages kerberos)
58989684 120 #:use-module (gnu packages gtk)
3ebf2c29
PAR
121 #:use-module (gnu packages xml)
122 #:use-module (gnu packages boost)
123 #:use-module (gnu packages elf)
bbc94ed0 124 #:use-module (gnu packages mpi)
6eb1d20b 125 #:use-module (gnu packages version-control)
bbc94ed0 126 #:use-module (gnu packages web))
f15164e7 127
c1f73569
RW
128(define-public aide
129 (package
130 (name "aide")
c3f4505e 131 (version "0.16.2")
737300be
TGR
132 (source
133 (origin
134 (method url-fetch)
135 (uri (string-append "https://github.com/aide/aide/releases/download/v"
136 version "/aide-" version ".tar.gz"))
137 (sha256
c3f4505e 138 (base32 "15xp47sz7kk1ciffw3f5xw2jg2mb2lqrbr3q6p4bkbz5dap9iy8p"))))
c1f73569
RW
139 (build-system gnu-build-system)
140 (native-inputs
141 `(("bison" ,bison)
142 ("flex" ,flex)))
143 (inputs
144 `(("libgcrypt" ,libgcrypt)
145 ("libgpg-error" ,libgpg-error)
146 ("libmhash" ,libmhash)
7d9d521f 147 ("pcre:static" ,pcre "static")
b067ad3e 148 ("pcre" ,pcre)
7d9d521f 149 ("zlib:static" ,zlib "static")
c1f73569
RW
150 ("zlib" ,zlib)))
151 (synopsis "File and directory integrity checker")
152 (description
153 "AIDE (Advanced Intrusion Detection Environment) is a file and directory
154integrity checker. It creates a database from the regular expression rules
155that it finds from its configuration files. Once this database is initialized
156it can be used to verify the integrity of the files. It has several message
157digest algorithms that are used to check the integrity of files. All of the
158usual file attributes can be checked for inconsistencies.")
737300be 159 (home-page "https://aide.github.io/")
c1f73569
RW
160 (license license:gpl2+)))
161
4971d5d0
RJ
162(define-public progress
163 (package
164 (name "progress")
3116a4c5 165 (version "0.14")
4b6456ce
TGR
166 (source
167 (origin
168 (method git-fetch)
169 (uri (git-reference
170 (url "https://github.com/Xfennec/progress.git")
171 (commit (string-append "v" version))))
172 (sha256
173 (base32 "1lk2v4b767klib93an4g3f7z5qrv9kdk9jf7545vw1immc4kamrl"))
174 (file-name (git-file-name name version))))
4971d5d0 175 (build-system gnu-build-system)
eec9c4a7
TGR
176 (native-inputs
177 `(("pkg-config" ,pkg-config)
178 ("which" ,which)))
4971d5d0
RJ
179 (inputs
180 `(("ncurses" ,ncurses)))
181 (arguments
4b6456ce 182 `(#:tests? #f ; no test suite
eec9c4a7 183 #:make-flags (list "CC=gcc"
4971d5d0
RJ
184 (string-append "PREFIX=" (assoc-ref %outputs "out")))
185 #:phases
186 (modify-phases %standard-phases
4b6456ce 187 (delete 'configure)))) ; no configure script
4971d5d0
RJ
188 (home-page "https://github.com/Xfennec/progress")
189 (synopsis "Program to view the progress of the coreutils commands")
190 (description "A program that looks for coreutils basic commands (cp, mv,
191dd, tar, gzip/gunzip, cat, etc.) currently running on your system and displays
192the percentage of copied data. It can also show estimated time and throughput,
193and provides a \"top-like\" mode (monitoring).")
194 (license license:gpl3+)))
195
e932d371 196(define-public shepherd
133056bd
LC
197 (package
198 (name "shepherd")
205c1e04 199 (version "0.7.0")
133056bd
LC
200 (source (origin
201 (method url-fetch)
9fb1ca08 202 (uri (string-append "mirror://gnu/shepherd/shepherd-"
133056bd
LC
203 version ".tar.gz"))
204 (sha256
205 (base32
205c1e04 206 "07j3vd0y8zab2nwbrwj0ahrfif1ldm5sjssn7m3dw4s307fsrfzx"))))
133056bd
LC
207 (build-system gnu-build-system)
208 (arguments
209 '(#:configure-flags '("--localstatedir=/var")))
425ab478
LC
210 (native-inputs
211 `(("pkg-config" ,pkg-config)
212
213 ;; This is the Guile we use as a cross-compiler...
24ba2cee 214 ("guile" ,guile-2.2/bug-fix)))
425ab478
LC
215 (inputs
216 ;; ... and this is the one that appears in shebangs when cross-compiling.
24ba2cee 217 `(("guile" ,guile-2.2/bug-fix) ;for <https://bugs.gnu.org/37757>
bfb06e58
LC
218
219 ;; The 'shepherd' command uses Readline when used interactively. It's
220 ;; an unusual use case though, so we don't propagate it.
221 ("guile-readline" ,guile-readline)))
133056bd
LC
222 (synopsis "System service manager")
223 (description
224 "The GNU Shepherd is a daemon-managing daemon, meaning that it supervises
225the execution of system services, replacing similar functionality found in
226typical init systems. It provides dependency-handling through a convenient
227interface and is based on GNU Guile.")
228 (license license:gpl3+)
9fb1ca08 229 (home-page "https://www.gnu.org/software/shepherd/")))
e932d371 230
139a9887
LC
231(define-public guile3.0-shepherd
232 (package
233 (inherit shepherd)
234 (name "guile3.0-shepherd")
235 (native-inputs
236 `(("pkg-config" ,pkg-config)
237 ("guile" ,guile-next)))
238 (inputs
239 `(("guile" ,guile-next)))))
240
bf949323
CB
241(define-public cloud-utils
242 (package
243 (name "cloud-utils")
244 (version "0.31")
245 (source
246 (origin
247 (method url-fetch)
248 (uri (string-append
249 "https://launchpad.net/cloud-utils/trunk/"
250 version "/+download/cloud-utils-" version ".tar.gz"))
251 (sha256
252 (base32
253 "07fl3dlqwdzw4xx7mcxhpkks6dnmaxha80zgs9f6wmibgzni8z0r"))))
254 (build-system gnu-build-system)
255 (arguments
256 '(#:make-flags
257 (let ((out (assoc-ref %outputs "out")))
258 (list (string-append "BINDIR=" out "/bin")
259 (string-append "MANDIR=" out "/share/man/man1")
260 (string-append "DOCDIR=" out "/share/doc")))
261 #:phases
262 (modify-phases %standard-phases
263 (delete 'configure)
264 (delete 'check)
265 (add-after 'install 'wrap
266 (lambda* (#:key outputs inputs #:allow-other-keys)
267 (let ((growpart (string-append (assoc-ref outputs "out")
268 "/bin/growpart")))
269 (wrap-program growpart
270 `("PATH" ":" prefix (,(dirname (which "sfdisk"))
271 ,(dirname (which "readlink"))))))
272 #t)))))
273 (inputs
274 `(("python" ,python)
275 ("util-linux" ,util-linux))) ; contains sfdisk for growpart
276 (home-page "https://launchpad.net/cloud-utils")
277 (synopsis "Set of utilities for cloud computing environments")
278 (description
279 "This package contains a set of utilities for cloud computing
280environments:
281
282@itemize @bullet
283@item @command{cloud-localds} Create a disk for cloud-init to utilize nocloud
284@item @command{cloud-publish-image} Wrapper for cloud image publishing
285@item @command{cloud-publish-tarball} Wrapper for publishing cloud tarballs
286@item @command{cloud-publish-ubuntu} Import a Ubuntu cloud image
287@item @command{ec2metadata} Query and display @acronym{EC2,Amazon Elastic
288 Compute Cloud} metadata
289@item @command{growpart} Grow a partition to fill the device
290@item @command{mount-image-callback} Mount a file and run a command
291@item @command{resize-part-image} Resize a partition image to a new size
292@item @command{ubuntu-cloudimg-query} Get the latest Ubuntu
293 @acronym{AMI,Amazon Machine Image}
294@item @command{ubuntu-ec2-run} Run a @acronym{EC2,Amazon Elastic Compute
295 Cloud} instance using Ubuntu
296@item @command{vcs-run} Obtain a repository, and run a command
297@item @command{write-mime-multipart} Handle multipart
298 @acronym{MIME,Multipurpose Internet Mail Extensions} messages
299@end itemize")
300 (license license:gpl3)))
301
db341bfa
CB
302(define-public daemontools
303 (package
304 (name "daemontools")
305 (version "0.76")
306 (source (origin
307 (method url-fetch)
308 (uri (string-append
213114a7
TGR
309 "https://cr.yp.to/daemontools/"
310 "daemontools-" version ".tar.gz"))
db341bfa
CB
311 (sha256
312 (base32
313 "07scvw88faxkscxi91031pjkpccql6wspk4yrlnsbrrb5c0kamd5"))))
314 (build-system gnu-build-system)
315 (arguments
316 `(#:tests? #f ;; No tests as far as I can tell.
317 #:phases
318 (modify-phases %standard-phases
319 (add-after 'unpack 'chdir
320 (lambda _
213114a7 321 (chdir ,(string-append "daemontools-" version))
cb8ba848 322 #t))
db341bfa
CB
323 (delete 'configure)
324 (add-before 'build 'patch
325 (lambda _
326 (substitute* "src/error.h"
327 (("extern int errno;")
cb8ba848
MW
328 "#include <errno.h>"))
329 #t))
db341bfa
CB
330 (replace 'build
331 (lambda _
332 (invoke "package/compile")))
333 (replace 'install
334 (lambda* (#:key outputs #:allow-other-keys)
335 (let* ((out (assoc-ref outputs "out"))
336 (bin (string-append out "/bin")))
337 (for-each (lambda (file)
338 (install-file file bin))
cb8ba848
MW
339 (find-files "command")))
340 #t)))))
db341bfa
CB
341 (synopsis "Tools for managing UNIX style services")
342 (description
343 "@code{daemontools} is a collection of tools for managing UNIX
344services.")
345 (license license:public-domain)
346 (home-page "https://cr.yp.to/daemontools.html")))
347
fbc1a58f
CR
348(define-public dfc
349 (package
350 (name "dfc")
48167ccd 351 (version "3.1.1")
fbc1a58f
CR
352 (source
353 (origin
354 (method url-fetch)
355 (uri (string-append
eeb8b0e6 356 "https://projects.gw-computing.net/attachments/download/615/dfc-"
fbc1a58f
CR
357 version ".tar.gz"))
358 (sha256
359 (base32
48167ccd 360 "0m1fd7l85ckb7bq4c5c3g257bkjglm8gq7x42pkmpp87fkknc94n"))))
fbc1a58f
CR
361 (build-system cmake-build-system)
362 (arguments '(#:tests? #f)) ; There are no tests.
b94a6ca0 363 (native-inputs `(("gettext" ,gettext-minimal)))
eeb8b0e6 364 (home-page "https://projects.gw-computing.net/projects/dfc")
fbc1a58f
CR
365 (synopsis "Display file system space usage using graphs and colors")
366 (description
367 "dfc (df color) is a modern version of df. It uses colors, draws pretty
368graphs and can export its output to different formats.")
f61e0e79 369 (license license:bsd-3)))
fbc1a58f 370
340c7033
CR
371(define-public htop
372 (package
611ee0c9
MB
373 (name "htop")
374 (version "2.2.0")
375 (source (origin
376 (method url-fetch)
377 (uri (string-append "http://hisham.hm/htop/releases/"
378 version "/htop-" version ".tar.gz"))
379 (sha256
380 (base32
381 "0mrwpb3cpn3ai7ar33m31yklj64c3pp576vh1naqff6f21pq5mnr"))))
382 (build-system gnu-build-system)
383 (inputs
384 `(("ncurses" ,ncurses)))
385 (native-inputs
386 `(("python" ,python-wrapper))) ;for scripts/MakeHeader.py
387 (home-page "https://hisham.hm/htop/")
388 (synopsis "Interactive process viewer")
389 (description
390 "This is htop, an interactive process viewer. It is a text-mode
340c7033 391application (for console or X terminals) and requires ncurses.")
611ee0c9 392 (license license:gpl2)))
340c7033 393
1df895b0
LC
394(define-public pies
395 (package
396 (name "pies")
3fb666bd 397 (version "1.4")
1df895b0
LC
398 (source
399 (origin
a9764b7d
LC
400 (method url-fetch)
401 (uri (string-append "mirror://gnu/pies/pies-"
402 version ".tar.bz2"))
403 (sha256
404 (base32
3fb666bd 405 "14jb4pa4zs26d5j2skxbaypnwhsx2lw8jgj1irrgs03c2dnf7gp6"))))
1df895b0 406 (build-system gnu-build-system)
a9764b7d
LC
407 (arguments
408 '(#:phases (modify-phases %standard-phases
409 (add-before 'build 'patch-/bin/sh
410 (lambda* (#:key inputs #:allow-other-keys)
411 ;; Use the right shell when executing user-provided
412 ;; shell commands.
413 (let ((bash (assoc-ref inputs "bash")))
3fb666bd 414 (substitute* '("src/progman.c" "src/comp.c")
a9764b7d
LC
415 (("\"/bin/sh\"")
416 (string-append "\"" bash "/bin/sh\"")))
417 #t))))))
56cb6f1d 418 (home-page "https://www.gnu.org.ua/software/pies/")
f50d2669 419 (synopsis "Program invocation and execution supervisor")
1df895b0 420 (description
79c311b8 421 "GNU pies is a program that supervises the invocation and execution of
a22dc0c4
LC
422other programs. It reads the list of programs to be started from its
423configuration file, executes them, and then monitors their status,
424re-executing them as necessary.")
f61e0e79 425 (license license:gpl3+)))
1df895b0
LC
426
427(define-public inetutils
428 (package
429 (name "inetutils")
8b1c8e4e 430 (version "1.9.4")
01eafd38
LC
431 (source (origin
432 (method url-fetch)
433 (uri (string-append "mirror://gnu/inetutils/inetutils-"
434 version ".tar.gz"))
435 (sha256
436 (base32
8b1c8e4e 437 "05n65k4ixl85dc6rxc51b1b732gnmm8xnqi424dy9f1nz7ppb3xy"))))
1df895b0 438 (build-system gnu-build-system)
483188b7 439 (arguments
e4015e57
LC
440 `(#:configure-flags '("--localstatedir=/var"
441
442 ;; Make sure 'PATH_PROCNET_DEV' gets defined when
443 ;; cross-compiling (by default it does not.)
444 ,@(if (%current-target-system)
445 '("--with-path-procnet-dev=/proc/net/dev")
446 '()))
ed6a21b4
MB
447 ;; On some systems, 'libls.sh' may fail with an error such as:
448 ;; "Failed to tell switch -a apart from -A".
449 #:parallel-tests? #f))
9927622f 450 (inputs `(("ncurses" ,ncurses)
6f5d28f9
MC
451 ("readline" ,readline))) ;for 'ftp'
452 (native-inputs `(("netstat" ,net-tools))) ;for tests
6fd52309 453 (home-page "https://www.gnu.org/software/inetutils/")
f50d2669 454 (synopsis "Basic networking utilities")
1df895b0 455 (description
a22dc0c4 456 "Inetutils is a collection of common network programs, such as an ftp
e048de60
LF
457client and server, a telnet client and server, an rsh client and server, and
458hostname.")
f61e0e79 459 (license license:gpl3+)))
9a9e72d5
LC
460
461(define-public shadow
462 (package
463 (name "shadow")
1c78a291 464 (version "4.8.1")
9a9e72d5 465 (source (origin
ca2a55d4
SB
466 (method url-fetch)
467 (uri (string-append
4153ef23 468 "https://github.com/shadow-maint/shadow/releases/"
469 "download/" version "/shadow-" version ".tar.xz"))
ca2a55d4
SB
470 (sha256
471 (base32
1c78a291 472 "0qmfq50sdhz6xilgxvinblll8j2iqfl7hwk45bq744y4plq4dbd3"))))
9a9e72d5
LC
473 (build-system gnu-build-system)
474 (arguments
ce6223e6 475 `(;; Assume System V `setpgrp (void)', which is the default on GNU
9a9e72d5 476 ;; variants (`AC_FUNC_SETPGRP' is not cross-compilation capable.)
52701a3d 477 #:configure-flags
478 '("--with-libpam" "ac_cv_func_setpgrp_void=yes")
9a9e72d5 479
52701a3d 480 #:phases
481 (modify-phases %standard-phases
482 (add-before 'build 'set-nscd-file-name
483 (lambda* (#:key inputs #:allow-other-keys)
484 ;; Use the right file name for nscd.
ce6223e6
LC
485 (let ((libc (assoc-ref inputs
486 ,(if (%current-target-system)
487 "cross-libc"
488 "libc"))))
52701a3d 489 (substitute* "lib/nscd.c"
490 (("/usr/sbin/nscd")
acfa777e
MW
491 (string-append libc "/sbin/nscd")))
492 #t)))
52701a3d 493 (add-after 'install 'remove-groups
494 (lambda* (#:key outputs #:allow-other-keys)
495 ;; Remove `groups', which is already provided by Coreutils.
496 (let* ((out (assoc-ref outputs "out"))
497 (bin (string-append out "/bin"))
498 (man (string-append out "/share/man")))
499 (delete-file (string-append bin "/groups"))
500 (for-each delete-file (find-files man "^groups\\."))
501 #t))))))
9a9e72d5 502
5dfbd769
LC
503 (inputs (if (string-contains (or (%current-target-system)
504 (%current-system))
505 "-linux")
506 `(("linux-pam" ,linux-pam))
507 '()))
1f6dd7e9 508 (home-page "https://github.com/shadow-maint/shadow")
9a9e72d5
LC
509 (synopsis "Authentication-related tools such as passwd, su, and login")
510 (description
511 "Shadow provides a number of authentication-related tools, including:
512login, passwd, su, groupadd, and useradd.")
513
514 ;; The `vipw' program is GPLv2+.
515 ;; libmisc/salt.c is public domain.
f61e0e79 516 (license license:bsd-3)))
1e151896
LC
517
518(define-public mingetty
519 (package
520 (name "mingetty")
521 (version "1.08")
522 (source (origin
523 (method url-fetch)
de67e922
LF
524 (uri (string-append "mirror://sourceforge/mingetty/mingetty/"
525 version "/mingetty-" version ".tar.gz"))
1e151896
LC
526 (sha256
527 (base32
528 "05yxrp44ky2kg6qknk1ih0kvwkgbn9fbz77r3vci7agslh5wjm8g"))))
529 (build-system gnu-build-system)
530 (arguments
dc1d3cde
KK
531 `(#:phases
532 (modify-phases %standard-phases
533 (replace 'configure
534 (lambda* (#:key inputs outputs #:allow-other-keys)
535 (let* ((out (assoc-ref outputs "out"))
536 (man8 (string-append out "/share/man/man8"))
537 (sbin (string-append out "/sbin"))
538 (shadow (assoc-ref inputs "shadow"))
539 (login (string-append shadow "/bin/login")))
540 (substitute* "Makefile"
541 (("^SBINDIR.*")
542 (string-append "SBINDIR = " out
543 "/sbin\n"))
544 (("^MANDIR.*")
545 (string-append "MANDIR = " out
546 "/share/man/man8\n")))
547
548 ;; Pick the right 'login' by default.
549 (substitute* "mingetty.c"
550 (("\"/bin/login\"")
551 (string-append "\"" login "\"")))
552
553 (mkdir-p sbin)
554 (mkdir-p man8))
555 #t)))
1e151896
LC
556 #:tests? #f)) ; no tests
557 (inputs `(("shadow" ,shadow)))
558
3b3b60d0 559 (home-page "https://sourceforge.net/projects/mingetty")
1e151896
LC
560 (synopsis "Getty for the text console")
561 (description
562 "Small console getty that is started on the Linux text console,
36a4366d
EF
563asks for a login name and then transfers over to @code{login}. It is extended
564to allow automatic login and starting any app.")
f61e0e79 565 (license license:gpl2+)))
c773aba8
LC
566
567(define-public net-base
568 (package
569 (name "net-base")
db719df7 570 (version "5.3")
c773aba8
LC
571 (source (origin
572 (method url-fetch)
573 (uri (string-append
34af3684 574 "mirror://debian/pool/main/n/netbase/netbase_"
db719df7 575 version ".tar.xz"))
c773aba8
LC
576 (sha256
577 (base32
db719df7 578 "12xqjwg3p4rzmmh2iib6sigm9l29y3dgk74mmnw64k84jnbwdxl1"))))
c773aba8
LC
579 (build-system trivial-build-system)
580 (arguments
581 `(#:modules ((guix build utils))
582 #:builder (begin
583 (use-modules (guix build utils)
584 (srfi srfi-26))
585
586 (let* ((source (assoc-ref %build-inputs "source"))
587 (tar (assoc-ref %build-inputs "tar"))
db719df7 588 (xz (assoc-ref %build-inputs "xz"))
c773aba8
LC
589 (output (assoc-ref %outputs "out"))
590 (etc (string-append output "/etc")))
db719df7 591 (setenv "PATH" (string-append xz "/bin"))
e3cfef22
MW
592 (invoke (string-append tar "/bin/tar") "xvf"
593 source)
c773aba8
LC
594 (chdir ,(string-append "netbase-" version))
595 (mkdir-p etc)
596 (for-each copy-file
597 '("etc-services" "etc-protocols" "etc-rpc")
598 (map (cut string-append etc "/" <>)
599 '("services" "protocols" "rpc")))
600 #t))))
601 (native-inputs `(("tar" ,tar)
f61e0e79 602 ("xz" ,xz)))
c773aba8
LC
603 (synopsis "IANA protocol, port, and RPC number assignments")
604 (description
605 "This package provides the /etc/services, /etc/protocols, and /etc/rpc
606files, which contain information about the IANA-assigned port, protocol, and
e881752c 607ONC RPC numbers.")
eeb8b0e6 608 (home-page "https://packages.debian.org/sid/netbase")
f61e0e79 609 (license license:gpl2)))
94c4a58a
LC
610
611(define-public netcat
612 (package
613 (name "netcat")
614 (version "0.7.1")
615 (source (origin
616 (method url-fetch)
de67e922
LF
617 (uri (string-append "mirror://sourceforge/netcat/netcat/" version
618 "/netcat-" version ".tar.bz2"))
94c4a58a
LC
619 (sha256
620 (base32
621 "1frjcdkhkpzk0f84hx6hmw5l0ynpmji8vcbaxg8h5k2svyxz0nmm"))))
622 (build-system gnu-build-system)
0e4e89c2
MW
623 (arguments
624 `(#:configure-flags
625 ;; By default, man and info pages are put in PREFIX/{man,info},
626 ;; but we want them in PREFIX/share/{man,info}.
627 (let ((out (assoc-ref %outputs "out")))
628 (list (string-append "--mandir=" out "/share/man")
629 (string-append "--infodir=" out "/share/info")))))
94c4a58a
LC
630 (home-page "http://netcat.sourceforge.net")
631 (synopsis "Read and write data over TCP/IP")
632 (description
633 "Netcat is a featured networking utility which reads and writes data
634across network connections, using the TCP/IP protocol. It is designed to be a
635reliable \"back-end\" tool that can be used directly or easily driven by other
35b9e423 636programs and scripts. At the same time, it is a feature-rich network debugging
94c4a58a
LC
637and exploration tool, since it can create almost any kind of connection you
638would need and has several interesting built-in capabilities.")
f61e0e79 639 (license license:gpl2+)))
d038cac1 640
37760623
AG
641(define-public netcat-openbsd
642 (package
643 (name "netcat-openbsd")
b0945d69 644 (version "1.206-1")
37760623
AG
645 (source (origin
646 (method git-fetch)
647 (uri (git-reference
648 (url "https://salsa.debian.org/debian/netcat-openbsd.git")
649 (commit (string-append "debian/" version))))
650 (file-name (git-file-name name version))
651 (sha256
652 (base32
b0945d69 653 "08r3mmck3s5pbvwyq19wp5g8jqcxza3cm8nkc6jm7rqn4jdydc4z"))))
37760623
AG
654 (build-system gnu-build-system)
655 (arguments
656 `(#:tests? #f ; no test suite
657 #:make-flags
658 (list "CC=gcc"
659 (string-append "CFLAGS=-I" (assoc-ref %build-inputs "libbsd") "/include")
660 "LDFLAGS=-lbsd")
661 #:phases
662 (modify-phases %standard-phases
663 (delete 'configure)
664 (add-before 'build 'patch
665 (lambda _
666 (setenv "QUILT_PATCHES" "debian/patches")
667 (invoke "quilt" "push" "-a")
668 #t))
669 (replace 'install
670 (lambda* (#:key outputs #:allow-other-keys)
671 (let* ((out (assoc-ref outputs "out"))
672 (bin (string-append out "/bin"))
673 (man (string-append out "/share/man/man1"))
674 (doc (string-append out "/share/doc/netcat-openbsd-" ,version))
675 (examples (string-append doc "/examples")))
676 (install-file "nc" bin)
677 (install-file "nc.1" man)
678 (install-file "debian/copyright" doc)
679 (copy-recursively "debian/examples" examples)
680 #t))))))
681 (inputs `(("libbsd" ,libbsd)))
682 (native-inputs `(("pkg-config" ,pkg-config)
683 ("quilt" ,quilt)))
684 (home-page "https://packages.debian.org/sid/netcat-openbsd")
685 (synopsis "Read and write data over TCP/IP")
686 (description
687 "Netcat is a simple Unix utility which reads and writes data across
688network connections using TCP or UDP protocol. It is designed to be a reliable
689\"back-end\" tool that can be used directly or easily driven by other programs
690and scripts. At the same time it is a feature-rich network debugging and
691exploration tool, since it can create almost any kind of connection you would
692need and has several interesting built-in capabilities.
693
694This package contains the OpenBSD rewrite of netcat, including support for
695IPv6, proxies, and Unix sockets.")
696 (license (list license:bsd-3
697 license:bsd-2)))) ; atomicio.*, socks.c
698
8d0edc82
OP
699(define-public sipcalc
700 (package
701 (name "sipcalc")
702 (version "1.1.6")
703 (source
704 (origin
705 (method url-fetch)
706 (uri (string-append "http://www.routemeister.net/projects"
707 "/sipcalc/files/sipcalc" "-" version ".tar.gz"))
708 (sha256
709 (base32
710 "0mv3wndj4z2bsshh2k8d5sy3j8wxzgf8mzmmkvj1k8gpcz37dm6g"))))
711 (build-system gnu-build-system)
712 (home-page "http://www.routemeister.net/projects/sipcalc/")
713 (synopsis "Command-line IP subnet calculator")
714 (description
715 "Sipcalc is an advanced command-line IP subnet calculator. It can take
716multiple forms of input (IPv4/IPv6/interface/hostname) and output a multitude
717of information about a given subnet.
718
719Features include:
720
721@itemize @bullet
722@item IPv4
723@itemize
724@item Retrieving of address information from interfaces.
725@item Classfull and CIDR output.
726@item Multiple address and netmask input and output formats (dotted quad, hex,
727number of bits).
728@item Output of broadcast address, network class, Cisco wildcard,
729hosts/range, network range.
730@item The ability to split a network based on a smaller netmask, now also with
731recursive runs on the generated subnets. (also IPv6)
732@end itemize
733@item IPv6
734@itemize
735@item Compressed and expanded input and output addresses.
736@item Standard IPv6 network output.
737@item v4 in v6 output.
738@item Reverse DNS address generation.
739@end itemize
740@end itemize\n")
741 (license license:bsd-3)))
742
d038cac1
LC
743(define-public alive
744 (package
745 (name "alive")
746 (version "2.0.2")
747 (source (origin
748 (method url-fetch)
749 (uri (string-append "mirror://gnu/alive/alive-"
750 version ".tar.xz"))
751 (sha256
752 (base32
753 "1vrzg51ai68x9yld7vbgl58sxaw5qpx8rbakwcxn4cqq6vpxj38j"))))
754 (build-system gnu-build-system)
755 (arguments '(#:configure-flags '("alive_cv_nice_ping=yes")))
756 (inputs `(("guile" ,guile-2.0)
757 ("inetutils" ,inetutils)))
6fd52309 758 (home-page "https://www.gnu.org/software/alive/")
d038cac1
LC
759 (synopsis "Autologin and keep-alive daemon")
760 (description
761 "GNU Alive sends periodic pings to a server, generally to keep a
762connection alive.")
f61e0e79 763 (license license:gpl3+)))
c73d4c92
LC
764
765(define-public isc-dhcp
6548b1e1 766 (let* ((bind-major-version "9")
4e2432d1 767 (bind-minor-version "11")
89af7ff3 768 (bind-patch-version "14")
f7780fdf
MW
769 (bind-release-type "") ; for patch release, use "-P"
770 (bind-release-version "") ; for patch release, e.g. "6"
6548b1e1
MW
771 (bind-version (string-append bind-major-version
772 "."
773 bind-minor-version
774 "."
775 bind-patch-version
776 bind-release-type
777 bind-release-version)))
778 (package
779 (name "isc-dhcp")
4bcc3908 780 (version "4.4.2")
6548b1e1
MW
781 (source (origin
782 (method url-fetch)
8198b3db 783 (uri (string-append "https://ftp.isc.org/isc/dhcp/"
6548b1e1
MW
784 version "/dhcp-" version ".tar.gz"))
785 (sha256
786 (base32
4bcc3908 787 "08a5003zdxgl41b29zjkxa92h2i40zyjgxg0npvnhpkfl5jcsz0s"))))
6548b1e1
MW
788 (build-system gnu-build-system)
789 (arguments
e54465ff 790 `(#:parallel-build? #f
445013b6 791 #:configure-flags '("--with-randomdev=/dev/random")
e54465ff 792 #:phases
6548b1e1
MW
793 (modify-phases %standard-phases
794 (add-after 'unpack 'replace-bundled-bind
f7780fdf 795 (lambda* (#:key inputs native-inputs #:allow-other-keys)
6548b1e1
MW
796 (delete-file "bind/bind.tar.gz")
797 (copy-file (assoc-ref inputs "bind-source-tarball")
798 "bind/bind.tar.gz")
799 (chmod "bind/bind.tar.gz" #o644)
800 (substitute* "bind/version.tmp"
801 (("^MAJORVER=.*")
802 (format #f "MAJORVER=~a\n" ,bind-major-version))
803 (("^MINORVER=.*")
804 (format #f "MINORVER=~a\n" ,bind-minor-version))
805 (("^PATCHVER=.*")
806 (format #f "PATCHVER=~a\n" ,bind-patch-version))
807 (("^RELEASETYPE=.*")
808 (format #f "RELEASETYPE=~a\n" ,bind-release-type))
809 (("^RELEASEVER=.*")
810 (format #f "RELEASEVER=~a\n" ,bind-release-version)))
811 #t))
445013b6
MO
812 (add-before 'configure 'fix-bind-cross-compilation
813 (lambda _
814 (substitute* "configure"
815 (("--host=\\$host")
816 "--host=$host_alias"))
817 #t))
6548b1e1
MW
818 (add-after 'configure 'post-configure
819 (lambda* (#:key outputs #:allow-other-keys)
820 ;; Point to the right client script, which will be
821 ;; installed in a later phase.
822 (substitute* "includes/dhcpd.h"
823 (("#define[[:blank:]]+_PATH_DHCLIENT_SCRIPT.*")
824 (let ((out (assoc-ref outputs "out")))
825 (string-append "#define _PATH_DHCLIENT_SCRIPT \""
826 out "/libexec/dhclient-script"
827 "\"\n"))))
c73d4c92 828
6548b1e1
MW
829 ;; During the 'build' phase, 'bind.tar.gz' is extracted, so
830 ;; we must patch shebangs in there and make sure the right
831 ;; shell is used.
832 (with-directory-excursion "bind"
833 (substitute* "Makefile"
f7780fdf 834 (("\\./configure ")
6548b1e1
MW
835 (let ((sh (which "sh")))
836 (string-append "./configure CONFIG_SHELL="
f7780fdf 837 sh " SHELL=" sh " "))))
c73d4c92 838
6548b1e1 839 (let ((bind-directory (string-append "bind-" ,bind-version)))
d6acc9f8 840 (invoke "tar" "xf" "bind.tar.gz")
6548b1e1
MW
841 (for-each patch-shebang
842 (find-files bind-directory ".*"))
f7780fdf
MW
843 (substitute* (string-append bind-directory "/configure")
844 (("/usr/bin/file")
845 (which "file")))
d6acc9f8
MW
846 (invoke "tar" "cf" "bind.tar.gz"
847 bind-directory
848 ;; avoid non-determinism in the archive
849 "--sort=name"
850 "--mtime=@0"
851 "--owner=root:0"
852 "--group=root:0")))))
6548b1e1
MW
853 (add-after 'install 'post-install
854 (lambda* (#:key inputs outputs #:allow-other-keys)
855 ;; Install the dhclient script for GNU/Linux and make sure
856 ;; if finds all the programs it needs.
857 (let* ((out (assoc-ref outputs "out"))
858 (libexec (string-append out "/libexec"))
859 (coreutils (assoc-ref inputs "coreutils"))
860 (inetutils (assoc-ref inputs "inetutils"))
861 (net-tools (assoc-ref inputs "net-tools"))
862 (sed (assoc-ref inputs "sed")))
863 (substitute* "client/scripts/linux"
864 (("/sbin/ip")
865 (string-append (assoc-ref inputs "iproute")
866 "/sbin/ip")))
c73d4c92 867
6548b1e1
MW
868 (mkdir-p libexec)
869 (copy-file "client/scripts/linux"
870 (string-append libexec "/dhclient-script"))
c73d4c92 871
6548b1e1
MW
872 (wrap-program
873 (string-append libexec "/dhclient-script")
874 `("PATH" ":" prefix
875 ,(map (lambda (dir)
876 (string-append dir "/bin:"
877 dir "/sbin"))
d6acc9f8
MW
878 (list inetutils net-tools coreutils sed))))
879 #t))))))
c73d4c92 880
f7780fdf
MW
881 (native-inputs
882 `(("perl" ,perl)
4bcc3908 883 ("file" ,file)))
c73d4c92 884
6548b1e1
MW
885 (inputs `(("inetutils" ,inetutils)
886 ("net-tools" ,net-tools)
887 ("iproute" ,iproute)
dc343935 888
4bcc3908
TGR
889 ;; isc-dhcp bundles a copy of BIND, which has proved vulnerable
890 ;; in the past. Use a BIND-VERSION of our choosing instead.
6548b1e1
MW
891 ("bind-source-tarball"
892 ,(origin
893 (method url-fetch)
8198b3db 894 (uri (string-append "https://ftp.isc.org/isc/bind9/"
6548b1e1
MW
895 bind-version
896 "/bind-" bind-version ".tar.gz"))
897 (sha256
898 (base32
89af7ff3 899 "1pv3bvm9dzyz2kqjkw15sgh0hd5fzsv274v5z6jp9c4nb5130fyr"))))
c73d4c92 900
6548b1e1
MW
901 ;; When cross-compiling, we need the cross Coreutils and sed.
902 ;; Otherwise just use those from %FINAL-INPUTS.
903 ,@(if (%current-target-system)
904 `(("coreutils" ,coreutils)
905 ("sed" ,sed))
906 '())))
907
8198b3db 908 (home-page "https://www.isc.org/products/DHCP/")
6548b1e1
MW
909 (synopsis "Dynamic Host Configuration Protocol (DHCP) tools")
910 (description
911 "ISC's Dynamic Host Configuration Protocol (DHCP) distribution provides a
c73d4c92
LC
912reference implementation of all aspects of DHCP, through a suite of DHCP
913tools: server, client, and relay agent.")
4e2432d1 914 (license license:mpl2.0)
159a5e01 915 (properties '((cpe-name . "dhcp"))))))
02c86a5e
LC
916
917(define-public libpcap
918 (package
919 (name "libpcap")
4cc0b485 920 (version "1.9.1")
02c86a5e
LC
921 (source (origin
922 (method url-fetch)
eeb8b0e6 923 (uri (string-append "https://www.tcpdump.org/release/libpcap-"
02c86a5e
LC
924 version ".tar.gz"))
925 (sha256
926 (base32
4cc0b485 927 "153h1378diqyc27jjgz6gg5nxmb4ddk006d9xg69nqavgiikflk3"))))
02c86a5e 928 (build-system gnu-build-system)
24dd949c
TGR
929 (native-inputs
930 `(("bison" ,bison)
931 ("flex" ,flex)))
932 (arguments
933 ;; There are some tests in testprogs/, but no automated test suite.
934 '(#:tests? #f))
eeb8b0e6 935 (home-page "https://www.tcpdump.org")
02c86a5e
LC
936 (synopsis "Network packet capture library")
937 (description
938 "libpcap is an interface for user-level packet capture. It provides a
939portable framework for low-level network monitoring. Applications include
940network statistics collection, security monitoring, network debugging, etc.")
24dd949c
TGR
941 (license (list license:bsd-4 ; fad-*.c and several other source files
942 license:bsd-3 ; pcap/, sockutils.* & others
943 license:bsd-2)))) ; the rest
02c86a5e 944
1da34f5a
LC
945(define-public tcpdump
946 (package
947 (name "tcpdump")
645d0c92 948 (version "4.9.3")
1da34f5a
LC
949 (source (origin
950 (method url-fetch)
eeb8b0e6 951 (uri (string-append "https://www.tcpdump.org/release/tcpdump-"
73a2ef36 952 version ".tar.gz"))
1da34f5a
LC
953 (sha256
954 (base32
645d0c92 955 "0434vdcnbqaia672rggjzdn4bb8p8dchz559yiszzdk0sjrprm1c"))))
1da34f5a 956 (build-system gnu-build-system)
10db1e6c 957 (inputs `(("libpcap" ,libpcap)
cc2b77df 958 ("openssl" ,openssl)))
1da34f5a 959 (native-inputs `(("perl" ,perl))) ; for tests
eeb8b0e6 960 (home-page "https://www.tcpdump.org/")
1da34f5a
LC
961 (synopsis "Network packet analyzer")
962 (description
963 "Tcpdump is a command-line tool to analyze network traffic passing
964through the network interface controller.")
f61e0e79 965 (license license:bsd-3)))
1da34f5a 966
02c86a5e
LC
967(define-public jnettop
968 (package
969 (name "jnettop")
970 (version "0.13.0")
971 (source (origin
972 (method url-fetch)
53923b0f
BH
973 (uri
974 (string-append "https://web.archive.org/web/20161221100811/"
975 "http://jnettop.kubs.info/dist/jnettop-"
976 version ".tar.gz"))
02c86a5e
LC
977 (sha256
978 (base32
979 "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9"))))
980 (build-system gnu-build-system)
981 (native-inputs
982 `(("pkg-config" ,pkg-config)))
983 (inputs
984 `(("glib" ,glib)
985 ("ncurses" ,ncurses)
986 ("libpcap" ,libpcap)))
53923b0f
BH
987 (home-page
988 "https://web.archive.org/web/20160703195221/http://jnettop.kubs.info/wiki/")
02c86a5e
LC
989 (synopsis "Visualize network traffic by bandwidth use")
990 (description
991 "Jnettop is a traffic visualiser, which captures traffic going
992through the host it is running from and displays streams sorted
993by bandwidth they use.")
f61e0e79 994 (license license:gpl2+)))
87216303
EB
995
996(define-public clusterssh
997 (package
998 (name "clusterssh")
c5829179 999 (version "4.13.2")
87216303
EB
1000 (source (origin
1001 (method url-fetch)
1002 (uri (string-append "mirror://sourceforge/clusterssh/"
c5829179
KK
1003 "2.%20ClusterSSH%20Series%204/"
1004 "App-ClusterSSH-v" version ".tar.gz"))
87216303
EB
1005 (sha256
1006 (base32
c5829179
KK
1007 "0rmk2p3f2wz1h092anidjclh212rv3gxyk0c641qk3frlrjnw6mp"))))
1008 (build-system perl-build-system)
12ea2571
TGR
1009 (arguments
1010 `(#:phases
1011 (modify-phases %standard-phases
1012 (add-after 'unpack 'refer-to-inputs
1013 (lambda* (#:key inputs #:allow-other-keys)
1014 (substitute* (list "lib/App/ClusterSSH/Config.pm"
1015 "t/15config.t")
1016 (("xterm")
1017 (which "xterm")))
1018 #t))
1019 (add-before 'check 'delete-failing-tests
1020 (lambda _
1021 ;; This checks whether all code is nicely formatted. The above
1022 ;; ‘refer-to-inputs’ phase breaks this pedantry, so disable it.
1023 (delete-file "t/perltidy.t")
1024 ;; Update the manifest so t/manifest.t happily passes.
1025 (substitute* "MANIFEST"
1026 (("t/perltidy.t\n") ""))
332a2765
TGR
1027 #t))
1028 (add-after 'install 'augment-library-path
1029 (lambda* (#:key inputs outputs #:allow-other-keys)
1030 (let* ((out (assoc-ref outputs "out"))
1031 (bin (string-append out "/bin")))
1032 (with-directory-excursion bin
1033 (for-each
1034 (lambda (program)
1035 (wrap-program program
1036 `("PERL5LIB" ":" prefix
1037 ,(map (lambda (file-name)
1038 (string-append file-name
1039 "/lib/perl5/site_perl"))
1040 (cons out
1041 (map (lambda (input)
1042 (assoc-ref inputs input))
1043 ;; These may be propagated and hence
1044 ;; not explicitly listed as inputs.
1045 (list "perl-class-data-inheritable"
1046 "perl-devel-stacktrace"
1047 "perl-exception-class"
1048 "perl-tk"
1049 "perl-try-tiny"
1050 "perl-x11-protocol"
1051 "perl-x11-protocol-other")))))))
1052 (find-files "." ".*")))
1053 #t))))))
c5829179
KK
1054 (native-inputs
1055 `(("perl-cpan-changes" ,perl-cpan-changes)
1056 ("perl-file-slurp" ,perl-file-slurp)
1057 ("perl-file-which" ,perl-file-which)
1058 ("perl-module-build" ,perl-module-build)
1059 ("perl-readonly" ,perl-readonly)
1060 ("perl-test-differences" ,perl-test-differences)
1061 ("perl-test-distmanifest" ,perl-test-distmanifest)
1062 ("perl-test-perltidy" ,perl-test-perltidy)
1063 ("perl-test-pod" ,perl-test-pod)
1064 ("perl-test-pod-coverage" ,perl-test-pod-coverage)
1065 ("perl-test-trap" ,perl-test-trap)
1066 ("perltidy" ,perltidy)))
12ea2571 1067 (inputs
12ea2571 1068 `(("perl-exception-class" ,perl-exception-class)
b07aea69 1069 ("perl-sort-naturally" ,perl-sort-naturally)
c5829179
KK
1070 ("perl-tk" ,perl-tk)
1071 ("perl-try-tiny" ,perl-try-tiny)
1072 ("perl-x11-protocol" ,perl-x11-protocol)
332a2765
TGR
1073 ("perl-x11-protocol-other" ,perl-x11-protocol-other)
1074 ("xterm" ,xterm)))
87216303 1075 ;; The clusterssh.sourceforge.net address requires login to view
3b3b60d0 1076 (home-page "https://sourceforge.net/projects/clusterssh/")
87216303
EB
1077 (synopsis "Secure concurrent multi-server terminal control")
1078 (description
1079 "ClusterSSH controls a number of xterm windows via a single graphical
1080console window to allow commands to be interactively run on multiple servers
1081over ssh connections.")
f61e0e79 1082 (license license:gpl2+)))
fccf2fe0 1083
d1ce1125
MB
1084(define-public rename
1085 (package
1086 (name "rename")
0db873dd 1087 (version "1.10")
d1ce1125
MB
1088 (source (origin
1089 (method url-fetch)
1090 (uri (string-append
1091 "mirror://cpan/authors/id/R/RM/RMBARKER/File-Rename-"
1092 version ".tar.gz"))
1093 (sha256
1094 (base32
0db873dd 1095 "137m8s06r4n038ivlr5r1d9a7q9l7shmwpvnyx053r9ndhvbnkh5"))))
d1ce1125 1096 (build-system perl-build-system)
e6dcf9ca
TGR
1097 (arguments
1098 `(#:phases
1099 (modify-phases %standard-phases
1100 (add-after 'install 'find-itself
1101 ;; Fix run-time 'Can't locate File/Rename.pm in @INC' failure.
1102 (lambda* (#:key outputs #:allow-other-keys)
1103 (let* ((out (assoc-ref outputs "out"))
1104 (bin (string-append out "/bin")))
1105 (with-directory-excursion bin
1106 (for-each
1107 (lambda (program)
1108 (wrap-program program
1109 `("PERL5LIB" ":" prefix
1110 (,(string-append out "/lib/perl5/site_perl")))))
1111 (find-files "." ".*")))
1112 #t))))))
d1ce1125
MB
1113 (native-inputs
1114 `(("perl-module-build" ,perl-module-build)
1115 ("perl-test-pod" ,perl-test-pod)
1116 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
1117 (home-page "https://metacpan.org/pod/distribution/File-Rename/rename.PL")
1118 (synopsis "Perl extension for renaming multiple files")
1119 (description
1120 "This package provides a Perl interface (@code{Perl::Rename}) as well
1121as a command-line utility (@command{rename}) that can rename multiple files
1122at once based on a Perl regular expression.")
1123 (license license:perl-license)))
1124
fccf2fe0
LC
1125(define-public rottlog
1126 (package
1127 (name "rottlog")
1128 (version "0.72.2")
1129 (source (origin
1130 (method url-fetch)
1131 (uri (string-append "mirror://gnu/rottlog/rottlog-"
1132 version ".tar.gz"))
1133 (sha256
1134 (base32
1135 "0751mb9l2f0jrk3vj6q8ilanifd121dliwk0c34g8k0dlzsv3kd7"))
1136 (modules '((guix build utils)))
1137 (snippet
6cbee49d
MW
1138 '(begin
1139 (substitute* "Makefile.in"
1140 (("-o \\$\\{LOG_OWN\\} -g \\$\\{LOG_GROUP\\}")
1141 ;; Don't try to chown root.
1142 "")
1143 (("mkdir -p \\$\\(ROTT_STATDIR\\)")
1144 ;; Don't attempt to create /var/lib/rottlog.
1145 "true"))
1146 #t))))
fccf2fe0
LC
1147 (build-system gnu-build-system)
1148 (arguments
268ad34e 1149 '(#:configure-flags (list "ROTT_ETCDIR=/etc/rottlog" ;rc file location
fccf2fe0 1150 "--localstatedir=/var")
268ad34e
LC
1151
1152 ;; Install example config files in OUT/etc.
1153 #:make-flags (list (string-append "ROTT_ETCDIR="
1154 (assoc-ref %outputs "out")
1155 "/etc"))
1156
8dc0ecae 1157 #:phases (modify-phases %standard-phases
d436c6b5
MB
1158 (add-after 'unpack 'patch-paths
1159 (lambda _
1160 (substitute* "rc/rc"
1161 (("/usr/sbin/sendmail") "sendmail"))
1162 #t))
11e74634
JN
1163 (add-after 'build 'set-packdir
1164 (lambda _
1165 ;; Set a default location for archived logs.
1166 (substitute* "rc/rc"
1167 (("packdir=\"\"")
1168 "packdir=\"/var/log\""))
1169 #t))
309e523e
LC
1170 (add-before 'install 'tweak-rc-weekly
1171 (lambda _
1172 (substitute* "rc/weekly"
1173 (("/bin/kill")
1174 (which "kill"))
1175 (("syslogd\\.pid")
1176 ;; The file is called 'syslog.pid' (no 'd').
1177 "syslog.pid"))
1178 #t))
8dc0ecae
LC
1179 (add-after 'install 'install-info
1180 (lambda _
cb8ba848 1181 (invoke "make" "install-info"))))))
fccf2fe0
LC
1182 (native-inputs `(("texinfo" ,texinfo)
1183 ("util-linux" ,util-linux))) ; for 'cal'
6fd52309 1184 (home-page "https://www.gnu.org/software/rottlog/")
fccf2fe0
LC
1185 (synopsis "Log rotation and management")
1186 (description
1187 "GNU Rot[t]log is a program for managing log files. It is used to
1188automatically rotate out log files when they have reached a given size or
1189according to a given schedule. It can also be used to automatically compress
1190and archive such logs. Rot[t]log will mail reports of its activity to the
1191system administrator.")
f61e0e79 1192 (license license:gpl3+)))
e1485c7b
LC
1193
1194(define-public sudo
1195 (package
1196 (name "sudo")
08b87d16 1197 (version "1.8.31")
e1485c7b
LC
1198 (source (origin
1199 (method url-fetch)
1200 (uri
6baa83d2 1201 (list (string-append "https://www.sudo.ws/sudo/dist/sudo-"
e1485c7b
LC
1202 version ".tar.gz")
1203 (string-append "ftp://ftp.sudo.ws/pub/sudo/OLD/sudo-"
1204 version ".tar.gz")))
1205 (sha256
1206 (base32
08b87d16 1207 "0ks5mm9hda5idivncyfpiz4lrd8fv0dpmsl711788k7f7ixdka3y"))
6b7f1b6c
MB
1208 (modules '((guix build utils)))
1209 (snippet
6cbee49d
MW
1210 '(begin
1211 (delete-file-recursively "lib/zlib")
1212 #t))))
e1485c7b
LC
1213 (build-system gnu-build-system)
1214 (arguments
0086ec73
LC
1215 `(#:configure-flags
1216 (list "--with-logpath=/var/log/sudo.log"
8e950ee9 1217 "--with-rundir=/var/run/sudo" ; must be cleaned up at boot time
0086ec73
LC
1218 "--with-vardir=/var/db/sudo"
1219 "--with-iologdir=/var/log/sudo-io"
1220
1221 ;; 'visudo.c' expects _PATH_MV to be defined, but glibc doesn't
1222 ;; provide it.
1223 (string-append "CPPFLAGS=-D_PATH_MV='\""
1224 (assoc-ref %build-inputs "coreutils")
1225 "/bin/mv\"'"))
511495fb
LC
1226
1227 ;; Avoid non-determinism; see <http://bugs.gnu.org/21918>.
1228 #:parallel-build? #f
1229
7fae2063
TGR
1230 #:phases
1231 (modify-phases %standard-phases
1232 (add-before 'configure 'pre-configure
1233 (lambda _
1234 (substitute* "src/sudo_usage.h.in"
1235 ;; Do not capture 'configure' arguments since we would
1236 ;; unduly retain references, and also because the
1237 ;; CPPFLAGS above would close the string literal
1238 ;; prematurely.
1239 (("@CONFIGURE_ARGS@") "\"\""))
1240 (substitute* (find-files "." "Makefile\\.in")
1241 (("-o [[:graph:]]+ -g [[:graph:]]+")
1242 ;; Allow installation as non-root.
1243 "")
1244 (("^install: (.*)install-sudoers(.*)" _ before after)
1245 ;; Don't try to create /etc/sudoers.
1246 (string-append "install: " before after "\n"))
1247 (("\\$\\(DESTDIR\\)\\$\\(rundir\\)")
1248 ;; Don't try to create /run/sudo.
1249 "$(TMPDIR)/dummy")
1250 (("\\$\\(DESTDIR\\)\\$\\(vardir\\)")
1251 ;; Don't try to create /var/db/sudo.
4b052c6a 1252 "$(TMPDIR)/dummy"))
cbaf756c
TGR
1253
1254 ;; ‘Checking existing [/etc/]sudoers file for syntax errors’ is
1255 ;; not the task of the build system, and fails.
1256 (substitute* "plugins/sudoers/Makefile.in"
1257 (("^pre-install:" match)
1258 (string-append match "\ndisabled-" match)))
4b052c6a 1259 #t)))
e1485c7b
LC
1260
1261 ;; XXX: The 'testsudoers' test series expects user 'root' to exist, but
1262 ;; the chroot's /etc/passwd doesn't have it. Turn off the tests.
1263 #:tests? #f))
1264 (inputs
1265 `(("groff" ,groff)
1266 ("linux-pam" ,linux-pam)
6b7f1b6c 1267 ("zlib" ,zlib)
e1485c7b 1268 ("coreutils" ,coreutils)))
6baa83d2 1269 (home-page "https://www.sudo.ws/")
e1485c7b
LC
1270 (synopsis "Run commands as root")
1271 (description
1272 "Sudo (su \"do\") allows a system administrator to delegate authority to
1273give certain users (or groups of users) the ability to run some (or all)
1274commands as root or another user while providing an audit trail of the
1275commands and their arguments.")
1276
1277 ;; See <http://www.sudo.ws/sudo/license.html>.
f61e0e79 1278 (license license:x11)))
952298d7 1279
1ce6f43a 1280(define-public wpa-supplicant-minimal
952298d7 1281 (package
1ce6f43a 1282 (name "wpa-supplicant-minimal")
ba7ff983 1283 (version "2.9")
952298d7
LC
1284 (source (origin
1285 (method url-fetch)
1286 (uri (string-append
eeb8b0e6 1287 "https://w1.fi/releases/wpa_supplicant-"
aeb1ed1a 1288 version ".tar.gz"))
952298d7
LC
1289 (sha256
1290 (base32
ba7ff983 1291 "05qzak1mssnxcgdrafifxh9w86a4ha69qabkg4bsigk499xyxggw"))
aeb1ed1a
MB
1292 (modules '((guix build utils)))
1293 (snippet
1294 '(begin
1295 (substitute* "wpa_supplicant/defconfig"
1296 ;; Disable D-Bus to save ~14MiB on the closure size.
1297 (("^CONFIG_CTRL_IFACE_DBUS" line _)
1298 (string-append "#" line)))
1299 #t))))
952298d7
LC
1300 (build-system gnu-build-system)
1301 (arguments
dc1d3cde
KK
1302 '(#:phases
1303 (modify-phases %standard-phases
1304 (replace 'configure
1305 (lambda* (#:key outputs #:allow-other-keys)
1306 (chdir "wpa_supplicant")
1307 (copy-file "defconfig" ".config")
1308 (let ((port (open-file ".config" "al")))
1309 (display "
952298d7 1310 CONFIG_DEBUG_SYSLOG=y
40b4c6d6 1311
aeb1ed1a 1312 CONFIG_TLS=openssl
61bdd0d8 1313
952298d7
LC
1314 CONFIG_DRIVER_NL80211=y
1315 CFLAGS += $(shell pkg-config libnl-3.0 --cflags)
1316 CONFIG_LIBNL32=y
1317 CONFIG_READLINE=y\n" port)
cb8ba848
MW
1318 (close-port port))
1319 #t))
3b165f2a 1320 (add-after 'install 'install-documentation
dc1d3cde
KK
1321 (lambda* (#:key outputs #:allow-other-keys)
1322 (let* ((out (assoc-ref outputs "out"))
3b165f2a 1323 (doc (string-append out "/share/doc/wpa-supplicant"))
dc1d3cde
KK
1324 (man (string-append out "/share/man"))
1325 (man5 (string-append man "/man5"))
1326 (man8 (string-append man "/man8")))
1327 (define (copy-man-page target)
1328 (lambda (file)
1329 (install-file file target)))
1330
1331 (mkdir-p man5) (mkdir man8)
1332 (for-each (copy-man-page man5)
1333 (find-files "doc/docbook" "\\.5"))
1334 (for-each (copy-man-page man8)
1335 (find-files "doc/docbook" "\\.8"))
3b165f2a
TL
1336
1337 ;; wpa_supplicant.conf(5) does not explain all configuration
1338 ;; options but refers to the example config file, so install it
1339 ;; along with READMEs.
1340 (for-each (lambda (file)
1341 (install-file file doc))
1342 '("README" "README-DPP" "README-HS20"
1343 "README-P2P" "README-WPS"
1344 "wpa_supplicant.conf"))
dc1d3cde 1345 #t))))
952298d7
LC
1346
1347 #:make-flags (list "CC=gcc"
1348 (string-append "BINDIR=" (assoc-ref %outputs "out")
1349 "/sbin")
1350 (string-append "LIBDIR=" (assoc-ref %outputs "out")
1351 "/lib"))
1352 #:tests? #f))
1353 (inputs
1354 `(("readline" ,readline)
1355 ("libnl" ,libnl)
aeb1ed1a 1356 ("openssl" ,openssl)))
952298d7
LC
1357 (native-inputs
1358 `(("pkg-config" ,pkg-config)))
eeb8b0e6 1359 (home-page "https://w1.fi/wpa_supplicant/")
952298d7
LC
1360 (synopsis "Connecting to WPA and WPA2-protected wireless networks")
1361 (description
1362 "wpa_supplicant is a WPA Supplicant with support for WPA and WPA2 (IEEE
1363802.11i / RSN). Supplicant is the IEEE 802.1X/WPA component that is used in
1364the client stations. It implements key negotiation with a WPA Authenticator
1365and it controls the roaming and IEEE 802.11 authentication/association of the
1366WLAN driver.
1367
36a4366d
EF
1368This package provides the @code{wpa_supplicant} daemon and the @code{wpa_cli}
1369command.")
952298d7
LC
1370
1371 ;; In practice, this is linked against Readline, which makes it GPLv3+.
107b081e
LC
1372 (license license:bsd-3)
1373
1374 (properties `((cpe-name . "wpa_supplicant")))))
c6b76405 1375
4fb7e0de 1376(define-public wpa-supplicant
1ce6f43a 1377 (package (inherit wpa-supplicant-minimal)
4fb7e0de
MW
1378 (name "wpa-supplicant")
1379 (inputs `(("dbus" ,dbus)
1ce6f43a 1380 ,@(package-inputs wpa-supplicant-minimal)))
4fb7e0de 1381 (arguments
1ce6f43a 1382 (substitute-keyword-arguments (package-arguments wpa-supplicant-minimal)
4fb7e0de 1383 ((#:phases phases)
dc1d3cde
KK
1384 `(modify-phases ,phases
1385 (add-after 'configure 'configure-for-dbus
1386 (lambda _
1387 (let ((port (open-file ".config" "al")))
1388 (display "
4fb7e0de
MW
1389 CONFIG_CTRL_IFACE_DBUS_NEW=y
1390 CONFIG_CTRL_IFACE_DBUS_INTRO=y\n" port)
dc1d3cde
KK
1391 (close-port port))
1392 #t))
3b165f2a 1393 (add-after 'install-documentation 'install-dbus-conf
dc1d3cde
KK
1394 (lambda* (#:key outputs #:allow-other-keys)
1395 (let* ((out (assoc-ref outputs "out"))
1396 (dir (string-append out "/etc/dbus-1/system.d")))
1397 (mkdir-p dir)
1398 (copy-file "dbus/dbus-wpa_supplicant.conf"
1399 (string-append dir "/wpa_supplicant.conf")))
1400 #t))))))))
4fb7e0de 1401
050e5756
MB
1402(define-public wpa-supplicant-gui
1403 (package
1404 (inherit wpa-supplicant)
1405 (name "wpa-supplicant-gui")
1406 (inputs `(("qtbase" ,qtbase)
1407 ("qtsvg" ,qtsvg)
1408 ,@(package-inputs wpa-supplicant)))
1409 (native-inputs
1410 ;; For icons.
1411 `(("imagemagick" ,imagemagick)
1412 ("inkscape" ,inkscape)
1413 ,@(package-native-inputs wpa-supplicant)))
1414 (arguments
1415 `(#:phases (modify-phases %standard-phases
1416 (add-after 'unpack 'chdir
1417 (lambda _
1418 (chdir "wpa_supplicant/wpa_gui-qt4")
1419 #t))
1420 (delete 'configure)
1421 (replace 'build
1422 (lambda _
1423 (invoke "qmake" "wpa_gui.pro")
1424 (invoke "make" "-j" (number->string (parallel-job-count)))
1425 (invoke "make" "-C" "icons")))
1426 (replace 'install
1427 (lambda* (#:key inputs outputs #:allow-other-keys)
1428 (let ((out (assoc-ref outputs "out"))
1429 (qt '("qtbase" "qtsvg")))
050e5756
MB
1430 (install-file "wpa_gui" (string-append out "/bin"))
1431 (install-file "wpa_gui.desktop"
1432 (string-append out "/share/applications"))
1433 (copy-recursively "icons/hicolor"
1434 (string-append out "/share/icons/hicolor"))
1435 (wrap-program (string-append out "/bin/wpa_gui")
1436 `("QT_PLUGIN_PATH" ":" prefix
1437 ,(map (lambda (label)
1438 (string-append (assoc-ref inputs label)
1439 "/lib/qt5/plugins/"))
1440 qt)))
1441 #t))))))
1442 (synopsis "Graphical user interface for WPA supplicant")))
1443
56038bac
LC
1444(define-public hostapd
1445 (package
1446 (name "hostapd")
f5bfaf32 1447 (version "2.9")
56038bac
LC
1448 (source (origin
1449 (method url-fetch)
1450 (uri (string-append "https://w1.fi/releases/hostapd-" version
1451 ".tar.gz"))
1452 (sha256
1453 (base32
f5bfaf32 1454 "1mrbvg4v7vm7mknf0n29mf88k3s4a4qj6r4d51wq8hmjj1m7s7c8"))))
56038bac
LC
1455 (build-system gnu-build-system)
1456 (arguments
1457 '(#:phases
1458 (modify-phases %standard-phases
1459 (replace 'configure
1460 (lambda* (#:key outputs #:allow-other-keys)
1461 ;; This is mostly copied from 'wpa-supplicant' above.
1462 (chdir "hostapd")
1463 (copy-file "defconfig" ".config")
1464 (let ((port (open-file ".config" "al")))
1465 (display "
1466 CONFIG_LIBNL32=y
1467 CONFIG_IEEE80211R=y
1468 CONFIG_IEEE80211N=y
1469 CONFIG_IEEE80211AC=y\n" port)
1470 (close-port port))
1471 #t))
1472 (add-after 'install 'install-man-pages
1473 (lambda* (#:key outputs #:allow-other-keys)
1474 (let* ((out (assoc-ref outputs "out"))
1475 (man (string-append out "/share/man"))
1476 (man1 (string-append man "/man1"))
1477 (man8 (string-append man "/man8")))
1478 (define (copy-man-page target)
1479 (lambda (file)
1480 (install-file file target)))
1481
1482 (for-each (copy-man-page man1)
1483 (find-files "." "\\.1"))
1484 (for-each (copy-man-page man8)
1485 (find-files "." "\\.8"))
1486 #t))))
1487
1488 #:make-flags (list "CC=gcc"
1489 (string-append "BINDIR=" (assoc-ref %outputs "out")
1490 "/sbin")
1491 (string-append "LIBDIR=" (assoc-ref %outputs "out")
1492 "/lib"))
1493 #:tests? #f))
1494 (native-inputs `(("pkg-config" ,pkg-config)))
1495
1496 ;; There's an optional dependency on SQLite.
1497 (inputs `(("openssl" ,openssl)
1498 ("libnl" ,libnl)))
1499 (home-page "https://w1.fi/hostapd/")
1500 (synopsis "Daemon for Wi-Fi access points and authentication servers")
1501 (description
1502 "hostapd is a user-space daemon for WiFi access points and authentication
1503servers. It implements IEEE 802.11 access point management, IEEE
1504802.1X/WPA/WPA2/EAP Authenticators, RADIUS client, EAP server, and RADIUS
1505authentication server.")
1506
1507 ;; Same license as wpa_supplicant.
1508 (license license:bsd-3)))
1509
c6b76405
LC
1510(define-public wakelan
1511 (package
1512 (name "wakelan")
1513 (version "1.1")
1514 (source (origin
1515 (method url-fetch)
1516 (uri (string-append
1517 "ftp://ftp.gwdg.de/pub/linux/metalab/system/network/misc/wakelan-"
1518 version ".tar.gz"))
1519 (sha256
1520 (base32
1521 "0vydqpf44146ir6k87gmqaq6xy66xhc1gkr3nsd7jj3nhy7ypx9x"))))
1522 (build-system gnu-build-system)
1523 (arguments
dc1d3cde
KK
1524 '(#:phases
1525 (modify-phases %standard-phases
1526 (replace 'configure
1527 (lambda* (#:key outputs #:allow-other-keys)
1528 (let ((out (assoc-ref outputs "out")))
1529 (mkdir-p (string-append out "/bin"))
1530 (mkdir-p (string-append out "/share/man/man1"))
1531
1532 ;; It's an old configure script that doesn't understand
1533 ;; the extra options we pass.
1534 (setenv "CONFIG_SHELL" (which "bash"))
cb8ba848
MW
1535 (invoke "./configure"
1536 (string-append "--prefix=" out)
1537 (string-append "--mandir=" out
1538 "/share/man"))))))
c6b76405 1539 #:tests? #f))
eeb8b0e6 1540 (home-page "https://www.kernel.org") ; really, no home page
c6b76405
LC
1541 (synopsis "Send a wake-on-LAN packet")
1542 (description
1543 "WakeLan broadcasts a properly formatted UDP packet across the local area
1544network, which causes enabled computers to power on.")
f61e0e79 1545 (license license:gpl2+)))
d43f4296
LC
1546
1547(define-public dmidecode
1548 (package
1549 (name "dmidecode")
31fdfc0c 1550 (version "3.2")
d43f4296
LC
1551 (source (origin
1552 (method url-fetch)
1553 (uri (string-append
1554 "mirror://savannah/dmidecode/dmidecode-"
06438b07 1555 version ".tar.xz"))
d43f4296
LC
1556 (sha256
1557 (base32
31fdfc0c 1558 "1pcfhcgs2ifdjwp7amnsr3lq95pgxpr150bjhdinvl505px0cw07"))))
d43f4296
LC
1559 (build-system gnu-build-system)
1560 (arguments
06438b07 1561 '(#:phases (modify-phases %standard-phases (delete 'configure))
d43f4296
LC
1562 #:tests? #f ; no 'check' target
1563 #:make-flags (list (string-append "prefix="
1564 (assoc-ref %outputs "out")))))
340978d7 1565 (home-page "https://www.nongnu.org/dmidecode/")
d43f4296
LC
1566 (synopsis "Read hardware information from the BIOS")
1567 (description
1568 "Dmidecode reports information about your system's hardware as described
1569in your system BIOS according to the SMBIOS/DMI standard. This typically
1570includes system manufacturer, model name, serial number, BIOS version, asset
1571tag as well as a lot of other details of varying level of interest and
1572reliability depending on the manufacturer. This will often include usage
1573status for the CPU sockets, expansion slots (e.g. AGP, PCI, ISA) and memory
1574module slots, and the list of I/O ports (e.g. serial, parallel, USB).")
f61e0e79 1575 (license license:gpl2+)))
42dc3af5 1576
13c8c2bf
MW
1577(define-public acpica
1578 (package
1579 (name "acpica")
762b2af6 1580 (version "20200110")
13c8c2bf
MW
1581 (source (origin
1582 (method url-fetch)
1583 (uri (string-append
1584 "https://acpica.org/sites/acpica/files/acpica-unix2-"
1585 version ".tar.gz"))
1586 (sha256
1587 (base32
762b2af6 1588 "1hb4g6r7w8s4bhlkk36fmb4qxghnrwvad7f18cpn6zz0b4sjs7za"))))
13c8c2bf
MW
1589 (build-system gnu-build-system)
1590 (native-inputs `(("flex" ,flex)
1591 ("bison" ,bison)))
1592 (arguments
1593 '(#:make-flags (list (string-append "PREFIX=" %output)
4a462aa7 1594 "CC=gcc"
13c8c2bf
MW
1595 "HOST=_LINUX"
1596 "OPT_CFLAGS=-Wall -fno-strict-aliasing")
e56feffe 1597 #:tests? #f ; no 'check' target
dc1d3cde 1598 #:phases (modify-phases %standard-phases (delete 'configure))))
6c441efc 1599 (home-page "https://acpica.org/")
35b9e423 1600 (synopsis "Tools for the development and debug of ACPI tables")
13c8c2bf 1601 (description
3908546a 1602 "The ACPI Component Architecture (@dfn{ACPICA}) project provides an
13c8c2bf 1603OS-independent reference implementation of the Advanced Configuration and
3908546a
TGR
1604Power Interface Specification (@dfn{ACPI}). ACPICA code contains those portions
1605of ACPI meant to be directly integrated into the host OS as a kernel-resident
13c8c2bf
MW
1606subsystem, and a small set of tools to assist in developing and debugging ACPI
1607tables. This package contains only the user-space tools needed for ACPI table
1608development, not the kernel implementation of ACPI.")
e56feffe 1609 (license license:gpl2))) ; dual GPLv2/ACPICA Licence
4cf7bd2b 1610
bee9f97e
CB
1611(define-public s-tui
1612 (package
1613 (name "s-tui")
96d580a6 1614 (version "1.0.0")
bee9f97e
CB
1615 (source
1616 (origin
1617 (method url-fetch)
1618 (uri (pypi-uri "s-tui" version))
1619 (sha256
96d580a6 1620 (base32 "0r5yhlsi5xiy7ii1w4kqkaxz9069v5bbfwi3x3xnxhk51yjfgr8n"))))
bee9f97e
CB
1621 (build-system python-build-system)
1622 (inputs
1623 `(("python-psutil" ,python-psutil)
1624 ("python-urwid" ,python-urwid)))
1625 (home-page "https://github.com/amanusk/s-tui")
1626 (synopsis "Interactive terminal stress test and monitoring tool")
1627 (description
1628 "The Stress Terminal UI displays graphs of the CPU frequency,
1629utilization, temperature and power.")
1630 (license license:gpl2+)))
1631
4cf7bd2b
MW
1632(define-public stress
1633 (package
1634 (name "stress")
ca52937c 1635 (version "1.0.4")
4cf7bd2b
MW
1636 (source (origin
1637 (method url-fetch)
1638 (uri (string-append "mirror://debian/pool/main/s/stress/stress_"
1639 version ".orig.tar.gz"))
1640 (sha256
1641 (base32
ca52937c 1642 "0nw210jajk38m3y7h8s130ps2qsbz7j75wab07hi2r3hlz14yzh5"))))
4cf7bd2b 1643 (build-system gnu-build-system)
abf7fed5 1644 (home-page "https://packages.debian.org/sid/stress")
9e771e3b 1645 (synopsis "Impose load on and stress test a computer system")
4cf7bd2b 1646 (description
35b9e423 1647 "Stress is a tool that imposes a configurable amount of CPU, memory, I/O,
4cf7bd2b
MW
1648or disk stress on a POSIX-compliant operating system and reports any errors it
1649detects.
1650
35b9e423 1651Stress is not a benchmark. It is a tool used by system administrators to
4cf7bd2b
MW
1652evaluate how well their systems will scale, by kernel programmers to evaluate
1653perceived performance characteristics, and by systems programmers to expose
1654the classes of bugs which only or more frequently manifest themselves when the
1655system is under heavy load.")
f61e0e79 1656 (license license:gpl2+)))
b36fcf95
EB
1657
1658(define-public detox
1659 (package
1660 (name "detox")
c2d512d3 1661 (version "1.3.0")
b36fcf95 1662 (source (origin
c2d512d3
EB
1663 (method git-fetch)
1664 (uri (git-reference
1665 (url "https://github.com/dharple/detox.git")
1666 (commit (string-append "v" version))))
f1d4d79f 1667 (file-name (git-file-name name version))
b36fcf95
EB
1668 (sha256
1669 (base32
c2d512d3 1670 "1dd608c7g65s5lj02cddvani3q9kzirddgkjqa22ap9d4f8b9xgr"))))
b36fcf95 1671 (build-system gnu-build-system)
c2d512d3
EB
1672 (native-inputs
1673 `(("autoconf" ,autoconf)
1674 ("automake" ,automake)
1675 ("flex" ,flex)))
b36fcf95 1676 (arguments
c2d512d3
EB
1677 `(#:tests? #f ;no 'check' target
1678 #:phases (modify-phases %standard-phases
1679 (add-after 'unpack 'delete-configure
1680 ;; The "configure" script is present, but otherwise the
1681 ;; project is not bootstrapped: missing install-sh and
1682 ;; Makefile.in, so delete it so the bootstrap phase will
1683 ;; take over.
1684 (lambda _ (delete-file "configure") #t)))))
1685 (home-page "https://github.com/dharple/detox")
e881752c 1686 (synopsis "Clean up file names")
b36fcf95
EB
1687 (description
1688 "Detox is a program that renames files to make them easier to work with
1689under Unix and related operating systems. Spaces and various other unsafe
1690characters (such as \"$\") get replaced with \"_\". ISO 8859-1 (Latin-1)
1691characters can be replaced as well, as can UTF-8 characters.")
f61e0e79 1692 (license license:bsd-3)))
c4492a16
LC
1693
1694(define-public testdisk
1695 (package
1696 (name "testdisk")
2b336e93 1697 (version "7.1")
c4492a16
LC
1698 (source (origin
1699 (method url-fetch)
e14c06d8 1700 (uri (string-append "https://www.cgsecurity.org/testdisk-"
c4492a16
LC
1701 version ".tar.bz2"))
1702 (sha256
1703 (base32
2b336e93 1704 "1zlh44w67py416hkvw6nrfmjickc2d43v51vcli5p374d5sw84ql"))))
c4492a16
LC
1705 (build-system gnu-build-system)
1706 (inputs
d6a08ec0 1707 `(("ntfs-3g" ,ntfs-3g)
c4492a16 1708 ("util-linux" ,util-linux)
cc2b77df 1709 ("openssl" ,openssl)
2b336e93 1710 ;; FIXME: add reiserfs.
f61e0e79 1711 ("zlib" ,zlib)
c4492a16
LC
1712 ("e2fsprogs" ,e2fsprogs)
1713 ("libjpeg" ,libjpeg)
1714 ("ncurses" ,ncurses)))
8fc46a43 1715 (home-page "https://www.cgsecurity.org/wiki/TestDisk")
c4492a16
LC
1716 (synopsis "Data recovery tool")
1717 (description
1718 "TestDisk is a program for data recovery, primarily designed to help
1719recover lost partitions and/or make non-booting disks bootable again.")
f61e0e79 1720 (license license:gpl2+)))
c4492a16 1721
15926aec
AS
1722(define-public tree
1723 (package
1724 (name "tree")
1e2ebf7c 1725 (version "1.8.0")
15926aec
AS
1726 (source (origin
1727 (method url-fetch)
1728 (uri (string-append
1729 "http://mama.indstate.edu/users/ice/tree/src/tree-"
1730 version ".tgz"))
1731 (sha256
1e2ebf7c 1732 (base32 "1hmpz6k0mr6salv0nprvm1g0rdjva1kx03bdf1scw8a38d5mspbi"))))
15926aec
AS
1733 (build-system gnu-build-system)
1734 (arguments
dc1d3cde 1735 '(#:phases (modify-phases %standard-phases (delete 'configure))
15926aec
AS
1736 #:tests? #f ; no check target
1737 #:make-flags (let ((out (assoc-ref %outputs "out")))
1738 (list (string-append "prefix=" out)))))
1739 (synopsis "Recursively list the contents of a directory")
1740 (description
1741 "Tree is a recursive directory listing command that produces a depth
1742indented listing of files, which is colorized ala dircolors if the LS_COLORS
1743environment variable is set and output is to tty.")
1744 (home-page "http://mama.indstate.edu/users/ice/tree/")
1745 (license license:gpl2+)))
1746
c2619e10
LC
1747(define-public direvent
1748 (package
1749 (name "direvent")
857ff515 1750 (version "5.2")
c2619e10
LC
1751 (source (origin
1752 (method url-fetch)
1753 (uri (string-append "mirror://gnu/direvent/direvent-"
1754 version ".tar.gz"))
1755 (sha256
1756 (base32
857ff515 1757 "0m9vi01b1km0cpknflyzsjnknbava0s1n6393b2bpjwyvb6j5613"))
c2619e10 1758 (modules '((guix build utils)))
6cbee49d
MW
1759 (snippet '(begin
1760 (substitute* "tests/testsuite"
1761 (("#![[:blank:]]?/bin/sh")
1762 "#!$SHELL"))
1763 #t))))
c2619e10
LC
1764 (build-system gnu-build-system)
1765 (arguments
dc1d3cde
KK
1766 '(#:phases
1767 (modify-phases %standard-phases
1768 (add-before 'build 'patch-/bin/sh
1769 (lambda* (#:key inputs #:allow-other-keys)
1770 ;; Use the right shell when executing the watcher and
1771 ;; user-provided shell commands.
1772 (let ((bash (assoc-ref inputs "bash")))
1773 (substitute* '("src/direvent.c" "src/progman.c")
1774 (("\"/bin/sh\"")
1775 (string-append "\"" bash "/bin/sh\"")))
1776
1777 ;; Adjust the 'shell.at' test accordingly.
1778 (substitute* "tests/testsuite"
1779 (("SHELL=/bin/sh")
1780 (string-append "SHELL=" bash "/bin/sh")))
1781
1782 #t))))))
1977e857 1783 (home-page "https://www.gnu.org.ua/software/direvent/")
c2619e10
LC
1784 (synopsis "Daemon to monitor directories for events such as file removal")
1785 (description
1786 "A daemon that monitors directories for events, such as creating,
35b9e423 1787deleting or modifying files. It can monitor different sets of directories for
c2619e10
LC
1788different events. When an event is detected, direvent calls a specified
1789external program with information about the event, such as the location
c5779c93
LC
1790within the file system where it occurred. Thus, \"direvent\" provides an
1791easy way to react immediately if given files undergo changes, for example, to
c2619e10 1792track changes in important system configuration files.")
f61e0e79 1793 (license license:gpl3+)))
da6c3749
TUBK
1794
1795(define-public libcap-ng
1796 (package
1797 (name "libcap-ng")
c692c1b7 1798 (version "0.7.10")
da6c3749
TUBK
1799 (source (origin
1800 (method url-fetch)
1801 (uri (string-append
eeb8b0e6 1802 "https://people.redhat.com/sgrubb/libcap-ng/libcap-ng-"
da6c3749
TUBK
1803 version ".tar.gz"))
1804 (sha256
1805 (base32
c692c1b7 1806 "1gzzy12agfa9ddipdf72h9y68zqqnvsjjylv4vnq6hj4w2safk58"))))
da6c3749 1807 (build-system gnu-build-system)
dd935df2
TGR
1808 (arguments
1809 `(#:configure-flags
1810 (list "--without-python")))
4a2982a1 1811 (home-page "https://people.redhat.com/sgrubb/libcap-ng/")
da6c3749
TUBK
1812 (synopsis "Library for more easily working with POSIX capabilities")
1813 (description
1814 "The libcap-ng library is intended to make programming with POSIX
1815capabilities easier than the traditional libcap library. It includes
1816utilities that can analyse all currently running applications and print out
1817any capabilities and whether or not it has an open ended bounding set. The
1818included utilities are designed to let admins and developers spot apps from
1819various ways that may be running with too much privilege.")
1820 ;; The library is lgpl2.1+, but also ships some utils which are gpl2+.
f61e0e79 1821 (license (list license:lgpl2.1+ license:gpl2+))))
d02f2cc4
TUBK
1822
1823(define-public smartmontools
1824 (package
1825 (name "smartmontools")
d252fbb4 1826 (version "7.1")
d02f2cc4
TUBK
1827 (source (origin
1828 (method url-fetch)
1829 (uri (string-append
1830 "mirror://sourceforge/smartmontools/smartmontools/"
1831 version "/smartmontools-" version ".tar.gz"))
1832 (sha256
1833 (base32
d252fbb4 1834 "0imqb7ka4ia5573w8rnpck571pjjc9698pdjcapy9cfyk4n4swrz"))))
d02f2cc4
TUBK
1835 (build-system gnu-build-system)
1836 (inputs `(("libcap-ng" ,libcap-ng)))
51b6a1dd 1837 (home-page "https://www.smartmontools.org/")
d02f2cc4
TUBK
1838 (synopsis "S.M.A.R.T. harddisk control and monitoring tools")
1839 (description
1840 "The smartmontools package contains utility programs to control and
1841monitor storage systems using the Self-Monitoring, Analysis and Reporting
c115b2db
TGR
1842Technology System (@dfn{S.M.A.R.T.}) built into most modern ATA and SCSI hard
1843disks. In many cases, these utilities will provide advanced warning of disk
d02f2cc4 1844degradation and failure.")
f61e0e79 1845 (license license:gpl2+)))
6efd0823
RW
1846
1847(define-public fdupes
1848 (package
1849 (name "fdupes")
47d7b303 1850 (version "1.6.1")
6efd0823
RW
1851 (source
1852 (origin
9bc96d13
TGR
1853 (method git-fetch)
1854 (uri (git-reference
1855 (url "https://github.com/adrianlopezroche/fdupes.git")
1856 (commit (string-append "v" version))))
1857 (file-name (git-file-name name version))
6efd0823 1858 (sha256
9bc96d13 1859 (base32 "19b6vqblddaw8ccw4sn0qsqzbswlhrz8ia6n4m3hymvcxn8skpz9"))))
6efd0823
RW
1860 (build-system gnu-build-system)
1861 (arguments
e192a230
TGR
1862 '(#:phases (modify-phases %standard-phases
1863 (delete 'configure))
6efd0823 1864 #:tests? #f ; no 'check' target
47d7b303
TGR
1865 #:make-flags (list "CC=gcc"
1866 (string-append "PREFIX="
6efd0823
RW
1867 (assoc-ref %outputs "out")))))
1868 (home-page "https://github.com/adrianlopezroche/fdupes")
1869 (synopsis "Identify duplicate files")
1870 (description
1871 "fdupes is a program for identifying duplicate files residing within
1872specified directories.")
1873 (license license:expat)))
4ecfbda7
DT
1874
1875(define-public graphios
1876 (package
1877 (name "graphios")
1878 (version "2.0.3")
1879 (source
1880 (origin
1881 (method url-fetch)
4267aa75 1882 (uri (pypi-uri "graphios" version))
4ecfbda7
DT
1883 (sha256
1884 (base32
1885 "1h87hvc315wg6lklbf4l7csd3n5pgljwrfli1p3nasdi0izgn66i"))))
1886 (build-system python-build-system)
1887 (arguments
1888 ;; Be warned: Building with Python 3 succeeds, but the build process
1889 ;; throws a syntax error that is ignored.
1890 `(#:python ,python-2
1891 #:phases
1892 (modify-phases %standard-phases
1893 (add-before 'build 'fix-setup.py
1894 (lambda* (#:key outputs #:allow-other-keys)
1895 ;; Fix hardcoded, unprefixed file names.
1896 (let ((out (assoc-ref outputs "out")))
1897 (substitute* '("setup.py")
1898 (("/etc") (string-append out "/etc"))
1899 (("/usr") out)
1900 (("distro_ver = .*") "distro_ver = ''"))
1901 #t))))))
4ecfbda7
DT
1902 (home-page "https://github.com/shawn-sterling/graphios")
1903 (synopsis "Emit Nagios metrics to Graphite, Statsd, and Librato")
1904 (description
1905 "Graphios is a script to emit nagios perfdata to various upstream metrics
1906processing and time-series systems. It's currently compatible with Graphite,
1907Statsd, Librato and InfluxDB. Graphios can emit Nagios metrics to any number
1908of supported upstream metrics systems simultaneously.")
1909 (license license:gpl2+)))
8d801045
ED
1910
1911(define-public ansible
1912 (package
1913 (name "ansible")
131e9676 1914 (version "2.8.5")
8d801045
ED
1915 (source
1916 (origin
1917 (method url-fetch)
697e86dd 1918 (uri (pypi-uri "ansible" version))
8d801045 1919 (sha256
131e9676 1920 (base32 "11k94ifp42psivzx147xwbmq1ak7qnjdgkb6c1xz53nfapkh754f"))))
8d801045
ED
1921 (build-system python-build-system)
1922 (native-inputs
504e26ed
KB
1923 `(("python-bcrypt" ,python-bcrypt)
1924 ("python-pynacl" ,python-pynacl)
1925 ("python-httplib2" ,python-httplib2)
1926 ("python-passlib" ,python-passlib)
1927 ("python-nose" ,python-nose)
1928 ("python-mock" ,python-mock)
1929 ("python-jinja2" ,python-jinja2)
1930 ("python-pyyaml" ,python-pyyaml)
1931 ("python-paramiko" ,python-paramiko)))
8d801045 1932 (inputs
504e26ed
KB
1933 `(("python-cryptography" ,python-cryptography)
1934 ("python-jinja2" ,python-jinja2)
1935 ("python-pyyaml" ,python-pyyaml)
1936 ("python-paramiko" ,python-paramiko)))
01cb4d47
AI
1937 (arguments
1938 `(#:phases
1939 (modify-phases %standard-phases
1940 ;; Several ansible commands (ansible-config, ansible-console, etc.)
1941 ;; are just symlinks to a single ansible executable. The ansible
1942 ;; executable behaves differently based on the value of
1943 ;; sys.argv[0]. This does not work well with our wrap phase, and
1944 ;; therefore the following two phases are required as a workaround.
1945 (add-after 'unpack 'hide-wrapping
1946 (lambda _
1947 ;; Overwrite sys.argv[0] to hide the wrapper script from it.
1948 (substitute* "bin/ansible"
1949 (("import traceback" all)
1950 (string-append all "
1951import re
1952sys.argv[0] = re.sub(r'\\.([^/]*)-real$', r'\\1', sys.argv[0])
1953")))
1954 #t))
ba8551ec 1955 (add-after 'install 'replace-symlinks
01cb4d47 1956 (lambda* (#:key outputs #:allow-other-keys)
ba8551ec
AI
1957 ;; Replace symlinks with duplicate copies of the ansible
1958 ;; executable.
01cb4d47
AI
1959 (let ((out (assoc-ref outputs "out")))
1960 (for-each
1961 (lambda (subprogram)
ba8551ec
AI
1962 (delete-file (string-append out "/bin/ansible-" subprogram))
1963 (copy-file (string-append out "/bin/ansible")
1964 (string-append out "/bin/ansible-" subprogram)))
01cb4d47
AI
1965 (list "config" "console" "doc" "galaxy"
1966 "inventory" "playbook" "pull" "vault")))
1967 #t)))))
ff18d0f1 1968 (home-page "https://www.ansible.com/")
8d801045
ED
1969 (synopsis "Radically simple IT automation")
1970 (description "Ansible is a radically simple IT automation system. It
e22473ff
TGR
1971handles configuration management, application deployment, cloud provisioning,
1972ad hoc task execution, and multinode orchestration---including trivializing
1973things like zero-downtime rolling updates with load balancers.")
8d801045 1974 (license license:gpl3+)))
44157e9f 1975
6eb1d20b
HG
1976(define-public debops
1977 (package
1978 (name "debops")
1979 (version "1.1.0")
1980 (source
1981 (origin
1982 (method git-fetch)
1983 (uri (git-reference
1984 (url "https://github.com/debops/debops")
1985 (commit (string-append "v" version))))
1986 (file-name (git-file-name name version))
1987 (sha256
1988 (base32 "052b2dykdn35pdpn9s4prawl6nl6yzih8nyf54hpvhpisvjrm1v5"))
1989 (patches
1990 (search-patches "debops-constants-for-external-program-names.patch"
1991 "debops-debops-defaults-fall-back-to-less.patch"))))
1992 (build-system python-build-system)
1993 (native-inputs
1994 `(("git" ,git)))
1995 (inputs
1996 `(("ansible" ,ansible)
1997 ("encfs" ,encfs)
1998 ("fuse" ,fuse)
1999 ("util-linux" ,util-linux) ;; for umount
2000 ("findutils" ,findutils)
2001 ("gnupg" ,gnupg)
2002 ("which" ,which)))
2003 (propagated-inputs
2004 `(("python-future" ,python-future)
2005 ("python-distro" ,python-distro)))
2006 (arguments
2007 `(#:tests? #f
2008 #:phases
2009 (modify-phases %standard-phases
2010 (add-after 'unpack 'nuke-debops-update
2011 (lambda _
2012 (chmod "bin/debops-update" #o755) ; FIXME work-around git-fetch issue
2013 (with-output-to-file "bin/debops-update"
2014 (lambda ()
2015 (format #t "#!/bin/sh
2016echo 'debops is installed via guix. guix-update is useless in this case.
2017Please use `guix package -u debops` instead.'")))
2018 #t))
2019 ;; patch shebangs only in actuall scripts, not in files included in
2020 ;; roles (which are to be delivered to the targte systems)
2021 (delete `patch-generated-file-shebangs)
2022 (replace 'patch-source-shebangs
2023 (lambda _
2024 (for-each patch-shebang
2025 (find-files "bin"
2026 (lambda (file stat)
2027 ;; Filter out symlinks.
2028 (eq? 'regular (stat:type stat)))
2029 #:stat lstat))))
2030 (add-after 'unpack 'fix-paths
2031 (lambda _
2032 (define (substitute-program-names file)
2033 ;; e.g. ANSIBLE_PLAYBOOK = '/gnu/store/…/bin/ansible-playbook'
2034 (for-each
2035 (lambda (name)
2036 (let ((varname (string-upcase
2037 (string-map
2038 (lambda (c) (if (char=? c #\-) #\_ c))
2039 name))))
2040 (substitute* file
2041 (((string-append "^(" varname " = )'.*'") line prefix)
2042 (string-append prefix "'" (which name) "'")))))
2043 '("ansible-playbook" "encfs" "find" "fusermount"
2044 "umount" "gpg" "ansible" "which")))
2045 (for-each substitute-program-names
2046 '("bin/debops"
2047 "bin/debops-padlock"
2048 "bin/debops-task"
2049 "debops/__init__.py"
2050 "debops/cmds/__init__.py"))
2051 #t)))))
2052 (home-page "https://www.debops.org/")
2053 (synopsis "Collection of general-purpose Ansible roles")
2054 (description "The Ansible roles provided by that can be used to manage
2055Debian or Ubuntu hosts. In addition, a default set of Ansible playbooks can
2056be used to apply the provided roles in a controlled way, using Ansible
2057inventory groups.
2058
2059The roles are written with a high customization in mind, which can be done
2060using Ansible inventory. This way the role and playbook code can be shared
2061between multiple environments, with different configuration in to each one.
2062
2063Services can be managed on a single host, or spread between multiple hosts.
2064DebOps provides support for different SQL and NoSQL databases, web servers,
2065programming languages and specialized applications useful in a data center
2066environment or in a cluster. The project can also be used to deploy
2067virtualization environments using KVM/libvirt, Docker or LXC technologies to
2068manage virtual machines and/or containers.")
2069 (license license:gpl3+)))
2070
2b6164f0
OP
2071(define-public emacs-ansible-doc
2072 (let ((commit "86083a7bb2ed0468ca64e52076b06441a2f8e9e0"))
2073 (package
2074 (name "emacs-ansible-doc")
2075 (version (git-version "0.4" "1" commit))
2076 (source
2077 (origin
2078 (method git-fetch)
2079 (uri (git-reference
2080 (url "https://github.com/lunaryorn/ansible-doc.el")
2081 (commit commit)))
2082 (file-name (git-file-name name version))
2083 (sha256
2084 (base32
2085 "0lap404ch74w99n3xip176jr42b38xhyzkfnkyqg0g3wk2cd3aq8"))))
2086 (build-system emacs-build-system)
2087 ;; Unmaintained by upstream.
2088 (home-page "https://github.com/lunaryorn/ansible-doc.el")
2089 (synopsis "Ansible documentation for Emacs")
2090 (description
2091 "This package provides an Ansible documentation for GNU Emacs.
2092
2093@code{ansible-doc} allows you to view the documentation of an Ansible
2094module and @code{ansible-doc-mode} minor mode adds documentation
2095lookup to YAML Mode. You could enable the mode with @code{(add-hook
2096'yaml-mode-hook #'ansible-doc-mode)}.")
2097 (license license:gpl3+))))
2098
44157e9f
EB
2099(define-public cpulimit
2100 (package
2101 (name "cpulimit")
2102 (version "0.2")
2103 (source
2104 (origin
aa372292
TGR
2105 (method git-fetch)
2106 (uri (git-reference
2107 (url "https://github.com/opsengine/cpulimit.git")
2108 (commit (string-append "v" version))))
2109 (file-name (git-file-name name version))
44157e9f 2110 (sha256
aa372292 2111 (base32 "1dz045yhcsw1rdamzpz4bk8mw888in7fyqk1q1b3m1yk4pd1ahkh"))))
44157e9f
EB
2112 (build-system gnu-build-system)
2113 (arguments
2114 `(#:phases (modify-phases %standard-phases
2115 (delete 'configure)
cb8ba848
MW
2116 (replace 'build
2117 (lambda _
2118 (invoke "make" "CC=gcc" "-Csrc")))
2119 (replace 'check
2120 (lambda _
2121 (invoke "make" "CC=gcc" "-Ctests")))
2122 (replace 'install
2123 (lambda* (#:key outputs #:allow-other-keys)
2124 (let* ((out (assoc-ref outputs "out"))
2125 (bin (string-append out "/bin")))
2126 (install-file "src/cpulimit" bin))
2127 #t)))))
44157e9f
EB
2128 (home-page "https://github.com/opsengine/cpulimit")
2129 (synopsis "Limit CPU usage")
2130 (description
2131 "Cpulimit limits the CPU usage of a process. It does not change the nice
2132value or other scheduling priority settings, but the real CPU usage, and is
2133able to adapt itself dynamically to the overall system load. Children
2134processes and threads of the specified process may optionally share the same
2135limits.")
2136 (license license:gpl2+)))
2328b47c
EB
2137
2138(define-public autojump
2139 (package
2140 (name "autojump")
0e684357 2141 (version "22.5.3")
2328b47c
EB
2142 (source
2143 (origin
24d459ce
TGR
2144 (method git-fetch)
2145 (uri (git-reference
2146 (url "https://github.com/wting/autojump.git")
2147 (commit (string-append "release-v" version))))
2148 (file-name (git-file-name name version))
2328b47c 2149 (sha256
0e684357 2150 (base32 "1rgpsh70manr2dydna9da4x7p8ahii7dgdgwir5fka340n1wrcws"))))
2328b47c 2151 (build-system gnu-build-system)
24d459ce 2152 (native-inputs ; for tests
2328b47c
EB
2153 `(("python-mock" ,python-mock)
2154 ("python-pytest" ,python-pytest)))
2155 (inputs
2156 `(("python" ,python-wrapper)))
2157 (arguments
eb9dda9c
KK
2158 `(#:phases
2159 (modify-phases %standard-phases
24d459ce
TGR
2160 (add-after 'unpack 'make-git-checkout-writable
2161 ;; ‘install.py’ modifies files before installing them.
2162 (lambda _
2163 (for-each make-file-writable (find-files "."))
2164 #t))
eb9dda9c
KK
2165 (delete 'configure)
2166 (delete 'build)
2167 (replace 'check
2168 (lambda _
2169 (invoke "python" "tests/unit/autojump_utils_test.py")))
2170 (replace 'install
2171 (lambda* (#:key outputs #:allow-other-keys)
2172 (setenv "SHELL" (which "bash"))
2173 (invoke "python" "install.py"
2174 (string-append "--destdir="
2175 (assoc-ref outputs "out"))))))))
2328b47c 2176 (home-page "https://github.com/wting/autojump")
8f65585b 2177 (synopsis "Shell extension for file system navigation")
2328b47c 2178 (description
8f65585b 2179 "Autojump provides a faster way to navigate your file system, with a \"cd
2328b47c
EB
2180command that learns\". It works by maintaining a database of the directories
2181you use the most from the command line and allows you to \"jump\" to
2182frequently used directories by typing only a small pattern.")
2183 (license license:gpl3+)))
765973cd 2184
1ca0ac1e
EB
2185(define-public fasd
2186 (package
2187 (name "fasd")
2188 (version "1.0.1")
2189 (source (origin
2190 (method git-fetch)
2191 (uri (git-reference
2192 (url "https://github.com/clvv/fasd.git")
2193 (commit version)))
2194 (file-name (git-file-name name version))
2195 (sha256
2196 (base32
2197 "1awi71jdv3mhjrmar2d4z1i90kn7apd7aq1w31sh6w4yibz9kiyj"))))
2198 (build-system gnu-build-system)
2199 (arguments
2200 `(#:phases (modify-phases %standard-phases
2201 (delete 'configure)) ;no configuration
2202 #:tests? #f ;no tests
2203 #:make-flags (list (string-append "PREFIX=" %output))))
2204 (home-page "https://github.com/clvv/fasd")
2205 (synopsis "Quick access to files and directories for shells")
2206 (description
2207 "Fasd (pronounced similar to \"fast\") is a command-line productivity
2208booster. Fasd offers quick access to files and directories for POSIX shells.
2209It is inspired by tools like autojump, z, and v. Fasd keeps track of files
2210and directories you have accessed so that you can quickly reference them in
2211the command line.")
2212 (license license:x11)))
2213
765973cd
LF
2214(define-public iftop
2215 (package
2216 (name "iftop")
2217 (version "1.0pre4")
2218 (source (origin
2219 (method url-fetch)
2220 (uri (string-append "http://www.ex-parrot.com/~pdw/iftop/download"
2221 "/iftop-" version ".tar.gz"))
2222 (sha256
2223 (base32
2224 "15sgkdyijb7vbxpxjavh5qm5nvyii3fqcg9mzvw7fx8s6zmfwczp"))))
2225 (build-system gnu-build-system)
2226 (inputs
2227 `(("libpcap" ,libpcap)
2228 ("ncurses" ,ncurses)))
2229 (synopsis "Monitor network usage")
2230 (description "Iftop does for network usage what @command{top} does
2231for CPU usage. It listens to network traffic on a named interface and
2232displays a table of current bandwidth usage by pairs of hosts.")
2233 (home-page "http://www.ex-parrot.com/~pdw/iftop/")
d4e21fbb 2234 (license license:gpl2+)))
f1957fc1
PP
2235
2236(define-public munge
2237 (package
2238 (name "munge")
5ee0e013 2239 (version "0.5.14")
f1957fc1
PP
2240 (source (origin
2241 (method url-fetch)
b52ae4de
EF
2242 (uri (string-append "https://github.com/dun/munge/releases/"
2243 "download/munge-" version "/munge-"
2244 version ".tar.xz"))
f1957fc1
PP
2245 (sha256
2246 (base32
5ee0e013 2247 "0h06sghb4rqvv1ywyd6mzsmbcgh712v6ygrff0gzm440y4ca41k6"))
8d080506
LC
2248 (modules '((guix build utils)))
2249 (snippet
2250 '(begin
2251 ;; Don't insist on write access to /var.
2252 (substitute* "src/etc/Makefile.in"
2253 (("\\$\\(INSTALL\\)(.*)localstatedir" _ middle)
5ee0e013
TGR
2254 (string-append "-$(INSTALL)" middle "localstatedir"))
2255 (("\\$\\(MKDIR_P\\) .*(local|run)statedir.*")
2256 ""))
8d080506 2257 #t))))
f1957fc1
PP
2258 (inputs
2259 `(("openssl" ,openssl)
2260 ("libgcrypt" ,libgcrypt)))
2261 (build-system gnu-build-system)
5ee0e013
TGR
2262 (arguments
2263 '(#:configure-flags
2264 (list "--localstatedir=/var"
2265 (string-append "--with-pkgconfigdir="
2266 (assoc-ref %outputs "out") "/lib/pkgconfig"))
2267 #:phases
2268 (modify-phases %standard-phases
2269 ;; XXX Many test series fail. Some might be fixable, others do no-no
2270 ;; things like invoking ‘sudo’.
2271 (add-after 'unpack 'skip-failing-tests
2272 (lambda _
2273 (for-each (lambda (test)
2274 (substitute* "t/Makefile.in"
2275 (((string-append test "\\.t ")) "")))
2276 (list "0100-munged-lock"
2277 "0010-basic"
2278 "0011-munged-cmdline"
2279 "0012-munge-cmdline"
2280 "0013-unmunge-cmdline"
2281 "0101-munged-security-socket"
2282 "0102-munged-security-keyfile"
2283 "0103-munged-security-logfile"
2284 "0110-munged-origin-addr"))
2285 #t)))))
b52ae4de 2286 (home-page "https://dun.github.io/munge/")
f1957fc1
PP
2287 (synopsis "Cluster computing authentication service")
2288 (description
2289 "Munge is an authentication service for creating and validating
2290credentials. It allows a process to authenticate the UID and GID of another
2291local or remote process within a group of hosts having common users and
2292groups. These hosts form a security realm that is defined by a shared
2293cryptographic key. Clients within this security realm can create and validate
2294credentials without the use of root privileges, reserved ports, or
2295platform-specific methods.")
2296 (license license:gpl3+)))
3d7a157c
RW
2297
2298(define-public audit
2299 (package
2300 (name "audit")
00f81f83 2301 (home-page "https://people.redhat.com/sgrubb/audit/")
b4e1f1ae 2302 (version "2.8.5")
3d7a157c
RW
2303 (source (origin
2304 (method url-fetch)
fe2f0166 2305 (uri (string-append home-page "audit-" version ".tar.gz"))
3d7a157c
RW
2306 (sha256
2307 (base32
b4e1f1ae 2308 "1dzcwb2q78q7x41shcachn7f4aksxbxd470yk38zh03fch1l2p8f"))))
3d7a157c 2309 (build-system gnu-build-system)
3d7a157c 2310 (arguments
8938b369
MB
2311 `(#:configure-flags (list "--with-python=no"
2312 "--disable-static")))
3d7a157c
RW
2313 (inputs
2314 `(("openldap" ,openldap)
1bafad56 2315 ("gnutls" ,gnutls)
3d7a157c
RW
2316 ("sasl" ,cyrus-sasl)))
2317 (synopsis "User-space component to the Linux auditing system")
2318 (description
2319 "auditd is the user-space component to the Linux auditing system, which
2320allows logging of system calls made by user-land processes. It's responsible
2321for writing audit records to the disk. Viewing the logs is done with the
2322@code{ausearch} or @code{aureport} utilities. Configuring the audit rules is
2323done with the @code{auditctl} utility.")
2324 (license license:gpl2+)))
d0457553
TUBK
2325
2326(define-public nmap
2327 (package
2328 (name "nmap")
8895b2e0 2329 (version "7.80")
d0457553
TUBK
2330 (source (origin
2331 (method url-fetch)
2332 (uri (string-append "https://nmap.org/dist/nmap-" version
2333 ".tar.bz2"))
2334 (sha256
2335 (base32
8895b2e0 2336 "1aizfys6l9f9grm82bk878w56mg0zpkfns3spzj157h98875mypw"))
d0457553
TUBK
2337 (modules '((guix build utils)))
2338 (snippet
6cbee49d
MW
2339 '(begin
2340 (for-each delete-file-recursively
2341 ;; Remove bundled lua, pcap, and pcre libraries.
2342 ;; FIXME: Remove bundled liblinear once packaged.
2343 '("liblua"
2344 "libpcap"
2345 "libpcre"
2346 ;; Remove pre-compiled binares.
2347 "mswin32"))
2348 #t))))
d0457553
TUBK
2349 (build-system gnu-build-system)
2350 (inputs
2351 `(("openssl" ,openssl)
2352 ("libpcap" ,libpcap)
2353 ("pcre" ,pcre)
2354 ("lua" ,lua)
069d0b7f
MB
2355 ("zlib" ,zlib) ;for NSE compression support
2356
d0457553
TUBK
2357 ;; For 'ndiff'.
2358 ("python" ,python-2)))
2359
2360 ;; TODO Add zenmap output.
2361 (outputs '("out" "ndiff"))
2362 (arguments
cc729d25 2363 `(#:configure-flags '("--without-zenmap")
d0457553
TUBK
2364 #:phases
2365 (modify-phases %standard-phases
f4dc22bc
MB
2366 (add-after 'configure 'patch-Makefile
2367 (lambda _
2368 (substitute* "Makefile"
2369 ;; Do not attempt to build lua.
2370 (("build-dnet build-lua") "build-dnet"))
2371 #t))
d0457553
TUBK
2372 (replace 'install
2373 (lambda* (#:key outputs #:allow-other-keys)
2374 (define (make out . args)
cb8ba848
MW
2375 (apply invoke "make"
2376 (string-append "prefix=" out)
2377 args))
d0457553 2378 (define (python-path dir)
cc729d25
EF
2379 (string-append dir "/lib/python"
2380 ,(version-major+minor
2381 (package-version python))
2382 "/site-packages"))
d0457553
TUBK
2383 (let ((out (assoc-ref outputs "out"))
2384 (ndiff (assoc-ref outputs "ndiff")))
2385 (for-each mkdir-p (list out ndiff))
2386 (make out
2387 "install-nmap"
2388 "install-nse"
2389 "install-ncat"
2390 "install-nping")
2391 (make ndiff "install-ndiff")
2392 (wrap-program (string-append ndiff "/bin/ndiff")
2393 `("PYTHONPATH" prefix
cb8ba848
MW
2394 (,(python-path ndiff)))))
2395 #t))
d0457553
TUBK
2396 ;; These are the tests that do not require network access.
2397 (replace 'check
cb8ba848
MW
2398 (lambda _ (invoke "make"
2399 "check-nse"
2400 "check-ndiff"
2401 "check-dns"))))
d0457553
TUBK
2402 ;; Nmap can't cope with out-of-source building.
2403 #:out-of-source? #f))
2404 (home-page "https://nmap.org/")
2405 (synopsis "Network discovery and security auditing tool")
2406 (description
2407 "Nmap (\"Network Mapper\") is a network discovery and security auditing
2408tool. It is also useful for tasks such as network inventory, managing service
2409upgrade schedules, and monitoring host or service uptime. It also provides an
2410advanced netcat implementation (ncat), a utility for comparing scan
2411results (ndiff), and a packet generation and response analysis tool (nping).")
2412 ;; This package uses nmap's bundled versions of libdnet and liblinear, which
2413 ;; both use a 3-clause BSD license.
2414 (license (list license:nmap license:bsd-3))))
1a0346f0
P
2415
2416(define-public dstat
2417 (package
2418 (name "dstat")
ad20da2e 2419 (version "0.7.4")
fc204d24
TGR
2420 (source
2421 (origin
2422 (method git-fetch)
2423 (uri (git-reference
2424 (url "https://github.com/dagwieers/dstat.git")
ad20da2e 2425 (commit (string-append "v" version))))
fc204d24
TGR
2426 (file-name (git-file-name "dstat" version))
2427 (sha256
10a32973
TGR
2428 (base32 "1qnmkhqmjd1m3if05jj29dvr5hn6kayq9bkkkh881w472c0zhp8v"))
2429 (patches (search-patches "dstat-fix-crash-when-specifying-delay.patch"
2430 "dstat-skip-devices-without-io.patch"))))
1a0346f0
P
2431 (build-system gnu-build-system)
2432 (arguments
fc204d24 2433 `(#:tests? #f ; no make check
1a0346f0
P
2434 #:make-flags (let ((out (assoc-ref %outputs "out")))
2435 (list (string-append "DESTDIR=" out)
2436 "prefix=/"))
5cc5364e
TGR
2437 #:phases
2438 (modify-phases %standard-phases
fa67073f
TGR
2439 (add-after 'unpack 'fix-python3-DeprecationWarning
2440 (lambda _
2441 (substitute* "dstat"
2442 (("collections") "collections.abc"))
2443 #t))
5cc5364e
TGR
2444 (delete 'configure) ; no configure script
2445 (add-after 'install 'wrap
2446 (lambda* (#:key outputs #:allow-other-keys)
2447 (let ((out (assoc-ref outputs "out")))
2448 (wrap-program (string-append out "/bin/dstat")
2449 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
2450 #t))))))
2451 (inputs
5cc5364e
TGR
2452 `(("python" ,python-wrapper)
2453 ("python-six" ,python-six)))
1a0346f0
P
2454 (synopsis "Versatile resource statistics tool")
2455 (description "Dstat is a versatile replacement for @command{vmstat},
2456@command{iostat}, @command{netstat}, and @command{ifstat}. Dstat overcomes
2457some of their limitations and adds some extra features, more counters and
2458flexibility. Dstat is handy for monitoring systems during performance tuning
2459tests, benchmarks or troubleshooting.
2460
2461Dstat allows you to view all of your system resources in real-time, you can,
2462e.g., compare disk utilization in combination with interrupts from your IDE
2463controller, or compare the network bandwidth numbers directly with the disk
2464throughput (in the same interval).")
2465 (home-page "http://dag.wiee.rs/home-made/dstat/")
c59f62e9 2466 (license license:gpl2+)))
0405e5f4
EB
2467
2468(define-public thefuck
2469 (package
2470 (name "thefuck")
68193087 2471 (version "3.29")
a0c693e1
TGR
2472 (source
2473 (origin
2474 (method git-fetch)
2475 (uri (git-reference
2476 (url "https://github.com/nvbn/thefuck.git")
2477 (commit version)))
2478 (file-name (git-file-name name version))
2479 (sha256
68193087 2480 (base32 "1qhxwjjgrzpqrqjv7l2847ywpln76lyd6j8bl9gz2r6kl0fx2fqs"))
a0c693e1 2481 (patches (search-patches "thefuck-test-environ.patch"))))
0405e5f4 2482 (build-system python-build-system)
1c1b67a3 2483 (arguments
bf5b6fb2
EB
2484 '(#:phases
2485 (modify-phases %standard-phases
2486 (delete 'check)
2487 (add-after 'install 'check
2488 (lambda* (#:key inputs outputs #:allow-other-keys)
2489 ;; Tests look for installed package
2490 (add-installed-pythonpath inputs outputs)
2491 ;; Some tests need write access to $HOME.
2492 (setenv "HOME" "/tmp")
2216b6f4
TGR
2493 (invoke "py.test" "-v")
2494 #t)))))
1c1b67a3 2495 (propagated-inputs
0405e5f4
EB
2496 `(("python-colorama" ,python-colorama)
2497 ("python-decorator" ,python-decorator)
2498 ("python-psutil" ,python-psutil)
2468ca04 2499 ("python-pyte" ,python-pyte)
0405e5f4 2500 ("python-six" ,python-six)))
2d1ac1d1 2501 (native-inputs
1c1b67a3
MB
2502 `(("python-mock" ,python-mock)
2503 ("python-pytest" ,python-pytest)
2468ca04 2504 ("python-pytest-mock" ,python-pytest-mock)))
0405e5f4
EB
2505 (home-page "https://github.com/nvbn/thefuck")
2506 (synopsis "Correct mistyped console command")
2507 (description
2508 "The Fuck tries to match a rule for a previous, mistyped command, creates
2509a new command using the matched rule, and runs it.")
2510 (license license:x11)))
61402398
JF
2511
2512(define-public di
2513 (package
2514 (name "di")
1a665022 2515 (version "4.47.3")
61402398
JF
2516 (source
2517 (origin
2518 (method url-fetch)
2519 (uri (string-append "https://gentoo.com/di/di-" version ".tar.gz"))
2520 (sha256
1a665022 2521 (base32 "0m4npba50sf5s61g5z3xd2r7937zwja941f2h3f081xi24c2hfck"))))
61402398
JF
2522 (build-system gnu-build-system)
2523 (arguments
ad9baf38 2524 `(#:tests? #f ; obscure test failures
61402398
JF
2525 #:phases
2526 (modify-phases %standard-phases
ad9baf38 2527 (delete 'configure) ; no configure script
61402398
JF
2528 (add-before 'build 'setup-environment
2529 (lambda* (#:key outputs #:allow-other-keys)
2530 (setenv "CC" "gcc")
2531 (setenv "prefix" (assoc-ref outputs "out"))
2532 #t)))
2533 #:make-flags (list "--environment-overrides")))
2534 (home-page "https://www.gentoo.com/di/")
2535 (synopsis "Advanced df like disk information utility")
2536 (description
36a4366d 2537 "@code{di} is a disk information utility, displaying everything that your
26c6de8b
TGR
2538@code{df} command does and more. It features the ability to display your disk
2539usage in whatever format you prefer. It is designed to be highly portable and
2540produce uniform output across heterogeneous networks.")
61402398 2541 (license license:zlib)))
5ec8b02d 2542
2543(define-public cbatticon
2544 (package
2545 (name "cbatticon")
50db7df4 2546 (version "1.6.10")
d8d910e6
TGR
2547 (source
2548 (origin
2549 (method git-fetch)
2550 (uri (git-reference
2551 (url "https://github.com/valr/cbatticon.git")
2552 (commit version)))
2553 (sha256
50db7df4 2554 (base32 "0ivm2dzhsa9ir25ry418r2qg2llby9j7a6m3arbvq5c3kaj8m9jr"))
d8d910e6 2555 (file-name (git-file-name name version))))
5ec8b02d 2556 (build-system gnu-build-system)
2557 (arguments
d8d910e6 2558 `(#:tests? #f ; no tests
5ec8b02d 2559 #:make-flags
2560 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2561 "CC=gcc")
2562 #:phases
2563 (modify-phases %standard-phases
d8d910e6 2564 (delete 'configure)))) ; no configure script
5ec8b02d 2565 (inputs
2566 `(("gtk+" ,gtk+)
b94a6ca0 2567 ("gettext" ,gettext-minimal)
5ec8b02d 2568 ("libnotify" ,libnotify)))
2569 (native-inputs
2570 `(("pkg-config" ,pkg-config)))
2571 (synopsis "Lightweight battery icon for the system tray")
2572 (description "cbatticon is a lightweight battery icon that displays
2573the status of your battery in the system tray.")
2574 (home-page "https://github.com/valr/cbatticon")
2575 (license license:gpl2+)))
c08533b2 2576
2577(define-public interrobang
2578 (let ((revision "1")
2579 (commit "896543735e1c99144765fdbd7b6e6b5afbd8b881"))
2580 (package
2581 (name "interrobang")
807a3099
TGR
2582 (version (git-version "0.0.0" revision commit))
2583 (source
2584 (origin
2585 (method git-fetch)
2586 (uri (git-reference
2587 (url "https://github.com/TrilbyWhite/interrobang.git")
2588 (commit commit)))
2589 (file-name (git-file-name name version))
2590 (sha256
2591 (base32 "1n13m70p1hfba5dy3i8hfclbr6k9q3d9dai3dg4jvhdhmxcpjzdf"))))
c08533b2 2592 (build-system gnu-build-system)
2593 (arguments
807a3099 2594 `(#:tests? #f ; no tests
c08533b2 2595 #:phases
2596 (modify-phases %standard-phases
807a3099 2597 (delete 'configure)) ; no configure script
c08533b2 2598 #:make-flags (list (string-append "PREFIX="
2599 (assoc-ref %outputs "out")))))
2600 (inputs
2601 `(("libx11" ,libx11)))
2602 (native-inputs
2603 `(("pkg-config" ,pkg-config)))
2604 (synopsis "Scriptable launcher menu")
2605 (description "Interrobang is a scriptable launcher menu with a customizable
2606shortcut syntax and completion options.")
2607 (home-page "https://github.com/TrilbyWhite/interrobang")
2608 (license license:gpl3+))))
94c5dc8c 2609
94c5dc8c
JD
2610(define-public pam-krb5
2611 (package
2612 (name "pam-krb5")
0e6c242b 2613 (version "4.8")
94c5dc8c
JD
2614 (source (origin
2615 (method url-fetch)
2616 (uri (string-append
ab213bfd
TGR
2617 "https://archives.eyrie.org/software/kerberos/"
2618 "pam-krb5-" version ".tar.xz"))
94c5dc8c
JD
2619 (sha256
2620 (base32
0e6c242b 2621 "1qjp8i1s9bz7g6kiqrkzzkxn5pfspa4sy53b6z40fqmdf9przdfb"))))
94c5dc8c
JD
2622 (build-system gnu-build-system)
2623 (arguments
2624 `(#:phases
2625 (modify-phases %standard-phases
2626 (add-before 'configure 'disable-tests
2627 (lambda _
2628 ;; The build container seems to interfere with some tests.
2629 (substitute* "tests/TESTS"
2630 (("module/basic\n") ""))
2631 (substitute* "tests/TESTS"
2632 (("pam-util/vector\n") ""))
2633 #t)))))
2634 (inputs
2635 `(("linux-pam" ,linux-pam)
2636 ("mit-krb5" ,mit-krb5)))
2637 (native-inputs
2638 `(("perl" ,perl)
2639 ("perl-test-pod" ,perl-test-pod))) ; required for tests
2640 (synopsis "Kerberos PAM module")
2641 (description
2642 "Pam-krb5 is a Kerberos PAM module for either MIT Kerberos or Heimdal.
2643It supports ticket refreshing by screen savers, configurable
2644authorization handling, authentication of non-local accounts for network
2645services, password changing, and password expiration, as well as all the
2646standard expected PAM features. It works correctly with OpenSSH, even
45298300
TGR
2647with @code{ChallengeResponseAuthentication} and @code{PrivilegeSeparation}
2648enabled, and supports extensive configuration either by PAM options or in
94c5dc8c
JD
2649krb5.conf or both. PKINIT is supported with recent versions of both MIT
2650Kerberos and Heimdal and FAST is supported with recent MIT Kerberos.")
eeb8b0e6 2651 (home-page "https://www.eyrie.org/~eagle/software/pam-krb5")
94c5dc8c
JD
2652 ;; Dual licenced under a homebrew non-copyleft OR GPL (any version)
2653 ;; However, the tarball does not contain a copy of the GPL, so unless
2654 ;; we put one in, we cannot distribute it under GPL without violating
2655 ;; clause requiring us to give all recipients a copy.
2656 (license license:gpl1+)))
2657
208e7434 2658(define (sunxi-tools-source version)
b04ca7a1 2659 (origin
43eb601f
TGR
2660 (method git-fetch)
2661 (uri (git-reference
2662 (url "https://github.com/linux-sunxi/sunxi-tools.git")
2663 (commit (string-append "v" version))))
b04ca7a1 2664 (sha256
43eb601f 2665 (base32 "04f3jqg8ww4jxsf9c6ddcdgy2xbhkyp0b3l5f1hvvbv94p81rjxd"))
b04ca7a1
DM
2666 (modules '((guix build utils)))
2667 (snippet
2668 ;; Remove binaries contained in the tarball which are only for the
2669 ;; target and can be regenerated anyway.
6cbee49d
MW
2670 '(begin
2671 (delete-file-recursively "bin")
2672 #t))
208e7434
DM
2673 (file-name (git-file-name "sunxi-tools" version))))
2674
2675(define sunxi-target-tools
2676 (package
2677 (name "sunxi-target-tools")
2678 (version "1.4.2")
2679 (build-system gnu-build-system)
2680 (source
2681 (sunxi-tools-source version))
2682 (arguments
2683 `(#:system "armhf-linux"
2684 #:tests? #f
2685 #:make-flags (list (string-append "PREFIX="
2686 (assoc-ref %outputs "out"))
2687 (string-append "CROSS_COMPILE=")
2688 "CC=gcc")
2689 #:phases
2690 (modify-phases %standard-phases
2691 (delete 'configure)
2692 (replace 'build
2693 (lambda* (#:key make-flags #:allow-other-keys)
2694 (apply invoke "make" "target-tools" make-flags)))
2695 (replace 'install
2696 (lambda* (#:key make-flags #:allow-other-keys)
2697 (apply invoke "make" "install-target-tools"
2698 make-flags))))))
2699 (home-page "https://github.com/linux-sunxi/sunxi-tools")
2700 (synopsis "Hardware management tools for Allwinner computers")
2701 (description "This package contains tools for Allwinner devices:
2702@enumerate
2703@item @command{sunxi-meminfo}: Prints memory bus settings.
2704@end enumerate")
2705 (license license:gpl2+)))
2706
2707(define-public sunxi-tools
2708 (package
2709 (name "sunxi-tools")
2710 (version "1.4.2")
2711 (source
2712 (sunxi-tools-source version))
b04ca7a1 2713 (native-inputs
208e7434
DM
2714 `(("sunxi-target-tools" ,sunxi-target-tools)
2715 ("pkg-config" ,pkg-config)))
b04ca7a1
DM
2716 (inputs
2717 `(("libusb" ,libusb)))
2718 (build-system gnu-build-system)
2719 (arguments
faa6bdf8 2720 `(#:tests? #f ; no tests exist
b04ca7a1
DM
2721 #:make-flags (list (string-append "PREFIX="
2722 (assoc-ref %outputs "out"))
208e7434 2723 (string-append "CROSS_COMPILE=disabled")
faa6bdf8 2724 "CC=gcc")
b04ca7a1
DM
2725 #:phases
2726 (modify-phases %standard-phases
b054b26a 2727 (delete 'configure)
faa6bdf8
DM
2728 (replace 'build
2729 (lambda* (#:key make-flags #:allow-other-keys)
cb8ba848 2730 (apply invoke "make" "tools" "misc" make-flags)))
b054b26a 2731 (replace 'install
208e7434
DM
2732 (lambda* (#:key inputs outputs make-flags #:allow-other-keys)
2733 ;; Those tools have been built for armhf but are part of the
2734 ;; installation in the upstream package. So do the same
2735 ;; here.
2736 (copy-recursively (assoc-ref inputs "sunxi-target-tools")
2737 (assoc-ref outputs "out"))
2738 (apply invoke "make" "install-tools" "install-misc"
cb8ba848 2739 make-flags))))))
b04ca7a1
DM
2740 (home-page "https://github.com/linux-sunxi/sunxi-tools")
2741 (synopsis "Hardware management tools for Allwinner computers")
2742 (description "This package contains tools for Allwinner devices:
2743@enumerate
2744@item @command{sunxi-fexc}, @command{bin2fex}, @command{fex2bin}: Compile
2745a textual description of a board (.fex) to a binary representation (.bin).
2746@item @command{sunxi-fel}: Puts an Allwinner device into FEL mode which
2747makes it register as a special USB device (rather than USB host).
2748You can then connect it to another computer and flash it from there.
2749@item @command{sunxi-nand-part}: Partitions NAND flash.
2750@item @command{sunxi-bootinfo}: Reads out boot0 and boot1 (Allwinner
2751bootloader) parameters.
2752@item @command{sunxi-pio}: Sets GPIO parameters and oscillates a GPIO
2753in order to be able to find it.
2754@item @command{sunxi-meminfo}: Prints memory bus settings.
b054b26a 2755@item @command{sunxi-nand-image-builder}: Prepares raw NAND images.
b04ca7a1
DM
2756@end enumerate")
2757 (license license:gpl2+)))
a054777e 2758
2759(define-public sedsed
2760 (package
2761 (name "sedsed")
bde99125 2762 (version "1.1")
a054777e 2763 (source
2764 (origin
7d6e8fda
TGR
2765 (method git-fetch)
2766 (uri (git-reference
2767 (url "https://github.com/aureliojargas/sedsed.git")
2768 (commit (string-append "v" version))))
2769 (file-name (git-file-name name version))
a054777e 2770 (sha256
bde99125 2771 (base32 "05cl35mwljdb9ynbbsfa8zx6ig8r0xncbg2cir9vwn5manndjj18"))))
a054777e 2772 (build-system python-build-system)
2773 (arguments
7d6e8fda 2774 `(#:tests? #f ; no tests
a054777e 2775 #:phases
2776 (modify-phases %standard-phases
2777 (add-after 'unpack 'patch-sed-in
2778 (lambda _
2779 (substitute* "sedsed.py"
2780 (("sedbin = 'sed'")
2781 (string-append "sedbin = '" (which "sed") "'")))
2782 #t))
2783 (delete 'build)
2784 (replace 'install
2785 (lambda* (#:key outputs #:allow-other-keys)
2786 (let* ((out (assoc-ref outputs "out"))
2787 (bin (string-append out "/bin")))
2788 ;; Just one file to copy around
2789 (install-file "sedsed.py" bin)
2790 #t)))
b7e26ec6 2791 (add-after 'wrap 'symlink
a054777e 2792 ;; Create 'sedsed' symlink to "sedsed.py".
2793 (lambda* (#:key outputs #:allow-other-keys)
2794 (let* ((out (assoc-ref outputs "out"))
2795 (bin (string-append out "/bin"))
2796 (sed (string-append bin "/sedsed"))
2797 (sedpy (string-append bin "/sedsed.py")))
b7e26ec6 2798 (symlink sedpy sed)
a054777e 2799 #t))))))
fbdabdad 2800 (home-page "https://aurelio.net/projects/sedsed")
a054777e 2801 (synopsis "Sed sed scripts")
2802 (description
975a0c15
TGR
2803 "@code{sedsed} can debug, indent, tokenize and HTMLize your @command{sed}
2804script.
a054777e 2805
975a0c15 2806In debug mode, it reads your script and adds extra commands to it. When
a054777e 2807executed you can see the data flow between the commands, revealing all the
975a0c15 2808magic sed performs on its internal buffers.
a054777e 2809
975a0c15 2810In indent mode, your script is reformatted with standard spacing.
a054777e 2811
975a0c15 2812In tokenize mode, you can see the elements of every command you use.
a054777e 2813
975a0c15 2814In HTMLize mode, your script is converted to a beautiful colored HTML file,
a054777e 2815with all the commands and parameters identified for your viewing pleasure.
2816
2817With sedsed you can master any sed script. No more secrets, no more hidden
2818buffers.")
2819 (license license:expat)))
d10fa5c7 2820
dca48d3c 2821(define-public igt-gpu-tools
d10fa5c7 2822 (package
dca48d3c 2823 (name "igt-gpu-tools")
bdd5fbaf 2824 (version "1.24")
e4d6746f
TGR
2825 (source
2826 (origin
2827 (method git-fetch)
2828 (uri (git-reference
2829 (url "https://gitlab.freedesktop.org/drm/igt-gpu-tools.git")
2830 (commit (string-append "igt-gpu-tools-" version))))
2831 (file-name (git-file-name name version))
2832 (sha256
bdd5fbaf 2833 (base32 "1gpdjs5aj6vsnzwcjvw5bb120lgffvvshi4202phr0bzw3b92ky8"))))
d10fa5c7
RW
2834 (build-system gnu-build-system)
2835 (arguments
dca48d3c 2836 `(#:tests? #f ; many of the tests try to load kernel modules
d10fa5c7
RW
2837 #:phases
2838 (modify-phases %standard-phases
355ba48c 2839 (replace 'bootstrap
d10fa5c7 2840 (lambda _
8e7e6170 2841 ;; Don't run configure in this phase.
d10fa5c7 2842 (setenv "NOCONFIGURE" "1")
8e7e6170 2843 (invoke "sh" "autogen.sh"))))))
d10fa5c7 2844 (inputs
10082d30 2845 `(("cairo" ,cairo)
bdd5fbaf 2846 ("elfutils" ,elfutils) ; libdw
10082d30
TGR
2847 ("eudev" ,eudev)
2848 ("glib" ,glib)
2849 ("kmod" ,kmod)
d10fa5c7
RW
2850 ("libdrm" ,libdrm)
2851 ("libpciaccess" ,libpciaccess)
d10fa5c7
RW
2852 ("libunwind" ,libunwind)
2853 ("libxrandr" ,libxrandr)
10082d30
TGR
2854 ("openssl" ,openssl)
2855 ("procps" ,procps)
2856 ("util-macros" ,util-macros)))
d10fa5c7
RW
2857 (native-inputs
2858 `(("autoconf" ,autoconf)
2859 ("automake" ,automake)
2860 ("libtool" ,libtool)
2861 ("pkg-config" ,pkg-config)))
2862 (home-page "https://cgit.freedesktop.org/xorg/app/intel-gpu-tools/")
2863 (synopsis "Tools for development and testing of the Intel DRM driver")
dca48d3c 2864 (description "IGT GPU Tools is a collection of tools for development and
d10fa5c7
RW
2865testing of the Intel DRM driver. There are many macro-level test suites that
2866get used against the driver, including xtest, rendercheck, piglit, and
2867oglconform, but failures from those can be difficult to track down to kernel
2868changes, and many require complicated build procedures or specific testing
dca48d3c 2869environments to get useful results. Therefore, IGT GPU Tools includes
d10fa5c7
RW
2870low-level tools and tests specifically for development and testing of the
2871Intel DRM Driver.")
9f375a4c 2872 (supported-systems '("i686-linux" "x86_64-linux"))
d10fa5c7 2873 (license license:expat)))
c1aba1a7 2874
dca48d3c
TGR
2875(define-public intel-gpu-tools
2876 (deprecated-package "intel-gpu-tools" igt-gpu-tools))
2877
b611f9c2
BS
2878(define-public fabric
2879 (package
2880 (name "fabric")
b8eeaaa2 2881 (version "1.14.1")
b611f9c2
BS
2882 (source
2883 (origin
2884 (method url-fetch)
2885 (uri (pypi-uri "Fabric" version))
2886 (sha256
2887 (base32
b8eeaaa2 2888 "1a3ndlpdw6bhn8fcw1jgznl117a8pnr84az9rb5fwnrypf1ph2b6"))))
b611f9c2
BS
2889 (build-system python-build-system)
2890 (arguments
e68e4a90
BS
2891 `(#:python ,python-2 ; Python 2 only
2892 #:phases
2893 (modify-phases %standard-phases
2894 (replace 'check
2895 (lambda _
2896 (invoke
2897 "nosetests" "-v" "tests/"
2898 ;; This test hangs indefinitely when run on a single core VM
2899 ;; (see GNU bug #26647 and Debian bug #850230).
2900 "--exclude=test_nested_execution_with_explicit_ports"
2901 ;; This test randomly fails in certain environments causing too
2902 ;; much noise to be useful (see Debian bug #854686).
2903 "--exclude=test_should_use_sentinel_for_tasks_that_errored"))))))
1b5b24c9 2904 (native-inputs
e68e4a90
BS
2905 `(("python2-fudge" ,python2-fudge) ; Requires < 1.0
2906 ("python2-jinja2" ,python2-jinja2) ; Requires < 3.0
2907 ("python2-nose" ,python2-nose) ; Requires < 2.0
a62d455d
RJ
2908 ("python2-pynacl" ,python2-pynacl)
2909 ("python2-bcrypt" ,python2-bcrypt)))
b611f9c2 2910 (propagated-inputs
b611f9c2 2911 `(("python2-paramiko" ,python2-paramiko)))
a06faea9 2912 (home-page "https://www.fabfile.org/")
b611f9c2
BS
2913 (synopsis "Simple Pythonic remote execution and deployment tool")
2914 (description
2915 "Fabric is designed to upload files and run shell commands on a number of
2916servers in parallel or serially. These commands are grouped in tasks (which
2917are regular Python functions) and specified in a @dfn{fabfile}.
2918
2919It is similar to Capistrano, except it's implemented in Python and doesn't
2920expect you to be deploying Rails applications. Fabric is a simple, Pythonic
2921tool for remote execution and deployment.")
2922 (license license:bsd-2)))
6e75ea48
EJ
2923
2924(define-public neofetch
73656471
OP
2925 (let ((commit "501d6b7594296d9eac8943140f8581daf555873d"))
2926 (package
2927 (name "neofetch")
2928 (version (git-version "6.1.0" "1" commit))
2929 (source (origin
2930 (method git-fetch)
2931 (uri (git-reference
2932 (url "https://github.com/dylanaraps/neofetch")
2933 (commit commit)))
2934 (file-name (git-file-name name version))
2935 (sha256
2936 (base32
2937 "1h5md9jimyc6z4d7w66j27hn8qghzyxgpkh5h9dclzxpp5cs8whb"))))
2938 (build-system gnu-build-system)
2939 (arguments
2940 `(#:tests? #f ; there are no tests
2941 #:make-flags
2942 (list (string-append "PREFIX=" %output))
2943 #:phases
2944 (modify-phases %standard-phases
2945 (delete 'configure)))) ; no configure script
2946 (home-page "https://github.com/dylanaraps/neofetch")
2947 (synopsis "System information script")
2948 (description "Neofetch is a command-line system information tool written in
2cd8e6e0 2949Bash. Neofetch displays information about your system next to an image, your OS
6e75ea48
EJ
2950logo, or any ASCII file of your choice. The main purpose of Neofetch is to be
2951used in screenshots to show other users what operating system or distribution
2952you are running, what theme or icon set you are using, etc.")
73656471 2953 (license license:expat))))
a76ca052 2954
67648704 2955(define-public screenfetch
9dbda847
TGR
2956 (package
2957 (name "screenfetch")
89f51a9d 2958 (version "3.9.1")
9dbda847
TGR
2959 (source (origin
2960 (method git-fetch)
2961 (uri (git-reference
2962 (url "https://github.com/KittyKatt/screenFetch")
2963 (commit (string-append "v" version))))
2964 (file-name (git-file-name name version))
2965 (sha256
2966 (base32
89f51a9d 2967 "04l8aqr474pb115nagn9f6y48jw92n1qfszgw7dbhgl4mpn95lcr"))))
9dbda847
TGR
2968 (build-system trivial-build-system)
2969 (arguments
2970 `(#:modules ((guix build utils))
2971 #:builder
2972 (begin
2973 (use-modules (guix build utils))
2974 (let ((source (assoc-ref %build-inputs "source"))
2975 (out (assoc-ref %outputs "out")))
2976 (mkdir-p (string-append out "/bin/"))
2977 (copy-file (string-append source "/screenfetch-dev")
2978 (string-append out "/bin/screenfetch"))
2979 (install-file (string-append source "/screenfetch.1")
2980 (string-append out "/man/man1/"))
2981 (install-file (string-append source "/COPYING")
2982 (string-append out "/share/doc/" ,name "-" ,version))
2983 (substitute* (string-append out "/bin/screenfetch")
2984 (("/usr/bin/env bash")
2985 (string-append (assoc-ref %build-inputs "bash")
2986 "/bin/bash")))
2987 (wrap-program
67648704 2988 (string-append out "/bin/screenfetch")
9dbda847
TGR
2989 `("PATH" ":" prefix
2990 (,(string-append (assoc-ref %build-inputs "bc") "/bin:"
2991 (assoc-ref %build-inputs "scrot") "/bin:"
2992 (assoc-ref %build-inputs "xdpyinfo") "/bin"
2993 (assoc-ref %build-inputs "xprop") "/bin"))))
2994 (substitute* (string-append out "/bin/screenfetch")
2995 (("#!#f")
2996 (string-append "#!" (assoc-ref %build-inputs "bash")
2997 "/bin/bash")))))))
2998 (inputs
2999 `(("bash" ,bash)
3000 ("bc" ,bc)
3001 ("scrot" ,scrot)
3002 ("xdpyinfo" ,xdpyinfo)
3003 ("xprop" ,xprop)))
3004 (home-page "https://github.com/KittyKatt/screenFetch")
3005 (synopsis "System information script")
3006 (description "Bash screenshot information tool which can be used to
67648704
JK
3007generate those nifty terminal theme information and ASCII distribution logos in
3008everyone's screenshots nowadays.")
9dbda847 3009 (license license:gpl3)))
67648704 3010
a76ca052
EJ
3011(define-public nnn
3012 (package
3013 (name "nnn")
5c9a3976 3014 (version "2.8.1")
eb5a6643
TGR
3015 (source
3016 (origin
3017 (method url-fetch)
3018 (uri (string-append "https://github.com/jarun/nnn/releases/download/v"
16572d0e 3019 version "/nnn-v" version ".tar.gz"))
eb5a6643 3020 (sha256
5c9a3976 3021 (base32 "1g47bndxld875d0xb3pgmlw223mz47p1xcvwym861y6l4zkgiyp0"))))
a76ca052 3022 (build-system gnu-build-system)
eb5a6643
TGR
3023 (inputs
3024 `(("ncurses" ,ncurses)
3025 ("readline" ,readline)))
3026 (native-inputs
3027 `(("pkg-config" ,pkg-config)))
a76ca052 3028 (arguments
eb5a6643 3029 '(#:tests? #f ; no tests
a76ca052 3030 #:phases
a76ca052 3031 (modify-phases %standard-phases
eb5a6643 3032 (delete 'configure)) ; no configure script
a76ca052
EJ
3033 #:make-flags
3034 (list
3035 (string-append "PREFIX="
3036 (assoc-ref %outputs "out"))
a76ca052
EJ
3037 "CC=gcc")))
3038 (home-page "https://github.com/jarun/nnn")
3039 (synopsis "Terminal file browser")
3040 (description "@command{nnn} is a fork of @command{noice}, a blazing-fast
3041lightweight terminal file browser with easy keyboard shortcuts for
3042navigation, opening files and running tasks. There is no config file and
3043mime associations are hard-coded. The incredible user-friendliness and speed
3044make it a perfect utility on modern distros.")
3045 (license license:bsd-2)))
58989684
CAW
3046
3047(define-public thermald
3048 (package
3049 (name "thermald")
63471410 3050 (version "1.9.1")
58989684
CAW
3051 (source
3052 (origin
d09e84c2
EF
3053 (method git-fetch)
3054 (uri (git-reference
3055 (url "https://github.com/01org/thermal_daemon")
3056 (commit (string-append "v" version))))
3057 (file-name (git-file-name name version))
3058 (sha256
63471410 3059 (base32 "0iagc3jqpnh6q2fa1gx4wx6r8qg0556j60xr159zqg95djr4dv99"))))
58989684
CAW
3060 (build-system gnu-build-system)
3061 (arguments
12007839 3062 `(#:configure-flags
58989684
CAW
3063 (let ((out (assoc-ref %outputs "out")))
3064 (list (string-append "--sysconfdir="
3065 out "/etc")
58989684
CAW
3066 (string-append "--with-dbus-sys-dir="
3067 out "/etc/dbus-1/system.d")
3068 "--localstatedir=/var"))))
3069 (native-inputs
3070 `(("autoconf" ,autoconf)
3071 ("automake" ,automake)
3072 ("glib" ,glib "bin") ; for glib-genmarshal, etc.
3073 ("pkg-config" ,pkg-config)))
3074 (inputs
3075 `(("dbus-glib" ,dbus-glib)
3076 ("libxml2" ,libxml2)))
3077 (home-page "https://01.org/linux-thermal-daemon/")
3078 (synopsis "CPU scaling for thermal management")
3079 (description "The Linux Thermal Daemon helps monitor and control temperature
3080on systems running the Linux kernel.")
b6315bc0 3081 ;; arm and aarch64 don't have cpuid.h.
86ee7625 3082 (supported-systems '("i686-linux" "x86_64-linux"))
58989684 3083 (license license:gpl2+)))
d7c64ad5
LF
3084
3085(define-public masscan
3086 (package
3087 (name "masscan")
b4bf9516 3088 (version "1.0.5")
e956d76d
TGR
3089 (source
3090 (origin
3091 (method git-fetch)
3092 (uri (git-reference
3093 (url "https://github.com/robertdavidgraham/masscan.git")
3094 (commit version)))
3095 (file-name (git-file-name name version))
3096 (sha256
3097 (base32 "0q0c7bsf0pbl8napry1qyg0gl4pd8wn872h4mz9b56dx4rx90vqg"))))
d7c64ad5
LF
3098 (build-system gnu-build-system)
3099 (inputs
3100 `(("libpcap" ,libpcap)))
3101 (arguments
3102 '(#:test-target "regress"
b4bf9516
TGR
3103 #:make-flags
3104 (list "CC=gcc"
3105 (string-append "PREFIX=" (assoc-ref %outputs "out")))
d7c64ad5
LF
3106 #:phases
3107 (modify-phases %standard-phases
b4bf9516 3108 (delete 'configure) ; no ./configure script
d7c64ad5
LF
3109 (add-after 'unpack 'patch-path
3110 (lambda* (#:key outputs inputs #:allow-other-keys)
3111 (let* ((out (assoc-ref outputs "out"))
3112 (pcap (assoc-ref inputs "libpcap")))
3113 (substitute* "src/rawsock-pcap.c"
3114 (("libpcap.so") (string-append pcap "/lib/libpcap.so")))
3115 #t))))))
3116 (synopsis "TCP port scanner")
3117 (description "MASSCAN is an asynchronous TCP port scanner. It can detect
3118open ports, and also complete the TCP connection and interact with the remote
3119application, collecting the information received.")
3120 (home-page "https://github.com/robertdavidgraham/masscan")
b4bf9516
TGR
3121 ;; 'src/siphash24.c' is the SipHash reference implementation, which
3122 ;; bears a CC0 Public Domain Dedication.
d7c64ad5 3123 (license license:agpl3+)))
82d57f12
TGR
3124
3125(define-public hungrycat
3126 (package
3127 (name "hungrycat")
3128 (version "0.4.1")
3129 (source (origin
3130 (method url-fetch)
3131 (uri (string-append "https://github.com/jwilk/hungrycat/"
3132 "releases/download/" version "/"
e20796dc 3133 "hungrycat-" version ".tar.gz"))
82d57f12
TGR
3134 (sha256
3135 (base32
3136 "03fc1zsrf99lvxa7b4ps6pbi43304wbxh1f6ci4q0vkal370yfwh"))))
3137 (build-system gnu-build-system)
3138 (native-inputs
3139 ;; For tests.
3140 `(("python" ,python-wrapper)
3141 ("python-nose" ,python-nose)))
3142 (arguments
3143 `(#:test-target "test"))
3144 (synopsis "A single tool that combines @command{cat} & @command{rm}")
3145 (description
3146 "hungrycat prints the contents of a file to standard output, while
3147simultaneously freeing the disk space it occupied. It is useful if you need
3148to process a large file, don't have enough space to store both the input and
3149output files, and don't need the input file afterwards.
3150While similar in principle to running @command{cat} immediately followed by
3151@command{rm}, @command{hungrycat} actually frees blocks as soon as they are
3152printed instead of after the entire file has been read, which is often too
3153late.")
3154 (home-page "https://jwilk.net/software/hungrycat")
3155 (license license:expat)))
3ebf2c29
PAR
3156
3157(define-public launchmon
3158 (package
3159 (name "launchmon")
3160 (version "1.0.2")
3161 (source (origin
3162 (method url-fetch)
3163 (uri (string-append
3164 "https://github.com/LLNL/LaunchMON/releases/download/v"
f44eca94 3165 version "/launchmon-v" version ".tar.gz"))
3ebf2c29
PAR
3166 (sha256
3167 (base32
3168 "0fm3nd9mydm9v2bf7bh01dbgrfnpwkapxa3dsvy3x1z0rz61qc0x"))))
3169 (build-system gnu-build-system)
3170 (inputs
3171 `(("mpi" ,openmpi)
3172 ("munge" ,munge)
3173 ("boost" ,boost)
3174 ("libelf" ,libelf)
3175 ("libgcrypt" ,libgcrypt)
3176 ("libgpg-error" ,libgpg-error)))
3177 (synopsis "Infrastructue for large scale tool daemon launching")
3178 (description
3179 "LaunchMON is a software infrastructure that enables HPC run-time
3180tools to co-locate tool daemons with a parallel job. Its API allows a
3181tool to identify all the remote processes of a job and to scalably
3182launch daemons into the relevant nodes.")
3183 (home-page "https://github.com/LLNL/LaunchMON")
3184 (supported-systems '("i686-linux" "x86_64-linux"))
3185 (license license:lgpl2.1)))
541dac8a
PAR
3186
3187(define-public spindle
3188 (package
3189 (name "spindle")
3190 (version "0.10")
3191 (source (origin
3192 ;; We use git checkout to avoid github auto-generated tarballs
3193 (method git-fetch)
3194 (uri (git-reference
3195 (url "https://github.com/hpc/Spindle.git")
3196 (commit (string-append "v" version))))
3197 (file-name (git-file-name name version))
3198 (sha256
3199 (base32
3200 "15n3ay0qq81r5v7fif61q1vdjcq44pp2nynkh3fvbzc9fj3c39wd"))))
3201 (build-system gnu-build-system)
3202 (arguments '(#:configure-flags '("--enable-sec-launchmon"
3203 "--enable-sec-munge"
3204 "--enable-sec-none")))
3205 (inputs
3206 `(("mpi" ,openmpi)
3207 ("munge" ,munge)
3208 ("launchmon" ,launchmon)
3209 ("libgcrypt" ,libgcrypt)))
3210 (synopsis "Scalable library loading in HPC environments")
3211 (description
3212 "Spindle is a tool for improving the performance of dynamic library and
3213Python loading in HPC environments.")
3214 (home-page "https://github.com/hpc/Spindle")
785f40df
EF
3215 ;; This package supports x86_64 and PowerPC64
3216 (supported-systems '("x86_64-linux"))
541dac8a 3217 (license license:lgpl2.1)))
bbc94ed0
PN
3218
3219(define-public inxi-minimal
3220 (let ((real-name "inxi"))
3221 (package
3222 (name "inxi-minimal")
ce0ca762 3223 (version "3.0.37-1")
bbc94ed0
PN
3224 (source
3225 (origin
b740a305
TGR
3226 (method git-fetch)
3227 (uri (git-reference
3228 (url "https://github.com/smxi/inxi")
3229 (commit version)))
7458ceac 3230 (file-name (git-file-name real-name version))
bbc94ed0 3231 (sha256
ce0ca762 3232 (base32 "15wvj9w601ci3bavd1hk5qlm8dfm7a7cjglczk29yir5yw2jww3f"))))
bbc94ed0
PN
3233 (build-system trivial-build-system)
3234 (inputs
a49bbaa6
EF
3235 `(("bash" ,bash-minimal)
3236 ("perl" ,perl)
3237 ("procps" ,procps)))
bbc94ed0 3238 (native-inputs
b740a305 3239 `(("gzip" ,gzip)))
bbc94ed0
PN
3240 (arguments
3241 `(#:modules
3242 ((guix build utils)
3243 (ice-9 match)
3244 (srfi srfi-26))
3245 #:builder
3246 (begin
3247 (use-modules (guix build utils)
3248 (ice-9 match)
3249 (srfi srfi-26))
3250 (setenv "PATH" (string-append
3251 (assoc-ref %build-inputs "bash") "/bin" ":"
3252 (assoc-ref %build-inputs "gzip") "/bin" ":"
b740a305
TGR
3253 (assoc-ref %build-inputs "perl") "/bin" ":"))
3254 (copy-recursively (assoc-ref %build-inputs "source")
3255 ,(string-append real-name "-" version))
bbc94ed0
PN
3256 (with-directory-excursion ,(string-append real-name "-" version)
3257 (with-fluids ((%default-port-encoding #f))
3258 (substitute* "inxi" (("/usr/bin/env perl") (which "perl"))))
3259 (let ((bin (string-append %output "/bin")))
3260 (install-file "inxi" bin)
3261 (wrap-program (string-append bin "/inxi")
3262 `("PATH" ":" =
3263 ("$PATH"
3264 ,@(map (lambda (input)
3265 (match input
3266 ((name . store)
3267 (let ((store-append
3268 (cut string-append store <>)))
3269 (cond
3270 ((member name '("util-linux"))
3271 (string-append (store-append "/bin") ":"
3272 (store-append "/sbin")))
3273 ((member name '("dmidecode" "iproute2"))
3274 (store-append "/sbin"))
3275 (else (store-append "/bin")))))))
3276 %build-inputs)))
3277 `("PERL5LIB" ":" =
3278 ,(delete
3279 ""
3280 (map (match-lambda
3281 (((? (cut string-prefix? "perl-" <>) name) . dir)
3282 (string-append dir "/lib/perl5/site_perl"))
3283 (_ ""))
3284 %build-inputs)))))
3285 (invoke "gzip" "inxi.1")
3286 (install-file "inxi.1.gz"
55f5556e 3287 (string-append %output "/share/man/man1")))
bbc94ed0
PN
3288 #t)))
3289 (home-page "https://smxi.org/docs/inxi.htm")
4ee41a6a 3290 (synopsis "Full-featured system information script")
bbc94ed0
PN
3291 (description "Inxi is a system information script that can display
3292various things about your hardware and software to users in an IRC chatroom or
4ee41a6a 3293support forum. It runs with the @code{/exec} command in most IRC clients.")
bbc94ed0
PN
3294 (license license:gpl3+))))
3295
3296(define-public inxi
3297 (package
3298 (inherit inxi-minimal)
3299 (name "inxi")
3300 (inputs
3301 `(("dmidecode" ,dmidecode)
3302 ("file" ,file)
3303 ("bind:utils" ,isc-bind "utils") ; dig
3304 ("gzip" ,gzip)
3305 ("iproute2" ,iproute) ; ip
3306 ("kmod" ,kmod) ; modinfo
3307 ("lm-sensors" ,lm-sensors)
3308 ("mesa-utils" ,mesa-utils)
3309 ("pciutils" ,pciutils)
bbc94ed0
PN
3310 ("tar" ,tar)
3311 ("tree" ,tree)
3312 ("util-linux" ,util-linux) ; lsblk
3313 ("usbutils" ,usbutils) ; lsusb
3314 ("wmctrl" ,wmctrl)
3315 ("xdpyinfo" ,xdpyinfo)
3316 ("xprop" ,xprop)
3317 ("xrandr" ,xrandr)
3318 ("coreutils" ,coreutils) ; uptime
3319 ("inetutils" ,inetutils) ; ifconfig
3320 ("perl-cpanel-json-xs" ,perl-cpanel-json-xs)
3321 ("perl-http-tiny" ,perl-http-tiny)
3322 ("perl-io-socket-ssl" ,perl-io-socket-ssl)
3323 ("perl-json-xs" ,perl-json-xs)
3324 ("perl-time-hires" ,perl-time-hires)
3325 ;; TODO: Add more inputs:
3326 ;; ipmi-sensors
3327 ;; hddtemp
3328 ;; perl-xml-dumper
3329 ;; ipmitool
3330 ,@(package-inputs inxi-minimal)))))
b19f3337
OP
3331
3332(define-public pscircle
3333 (package
3334 (name "pscircle")
0b4ced58 3335 (version "1.3.1")
b19f3337
OP
3336 (source
3337 (origin
494b702a
TGR
3338 (method git-fetch)
3339 (uri (git-reference
3340 (url "https://gitlab.com/mildlyparallel/pscircle.git")
3341 (commit (string-append "v" version))))
3342 (file-name (git-file-name name version))
b19f3337 3343 (sha256
0b4ced58 3344 (base32 "1sm99423hh90kr4wdjqi9sdrrpk65j2vz2hzj65zcxfxyr6khjci"))))
b19f3337
OP
3345 (build-system meson-build-system)
3346 (native-inputs
3347 `(("pkg-config" ,pkg-config)))
3348 (inputs
3349 `(("cairo" ,cairo)
3350 ("libpng" ,libpng)
3351 ("libx11" ,libx11)))
3352 (home-page "https://gitlab.com/mildlyparallel/pscircle")
3353 (synopsis "Visualize Linux processes in a form of radial tree")
3354 (description
3355 "@code{pscircle} visualizes Linux processes in the form of a radial tree.")
3356 (license license:gpl2+)))
ac94ccb9
DM
3357
3358(define-public python-pyudev
3359 (package
3360 (name "python-pyudev")
3361 (version "0.21.0")
3362 (source
3363 (origin
3364 (method url-fetch)
3365 (uri (pypi-uri "pyudev" version))
3366 (sha256
3367 (base32
3368 "0arz0dqp75sszsmgm6vhg92n1lsx91ihddx3m944f4ah0487ljq9"))))
3369 (build-system python-build-system)
3370 (arguments
3371 `(#:tests? #f ; Tests require /sys
3372 #:phases
3373 (modify-phases %standard-phases
3374 (add-after 'unpack 'patch-ctypes-udev
3375 (lambda* (#:key inputs outputs #:allow-other-keys)
3376 (let ((eudev (assoc-ref inputs "eudev")))
3377 (substitute* "src/pyudev/core.py"
3378 (("'udev'")
3379 (string-append "'" eudev "/lib/libudev.so'")))
3380 (substitute* "src/pyudev/_ctypeslib/utils.py"
3381 ;; Use absolute paths instead of keys.
3382 (("= find_library") "= "))
3383 #t))))))
3384 (inputs
3385 `(("eudev" ,eudev)))
cbb1b168
RJ
3386 (propagated-inputs
3387 `(("python-six" ,python-six)))
ac94ccb9
DM
3388 (native-inputs
3389 `(("python-docutils" ,python-docutils)
3390 ("python-hypothesis" ,python-hypothesis)
3391 ("python-mock" ,python-mock)
3392 ("python-pytest" ,python-pytest)
3393 ("python-sphinx" ,python-sphinx)))
a20ede32 3394 (home-page "https://pyudev.readthedocs.io/")
ac94ccb9
DM
3395 (synopsis "Python udev binding")
3396 (description "This package provides @code{udev} bindings for Python.")
3397 (license license:lgpl2.1)))
15c56e82
DM
3398
3399(define-public solaar
3400 (package
3401 (name "solaar")
3402 (version "0.9.2")
3403 (source (origin
3404 (method git-fetch)
3405 (uri (git-reference
3406 (url "https://github.com/pwr/Solaar.git")
3407 (commit version)))
3408 (file-name (git-file-name name version))
3409 (sha256
3410 (base32
3411 "085mfa13dap3wqik1dqlad0d7kff4rv7j4ljh99c7l8nhczkqgwm"))))
3412 (build-system python-build-system)
3413 (arguments
3414 `(#:phases
3415 (modify-phases %standard-phases
3416 (add-after 'unpack 'fix-prefix-detection
3417 (lambda _
3418 (substitute* "setup.py"
3419 (("'--prefix' in sys\\.argv")
3420 "len([x.startswith('--prefix=') for x in sys.argv]) > 0"))
3421 #t))
3422 (replace 'build
3423 (lambda _
3424 (invoke "python" "setup.py" "build")))
3425 (add-before 'check 'setenv-PATH
3426 (lambda _
3427 (setenv "PYTHONPATH" (string-append "lib:" (getenv "PYTHONPATH")))
3428 #t)))))
3429 (propagated-inputs
3430 `(("python-pygobject" ,python-pygobject)
3431 ("python-pyudev" ,python-pyudev)))
3432 (home-page "https://smxi.org/docs/inxi.htm")
3433 (synopsis "Linux devices manager for the Logitech Unifying Receiver")
3434 (description "This package provides tools to manage clients of the
3435Logitech Unifying Receiver.")
3436 (license license:gpl2)))
4d26987d
AI
3437
3438(define-public lynis
3439 (package
3440 (name "lynis")
112dc8eb 3441 ;; Also update the ‘lynis-sdk’ input to the commit matching this release.
248f218e 3442 (version "2.7.5")
4d26987d
AI
3443 (source
3444 (origin
3445 (method git-fetch)
3446 (uri (git-reference
3447 (url "https://github.com/CISOfy/lynis")
3448 (commit version)))
3449 (file-name (git-file-name name version))
3450 (sha256
248f218e 3451 (base32 "1lkkbvxm0rgrrlx0szaxmf8ghc3d26wal96sgqk84m37mvs1f7p0"))
4d26987d
AI
3452 (modules '((guix build utils)))
3453 (snippet
3454 '(begin
3455 ;; Remove proprietary plugins. As of now, all plugins supplied with
3456 ;; lynis are proprietary. In the future, if free plugins are
3457 ;; provided, whitelist them from deletion.
3458 (for-each delete-file (find-files "plugins"))
3459 #t))))
3460 (build-system gnu-build-system)
3461 (native-inputs
3462 `(;; For tests
3463 ("lynis-sdk"
3464 ,(origin
3465 (method git-fetch)
3466 (uri (git-reference
3467 (url "https://github.com/CISOfy/lynis-sdk")
248f218e 3468 (commit "bf1c1d95121da9ca79a9eac5a15ed8d81e34094d")))
4d26987d
AI
3469 (file-name (git-file-name "lynis-sdk" version))
3470 (sha256
248f218e 3471 (base32 "1ndz5v0039dqa87cva2dk55a8hkw0fibsw8hh2ddmny9qkr4l3dp"))))))
4d26987d
AI
3472 (arguments
3473 `(#:phases
3474 (modify-phases %standard-phases
3475 (replace 'configure
3476 (lambda* (#:key inputs outputs #:allow-other-keys)
3477 (substitute* "lynis"
3478 (("/usr/share/lynis")
3479 (string-append (assoc-ref outputs "out") "/share/lynis")))
3480 (substitute* "include/functions"
3481 (("/usr/local/etc/lynis")
3482 (string-append (assoc-ref outputs "out") "/etc/lynis")))
3483 #t))
3484 (delete 'build)
3485 (replace 'install
3486 (lambda* (#:key outputs #:allow-other-keys)
3487 (let ((out (assoc-ref outputs "out")))
3488 (install-file "lynis" (string-append out "/bin/"))
3489 (install-file "default.prf" (string-append out "/etc/lynis"))
3490 (for-each
3491 (lambda (dir)
3492 (copy-recursively dir (string-append out "/share/lynis/" dir)))
3493 (list "db" "include" "plugins"))
3494 (install-file "lynis.8" (string-append out "/share/man/man8"))
3495 #t)))
3496 (replace 'check
3497 (lambda* (#:key inputs #:allow-other-keys)
3498 (copy-recursively (assoc-ref inputs "lynis-sdk") "../lynis-sdk")
3499 (setenv "LANG" "en_US.UTF-8")
3500 (let ((lynis-dir (getcwd)))
3501 (with-directory-excursion "../lynis-sdk"
3502 (substitute* "config"
3503 (("\\.\\./lynis") lynis-dir))
3504 (substitute* "unit-tests/tests-language-translations.sh"
3505 (("\\.\\./lynis") lynis-dir))
3506 (invoke "sh" "lynis-devkit" "run" "unit-tests"))))))))
3507 (home-page "https://cisofy.com/lynis/")
3508 (synopsis "Security auditing tool")
3509 (description "Lynis is a security auditing tool. It performs an in-depth
3510security scan and runs on the system itself. The primary goal is to test
3511security defenses and provide tips for further system hardening. It will also
3512scan for general system information, vulnerable software packages, and
3513possible configuration issues.")
3514 (license license:gpl3+)))
2eddeeba
PN
3515
3516(define-public ngrep
3517 (package
3518 (name "ngrep")
3519 (version "1.47")
3520 (source
3521 (origin
3522 (method git-fetch)
3523 (uri (git-reference
3524 (url "https://github.com/jpr5/ngrep/")
3525 (commit (string-append "V" (string-replace-substring version "." "_")))))
3526 (file-name (git-file-name name version))
3527 (sha256
3528 (base32
3529 "1x2fyd7wdqlj1r76ilal06cl2wmbz0ws6i3ys204sbjh1cj6dcl7"))))
3530 (build-system gnu-build-system)
3531 (inputs
3532 `(("libpcap" ,libpcap)))
3533 (arguments
3534 `(#:tests? #f ;; No tests.
3535 #:configure-flags (list (string-append "--with-pcap-includes="
3536 (assoc-ref %build-inputs "libpcap")
3537 "/include/pcap"))))
3538 (home-page "https://github.com/jpr5/ngrep/")
3539 (synopsis "Grep-like utility to search for network packets on an interface")
3540 (description "@command{ngrep} is like GNU grep applied to the network
3541layer. It's a PCAP-based tool that allows you to specify an extended regular
3542or hexadecimal expression to match against data payloads of packets. It
3543understands many kinds of protocols, including IPv4/6, TCP, UDP, ICMPv4/6,
3544IGMP and Raw, across a wide variety of interface types, and understands BPF
3545filter logic in the same fashion as more common packet sniffing tools, such as
3546tcpdump and snoop.")
3547 (license license:bsd-3)))
cd2ce8ab
GLV
3548
3549(define-public pam-mount
3550 (package
3551 (name "pam-mount")
3552 (version "2.16")
3553 (source
3554 (origin
3555 (method url-fetch)
3556 (uri (string-append "mirror://sourceforge/pam-mount/pam_mount/"
3557 version "/pam_mount-" version ".tar.xz"))
3558 (sha256
3559 (base32
3560 "1rvi4irb7ylsbhvx1cr6islm2xxw1a4b19q6z4a9864ndkm0f0mf"))
3561 (patches
3562 ;; Patch adding support for encrypted volumes in LUKS2 format.
3563 ;; It comes from the Gentoo package definition for sys-auth/pam_mount.
3564 (search-patches "pam-mount-luks2-support.patch"))))
3565 (build-system gnu-build-system)
3566 (native-inputs
3567 `(("perl" ,perl)
3568 ("pkg-config" ,pkg-config)))
3569 (inputs
3570 `(("cryptsetup" ,cryptsetup)
3571 ("libhx" ,libhx)
3572 ("libxml2" ,libxml2)
3573 ("linux-pam" ,linux-pam)
3574 ("lvm2" ,lvm2)
3575 ("openssl" ,openssl)
3576 ("pcre" ,pcre)
3577 ("util-linux" ,util-linux)))
3578 (arguments
3579 `(#:configure-flags
3580 (list (string-append "--with-slibdir=" %output "/lib")
3581 (string-append "--with-ssbindir=" %output "/sbin"))
3582 #:phases
3583 (modify-phases %standard-phases
3584 (add-after 'unpack 'fix-program-paths
3585 (lambda* (#:key inputs outputs #:allow-other-keys)
3586 (let ((util-linux (assoc-ref inputs "util-linux"))
3587 (out (assoc-ref outputs "out")))
3588 (substitute* "src/mtcrypt.c"
3589 (("\"mount\";")
3590 (string-append "\"" util-linux "/bin/mount\";"))
3591 (("\"umount\";")
3592 (string-append "\"" util-linux "/bin/umount\";"))
3593 (("\"fsck\",")
3594 (string-append "\"" util-linux "/sbin/fsck\",")))
3595 (substitute* "src/rdconf1.c"
3596 (("\"mount\", \"")
3597 (string-append "\"" util-linux "/bin/mount\", \""))
3598 (("\"umount\", \"")
3599 (string-append "\"" util-linux "/bin/umount\", \""))
3600 (("\"fsck\", \"")
3601 (string-append "\"" util-linux "/sbin/fsck\", \""))
3602 (("\"pmvarrun\", \"")
3603 (string-append "\"" out "/sbin/pmvarrun\", \""))))
3604 #t)))))
3605 (home-page "http://pam-mount.sourceforge.net")
3606 (synopsis "PAM module to mount volumes for a user session")
3607 (description
3608 "Pam-mount is a PAM module that can mount volumes when a user logs in.
3609It supports mounting local filesystems of any kind the normal mount utility
3610supports. It can also mount encrypted LUKS volumes using the password
3611supplied by the user when logging in.")
3612 (license (list license:gpl2+ license:lgpl2.1+))))