gnu: ddrescue: Update to 1.22.
[jackhill/guix/guix.git] / gnu / packages / admin.scm
CommitLineData
233e7676 1;;; GNU Guix --- Functional package management for GNU
89e34644 2;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
340c7033 3;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
75418ae0 4;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
2328b47c 5;;; Copyright © 2014, 2015, 2016 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>
765973cd 9;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
f1957fc1 10;;; Copyright © 2016 Pjotr Prins <pjotr.guix@thebird.nl>
3d7a157c 11;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
4fb14fad 12;;; Copyright © 2016, 2017 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>
5ec8b02d 15;;; Coypright © 2016 ng0 <ng0@we.make.ritual.n0.is>
47d7b303 16;;; Coypright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
94c5dc8c 17;;; Coypright © 2016 John Darrington <jmd@gnu.org>
1df895b0 18;;;
233e7676 19;;; This file is part of GNU Guix.
1df895b0 20;;;
233e7676 21;;; GNU Guix is free software; you can redistribute it and/or modify it
1df895b0
LC
22;;; under the terms of the GNU General Public License as published by
23;;; the Free Software Foundation; either version 3 of the License, or (at
24;;; your option) any later version.
25;;;
233e7676 26;;; GNU Guix is distributed in the hope that it will be useful, but
1df895b0
LC
27;;; WITHOUT ANY WARRANTY; without even the implied warranty of
28;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29;;; GNU General Public License for more details.
30;;;
31;;; You should have received a copy of the GNU General Public License
233e7676 32;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
1df895b0 33
4aeea896 34(define-module (gnu packages admin)
f61e0e79 35 #:use-module ((guix licenses) #:prefix license:)
1df895b0 36 #:use-module (guix packages)
4fb7e0de 37 #:use-module (guix utils)
1df895b0 38 #:use-module (guix download)
aaff68ee 39 #:use-module (guix git-download)
fbc1a58f 40 #:use-module (guix build-system cmake)
1df895b0 41 #:use-module (guix build-system gnu)
4ecfbda7 42 #:use-module (guix build-system python)
c773aba8 43 #:use-module (guix build-system trivial)
59a43334 44 #:use-module (gnu packages)
c73d4c92 45 #:use-module (gnu packages base)
3d7a157c 46 #:use-module (gnu packages cyrus-sasl)
9a9e72d5 47 #:use-module (gnu packages ncurses)
9927622f 48 #:use-module (gnu packages readline)
f15164e7 49 #:use-module (gnu packages linux)
d0457553 50 #:use-module (gnu packages lua)
f15164e7 51 #:use-module (gnu packages guile)
1dba6407 52 #:use-module (gnu packages gettext)
d0457553 53 #:use-module (gnu packages pcre)
c73d4c92 54 #:use-module (gnu packages perl)
87216303 55 #:use-module (gnu packages tcl)
f61e0e79 56 #:use-module (gnu packages compression)
a7fd7b68 57 #:use-module (gnu packages tls)
61bdd0d8 58 #:use-module (gnu packages gnupg)
02c86a5e
LC
59 #:use-module (gnu packages bison)
60 #:use-module (gnu packages flex)
61 #:use-module (gnu packages glib)
3d7a157c 62 #:use-module (gnu packages openldap)
c1f73569 63 #:use-module (gnu packages mcrypt)
87216303 64 #:use-module (gnu packages pkg-config)
b36fcf95 65 #:use-module (gnu packages popt)
1a0346f0 66 #:use-module (gnu packages python)
fccf2fe0 67 #:use-module (gnu packages texinfo)
e1485c7b 68 #:use-module (gnu packages groff)
42dc3af5
MW
69 #:use-module (gnu packages pciutils)
70 #:use-module (gnu packages libusb)
71 #:use-module (gnu packages libftdi)
c4492a16 72 #:use-module (gnu packages image)
da6c3749 73 #:use-module (gnu packages xorg)
d525da85 74 #:use-module (gnu packages python)
e932d371 75 #:use-module (gnu packages man)
5ec8b02d 76 #:use-module (gnu packages autotools)
77 #:use-module (gnu packages gnome)
89e34644 78 #:use-module (gnu packages kerberos)
5ec8b02d 79 #:use-module (gnu packages gtk))
f15164e7 80
c1f73569
RW
81(define-public aide
82 (package
83 (name "aide")
84 (version "0.15.1")
85 (source (origin
86 (method url-fetch)
87 (uri (string-append "mirror://sourceforge/aide/aide/"
88 version "/aide-" version ".tar.gz"))
89 (sha256
90 (base32
91 "1vsrc0s62kv1i84skm6k6zy868gayjck268qwj38rpspc8c5qgih"))))
92 (build-system gnu-build-system)
93 (native-inputs
94 `(("bison" ,bison)
95 ("flex" ,flex)))
96 (inputs
97 `(("libgcrypt" ,libgcrypt)
98 ("libgpg-error" ,libgpg-error)
99 ("libmhash" ,libmhash)
100 ("zlib" ,zlib)))
101 (synopsis "File and directory integrity checker")
102 (description
103 "AIDE (Advanced Intrusion Detection Environment) is a file and directory
104integrity checker. It creates a database from the regular expression rules
105that it finds from its configuration files. Once this database is initialized
106it can be used to verify the integrity of the files. It has several message
107digest algorithms that are used to check the integrity of files. All of the
108usual file attributes can be checked for inconsistencies.")
109 (home-page "http://aide.sourceforge.net/")
110 (license license:gpl2+)))
111
4971d5d0
RJ
112(define-public progress
113 (package
114 (name "progress")
115 (version "0.13")
116 (source (origin
117 (method url-fetch)
118 (uri (string-append "https://github.com/Xfennec/"
119 name "/archive/v" version ".tar.gz"))
120 (sha256
121 (base32 "133iar4vq5vlklydb4cyazjy6slmpbndrws474mg738bd8avc30n"))
122 (file-name (string-append name "-" version ".tar.gz"))))
123 (build-system gnu-build-system)
124 (inputs
125 `(("ncurses" ,ncurses)))
126 (arguments
127 `(#:tests? #f ; There is no test suite.
128 #:make-flags (list "CC=gcc" "LDFLAGS+=-lncurses"
129 (string-append "PREFIX=" (assoc-ref %outputs "out")))
130 #:phases
131 (modify-phases %standard-phases
132 (delete 'configure)))) ; There's no configure phase.
133 (home-page "https://github.com/Xfennec/progress")
134 (synopsis "Program to view the progress of the coreutils commands")
135 (description "A program that looks for coreutils basic commands (cp, mv,
136dd, tar, gzip/gunzip, cat, etc.) currently running on your system and displays
137the percentage of copied data. It can also show estimated time and throughput,
138and provides a \"top-like\" mode (monitoring).")
139 (license license:gpl3+)))
140
e932d371 141(define-public shepherd
133056bd
LC
142 (package
143 (name "shepherd")
95088559 144 (version "0.3.2")
133056bd
LC
145 (source (origin
146 (method url-fetch)
147 (uri (string-append "ftp://alpha.gnu.org/gnu/dmd/shepherd-"
148 version ".tar.gz"))
149 (sha256
150 (base32
95088559 151 "174q1qg7yg6w1hfvlfv720hr6hid4h5xzw15y3ycfpspllzldhcb"))))
133056bd
LC
152 (build-system gnu-build-system)
153 (arguments
154 '(#:configure-flags '("--localstatedir=/var")))
155 (native-inputs `(("pkg-config" ,pkg-config)))
156 (inputs `(("guile" ,guile-2.0)))
157 (synopsis "System service manager")
158 (description
159 "The GNU Shepherd is a daemon-managing daemon, meaning that it supervises
160the execution of system services, replacing similar functionality found in
161typical init systems. It provides dependency-handling through a convenient
162interface and is based on GNU Guile.")
163 (license license:gpl3+)
95088559
LC
164 (home-page "https://www.gnu.org/software/shepherd/")
165 (properties '((ftp-server . "alpha.gnu.org")))))
e932d371 166
fbc1a58f
CR
167(define-public dfc
168 (package
169 (name "dfc")
180d7ac1 170 (version "3.0.4")
fbc1a58f
CR
171 (source
172 (origin
173 (method url-fetch)
174 (uri (string-append
180d7ac1 175 "http://projects.gw-computing.net/attachments/download/79/dfc-"
fbc1a58f
CR
176 version ".tar.gz"))
177 (sha256
178 (base32
180d7ac1 179 "0zk1ppx93ijimf4sbgqilxxikpsa2gmpbynknyh41xy7jbdjxp0b"))))
fbc1a58f
CR
180 (build-system cmake-build-system)
181 (arguments '(#:tests? #f)) ; There are no tests.
b94a6ca0 182 (native-inputs `(("gettext" ,gettext-minimal)))
fbc1a58f
CR
183 (home-page "http://projects.gw-computing.net/projects/dfc")
184 (synopsis "Display file system space usage using graphs and colors")
185 (description
186 "dfc (df color) is a modern version of df. It uses colors, draws pretty
187graphs and can export its output to different formats.")
f61e0e79 188 (license license:bsd-3)))
fbc1a58f 189
340c7033
CR
190(define-public htop
191 (package
192 (name "htop")
621954ba 193 (version "2.0.2")
340c7033
CR
194 (source (origin
195 (method url-fetch)
20e6c852 196 (uri (string-append "http://hisham.hm/htop/releases/"
340c7033
CR
197 version "/htop-" version ".tar.gz"))
198 (sha256
199 (base32
621954ba 200 "11zlwadm6dpkrlfvf3z3xll26yyffa7qrxd1w72y1kl0rgffk6qp"))))
340c7033
CR
201 (build-system gnu-build-system)
202 (inputs
203 `(("ncurses" ,ncurses)))
204 (home-page "http://htop.sourceforge.net/")
205 (synopsis "Interactive process viewer")
206 (description
207 "This is htop, an interactive process viewer. It is a text-mode
208application (for console or X terminals) and requires ncurses.")
f61e0e79 209 (license license:gpl2)))
340c7033 210
1df895b0
LC
211(define-public pies
212 (package
213 (name "pies")
a9764b7d 214 (version "1.3")
1df895b0
LC
215 (source
216 (origin
a9764b7d
LC
217 (method url-fetch)
218 (uri (string-append "mirror://gnu/pies/pies-"
219 version ".tar.bz2"))
220 (sha256
221 (base32
222 "12r7rjjyibjdj08dvwbp0iflfpzl4s0zhn6cr6zj3hwf9gbzgl1g"))))
1df895b0 223 (build-system gnu-build-system)
a9764b7d
LC
224 (arguments
225 '(#:phases (modify-phases %standard-phases
226 (add-before 'build 'patch-/bin/sh
227 (lambda* (#:key inputs #:allow-other-keys)
228 ;; Use the right shell when executing user-provided
229 ;; shell commands.
230 (let ((bash (assoc-ref inputs "bash")))
231 (substitute* "src/progman.c"
232 (("\"/bin/sh\"")
233 (string-append "\"" bash "/bin/sh\"")))
234 #t))))))
1df895b0 235 (home-page "http://www.gnu.org/software/pies/")
f50d2669 236 (synopsis "Program invocation and execution supervisor")
1df895b0 237 (description
79c311b8 238 "GNU pies is a program that supervises the invocation and execution of
a22dc0c4
LC
239other programs. It reads the list of programs to be started from its
240configuration file, executes them, and then monitors their status,
241re-executing them as necessary.")
f61e0e79 242 (license license:gpl3+)))
1df895b0
LC
243
244(define-public inetutils
245 (package
246 (name "inetutils")
8b1c8e4e 247 (version "1.9.4")
01eafd38
LC
248 (source (origin
249 (method url-fetch)
250 (uri (string-append "mirror://gnu/inetutils/inetutils-"
251 version ".tar.gz"))
252 (sha256
253 (base32
8b1c8e4e 254 "05n65k4ixl85dc6rxc51b1b732gnmm8xnqi424dy9f1nz7ppb3xy"))))
1df895b0 255 (build-system gnu-build-system)
e4a01b7d
LC
256 (arguments `(#:configure-flags '("--localstatedir=/var")
257
258 ;; FIXME: `tftp.sh' relies on `netstat' from utils-linux,
1df895b0
LC
259 ;; which is currently missing.
260 #:tests? #f))
9927622f
LC
261 (inputs `(("ncurses" ,ncurses)
262 ("readline" ,readline))) ; for 'ftp'
1df895b0 263 (home-page "http://www.gnu.org/software/inetutils/")
f50d2669 264 (synopsis "Basic networking utilities")
1df895b0 265 (description
a22dc0c4
LC
266 "Inetutils is a collection of common network programs, such as an ftp
267client and server, a telnet client and server, and an rsh client and server.")
f61e0e79 268 (license license:gpl3+)))
9a9e72d5
LC
269
270(define-public shadow
271 (package
272 (name "shadow")
ca2a55d4 273 (version "4.2.1")
9a9e72d5 274 (source (origin
ca2a55d4
SB
275 (method url-fetch)
276 (uri (string-append
277 "http://pkg-shadow.alioth.debian.org/releases/"
278 name "-" version ".tar.xz"))
279 (sha256
280 (base32
281 "0h9x1zdbq0pqmygmc1x459jraiqw4gqz8849v268crk78z8r621v"))))
9a9e72d5
LC
282 (build-system gnu-build-system)
283 (arguments
284 '(;; Assume System V `setpgrp (void)', which is the default on GNU
285 ;; variants (`AC_FUNC_SETPGRP' is not cross-compilation capable.)
286 #:configure-flags '("--with-libpam" "ac_cv_func_setpgrp_void=yes")
287
288 #:phases (alist-cons-before
289 'build 'set-nscd-file-name
290 (lambda* (#:key inputs #:allow-other-keys)
291 ;; Use the right file name for nscd.
292 (let ((libc (assoc-ref inputs "libc")))
293 (substitute* "lib/nscd.c"
294 (("/usr/sbin/nscd")
295 (string-append libc "/sbin/nscd")))))
296 (alist-cons-after
297 'install 'remove-groups
298 (lambda* (#:key outputs #:allow-other-keys)
299 ;; Remove `groups', which is already provided by Coreutils.
300 (let* ((out (assoc-ref outputs "out"))
301 (bin (string-append out "/bin"))
ca2a55d4 302 (man (string-append out "/share/man")))
9a9e72d5
LC
303 (delete-file (string-append bin "/groups"))
304 (for-each delete-file (find-files man "^groups\\."))
305 #t))
8d846470 306 %standard-phases))))
9a9e72d5
LC
307
308 (inputs (if (string-suffix? "-linux"
309 (or (%current-target-system)
310 (%current-system)))
311 `(("linux-pam" ,linux-pam))
312 '()))
313 (home-page "http://pkg-shadow.alioth.debian.org/")
314 (synopsis "Authentication-related tools such as passwd, su, and login")
315 (description
316 "Shadow provides a number of authentication-related tools, including:
317login, passwd, su, groupadd, and useradd.")
318
319 ;; The `vipw' program is GPLv2+.
320 ;; libmisc/salt.c is public domain.
f61e0e79 321 (license license:bsd-3)))
1e151896
LC
322
323(define-public mingetty
324 (package
325 (name "mingetty")
326 (version "1.08")
327 (source (origin
328 (method url-fetch)
de67e922
LF
329 (uri (string-append "mirror://sourceforge/mingetty/mingetty/"
330 version "/mingetty-" version ".tar.gz"))
1e151896
LC
331 (sha256
332 (base32
333 "05yxrp44ky2kg6qknk1ih0kvwkgbn9fbz77r3vci7agslh5wjm8g"))))
334 (build-system gnu-build-system)
335 (arguments
336 `(#:phases (alist-replace 'configure
337 (lambda* (#:key inputs outputs
338 #:allow-other-keys)
339 (let* ((out (assoc-ref outputs "out"))
340 (man8 (string-append
341 out "/share/man/man8"))
342 (sbin (string-append out "/sbin"))
343 (shadow (assoc-ref inputs "shadow"))
344 (login (string-append shadow
345 "/bin/login")))
346 (substitute* "Makefile"
347 (("^SBINDIR.*")
348 (string-append "SBINDIR = " out
349 "/sbin\n"))
350 (("^MANDIR.*")
351 (string-append "MANDIR = " out
352 "/share/man/man8\n")))
353
354 ;; Pick the right 'login' by default.
355 (substitute* "mingetty.c"
356 (("\"/bin/login\"")
357 (string-append "\"" login "\"")))
358
359 (mkdir-p sbin)
360 (mkdir-p man8)))
361 %standard-phases)
362 #:tests? #f)) ; no tests
363 (inputs `(("shadow" ,shadow)))
364
3b3b60d0 365 (home-page "https://sourceforge.net/projects/mingetty")
1e151896
LC
366 (synopsis "Getty for the text console")
367 (description
368 "Small console getty that is started on the Linux text console,
369asks for a login name and then transfers over to 'login'. It is extended to
370allow automatic login and starting any app.")
f61e0e79 371 (license license:gpl2+)))
c773aba8
LC
372
373(define-public net-base
374 (package
375 (name "net-base")
db719df7 376 (version "5.3")
c773aba8
LC
377 (source (origin
378 (method url-fetch)
379 (uri (string-append
34af3684 380 "mirror://debian/pool/main/n/netbase/netbase_"
db719df7 381 version ".tar.xz"))
c773aba8
LC
382 (sha256
383 (base32
db719df7 384 "12xqjwg3p4rzmmh2iib6sigm9l29y3dgk74mmnw64k84jnbwdxl1"))))
c773aba8
LC
385 (build-system trivial-build-system)
386 (arguments
387 `(#:modules ((guix build utils))
388 #:builder (begin
389 (use-modules (guix build utils)
390 (srfi srfi-26))
391
392 (let* ((source (assoc-ref %build-inputs "source"))
393 (tar (assoc-ref %build-inputs "tar"))
db719df7 394 (xz (assoc-ref %build-inputs "xz"))
c773aba8
LC
395 (output (assoc-ref %outputs "out"))
396 (etc (string-append output "/etc")))
db719df7 397 (setenv "PATH" (string-append xz "/bin"))
c773aba8
LC
398 (system* (string-append tar "/bin/tar") "xvf"
399 source)
400 (chdir ,(string-append "netbase-" version))
401 (mkdir-p etc)
402 (for-each copy-file
403 '("etc-services" "etc-protocols" "etc-rpc")
404 (map (cut string-append etc "/" <>)
405 '("services" "protocols" "rpc")))
406 #t))))
407 (native-inputs `(("tar" ,tar)
f61e0e79 408 ("xz" ,xz)))
c773aba8
LC
409 (synopsis "IANA protocol, port, and RPC number assignments")
410 (description
411 "This package provides the /etc/services, /etc/protocols, and /etc/rpc
412files, which contain information about the IANA-assigned port, protocol, and
e881752c 413ONC RPC numbers.")
c773aba8 414 (home-page "http://packages.debian.org/sid/netbase")
f61e0e79 415 (license license:gpl2)))
94c4a58a
LC
416
417(define-public netcat
418 (package
419 (name "netcat")
420 (version "0.7.1")
421 (source (origin
422 (method url-fetch)
de67e922
LF
423 (uri (string-append "mirror://sourceforge/netcat/netcat/" version
424 "/netcat-" version ".tar.bz2"))
94c4a58a
LC
425 (sha256
426 (base32
427 "1frjcdkhkpzk0f84hx6hmw5l0ynpmji8vcbaxg8h5k2svyxz0nmm"))))
428 (build-system gnu-build-system)
0e4e89c2
MW
429 (arguments
430 `(#:configure-flags
431 ;; By default, man and info pages are put in PREFIX/{man,info},
432 ;; but we want them in PREFIX/share/{man,info}.
433 (let ((out (assoc-ref %outputs "out")))
434 (list (string-append "--mandir=" out "/share/man")
435 (string-append "--infodir=" out "/share/info")))))
94c4a58a
LC
436 (home-page "http://netcat.sourceforge.net")
437 (synopsis "Read and write data over TCP/IP")
438 (description
439 "Netcat is a featured networking utility which reads and writes data
440across network connections, using the TCP/IP protocol. It is designed to be a
441reliable \"back-end\" tool that can be used directly or easily driven by other
35b9e423 442programs and scripts. At the same time, it is a feature-rich network debugging
94c4a58a
LC
443and exploration tool, since it can create almost any kind of connection you
444would need and has several interesting built-in capabilities.")
f61e0e79 445 (license license:gpl2+)))
d038cac1
LC
446
447(define-public alive
448 (package
449 (name "alive")
450 (version "2.0.2")
451 (source (origin
452 (method url-fetch)
453 (uri (string-append "mirror://gnu/alive/alive-"
454 version ".tar.xz"))
455 (sha256
456 (base32
457 "1vrzg51ai68x9yld7vbgl58sxaw5qpx8rbakwcxn4cqq6vpxj38j"))))
458 (build-system gnu-build-system)
459 (arguments '(#:configure-flags '("alive_cv_nice_ping=yes")))
460 (inputs `(("guile" ,guile-2.0)
461 ("inetutils" ,inetutils)))
462 (home-page "http://www.gnu.org/software/alive/")
463 (synopsis "Autologin and keep-alive daemon")
464 (description
465 "GNU Alive sends periodic pings to a server, generally to keep a
466connection alive.")
f61e0e79 467 (license license:gpl3+)))
c73d4c92
LC
468
469(define-public isc-dhcp
6548b1e1
MW
470 (let* ((bind-major-version "9")
471 (bind-minor-version "9")
ef3b9047 472 (bind-patch-version "9")
8be2428e 473 (bind-release-type "-P") ; for patch release, use "-P"
639168dd 474 (bind-release-version "5") ; for patch release, e.g. "4"
6548b1e1
MW
475 (bind-version (string-append bind-major-version
476 "."
477 bind-minor-version
478 "."
479 bind-patch-version
480 bind-release-type
481 bind-release-version)))
482 (package
483 (name "isc-dhcp")
86c61a6b 484 (version "4.3.5")
6548b1e1
MW
485 (source (origin
486 (method url-fetch)
487 (uri (string-append "http://ftp.isc.org/isc/dhcp/"
488 version "/dhcp-" version ".tar.gz"))
489 (sha256
490 (base32
86c61a6b 491 "0m7rwxvpb7xrmfl9ynpckhl0hi0xgm9bq1fmbp2r68sxy5mr75gb"))))
6548b1e1
MW
492 (build-system gnu-build-system)
493 (arguments
e54465ff
MW
494 `(#:parallel-build? #f
495 #:phases
6548b1e1
MW
496 (modify-phases %standard-phases
497 (add-after 'unpack 'replace-bundled-bind
498 (lambda* (#:key inputs #:allow-other-keys)
499 (delete-file "bind/bind.tar.gz")
500 (copy-file (assoc-ref inputs "bind-source-tarball")
501 "bind/bind.tar.gz")
502 (chmod "bind/bind.tar.gz" #o644)
503 (substitute* "bind/version.tmp"
504 (("^MAJORVER=.*")
505 (format #f "MAJORVER=~a\n" ,bind-major-version))
506 (("^MINORVER=.*")
507 (format #f "MINORVER=~a\n" ,bind-minor-version))
508 (("^PATCHVER=.*")
509 (format #f "PATCHVER=~a\n" ,bind-patch-version))
510 (("^RELEASETYPE=.*")
511 (format #f "RELEASETYPE=~a\n" ,bind-release-type))
512 (("^RELEASEVER=.*")
513 (format #f "RELEASEVER=~a\n" ,bind-release-version)))
514 #t))
515 (add-after 'configure 'post-configure
516 (lambda* (#:key outputs #:allow-other-keys)
517 ;; Point to the right client script, which will be
518 ;; installed in a later phase.
519 (substitute* "includes/dhcpd.h"
520 (("#define[[:blank:]]+_PATH_DHCLIENT_SCRIPT.*")
521 (let ((out (assoc-ref outputs "out")))
522 (string-append "#define _PATH_DHCLIENT_SCRIPT \""
523 out "/libexec/dhclient-script"
524 "\"\n"))))
c73d4c92 525
6548b1e1
MW
526 ;; During the 'build' phase, 'bind.tar.gz' is extracted, so
527 ;; we must patch shebangs in there and make sure the right
528 ;; shell is used.
529 (with-directory-excursion "bind"
530 (substitute* "Makefile"
531 (("\\./configure")
532 (let ((sh (which "sh")))
533 (string-append "./configure CONFIG_SHELL="
534 sh " SHELL=" sh))))
c73d4c92 535
6548b1e1
MW
536 (let ((bind-directory (string-append "bind-" ,bind-version)))
537 (system* "tar" "xf" "bind.tar.gz")
538 (for-each patch-shebang
539 (find-files bind-directory ".*"))
540 (zero? (system* "tar" "cf" "bind.tar.gz"
541 bind-directory
542 ;; avoid non-determinism in the archive
543 "--sort=name"
544 "--mtime=@0"
545 "--owner=root:0"
546 "--group=root:0"))))))
547 (add-after 'install 'post-install
548 (lambda* (#:key inputs outputs #:allow-other-keys)
549 ;; Install the dhclient script for GNU/Linux and make sure
550 ;; if finds all the programs it needs.
551 (let* ((out (assoc-ref outputs "out"))
552 (libexec (string-append out "/libexec"))
553 (coreutils (assoc-ref inputs "coreutils"))
554 (inetutils (assoc-ref inputs "inetutils"))
555 (net-tools (assoc-ref inputs "net-tools"))
556 (sed (assoc-ref inputs "sed")))
557 (substitute* "client/scripts/linux"
558 (("/sbin/ip")
559 (string-append (assoc-ref inputs "iproute")
560 "/sbin/ip")))
c73d4c92 561
6548b1e1
MW
562 (mkdir-p libexec)
563 (copy-file "client/scripts/linux"
564 (string-append libexec "/dhclient-script"))
c73d4c92 565
6548b1e1
MW
566 (wrap-program
567 (string-append libexec "/dhclient-script")
568 `("PATH" ":" prefix
569 ,(map (lambda (dir)
570 (string-append dir "/bin:"
571 dir "/sbin"))
572 (list inetutils net-tools coreutils sed))))))))))
c73d4c92 573
6548b1e1 574 (native-inputs `(("perl" ,perl)))
c73d4c92 575
6548b1e1
MW
576 (inputs `(("inetutils" ,inetutils)
577 ("net-tools" ,net-tools)
578 ("iproute" ,iproute)
dc343935 579
6548b1e1
MW
580 ;; XXX isc-dhcp bundles a copy of bind that has security
581 ;; flaws, so we use a newer version.
582 ("bind-source-tarball"
583 ,(origin
584 (method url-fetch)
585 (uri (string-append "http://ftp.isc.org/isc/bind9/"
586 bind-version
587 "/bind-" bind-version ".tar.gz"))
588 (sha256
589 (base32
639168dd 590 "1yn15chkfqf4d7961ip2x10jm27a9wqymz2xqh0a2g89arrirkaw"))))
c73d4c92 591
6548b1e1
MW
592 ;; When cross-compiling, we need the cross Coreutils and sed.
593 ;; Otherwise just use those from %FINAL-INPUTS.
594 ,@(if (%current-target-system)
595 `(("coreutils" ,coreutils)
596 ("sed" ,sed))
597 '())))
598
599 (home-page "http://www.isc.org/products/DHCP/")
600 (synopsis "Dynamic Host Configuration Protocol (DHCP) tools")
601 (description
602 "ISC's Dynamic Host Configuration Protocol (DHCP) distribution provides a
c73d4c92
LC
603reference implementation of all aspects of DHCP, through a suite of DHCP
604tools: server, client, and relay agent.")
159a5e01
LC
605 (license license:isc)
606 (properties '((cpe-name . "dhcp"))))))
02c86a5e
LC
607
608(define-public libpcap
609 (package
610 (name "libpcap")
df4a2b44 611 (version "1.8.1")
02c86a5e
LC
612 (source (origin
613 (method url-fetch)
614 (uri (string-append "http://www.tcpdump.org/release/libpcap-"
615 version ".tar.gz"))
616 (sha256
617 (base32
df4a2b44 618 "07jlhc66z76dipj4j5v3dig8x6h3k6cb36kmnmpsixf3zmlvqgb7"))))
02c86a5e
LC
619 (build-system gnu-build-system)
620 (native-inputs `(("bison" ,bison) ("flex" ,flex)))
e03f6d5e
RW
621 (arguments '(#:configure-flags '("--with-pcap=linux")
622 #:tests? #f)) ; no 'check' target
02c86a5e
LC
623 (home-page "http://www.tcpdump.org")
624 (synopsis "Network packet capture library")
625 (description
626 "libpcap is an interface for user-level packet capture. It provides a
627portable framework for low-level network monitoring. Applications include
628network statistics collection, security monitoring, network debugging, etc.")
629
630 ;; fad-*.c and a couple other files are BSD-4, but the rest is BSD-3.
f61e0e79 631 (license license:bsd-3)))
02c86a5e 632
1da34f5a
LC
633(define-public tcpdump
634 (package
635 (name "tcpdump")
af7d72b1 636 (version "4.9.0")
1da34f5a
LC
637 (source (origin
638 (method url-fetch)
af7d72b1
LF
639 ;; We use this Debian URL while the upstream URL is still
640 ;; officially private. This is the result of a botched
641 ;; coordinated release of tcpdump 4.9.0. I verified with
642 ;; the tcpdump maintainers that the upstream URL provides
643 ;; the same data as this Debian URL.
644 (uri
645 (list
646 (string-append "http://http.debian.net/debian/pool/main/t/"
647 name "/" name "_" version ".orig.tar.gz")
648 (string-append "http://www.tcpdump.org/release/tcpdump-"
649 version ".tar.gz")))
650 (file-name (string-append name "-" version ".tar.gz"))
1da34f5a
LC
651 (sha256
652 (base32
af7d72b1 653 "0pjsxsy8l71i813sa934cwf1ryp9xbr7nxwsvnzavjdirchq3sga"))))
1da34f5a 654 (build-system gnu-build-system)
10db1e6c 655 (inputs `(("libpcap" ,libpcap)
cc2b77df 656 ("openssl" ,openssl)))
1da34f5a 657 (native-inputs `(("perl" ,perl))) ; for tests
1da34f5a
LC
658 (home-page "http://www.tcpdump.org/")
659 (synopsis "Network packet analyzer")
660 (description
661 "Tcpdump is a command-line tool to analyze network traffic passing
662through the network interface controller.")
f61e0e79 663 (license license:bsd-3)))
1da34f5a 664
02c86a5e
LC
665(define-public jnettop
666 (package
667 (name "jnettop")
668 (version "0.13.0")
669 (source (origin
670 (method url-fetch)
671 (uri (string-append "http://jnettop.kubs.info/dist/jnettop-"
672 version ".tar.gz"))
673 (sha256
674 (base32
675 "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9"))))
676 (build-system gnu-build-system)
677 (native-inputs
678 `(("pkg-config" ,pkg-config)))
679 (inputs
680 `(("glib" ,glib)
681 ("ncurses" ,ncurses)
682 ("libpcap" ,libpcap)))
683 (home-page "http://jnettop.kubs.info/")
684 (synopsis "Visualize network traffic by bandwidth use")
685 (description
686 "Jnettop is a traffic visualiser, which captures traffic going
687through the host it is running from and displays streams sorted
688by bandwidth they use.")
f61e0e79 689 (license license:gpl2+)))
87216303
EB
690
691(define-public clusterssh
692 (package
693 (name "clusterssh")
694 (version "3.28")
695 (source (origin
696 (method url-fetch)
697 (uri (string-append "mirror://sourceforge/clusterssh/"
de67e922
LF
698 "1.%20ClusterSSH%20Series%203/" version
699 "/clusterssh-" version ".tar.gz"))
87216303
EB
700 (sha256
701 (base32
702 "1bwggpvaj2al5blg1ynapviv2kpydffpzq2zkhi81najnvzc1rr7"))))
703 (build-system gnu-build-system)
704 (inputs `(("perl" ,perl)))
705 (propagated-inputs `(("xterm" ,xterm)
706 ("perl-tk" ,perl-tk)
707 ("perl-x11-protocol" ,perl-x11-protocol)))
708 (arguments
709 `(#:phases
710 (alist-cons-after
711 'install 'set-load-paths
712 (lambda* (#:key inputs outputs #:allow-other-keys)
713 ;; Put the perl-tk and perl-x11-protocol modules in the perl inc
714 ;; path for PROG
715 (let* ((out (assoc-ref outputs "out"))
716 (prog (string-append out "/bin/cssh"))
717 (perl-ver ,(package-version perl))
718 (x11-inc (string-append
719 (assoc-ref inputs "perl-x11-protocol")
720 "/lib/perl5/site_perl/" perl-ver))
721 (tk-inc (string-append
722 (assoc-ref inputs "perl-tk")
723 "/lib/perl5/site_perl/" perl-ver
724 "/x86_64-linux")))
725 (wrap-program
726 prog
727 `("PERL5LIB" ":" prefix (,x11-inc ,tk-inc)))))
728 %standard-phases)))
729 ;; The clusterssh.sourceforge.net address requires login to view
3b3b60d0 730 (home-page "https://sourceforge.net/projects/clusterssh/")
87216303
EB
731 (synopsis "Secure concurrent multi-server terminal control")
732 (description
733 "ClusterSSH controls a number of xterm windows via a single graphical
734console window to allow commands to be interactively run on multiple servers
735over ssh connections.")
f61e0e79 736 (license license:gpl2+)))
fccf2fe0
LC
737
738(define-public rottlog
739 (package
740 (name "rottlog")
741 (version "0.72.2")
742 (source (origin
743 (method url-fetch)
744 (uri (string-append "mirror://gnu/rottlog/rottlog-"
745 version ".tar.gz"))
746 (sha256
747 (base32
748 "0751mb9l2f0jrk3vj6q8ilanifd121dliwk0c34g8k0dlzsv3kd7"))
749 (modules '((guix build utils)))
750 (snippet
751 '(substitute* "Makefile.in"
752 (("-o \\$\\{LOG_OWN\\} -g \\$\\{LOG_GROUP\\}")
753 ;; Don't try to chown root.
754 "")
755 (("mkdir -p \\$\\(ROTT_STATDIR\\)")
756 ;; Don't attempt to create /var/lib/rottlog.
757 "true")))))
758 (build-system gnu-build-system)
759 (arguments
268ad34e 760 '(#:configure-flags (list "ROTT_ETCDIR=/etc/rottlog" ;rc file location
fccf2fe0 761 "--localstatedir=/var")
268ad34e
LC
762
763 ;; Install example config files in OUT/etc.
764 #:make-flags (list (string-append "ROTT_ETCDIR="
765 (assoc-ref %outputs "out")
766 "/etc"))
767
8dc0ecae 768 #:phases (modify-phases %standard-phases
11e74634
JN
769 (add-after 'build 'set-packdir
770 (lambda _
771 ;; Set a default location for archived logs.
772 (substitute* "rc/rc"
773 (("packdir=\"\"")
774 "packdir=\"/var/log\""))
775 #t))
309e523e
LC
776 (add-before 'install 'tweak-rc-weekly
777 (lambda _
778 (substitute* "rc/weekly"
779 (("/bin/kill")
780 (which "kill"))
781 (("syslogd\\.pid")
782 ;; The file is called 'syslog.pid' (no 'd').
783 "syslog.pid"))
784 #t))
8dc0ecae
LC
785 (add-after 'install 'install-info
786 (lambda _
787 (zero? (system* "make" "install-info")))))))
fccf2fe0
LC
788 (native-inputs `(("texinfo" ,texinfo)
789 ("util-linux" ,util-linux))) ; for 'cal'
790 (home-page "http://www.gnu.org/software/rottlog/")
791 (synopsis "Log rotation and management")
792 (description
793 "GNU Rot[t]log is a program for managing log files. It is used to
794automatically rotate out log files when they have reached a given size or
795according to a given schedule. It can also be used to automatically compress
796and archive such logs. Rot[t]log will mail reports of its activity to the
797system administrator.")
f61e0e79 798 (license license:gpl3+)))
e1485c7b
LC
799
800(define-public sudo
801 (package
802 (name "sudo")
4fb14fad 803 (version "1.8.19p1")
e1485c7b
LC
804 (source (origin
805 (method url-fetch)
806 (uri
6baa83d2 807 (list (string-append "https://www.sudo.ws/sudo/dist/sudo-"
e1485c7b
LC
808 version ".tar.gz")
809 (string-append "ftp://ftp.sudo.ws/pub/sudo/OLD/sudo-"
810 version ".tar.gz")))
811 (sha256
812 (base32
4fb14fad 813 "14pwdwl03kdbbyjkvxrfx409x3c1fjqz8aqz2wgwddinhz7v3bxq"))))
e1485c7b
LC
814 (build-system gnu-build-system)
815 (arguments
0086ec73
LC
816 `(#:configure-flags
817 (list "--with-logpath=/var/log/sudo.log"
7b78f359 818 "--with-rundir=/var/run/sudo" ;must be cleaned up at boot time
0086ec73
LC
819 "--with-vardir=/var/db/sudo"
820 "--with-iologdir=/var/log/sudo-io"
821
822 ;; 'visudo.c' expects _PATH_MV to be defined, but glibc doesn't
823 ;; provide it.
824 (string-append "CPPFLAGS=-D_PATH_MV='\""
825 (assoc-ref %build-inputs "coreutils")
826 "/bin/mv\"'"))
511495fb
LC
827
828 ;; Avoid non-determinism; see <http://bugs.gnu.org/21918>.
829 #:parallel-build? #f
830
e1485c7b
LC
831 #:phases (alist-cons-before
832 'configure 'pre-configure
833 (lambda _
0086ec73
LC
834 (substitute* "src/sudo_usage.h.in"
835 ;; Do not capture 'configure' arguments since we would
836 ;; unduly retain references, and also because the
837 ;; CPPFLAGS above would close the string literal
838 ;; prematurely.
839 (("@CONFIGURE_ARGS@") "\"\""))
e1485c7b 840 (substitute* (find-files "." "Makefile\\.in")
0086ec73 841 (("-o [[:graph:]]+ -g [[:graph:]]+")
e1485c7b
LC
842 ;; Allow installation as non-root.
843 "")
844 (("^install: (.*)install-sudoers(.*)" _ before after)
845 ;; Don't try to create /etc/sudoers.
e1626e3b
SB
846 (string-append "install: " before after "\n"))
847 (("\\$\\(DESTDIR\\)\\$\\(rundir\\)")
848 ;; Don't try to create /run/sudo.
849 "$(TMPDIR)/dummy")
850 (("\\$\\(DESTDIR\\)\\$\\(vardir\\)")
851 ;; Don't try to create /var/db/sudo.
852 "$(TMPDIR)/dummy")))
e1485c7b
LC
853 %standard-phases)
854
855 ;; XXX: The 'testsudoers' test series expects user 'root' to exist, but
856 ;; the chroot's /etc/passwd doesn't have it. Turn off the tests.
857 #:tests? #f))
858 (inputs
859 `(("groff" ,groff)
860 ("linux-pam" ,linux-pam)
861 ("coreutils" ,coreutils)))
6baa83d2 862 (home-page "https://www.sudo.ws/")
e1485c7b
LC
863 (synopsis "Run commands as root")
864 (description
865 "Sudo (su \"do\") allows a system administrator to delegate authority to
866give certain users (or groups of users) the ability to run some (or all)
867commands as root or another user while providing an audit trail of the
868commands and their arguments.")
869
870 ;; See <http://www.sudo.ws/sudo/license.html>.
f61e0e79 871 (license license:x11)))
952298d7 872
1ce6f43a 873(define-public wpa-supplicant-minimal
952298d7 874 (package
1ce6f43a 875 (name "wpa-supplicant-minimal")
fc008121 876 (version "2.6")
952298d7
LC
877 (source (origin
878 (method url-fetch)
879 (uri (string-append
9a727700 880 "http://w1.fi/releases/wpa_supplicant-"
952298d7
LC
881 version
882 ".tar.gz"))
883 (sha256
884 (base32
fc008121 885 "0l0l5gz3d5j9bqjsbjlfcv4w4jwndllp9fmyai4x9kg6qhs6v4xl"))))
952298d7
LC
886 (build-system gnu-build-system)
887 (arguments
888 '(#:phases (alist-replace
889 'configure
890 (lambda* (#:key outputs #:allow-other-keys)
891 (chdir "wpa_supplicant")
892 (copy-file "defconfig" ".config")
893 (let ((port (open-file ".config" "al")))
894 (display "
895 CONFIG_DEBUG_SYSLOG=y
40b4c6d6 896
61bdd0d8
LC
897 # Choose GnuTLS (the default is OpenSSL.)
898 CONFIG_TLS=gnutls
899
952298d7
LC
900 CONFIG_DRIVER_NL80211=y
901 CFLAGS += $(shell pkg-config libnl-3.0 --cflags)
902 CONFIG_LIBNL32=y
903 CONFIG_READLINE=y\n" port)
904 (close-port port)))
ffd74de0
LC
905
906 (alist-cons-after
907 'install 'install-man-pages
908 (lambda* (#:key outputs #:allow-other-keys)
909 (let* ((out (assoc-ref outputs "out"))
910 (man (string-append out "/share/man"))
911 (man5 (string-append man "/man5"))
912 (man8 (string-append man "/man8")))
913 (define (copy-man-page target)
914 (lambda (file)
915 (copy-file file
916 (string-append target "/"
917 (basename file)))))
918
919 (mkdir-p man5) (mkdir man8)
920 (for-each (copy-man-page man5)
921 (find-files "doc/docbook" "\\.5"))
922 (for-each (copy-man-page man8)
923 (find-files "doc/docbook" "\\.8"))
924 #t))
925 %standard-phases))
952298d7
LC
926
927 #:make-flags (list "CC=gcc"
928 (string-append "BINDIR=" (assoc-ref %outputs "out")
929 "/sbin")
930 (string-append "LIBDIR=" (assoc-ref %outputs "out")
931 "/lib"))
932 #:tests? #f))
933 (inputs
934 `(("readline" ,readline)
935 ("libnl" ,libnl)
61bdd0d8
LC
936 ("gnutls" ,gnutls)
937 ("libgcrypt" ,libgcrypt))) ;needed by crypto_gnutls.c
952298d7
LC
938 (native-inputs
939 `(("pkg-config" ,pkg-config)))
9a727700 940 (home-page "http://w1.fi/wpa_supplicant/")
952298d7
LC
941 (synopsis "Connecting to WPA and WPA2-protected wireless networks")
942 (description
943 "wpa_supplicant is a WPA Supplicant with support for WPA and WPA2 (IEEE
944802.11i / RSN). Supplicant is the IEEE 802.1X/WPA component that is used in
945the client stations. It implements key negotiation with a WPA Authenticator
946and it controls the roaming and IEEE 802.11 authentication/association of the
947WLAN driver.
948
949This package provides the 'wpa_supplicant' daemon and the 'wpa_cli' command.")
950
951 ;; In practice, this is linked against Readline, which makes it GPLv3+.
f61e0e79 952 (license license:bsd-3)))
c6b76405 953
4fb7e0de 954(define-public wpa-supplicant
1ce6f43a 955 (package (inherit wpa-supplicant-minimal)
4fb7e0de
MW
956 (name "wpa-supplicant")
957 (inputs `(("dbus" ,dbus)
1ce6f43a 958 ,@(package-inputs wpa-supplicant-minimal)))
4fb7e0de 959 (arguments
1ce6f43a 960 (substitute-keyword-arguments (package-arguments wpa-supplicant-minimal)
4fb7e0de 961 ((#:phases phases)
6744aba8
MW
962 `(alist-cons-after
963 'configure 'configure-for-dbus
964 (lambda _
965 (let ((port (open-file ".config" "al")))
966 (display "
4fb7e0de
MW
967 CONFIG_CTRL_IFACE_DBUS=y
968 CONFIG_CTRL_IFACE_DBUS_NEW=y
969 CONFIG_CTRL_IFACE_DBUS_INTRO=y\n" port)
6744aba8
MW
970 (close-port port))
971 #t)
972 (alist-cons-after
973 'install-man-pages 'install-dbus-conf
974 (lambda* (#:key outputs #:allow-other-keys)
975 (let* ((out (assoc-ref outputs "out"))
976 (dir (string-append out "/etc/dbus-1/system.d")))
977 (mkdir-p dir)
978 (copy-file "dbus/dbus-wpa_supplicant.conf"
979 (string-append dir "/wpa_supplicant.conf"))))
980 ,phases)))))))
4fb7e0de 981
c6b76405
LC
982(define-public wakelan
983 (package
984 (name "wakelan")
985 (version "1.1")
986 (source (origin
987 (method url-fetch)
988 (uri (string-append
989 "ftp://ftp.gwdg.de/pub/linux/metalab/system/network/misc/wakelan-"
990 version ".tar.gz"))
991 (sha256
992 (base32
993 "0vydqpf44146ir6k87gmqaq6xy66xhc1gkr3nsd7jj3nhy7ypx9x"))))
994 (build-system gnu-build-system)
995 (arguments
996 '(#:phases (alist-replace
997 'configure
998 (lambda* (#:key outputs #:allow-other-keys)
999 (let ((out (assoc-ref outputs "out")))
1000 (mkdir-p (string-append out "/bin"))
1001 (mkdir-p (string-append out "/share/man/man1"))
1002
1003 ;; It's an old configure script that doesn't understand
1004 ;; the extra options we pass.
1005 (setenv "CONFIG_SHELL" (which "bash"))
1006 (zero?
1007 (system* "./configure"
1008 (string-append "--prefix=" out)
1009 (string-append "--mandir=" out
1010 "/share/man")))))
1011 %standard-phases)
1012 #:tests? #f))
1013 (home-page "http://kernel.org") ; really, no home page
1014 (synopsis "Send a wake-on-LAN packet")
1015 (description
1016 "WakeLan broadcasts a properly formatted UDP packet across the local area
1017network, which causes enabled computers to power on.")
f61e0e79 1018 (license license:gpl2+)))
d43f4296
LC
1019
1020(define-public dmidecode
1021 (package
1022 (name "dmidecode")
06438b07 1023 (version "3.0")
d43f4296
LC
1024 (source (origin
1025 (method url-fetch)
1026 (uri (string-append
1027 "mirror://savannah/dmidecode/dmidecode-"
06438b07 1028 version ".tar.xz"))
d43f4296
LC
1029 (sha256
1030 (base32
06438b07 1031 "0iby0xfk5x3cdr0x0gxj5888jjyjhafvaq0l79civ73jjfqmphvy"))))
d43f4296
LC
1032 (build-system gnu-build-system)
1033 (arguments
06438b07 1034 '(#:phases (modify-phases %standard-phases (delete 'configure))
d43f4296
LC
1035 #:tests? #f ; no 'check' target
1036 #:make-flags (list (string-append "prefix="
1037 (assoc-ref %outputs "out")))))
1038 (home-page "http://www.nongnu.org/dmidecode/")
1039 (synopsis "Read hardware information from the BIOS")
1040 (description
1041 "Dmidecode reports information about your system's hardware as described
1042in your system BIOS according to the SMBIOS/DMI standard. This typically
1043includes system manufacturer, model name, serial number, BIOS version, asset
1044tag as well as a lot of other details of varying level of interest and
1045reliability depending on the manufacturer. This will often include usage
1046status for the CPU sockets, expansion slots (e.g. AGP, PCI, ISA) and memory
1047module slots, and the list of I/O ports (e.g. serial, parallel, USB).")
f61e0e79 1048 (license license:gpl2+)))
42dc3af5 1049
13c8c2bf
MW
1050(define-public acpica
1051 (package
1052 (name "acpica")
2036a648 1053 (version "20150410")
13c8c2bf
MW
1054 (source (origin
1055 (method url-fetch)
1056 (uri (string-append
1057 "https://acpica.org/sites/acpica/files/acpica-unix2-"
1058 version ".tar.gz"))
1059 (sha256
1060 (base32
2036a648 1061 "0q1fjwkyw9x6gsva6fd0zbn7ly4fx0ha4853f416np9kf2irillw"))))
13c8c2bf
MW
1062 (build-system gnu-build-system)
1063 (native-inputs `(("flex" ,flex)
1064 ("bison" ,bison)))
1065 (arguments
1066 '(#:make-flags (list (string-append "PREFIX=" %output)
1067 "HOST=_LINUX"
1068 "OPT_CFLAGS=-Wall -fno-strict-aliasing")
1069 #:tests? #f ; no 'check' target.
1070 #:phases (alist-delete 'configure %standard-phases)))
1071 (home-page "http://acpica.org/")
35b9e423 1072 (synopsis "Tools for the development and debug of ACPI tables")
13c8c2bf
MW
1073 (description
1074 "The ACPI Component Architecture (ACPICA) project provides an
1075OS-independent reference implementation of the Advanced Configuration and
1076Power Interface Specification (ACPI). ACPICA code contains those portions of
1077ACPI meant to be directly integrated into the host OS as a kernel-resident
1078subsystem, and a small set of tools to assist in developing and debugging ACPI
1079tables. This package contains only the user-space tools needed for ACPI table
1080development, not the kernel implementation of ACPI.")
f61e0e79 1081 (license license:gpl2))) ; Dual GPLv2/ACPICA Licence
4cf7bd2b
MW
1082
1083(define-public stress
1084 (package
1085 (name "stress")
1086 (version "1.0.1")
1087 (source (origin
1088 (method url-fetch)
1089 (uri (string-append "mirror://debian/pool/main/s/stress/stress_"
1090 version ".orig.tar.gz"))
1091 (sha256
1092 (base32
1093 "1v9vnzlihqfjsxa93hdbrq72pqqk00dkylmlg8jpxhm7s1w9qfl1"))))
1094 (build-system gnu-build-system)
1095 (home-page "http://packages.debian.org/wheezy/stress")
9e771e3b 1096 (synopsis "Impose load on and stress test a computer system")
4cf7bd2b 1097 (description
35b9e423 1098 "Stress is a tool that imposes a configurable amount of CPU, memory, I/O,
4cf7bd2b
MW
1099or disk stress on a POSIX-compliant operating system and reports any errors it
1100detects.
1101
35b9e423 1102Stress is not a benchmark. It is a tool used by system administrators to
4cf7bd2b
MW
1103evaluate how well their systems will scale, by kernel programmers to evaluate
1104perceived performance characteristics, and by systems programmers to expose
1105the classes of bugs which only or more frequently manifest themselves when the
1106system is under heavy load.")
f61e0e79 1107 (license license:gpl2+)))
b36fcf95
EB
1108
1109(define-public detox
1110 (package
1111 (name "detox")
1112 (version "1.2.0")
1113 (source (origin
1114 (method url-fetch)
de67e922
LF
1115 (uri (string-append "mirror://sourceforge/detox/detox/" version
1116 "/detox-" version ".tar.bz2"))
b36fcf95
EB
1117 (sha256
1118 (base32
1119 "1y6vvjqsg54kl49cry73jbfhr04s7wjs779vrr9zrq6kww7dkymb"))))
1120 (build-system gnu-build-system)
1121 ;; Both flex and popt are used in this case for their runtime libraries
1122 ;; (libfl and libpopt).
1123 (inputs
1124 `(("flex" ,flex)
1125 ("popt" ,popt)))
1126 (arguments
1127 `(#:configure-flags `(,(string-append "--with-popt="
1128 (assoc-ref %build-inputs "popt")))
1129 #:tests? #f)) ;no 'check' target
1130 (home-page "http://detox.sourceforge.net")
e881752c 1131 (synopsis "Clean up file names")
b36fcf95
EB
1132 (description
1133 "Detox is a program that renames files to make them easier to work with
1134under Unix and related operating systems. Spaces and various other unsafe
1135characters (such as \"$\") get replaced with \"_\". ISO 8859-1 (Latin-1)
1136characters can be replaced as well, as can UTF-8 characters.")
f61e0e79 1137 (license license:bsd-3)))
c4492a16
LC
1138
1139(define-public testdisk
1140 (package
1141 (name "testdisk")
cf91cfc0 1142 (version "7.0")
c4492a16
LC
1143 (source (origin
1144 (method url-fetch)
1145 (uri (string-append "http://www.cgsecurity.org/testdisk-"
1146 version ".tar.bz2"))
1147 (sha256
1148 (base32
cf91cfc0 1149 "0ba4wfz2qrf60vwvb1qsq9l6j0pgg81qgf7fh22siaz649mkpfq0"))))
c4492a16
LC
1150 (build-system gnu-build-system)
1151 (inputs
d6a08ec0 1152 `(("ntfs-3g" ,ntfs-3g)
c4492a16 1153 ("util-linux" ,util-linux)
cc2b77df 1154 ("openssl" ,openssl)
d6a08ec0 1155 ;; FIXME: add reiserfs
f61e0e79 1156 ("zlib" ,zlib)
c4492a16
LC
1157 ("e2fsprogs" ,e2fsprogs)
1158 ("libjpeg" ,libjpeg)
1159 ("ncurses" ,ncurses)))
1160 (home-page "http://www.cgsecurity.org/wiki/TestDisk")
1161 (synopsis "Data recovery tool")
1162 (description
1163 "TestDisk is a program for data recovery, primarily designed to help
1164recover lost partitions and/or make non-booting disks bootable again.")
f61e0e79 1165 (license license:gpl2+)))
c4492a16 1166
15926aec
AS
1167(define-public tree
1168 (package
1169 (name "tree")
1170 (version "1.7.0")
1171 (source (origin
1172 (method url-fetch)
1173 (uri (string-append
1174 "http://mama.indstate.edu/users/ice/tree/src/tree-"
1175 version ".tgz"))
1176 (sha256
1177 (base32 "04kviw799qxly08zb8n5mgxfd96gyis6x69q2qiw86jnh87c4mv9"))))
1178 (build-system gnu-build-system)
1179 (arguments
1180 '(#:phases (alist-delete 'configure %standard-phases)
1181 #:tests? #f ; no check target
1182 #:make-flags (let ((out (assoc-ref %outputs "out")))
1183 (list (string-append "prefix=" out)))))
1184 (synopsis "Recursively list the contents of a directory")
1185 (description
1186 "Tree is a recursive directory listing command that produces a depth
1187indented listing of files, which is colorized ala dircolors if the LS_COLORS
1188environment variable is set and output is to tty.")
1189 (home-page "http://mama.indstate.edu/users/ice/tree/")
1190 (license license:gpl2+)))
1191
c2619e10
LC
1192(define-public direvent
1193 (package
1194 (name "direvent")
bac67a5a 1195 (version "5.1")
c2619e10
LC
1196 (source (origin
1197 (method url-fetch)
1198 (uri (string-append "mirror://gnu/direvent/direvent-"
1199 version ".tar.gz"))
1200 (sha256
1201 (base32
bac67a5a 1202 "1nwvjmx7kb14ni34c0b8x9a3791pc20gvhj7xaj66d8q4h6n0qf4"))
c2619e10
LC
1203 (modules '((guix build utils)))
1204 (snippet '(substitute* "tests/testsuite"
1205 (("#![[:blank:]]?/bin/sh")
1206 "#!$SHELL")))))
1207 (build-system gnu-build-system)
1208 (arguments
1209 '(#:phases (alist-cons-before
1210 'build 'patch-/bin/sh
1211 (lambda* (#:key inputs #:allow-other-keys)
bac67a5a
LC
1212 ;; Use the right shell when executing the watcher and
1213 ;; user-provided shell commands.
c2619e10 1214 (let ((bash (assoc-ref inputs "bash")))
bac67a5a 1215 (substitute* '("src/direvent.c" "src/progman.c")
c2619e10 1216 (("\"/bin/sh\"")
bac67a5a
LC
1217 (string-append "\"" bash "/bin/sh\"")))
1218
1219 ;; Adjust the 'shell.at' test accordingly.
1220 (substitute* "tests/testsuite"
1221 (("SHELL=/bin/sh")
1222 (string-append "SHELL=" bash "/bin/sh")))
1223
1224 #t))
c2619e10
LC
1225 %standard-phases)))
1226 (home-page "http://www.gnu.org/software/direvent/")
1227 (synopsis "Daemon to monitor directories for events such as file removal")
1228 (description
1229 "A daemon that monitors directories for events, such as creating,
35b9e423 1230deleting or modifying files. It can monitor different sets of directories for
c2619e10
LC
1231different events. When an event is detected, direvent calls a specified
1232external program with information about the event, such as the location
c5779c93
LC
1233within the file system where it occurred. Thus, \"direvent\" provides an
1234easy way to react immediately if given files undergo changes, for example, to
c2619e10 1235track changes in important system configuration files.")
f61e0e79 1236 (license license:gpl3+)))
da6c3749
TUBK
1237
1238(define-public libcap-ng
1239 (package
1240 (name "libcap-ng")
1241 (version "0.7.4")
1242 (source (origin
1243 (method url-fetch)
1244 (uri (string-append
1245 "http://people.redhat.com/sgrubb/libcap-ng/libcap-ng-"
1246 version ".tar.gz"))
1247 (sha256
1248 (base32
1249 "0ssvnh4cvhya0c1j6k6192zvqcq7nc0x01fb5nwhr0prfqr0i8j8"))))
1250 (build-system gnu-build-system)
1251 (inputs `(("python" ,python)))
1252 (home-page "http://people.redhat.com/sgrubb/libcap-ng/")
1253 (synopsis "Library for more easily working with POSIX capabilities")
1254 (description
1255 "The libcap-ng library is intended to make programming with POSIX
1256capabilities easier than the traditional libcap library. It includes
1257utilities that can analyse all currently running applications and print out
1258any capabilities and whether or not it has an open ended bounding set. The
1259included utilities are designed to let admins and developers spot apps from
1260various ways that may be running with too much privilege.")
1261 ;; The library is lgpl2.1+, but also ships some utils which are gpl2+.
f61e0e79 1262 (license (list license:lgpl2.1+ license:gpl2+))))
d02f2cc4
TUBK
1263
1264(define-public smartmontools
1265 (package
1266 (name "smartmontools")
85de4365 1267 (version "6.5")
d02f2cc4
TUBK
1268 (source (origin
1269 (method url-fetch)
1270 (uri (string-append
1271 "mirror://sourceforge/smartmontools/smartmontools/"
1272 version "/smartmontools-" version ".tar.gz"))
1273 (sha256
1274 (base32
85de4365 1275 "1g25r6sx85b5lay5n6sbnqv05qxzj6xsafsp93hnrg1h044bps49"))))
d02f2cc4
TUBK
1276 (build-system gnu-build-system)
1277 (inputs `(("libcap-ng" ,libcap-ng)))
1278 (home-page "http://www.smartmontools.org/")
1279 (synopsis "S.M.A.R.T. harddisk control and monitoring tools")
1280 (description
1281 "The smartmontools package contains utility programs to control and
1282monitor storage systems using the Self-Monitoring, Analysis and Reporting
1283Technology System (S.M.A.R.T.) built into most modern ATA and SCSI harddisks.
1284In many cases, these utilities will provide advanced warning of disk
1285degradation and failure.")
f61e0e79 1286 (license license:gpl2+)))
6efd0823
RW
1287
1288(define-public fdupes
1289 (package
1290 (name "fdupes")
47d7b303 1291 (version "1.6.1")
6efd0823
RW
1292 (source
1293 (origin
1294 (method url-fetch)
1295 (uri (string-append
47d7b303 1296 "https://github.com/adrianlopezroche/fdupes/archive/v"
6efd0823 1297 version ".tar.gz"))
47d7b303 1298 (file-name (string-append name "-" version ".tar.gz"))
6efd0823
RW
1299 (sha256
1300 (base32
47d7b303 1301 "1sj9pa40pbz6xdwbxfwhdhkvhdf1xc5gvggk9mdq26c41gdnyswx"))))
6efd0823
RW
1302 (build-system gnu-build-system)
1303 (arguments
e192a230
TGR
1304 '(#:phases (modify-phases %standard-phases
1305 (delete 'configure))
6efd0823 1306 #:tests? #f ; no 'check' target
47d7b303
TGR
1307 #:make-flags (list "CC=gcc"
1308 (string-append "PREFIX="
6efd0823
RW
1309 (assoc-ref %outputs "out")))))
1310 (home-page "https://github.com/adrianlopezroche/fdupes")
1311 (synopsis "Identify duplicate files")
1312 (description
1313 "fdupes is a program for identifying duplicate files residing within
1314specified directories.")
1315 (license license:expat)))
4ecfbda7
DT
1316
1317(define-public graphios
1318 (package
1319 (name "graphios")
1320 (version "2.0.3")
1321 (source
1322 (origin
1323 (method url-fetch)
1324 (uri (string-append
1325 "https://pypi.python.org/packages/source/g/graphios/graphios-"
1326 version ".tar.gz"))
1327 (sha256
1328 (base32
1329 "1h87hvc315wg6lklbf4l7csd3n5pgljwrfli1p3nasdi0izgn66i"))))
1330 (build-system python-build-system)
1331 (arguments
1332 ;; Be warned: Building with Python 3 succeeds, but the build process
1333 ;; throws a syntax error that is ignored.
1334 `(#:python ,python-2
1335 #:phases
1336 (modify-phases %standard-phases
1337 (add-before 'build 'fix-setup.py
1338 (lambda* (#:key outputs #:allow-other-keys)
1339 ;; Fix hardcoded, unprefixed file names.
1340 (let ((out (assoc-ref outputs "out")))
1341 (substitute* '("setup.py")
1342 (("/etc") (string-append out "/etc"))
1343 (("/usr") out)
1344 (("distro_ver = .*") "distro_ver = ''"))
1345 #t))))))
4ecfbda7
DT
1346 (home-page "https://github.com/shawn-sterling/graphios")
1347 (synopsis "Emit Nagios metrics to Graphite, Statsd, and Librato")
1348 (description
1349 "Graphios is a script to emit nagios perfdata to various upstream metrics
1350processing and time-series systems. It's currently compatible with Graphite,
1351Statsd, Librato and InfluxDB. Graphios can emit Nagios metrics to any number
1352of supported upstream metrics systems simultaneously.")
1353 (license license:gpl2+)))
8d801045
ED
1354
1355(define-public ansible
1356 (package
1357 (name "ansible")
0691c9c0 1358 (version "2.2.1.0")
8d801045
ED
1359 (source
1360 (origin
1361 (method url-fetch)
697e86dd 1362 (uri (pypi-uri "ansible" version))
8d801045
ED
1363 (sha256
1364 (base32
0691c9c0 1365 "0gz9i30pdmkchi936ijy873k8di6fmf3v5rv551hxyf0hjkjx8b3"))))
8d801045
ED
1366 (build-system python-build-system)
1367 (native-inputs
f3b98f4f 1368 `(("python2-pycrypto" ,python2-pycrypto)
8d801045
ED
1369 ("python2-httplib2" ,python2-httplib2)
1370 ("python2-passlib" ,python2-passlib)
1371 ("python2-nose" ,python2-nose)
1372 ("python2-mock" ,python2-mock)
1373 ("python2-jinja2" ,python2-jinja2)
1374 ("python2-pyyaml" ,python2-pyyaml)
1375 ("python2-paramiko" ,python2-paramiko)))
1376 (inputs
1377 `(("python2-pycrypto" ,python2-pycrypto)
1378 ("python2-jinja2" ,python2-jinja2)
1379 ("python2-pyyaml" ,python2-pyyaml)
1380 ("python2-paramiko" ,python2-paramiko)))
1381 (arguments
1382 `(#:python ,python-2)) ; incompatible with Python 3
1383 (home-page "http://ansible.com/")
1384 (synopsis "Radically simple IT automation")
1385 (description "Ansible is a radically simple IT automation system. It
1386handles configuration-management, application deployment, cloud provisioning,
1387ad-hoc task-execution, and multinode orchestration - including trivializing
1388things like zero downtime rolling updates with load balancers.")
1389 (license license:gpl3+)))
44157e9f
EB
1390
1391(define-public cpulimit
1392 (package
1393 (name "cpulimit")
1394 (version "0.2")
1395 (source
1396 (origin
1397 (method url-fetch)
1398 (uri (string-append "https://github.com/opsengine/cpulimit/archive/v"
1399 version ".tar.gz"))
1400 (file-name (string-append name "-" version ".tar.gz"))
1401 (sha256
1402 (base32
1403 "1nn2w849xd5bw4y5sqnll29nxdwl5h0cv4smc7dwmpb9qnd2ycb4"))))
1404 (build-system gnu-build-system)
1405 (arguments
1406 `(#:phases (modify-phases %standard-phases
1407 (delete 'configure)
1408 (replace
1409 'build
1410 (lambda _
1411 (zero? (system* "make" "CC=gcc" "-Csrc"))))
1412 (replace
1413 'check
1414 (lambda _
1415 (zero? (system* "make" "CC=gcc" "-Ctests"))))
1416 (replace
1417 'install
1418 (lambda* (#:key outputs #:allow-other-keys)
1419 (let* ((out (assoc-ref outputs "out"))
1420 (bin (string-append out "/bin")))
1421 (install-file "src/cpulimit" bin)))))))
1422 (home-page "https://github.com/opsengine/cpulimit")
1423 (synopsis "Limit CPU usage")
1424 (description
1425 "Cpulimit limits the CPU usage of a process. It does not change the nice
1426value or other scheduling priority settings, but the real CPU usage, and is
1427able to adapt itself dynamically to the overall system load. Children
1428processes and threads of the specified process may optionally share the same
1429limits.")
1430 (license license:gpl2+)))
2328b47c
EB
1431
1432(define-public autojump
1433 (package
1434 (name "autojump")
1d33b9ea 1435 (version "22.3.4")
2328b47c
EB
1436 (source
1437 (origin
1438 (method url-fetch)
1439 (uri (string-append "https://github.com/wting/autojump/archive/"
1440 "release-v" version ".tar.gz"))
1441 (file-name (string-append name "-" version ".tar.gz"))
1442 (sha256
1443 (base32
1d33b9ea 1444 "113rcpr37ngf2xs8da41qdarq5qmj0dwx8ggqy3lhlb0kvqq7g9z"))))
2328b47c
EB
1445 (build-system gnu-build-system)
1446 (native-inputs ;for tests
1447 `(("python-mock" ,python-mock)
1448 ("python-pytest" ,python-pytest)))
1449 (inputs
1450 `(("python" ,python-wrapper)))
1451 (arguments
1452 `(#:phases (modify-phases %standard-phases
1453 (delete 'configure)
1454 (delete 'build)
1455 (replace 'check
1456 (lambda _
1457 (zero?
0c4520d6 1458 (system* "python" "tests/unit/autojump_utils_test.py"))))
2328b47c
EB
1459 (replace 'install
1460 ;; The install.py script doesn't allow system installation
1461 ;; into an arbitrary prefix, so do our own install.
1462 (lambda* (#:key outputs #:allow-other-keys)
1463 (let* ((out (assoc-ref outputs "out"))
1464 (bin (string-append out "/bin"))
1465 (share (string-append out "/share/autojump"))
1466 (py (string-append out "/lib/python"
1467 ,(version-major+minor
1468 (package-version python-wrapper))
1469 "/site-packages"))
1470 (man (string-append out "/share/man/man1")))
1471 (install-file "bin/autojump" bin)
1472 (for-each (λ (f) (install-file f py))
1473 (find-files "bin" "\\.py$"))
1474 (for-each (λ (f) (install-file f share))
1475 (find-files "bin" "autojump\\..*$"))
1476 (substitute* (string-append share "/autojump.sh")
1477 (("/usr/local") out))
1478 (install-file "docs/autojump.1" man)
1479 (wrap-program (string-append bin "/autojump")
1480 `("PYTHONPATH" ":" prefix (,py)))
1481 #t))))))
1482 (home-page "https://github.com/wting/autojump")
8f65585b 1483 (synopsis "Shell extension for file system navigation")
2328b47c 1484 (description
8f65585b 1485 "Autojump provides a faster way to navigate your file system, with a \"cd
2328b47c
EB
1486command that learns\". It works by maintaining a database of the directories
1487you use the most from the command line and allows you to \"jump\" to
1488frequently used directories by typing only a small pattern.")
1489 (license license:gpl3+)))
765973cd
LF
1490
1491(define-public iftop
1492 (package
1493 (name "iftop")
1494 (version "1.0pre4")
1495 (source (origin
1496 (method url-fetch)
1497 (uri (string-append "http://www.ex-parrot.com/~pdw/iftop/download"
1498 "/iftop-" version ".tar.gz"))
1499 (sha256
1500 (base32
1501 "15sgkdyijb7vbxpxjavh5qm5nvyii3fqcg9mzvw7fx8s6zmfwczp"))))
1502 (build-system gnu-build-system)
1503 (inputs
1504 `(("libpcap" ,libpcap)
1505 ("ncurses" ,ncurses)))
1506 (synopsis "Monitor network usage")
1507 (description "Iftop does for network usage what @command{top} does
1508for CPU usage. It listens to network traffic on a named interface and
1509displays a table of current bandwidth usage by pairs of hosts.")
1510 (home-page "http://www.ex-parrot.com/~pdw/iftop/")
d4e21fbb 1511 (license license:gpl2+)))
f1957fc1
PP
1512
1513(define-public munge
1514 (package
1515 (name "munge")
b52ae4de 1516 (version "0.5.12")
f1957fc1
PP
1517 (source (origin
1518 (method url-fetch)
b52ae4de
EF
1519 (uri (string-append "https://github.com/dun/munge/releases/"
1520 "download/munge-" version "/munge-"
1521 version ".tar.xz"))
f1957fc1
PP
1522 (sha256
1523 (base32
b52ae4de 1524 "1s0vlwgm3hcx75vcmjf2y3icy5nv8y07bx93w2cmm6a7x71y6wp9"))))
f1957fc1
PP
1525 (inputs
1526 `(("openssl" ,openssl)
1527 ("libgcrypt" ,libgcrypt)))
1528 (build-system gnu-build-system)
b52ae4de 1529 (home-page "https://dun.github.io/munge/")
f1957fc1
PP
1530 (synopsis "Cluster computing authentication service")
1531 (description
1532 "Munge is an authentication service for creating and validating
1533credentials. It allows a process to authenticate the UID and GID of another
1534local or remote process within a group of hosts having common users and
1535groups. These hosts form a security realm that is defined by a shared
1536cryptographic key. Clients within this security realm can create and validate
1537credentials without the use of root privileges, reserved ports, or
1538platform-specific methods.")
1539 (license license:gpl3+)))
3d7a157c
RW
1540
1541(define-public audit
1542 (package
1543 (name "audit")
1544 (version "2.4.5")
1545 (source (origin
1546 (method url-fetch)
1547 (uri (string-append "http://people.redhat.com/sgrubb/audit/"
1548 "audit-" version ".tar.gz"))
1549 (sha256
1550 (base32
1551 "1q1q51dvxscbi4kbakmd4bn0xrvwwaiwvaya79925cbrqwzxsg77"))))
1552 (build-system gnu-build-system)
1553 (home-page "http://people.redhat.com/sgrubb/audit/")
1554 (arguments
1555 `(#:configure-flags (list "--with-python=no")
1556 #:phases
1557 (modify-phases %standard-phases
1558 (add-after 'unpack 'fix-tests
1559 (lambda _
1560 ;; In the build environmnte /etc/passwd does not contain an entry
1561 ;; for root/0, so we have to patch the expected value.
1562 (substitute* "auparse/test/auparse_test.ref"
1563 (("=0 \\(root\\)") "=0 (unknown(0))"))
1564 #t)))))
1565 (inputs
1566 `(("openldap" ,openldap)
1bafad56 1567 ("gnutls" ,gnutls)
3d7a157c
RW
1568 ("sasl" ,cyrus-sasl)))
1569 (synopsis "User-space component to the Linux auditing system")
1570 (description
1571 "auditd is the user-space component to the Linux auditing system, which
1572allows logging of system calls made by user-land processes. It's responsible
1573for writing audit records to the disk. Viewing the logs is done with the
1574@code{ausearch} or @code{aureport} utilities. Configuring the audit rules is
1575done with the @code{auditctl} utility.")
1576 (license license:gpl2+)))
d0457553
TUBK
1577
1578(define-public nmap
1579 (package
1580 (name "nmap")
21eced80 1581 (version "7.40")
d0457553
TUBK
1582 (source (origin
1583 (method url-fetch)
1584 (uri (string-append "https://nmap.org/dist/nmap-" version
1585 ".tar.bz2"))
1586 (sha256
1587 (base32
21eced80 1588 "121i9mgyc28ra2825akd0ix5qyssv4xc2qlx296mam6hzxgnc54y"))
d0457553
TUBK
1589 (modules '((guix build utils)))
1590 (snippet
1591 '(map delete-file-recursively
1592 ;; Remove bundled lua, pcap, and pcre libraries.
1593 ;; FIXME: Remove bundled liblinear once packaged.
1594 '("liblua"
1595 "libpcap"
1596 "libpcre"
1597 ;; Remove pre-compiled binares.
1598 "mswin32")))))
1599 (build-system gnu-build-system)
1600 (inputs
1601 `(("openssl" ,openssl)
1602 ("libpcap" ,libpcap)
1603 ("pcre" ,pcre)
1604 ("lua" ,lua)
1605 ;; For 'ndiff'.
1606 ("python" ,python-2)))
1607
1608 ;; TODO Add zenmap output.
1609 (outputs '("out" "ndiff"))
1610 (arguments
1611 '(#:configure-flags '("--without-zenmap")
1612 #:phases
1613 (modify-phases %standard-phases
f4dc22bc
MB
1614 (add-after 'configure 'patch-Makefile
1615 (lambda _
1616 (substitute* "Makefile"
1617 ;; Do not attempt to build lua.
1618 (("build-dnet build-lua") "build-dnet"))
1619 #t))
d0457553
TUBK
1620 (replace 'install
1621 (lambda* (#:key outputs #:allow-other-keys)
1622 (define (make out . args)
1623 (unless (zero? (apply system* "make"
1624 (string-append "prefix=" out)
1625 args))
1626 (error "make failed")))
1627 (define (python-path dir)
1628 (string-append dir "/lib/python2.7/site-packages"))
1629 (let ((out (assoc-ref outputs "out"))
1630 (ndiff (assoc-ref outputs "ndiff")))
1631 (for-each mkdir-p (list out ndiff))
1632 (make out
1633 "install-nmap"
1634 "install-nse"
1635 "install-ncat"
1636 "install-nping")
1637 (make ndiff "install-ndiff")
1638 (wrap-program (string-append ndiff "/bin/ndiff")
1639 `("PYTHONPATH" prefix
1640 (,(python-path ndiff)))))))
1641 ;; These are the tests that do not require network access.
1642 (replace 'check
1643 (lambda _ (zero? (system* "make"
1644 "check-nse"
1645 "check-ndiff"
1646 "check-dns")))))
1647 ;; Nmap can't cope with out-of-source building.
1648 #:out-of-source? #f))
1649 (home-page "https://nmap.org/")
1650 (synopsis "Network discovery and security auditing tool")
1651 (description
1652 "Nmap (\"Network Mapper\") is a network discovery and security auditing
1653tool. It is also useful for tasks such as network inventory, managing service
1654upgrade schedules, and monitoring host or service uptime. It also provides an
1655advanced netcat implementation (ncat), a utility for comparing scan
1656results (ndiff), and a packet generation and response analysis tool (nping).")
1657 ;; This package uses nmap's bundled versions of libdnet and liblinear, which
1658 ;; both use a 3-clause BSD license.
1659 (license (list license:nmap license:bsd-3))))
1a0346f0
P
1660
1661(define-public dstat
1662 (package
1663 (name "dstat")
1664 (version "0.7.3")
1665 (source (origin
1666 (method url-fetch)
1667 (uri (string-append
1668 "https://github.com/dagwieers/dstat/archive/"
1669 version ".tar.gz"))
1670 (file-name (string-append "dstat-" version ".tar.gz"))
1671 (sha256
1672 (base32
1673 "16286z3y2lc9nsq8njzjkv6k2vyxrj9xiixj1k3gnsbvhlhkirj6"))))
1674 (build-system gnu-build-system)
1675 (arguments
1676 `(#:tests? #f ;; no make check
1677 #:make-flags (let ((out (assoc-ref %outputs "out")))
1678 (list (string-append "DESTDIR=" out)
1679 "prefix=/"))
1680 ;; no configure script
1681 #:phases (alist-delete 'configure %standard-phases)))
1682 (inputs `(("python-2" ,python-2)))
1683 (synopsis "Versatile resource statistics tool")
1684 (description "Dstat is a versatile replacement for @command{vmstat},
1685@command{iostat}, @command{netstat}, and @command{ifstat}. Dstat overcomes
1686some of their limitations and adds some extra features, more counters and
1687flexibility. Dstat is handy for monitoring systems during performance tuning
1688tests, benchmarks or troubleshooting.
1689
1690Dstat allows you to view all of your system resources in real-time, you can,
1691e.g., compare disk utilization in combination with interrupts from your IDE
1692controller, or compare the network bandwidth numbers directly with the disk
1693throughput (in the same interval).")
1694 (home-page "http://dag.wiee.rs/home-made/dstat/")
c59f62e9 1695 (license license:gpl2+)))
0405e5f4
EB
1696
1697(define-public thefuck
1698 (package
1699 (name "thefuck")
d24e011e 1700 (version "3.11")
0405e5f4
EB
1701 (source (origin
1702 (method url-fetch)
1703 (uri (string-append "https://github.com/nvbn/thefuck/archive/"
1704 version ".tar.gz"))
1705 (file-name (string-append name "-" version ".tar.gz"))
1706 (sha256
1707 (base32
d24e011e 1708 "04q2cn8c83f6z6wn1scla1ilrpi5ssjc64987hvmwfvwvb82bvkp"))))
0405e5f4 1709 (build-system python-build-system)
0405e5f4
EB
1710 (inputs
1711 `(("python-colorama" ,python-colorama)
1712 ("python-decorator" ,python-decorator)
1713 ("python-psutil" ,python-psutil)
1714 ("python-six" ,python-six)))
2d1ac1d1 1715 (native-inputs
48160559
HG
1716 ;; Requires setuptools >= 17.1 due to some features used, while our
1717 ;; python currently only includes 12.0. TODO: Remove this input.
1718 `(("python-setuptools" ,python-setuptools)))
0405e5f4
EB
1719 (home-page "https://github.com/nvbn/thefuck")
1720 (synopsis "Correct mistyped console command")
1721 (description
1722 "The Fuck tries to match a rule for a previous, mistyped command, creates
1723a new command using the matched rule, and runs it.")
1724 (license license:x11)))
61402398
JF
1725
1726(define-public di
1727 (package
1728 (name "di")
1729 (version "4.42")
1730 (source
1731 (origin
1732 (method url-fetch)
1733 (uri (string-append "https://gentoo.com/di/di-" version ".tar.gz"))
1734 (sha256
1735 (base32 "1i6m9zdnidn8268q1lz9fd8payk7s4pgwh5zlam9rr4dy6h6a67n"))))
1736 (build-system gnu-build-system)
1737 (arguments
1738 `(#:tests? #f ; Obscure test failures.
1739 #:phases
1740 (modify-phases %standard-phases
1741 (delete 'configure)
1742 (add-before 'build 'setup-environment
1743 (lambda* (#:key outputs #:allow-other-keys)
1744 (setenv "CC" "gcc")
1745 (setenv "prefix" (assoc-ref outputs "out"))
1746 #t)))
1747 #:make-flags (list "--environment-overrides")))
1748 (home-page "https://www.gentoo.com/di/")
1749 (synopsis "Advanced df like disk information utility")
1750 (description
1751 "'di' is a disk information utility, displaying everything
1752(and more) that your @code{df} command does. It features the ability to
1753display your disk usage in whatever format you prefer. It is designed to be
1754highly portable. Great for heterogenous networks.")
1755 (license license:zlib)))
5ec8b02d 1756
1757(define-public cbatticon
1758 (package
1759 (name "cbatticon")
1760 (version "1.6.4")
1761 (source (origin
1762 (method url-fetch)
1763 (uri (string-append "https://github.com/valr/"
1764 name "/archive/" version ".tar.gz"))
1765 (sha256
1766 (base32
1767 "023fvsa4q7rl98rqgwrb1shyzaybdkkbyz5sywd0s5p7ixkksxqx"))
1768 (file-name (string-append name "-" version ".tar.gz"))))
1769 (build-system gnu-build-system)
1770 (arguments
1771 `(#:tests? #f ; no tests
1772 #:make-flags
1773 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
1774 "CC=gcc")
1775 #:phases
1776 (modify-phases %standard-phases
1777 (delete 'configure)))) ; no configure script
1778 (inputs
1779 `(("gtk+" ,gtk+)
b94a6ca0 1780 ("gettext" ,gettext-minimal)
5ec8b02d 1781 ("libnotify" ,libnotify)))
1782 (native-inputs
1783 `(("pkg-config" ,pkg-config)))
1784 (synopsis "Lightweight battery icon for the system tray")
1785 (description "cbatticon is a lightweight battery icon that displays
1786the status of your battery in the system tray.")
1787 (home-page "https://github.com/valr/cbatticon")
1788 (license license:gpl2+)))
c08533b2 1789
1790(define-public interrobang
1791 (let ((revision "1")
1792 (commit "896543735e1c99144765fdbd7b6e6b5afbd8b881"))
1793 (package
1794 (name "interrobang")
1795 (version (string-append "0.0.0-" revision "." (string-take commit 7)))
1796 (source (origin
1797 (method git-fetch)
1798 (uri (git-reference
1799 (url "git://github.com/TrilbyWhite/interrobang")
1800 (commit commit)))
1801 (file-name (string-append name "-" version))
1802 (sha256
1803 (base32
1804 "1n13m70p1hfba5dy3i8hfclbr6k9q3d9dai3dg4jvhdhmxcpjzdf"))))
1805 (build-system gnu-build-system)
1806 (arguments
1807 `(#:tests? #f ; no tests
1808 #:phases
1809 (modify-phases %standard-phases
1810 (delete 'configure)) ; no configure script
1811 #:make-flags (list (string-append "PREFIX="
1812 (assoc-ref %outputs "out")))))
1813 (inputs
1814 `(("libx11" ,libx11)))
1815 (native-inputs
1816 `(("pkg-config" ,pkg-config)))
1817 (synopsis "Scriptable launcher menu")
1818 (description "Interrobang is a scriptable launcher menu with a customizable
1819shortcut syntax and completion options.")
1820 (home-page "https://github.com/TrilbyWhite/interrobang")
1821 (license license:gpl3+))))
94c5dc8c
JD
1822
1823
1824
1825(define-public pam-krb5
1826 (package
1827 (name "pam-krb5")
1828 (version "4.7")
1829 (source (origin
1830 (method url-fetch)
1831 (uri (string-append
1832 "https://archives.eyrie.org/software/kerberos/" name "-"
1833 version ".tar.xz"))
1834 (sha256
1835 (base32
1836 "0abf8cfpkprmhw5ca8iyqgrggh65lgqvmfllc1y6qz7zw1gas894"))))
1837 (build-system gnu-build-system)
1838 (arguments
1839 `(#:phases
1840 (modify-phases %standard-phases
1841 (add-before 'configure 'disable-tests
1842 (lambda _
1843 ;; The build container seems to interfere with some tests.
1844 (substitute* "tests/TESTS"
1845 (("module/basic\n") ""))
1846 (substitute* "tests/TESTS"
1847 (("pam-util/vector\n") ""))
1848 #t)))))
1849 (inputs
1850 `(("linux-pam" ,linux-pam)
1851 ("mit-krb5" ,mit-krb5)))
1852 (native-inputs
1853 `(("perl" ,perl)
1854 ("perl-test-pod" ,perl-test-pod))) ; required for tests
1855 (synopsis "Kerberos PAM module")
1856 (description
1857 "Pam-krb5 is a Kerberos PAM module for either MIT Kerberos or Heimdal.
1858It supports ticket refreshing by screen savers, configurable
1859authorization handling, authentication of non-local accounts for network
1860services, password changing, and password expiration, as well as all the
1861standard expected PAM features. It works correctly with OpenSSH, even
1862with ChallengeResponseAuthentication and PrivilegeSeparation enabled,
1863and supports extensive configuration either by PAM options or in
1864krb5.conf or both. PKINIT is supported with recent versions of both MIT
1865Kerberos and Heimdal and FAST is supported with recent MIT Kerberos.")
1866 (home-page "http://www.eyrie.org/~eagle/software/pam-krb5")
1867 ;; Dual licenced under a homebrew non-copyleft OR GPL (any version)
1868 ;; However, the tarball does not contain a copy of the GPL, so unless
1869 ;; we put one in, we cannot distribute it under GPL without violating
1870 ;; clause requiring us to give all recipients a copy.
1871 (license license:gpl1+)))
1872
1873;;http://archives.eyrie.org/software/kerberos/pam-krb5-4.7.tar.xz
b04ca7a1
DM
1874
1875(define-public sunxi-tools
1876 (package
1877 (name "sunxi-tools")
0c6fc4b7 1878 (version "1.4.2")
b04ca7a1
DM
1879 (source
1880 (origin
1881 (method url-fetch)
1882 (uri (string-append "https://github.com/linux-sunxi/"
1883 "sunxi-tools/archive/v" version ".tar.gz"))
1884 (sha256
0c6fc4b7 1885 (base32 "08iqwj95qw2s7ilhrdi2lkbc8dx64zk5lzz1qk587jr0lla81x41"))
b04ca7a1
DM
1886 (modules '((guix build utils)))
1887 (snippet
1888 ;; Remove binaries contained in the tarball which are only for the
1889 ;; target and can be regenerated anyway.
1890 '(delete-file-recursively "bin"))
1891 (file-name (string-append name "-" version ".tar.gz"))))
1892 (native-inputs
1893 `(("pkg-config" ,pkg-config)))
1894 (inputs
1895 `(("libusb" ,libusb)))
1896 (build-system gnu-build-system)
1897 (arguments
1898 `(#:tests? #f ; no tests exist
1899 #:make-flags (list (string-append "PREFIX="
1900 (assoc-ref %outputs "out"))
b054b26a
DM
1901 "CROSS_COMPILE="
1902 "CC=gcc"
1903 "all")
b04ca7a1
DM
1904 #:phases
1905 (modify-phases %standard-phases
b054b26a
DM
1906 (delete 'configure)
1907 (replace 'install
1908 (lambda* (#:key make-flags #:allow-other-keys)
1909 (zero? (apply system* "make" "install-all" "install-misc"
1910 make-flags)))))))
b04ca7a1
DM
1911 (home-page "https://github.com/linux-sunxi/sunxi-tools")
1912 (synopsis "Hardware management tools for Allwinner computers")
1913 (description "This package contains tools for Allwinner devices:
1914@enumerate
1915@item @command{sunxi-fexc}, @command{bin2fex}, @command{fex2bin}: Compile
1916a textual description of a board (.fex) to a binary representation (.bin).
1917@item @command{sunxi-fel}: Puts an Allwinner device into FEL mode which
1918makes it register as a special USB device (rather than USB host).
1919You can then connect it to another computer and flash it from there.
1920@item @command{sunxi-nand-part}: Partitions NAND flash.
1921@item @command{sunxi-bootinfo}: Reads out boot0 and boot1 (Allwinner
1922bootloader) parameters.
1923@item @command{sunxi-pio}: Sets GPIO parameters and oscillates a GPIO
1924in order to be able to find it.
1925@item @command{sunxi-meminfo}: Prints memory bus settings.
b054b26a 1926@item @command{sunxi-nand-image-builder}: Prepares raw NAND images.
b04ca7a1
DM
1927@end enumerate")
1928 (license license:gpl2+)))