gnu: libcap-ng: Use HTTPS for home page.
[jackhill/guix/guix.git] / gnu / packages / admin.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
4 ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014, 2015, 2016, 2017 Eric Bavier <bavier@member.fsf.org>
6 ;;; Copyright © 2015, 2016 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
7 ;;; Copyright © 2015 Alex Sassmannshausen <alex.sassmannshausen@gmail.com>
8 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
9 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
10 ;;; Copyright © 2016 Pjotr Prins <pjotr.guix@thebird.nl>
11 ;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
12 ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
13 ;;; Copyright © 2016 Peter Feigl <peter.feigl@nexoid.at>
14 ;;; Copyright © 2016 John J. Foerch <jjfoerch@earthlink.net>
15 ;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net>
16 ;;; Copyright © 2016, 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
17 ;;; Copyright © 2016 John Darrington <jmd@gnu.org>
18 ;;; Copyright © 2017 Ben Sturmfels <ben@sturm.com.au>
19 ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
20 ;;; Copyright © 2017 Christopher Allan Webber <cwebber@dustycloud.org>
21 ;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
22 ;;;
23 ;;; This file is part of GNU Guix.
24 ;;;
25 ;;; GNU Guix is free software; you can redistribute it and/or modify it
26 ;;; under the terms of the GNU General Public License as published by
27 ;;; the Free Software Foundation; either version 3 of the License, or (at
28 ;;; your option) any later version.
29 ;;;
30 ;;; GNU Guix is distributed in the hope that it will be useful, but
31 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
32 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
33 ;;; GNU General Public License for more details.
34 ;;;
35 ;;; You should have received a copy of the GNU General Public License
36 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
37
38 (define-module (gnu packages admin)
39 #:use-module ((guix licenses) #:prefix license:)
40 #:use-module (guix packages)
41 #:use-module (guix utils)
42 #:use-module (guix download)
43 #:use-module (guix git-download)
44 #:use-module (guix build-system cmake)
45 #:use-module (guix build-system gnu)
46 #:use-module (guix build-system perl)
47 #:use-module (guix build-system python)
48 #:use-module (guix build-system trivial)
49 #:use-module (gnu packages)
50 #:use-module (gnu packages base)
51 #:use-module (gnu packages check)
52 #:use-module (gnu packages cyrus-sasl)
53 #:use-module (gnu packages ncurses)
54 #:use-module (gnu packages readline)
55 #:use-module (gnu packages linux)
56 #:use-module (gnu packages lua)
57 #:use-module (gnu packages guile)
58 #:use-module (gnu packages gettext)
59 #:use-module (gnu packages pcre)
60 #:use-module (gnu packages perl)
61 #:use-module (gnu packages perl-check)
62 #:use-module (gnu packages tcl)
63 #:use-module (gnu packages compression)
64 #:use-module (gnu packages cross-base)
65 #:use-module (gnu packages tls)
66 #:use-module (gnu packages gnupg)
67 #:use-module (gnu packages bison)
68 #:use-module (gnu packages flex)
69 #:use-module (gnu packages glib)
70 #:use-module (gnu packages openldap)
71 #:use-module (gnu packages mcrypt)
72 #:use-module (gnu packages pkg-config)
73 #:use-module (gnu packages popt)
74 #:use-module (gnu packages python)
75 #:use-module (gnu packages python-crypto)
76 #:use-module (gnu packages python-web)
77 #:use-module (gnu packages texinfo)
78 #:use-module (gnu packages groff)
79 #:use-module (gnu packages pciutils)
80 #:use-module (gnu packages libunwind)
81 #:use-module (gnu packages libusb)
82 #:use-module (gnu packages libftdi)
83 #:use-module (gnu packages image)
84 #:use-module (gnu packages xorg)
85 #:use-module (gnu packages xdisorg)
86 #:use-module (gnu packages man)
87 #:use-module (gnu packages autotools)
88 #:use-module (gnu packages gnome)
89 #:use-module (gnu packages kerberos)
90 #:use-module (gnu packages gtk)
91 #:use-module (gnu packages xml))
92
93 (define-public aide
94 (package
95 (name "aide")
96 (version "0.16")
97 (source (origin
98 (method url-fetch)
99 (uri (string-append "mirror://sourceforge/aide/aide/"
100 version "/aide-" version ".tar.gz"))
101 (sha256
102 (base32
103 "0ibkv4z2gk14fn014kq13rp2ysiq6nn2cflv2q5i7zf466hm6758"))))
104 (build-system gnu-build-system)
105 (native-inputs
106 `(("bison" ,bison)
107 ("flex" ,flex)))
108 (inputs
109 `(("libgcrypt" ,libgcrypt)
110 ("libgpg-error" ,libgpg-error)
111 ("libmhash" ,libmhash)
112 ("pcre" ,pcre)
113 ("zlib" ,zlib)))
114 (synopsis "File and directory integrity checker")
115 (description
116 "AIDE (Advanced Intrusion Detection Environment) is a file and directory
117 integrity checker. It creates a database from the regular expression rules
118 that it finds from its configuration files. Once this database is initialized
119 it can be used to verify the integrity of the files. It has several message
120 digest algorithms that are used to check the integrity of files. All of the
121 usual file attributes can be checked for inconsistencies.")
122 (home-page "http://aide.sourceforge.net/")
123 (license license:gpl2+)))
124
125 (define-public progress
126 (package
127 (name "progress")
128 (version "0.13.1")
129 (source (origin
130 (method url-fetch)
131 (uri (string-append "https://github.com/Xfennec/"
132 name "/archive/v" version ".tar.gz"))
133 (sha256
134 (base32 "199rk6608q9m6l0fbjm0xl2w1c5krf8245dqnksdp4rqp7l9ak06"))
135 (file-name (string-append name "-" version ".tar.gz"))))
136 (build-system gnu-build-system)
137 (native-inputs
138 `(("pkg-config" ,pkg-config)
139 ("which" ,which)))
140 (inputs
141 `(("ncurses" ,ncurses)))
142 (arguments
143 `(#:tests? #f ; There is no test suite.
144 #:make-flags (list "CC=gcc"
145 (string-append "PREFIX=" (assoc-ref %outputs "out")))
146 #:phases
147 (modify-phases %standard-phases
148 (delete 'configure)))) ; There's no configure phase.
149 (home-page "https://github.com/Xfennec/progress")
150 (synopsis "Program to view the progress of the coreutils commands")
151 (description "A program that looks for coreutils basic commands (cp, mv,
152 dd, tar, gzip/gunzip, cat, etc.) currently running on your system and displays
153 the percentage of copied data. It can also show estimated time and throughput,
154 and provides a \"top-like\" mode (monitoring).")
155 (license license:gpl3+)))
156
157 (define-public shepherd
158 (package
159 (name "shepherd")
160 (version "0.3.2")
161 (source (origin
162 (method url-fetch)
163 (uri (string-append "ftp://alpha.gnu.org/gnu/dmd/shepherd-"
164 version ".tar.gz"))
165 (sha256
166 (base32
167 "174q1qg7yg6w1hfvlfv720hr6hid4h5xzw15y3ycfpspllzldhcb"))
168 (patches (search-patches "shepherd-close-fds.patch"))))
169 (build-system gnu-build-system)
170 (arguments
171 '(#:configure-flags '("--localstatedir=/var")))
172 (native-inputs
173 `(("pkg-config" ,pkg-config)
174
175 ;; This is the Guile we use as a cross-compiler...
176 ("guile" ,guile-2.2)))
177 (inputs
178 ;; ... and this is the one that appears in shebangs when cross-compiling.
179 `(("guile" ,guile-2.2)))
180 (synopsis "System service manager")
181 (description
182 "The GNU Shepherd is a daemon-managing daemon, meaning that it supervises
183 the execution of system services, replacing similar functionality found in
184 typical init systems. It provides dependency-handling through a convenient
185 interface and is based on GNU Guile.")
186 (license license:gpl3+)
187 (home-page "https://www.gnu.org/software/shepherd/")
188 (properties '((ftp-server . "alpha.gnu.org")))))
189
190 (define-public dfc
191 (package
192 (name "dfc")
193 (version "3.0.4")
194 (source
195 (origin
196 (method url-fetch)
197 (uri (string-append
198 "http://projects.gw-computing.net/attachments/download/79/dfc-"
199 version ".tar.gz"))
200 (sha256
201 (base32
202 "0zk1ppx93ijimf4sbgqilxxikpsa2gmpbynknyh41xy7jbdjxp0b"))))
203 (build-system cmake-build-system)
204 (arguments '(#:tests? #f)) ; There are no tests.
205 (native-inputs `(("gettext" ,gettext-minimal)))
206 (home-page "http://projects.gw-computing.net/projects/dfc")
207 (synopsis "Display file system space usage using graphs and colors")
208 (description
209 "dfc (df color) is a modern version of df. It uses colors, draws pretty
210 graphs and can export its output to different formats.")
211 (license license:bsd-3)))
212
213 (define-public htop
214 (package
215 (name "htop")
216 (version "2.0.2")
217 (source (origin
218 (method url-fetch)
219 (uri (string-append "http://hisham.hm/htop/releases/"
220 version "/htop-" version ".tar.gz"))
221 (sha256
222 (base32
223 "11zlwadm6dpkrlfvf3z3xll26yyffa7qrxd1w72y1kl0rgffk6qp"))))
224 (build-system gnu-build-system)
225 (inputs
226 `(("ncurses" ,ncurses)))
227 (home-page "http://htop.sourceforge.net/")
228 (synopsis "Interactive process viewer")
229 (description
230 "This is htop, an interactive process viewer. It is a text-mode
231 application (for console or X terminals) and requires ncurses.")
232 (license license:gpl2)))
233
234 (define-public pies
235 (package
236 (name "pies")
237 (version "1.3")
238 (source
239 (origin
240 (method url-fetch)
241 (uri (string-append "mirror://gnu/pies/pies-"
242 version ".tar.bz2"))
243 (sha256
244 (base32
245 "12r7rjjyibjdj08dvwbp0iflfpzl4s0zhn6cr6zj3hwf9gbzgl1g"))))
246 (build-system gnu-build-system)
247 (arguments
248 '(#:phases (modify-phases %standard-phases
249 (add-before 'build 'patch-/bin/sh
250 (lambda* (#:key inputs #:allow-other-keys)
251 ;; Use the right shell when executing user-provided
252 ;; shell commands.
253 (let ((bash (assoc-ref inputs "bash")))
254 (substitute* "src/progman.c"
255 (("\"/bin/sh\"")
256 (string-append "\"" bash "/bin/sh\"")))
257 #t))))))
258 (home-page "https://www.gnu.org/software/pies/")
259 (synopsis "Program invocation and execution supervisor")
260 (description
261 "GNU pies is a program that supervises the invocation and execution of
262 other programs. It reads the list of programs to be started from its
263 configuration file, executes them, and then monitors their status,
264 re-executing them as necessary.")
265 (license license:gpl3+)))
266
267 (define-public inetutils
268 (package
269 (name "inetutils")
270 (version "1.9.4")
271 (source (origin
272 (method url-fetch)
273 (uri (string-append "mirror://gnu/inetutils/inetutils-"
274 version ".tar.gz"))
275 (sha256
276 (base32
277 "05n65k4ixl85dc6rxc51b1b732gnmm8xnqi424dy9f1nz7ppb3xy"))))
278 (build-system gnu-build-system)
279 (arguments
280 `(#:configure-flags '("--localstatedir=/var"
281
282 ;; Make sure 'PATH_PROCNET_DEV' gets defined when
283 ;; cross-compiling (by default it does not.)
284 ,@(if (%current-target-system)
285 '("--with-path-procnet-dev=/proc/net/dev")
286 '()))
287 ;; On some systems, 'libls.sh' may fail with an error such as:
288 ;; "Failed to tell switch -a apart from -A".
289 #:parallel-tests? #f))
290 (inputs `(("ncurses" ,ncurses)
291 ("readline" ,readline))) ;for 'ftp'
292 (native-inputs `(("netstat" ,net-tools))) ;for tests
293 (home-page "https://www.gnu.org/software/inetutils/")
294 (synopsis "Basic networking utilities")
295 (description
296 "Inetutils is a collection of common network programs, such as an ftp
297 client and server, a telnet client and server, an rsh client and server, and
298 hostname.")
299 (license license:gpl3+)))
300
301 (define-public shadow
302 (package
303 (name "shadow")
304 (version "4.5")
305 (source (origin
306 (method url-fetch)
307 (uri (string-append
308 "https://github.com/shadow-maint/shadow/releases/"
309 "download/" version "/shadow-" version ".tar.xz"))
310 (sha256
311 (base32
312 "0hdpai78n63l3v3fgr3kkiqzhd0awrpfnnzz4mf7lmxdh61qb37w"))))
313 (build-system gnu-build-system)
314 (arguments
315 `(;; Assume System V `setpgrp (void)', which is the default on GNU
316 ;; variants (`AC_FUNC_SETPGRP' is not cross-compilation capable.)
317 #:configure-flags
318 '("--with-libpam" "ac_cv_func_setpgrp_void=yes")
319
320 #:phases
321 (modify-phases %standard-phases
322 (add-before 'build 'set-nscd-file-name
323 (lambda* (#:key inputs #:allow-other-keys)
324 ;; Use the right file name for nscd.
325 (let ((libc (assoc-ref inputs
326 ,(if (%current-target-system)
327 "cross-libc"
328 "libc"))))
329 (substitute* "lib/nscd.c"
330 (("/usr/sbin/nscd")
331 (string-append libc "/sbin/nscd"))))))
332 (add-after 'install 'remove-groups
333 (lambda* (#:key outputs #:allow-other-keys)
334 ;; Remove `groups', which is already provided by Coreutils.
335 (let* ((out (assoc-ref outputs "out"))
336 (bin (string-append out "/bin"))
337 (man (string-append out "/share/man")))
338 (delete-file (string-append bin "/groups"))
339 (for-each delete-file (find-files man "^groups\\."))
340 #t))))))
341
342 (inputs (if (string-contains (or (%current-target-system)
343 (%current-system))
344 "-linux")
345 `(("linux-pam" ,linux-pam))
346 '()))
347 (home-page "http://pkg-shadow.alioth.debian.org/")
348 (synopsis "Authentication-related tools such as passwd, su, and login")
349 (description
350 "Shadow provides a number of authentication-related tools, including:
351 login, passwd, su, groupadd, and useradd.")
352
353 ;; The `vipw' program is GPLv2+.
354 ;; libmisc/salt.c is public domain.
355 (license license:bsd-3)))
356
357 (define-public mingetty
358 (package
359 (name "mingetty")
360 (version "1.08")
361 (source (origin
362 (method url-fetch)
363 (uri (string-append "mirror://sourceforge/mingetty/mingetty/"
364 version "/mingetty-" version ".tar.gz"))
365 (sha256
366 (base32
367 "05yxrp44ky2kg6qknk1ih0kvwkgbn9fbz77r3vci7agslh5wjm8g"))))
368 (build-system gnu-build-system)
369 (arguments
370 `(#:phases
371 (modify-phases %standard-phases
372 (replace 'configure
373 (lambda* (#:key inputs outputs #:allow-other-keys)
374 (let* ((out (assoc-ref outputs "out"))
375 (man8 (string-append out "/share/man/man8"))
376 (sbin (string-append out "/sbin"))
377 (shadow (assoc-ref inputs "shadow"))
378 (login (string-append shadow "/bin/login")))
379 (substitute* "Makefile"
380 (("^SBINDIR.*")
381 (string-append "SBINDIR = " out
382 "/sbin\n"))
383 (("^MANDIR.*")
384 (string-append "MANDIR = " out
385 "/share/man/man8\n")))
386
387 ;; Pick the right 'login' by default.
388 (substitute* "mingetty.c"
389 (("\"/bin/login\"")
390 (string-append "\"" login "\"")))
391
392 (mkdir-p sbin)
393 (mkdir-p man8))
394 #t)))
395 #:tests? #f)) ; no tests
396 (inputs `(("shadow" ,shadow)))
397
398 (home-page "https://sourceforge.net/projects/mingetty")
399 (synopsis "Getty for the text console")
400 (description
401 "Small console getty that is started on the Linux text console,
402 asks for a login name and then transfers over to 'login'. It is extended to
403 allow automatic login and starting any app.")
404 (license license:gpl2+)))
405
406 (define-public net-base
407 (package
408 (name "net-base")
409 (version "5.3")
410 (source (origin
411 (method url-fetch)
412 (uri (string-append
413 "mirror://debian/pool/main/n/netbase/netbase_"
414 version ".tar.xz"))
415 (sha256
416 (base32
417 "12xqjwg3p4rzmmh2iib6sigm9l29y3dgk74mmnw64k84jnbwdxl1"))))
418 (build-system trivial-build-system)
419 (arguments
420 `(#:modules ((guix build utils))
421 #:builder (begin
422 (use-modules (guix build utils)
423 (srfi srfi-26))
424
425 (let* ((source (assoc-ref %build-inputs "source"))
426 (tar (assoc-ref %build-inputs "tar"))
427 (xz (assoc-ref %build-inputs "xz"))
428 (output (assoc-ref %outputs "out"))
429 (etc (string-append output "/etc")))
430 (setenv "PATH" (string-append xz "/bin"))
431 (system* (string-append tar "/bin/tar") "xvf"
432 source)
433 (chdir ,(string-append "netbase-" version))
434 (mkdir-p etc)
435 (for-each copy-file
436 '("etc-services" "etc-protocols" "etc-rpc")
437 (map (cut string-append etc "/" <>)
438 '("services" "protocols" "rpc")))
439 #t))))
440 (native-inputs `(("tar" ,tar)
441 ("xz" ,xz)))
442 (synopsis "IANA protocol, port, and RPC number assignments")
443 (description
444 "This package provides the /etc/services, /etc/protocols, and /etc/rpc
445 files, which contain information about the IANA-assigned port, protocol, and
446 ONC RPC numbers.")
447 (home-page "http://packages.debian.org/sid/netbase")
448 (license license:gpl2)))
449
450 (define-public netcat
451 (package
452 (name "netcat")
453 (version "0.7.1")
454 (source (origin
455 (method url-fetch)
456 (uri (string-append "mirror://sourceforge/netcat/netcat/" version
457 "/netcat-" version ".tar.bz2"))
458 (sha256
459 (base32
460 "1frjcdkhkpzk0f84hx6hmw5l0ynpmji8vcbaxg8h5k2svyxz0nmm"))))
461 (build-system gnu-build-system)
462 (arguments
463 `(#:configure-flags
464 ;; By default, man and info pages are put in PREFIX/{man,info},
465 ;; but we want them in PREFIX/share/{man,info}.
466 (let ((out (assoc-ref %outputs "out")))
467 (list (string-append "--mandir=" out "/share/man")
468 (string-append "--infodir=" out "/share/info")))))
469 (home-page "http://netcat.sourceforge.net")
470 (synopsis "Read and write data over TCP/IP")
471 (description
472 "Netcat is a featured networking utility which reads and writes data
473 across network connections, using the TCP/IP protocol. It is designed to be a
474 reliable \"back-end\" tool that can be used directly or easily driven by other
475 programs and scripts. At the same time, it is a feature-rich network debugging
476 and exploration tool, since it can create almost any kind of connection you
477 would need and has several interesting built-in capabilities.")
478 (license license:gpl2+)))
479
480 (define-public alive
481 (package
482 (name "alive")
483 (version "2.0.2")
484 (source (origin
485 (method url-fetch)
486 (uri (string-append "mirror://gnu/alive/alive-"
487 version ".tar.xz"))
488 (sha256
489 (base32
490 "1vrzg51ai68x9yld7vbgl58sxaw5qpx8rbakwcxn4cqq6vpxj38j"))))
491 (build-system gnu-build-system)
492 (arguments '(#:configure-flags '("alive_cv_nice_ping=yes")))
493 (inputs `(("guile" ,guile-2.0)
494 ("inetutils" ,inetutils)))
495 (home-page "https://www.gnu.org/software/alive/")
496 (synopsis "Autologin and keep-alive daemon")
497 (description
498 "GNU Alive sends periodic pings to a server, generally to keep a
499 connection alive.")
500 (license license:gpl3+)))
501
502 (define-public isc-dhcp
503 (let* ((bind-major-version "9")
504 (bind-minor-version "9")
505 (bind-patch-version "10")
506 (bind-release-type "-P") ; for patch release, use "-P"
507 (bind-release-version "3") ; for patch release, e.g. "6"
508 (bind-version (string-append bind-major-version
509 "."
510 bind-minor-version
511 "."
512 bind-patch-version
513 bind-release-type
514 bind-release-version)))
515 (package
516 (name "isc-dhcp")
517 (version "4.3.5")
518 (source (origin
519 (method url-fetch)
520 (uri (string-append "http://ftp.isc.org/isc/dhcp/"
521 version "/dhcp-" version ".tar.gz"))
522 (sha256
523 (base32
524 "0m7rwxvpb7xrmfl9ynpckhl0hi0xgm9bq1fmbp2r68sxy5mr75gb"))))
525 (build-system gnu-build-system)
526 (arguments
527 `(#:parallel-build? #f
528 #:phases
529 (modify-phases %standard-phases
530 (add-after 'unpack 'replace-bundled-bind
531 (lambda* (#:key inputs #:allow-other-keys)
532 (delete-file "bind/bind.tar.gz")
533 (copy-file (assoc-ref inputs "bind-source-tarball")
534 "bind/bind.tar.gz")
535 (chmod "bind/bind.tar.gz" #o644)
536 (substitute* "bind/version.tmp"
537 (("^MAJORVER=.*")
538 (format #f "MAJORVER=~a\n" ,bind-major-version))
539 (("^MINORVER=.*")
540 (format #f "MINORVER=~a\n" ,bind-minor-version))
541 (("^PATCHVER=.*")
542 (format #f "PATCHVER=~a\n" ,bind-patch-version))
543 (("^RELEASETYPE=.*")
544 (format #f "RELEASETYPE=~a\n" ,bind-release-type))
545 (("^RELEASEVER=.*")
546 (format #f "RELEASEVER=~a\n" ,bind-release-version)))
547 #t))
548 (add-after 'configure 'post-configure
549 (lambda* (#:key outputs #:allow-other-keys)
550 ;; Point to the right client script, which will be
551 ;; installed in a later phase.
552 (substitute* "includes/dhcpd.h"
553 (("#define[[:blank:]]+_PATH_DHCLIENT_SCRIPT.*")
554 (let ((out (assoc-ref outputs "out")))
555 (string-append "#define _PATH_DHCLIENT_SCRIPT \""
556 out "/libexec/dhclient-script"
557 "\"\n"))))
558
559 ;; During the 'build' phase, 'bind.tar.gz' is extracted, so
560 ;; we must patch shebangs in there and make sure the right
561 ;; shell is used.
562 (with-directory-excursion "bind"
563 (substitute* "Makefile"
564 (("\\./configure")
565 (let ((sh (which "sh")))
566 (string-append "./configure CONFIG_SHELL="
567 sh " SHELL=" sh))))
568
569 (let ((bind-directory (string-append "bind-" ,bind-version)))
570 (system* "tar" "xf" "bind.tar.gz")
571 (for-each patch-shebang
572 (find-files bind-directory ".*"))
573 (zero? (system* "tar" "cf" "bind.tar.gz"
574 bind-directory
575 ;; avoid non-determinism in the archive
576 "--sort=name"
577 "--mtime=@0"
578 "--owner=root:0"
579 "--group=root:0"))))))
580 (add-after 'install 'post-install
581 (lambda* (#:key inputs outputs #:allow-other-keys)
582 ;; Install the dhclient script for GNU/Linux and make sure
583 ;; if finds all the programs it needs.
584 (let* ((out (assoc-ref outputs "out"))
585 (libexec (string-append out "/libexec"))
586 (coreutils (assoc-ref inputs "coreutils"))
587 (inetutils (assoc-ref inputs "inetutils"))
588 (net-tools (assoc-ref inputs "net-tools"))
589 (sed (assoc-ref inputs "sed")))
590 (substitute* "client/scripts/linux"
591 (("/sbin/ip")
592 (string-append (assoc-ref inputs "iproute")
593 "/sbin/ip")))
594
595 (mkdir-p libexec)
596 (copy-file "client/scripts/linux"
597 (string-append libexec "/dhclient-script"))
598
599 (wrap-program
600 (string-append libexec "/dhclient-script")
601 `("PATH" ":" prefix
602 ,(map (lambda (dir)
603 (string-append dir "/bin:"
604 dir "/sbin"))
605 (list inetutils net-tools coreutils sed))))))))))
606
607 (native-inputs `(("perl" ,perl)))
608
609 (inputs `(("inetutils" ,inetutils)
610 ("net-tools" ,net-tools)
611 ("iproute" ,iproute)
612
613 ;; XXX isc-dhcp bundles a copy of bind that has security
614 ;; flaws, so we use a newer version.
615 ("bind-source-tarball"
616 ,(origin
617 (method url-fetch)
618 (uri (string-append "http://ftp.isc.org/isc/bind9/"
619 bind-version
620 "/bind-" bind-version ".tar.gz"))
621 (sha256
622 (base32
623 "00yh1d5shrq7y0kfwacax4f8dc0akaa2fha430j92n7mshms65m1"))))
624
625 ;; When cross-compiling, we need the cross Coreutils and sed.
626 ;; Otherwise just use those from %FINAL-INPUTS.
627 ,@(if (%current-target-system)
628 `(("coreutils" ,coreutils)
629 ("sed" ,sed))
630 '())))
631
632 (home-page "http://www.isc.org/products/DHCP/")
633 (synopsis "Dynamic Host Configuration Protocol (DHCP) tools")
634 (description
635 "ISC's Dynamic Host Configuration Protocol (DHCP) distribution provides a
636 reference implementation of all aspects of DHCP, through a suite of DHCP
637 tools: server, client, and relay agent.")
638 (license license:isc)
639 (properties '((cpe-name . "dhcp"))))))
640
641 (define-public libpcap
642 (package
643 (name "libpcap")
644 (version "1.8.1")
645 (source (origin
646 (method url-fetch)
647 (uri (string-append "http://www.tcpdump.org/release/libpcap-"
648 version ".tar.gz"))
649 (sha256
650 (base32
651 "07jlhc66z76dipj4j5v3dig8x6h3k6cb36kmnmpsixf3zmlvqgb7"))))
652 (build-system gnu-build-system)
653 (native-inputs `(("bison" ,bison) ("flex" ,flex)))
654 (arguments '(#:configure-flags '("--with-pcap=linux")
655 #:tests? #f)) ; no 'check' target
656 (home-page "http://www.tcpdump.org")
657 (synopsis "Network packet capture library")
658 (description
659 "libpcap is an interface for user-level packet capture. It provides a
660 portable framework for low-level network monitoring. Applications include
661 network statistics collection, security monitoring, network debugging, etc.")
662
663 ;; fad-*.c and a couple other files are BSD-4, but the rest is BSD-3.
664 (license license:bsd-3)))
665
666 (define-public tcpdump
667 (package
668 (name "tcpdump")
669 (version "4.9.2")
670 (source (origin
671 (method url-fetch)
672 (uri (string-append "http://www.tcpdump.org/release/tcpdump-"
673 version ".tar.gz"))
674 (sha256
675 (base32
676 "0ygy0layzqaj838r5xd613iraz09wlfgpyh7pc6cwclql8v3b2vr"))))
677 (build-system gnu-build-system)
678 (inputs `(("libpcap" ,libpcap)
679 ("openssl" ,openssl)))
680 (native-inputs `(("perl" ,perl))) ; for tests
681 (home-page "http://www.tcpdump.org/")
682 (synopsis "Network packet analyzer")
683 (description
684 "Tcpdump is a command-line tool to analyze network traffic passing
685 through the network interface controller.")
686 (license license:bsd-3)))
687
688 (define-public jnettop
689 (package
690 (name "jnettop")
691 (version "0.13.0")
692 (source (origin
693 (method url-fetch)
694 (uri (string-append "http://jnettop.kubs.info/dist/jnettop-"
695 version ".tar.gz"))
696 (sha256
697 (base32
698 "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9"))))
699 (build-system gnu-build-system)
700 (native-inputs
701 `(("pkg-config" ,pkg-config)))
702 (inputs
703 `(("glib" ,glib)
704 ("ncurses" ,ncurses)
705 ("libpcap" ,libpcap)))
706 (home-page "http://jnettop.kubs.info/")
707 (synopsis "Visualize network traffic by bandwidth use")
708 (description
709 "Jnettop is a traffic visualiser, which captures traffic going
710 through the host it is running from and displays streams sorted
711 by bandwidth they use.")
712 (license license:gpl2+)))
713
714 (define-public clusterssh
715 (package
716 (name "clusterssh")
717 (version "3.28")
718 (source (origin
719 (method url-fetch)
720 (uri (string-append "mirror://sourceforge/clusterssh/"
721 "1.%20ClusterSSH%20Series%203/" version
722 "/clusterssh-" version ".tar.gz"))
723 (sha256
724 (base32
725 "1bwggpvaj2al5blg1ynapviv2kpydffpzq2zkhi81najnvzc1rr7"))))
726 (build-system gnu-build-system)
727 (inputs `(("perl" ,perl)))
728 (propagated-inputs `(("xterm" ,xterm)
729 ("perl-tk" ,perl-tk)
730 ("perl-x11-protocol" ,perl-x11-protocol)))
731 (arguments
732 `(#:phases
733 (modify-phases %standard-phases
734 (add-after 'install 'set-load-paths
735 (lambda* (#:key inputs outputs #:allow-other-keys)
736 ;; Put the perl-tk and perl-x11-protocol modules in the perl inc
737 ;; path for PROG
738 (let* ((out (assoc-ref outputs "out"))
739 (prog (string-append out "/bin/cssh"))
740 (perl-ver ,(package-version perl))
741 (x11-inc (string-append
742 (assoc-ref inputs "perl-x11-protocol")
743 "/lib/perl5/site_perl/" perl-ver))
744 (tk-inc (string-append
745 (assoc-ref inputs "perl-tk")
746 "/lib/perl5/site_perl/" perl-ver
747 "/x86_64-linux")))
748 (wrap-program
749 prog
750 `("PERL5LIB" ":" prefix (,x11-inc ,tk-inc))))
751 #t)))))
752 ;; The clusterssh.sourceforge.net address requires login to view
753 (home-page "https://sourceforge.net/projects/clusterssh/")
754 (synopsis "Secure concurrent multi-server terminal control")
755 (description
756 "ClusterSSH controls a number of xterm windows via a single graphical
757 console window to allow commands to be interactively run on multiple servers
758 over ssh connections.")
759 (license license:gpl2+)))
760
761 (define-public rename
762 (package
763 (name "rename")
764 (version "0.20")
765 (source (origin
766 (method url-fetch)
767 (uri (string-append
768 "mirror://cpan/authors/id/R/RM/RMBARKER/File-Rename-"
769 version ".tar.gz"))
770 (sha256
771 (base32
772 "1cf6xx2hiy1xalp35fh8g73j67r0w0g66jpcbc6971x9jbm7bvjy"))))
773 (build-system perl-build-system)
774 (native-inputs
775 `(("perl-module-build" ,perl-module-build)
776 ("perl-test-pod" ,perl-test-pod)
777 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
778 (home-page "https://metacpan.org/pod/distribution/File-Rename/rename.PL")
779 (synopsis "Perl extension for renaming multiple files")
780 (description
781 "This package provides a Perl interface (@code{Perl::Rename}) as well
782 as a command-line utility (@command{rename}) that can rename multiple files
783 at once based on a Perl regular expression.")
784 (license license:perl-license)))
785
786 (define-public rottlog
787 (package
788 (name "rottlog")
789 (version "0.72.2")
790 (source (origin
791 (method url-fetch)
792 (uri (string-append "mirror://gnu/rottlog/rottlog-"
793 version ".tar.gz"))
794 (sha256
795 (base32
796 "0751mb9l2f0jrk3vj6q8ilanifd121dliwk0c34g8k0dlzsv3kd7"))
797 (modules '((guix build utils)))
798 (snippet
799 '(substitute* "Makefile.in"
800 (("-o \\$\\{LOG_OWN\\} -g \\$\\{LOG_GROUP\\}")
801 ;; Don't try to chown root.
802 "")
803 (("mkdir -p \\$\\(ROTT_STATDIR\\)")
804 ;; Don't attempt to create /var/lib/rottlog.
805 "true")))))
806 (build-system gnu-build-system)
807 (arguments
808 '(#:configure-flags (list "ROTT_ETCDIR=/etc/rottlog" ;rc file location
809 "--localstatedir=/var")
810
811 ;; Install example config files in OUT/etc.
812 #:make-flags (list (string-append "ROTT_ETCDIR="
813 (assoc-ref %outputs "out")
814 "/etc"))
815
816 #:phases (modify-phases %standard-phases
817 (add-after 'unpack 'patch-paths
818 (lambda _
819 (substitute* "rc/rc"
820 (("/usr/sbin/sendmail") "sendmail"))
821 #t))
822 (add-after 'build 'set-packdir
823 (lambda _
824 ;; Set a default location for archived logs.
825 (substitute* "rc/rc"
826 (("packdir=\"\"")
827 "packdir=\"/var/log\""))
828 #t))
829 (add-before 'install 'tweak-rc-weekly
830 (lambda _
831 (substitute* "rc/weekly"
832 (("/bin/kill")
833 (which "kill"))
834 (("syslogd\\.pid")
835 ;; The file is called 'syslog.pid' (no 'd').
836 "syslog.pid"))
837 #t))
838 (add-after 'install 'install-info
839 (lambda _
840 (zero? (system* "make" "install-info")))))))
841 (native-inputs `(("texinfo" ,texinfo)
842 ("util-linux" ,util-linux))) ; for 'cal'
843 (home-page "https://www.gnu.org/software/rottlog/")
844 (synopsis "Log rotation and management")
845 (description
846 "GNU Rot[t]log is a program for managing log files. It is used to
847 automatically rotate out log files when they have reached a given size or
848 according to a given schedule. It can also be used to automatically compress
849 and archive such logs. Rot[t]log will mail reports of its activity to the
850 system administrator.")
851 (license license:gpl3+)))
852
853 (define-public sudo
854 (package
855 (name "sudo")
856 (version "1.8.21p2")
857 (source (origin
858 (method url-fetch)
859 (uri
860 (list (string-append "https://www.sudo.ws/sudo/dist/sudo-"
861 version ".tar.gz")
862 (string-append "ftp://ftp.sudo.ws/pub/sudo/OLD/sudo-"
863 version ".tar.gz")))
864 (sha256
865 (base32
866 "0s33szq6q59v5s377l4v6ybsdy7pfq6sz7y364j4x09ssdn79ibl"))
867 (modules '((guix build utils)))
868 (snippet
869 '(delete-file-recursively "lib/zlib"))))
870 (build-system gnu-build-system)
871 (arguments
872 `(#:configure-flags
873 (list "--with-logpath=/var/log/sudo.log"
874 "--with-rundir=/var/run/sudo" ;must be cleaned up at boot time
875 "--with-vardir=/var/db/sudo"
876 "--with-iologdir=/var/log/sudo-io"
877
878 ;; 'visudo.c' expects _PATH_MV to be defined, but glibc doesn't
879 ;; provide it.
880 (string-append "CPPFLAGS=-D_PATH_MV='\""
881 (assoc-ref %build-inputs "coreutils")
882 "/bin/mv\"'"))
883
884 ;; Avoid non-determinism; see <http://bugs.gnu.org/21918>.
885 #:parallel-build? #f
886
887 #:phases
888 (modify-phases %standard-phases
889 (add-before 'configure 'pre-configure
890 (lambda _
891 (substitute* "src/sudo_usage.h.in"
892 ;; Do not capture 'configure' arguments since we would
893 ;; unduly retain references, and also because the
894 ;; CPPFLAGS above would close the string literal
895 ;; prematurely.
896 (("@CONFIGURE_ARGS@") "\"\""))
897 (substitute* (find-files "." "Makefile\\.in")
898 (("-o [[:graph:]]+ -g [[:graph:]]+")
899 ;; Allow installation as non-root.
900 "")
901 (("^install: (.*)install-sudoers(.*)" _ before after)
902 ;; Don't try to create /etc/sudoers.
903 (string-append "install: " before after "\n"))
904 (("\\$\\(DESTDIR\\)\\$\\(rundir\\)")
905 ;; Don't try to create /run/sudo.
906 "$(TMPDIR)/dummy")
907 (("\\$\\(DESTDIR\\)\\$\\(vardir\\)")
908 ;; Don't try to create /var/db/sudo.
909 "$(TMPDIR)/dummy"))
910 #t)))
911
912 ;; XXX: The 'testsudoers' test series expects user 'root' to exist, but
913 ;; the chroot's /etc/passwd doesn't have it. Turn off the tests.
914 #:tests? #f))
915 (inputs
916 `(("groff" ,groff)
917 ("linux-pam" ,linux-pam)
918 ("zlib" ,zlib)
919 ("coreutils" ,coreutils)))
920 (home-page "https://www.sudo.ws/")
921 (synopsis "Run commands as root")
922 (description
923 "Sudo (su \"do\") allows a system administrator to delegate authority to
924 give certain users (or groups of users) the ability to run some (or all)
925 commands as root or another user while providing an audit trail of the
926 commands and their arguments.")
927
928 ;; See <http://www.sudo.ws/sudo/license.html>.
929 (license license:x11)))
930
931 (define-public wpa-supplicant-minimal
932 (package
933 (name "wpa-supplicant-minimal")
934 (version "2.6")
935 (source (origin
936 (method url-fetch)
937 (uri (string-append
938 "http://w1.fi/releases/wpa_supplicant-"
939 version
940 ".tar.gz"))
941 (patches (search-patches "wpa-supplicant-CVE-2017-13082.patch"
942 "wpa-supplicant-fix-key-reuse.patch"
943 "wpa-supplicant-fix-zeroed-keys.patch"
944 "wpa-supplicant-fix-nonce-reuse.patch"
945 "wpa-supplicant-krack-followups.patch"))
946 (sha256
947 (base32
948 "0l0l5gz3d5j9bqjsbjlfcv4w4jwndllp9fmyai4x9kg6qhs6v4xl"))))
949 (build-system gnu-build-system)
950 (arguments
951 '(#:phases
952 (modify-phases %standard-phases
953 (replace 'configure
954 (lambda* (#:key outputs #:allow-other-keys)
955 (chdir "wpa_supplicant")
956 (copy-file "defconfig" ".config")
957 (let ((port (open-file ".config" "al")))
958 (display "
959 CONFIG_DEBUG_SYSLOG=y
960
961 # Choose GnuTLS (the default is OpenSSL.)
962 CONFIG_TLS=gnutls
963
964 CONFIG_DRIVER_NL80211=y
965 CFLAGS += $(shell pkg-config libnl-3.0 --cflags)
966 CONFIG_LIBNL32=y
967 CONFIG_READLINE=y\n" port)
968 (close-port port))))
969 (add-after 'install 'install-man-pages
970 (lambda* (#:key outputs #:allow-other-keys)
971 (let* ((out (assoc-ref outputs "out"))
972 (man (string-append out "/share/man"))
973 (man5 (string-append man "/man5"))
974 (man8 (string-append man "/man8")))
975 (define (copy-man-page target)
976 (lambda (file)
977 (install-file file target)))
978
979 (mkdir-p man5) (mkdir man8)
980 (for-each (copy-man-page man5)
981 (find-files "doc/docbook" "\\.5"))
982 (for-each (copy-man-page man8)
983 (find-files "doc/docbook" "\\.8"))
984 #t))))
985
986 #:make-flags (list "CC=gcc"
987 (string-append "BINDIR=" (assoc-ref %outputs "out")
988 "/sbin")
989 (string-append "LIBDIR=" (assoc-ref %outputs "out")
990 "/lib"))
991 #:tests? #f))
992 (inputs
993 `(("readline" ,readline)
994 ("libnl" ,libnl)
995 ("gnutls" ,gnutls)
996 ("libgcrypt" ,libgcrypt))) ;needed by crypto_gnutls.c
997 (native-inputs
998 `(("pkg-config" ,pkg-config)))
999 (home-page "http://w1.fi/wpa_supplicant/")
1000 (synopsis "Connecting to WPA and WPA2-protected wireless networks")
1001 (description
1002 "wpa_supplicant is a WPA Supplicant with support for WPA and WPA2 (IEEE
1003 802.11i / RSN). Supplicant is the IEEE 802.1X/WPA component that is used in
1004 the client stations. It implements key negotiation with a WPA Authenticator
1005 and it controls the roaming and IEEE 802.11 authentication/association of the
1006 WLAN driver.
1007
1008 This package provides the 'wpa_supplicant' daemon and the 'wpa_cli' command.")
1009
1010 ;; In practice, this is linked against Readline, which makes it GPLv3+.
1011 (license license:bsd-3)))
1012
1013 (define-public wpa-supplicant
1014 (package (inherit wpa-supplicant-minimal)
1015 (name "wpa-supplicant")
1016 (inputs `(("dbus" ,dbus)
1017 ,@(package-inputs wpa-supplicant-minimal)))
1018 (arguments
1019 (substitute-keyword-arguments (package-arguments wpa-supplicant-minimal)
1020 ((#:phases phases)
1021 `(modify-phases ,phases
1022 (add-after 'configure 'configure-for-dbus
1023 (lambda _
1024 (let ((port (open-file ".config" "al")))
1025 (display "
1026 CONFIG_CTRL_IFACE_DBUS=y
1027 CONFIG_CTRL_IFACE_DBUS_NEW=y
1028 CONFIG_CTRL_IFACE_DBUS_INTRO=y\n" port)
1029 (close-port port))
1030 #t))
1031 (add-after 'install-man-pages 'install-dbus-conf
1032 (lambda* (#:key outputs #:allow-other-keys)
1033 (let* ((out (assoc-ref outputs "out"))
1034 (dir (string-append out "/etc/dbus-1/system.d")))
1035 (mkdir-p dir)
1036 (copy-file "dbus/dbus-wpa_supplicant.conf"
1037 (string-append dir "/wpa_supplicant.conf")))
1038 #t))))))))
1039
1040 (define-public wakelan
1041 (package
1042 (name "wakelan")
1043 (version "1.1")
1044 (source (origin
1045 (method url-fetch)
1046 (uri (string-append
1047 "ftp://ftp.gwdg.de/pub/linux/metalab/system/network/misc/wakelan-"
1048 version ".tar.gz"))
1049 (sha256
1050 (base32
1051 "0vydqpf44146ir6k87gmqaq6xy66xhc1gkr3nsd7jj3nhy7ypx9x"))))
1052 (build-system gnu-build-system)
1053 (arguments
1054 '(#:phases
1055 (modify-phases %standard-phases
1056 (replace 'configure
1057 (lambda* (#:key outputs #:allow-other-keys)
1058 (let ((out (assoc-ref outputs "out")))
1059 (mkdir-p (string-append out "/bin"))
1060 (mkdir-p (string-append out "/share/man/man1"))
1061
1062 ;; It's an old configure script that doesn't understand
1063 ;; the extra options we pass.
1064 (setenv "CONFIG_SHELL" (which "bash"))
1065 (zero?
1066 (system* "./configure"
1067 (string-append "--prefix=" out)
1068 (string-append "--mandir=" out
1069 "/share/man")))))))
1070 #:tests? #f))
1071 (home-page "http://kernel.org") ; really, no home page
1072 (synopsis "Send a wake-on-LAN packet")
1073 (description
1074 "WakeLan broadcasts a properly formatted UDP packet across the local area
1075 network, which causes enabled computers to power on.")
1076 (license license:gpl2+)))
1077
1078 (define-public dmidecode
1079 (package
1080 (name "dmidecode")
1081 (version "3.1")
1082 (source (origin
1083 (method url-fetch)
1084 (uri (string-append
1085 "mirror://savannah/dmidecode/dmidecode-"
1086 version ".tar.xz"))
1087 (sha256
1088 (base32
1089 "1h0sg0lxa15nzf8s7884p6q7p6md9idm0c79wyqmk32l4ndwwrnp"))))
1090 (build-system gnu-build-system)
1091 (arguments
1092 '(#:phases (modify-phases %standard-phases (delete 'configure))
1093 #:tests? #f ; no 'check' target
1094 #:make-flags (list (string-append "prefix="
1095 (assoc-ref %outputs "out")))))
1096 (home-page "http://www.nongnu.org/dmidecode/")
1097 (synopsis "Read hardware information from the BIOS")
1098 (description
1099 "Dmidecode reports information about your system's hardware as described
1100 in your system BIOS according to the SMBIOS/DMI standard. This typically
1101 includes system manufacturer, model name, serial number, BIOS version, asset
1102 tag as well as a lot of other details of varying level of interest and
1103 reliability depending on the manufacturer. This will often include usage
1104 status for the CPU sockets, expansion slots (e.g. AGP, PCI, ISA) and memory
1105 module slots, and the list of I/O ports (e.g. serial, parallel, USB).")
1106 (license license:gpl2+)))
1107
1108 (define-public acpica
1109 (package
1110 (name "acpica")
1111 (version "20171110")
1112 (source (origin
1113 (method url-fetch)
1114 (uri (string-append
1115 "https://acpica.org/sites/acpica/files/acpica-unix2-"
1116 version ".tar.gz"))
1117 (sha256
1118 (base32
1119 "08g83qvhfx04vzb3f3pfpkp0w601v6csjzdv7z1vjzz1k71h7yml"))))
1120 (build-system gnu-build-system)
1121 (native-inputs `(("flex" ,flex)
1122 ("bison" ,bison)))
1123 (arguments
1124 '(#:make-flags (list (string-append "PREFIX=" %output)
1125 "CC=gcc"
1126 "HOST=_LINUX"
1127 "OPT_CFLAGS=-Wall -fno-strict-aliasing")
1128 #:tests? #f ; no 'check' target.
1129 #:phases (modify-phases %standard-phases (delete 'configure))))
1130 (home-page "https://acpica.org/")
1131 (synopsis "Tools for the development and debug of ACPI tables")
1132 (description
1133 "The ACPI Component Architecture (@dfn{ACPICA}) project provides an
1134 OS-independent reference implementation of the Advanced Configuration and
1135 Power Interface Specification (@dfn{ACPI}). ACPICA code contains those portions
1136 of ACPI meant to be directly integrated into the host OS as a kernel-resident
1137 subsystem, and a small set of tools to assist in developing and debugging ACPI
1138 tables. This package contains only the user-space tools needed for ACPI table
1139 development, not the kernel implementation of ACPI.")
1140 (license license:gpl2))) ; Dual GPLv2/ACPICA Licence
1141
1142 (define-public stress
1143 (package
1144 (name "stress")
1145 (version "1.0.1")
1146 (source (origin
1147 (method url-fetch)
1148 (uri (string-append "mirror://debian/pool/main/s/stress/stress_"
1149 version ".orig.tar.gz"))
1150 (sha256
1151 (base32
1152 "1v9vnzlihqfjsxa93hdbrq72pqqk00dkylmlg8jpxhm7s1w9qfl1"))))
1153 (build-system gnu-build-system)
1154 (home-page "http://packages.debian.org/wheezy/stress")
1155 (synopsis "Impose load on and stress test a computer system")
1156 (description
1157 "Stress is a tool that imposes a configurable amount of CPU, memory, I/O,
1158 or disk stress on a POSIX-compliant operating system and reports any errors it
1159 detects.
1160
1161 Stress is not a benchmark. It is a tool used by system administrators to
1162 evaluate how well their systems will scale, by kernel programmers to evaluate
1163 perceived performance characteristics, and by systems programmers to expose
1164 the classes of bugs which only or more frequently manifest themselves when the
1165 system is under heavy load.")
1166 (license license:gpl2+)))
1167
1168 (define-public detox
1169 (package
1170 (name "detox")
1171 (version "1.2.0")
1172 (source (origin
1173 (method url-fetch)
1174 (uri (string-append "mirror://sourceforge/detox/detox/" version
1175 "/detox-" version ".tar.bz2"))
1176 (sha256
1177 (base32
1178 "1y6vvjqsg54kl49cry73jbfhr04s7wjs779vrr9zrq6kww7dkymb"))))
1179 (build-system gnu-build-system)
1180 ;; Both flex and popt are used in this case for their runtime libraries
1181 ;; (libfl and libpopt).
1182 (inputs
1183 `(("flex" ,flex)
1184 ("popt" ,popt)))
1185 (arguments
1186 `(#:configure-flags `(,(string-append "--with-popt="
1187 (assoc-ref %build-inputs "popt")))
1188 #:tests? #f)) ;no 'check' target
1189 (home-page "http://detox.sourceforge.net")
1190 (synopsis "Clean up file names")
1191 (description
1192 "Detox is a program that renames files to make them easier to work with
1193 under Unix and related operating systems. Spaces and various other unsafe
1194 characters (such as \"$\") get replaced with \"_\". ISO 8859-1 (Latin-1)
1195 characters can be replaced as well, as can UTF-8 characters.")
1196 (license license:bsd-3)))
1197
1198 (define-public testdisk
1199 (package
1200 (name "testdisk")
1201 (version "7.0")
1202 (source (origin
1203 (method url-fetch)
1204 (uri (string-append "http://www.cgsecurity.org/testdisk-"
1205 version ".tar.bz2"))
1206 (sha256
1207 (base32
1208 "0ba4wfz2qrf60vwvb1qsq9l6j0pgg81qgf7fh22siaz649mkpfq0"))))
1209 (build-system gnu-build-system)
1210 (inputs
1211 `(("ntfs-3g" ,ntfs-3g)
1212 ("util-linux" ,util-linux)
1213 ("openssl" ,openssl)
1214 ;; FIXME: add reiserfs
1215 ("zlib" ,zlib)
1216 ("e2fsprogs" ,e2fsprogs)
1217 ("libjpeg" ,libjpeg)
1218 ("ncurses" ,ncurses)))
1219 (home-page "http://www.cgsecurity.org/wiki/TestDisk")
1220 (synopsis "Data recovery tool")
1221 (description
1222 "TestDisk is a program for data recovery, primarily designed to help
1223 recover lost partitions and/or make non-booting disks bootable again.")
1224 (license license:gpl2+)))
1225
1226 (define-public tree
1227 (package
1228 (name "tree")
1229 (version "1.7.0")
1230 (source (origin
1231 (method url-fetch)
1232 (uri (string-append
1233 "http://mama.indstate.edu/users/ice/tree/src/tree-"
1234 version ".tgz"))
1235 (sha256
1236 (base32 "04kviw799qxly08zb8n5mgxfd96gyis6x69q2qiw86jnh87c4mv9"))))
1237 (build-system gnu-build-system)
1238 (arguments
1239 '(#:phases (modify-phases %standard-phases (delete 'configure))
1240 #:tests? #f ; no check target
1241 #:make-flags (let ((out (assoc-ref %outputs "out")))
1242 (list (string-append "prefix=" out)))))
1243 (synopsis "Recursively list the contents of a directory")
1244 (description
1245 "Tree is a recursive directory listing command that produces a depth
1246 indented listing of files, which is colorized ala dircolors if the LS_COLORS
1247 environment variable is set and output is to tty.")
1248 (home-page "http://mama.indstate.edu/users/ice/tree/")
1249 (license license:gpl2+)))
1250
1251 (define-public direvent
1252 (package
1253 (name "direvent")
1254 (version "5.1")
1255 (source (origin
1256 (method url-fetch)
1257 (uri (string-append "mirror://gnu/direvent/direvent-"
1258 version ".tar.gz"))
1259 (sha256
1260 (base32
1261 "1nwvjmx7kb14ni34c0b8x9a3791pc20gvhj7xaj66d8q4h6n0qf4"))
1262 (modules '((guix build utils)))
1263 (snippet '(substitute* "tests/testsuite"
1264 (("#![[:blank:]]?/bin/sh")
1265 "#!$SHELL")))))
1266 (build-system gnu-build-system)
1267 (arguments
1268 '(#:phases
1269 (modify-phases %standard-phases
1270 (add-before 'build 'patch-/bin/sh
1271 (lambda* (#:key inputs #:allow-other-keys)
1272 ;; Use the right shell when executing the watcher and
1273 ;; user-provided shell commands.
1274 (let ((bash (assoc-ref inputs "bash")))
1275 (substitute* '("src/direvent.c" "src/progman.c")
1276 (("\"/bin/sh\"")
1277 (string-append "\"" bash "/bin/sh\"")))
1278
1279 ;; Adjust the 'shell.at' test accordingly.
1280 (substitute* "tests/testsuite"
1281 (("SHELL=/bin/sh")
1282 (string-append "SHELL=" bash "/bin/sh")))
1283
1284 #t))))))
1285 (home-page "https://www.gnu.org/software/direvent/")
1286 (synopsis "Daemon to monitor directories for events such as file removal")
1287 (description
1288 "A daemon that monitors directories for events, such as creating,
1289 deleting or modifying files. It can monitor different sets of directories for
1290 different events. When an event is detected, direvent calls a specified
1291 external program with information about the event, such as the location
1292 within the file system where it occurred. Thus, \"direvent\" provides an
1293 easy way to react immediately if given files undergo changes, for example, to
1294 track changes in important system configuration files.")
1295 (license license:gpl3+)))
1296
1297 (define-public libcap-ng
1298 (package
1299 (name "libcap-ng")
1300 (version "0.7.4")
1301 (source (origin
1302 (method url-fetch)
1303 (uri (string-append
1304 "http://people.redhat.com/sgrubb/libcap-ng/libcap-ng-"
1305 version ".tar.gz"))
1306 (sha256
1307 (base32
1308 "0ssvnh4cvhya0c1j6k6192zvqcq7nc0x01fb5nwhr0prfqr0i8j8"))))
1309 (build-system gnu-build-system)
1310 (inputs `(("python" ,python)))
1311 (home-page "https://people.redhat.com/sgrubb/libcap-ng/")
1312 (synopsis "Library for more easily working with POSIX capabilities")
1313 (description
1314 "The libcap-ng library is intended to make programming with POSIX
1315 capabilities easier than the traditional libcap library. It includes
1316 utilities that can analyse all currently running applications and print out
1317 any capabilities and whether or not it has an open ended bounding set. The
1318 included utilities are designed to let admins and developers spot apps from
1319 various ways that may be running with too much privilege.")
1320 ;; The library is lgpl2.1+, but also ships some utils which are gpl2+.
1321 (license (list license:lgpl2.1+ license:gpl2+))))
1322
1323 (define-public smartmontools
1324 (package
1325 (name "smartmontools")
1326 (version "6.6")
1327 (source (origin
1328 (method url-fetch)
1329 (uri (string-append
1330 "mirror://sourceforge/smartmontools/smartmontools/"
1331 version "/smartmontools-" version ".tar.gz"))
1332 (sha256
1333 (base32
1334 "0m1hllbb78rr6cxkbalmz1gqkl0psgq8rrmv4gwcmz34n07kvx2i"))))
1335 (build-system gnu-build-system)
1336 (inputs `(("libcap-ng" ,libcap-ng)))
1337 (home-page "https://www.smartmontools.org/")
1338 (synopsis "S.M.A.R.T. harddisk control and monitoring tools")
1339 (description
1340 "The smartmontools package contains utility programs to control and
1341 monitor storage systems using the Self-Monitoring, Analysis and Reporting
1342 Technology System (@dfn{S.M.A.R.T.}) built into most modern ATA and SCSI hard
1343 disks. In many cases, these utilities will provide advanced warning of disk
1344 degradation and failure.")
1345 (license license:gpl2+)))
1346
1347 (define-public fdupes
1348 (package
1349 (name "fdupes")
1350 (version "1.6.1")
1351 (source
1352 (origin
1353 (method url-fetch)
1354 (uri (string-append
1355 "https://github.com/adrianlopezroche/fdupes/archive/v"
1356 version ".tar.gz"))
1357 (file-name (string-append name "-" version ".tar.gz"))
1358 (sha256
1359 (base32
1360 "1sj9pa40pbz6xdwbxfwhdhkvhdf1xc5gvggk9mdq26c41gdnyswx"))))
1361 (build-system gnu-build-system)
1362 (arguments
1363 '(#:phases (modify-phases %standard-phases
1364 (delete 'configure))
1365 #:tests? #f ; no 'check' target
1366 #:make-flags (list "CC=gcc"
1367 (string-append "PREFIX="
1368 (assoc-ref %outputs "out")))))
1369 (home-page "https://github.com/adrianlopezroche/fdupes")
1370 (synopsis "Identify duplicate files")
1371 (description
1372 "fdupes is a program for identifying duplicate files residing within
1373 specified directories.")
1374 (license license:expat)))
1375
1376 (define-public graphios
1377 (package
1378 (name "graphios")
1379 (version "2.0.3")
1380 (source
1381 (origin
1382 (method url-fetch)
1383 (uri (string-append
1384 "https://pypi.python.org/packages/source/g/graphios/graphios-"
1385 version ".tar.gz"))
1386 (sha256
1387 (base32
1388 "1h87hvc315wg6lklbf4l7csd3n5pgljwrfli1p3nasdi0izgn66i"))))
1389 (build-system python-build-system)
1390 (arguments
1391 ;; Be warned: Building with Python 3 succeeds, but the build process
1392 ;; throws a syntax error that is ignored.
1393 `(#:python ,python-2
1394 #:phases
1395 (modify-phases %standard-phases
1396 (add-before 'build 'fix-setup.py
1397 (lambda* (#:key outputs #:allow-other-keys)
1398 ;; Fix hardcoded, unprefixed file names.
1399 (let ((out (assoc-ref outputs "out")))
1400 (substitute* '("setup.py")
1401 (("/etc") (string-append out "/etc"))
1402 (("/usr") out)
1403 (("distro_ver = .*") "distro_ver = ''"))
1404 #t))))))
1405 (home-page "https://github.com/shawn-sterling/graphios")
1406 (synopsis "Emit Nagios metrics to Graphite, Statsd, and Librato")
1407 (description
1408 "Graphios is a script to emit nagios perfdata to various upstream metrics
1409 processing and time-series systems. It's currently compatible with Graphite,
1410 Statsd, Librato and InfluxDB. Graphios can emit Nagios metrics to any number
1411 of supported upstream metrics systems simultaneously.")
1412 (license license:gpl2+)))
1413
1414 (define-public ansible
1415 (package
1416 (name "ansible")
1417 (version "2.4.2.0")
1418 (source
1419 (origin
1420 (method url-fetch)
1421 (uri (pypi-uri "ansible" version))
1422 (sha256
1423 (base32
1424 "0n3n9py4s3aykiii31xq8g4wmd6693jvby0424pjrg0bna01apri"))
1425 (patches (search-patches "ansible-wrap-program-hack.patch"))))
1426 (build-system python-build-system)
1427 (native-inputs
1428 `(("python2-pycrypto" ,python2-pycrypto)
1429 ("python2-httplib2" ,python2-httplib2)
1430 ("python2-passlib" ,python2-passlib)
1431 ("python2-nose" ,python2-nose)
1432 ("python2-mock" ,python2-mock)
1433 ("python2-jinja2" ,python2-jinja2)
1434 ("python2-pyyaml" ,python2-pyyaml)
1435 ("python2-paramiko" ,python2-paramiko)))
1436 (inputs
1437 `(("python2-pycrypto" ,python2-pycrypto)
1438 ("python2-jinja2" ,python2-jinja2)
1439 ("python2-pyyaml" ,python2-pyyaml)
1440 ("python2-paramiko" ,python2-paramiko)))
1441 (arguments
1442 `(#:python ,python-2)) ; incompatible with Python 3
1443 (home-page "https://www.ansible.com/")
1444 (synopsis "Radically simple IT automation")
1445 (description "Ansible is a radically simple IT automation system. It
1446 handles configuration management, application deployment, cloud provisioning,
1447 ad hoc task execution, and multinode orchestration---including trivializing
1448 things like zero-downtime rolling updates with load balancers.")
1449 (license license:gpl3+)))
1450
1451 (define-public cpulimit
1452 (package
1453 (name "cpulimit")
1454 (version "0.2")
1455 (source
1456 (origin
1457 (method url-fetch)
1458 (uri (string-append "https://github.com/opsengine/cpulimit/archive/v"
1459 version ".tar.gz"))
1460 (file-name (string-append name "-" version ".tar.gz"))
1461 (sha256
1462 (base32
1463 "1nn2w849xd5bw4y5sqnll29nxdwl5h0cv4smc7dwmpb9qnd2ycb4"))))
1464 (build-system gnu-build-system)
1465 (arguments
1466 `(#:phases (modify-phases %standard-phases
1467 (delete 'configure)
1468 (replace
1469 'build
1470 (lambda _
1471 (zero? (system* "make" "CC=gcc" "-Csrc"))))
1472 (replace
1473 'check
1474 (lambda _
1475 (zero? (system* "make" "CC=gcc" "-Ctests"))))
1476 (replace
1477 'install
1478 (lambda* (#:key outputs #:allow-other-keys)
1479 (let* ((out (assoc-ref outputs "out"))
1480 (bin (string-append out "/bin")))
1481 (install-file "src/cpulimit" bin)))))))
1482 (home-page "https://github.com/opsengine/cpulimit")
1483 (synopsis "Limit CPU usage")
1484 (description
1485 "Cpulimit limits the CPU usage of a process. It does not change the nice
1486 value or other scheduling priority settings, but the real CPU usage, and is
1487 able to adapt itself dynamically to the overall system load. Children
1488 processes and threads of the specified process may optionally share the same
1489 limits.")
1490 (license license:gpl2+)))
1491
1492 (define-public autojump
1493 (package
1494 (name "autojump")
1495 (version "22.3.4")
1496 (source
1497 (origin
1498 (method url-fetch)
1499 (uri (string-append "https://github.com/wting/autojump/archive/"
1500 "release-v" version ".tar.gz"))
1501 (file-name (string-append name "-" version ".tar.gz"))
1502 (sha256
1503 (base32
1504 "113rcpr37ngf2xs8da41qdarq5qmj0dwx8ggqy3lhlb0kvqq7g9z"))))
1505 (build-system gnu-build-system)
1506 (native-inputs ;for tests
1507 `(("python-mock" ,python-mock)
1508 ("python-pytest" ,python-pytest)))
1509 (inputs
1510 `(("python" ,python-wrapper)))
1511 (arguments
1512 `(#:phases (modify-phases %standard-phases
1513 (delete 'configure)
1514 (delete 'build)
1515 (replace 'check
1516 (lambda _
1517 (zero?
1518 (system* "python" "tests/unit/autojump_utils_test.py"))))
1519 (replace 'install
1520 ;; The install.py script doesn't allow system installation
1521 ;; into an arbitrary prefix, so do our own install.
1522 (lambda* (#:key outputs #:allow-other-keys)
1523 (let* ((out (assoc-ref outputs "out"))
1524 (bin (string-append out "/bin"))
1525 (share (string-append out "/share/autojump"))
1526 (py (string-append out "/lib/python"
1527 ,(version-major+minor
1528 (package-version python-wrapper))
1529 "/site-packages"))
1530 (man (string-append out "/share/man/man1")))
1531 (install-file "bin/autojump" bin)
1532 (for-each (λ (f) (install-file f py))
1533 (find-files "bin" "\\.py$"))
1534 (for-each (λ (f) (install-file f share))
1535 (find-files "bin" "autojump\\..*$"))
1536 (substitute* (string-append share "/autojump.sh")
1537 (("/usr/local") out))
1538 (install-file "docs/autojump.1" man)
1539 (wrap-program (string-append bin "/autojump")
1540 `("PYTHONPATH" ":" prefix (,py)))
1541 #t))))))
1542 (home-page "https://github.com/wting/autojump")
1543 (synopsis "Shell extension for file system navigation")
1544 (description
1545 "Autojump provides a faster way to navigate your file system, with a \"cd
1546 command that learns\". It works by maintaining a database of the directories
1547 you use the most from the command line and allows you to \"jump\" to
1548 frequently used directories by typing only a small pattern.")
1549 (license license:gpl3+)))
1550
1551 (define-public iftop
1552 (package
1553 (name "iftop")
1554 (version "1.0pre4")
1555 (source (origin
1556 (method url-fetch)
1557 (uri (string-append "http://www.ex-parrot.com/~pdw/iftop/download"
1558 "/iftop-" version ".tar.gz"))
1559 (sha256
1560 (base32
1561 "15sgkdyijb7vbxpxjavh5qm5nvyii3fqcg9mzvw7fx8s6zmfwczp"))))
1562 (build-system gnu-build-system)
1563 (inputs
1564 `(("libpcap" ,libpcap)
1565 ("ncurses" ,ncurses)))
1566 (synopsis "Monitor network usage")
1567 (description "Iftop does for network usage what @command{top} does
1568 for CPU usage. It listens to network traffic on a named interface and
1569 displays a table of current bandwidth usage by pairs of hosts.")
1570 (home-page "http://www.ex-parrot.com/~pdw/iftop/")
1571 (license license:gpl2+)))
1572
1573 (define-public munge
1574 (package
1575 (name "munge")
1576 (version "0.5.13")
1577 (source (origin
1578 (method url-fetch)
1579 (uri (string-append "https://github.com/dun/munge/releases/"
1580 "download/munge-" version "/munge-"
1581 version ".tar.xz"))
1582 (sha256
1583 (base32
1584 "1nj486bbg1adfg298zck96vgx57kchcypc1zdz1n7w540vyksxcr"))))
1585 (inputs
1586 `(("openssl" ,openssl)
1587 ("libgcrypt" ,libgcrypt)))
1588 (build-system gnu-build-system)
1589 (home-page "https://dun.github.io/munge/")
1590 (synopsis "Cluster computing authentication service")
1591 (description
1592 "Munge is an authentication service for creating and validating
1593 credentials. It allows a process to authenticate the UID and GID of another
1594 local or remote process within a group of hosts having common users and
1595 groups. These hosts form a security realm that is defined by a shared
1596 cryptographic key. Clients within this security realm can create and validate
1597 credentials without the use of root privileges, reserved ports, or
1598 platform-specific methods.")
1599 (license license:gpl3+)))
1600
1601 (define-public audit
1602 (package
1603 (name "audit")
1604 (version "2.4.5")
1605 (source (origin
1606 (method url-fetch)
1607 (uri (string-append "http://people.redhat.com/sgrubb/audit/"
1608 "audit-" version ".tar.gz"))
1609 (sha256
1610 (base32
1611 "1q1q51dvxscbi4kbakmd4bn0xrvwwaiwvaya79925cbrqwzxsg77"))))
1612 (build-system gnu-build-system)
1613 (home-page "http://people.redhat.com/sgrubb/audit/")
1614 (arguments
1615 `(#:configure-flags (list "--with-python=no")
1616 #:phases
1617 (modify-phases %standard-phases
1618 (add-after 'unpack 'fix-tests
1619 (lambda _
1620 ;; In the build environmnte /etc/passwd does not contain an entry
1621 ;; for root/0, so we have to patch the expected value.
1622 (substitute* "auparse/test/auparse_test.ref"
1623 (("=0 \\(root\\)") "=0 (unknown(0))"))
1624 #t)))))
1625 (inputs
1626 `(("openldap" ,openldap)
1627 ("gnutls" ,gnutls)
1628 ("sasl" ,cyrus-sasl)))
1629 (synopsis "User-space component to the Linux auditing system")
1630 (description
1631 "auditd is the user-space component to the Linux auditing system, which
1632 allows logging of system calls made by user-land processes. It's responsible
1633 for writing audit records to the disk. Viewing the logs is done with the
1634 @code{ausearch} or @code{aureport} utilities. Configuring the audit rules is
1635 done with the @code{auditctl} utility.")
1636 (license license:gpl2+)))
1637
1638 (define-public nmap
1639 (package
1640 (name "nmap")
1641 (version "7.60")
1642 (source (origin
1643 (method url-fetch)
1644 (uri (string-append "https://nmap.org/dist/nmap-" version
1645 ".tar.bz2"))
1646 (sha256
1647 (base32
1648 "08bga42ipymmbxd7wy4x5sl26c0ir1fm3n9rc6nqmhx69z66wyd8"))
1649 (modules '((guix build utils)))
1650 (snippet
1651 '(map delete-file-recursively
1652 ;; Remove bundled lua, pcap, and pcre libraries.
1653 ;; FIXME: Remove bundled liblinear once packaged.
1654 '("liblua"
1655 "libpcap"
1656 "libpcre"
1657 ;; Remove pre-compiled binares.
1658 "mswin32")))))
1659 (build-system gnu-build-system)
1660 (inputs
1661 `(("openssl" ,openssl)
1662 ("libpcap" ,libpcap)
1663 ("pcre" ,pcre)
1664 ("lua" ,lua)
1665 ;; For 'ndiff'.
1666 ("python" ,python-2)))
1667
1668 ;; TODO Add zenmap output.
1669 (outputs '("out" "ndiff"))
1670 (arguments
1671 '(#:configure-flags '("--without-zenmap")
1672 #:phases
1673 (modify-phases %standard-phases
1674 (add-after 'configure 'patch-Makefile
1675 (lambda _
1676 (substitute* "Makefile"
1677 ;; Do not attempt to build lua.
1678 (("build-dnet build-lua") "build-dnet"))
1679 #t))
1680 (replace 'install
1681 (lambda* (#:key outputs #:allow-other-keys)
1682 (define (make out . args)
1683 (unless (zero? (apply system* "make"
1684 (string-append "prefix=" out)
1685 args))
1686 (error "make failed")))
1687 (define (python-path dir)
1688 (string-append dir "/lib/python2.7/site-packages"))
1689 (let ((out (assoc-ref outputs "out"))
1690 (ndiff (assoc-ref outputs "ndiff")))
1691 (for-each mkdir-p (list out ndiff))
1692 (make out
1693 "install-nmap"
1694 "install-nse"
1695 "install-ncat"
1696 "install-nping")
1697 (make ndiff "install-ndiff")
1698 (wrap-program (string-append ndiff "/bin/ndiff")
1699 `("PYTHONPATH" prefix
1700 (,(python-path ndiff)))))))
1701 ;; These are the tests that do not require network access.
1702 (replace 'check
1703 (lambda _ (zero? (system* "make"
1704 "check-nse"
1705 "check-ndiff"
1706 "check-dns")))))
1707 ;; Nmap can't cope with out-of-source building.
1708 #:out-of-source? #f))
1709 (home-page "https://nmap.org/")
1710 (synopsis "Network discovery and security auditing tool")
1711 (description
1712 "Nmap (\"Network Mapper\") is a network discovery and security auditing
1713 tool. It is also useful for tasks such as network inventory, managing service
1714 upgrade schedules, and monitoring host or service uptime. It also provides an
1715 advanced netcat implementation (ncat), a utility for comparing scan
1716 results (ndiff), and a packet generation and response analysis tool (nping).")
1717 ;; This package uses nmap's bundled versions of libdnet and liblinear, which
1718 ;; both use a 3-clause BSD license.
1719 (license (list license:nmap license:bsd-3))))
1720
1721 (define-public dstat
1722 (package
1723 (name "dstat")
1724 (version "0.7.3")
1725 (source (origin
1726 (method url-fetch)
1727 (uri (string-append
1728 "https://github.com/dagwieers/dstat/archive/"
1729 version ".tar.gz"))
1730 (file-name (string-append "dstat-" version ".tar.gz"))
1731 (sha256
1732 (base32
1733 "16286z3y2lc9nsq8njzjkv6k2vyxrj9xiixj1k3gnsbvhlhkirj6"))))
1734 (build-system gnu-build-system)
1735 (arguments
1736 `(#:tests? #f ;; no make check
1737 #:make-flags (let ((out (assoc-ref %outputs "out")))
1738 (list (string-append "DESTDIR=" out)
1739 "prefix=/"))
1740 ;; no configure script
1741 #:phases (modify-phases %standard-phases (delete 'configure))))
1742 (inputs `(("python-2" ,python-2)))
1743 (synopsis "Versatile resource statistics tool")
1744 (description "Dstat is a versatile replacement for @command{vmstat},
1745 @command{iostat}, @command{netstat}, and @command{ifstat}. Dstat overcomes
1746 some of their limitations and adds some extra features, more counters and
1747 flexibility. Dstat is handy for monitoring systems during performance tuning
1748 tests, benchmarks or troubleshooting.
1749
1750 Dstat allows you to view all of your system resources in real-time, you can,
1751 e.g., compare disk utilization in combination with interrupts from your IDE
1752 controller, or compare the network bandwidth numbers directly with the disk
1753 throughput (in the same interval).")
1754 (home-page "http://dag.wiee.rs/home-made/dstat/")
1755 (license license:gpl2+)))
1756
1757 (define-public thefuck
1758 (package
1759 (name "thefuck")
1760 (version "3.19")
1761 (source (origin
1762 (method url-fetch)
1763 (uri (string-append "https://github.com/nvbn/thefuck/archive/"
1764 version ".tar.gz"))
1765 (file-name (string-append name "-" version ".tar.gz"))
1766 (sha256
1767 (base32
1768 "191zbvkyc02h0wwd46xwj4zzg7jhlr8xv0ji6knqkgjnk0nvqq01"))
1769 (patches (search-patches "thefuck-test-environ.patch"))))
1770 (build-system python-build-system)
1771 (arguments
1772 '(#:phases
1773 (modify-phases %standard-phases
1774 (delete 'check)
1775 (add-after 'install 'check
1776 (lambda* (#:key inputs outputs #:allow-other-keys)
1777 ;; Tests look for installed package
1778 (add-installed-pythonpath inputs outputs)
1779 ;; Some tests need write access to $HOME.
1780 (setenv "HOME" "/tmp")
1781 (zero? (system* "py.test" "-v")))))))
1782 (propagated-inputs
1783 `(("python-colorama" ,python-colorama)
1784 ("python-decorator" ,python-decorator)
1785 ("python-psutil" ,python-psutil)
1786 ("python-six" ,python-six)))
1787 (native-inputs
1788 `(("python-mock" ,python-mock)
1789 ("python-pytest" ,python-pytest)
1790 ("python-pytest-mock" ,python-pytest-mock)
1791 ;; Requires setuptools >= 17.1 due to some features used, while our
1792 ;; python currently only includes 12.0. TODO: Remove this input.
1793 ("python-setuptools" ,python-setuptools)))
1794 (home-page "https://github.com/nvbn/thefuck")
1795 (synopsis "Correct mistyped console command")
1796 (description
1797 "The Fuck tries to match a rule for a previous, mistyped command, creates
1798 a new command using the matched rule, and runs it.")
1799 (license license:x11)))
1800
1801 (define-public di
1802 (package
1803 (name "di")
1804 (version "4.44")
1805 (source
1806 (origin
1807 (method url-fetch)
1808 (uri (string-append "https://gentoo.com/di/di-" version ".tar.gz"))
1809 (sha256
1810 (base32 "0803lp8kd3mp1jcm17i019xiqxdy85hhs6xk67zib8gmvg500gcn"))))
1811 (build-system gnu-build-system)
1812 (arguments
1813 `(#:tests? #f ; Obscure test failures.
1814 #:phases
1815 (modify-phases %standard-phases
1816 (delete 'configure)
1817 (add-before 'build 'setup-environment
1818 (lambda* (#:key outputs #:allow-other-keys)
1819 (setenv "CC" "gcc")
1820 (setenv "prefix" (assoc-ref outputs "out"))
1821 #t)))
1822 #:make-flags (list "--environment-overrides")))
1823 (home-page "https://www.gentoo.com/di/")
1824 (synopsis "Advanced df like disk information utility")
1825 (description
1826 "'di' is a disk information utility, displaying everything that your
1827 @code{df} command does and more. It features the ability to display your disk
1828 usage in whatever format you prefer. It is designed to be highly portable and
1829 produce uniform output across heterogeneous networks.")
1830 (license license:zlib)))
1831
1832 (define-public cbatticon
1833 (package
1834 (name "cbatticon")
1835 (version "1.6.7")
1836 (source (origin
1837 (method url-fetch)
1838 (uri (string-append "https://github.com/valr/"
1839 name "/archive/" version ".tar.gz"))
1840 (sha256
1841 (base32
1842 "1s2n49ydh7pznnf02fak4yy0wqkgi9ag7yiw1zg1lhp4m0h37hyh"))
1843 (file-name (string-append name "-" version ".tar.gz"))))
1844 (build-system gnu-build-system)
1845 (arguments
1846 `(#:tests? #f ; no tests
1847 #:make-flags
1848 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
1849 "CC=gcc")
1850 #:phases
1851 (modify-phases %standard-phases
1852 (delete 'configure)))) ; no configure script
1853 (inputs
1854 `(("gtk+" ,gtk+)
1855 ("gettext" ,gettext-minimal)
1856 ("libnotify" ,libnotify)))
1857 (native-inputs
1858 `(("pkg-config" ,pkg-config)))
1859 (synopsis "Lightweight battery icon for the system tray")
1860 (description "cbatticon is a lightweight battery icon that displays
1861 the status of your battery in the system tray.")
1862 (home-page "https://github.com/valr/cbatticon")
1863 (license license:gpl2+)))
1864
1865 (define-public interrobang
1866 (let ((revision "1")
1867 (commit "896543735e1c99144765fdbd7b6e6b5afbd8b881"))
1868 (package
1869 (name "interrobang")
1870 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
1871 (source (origin
1872 (method git-fetch)
1873 (uri (git-reference
1874 (url "https://github.com/TrilbyWhite/interrobang")
1875 (commit commit)))
1876 (file-name (string-append name "-" version))
1877 (sha256
1878 (base32
1879 "1n13m70p1hfba5dy3i8hfclbr6k9q3d9dai3dg4jvhdhmxcpjzdf"))))
1880 (build-system gnu-build-system)
1881 (arguments
1882 `(#:tests? #f ; no tests
1883 #:phases
1884 (modify-phases %standard-phases
1885 (delete 'configure)) ; no configure script
1886 #:make-flags (list (string-append "PREFIX="
1887 (assoc-ref %outputs "out")))))
1888 (inputs
1889 `(("libx11" ,libx11)))
1890 (native-inputs
1891 `(("pkg-config" ,pkg-config)))
1892 (synopsis "Scriptable launcher menu")
1893 (description "Interrobang is a scriptable launcher menu with a customizable
1894 shortcut syntax and completion options.")
1895 (home-page "https://github.com/TrilbyWhite/interrobang")
1896 (license license:gpl3+))))
1897
1898
1899
1900 (define-public pam-krb5
1901 (package
1902 (name "pam-krb5")
1903 (version "4.7")
1904 (source (origin
1905 (method url-fetch)
1906 (uri (string-append
1907 "https://archives.eyrie.org/software/kerberos/" name "-"
1908 version ".tar.xz"))
1909 (sha256
1910 (base32
1911 "0abf8cfpkprmhw5ca8iyqgrggh65lgqvmfllc1y6qz7zw1gas894"))))
1912 (build-system gnu-build-system)
1913 (arguments
1914 `(#:phases
1915 (modify-phases %standard-phases
1916 (add-before 'configure 'disable-tests
1917 (lambda _
1918 ;; The build container seems to interfere with some tests.
1919 (substitute* "tests/TESTS"
1920 (("module/basic\n") ""))
1921 (substitute* "tests/TESTS"
1922 (("pam-util/vector\n") ""))
1923 #t)))))
1924 (inputs
1925 `(("linux-pam" ,linux-pam)
1926 ("mit-krb5" ,mit-krb5)))
1927 (native-inputs
1928 `(("perl" ,perl)
1929 ("perl-test-pod" ,perl-test-pod))) ; required for tests
1930 (synopsis "Kerberos PAM module")
1931 (description
1932 "Pam-krb5 is a Kerberos PAM module for either MIT Kerberos or Heimdal.
1933 It supports ticket refreshing by screen savers, configurable
1934 authorization handling, authentication of non-local accounts for network
1935 services, password changing, and password expiration, as well as all the
1936 standard expected PAM features. It works correctly with OpenSSH, even
1937 with ChallengeResponseAuthentication and PrivilegeSeparation enabled,
1938 and supports extensive configuration either by PAM options or in
1939 krb5.conf or both. PKINIT is supported with recent versions of both MIT
1940 Kerberos and Heimdal and FAST is supported with recent MIT Kerberos.")
1941 (home-page "http://www.eyrie.org/~eagle/software/pam-krb5")
1942 ;; Dual licenced under a homebrew non-copyleft OR GPL (any version)
1943 ;; However, the tarball does not contain a copy of the GPL, so unless
1944 ;; we put one in, we cannot distribute it under GPL without violating
1945 ;; clause requiring us to give all recipients a copy.
1946 (license license:gpl1+)))
1947
1948 ;;http://archives.eyrie.org/software/kerberos/pam-krb5-4.7.tar.xz
1949
1950 (define-public sunxi-tools
1951 (package
1952 (name "sunxi-tools")
1953 (version "1.4.2")
1954 (source
1955 (origin
1956 (method url-fetch)
1957 (uri (string-append "https://github.com/linux-sunxi/"
1958 "sunxi-tools/archive/v" version ".tar.gz"))
1959 (sha256
1960 (base32 "08iqwj95qw2s7ilhrdi2lkbc8dx64zk5lzz1qk587jr0lla81x41"))
1961 (modules '((guix build utils)))
1962 (snippet
1963 ;; Remove binaries contained in the tarball which are only for the
1964 ;; target and can be regenerated anyway.
1965 '(delete-file-recursively "bin"))
1966 (file-name (string-append name "-" version ".tar.gz"))))
1967 (native-inputs
1968 `(("pkg-config" ,pkg-config)
1969 ("cross-gcc" ,(cross-gcc "arm-linux-gnueabihf"
1970 #:xbinutils (cross-binutils "arm-linux-gnueabihf")
1971 #:libc (cross-libc "arm-linux-gnueabihf")))
1972 ("cross-libc" ,(cross-libc "arm-linux-gnueabihf"))))
1973 (inputs
1974 `(("libusb" ,libusb)))
1975 (build-system gnu-build-system)
1976 (arguments
1977 `(#:tests? #f ; no tests exist
1978 #:make-flags (list (string-append "PREFIX="
1979 (assoc-ref %outputs "out"))
1980 (string-append "CROSS_COMPILE="
1981 "arm-linux-gnueabihf-")
1982 "CC=gcc")
1983 #:phases
1984 (modify-phases %standard-phases
1985 (delete 'configure)
1986 (add-before 'build 'set-environment-up
1987 (lambda* (#:key make-flags #:allow-other-keys)
1988 (define (cross? x)
1989 (string-contains x "cross-arm-linux"))
1990 (setenv "CROSS_C_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))
1991 (setenv "CROSS_CPLUS_INCLUDE_PATH" (getenv "CPLUS_INCLUDE_PATH"))
1992 (setenv "CROSS_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
1993 (for-each
1994 (lambda (env-name)
1995 (let* ((env-value (getenv env-name))
1996 (search-path (search-path-as-string->list env-value))
1997 (new-search-path (filter (lambda (e) (not (cross? e)))
1998 search-path))
1999 (new-env-value (list->search-path-as-string
2000 new-search-path ":")))
2001 (setenv env-name new-env-value)))
2002 '("C_INCLUDE_PATH" "CPLUS_INCLUDE_PATH" "LIBRARY_PATH"))
2003 #t))
2004 (replace 'build
2005 (lambda* (#:key make-flags #:allow-other-keys)
2006 (zero? (apply system* "make" "tools" "misc" make-flags))))
2007 (add-after 'build 'build-armhf
2008 (lambda* (#:key make-flags #:allow-other-keys)
2009 (zero? (apply system* "make" "target-tools" make-flags))))
2010 (replace 'install
2011 (lambda* (#:key make-flags #:allow-other-keys)
2012 (zero? (apply system* "make" "install-all" "install-misc"
2013 make-flags)))))))
2014 (home-page "https://github.com/linux-sunxi/sunxi-tools")
2015 (synopsis "Hardware management tools for Allwinner computers")
2016 (description "This package contains tools for Allwinner devices:
2017 @enumerate
2018 @item @command{sunxi-fexc}, @command{bin2fex}, @command{fex2bin}: Compile
2019 a textual description of a board (.fex) to a binary representation (.bin).
2020 @item @command{sunxi-fel}: Puts an Allwinner device into FEL mode which
2021 makes it register as a special USB device (rather than USB host).
2022 You can then connect it to another computer and flash it from there.
2023 @item @command{sunxi-nand-part}: Partitions NAND flash.
2024 @item @command{sunxi-bootinfo}: Reads out boot0 and boot1 (Allwinner
2025 bootloader) parameters.
2026 @item @command{sunxi-pio}: Sets GPIO parameters and oscillates a GPIO
2027 in order to be able to find it.
2028 @item @command{sunxi-meminfo}: Prints memory bus settings.
2029 @item @command{sunxi-nand-image-builder}: Prepares raw NAND images.
2030 @end enumerate")
2031 (license license:gpl2+)))
2032
2033 (define-public sedsed
2034 (package
2035 (name "sedsed")
2036 (version "1.0")
2037 (source
2038 (origin
2039 (method url-fetch)
2040 (uri (string-append "https://github.com/aureliojargas/sedsed/"
2041 "archive/v" version ".tar.gz"))
2042 (file-name (string-append name "-" version ".tar.gz"))
2043 (sha256
2044 (base32
2045 "0139jkqvm8ipiwfj7k69ry2f9b1ffgpk79arpz4r7w9kf6h23bnh"))))
2046 (build-system python-build-system)
2047 (arguments
2048 `(#:tests? #f ; No tests.
2049 #:python ,python-2
2050 #:phases
2051 (modify-phases %standard-phases
2052 (add-after 'unpack 'patch-sed-in
2053 (lambda _
2054 (substitute* "sedsed.py"
2055 (("sedbin = 'sed'")
2056 (string-append "sedbin = '" (which "sed") "'")))
2057 #t))
2058 (delete 'build)
2059 (replace 'install
2060 (lambda* (#:key outputs #:allow-other-keys)
2061 (let* ((out (assoc-ref outputs "out"))
2062 (bin (string-append out "/bin")))
2063 ;; Just one file to copy around
2064 (install-file "sedsed.py" bin)
2065 #t)))
2066 (add-after 'install 'symlink
2067 ;; Create 'sedsed' symlink to "sedsed.py".
2068 (lambda* (#:key outputs #:allow-other-keys)
2069 (let* ((out (assoc-ref outputs "out"))
2070 (bin (string-append out "/bin"))
2071 (sed (string-append bin "/sedsed"))
2072 (sedpy (string-append bin "/sedsed.py")))
2073 (symlink sedpy sed)
2074 #t))))))
2075 (home-page "http://aurelio.net/projects/sedsed")
2076 (synopsis "Sed sed scripts")
2077 (description
2078 "@code{sedsed} can debug, indent, tokenize and HTMLize your sed(1) script.
2079
2080 In debug mode it reads your script and add extra commands to it. When
2081 executed you can see the data flow between the commands, revealing all the
2082 magic sed does on its internal buffers.
2083
2084 In indent mode your script is reformatted with standard spacing.
2085
2086 In tokenize mode you can see the elements of every command you use.
2087
2088 In HTMLize mode your script is converted to a beautiful colored HTML file,
2089 with all the commands and parameters identified for your viewing pleasure.
2090
2091 With sedsed you can master any sed script. No more secrets, no more hidden
2092 buffers.")
2093 (license license:expat)))
2094
2095 (define-public intel-gpu-tools
2096 (package
2097 (name "intel-gpu-tools")
2098 (version "1.18")
2099 (source (origin
2100 (method url-fetch)
2101 (uri (string-append "https://cgit.freedesktop.org/xorg/app/"
2102 "intel-gpu-tools/snapshot/"
2103 "intel-gpu-tools-" version ".tar.gz"))
2104 (sha256
2105 (base32
2106 "0w7djk0y5w76hzn1b3cm39zd5c6w9za1wfn80wd857h0v313rzq3"))))
2107 (build-system gnu-build-system)
2108 (arguments
2109 `(#:tests? #f ; many of the tests try to load kernel modules
2110 #:phases
2111 (modify-phases %standard-phases
2112 (add-after 'unpack 'autogen
2113 (lambda _
2114 ;; Don't run configure in this phase
2115 (setenv "NOCONFIGURE" "1")
2116 (zero? (system* "sh" "autogen.sh")))))))
2117 (inputs
2118 `(("util-macros" ,util-macros)
2119 ("libdrm" ,libdrm)
2120 ("libpciaccess" ,libpciaccess)
2121 ("kmod" ,kmod)
2122 ("procps" ,procps)
2123 ("cairo" ,cairo)
2124 ("libunwind" ,libunwind)
2125 ("libxrandr" ,libxrandr)
2126 ("glib" ,glib)))
2127 (native-inputs
2128 `(("autoconf" ,autoconf)
2129 ("automake" ,automake)
2130 ("libtool" ,libtool)
2131 ("pkg-config" ,pkg-config)))
2132 (home-page "https://cgit.freedesktop.org/xorg/app/intel-gpu-tools/")
2133 (synopsis "Tools for development and testing of the Intel DRM driver")
2134 (description "Intel GPU Tools is a collection of tools for development and
2135 testing of the Intel DRM driver. There are many macro-level test suites that
2136 get used against the driver, including xtest, rendercheck, piglit, and
2137 oglconform, but failures from those can be difficult to track down to kernel
2138 changes, and many require complicated build procedures or specific testing
2139 environments to get useful results. Therefore, Intel GPU Tools includes
2140 low-level tools and tests specifically for development and testing of the
2141 Intel DRM Driver.")
2142 (license license:expat)))
2143
2144 (define-public fabric
2145 (package
2146 (name "fabric")
2147 (version "1.13.2")
2148 (source
2149 (origin
2150 (method url-fetch)
2151 (uri (pypi-uri "Fabric" version))
2152 (sha256
2153 (base32
2154 "0k944dxr41whw7ib6380q9x15wyskx7fqni656icdn8rzshn9bwq"))))
2155 (build-system python-build-system)
2156 (arguments
2157 `(#:python ,python-2)) ; Python 2 only
2158 (native-inputs
2159 `(("python2-fudge" ,python2-fudge)
2160 ("python2-jinja2" ,python2-jinja2)
2161 ("python2-nose" ,python2-nose)))
2162 (propagated-inputs
2163 `(("python2-paramiko" ,python2-paramiko)))
2164 (home-page "http://fabfile.org")
2165 (synopsis "Simple Pythonic remote execution and deployment tool")
2166 (description
2167 "Fabric is designed to upload files and run shell commands on a number of
2168 servers in parallel or serially. These commands are grouped in tasks (which
2169 are regular Python functions) and specified in a @dfn{fabfile}.
2170
2171 It is similar to Capistrano, except it's implemented in Python and doesn't
2172 expect you to be deploying Rails applications. Fabric is a simple, Pythonic
2173 tool for remote execution and deployment.")
2174 (license license:bsd-2)))
2175
2176 (define-public neofetch
2177 (package
2178 (name "neofetch")
2179 (version "3.3.0")
2180 (source (origin
2181 (method url-fetch)
2182 (uri (string-append "https://github.com/dylanaraps/neofetch/"
2183 "archive/" version ".tar.gz"))
2184 (file-name (string-append name "-" version ".tar.gz"))
2185 (sha256
2186 (base32
2187 "15p69q0jchfms1fpb4i7kq8b28w2xpgh2zmynln618qxv1myf228"))))
2188 (build-system gnu-build-system)
2189 (arguments
2190 `(#:tests? #f ; there are no tests
2191 #:make-flags
2192 (list (string-append "PREFIX=" %output))
2193 #:phases
2194 (modify-phases %standard-phases
2195 (add-after 'unpack 'patch-target-directories
2196 (lambda* (#:key outputs #:allow-other-keys)
2197 (let ((out (assoc-ref outputs "out")))
2198 (substitute* "Makefile"
2199 (("\\$\\(DESTDIR\\)/etc/")
2200 "$(PREFIX)/etc/"))
2201 (substitute* "neofetch"
2202 (("\"/etc/neofetch")
2203 (string-append "\"" out "/etc/neofetch"))
2204 (("\"/usr/share/neofetch")
2205 (string-append "\"" out "/share/neofetch"))))
2206 #t))
2207 (delete 'configure) ; no configure script
2208 (replace 'install
2209 (lambda* (#:key make-flags outputs #:allow-other-keys)
2210 (let* ((out (assoc-ref outputs "out"))
2211 (doc (string-append out "/share/doc/" ,name "-" ,version))
2212 (etc (string-append doc "/examples/etc")))
2213 (zero? (apply system* `("make" ,@make-flags
2214 ,(string-append "SYSCONFDIR=" etc)
2215 "install")))))))))
2216 (home-page "https://github.com/dylanaraps/neofetch")
2217 (synopsis "System info script")
2218 (description "Neofetch is a CLI system information tool written in Bash.
2219 Neofetch displays information about your system next to an image, your OS
2220 logo, or any ASCII file of your choice. The main purpose of Neofetch is to be
2221 used in screenshots to show other users what operating system or distribution
2222 you are running, what theme or icon set you are using, etc.")
2223 (license license:expat)))
2224
2225 (define-public nnn
2226 (package
2227 (name "nnn")
2228 (version "1.5")
2229 (source (origin
2230 (method url-fetch)
2231 (uri (string-append "https://github.com/jarun/nnn/"
2232 "archive/v" version ".tar.gz"))
2233 (file-name (string-append name "-" version ".tar.gz"))
2234 (sha256
2235 (base32
2236 "0zswf8lb29zr1z642i1d0zi1y2mxal8qjqdrpdiqjh197jamj3zm"))))
2237 (build-system gnu-build-system)
2238 (inputs `(("ncurses" ,ncurses)
2239 ("readline" ,readline)))
2240 (arguments
2241 '(#:tests? #f ; no tests
2242 #:phases
2243 ;; We do not provide `ncurses.h' within an `ncursesw'
2244 ;; sub-directory, so patch the source accordingly. See
2245 ;; <http://bugs.gnu.org/19018>.
2246 ;; Thanks to gtypist maintainer.
2247 (modify-phases %standard-phases
2248 (add-after 'unpack 'patch-curses-lib
2249 (lambda* (#:key outputs #:allow-other-keys)
2250 (let ((out (assoc-ref outputs "out")))
2251 (substitute* "Makefile"
2252 (("-lncursesw")
2253 "-lncurses"))
2254 (substitute* "nnn.c"
2255 (("ncursesw\\/curses.h")
2256 "ncurses.h")))
2257 #t))
2258 (delete 'configure))
2259 #:make-flags
2260 (list
2261 (string-append "PREFIX="
2262 (assoc-ref %outputs "out"))
2263 (string-append "-Wl,-rpath="
2264 %output "/lib")
2265 "CC=gcc")))
2266 (home-page "https://github.com/jarun/nnn")
2267 (synopsis "Terminal file browser")
2268 (description "@command{nnn} is a fork of @command{noice}, a blazing-fast
2269 lightweight terminal file browser with easy keyboard shortcuts for
2270 navigation, opening files and running tasks. There is no config file and
2271 mime associations are hard-coded. The incredible user-friendliness and speed
2272 make it a perfect utility on modern distros.")
2273 (license license:bsd-2)))
2274
2275 (define-public thermald
2276 (package
2277 (name "thermald")
2278 (version "1.6")
2279 (source
2280 (origin
2281 (method url-fetch)
2282 (uri (string-append "https://github.com/01org/thermal_daemon/archive/v"
2283 version ".tar.gz"))
2284 (file-name (string-append name "-" version ".tar.gz"))
2285 (sha256 (base32
2286 "14klz9fnvi9jdlaqwrp61xa5nh051n8ykrs1fh1wxd7j66qf2fn6"))))
2287 (build-system gnu-build-system)
2288 (arguments
2289 `(#:phases (modify-phases %standard-phases
2290 (add-after
2291 'unpack 'autogen.sh-and-fix-paths
2292 (lambda* (#:key outputs #:allow-other-keys)
2293 (let ((out (assoc-ref outputs "out")))
2294 ;; upstartconfir is hardcoded to /etc/init and the build
2295 ;; system tries to mkdir that. We don't even need upstart
2296 ;; files at all; this is a fast and kludgy workaround
2297 (substitute* "data/Makefile.am"
2298 (("upstartconfdir = /etc/init")
2299 (string-append "upstartconfdir = "
2300 out "/etc/init")))
2301 ;; Now run autogen
2302 (zero? (system* "sh" "autogen.sh"))))))
2303 #:configure-flags
2304 (let ((out (assoc-ref %outputs "out")))
2305 (list (string-append "--sysconfdir="
2306 out "/etc")
2307 (string-append "--with-udev-dir="
2308 out "/lib/udev")
2309 (string-append "--with-dbus-sys-dir="
2310 out "/etc/dbus-1/system.d")
2311 "--localstatedir=/var"))))
2312 (native-inputs
2313 `(("autoconf" ,autoconf)
2314 ("automake" ,automake)
2315 ("glib" ,glib "bin") ; for glib-genmarshal, etc.
2316 ("pkg-config" ,pkg-config)))
2317 (inputs
2318 `(("dbus-glib" ,dbus-glib)
2319 ("libxml2" ,libxml2)))
2320 (home-page "https://01.org/linux-thermal-daemon/")
2321 (synopsis "CPU scaling for thermal management")
2322 (description "The Linux Thermal Daemon helps monitor and control temperature
2323 on systems running the Linux kernel.")
2324 ;; arm and aarch64 don't have cpuid.h
2325 (supported-systems '("i686-linux" "x86_64-linux"))
2326 (license license:gpl2+)))
2327
2328 (define-public masscan
2329 (package
2330 (name "masscan")
2331 (version "1.0.4")
2332 (source (origin
2333 (method url-fetch)
2334 (uri (string-append "https://github.com/robertdavidgraham/masscan"
2335 "/archive/" version ".tar.gz"))
2336 (sha256
2337 (base32
2338 "1y9af345g00z83rliv6bmlqg37xwc7xpnx5xqdgmjikzcxgk9pji"))))
2339 (build-system gnu-build-system)
2340 (inputs
2341 `(("libpcap" ,libpcap)))
2342 (arguments
2343 '(#:test-target "regress"
2344 #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
2345 #:phases
2346 (modify-phases %standard-phases
2347 (delete 'configure) ; There is no ./configure script
2348 (add-after 'unpack 'patch-path
2349 (lambda* (#:key outputs inputs #:allow-other-keys)
2350 (let* ((out (assoc-ref outputs "out"))
2351 (pcap (assoc-ref inputs "libpcap")))
2352 (substitute* "src/rawsock-pcap.c"
2353 (("libpcap.so") (string-append pcap "/lib/libpcap.so")))
2354 #t))))))
2355 (synopsis "TCP port scanner")
2356 (description "MASSCAN is an asynchronous TCP port scanner. It can detect
2357 open ports, and also complete the TCP connection and interact with the remote
2358 application, collecting the information received.")
2359 (home-page "https://github.com/robertdavidgraham/masscan")
2360 ;; 'src/siphash24.c' is the SipHash reference implementation, which
2361 ;; bears a CC0 Public Domain Dedication.
2362 (license license:agpl3+)))
2363
2364 (define-public hungrycat
2365 (package
2366 (name "hungrycat")
2367 (version "0.4.1")
2368 (source (origin
2369 (method url-fetch)
2370 (uri (string-append "https://github.com/jwilk/hungrycat/"
2371 "releases/download/" version "/"
2372 name "-" version ".tar.gz"))
2373 (sha256
2374 (base32
2375 "03fc1zsrf99lvxa7b4ps6pbi43304wbxh1f6ci4q0vkal370yfwh"))))
2376 (build-system gnu-build-system)
2377 (native-inputs
2378 ;; For tests.
2379 `(("python" ,python-wrapper)
2380 ("python-nose" ,python-nose)))
2381 (arguments
2382 `(#:test-target "test"))
2383 (synopsis "A single tool that combines @command{cat} & @command{rm}")
2384 (description
2385 "hungrycat prints the contents of a file to standard output, while
2386 simultaneously freeing the disk space it occupied. It is useful if you need
2387 to process a large file, don't have enough space to store both the input and
2388 output files, and don't need the input file afterwards.
2389 While similar in principle to running @command{cat} immediately followed by
2390 @command{rm}, @command{hungrycat} actually frees blocks as soon as they are
2391 printed instead of after the entire file has been read, which is often too
2392 late.")
2393 (home-page "https://jwilk.net/software/hungrycat")
2394 (license license:expat)))