Commit | Line | Data |
---|---|---|
e04f30e0 | 1 | ;;; GNU Guix --- Functional package management for GNU |
cc4a2aeb | 2 | ;;; Copyright © 2012, 2013 Nikita Karetnikov <nikita@karetnikov.org> |
1b933e62 | 3 | ;;; Copyright © 2015 Mathieu Lirzin <mthl@gnu.org> |
dd4a8620 | 4 | ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org> |
2d4c1c0b | 5 | ;;; Copyright © 2016, 2018–2021 Tobias Geerinckx-Rice <me@tobias.gr> |
39d93ce2 | 6 | ;;; Copyright © 2016, 2019, 2020 Efraim Flashner <efraim@flashner.co.il> |
abba1d08 | 7 | ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org> |
c20e552b | 8 | ;;; Copyright © 2016 Roel Janssen <roel@gnu.org> |
5f0f3686 | 9 | ;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com> |
49393691 | 10 | ;;; Copyright © 2017 Hartmut Goebel <h.goebel@crazy-compilers.com> |
893f9d24 | 11 | ;;; Copyright © 2017 Stefan Reichör <stefan@xsteve.at> |
d232e02e | 12 | ;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com> |
834b0b9a | 13 | ;;; Copyright © 2018 Eric Bavier <bavier@member.fsf.org> |
19b662ea | 14 | ;;; Copyright © 2018 Rutger Helling <rhelling@mykolab.com> |
eb44d3b8 | 15 | ;;; Copyright © 2018, 2019, 2020 Pierre Neidhardt <mail@ambrevar.xyz> |
ff22ff42 | 16 | ;;; Copyright © 2019 Leo Famulari <leo@famulari.name> |
a55dd25d | 17 | ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com> |
d441a645 | 18 | ;;; Copyright © 2020 Pkill -9 <pkill9@runbox.com> |
19b10c91 | 19 | ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com> |
83fda6dd | 20 | ;;; Copyright © 2020 Raghav Gururajan <raghavgururajan@disroot.org> |
8f90c74d | 21 | ;;; Copyright © 2021 Michael Rohleder <mike@rohleder.de> |
e04f30e0 NK |
22 | ;;; |
23 | ;;; This file is part of GNU Guix. | |
24 | ;;; | |
25 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
26 | ;;; under the terms of the GNU General Public License as published by | |
27 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
28 | ;;; your option) any later version. | |
29 | ;;; | |
30 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
31 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
32 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
33 | ;;; GNU General Public License for more details. | |
34 | ;;; | |
35 | ;;; You should have received a copy of the GNU General Public License | |
36 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
37 | ||
cc4a2aeb | 38 | (define-module (gnu packages disk) |
abba1d08 | 39 | #:use-module (gnu packages) |
3820d51b | 40 | #:use-module (gnu packages autotools) |
c20e552b | 41 | #:use-module (gnu packages base) |
3820d51b TGR |
42 | #:use-module (gnu packages bash) |
43 | #:use-module (gnu packages c) | |
834b0b9a | 44 | #:use-module (gnu packages check) |
3820d51b | 45 | #:use-module (gnu packages compression) |
f95114e5 | 46 | #:use-module (gnu packages crypto) |
3820d51b | 47 | #:use-module (gnu packages cryptsetup) |
c20e552b | 48 | #:use-module (gnu packages docbook) |
3820d51b | 49 | #:use-module (gnu packages documentation) |
3b451546 | 50 | #:use-module (gnu packages elf) |
159e9dce | 51 | #:use-module (gnu packages file-systems) |
9b1f80a4 | 52 | #:use-module (gnu packages file) |
83fda6dd | 53 | #:use-module (gnu packages fontutils) |
1dba6407 | 54 | #:use-module (gnu packages gettext) |
c20e552b | 55 | #:use-module (gnu packages glib) |
c20e552b | 56 | #:use-module (gnu packages gnome) |
3820d51b | 57 | #:use-module (gnu packages gnupg) |
83fda6dd | 58 | #:use-module (gnu packages graphics) |
3820d51b TGR |
59 | #:use-module (gnu packages gtk) |
60 | #:use-module (gnu packages guile) | |
e04f30e0 | 61 | #:use-module (gnu packages linux) |
abba1d08 | 62 | #:use-module (gnu packages ncurses) |
aff0cce9 | 63 | #:use-module (gnu packages nss) |
1b933e62 | 64 | #:use-module (gnu packages perl) |
c20e552b | 65 | #:use-module (gnu packages pkg-config) |
abba1d08 | 66 | #:use-module (gnu packages popt) |
1b933e62 | 67 | #:use-module (gnu packages python) |
44d10b1f | 68 | #:use-module (gnu packages python-xyz) |
cc4a2aeb | 69 | #:use-module (gnu packages readline) |
159e9dce | 70 | #:use-module (gnu packages samba) |
9d0c291e | 71 | #:use-module (gnu packages sphinx) |
cd0322a3 | 72 | #:use-module (gnu packages sqlite) |
3820d51b | 73 | #:use-module (gnu packages swig) |
d441a645 P |
74 | #:use-module (gnu packages terminals) |
75 | #:use-module (gnu packages textutils) | |
5f0f3686 | 76 | #:use-module (gnu packages vim) |
19b662ea | 77 | #:use-module (gnu packages w3m) |
f7a4f7c0 | 78 | #:use-module (gnu packages web) |
3820d51b | 79 | #:use-module (gnu packages xml) |
83fda6dd | 80 | #:use-module (gnu packages xorg) |
3820d51b | 81 | #:use-module (guix build-system gnu) |
b514478c | 82 | #:use-module (guix build-system glib-or-gtk) |
d441a645 | 83 | #:use-module (guix build-system go) |
3820d51b TGR |
84 | #:use-module (guix build-system python) |
85 | #:use-module (guix build-system trivial) | |
3b451546 | 86 | #:use-module (guix build-system scons) |
3820d51b TGR |
87 | #:use-module (guix download) |
88 | #:use-module (guix git-download) | |
89 | #:use-module ((guix licenses) #:prefix license:) | |
4ace204d TGR |
90 | #:use-module (guix packages) |
91 | #:use-module (guix utils)) | |
e04f30e0 | 92 | |
98535733 TGR |
93 | (define-public bcache-tools |
94 | ;; The 1.1 release is a year old and missing new features & documentation. | |
95 | (let ((commit "096d205a9f1be8540cbc5a468c0da8203023de70") | |
96 | (revision "0")) | |
97 | (package | |
98 | (name "bcache-tools") | |
99 | (version (git-version "1.1" revision commit)) | |
100 | (source | |
101 | (origin | |
102 | (method git-fetch) | |
103 | (uri (git-reference | |
104 | (url (string-append "https://git.kernel.org/pub/scm/" | |
105 | "linux/kernel/git/colyli/bcache-tools.git")) | |
106 | (commit commit))) | |
107 | (file-name (git-file-name name version)) | |
108 | (sha256 | |
109 | (base32 "0r0vwg4vacz5zgsafk360xn7gi2scy01c79mkmjrdyxjfij5z3iy")))) | |
110 | (build-system gnu-build-system) | |
111 | (arguments | |
112 | `(#:tests? #f ; no test suite | |
113 | #:make-flags | |
114 | (list (string-append "PREFIX=" (assoc-ref %outputs "out")) | |
115 | (string-append "UDEVLIBDIR=" (assoc-ref %outputs "out") | |
116 | "/lib/udev") | |
117 | (string-append "DRACUTLIBDIR=" (assoc-ref %outputs "out") | |
118 | "/lib/dracut") | |
119 | (string-append "CC=" ,(cc-for-target))) | |
120 | #:phases | |
121 | (modify-phases %standard-phases | |
122 | (delete 'configure) ; no configure script | |
123 | (add-before 'install 'fix-hard-coded-file-names | |
124 | (lambda _ | |
125 | ;; Some rules still hard-code /usr. | |
126 | (substitute* "Makefile" | |
127 | (("/usr") "${PREFIX}")) | |
128 | #t)) | |
129 | (add-before 'install 'create-target-directories | |
130 | (lambda* (#:key outputs #:allow-other-keys) | |
131 | (let* ((out (assoc-ref outputs "out"))) | |
132 | (for-each (lambda (dir) | |
133 | (mkdir-p (string-append out dir))) | |
134 | (list "/lib/udev/rules.d" | |
135 | "/sbin" | |
136 | "/share/man/man8")) | |
137 | #t)))))) | |
138 | (native-inputs | |
139 | `(("pkg-config" ,pkg-config))) | |
140 | (inputs | |
141 | `(("util-linux:lib" ,util-linux "lib"))) ; libblkid | |
142 | (home-page "https://bcache.evilpiepirate.org") | |
143 | (synopsis "Tools for the Linux kernel block layer cache") | |
144 | (description | |
145 | "This package contains user-space utilities to create and inspect bcache | |
146 | partitions. It's rather minimal as bcache is designed to work well without | |
147 | configuration on any system. | |
148 | ||
149 | Linux's @acronym{bcache, block layer cache} lets one or more fast block devices, | |
150 | such as flash-based @acronym{SSDs, solid state drives}, to act as a cache for | |
151 | one or more slower (and inexpensive) devices, such as hard disk drives or | |
152 | redundant storage arrays. In fact, bcache intends to be a superior alternative | |
153 | to battery-backed RAID controllers. | |
154 | ||
155 | Bcache is designed around the performance characteristics of SSDs and tries to | |
156 | minimize write inflation. It's file-system agnostic and does both write-through | |
157 | and write-back caching.") | |
158 | (license license:gpl2)))) | |
159 | ||
159e9dce RG |
160 | (define-public udevil |
161 | (package | |
162 | (name "udevil") | |
163 | (version "0.4.4") | |
164 | (source | |
165 | (origin | |
166 | (method git-fetch) | |
167 | (uri | |
168 | (git-reference | |
b0e7b699 | 169 | (url "https://github.com/IgnorantGuru/udevil") |
159e9dce RG |
170 | (commit version))) |
171 | (file-name (git-file-name name version)) | |
172 | (sha256 | |
173 | (base32 "0x9mjr9abvbxzfa9mrip5264iz1qxvsl01k3ybz95q4a7xl4jcb3")))) | |
174 | (build-system gnu-build-system) | |
175 | (arguments | |
176 | `(#:configure-flags | |
8546f4da RG |
177 | (list |
178 | "--disable-systemd" | |
179 | (string-append "--sysconfdir=" | |
180 | (assoc-ref %outputs "out") | |
181 | "/etc") | |
182 | ;; udevil expects these programs to be run with uid set as root. | |
183 | ;; user has to manually add these programs to setuid-programs. | |
184 | ;; mount and umount are default setuid-programs in guix system. | |
185 | "--with-mount-prog=/run/setuid-programs/mount" | |
186 | "--with-umount-prog=/run/setuid-programs/umount" | |
187 | "--with-losetup-prog=/run/setuid-programs/losetup" | |
188 | "--with-setfacl-prog=/run/setuid-programs/setfacl") | |
159e9dce RG |
189 | #:phases |
190 | (modify-phases %standard-phases | |
191 | (add-after 'unpack 'remove-root-reference | |
192 | (lambda _ | |
193 | (substitute* "src/Makefile.in" | |
194 | (("-o root -g root") "")) | |
8546f4da RG |
195 | #t)) |
196 | (add-after 'unpack 'patch-udevil-reference | |
197 | ;; udevil expects itself to be run with uid set as root. | |
198 | ;; devmon also expects udevil to be run with uid set as root. | |
199 | ;; user has to manually add udevil to setuid-programs. | |
200 | (lambda _ | |
201 | (substitute* "src/udevil.c" | |
202 | (("/usr/bin/udevil") "/run/setuid-programs/udevil")) | |
203 | (substitute* "src/devmon" | |
204 | (("`which udevil 2>/dev/null`") "/run/setuid-programs/udevil")) | |
159e9dce RG |
205 | #t))))) |
206 | (native-inputs | |
207 | `(("intltool" ,intltool) | |
208 | ("pkg-config" ,pkg-config))) | |
209 | (inputs | |
210 | `(("cifs-utils" ,cifs-utils) | |
211 | ("curlftpfs" ,curlftpfs) | |
212 | ("eudev" ,eudev) | |
213 | ("fakeroot" ,fakeroot) | |
214 | ("glib" ,glib) | |
215 | ("sshfs" ,sshfs))) | |
216 | (synopsis "Device and file system manager") | |
217 | (description "udevil is a command line program that mounts and unmounts | |
218 | removable devices without a password, shows device info, and monitors device | |
219 | changes. It can also mount ISO files, NFS, SMB, FTP, SSH and WebDAV URLs, and | |
220 | tmpfs/ramfs filesystems.") | |
221 | (home-page "https://ignorantguru.github.io/udevil/") | |
222 | (license license:gpl3+))) | |
223 | ||
e04f30e0 NK |
224 | (define-public parted |
225 | (package | |
226 | (name "parted") | |
6ad7e357 | 227 | (version "3.3") |
1b933e62 ML |
228 | (source (origin |
229 | (method url-fetch) | |
230 | (uri (string-append "mirror://gnu/parted/parted-" | |
231 | version ".tar.xz")) | |
232 | (sha256 | |
233 | (base32 | |
6ad7e357 | 234 | "0i1xp367wpqw75b20c3jnism3dg3yqj4a7a22p2jb1h1hyyv9qjp")))) |
e04f30e0 | 235 | (build-system gnu-build-system) |
1b933e62 ML |
236 | (arguments |
237 | `(#:phases | |
238 | (modify-phases %standard-phases | |
bd321df3 MB |
239 | (add-after 'unpack 'fix-locales-and-python |
240 | (lambda* (#:key inputs #:allow-other-keys) | |
241 | (substitute* "tests/t0251-gpt-unicode.sh" | |
242 | (("C.UTF-8") "en_US.utf8")) ;not in Glibc locales | |
243 | (substitute* "tests/msdos-overlap" | |
244 | (("/usr/bin/python") (which "python"))) | |
245 | #t))))) | |
e04f30e0 | 246 | (inputs |
1b933e62 ML |
247 | `(("lvm2" ,lvm2) |
248 | ("readline" ,readline) | |
bb93042c | 249 | ("util-linux" ,util-linux "lib"))) |
c4c4cc05 | 250 | (native-inputs |
b94a6ca0 | 251 | `(("gettext" ,gettext-minimal) |
bb93042c | 252 | |
1b933e62 | 253 | ;; For the tests. |
20e01573 | 254 | ("e2fsprogs" ,e2fsprogs) |
1b933e62 | 255 | ("perl" ,perl) |
bb93042c MB |
256 | ("python" ,python-2) |
257 | ("util-linux" ,util-linux))) | |
1b933e62 | 258 | (home-page "https://www.gnu.org/software/parted/") |
f50d2669 | 259 | (synopsis "Disk partition editor") |
e04f30e0 | 260 | (description |
79c311b8 LC |
261 | "GNU Parted is a package for creating and manipulating disk partition |
262 | tables. It includes a library and command-line utility.") | |
fd297f4a | 263 | (license license:gpl3+))) |
cc4a2aeb LC |
264 | |
265 | (define-public fdisk | |
266 | (package | |
267 | (name "fdisk") | |
ae03ee42 | 268 | (version "2.0.0a1") |
cc4a2aeb LC |
269 | (source |
270 | (origin | |
271 | (method url-fetch) | |
272 | (uri (string-append "mirror://gnu/fdisk/gnufdisk-" | |
273 | version ".tar.gz")) | |
274 | (sha256 | |
275 | (base32 | |
ae03ee42 | 276 | "1d8za79kw8ihnp2br084rgyjv9whkwp7957rzw815i0izx6xhqy9")))) |
cc4a2aeb LC |
277 | (build-system gnu-build-system) |
278 | (inputs | |
b94a6ca0 | 279 | `(("gettext" ,gettext-minimal) |
cc4a2aeb | 280 | ("guile" ,guile-1.8) |
bb93042c | 281 | ("util-linux" ,util-linux "lib") |
cc4a2aeb | 282 | ("parted" ,parted))) |
ae03ee42 TGR |
283 | ;; The build neglects to look for its own headers in its own tree. A next |
284 | ;; release should fix this, but may never come: GNU fdisk looks abandoned. | |
285 | (arguments | |
286 | `(#:phases | |
287 | (modify-phases %standard-phases | |
288 | (add-after 'unpack 'skip-broken-header-probes | |
289 | (lambda _ | |
290 | (substitute* "backend/configure" | |
291 | (("gnufdisk-common.h .*") "\n")) | |
292 | #t))) | |
293 | #:make-flags (list (string-append "CPPFLAGS=" | |
294 | " -I../common/include " | |
295 | " -I../debug/include " | |
296 | " -I../exception/include")))) | |
cc4a2aeb LC |
297 | (home-page "https://www.gnu.org/software/fdisk/") |
298 | (synopsis "Low-level disk partitioning and formatting") | |
299 | (description | |
300 | "GNU fdisk provides a GNU version of the common disk partitioning tool | |
301 | fdisk. fdisk is used for the creation and manipulation of disk partition | |
302 | tables, and it understands a variety of different formats.") | |
fd297f4a | 303 | (license license:gpl3+))) |
cc4a2aeb | 304 | |
abba1d08 JN |
305 | (define-public gptfdisk |
306 | (package | |
307 | (name "gptfdisk") | |
381bc724 | 308 | (version "1.0.6") |
abba1d08 JN |
309 | (source |
310 | (origin | |
311 | (method url-fetch) | |
312 | (uri (string-append "mirror://sourceforge/gptfdisk/gptfdisk/" | |
848be51c | 313 | version "/gptfdisk-" version ".tar.gz")) |
abba1d08 | 314 | (sha256 |
381bc724 | 315 | (base32 "1a4c2ss6n2s6x8v11h79jykh96y46apd6i838ka0ngx58gb53ifx")))) |
abba1d08 JN |
316 | (build-system gnu-build-system) |
317 | (inputs | |
b94a6ca0 | 318 | `(("gettext" ,gettext-minimal) |
abba1d08 JN |
319 | ("ncurses" ,ncurses) |
320 | ("popt" ,popt) | |
bb93042c | 321 | ("util-linux" ,util-linux "lib"))) ;libuuid |
abba1d08 JN |
322 | (arguments |
323 | `(#:test-target "test" | |
324 | #:phases | |
325 | (modify-phases %standard-phases | |
848be51c TGR |
326 | (add-after 'unpack 'fix-include-directory |
327 | (lambda _ | |
328 | (substitute* "gptcurses.cc" | |
329 | (("ncursesw/ncurses.h") "ncurses.h")) | |
330 | #t)) | |
331 | (delete 'configure) ; no configure script | |
abba1d08 | 332 | (replace 'install |
848be51c | 333 | ;; There's no ‘make install’ target. |
abba1d08 | 334 | (lambda* (#:key outputs #:allow-other-keys) |
6fb9e069 LF |
335 | (let* ((out (assoc-ref outputs "out")) |
336 | (bin (string-append out "/bin")) | |
337 | (man (string-append out "/share/man/man8"))) | |
abba1d08 JN |
338 | (install-file "gdisk" bin) |
339 | (install-file "sgdisk" bin) | |
340 | (install-file "cgdisk" bin) | |
6fb9e069 LF |
341 | (install-file "fixparts" bin) |
342 | (install-file "cgdisk.8" man) | |
343 | (install-file "fixparts.8" man) | |
344 | (install-file "gdisk.8" man) | |
345 | (install-file "sgdisk.8" man))))))) | |
094afc97 | 346 | (home-page "https://www.rodsbooks.com/gdisk/") |
abba1d08 JN |
347 | (synopsis "Low-level GPT disk partitioning and formatting") |
348 | (description "GPT fdisk (aka gdisk) is a text-mode partitioning tool that | |
73fe4552 TGR |
349 | works on Globally Unique Identifier (@dfn{GUID}) Partition Table (@dfn{GPT}) |
350 | disks, rather than on the older Master Boot Record (@dfn{MBR}) partition | |
351 | scheme.") | |
fd297f4a | 352 | (license license:gpl2))) |
abba1d08 | 353 | |
cc4a2aeb LC |
354 | (define-public ddrescue |
355 | (package | |
356 | (name "ddrescue") | |
39d93ce2 | 357 | (version "1.25") |
cc4a2aeb LC |
358 | (source |
359 | (origin | |
360 | (method url-fetch) | |
361 | (uri (string-append "mirror://gnu/ddrescue/ddrescue-" | |
362 | version ".tar.lz")) | |
363 | (sha256 | |
39d93ce2 | 364 | (base32 "0qqh38izl5ppap9a5izf3hijh94k65s3zbfkczd4b7x04syqwlyf")))) |
cc4a2aeb | 365 | (build-system gnu-build-system) |
416c57f0 | 366 | (home-page "https://www.gnu.org/software/ddrescue/ddrescue.html") |
cc4a2aeb LC |
367 | (synopsis "Data recovery utility") |
368 | (native-inputs `(("lzip" ,lzip))) | |
369 | (description | |
370 | "GNU ddrescue is a fully automated data recovery tool. It copies data | |
371 | from one file to another, working to rescue data in case of read errors. The | |
372 | program also includes a tool for manipulating its log files, which are used | |
373 | to recover data more efficiently by only reading the necessary blocks.") | |
fd297f4a | 374 | (license license:gpl3+))) |
dd4a8620 MW |
375 | |
376 | (define-public dosfstools | |
377 | (package | |
378 | (name "dosfstools") | |
5f0f3686 | 379 | (version "4.1") |
dd4a8620 MW |
380 | (source |
381 | (origin | |
382 | (method url-fetch) | |
383 | (uri (string-append "https://github.com/" name "/" name | |
384 | "/releases/download/v" version "/" | |
385 | name "-" version ".tar.xz")) | |
386 | (sha256 | |
387 | (base32 | |
5f0f3686 | 388 | "0wy13i3i4x2bw1hf5m4fd0myh61f9bcrs035fdlf6gyc1jksrcp6")))) |
dd4a8620 MW |
389 | (build-system gnu-build-system) |
390 | (arguments | |
a55dd25d PL |
391 | `(#:configure-flags (list "--enable-compat-symlinks") |
392 | #:make-flags (list (string-append "PREFIX=" %output) | |
5f0f3686 MB |
393 | "CC=gcc"))) |
394 | (native-inputs | |
9fc513ad | 395 | `(("xxd" ,xxd))) ; for tests |
dd4a8620 | 396 | (home-page "https://github.com/dosfstools/dosfstools") |
8f65585b | 397 | (synopsis "Utilities for making and checking MS-DOS FAT file systems") |
dd4a8620 MW |
398 | (description |
399 | "The dosfstools package includes the mkfs.fat and fsck.fat utilities, | |
8f65585b | 400 | which respectively make and check MS-DOS FAT file systems.") |
fd297f4a | 401 | (license license:gpl3+))) |
0f860464 | 402 | |
51ad11ad MB |
403 | (define dosfstools/static |
404 | (static-package | |
405 | (package (inherit dosfstools)))) | |
406 | ||
407 | (define-public fatfsck/static | |
408 | (package | |
409 | (name "fatfsck-static") | |
410 | (version (package-version dosfstools)) | |
411 | (build-system trivial-build-system) | |
412 | (source #f) | |
413 | (arguments | |
414 | `(#:modules ((guix build utils)) | |
415 | #:builder | |
416 | (begin | |
417 | (use-modules (guix build utils)) | |
418 | (let ((src (string-append (assoc-ref %build-inputs "dosfstools") | |
419 | "/sbin")) | |
420 | (exe "fsck.fat") | |
421 | (bin (string-append (assoc-ref %outputs "out") "/sbin"))) | |
422 | (mkdir-p bin) | |
423 | (with-directory-excursion bin | |
424 | (copy-file (string-append src "/" exe) exe) | |
425 | (remove-store-references exe) | |
426 | (chmod exe #o555) | |
427 | ;; Add fsck.vfat symlink to match the Linux driver name. | |
428 | (symlink exe "fsck.vfat") | |
429 | #t))))) | |
430 | (inputs `(("dosfstools" ,dosfstools/static))) | |
431 | (home-page (package-home-page dosfstools)) | |
432 | (synopsis "Statically linked fsck.fat from dosfstools") | |
433 | (description "This package provides a statically-linked @command{fsck.fat} | |
434 | and a @command{fsck.vfat} compatibility symlink for use in an initrd.") | |
435 | (license (package-license dosfstools)))) | |
436 | ||
0f860464 TGR |
437 | (define-public sdparm |
438 | (package | |
439 | (name "sdparm") | |
b7afc63f | 440 | (version "1.11") |
0f860464 TGR |
441 | (source |
442 | (origin | |
443 | (method url-fetch) | |
444 | (uri (string-append "http://sg.danny.cz/sg/p/" | |
b7afc63f | 445 | "sdparm-" version ".tar.xz")) |
0f860464 | 446 | (sha256 |
b7afc63f | 447 | (base32 "1nqjc4w2w47zavcbf5xmm53x1zbwgljaw1lpajcdi537cgy32fa8")))) |
0f860464 TGR |
448 | (build-system gnu-build-system) |
449 | (home-page "http://sg.danny.cz/sg/sdparm.html") | |
450 | (synopsis "Provide access to SCSI device parameters") | |
451 | (description | |
452 | "Sdparm reads and modifies SCSI device parameters. These devices can be | |
453 | SCSI disks, in which case the role of @command{sdparm} is similar to its | |
454 | namesake: the @command{hdparm} utility originally designed for ATA disks. | |
455 | However, @command{sdparm} can be used to access parameters on any device that | |
456 | uses a SCSI command set. Such devices include CD/DVD drives (irrespective of | |
457 | transport), SCSI and ATAPI tape drives, and SCSI enclosures. This utility can | |
458 | also send commands associated with starting and stopping the media, loading | |
459 | and unloading removable media and some other housekeeping functions.") | |
fd297f4a | 460 | (license license:bsd-3))) |
8e14e059 TGR |
461 | |
462 | (define-public idle3-tools | |
463 | (package | |
464 | (name "idle3-tools") | |
465 | (version "0.9.1") | |
466 | (source | |
467 | (origin | |
468 | (method url-fetch) | |
469 | (uri (string-append "mirror://sourceforge/idle3-tools/idle3-tools-" | |
470 | version ".tgz")) | |
471 | (sha256 | |
472 | (base32 | |
473 | "00ia7xq9yldxyl9gz0mr4xa568nav14p0fnv82f2rbbkg060cy4p")))) | |
474 | (build-system gnu-build-system) | |
475 | (arguments | |
476 | `(#:tests? #f ;no test suite | |
477 | #:phases | |
478 | (modify-phases %standard-phases | |
479 | (delete 'configure)) | |
480 | #:make-flags (list "CC=gcc" | |
481 | (string-append "manprefix=") | |
482 | (string-append "DESTDIR=" | |
483 | (assoc-ref %outputs "out"))))) | |
484 | (home-page "http://idle3-tools.sourceforge.net") | |
485 | (synopsis "Change or disable Western Digital hard drives' Idle3 timer") | |
486 | (description | |
487 | "Idle3-tools provides a utility to get, set, or disable the Idle3 timer | |
488 | present in many Western Digital hard drives. This timer is part of the | |
489 | \"IntelliPark\" feature that stops the disk when not in use. Unfortunately, | |
490 | the default timer setting is not well suited to Linux or other *nix systems, | |
491 | and can dramatically shorten the lifespan of the drive if left unchecked.") | |
fd297f4a | 492 | (license license:gpl3+))) |
c20e552b RJ |
493 | |
494 | (define-public gparted | |
495 | (package | |
496 | (name "gparted") | |
8f90c74d | 497 | (version "1.2.0") |
c20e552b RJ |
498 | (source |
499 | (origin | |
500 | (method url-fetch) | |
501 | (uri (string-append "mirror://sourceforge/gparted/gparted/gparted-" | |
502 | version "/gparted-" version ".tar.gz")) | |
503 | (sha256 | |
8f90c74d | 504 | (base32 "06f72hqx5jf2irzsmi7lgpxxj38ncixh0acb4307wyjd4mfp343c")))) |
b514478c | 505 | (build-system glib-or-gtk-build-system) |
c20e552b | 506 | (arguments |
ff22ff42 LF |
507 | ;; Tests require access to paths outside the build container, such |
508 | ;; as '/dev/disk/by-id' | |
509 | `(#:tests? #f)) | |
c20e552b | 510 | (inputs |
bb93042c | 511 | `(("util-linux" ,util-linux "lib") |
c20e552b RJ |
512 | ("parted" ,parted) |
513 | ("glib" ,glib) | |
ff22ff42 | 514 | ("gtkmm" ,gtkmm) |
19b10c91 | 515 | ("libxml2" ,libxml2))) |
c20e552b RJ |
516 | (native-inputs |
517 | `(("intltool" ,intltool) | |
3e68e7d2 | 518 | ("itstool" ,itstool) |
ff22ff42 | 519 | ("lvm2" ,lvm2) ; for tests |
19b10c91 | 520 | ("yelp-tools" ,yelp-tools) |
c20e552b | 521 | ("pkg-config" ,pkg-config))) |
d5909be9 | 522 | (home-page "https://gparted.org/") |
c20e552b RJ |
523 | (synopsis "Partition editor to graphically manage disk partitions") |
524 | (description "GParted is a GNOME partition editor for creating, | |
525 | reorganizing, and deleting disk partitions. It uses libparted from the parted | |
526 | project to detect and manipulate partition tables. Optional file system tools | |
527 | permit managing file systems not included in libparted.") | |
528 | ;; The home page says GPLv2, but the source code says GPLv2+. | |
529 | (license license:gpl2+))) | |
49393691 | 530 | |
893f9d24 SR |
531 | (define-public pydf |
532 | (package | |
533 | (name "pydf") | |
534 | (version "12") | |
535 | (source | |
536 | (origin | |
537 | (method url-fetch) | |
538 | (uri (pypi-uri "pydf" version)) | |
539 | (sha256 | |
540 | (base32 | |
541 | "0f8ly8xyp93i2hm9c0qjqd4y86nz73axw2f09z01mszwmg1sfivz")))) | |
542 | (build-system python-build-system) | |
543 | (home-page "http://kassiopeia.juls.savba.sk/~garabik/software/pydf/") | |
544 | (synopsis "Colourised @command{df} clone") | |
545 | (description "All-singing, all-dancing, fully colourised @command{df} clone | |
546 | written in Python. It displays the amount of disk space available on the | |
162a1374 | 547 | mounted file systems, using different colours for different types of file |
893f9d24 SR |
548 | systems. Output format is completely customizable.") |
549 | (license license:public-domain))) | |
49393691 HG |
550 | |
551 | (define-public f3 | |
552 | (package | |
553 | (name "f3") | |
84acc3d2 | 554 | (version "8.0") |
49393691 HG |
555 | (source |
556 | (origin | |
b3307bfd TGR |
557 | (method git-fetch) |
558 | (uri (git-reference | |
b0e7b699 | 559 | (url "https://github.com/AltraMayor/f3") |
b3307bfd TGR |
560 | (commit (string-append "v" version)))) |
561 | (file-name (git-file-name name version)) | |
49393691 | 562 | (sha256 |
84acc3d2 | 563 | (base32 "17l5vspfcgfbkqg7bakp3gql29yb05gzawm8n3im30ilzdr53678")))) |
49393691 HG |
564 | (build-system gnu-build-system) |
565 | (arguments | |
47ddb109 TGR |
566 | `(#:tests? #f ; no check target |
567 | #:make-flags (list (string-append "CC=" ,(cc-for-target)) | |
49393691 HG |
568 | (string-append "PREFIX=" %output)) |
569 | #:phases | |
570 | (modify-phases %standard-phases | |
af514ead TGR |
571 | (delete 'configure) ; no configure script |
572 | (add-after 'build 'build-extra | |
573 | (lambda* (#:key make-flags #:allow-other-keys) | |
574 | (apply invoke "make" "extra" make-flags))) | |
575 | (add-after 'build 'install-extra | |
576 | (lambda* (#:key make-flags #:allow-other-keys) | |
577 | (apply invoke "make" "install-extra" make-flags)))))) | |
49393691 HG |
578 | (inputs |
579 | `(("eudev" ,eudev) | |
580 | ("parted" ,parted))) | |
581 | (home-page "http://oss.digirati.com.br/f3/") | |
582 | (synopsis "Test real capacity of flash memory cards and such.") | |
583 | (description "F3 (Fight Flash Fraud or Fight Fake Flash) tests the full | |
584 | capacity of a flash card (flash drive, flash disk, pendrive). F3 writes to | |
585 | the card and then checks if can read it. It will assure you haven't been sold | |
586 | a card with a smaller capacity than stated.") | |
587 | (license license:gpl3+))) | |
9b36e3bf DM |
588 | |
589 | (define-public python-parted | |
590 | (package | |
591 | (name "python-parted") | |
735093e5 | 592 | (version "3.11.7") |
9b36e3bf DM |
593 | (source |
594 | (origin | |
455d29dd TGR |
595 | (method git-fetch) |
596 | (uri (git-reference | |
b0e7b699 | 597 | (url "https://github.com/dcantrell/pyparted") |
455d29dd TGR |
598 | (commit (string-append "v" version)))) |
599 | (file-name (git-file-name name version)) | |
9b36e3bf | 600 | (sha256 |
735093e5 | 601 | (base32 "01193fmkss9icjvqpw85szpk8ld1pnha7p9kqm7mpwk6rc6gi2m3")))) |
9b36e3bf DM |
602 | (build-system python-build-system) |
603 | (arguments | |
604 | `(#:phases | |
605 | (modify-phases %standard-phases | |
606 | (delete 'check) | |
607 | (add-after 'install 'check | |
608 | (lambda* (#:key outputs inputs #:allow-other-keys) | |
609 | (add-installed-pythonpath inputs outputs) | |
610 | ;; See <https://github.com/dcantrell/pyparted/issues/47>. | |
611 | (substitute* "tests/test__ped_ped.py" | |
612 | (("\"/tmp/temp-device-\"") "self.path")) | |
613 | (invoke "python" "-m" "unittest" "discover" "-v") | |
614 | #t))))) | |
615 | (native-inputs | |
616 | `(("e2fsprogs" ,e2fsprogs) | |
617 | ("pkg-config" ,pkg-config))) | |
618 | (propagated-inputs | |
619 | `(("python-six" ,python-six))) | |
620 | (inputs | |
621 | `(("parted" ,parted))) | |
622 | (home-page "https://github.com/dcantrell/pyparted") | |
623 | (synopsis "Parted bindings for Python") | |
624 | (description "This package provides @code{parted} bindings for Python.") | |
625 | (license license:gpl2+))) | |
626 | ||
d232e02e VD |
627 | (define-public duperemove |
628 | (package | |
629 | (name "duperemove") | |
d0f41f91 | 630 | (version "0.11.2") |
acc6eb89 TGR |
631 | (source |
632 | (origin | |
633 | (method git-fetch) | |
634 | (uri (git-reference | |
b0e7b699 | 635 | (url "https://github.com/markfasheh/duperemove") |
acc6eb89 TGR |
636 | (commit (string-append "v" version)))) |
637 | (sha256 | |
d0f41f91 | 638 | (base32 "1a87mka2sfzhbch2jip6wlvvs0glxq9lqwmyrp359d1rmwwmqiw9")) |
acc6eb89 | 639 | (file-name (git-file-name name version)))) |
d232e02e VD |
640 | (build-system gnu-build-system) |
641 | (native-inputs | |
642 | `(("pkg-config" ,pkg-config))) | |
643 | (inputs | |
644 | `(("glib" ,glib) | |
645 | ("sqlite" ,sqlite))) | |
646 | (arguments | |
51c4fb00 | 647 | `(#:tests? #f ; no test suite |
d232e02e VD |
648 | #:phases |
649 | (modify-phases %standard-phases | |
51c4fb00 | 650 | (delete 'configure)) ; no configure script |
d232e02e | 651 | #:make-flags (list (string-append "PREFIX=" %output) |
8791ef7c TGR |
652 | (string-append "CC=" ,(cc-for-target)) |
653 | ;; Set to <next release>dev by default. | |
654 | (string-append "VER=" ,version)))) | |
d232e02e VD |
655 | (home-page "https://github.com/markfasheh/duperemove") |
656 | (synopsis "Tools for de-duplicating file system data") | |
657 | (description "Duperemove is a simple tool for finding duplicated extents | |
658 | and submitting them for deduplication. When given a list of files it will | |
659 | hash their contents on a block by block basis and compare those hashes to each | |
660 | other, finding and categorizing blocks that match each other. When given the | |
661 | @option{-d} option, duperemove will submit those extents for deduplication | |
662 | using the Linux kernel extent-same @code{ioctl}. | |
663 | ||
664 | Duperemove can store the hashes it computes in a @dfn{hash file}. If given an | |
665 | existing hash file, duperemove will only compute hashes for those files which | |
666 | have changed since the last run. Thus you can run duperemove repeatedly on | |
667 | your data as it changes, without having to re-checksum unchanged data. | |
668 | ||
669 | Duperemove can also take input from the @command{fdupes} program.") | |
670 | (license license:gpl2))) | |
834b0b9a EB |
671 | |
672 | (define-public ranger | |
673 | (package | |
674 | (name "ranger") | |
7ff557a5 | 675 | (version "1.9.3") |
834b0b9a EB |
676 | (source (origin |
677 | (method url-fetch) | |
678 | (uri (string-append "https://ranger.github.io/" | |
679 | "ranger-" version ".tar.gz")) | |
680 | (sha256 | |
681 | (base32 | |
7ff557a5 | 682 | "0lfjrpv3z4h0knd3v94fijrw2zjba51mrp3mjqx2c98wr428l26f")))) |
834b0b9a | 683 | (build-system python-build-system) |
19b662ea RH |
684 | (inputs |
685 | `(("w3m" ,w3m))) | |
43c97cce TGR |
686 | (native-inputs |
687 | `(("which" ,which) | |
688 | ||
689 | ;; For tests. | |
690 | ("python-pytest" ,python-pytest))) | |
19b662ea | 691 | (arguments |
43c97cce TGR |
692 | '( ;; The 'test' target runs developer tools like pylint, which fail. |
693 | #:test-target "test_pytest" | |
19b662ea RH |
694 | #:phases |
695 | (modify-phases %standard-phases | |
696 | (add-after 'configure 'wrap-program | |
697 | ;; Tell 'ranger' where 'w3mimgdisplay' is. | |
698 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
699 | (let* ((out (assoc-ref outputs "out")) | |
700 | (ranger (string-append out "/bin/ranger")) | |
701 | (w3m (assoc-ref inputs "w3m")) | |
702 | (w3mimgdisplay (string-append w3m | |
703 | "/libexec/w3m/w3mimgdisplay"))) | |
704 | (wrap-program ranger | |
705 | `("W3MIMGDISPLAY_PATH" ":" prefix (,w3mimgdisplay))) | |
3d0fdb34 TGR |
706 | #t))) |
707 | (replace 'check | |
43c97cce TGR |
708 | ;; The default check phase simply prints 'Ran 0 tests in 0.000s'. |
709 | (lambda* (#:key test-target #:allow-other-keys) | |
710 | (invoke "make" test-target)))))) | |
834b0b9a EB |
711 | (home-page "https://ranger.github.io/") |
712 | (synopsis "Console file manager") | |
adfc742c EB |
713 | (description "ranger is a console file manager with Vi key bindings. It |
714 | provides a minimalistic and nice curses interface with a view on the directory | |
715 | hierarchy. It ships with @code{rifle}, a file launcher that is good at | |
716 | automatically finding out which program to use for what file type.") | |
834b0b9a | 717 | (license license:gpl3))) |
dedc0d0b PN |
718 | |
719 | (define-public volume-key | |
720 | (package | |
721 | (name "volume-key") | |
8984dbd0 | 722 | (version "0.3.12") |
dedc0d0b PN |
723 | (source (origin |
724 | (method url-fetch) | |
725 | (uri (string-append "https://releases.pagure.org/volume_key/volume_key-" | |
726 | version ".tar.xz")) | |
727 | (sha256 | |
728 | (base32 | |
8984dbd0 | 729 | "16rhfz6sjwxlmss1plb2wv2i3jq6wza02rmz1d2jrlnsq67p98vc")))) |
dedc0d0b PN |
730 | (build-system gnu-build-system) |
731 | (native-inputs | |
732 | `(("pkg-config" ,pkg-config) | |
dedc0d0b | 733 | ("swig" ,swig) |
8984dbd0 | 734 | ("python" ,python-3))) ; used to generate the Python bindings |
dedc0d0b PN |
735 | (inputs |
736 | `(("cryptsetup" ,cryptsetup) | |
737 | ("nss" ,nss) | |
bb93042c | 738 | ("libblkid" ,util-linux "lib") |
8984dbd0 | 739 | ("lvm2" ,lvm2) ; for "-ldevmapper" |
dedc0d0b PN |
740 | ("glib" ,glib) |
741 | ("gpgme" ,gpgme))) | |
742 | (arguments | |
8984dbd0 | 743 | `(#:tests? #f ; not sure how tests are supposed to pass, even when run manually |
dedc0d0b PN |
744 | #:phases |
745 | (modify-phases %standard-phases | |
746 | (add-before 'configure 'patch-python.h-path | |
747 | (lambda* (#:key inputs #:allow-other-keys) | |
748 | (let ((python (assoc-ref inputs "python"))) | |
749 | (substitute* "Makefile.in" | |
750 | (("/usr/include/python") (string-append python "/include/python"))) | |
751 | #t)))))) | |
752 | (home-page "https://pagure.io/volume_key") | |
753 | (synopsis "Manipulate storage volume encryption keys") | |
754 | (description | |
755 | "This package provides a library for manipulating storage volume | |
756 | encryption keys and storing them separately from volumes to handle forgotten | |
757 | passphrases.") | |
758 | (license license:gpl2))) | |
f7a4f7c0 PN |
759 | |
760 | (define-public ndctl | |
761 | (package | |
762 | (name "ndctl") | |
2d4c1c0b | 763 | (version "71.1") |
f7a4f7c0 PN |
764 | (source (origin |
765 | (method git-fetch) | |
766 | (uri (git-reference | |
b0e7b699 | 767 | (url "https://github.com/pmem/ndctl") |
f7a4f7c0 | 768 | (commit (string-append "v" version)))) |
1f033795 | 769 | (file-name (git-file-name name version)) |
f7a4f7c0 PN |
770 | (sha256 |
771 | (base32 | |
2d4c1c0b | 772 | "1vi61bm9wyawklswh9mj9zdp28ar7r97qckwnhgiyila73fb3jx2")))) |
f7a4f7c0 PN |
773 | (build-system gnu-build-system) |
774 | (native-inputs | |
775 | `(("asciidoc" ,asciidoc) | |
776 | ("automake" ,automake) | |
777 | ("autoconf" ,autoconf) | |
1f033795 | 778 | ("bash-completion" ,bash-completion) |
f7a4f7c0 PN |
779 | ("docbook-xsl" ,docbook-xsl) |
780 | ("libtool" ,libtool) | |
781 | ("libxml2" ,libxml2) | |
782 | ("pkg-config" ,pkg-config) | |
783 | ("xmlto" ,xmlto) | |
1f033795 | 784 | ;; Required for offline docbook generation. |
f7a4f7c0 PN |
785 | ("which" ,which))) |
786 | (inputs | |
787 | `(("eudev" ,eudev) | |
788 | ("json-c" ,json-c) | |
f95114e5 | 789 | ("keyutils" ,keyutils) |
f7a4f7c0 | 790 | ("kmod" ,kmod) |
bb93042c | 791 | ("util-linux" ,util-linux "lib"))) |
f7a4f7c0 | 792 | (arguments |
1f033795 TGR |
793 | `(#:configure-flags |
794 | (list "--disable-asciidoctor" ; use docbook-xsl instead | |
795 | "--without-systemd") | |
796 | #:phases | |
f7a4f7c0 | 797 | (modify-phases %standard-phases |
a926109d | 798 | (add-after 'unpack 'patch-FHS-file-names |
f7a4f7c0 | 799 | (lambda _ |
f7a4f7c0 PN |
800 | (substitute* "git-version-gen" |
801 | (("/bin/sh") (which "sh"))) | |
802 | (substitute* "git-version" | |
a926109d TGR |
803 | (("/bin/bash") (which "bash"))) |
804 | #t))) | |
f7a4f7c0 PN |
805 | #:make-flags |
806 | (let ((out (assoc-ref %outputs "out"))) | |
807 | (list (string-append "BASH_COMPLETION_DIR=" out | |
808 | "/share/bash-completion/completions"))))) | |
809 | (home-page "https://github.com/pmem/ndctl") | |
810 | (synopsis "Manage the non-volatile memory device sub-system in the Linux kernel") | |
811 | (description | |
812 | "This package provides a utility library for managing the | |
813 | libnvdimm (non-volatile memory device) sub-system in the Linux kernel.") | |
814 | ;; COPYING says LGPL2.1, but many source files are GPL2 so that's | |
815 | ;; the effective license. Note that some files under ccan/ are | |
816 | ;; covered by BSD-3 or public domain, see the individual folders. | |
817 | (license license:gpl2))) | |
82aac7c1 PN |
818 | |
819 | (define-public dmraid | |
820 | (package | |
821 | (name "dmraid") | |
822 | (version "1.0.0.rc16-3") | |
823 | (source (origin | |
824 | (method url-fetch) | |
825 | (uri (string-append "https://people.redhat.com/~heinzm/sw/dmraid/src/dmraid-" | |
826 | version ".tar.bz2")) | |
827 | (sha256 | |
828 | (base32 | |
829 | "1n7vsqvh7y6yvil682q129d21yhb0cmvd5fvsbkza7ypd78inhlk")))) | |
830 | (build-system gnu-build-system) | |
831 | (inputs `(("lvm2" ,lvm2))) | |
832 | (native-inputs `(("which" ,which))) | |
833 | (arguments | |
834 | `(#:tests? #f ; No tests. | |
22070535 MB |
835 | ;; Prevent a race condition where some target would attempt to link |
836 | ;; libdmraid.so before it had been built as reported in | |
837 | ;; <https://bugs.gnu.org/31999#187>. | |
838 | #:parallel-build? #f | |
82aac7c1 PN |
839 | #:phases (modify-phases %standard-phases |
840 | (add-before 'configure 'change-directory | |
841 | (lambda _ | |
842 | (chdir (string-append ,version "/dmraid")) | |
843 | (substitute* "make.tmpl.in" | |
844 | (("/bin/sh") (which "sh"))) | |
845 | #t))) | |
846 | #:configure-flags (list ;; Make sure programs such as 'dmevent_tool' can | |
847 | ;; find libdmraid.so. | |
848 | (string-append "LDFLAGS=-Wl,-rpath=" | |
849 | (assoc-ref %outputs "out") | |
850 | "/lib")))) | |
851 | (home-page "https://people.redhat.com/~heinzm/sw/dmraid/") | |
852 | (synopsis "Device mapper RAID interface") | |
853 | (description | |
854 | "This software supports RAID device discovery, RAID set activation, creation, | |
855 | removal, rebuild and display of properties for ATARAID/DDF1 metadata. | |
856 | ||
857 | @command{dmraid} uses @file{libdevmapper} and the device-mapper kernel runtime | |
858 | to create devices with respective mappings for the ATARAID sets discovered.") | |
859 | (license license:gpl2+))) | |
fac91b39 PN |
860 | |
861 | (define-public libblockdev | |
862 | (package | |
863 | (name "libblockdev") | |
a8f8680b | 864 | (version "2.25") |
fac91b39 PN |
865 | (source (origin |
866 | (method url-fetch) | |
4273a7ef TGR |
867 | (uri (string-append "https://github.com/storaged-project/" |
868 | "libblockdev/releases/download/" | |
fac91b39 PN |
869 | version "-1/libblockdev-" version ".tar.gz")) |
870 | (sha256 | |
871 | (base32 | |
a8f8680b | 872 | "0s0nazkpzpn4an00qghjkk9n7gdm5a8dqfr5hfnlk5mk5lma8njm")))) |
fac91b39 | 873 | (build-system gnu-build-system) |
99f2c934 BW |
874 | (arguments |
875 | `(#:phases | |
876 | (modify-phases %standard-phases | |
877 | (add-after 'unpack 'patch-configuration-directory | |
878 | (lambda* (#:key outputs #:allow-other-keys) | |
879 | (let ((out (assoc-ref outputs "out"))) | |
880 | (substitute* "src/lib/blockdev.c" | |
881 | (("/etc/libblockdev/conf.d/" path) (string-append out path))))))))) | |
fac91b39 | 882 | (native-inputs |
7d18deb2 BW |
883 | `(("gobject-introspection" ,gobject-introspection) |
884 | ("pkg-config" ,pkg-config) | |
fac91b39 PN |
885 | ("python" ,python-wrapper) |
886 | ("util-linux" ,util-linux))) | |
887 | (inputs | |
888 | `(("btrfs-progs" ,btrfs-progs) | |
889 | ("cryptsetup" ,cryptsetup) | |
890 | ("dosfstools" ,dosfstools) | |
891 | ("dmraid" ,dmraid) | |
892 | ("eudev" ,eudev) | |
893 | ("glib" ,glib) | |
fac91b39 PN |
894 | ("kmod" ,kmod) |
895 | ("libbytesize" ,libbytesize) | |
896 | ("libyaml" ,libyaml) | |
897 | ("lvm2" ,lvm2) | |
898 | ("mdadm" ,mdadm) | |
899 | ("ndctl" ,ndctl) | |
900 | ("nss" ,nss) | |
901 | ("parted" ,parted) | |
902 | ("volume-key" ,volume-key) | |
903 | ;; ("xfsprogs" ,xfsprogs) ; TODO: Package? | |
904 | )) | |
905 | (home-page "https://github.com/storaged-project/libblockdev") | |
906 | (synopsis "Library for manipulating block devices") | |
907 | (description | |
908 | "libblockdev is a C library supporting GObject introspection for | |
909 | manipulation of block devices. It has a plugin-based architecture where each | |
910 | technology (like LVM, Btrfs, MD RAID, Swap...) is implemented in a separate | |
911 | plugin, possibly with multiple implementations (e.g. using LVM CLI or the new | |
912 | LVM D-Bus API).") | |
4273a7ef | 913 | (license license:lgpl2.1+))) |
3b451546 PN |
914 | |
915 | (define-public rmlint | |
916 | (package | |
917 | (name "rmlint") | |
46c26a73 | 918 | (version "2.10.1") |
3b451546 PN |
919 | (source (origin |
920 | (method git-fetch) | |
921 | (uri (git-reference | |
922 | (url "https://github.com/sahib/rmlint") | |
923 | (commit (string-append "v" version)))) | |
924 | (file-name (git-file-name name version)) | |
925 | (sha256 | |
926 | (base32 | |
46c26a73 | 927 | "15xfkcw1bkfyf3z8kl23k3rlv702m0h7ghqxvhniynvlwbgh6j2x")))) |
3b451546 PN |
928 | (build-system scons-build-system) |
929 | (arguments | |
930 | `(#:scons ,scons-python2 | |
931 | #:scons-flags (list (string-append "--prefix=" %output) | |
932 | (string-append "--actual-prefix=" %output)) | |
933 | #:tests? #f ; No tests? | |
934 | #:phases | |
935 | (modify-phases %standard-phases | |
936 | (add-after 'unpack 'scons-propagate-environment | |
937 | (lambda* (#:key inputs #:allow-other-keys) | |
938 | ;; TODO: `rmlint --gui` fails with | |
939 | ;; "Failed to load shredder: No module named 'shredder'". | |
940 | ;; The GUI might also need extra dependencies, such as | |
941 | ;; python-gobject, python-cairo, dconf, librsvg, gtksourceview3. | |
942 | (substitute* "lib/cmdline.c" | |
943 | (("const char \\*commands\\[\\] = \\{\"python3\", \"python\", NULL\\};") | |
944 | (string-append | |
945 | "const char *commands[] = {\"" | |
946 | (assoc-ref inputs "python") "/bin/python" | |
947 | "\", \"python\", NULL};"))) | |
948 | ;; By design, SCons does not, by default, propagate | |
949 | ;; environment variables to subprocesses. See: | |
950 | ;; <http://comments.gmane.org/gmane.linux.distributions.nixos/4969> | |
951 | ;; Here, we modify the SConstruct file to arrange for | |
952 | ;; environment variables to be propagated. | |
953 | (substitute* "SConstruct" | |
954 | (("^env = Environment\\(.*\\)" all) | |
955 | (string-append | |
956 | all | |
957 | "\nenv['ENV']=os.environ")))))))) | |
958 | (native-inputs | |
959 | `(("pkg-config" ,pkg-config) | |
960 | ("glib:bin" ,glib "bin") | |
961 | ("python-sphinx" ,python-sphinx))) | |
962 | (inputs | |
963 | `(("python" ,python-wrapper) | |
964 | ("glib" ,glib) | |
965 | ("libelf" ,libelf) | |
966 | ("elfutils" ,elfutils) | |
967 | ("json-glib" ,json-glib) | |
bb93042c | 968 | ("libblkid" ,util-linux "lib"))) |
3b451546 | 969 | (home-page "https://rmlint.rtfd.org") |
52beae7b | 970 | (synopsis "Remove duplicates and other lint from the file system") |
3b451546 | 971 | (description "@command{rmlint} finds space waste and other broken things |
52beae7b | 972 | on your file system and offers to remove it. @command{rmlint} can find: |
3b451546 PN |
973 | |
974 | @itemize | |
975 | @item duplicate files and duplicate directories, | |
976 | @item non-stripped binaries (i.e. binaries with debug symbols), | |
977 | @item broken symbolic links, | |
978 | @item empty files and directories, | |
979 | @item files with broken user and/or group ID. | |
980 | @end itemize\n") | |
981 | (license license:gpl3+))) | |
d441a645 P |
982 | |
983 | (define-public lf | |
984 | (package | |
985 | (name "lf") | |
986 | (version "13") | |
987 | (source (origin | |
988 | (method git-fetch) | |
989 | (uri (git-reference | |
b0e7b699 | 990 | (url "https://github.com/gokcehan/lf") |
d441a645 P |
991 | (commit (string-append "r" version)))) |
992 | (file-name (git-file-name name version)) | |
993 | (sha256 | |
994 | (base32 | |
995 | "1ld3q75v8rvp169w5p85z1vznqs9bhck6bm2f6fykxx16hmpb6ga")))) | |
996 | (build-system go-build-system) | |
997 | (native-inputs | |
998 | `(("go-github.com-mattn-go-runewidth" ,go-github.com-mattn-go-runewidth) | |
999 | ("go-github.com-nsf-termbox-go" ,go-github.com-nsf-termbox-go))) | |
1000 | (arguments | |
1001 | `(#:import-path "github.com/gokcehan/lf")) | |
1002 | (home-page "https://github.com/gokcehan/lf") | |
1003 | (synopsis "Console file browser similar to Ranger") | |
1004 | (description "lf (as in \"list files\") is a terminal file manager | |
1005 | written in Go. It is heavily inspired by ranger with some missing and | |
1006 | extra features. Some of the missing features are deliberately omitted | |
1007 | since they are better handled by external tools.") | |
1008 | (license license:expat))) | |
83fda6dd RG |
1009 | |
1010 | (define-public xfe | |
1011 | (package | |
1012 | (name "xfe") | |
1013 | (version "1.43.2") | |
1014 | (source | |
1015 | (origin | |
1016 | (method url-fetch) | |
1017 | (uri | |
26e11cff NG |
1018 | (string-append "mirror://sourceforge/xfe/xfe/" version "/" |
1019 | "xfe-" version ".tar.gz")) | |
83fda6dd RG |
1020 | (sha256 |
1021 | (base32 "1fl51k5jm2vrfc2g66agbikzirmp0yb0lqhmsssixfb4mky3hpzs")))) | |
1022 | (build-system gnu-build-system) | |
9b1f80a4 RG |
1023 | (arguments |
1024 | `(#:phases | |
1025 | (modify-phases %standard-phases | |
1026 | (add-after 'unpack 'patch-bin-dirs | |
1027 | (lambda* (#:key inputs #:allow-other-keys) | |
1028 | (let* ((bash (assoc-ref inputs "bash")) | |
1029 | (coreutils (assoc-ref inputs "coreutils")) | |
1030 | (findutils (assoc-ref inputs "findutils")) | |
1031 | (file-prog (assoc-ref inputs "file"))) | |
1032 | (with-directory-excursion "src" | |
1033 | (substitute* '("FilePanel.cpp" "help.h" "SearchPanel.cpp" | |
705a5dcb RG |
1034 | "startupnotification.cpp" "xfeutils.cpp" |
1035 | "../st/config.h") | |
9b1f80a4 RG |
1036 | (("/bin/sh" file) (string-append bash file)) |
1037 | (("/bin/ls" file) (string-append coreutils file)) | |
1038 | (("/usr(/bin/du)" _ file) (string-append coreutils file)) | |
1039 | (("/usr(/bin/sort)" _ file) (string-append coreutils file)) | |
1040 | (("/usr(/bin/cut)" _ file) (string-append coreutils file)) | |
1041 | (("/usr(/bin/xargs)" _ file) (string-append findutils file)) | |
1042 | (("/usr(/bin/file)" _ file) (string-append file-prog file)))) | |
1043 | #t))) | |
1044 | (add-after 'unpack 'patch-share-dirs | |
1045 | (lambda* (#:key outputs #:allow-other-keys) | |
1046 | (let* ((out (assoc-ref outputs "out")) | |
705a5dcb RG |
1047 | (share (string-append out "/share")) |
1048 | (xfe (string-append share "/xfe"))) | |
9b1f80a4 RG |
1049 | (with-directory-excursion "src" |
1050 | (substitute* '("foxhacks.cpp" "help.h" "xfedefs.h" | |
1051 | "XFileExplorer.cpp") | |
705a5dcb RG |
1052 | (("/(usr|opt)(/local)?/share") share) |
1053 | (("~/.config/xfe") xfe))) | |
9b1f80a4 | 1054 | #t)))))) |
83fda6dd RG |
1055 | (native-inputs |
1056 | `(("intltool" ,intltool) | |
1057 | ("pkg-config" ,pkg-config))) | |
1058 | (inputs | |
9b1f80a4 RG |
1059 | `(("bash" ,bash) |
1060 | ("coreutils" ,coreutils) | |
1061 | ("file" ,file) | |
1062 | ("findutils" ,findutils) | |
1063 | ("fox" ,fox) | |
83fda6dd RG |
1064 | ("freetype" ,freetype) |
1065 | ("x11" ,libx11) | |
1066 | ("xcb" ,libxcb) | |
1067 | ("xcb-util" ,xcb-util) | |
1068 | ("xft" ,libxft) | |
1069 | ("xrandr" ,libxrandr))) | |
83fda6dd | 1070 | (synopsis "File Manager for X-Based Graphical Systems") |
9b1f80a4 | 1071 | (description "XFE (X File Explorer) is a file manager for X. It is based on |
83fda6dd RG |
1072 | the popular but discontinued, X Win Commander. It aims to be the file manager |
1073 | of choice for all light thinking Unix addicts!") | |
1074 | (home-page "http://roland65.free.fr/xfe/") | |
26e11cff | 1075 | (license license:gpl2+))) |
eb44d3b8 PN |
1076 | |
1077 | (define-public hddtemp | |
1078 | (package | |
1079 | (name "hddtemp") | |
1080 | (version "0.3-beta15") | |
1081 | (source (origin | |
1082 | (method url-fetch) | |
1083 | (uri (string-append "mirror://savannah/hddtemp/hddtemp-" | |
1084 | version | |
1085 | ".tar.bz2")) | |
1086 | (sha256 | |
1087 | (base32 | |
1088 | "0nzgg4nl8zm9023wp4dg007z6x3ir60rwbcapr9ks2al81c431b1")))) | |
1089 | (build-system gnu-build-system) | |
1090 | (arguments | |
1091 | `(#:configure-flags (list (string-append | |
1092 | "--with-db-path=" | |
1093 | (assoc-ref %outputs "out") | |
1094 | "/share/hddtemp/hddtemp.db")) | |
1095 | #:phases | |
1096 | (modify-phases %standard-phases | |
1097 | (add-after 'install 'install-db | |
1098 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
1099 | (let ((target (string-append (assoc-ref outputs "out") | |
1100 | "/share/hddtemp/hddtemp.db"))) | |
1101 | (mkdir-p (dirname target)) | |
1102 | (copy-file (assoc-ref inputs "db") target))))))) | |
1103 | (inputs | |
1104 | `(("db" ,(origin | |
1105 | (method url-fetch) | |
1106 | (uri "mirror://savannah/hddtemp/hddtemp.db") | |
1107 | (sha256 | |
1108 | (base32 "1fr6qgns6qv7cr40lic5yqwkkc7yjmmgx8j0z6d93csg3smzhhya")))))) | |
1109 | (home-page "https://savannah.nongnu.org/projects/hddtemp/") | |
1110 | (synopsis "Report the temperature of hard drives from S.M.A.R.T. information") | |
1111 | (description "@command{hddtemp} is a small utility that gives you the | |
7230f6d5 | 1112 | temperature of your hard drive by reading S.M.A.R.T. information (for drives |
eb44d3b8 PN |
1113 | that support this feature).") |
1114 | (license license:gpl2+))) | |
a6d78f2b DM |
1115 | |
1116 | (define-public memkind | |
1117 | (package | |
1118 | (name "memkind") | |
1119 | (version "1.10.1") | |
1120 | (source (origin | |
1121 | (method git-fetch) | |
1122 | (uri (git-reference | |
8ed4c468 | 1123 | (url "https://github.com/memkind/memkind") |
a6d78f2b | 1124 | (commit (string-append "v" version)))) |
186b8dff | 1125 | (file-name (git-file-name name version)) |
a6d78f2b DM |
1126 | (sha256 |
1127 | (base32 | |
1128 | "11iz887f3cp5pzf1bzm644wzab8gkbhz3b7x1w6pcps71yd94ylj")))) | |
1129 | (build-system gnu-build-system) | |
1130 | (inputs | |
1131 | `(;; memkind patched jemalloc to add je_arenalookupx, | |
1132 | ;; je_check_reallocatex--i.e. they forked jemalloc. | |
1133 | ;("jemalloc" ,jemalloc) | |
1134 | ("ndctl" ,ndctl) | |
1135 | ("numactl" ,numactl))) | |
1136 | (native-inputs | |
1137 | `(("autoconf" ,autoconf) | |
1138 | ("automake" ,automake) | |
1139 | ("libtool" ,libtool))) | |
1140 | (arguments | |
1141 | `(#:tests? #f ; Tests require a NUMA-enabled system. | |
1142 | #:phases | |
1143 | (modify-phases %standard-phases | |
1144 | (add-before 'build 'autogen-jemalloc | |
1145 | (lambda _ | |
1146 | (with-directory-excursion "jemalloc" | |
1147 | (substitute* "Makefile.in" | |
1148 | (("/bin/sh") (which "sh"))) | |
1149 | (invoke "autoconf") | |
1150 | (substitute* "configure" | |
1151 | (("/bin/sh") (which "sh")))) | |
1152 | #t))))) | |
1153 | (home-page "https://github.com/memkind/memkind") | |
1154 | (synopsis "Heap manager with memory kinds (for NUMA)") | |
1155 | (description "This package provides a user-extensible heap manager | |
1156 | built on top of jemalloc which enables control of memory characteristics | |
1157 | and a partitioning of the heap between kinds of memory (for NUMA).") | |
1158 | (license license:bsd-3))) |