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