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