gnu: dvdisaster: Update to 0.79.10.
[jackhill/guix/guix.git] / gnu / packages / cdrom.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2018 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013, 2014 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
5 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
6 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
8 ;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
9 ;;; Copyright © 2017 John Darrington <jmd@gnu.org>
10 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
11 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
12 ;;; Copyright © 2017 Nikita <nikita@n0.is>
13 ;;; Copyright © 2018 Oleg Pykhalov <go.wigust@gmail.com>
14 ;;; Copyright © 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
15 ;;; Copyright © 2019 Eric Bavier <bavier@member.fsf.org>
16 ;;; Copyright © 2020 Timotej Lazar <timotej.lazar@araneo.si>
17 ;;;
18 ;;; This file is part of GNU Guix.
19 ;;;
20 ;;; GNU Guix is free software; you can redistribute it and/or modify it
21 ;;; under the terms of the GNU General Public License as published by
22 ;;; the Free Software Foundation; either version 3 of the License, or (at
23 ;;; your option) any later version.
24 ;;;
25 ;;; GNU Guix is distributed in the hope that it will be useful, but
26 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
27 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28 ;;; GNU General Public License for more details.
29 ;;;
30 ;;; You should have received a copy of the GNU General Public License
31 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
32
33 (define-module (gnu packages cdrom)
34 #:use-module (guix download)
35 #:use-module (guix git-download)
36 #:use-module (guix packages)
37 #:use-module ((guix licenses) #:select (lgpl2.1+ gpl2 gpl2+ gpl3+ cddl1.0))
38 #:use-module (guix build-system cmake)
39 #:use-module (guix build-system gnu)
40 #:use-module (guix build-system glib-or-gtk)
41 #:use-module (guix gexp)
42 #:use-module (guix utils)
43 #:use-module (gnu packages)
44 #:use-module (gnu packages acl)
45 #:use-module (gnu packages audio)
46 #:use-module (gnu packages autotools)
47 #:use-module (gnu packages bison)
48 #:use-module (gnu packages compression)
49 #:use-module (gnu packages flex)
50 #:use-module (gnu packages fontutils)
51 #:use-module (gnu packages gettext)
52 #:use-module (gnu packages docbook)
53 #:use-module (gnu packages xml)
54 #:use-module (gnu packages gtk)
55 #:use-module (gnu packages glib)
56 #:use-module (gnu packages m4)
57 #:use-module (gnu packages man)
58 #:use-module (gnu packages mp3)
59 #:use-module (gnu packages music)
60 #:use-module (gnu packages ncurses)
61 #:use-module (gnu packages elf)
62 #:use-module (gnu packages wxwidgets)
63 #:use-module (gnu packages linux)
64 #:use-module (gnu packages pkg-config)
65 #:use-module (gnu packages readline)
66 #:use-module (gnu packages base)
67 #:use-module (gnu packages perl)
68 #:use-module (gnu packages perl-web)
69 #:use-module (gnu packages python)
70 #:use-module (gnu packages image)
71 #:use-module (gnu packages photo)
72 #:use-module (gnu packages tcl)
73 #:use-module (gnu packages video)
74 #:use-module (gnu packages wget)
75 #:use-module (gnu packages xiph))
76
77 (define-public libcddb
78 (package
79 (name "libcddb")
80 (version "1.3.2")
81 (source (origin
82 (method url-fetch)
83 (uri (string-append "mirror://sourceforge/libcddb/libcddb/" version
84 "/libcddb-" version ".tar.bz2"))
85 (sha256
86 (base32
87 "0fr21a7vprdyy1bq6s99m0x420c9jm5fipsd63pqv8qyfkhhxkim"))))
88 (build-system gnu-build-system)
89 (arguments '(#:tests? #f)) ; tests rely on access to external servers
90 (home-page "http://libcddb.sourceforge.net/")
91 (synopsis "C library to access data on a CDDB server")
92 (description
93 "Libcddb is a C library to access data on a CDDB server (freedb.org). It
94 allows you to:
95
96 1. search the database for possible CD matches;
97
98 2. retrieve detailed information about a specific CD;
99
100 3. submit new CD entries to the database.
101
102 Libcddb supports both the custom CDDB protocol and tunnelling the query and
103 read operations over plain HTTP. It is also possible to use an HTTP proxy
104 server. If you want to speed things up, you can make use of the built-in
105 caching facility provided by the library.")
106 (license lgpl2.1+)))
107
108 (define-public libcdio
109 (package
110 (name "libcdio")
111 (version "2.1.0")
112 (source (origin
113 (method url-fetch)
114 (uri (string-append "mirror://gnu/libcdio/libcdio-"
115 version ".tar.bz2"))
116 (sha256
117 (base32
118 "0avi6apv5ydjy6b9c3z9a46rvp5i57qyr09vr7x4nndxkmcfjl45"))))
119 (build-system gnu-build-system)
120 (inputs
121 (list ncurses libcddb))
122 (native-inputs
123 (list help2man pkg-config))
124 (home-page "https://www.gnu.org/software/libcdio/")
125 (synopsis "CD Input and Control library")
126 (description
127 "The GNU Compact Disc Input and Control Library (libcdio) is a library
128 for CD-ROM and CD image file access. It allows the developer to add CD
129 access to an application without having to worry about the OS- and
130 device-dependent properties of CD-ROM or the specific details of CD image
131 formats. It includes pycdio, a Python interface to libcdio, and
132 libcdio-paranoia, a library providing jitter-free and error-free audio
133 extraction from CDs.")
134 (license gpl3+)))
135
136 (define-public libcdio-paranoia
137 (package
138 (name "libcdio-paranoia")
139 (version "10.2+2.0.1")
140 (source (origin
141 (method url-fetch)
142 (uri (string-append "mirror://gnu/libcdio/libcdio-paranoia-"
143 version ".tar.bz2"))
144 (sha256
145 (base32
146 "12hfnrq7amv9qjzc92cr265m7kh0a1hpasck8cxx1gygbhqczc9k"))))
147 (build-system gnu-build-system)
148 (native-inputs (list pkg-config))
149 (propagated-inputs (list libcdio))
150 (home-page "https://www.gnu.org/software/libcdio/")
151 (synopsis "Jitter- and error-tolerant CD audio extraction")
152 (description
153 "libcdio-paranoia is an implementation of CD paranoia libraries based on
154 libcdio.")
155 (license gpl3+)))
156
157 ;; Xorriso is used by Guix for creating ISO images. If you change this package,
158 ;; please make sure the Guix functionality still works by running some related
159 ;; system tests.
160 ;; For example, try running `make check-system TESTS=iso-image-installer`.
161 (define-public xorriso
162 (package
163 (name "xorriso")
164 (version "1.5.2")
165 (outputs '("out" "gui"))
166 (source (origin
167 (method url-fetch)
168 (uri (string-append "mirror://gnu/xorriso/xorriso-"
169 version ".tar.gz"))
170 (sha256
171 (base32
172 "1rqpzj95f70jfwpn4lamasfgqpizjsipz12aprdhri777b4zas9v"))))
173 (build-system gnu-build-system)
174 (arguments
175 `(#:phases
176 (modify-phases %standard-phases
177 (add-after 'install 'install-frontends
178 (lambda* (#:key outputs #:allow-other-keys)
179 (let* ((out (assoc-ref outputs "out"))
180 (out-bin (string-append out "/bin")))
181 (install-file "frontend/grub-mkrescue-sed.sh" out-bin)
182 #t)))
183 (add-after 'install 'move-gui-to-separate-output
184 (lambda* (#:key outputs #:allow-other-keys)
185 (let ((out (assoc-ref outputs "out"))
186 (gui (assoc-ref outputs "gui")))
187 (for-each
188 (lambda (file)
189 (mkdir-p (string-append gui (dirname file)))
190 (rename-file (string-append out file)
191 (string-append gui file)))
192 (list "/bin/xorriso-tcltk"
193 "/share/info/xorriso-tcltk.info"
194 "/share/man/man1/xorriso-tcltk.1"))
195 (wrap-program (string-append gui "/bin/xorriso-tcltk")
196 `("PATH" ":" prefix (,(string-append out "/bin"))))
197 #t))))))
198 (inputs
199 (list acl readline tk zlib))
200 (home-page "https://www.gnu.org/software/xorriso/")
201 (synopsis "Create, manipulate, burn ISO-9660 file systems")
202 (description
203 "GNU Xorriso is a tool for copying files to and from ISO 9660 Rock
204 Ridge, a.k.a. Compact Disc File System, file systems and it allows
205 session-wise manipulation of them. It features a formatter and burner for
206 CD, DVD and BD. It can operate on existing ISO images or it can create new
207 ones. xorriso can then be used to copy files directly into or out of ISO
208 files.")
209 (license gpl3+)))
210
211 (define-public cdparanoia
212 (package
213 (name "cdparanoia")
214 (version "10.2")
215 (source (origin
216 (method url-fetch)
217 (uri (string-append "http://downloads.xiph.org/releases/"
218 "cdparanoia/cdparanoia-III-"
219 version ".src.tgz"))
220 (sha256
221 (base32
222 "1pv4zrajm46za0f6lv162iqffih57a8ly4pc69f7y0gfyigb8p80"))
223 (patches (search-patches "cdparanoia-fpic.patch"))
224 (modules '((guix build utils)))
225 (snippet
226 '(begin
227 ;; Make libraries respect LDFLAGS.
228 (substitute* '("paranoia/Makefile.in" "interface/Makefile.in")
229 (("-Wl,-soname") "$(LDFLAGS) -Wl,-soname"))))))
230 (build-system gnu-build-system)
231 (arguments
232 `(#:tests? #f ; there is no check target
233 #:parallel-build? #f ;randomly fails to link
234 #:configure-flags ; Add $libdir to the RUNPATH of all the executables.
235 (list (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib"))
236 ;; Building in parallel is flaky: “ld: […]/cachetest.c:393: undefined
237 ;; reference to `paranoia_free'”.
238 #:parallel-build? #f))
239 (home-page "https://www.xiph.org/paranoia/")
240 (synopsis "Audio CD reading utility")
241 (description "Cdparanoia retrieves audio tracks from CDDA capable CDROM
242 drives. The data can be saved to a file or directed to standard output
243 in WAV, AIFF, AIFF-C or raw format. Most ATAPI, SCSI and several
244 proprietary CDROM drive makes are supported; cdparanoia can determine if the
245 target drive is CDDA capable. In addition to simple reading, cdparanoia adds
246 extra-robust data verification, synchronization, error handling and scratch
247 reconstruction capability.")
248 (license gpl2))) ; libraries under lgpl2.1
249
250 (define-public cdrdao
251 (package
252 (name "cdrdao")
253 (version "1.2.4")
254 (source
255 (origin
256 (method git-fetch)
257 (uri (git-reference
258 (url "https://github.com/cdrdao/cdrdao")
259 (commit
260 (string-append "rel_" (string-replace-substring version "." "_")))))
261 (file-name (git-file-name name version))
262 (sha256
263 (base32 "1gcl8ibyylamy2d1piq3749nw3xrlp12r0spzp2gmni57b8a6b7j"))))
264 (build-system gnu-build-system)
265 (arguments
266 '(#:configure-flags
267 (list
268 ;; GCDMaster depends on obsolete libgnomeuimm, see
269 ;; <https://github.com/cdrdao/cdrdao/issues/3>.
270 "--without-gcdmaster"
271 ;; Use the native SCSI interface.
272 "--without-scglib")
273 #:phases
274 (modify-phases %standard-phases
275 (add-before 'bootstrap 'fix-configure.ac
276 (lambda _
277 ;; Remove reference to missing macro.
278 (substitute* "configure.ac" (("^AM_GCONF_SOURCE_2.*") ""))
279 #t)))))
280 (native-inputs
281 (list autoconf automake pkg-config))
282 (inputs
283 (list ao lame libmad libvorbis))
284 (home-page "http://cdrdao.sourceforge.net")
285 (synopsis "Read and write CDs in disk-at-once mode")
286 (description "cdrdao records audio or data CDs in disk-at-once (DAO) mode,
287 based on a textual description of the contents. This mode writes the complete
288 disc – lead-in, one or more tracks, and lead-out – in a single step and is
289 commonly used with audio CDs. @code{cdrdao} can also handle the bin/cue
290 format, commonly used for VCDs or disks with subchannel data.")
291 (license gpl2+)))
292
293 (define-public cdrtools
294 (package
295 (name "cdrtools")
296 (version "3.01")
297 (source (origin
298 (method url-fetch)
299 (uri (string-append
300 "mirror://sourceforge/cdrtools/cdrtools-" version ".tar.bz2"))
301 (sha256
302 (base32
303 "03w6ypsmwwy4d7vh6zgwpc60v541vc5ywp8bdb758hbc4yv2wa7d"))
304 (modules '((guix build utils)))
305 (snippet
306 '(begin
307 ;; By default 'cdda2wav --help' would print a string like
308 ;; "Version 3.01_linux_4.19.10-gnu_x86_64_x86_64". Change
309 ;; it to not capture the kernel version of the build
310 ;; machine, to allow for reproducible builds.
311 (substitute* "cdda2wav/local.cnf.in"
312 (("^VERSION_OS=.*")
313 (string-append
314 "actual_os := $(shell uname -o)\n"
315 "actual_arch := $(shell uname -m)\n"
316 "VERSION_OS = _$(actual_os)_$(actual_arch)\n")))))
317 (patches (search-patches "cdrtools-3.01-mkisofs-isoinfo.patch"))))
318 (build-system gnu-build-system)
319 ;; XXX cdrtools bundles a modified, relicensed early version of cdparanoia.
320 (arguments
321 (list #:make-flags
322 #~(list "RM=rm" "LN=ln" "SYMLINK=ln -s"
323 "CONFIG_SHELL=sh"
324 (string-append "CCOM=" #$(cc-for-target))
325 "LINKMODE=dynamic"
326 (string-append "INS_BASE=" #$output)
327 (string-append "INS_RBASE=" #$output))
328 ;; Parallel builds appear to be unsafe, see
329 ;; https://hydra.gnu.org/build/3346840/log/raw
330 #:parallel-build? #f
331 #:phases
332 #~(modify-phases %standard-phases
333 (delete 'configure)
334 (add-before 'build 'set-linux-headers
335 (lambda _
336 (substitute* "autoconf/configure"
337 (("/usr/src/linux")
338 (assoc-ref %build-inputs "kernel-headers")))))
339 (add-before 'build 'avoid-bogus-RPATH-entry
340 (lambda _
341 (substitute* (append (find-files "DEFAULTS" "^Defaults\\.")
342 (find-files "DEFAULTS_ENG" "^Defaults\\.")
343 (find-files "TEMPLATES" "^Defaults\\."))
344 (("/opt/schily")
345 #$output)))))
346 #:tests? #f)) ; no tests
347 (synopsis "Command line utilities to manipulate and burn CD/DVD/BD images")
348 (description "cdrtools is a collection of command line utilities to create
349 CD's, DVD's or Blue Ray discs. The most important components are
350 @command{cdrecord}, a burning program, @command{cdda2wav}, a CD audio ripper
351 which uses libparanoia, and @command{mkisofs}, which can create various disc
352 images.")
353 (home-page "http://cdrtools.sourceforge.net/private/cdrecord.html")
354
355 ;; mkisofs is GPL, the other programs are CDDL.
356 (license (list cddl1.0 gpl2))))
357
358 (define-public dvd+rw-tools
359 (package
360 (name "dvd+rw-tools")
361 (version "7.1")
362 (source (origin
363 (method url-fetch)
364 (uri (string-append
365 "http://fy.chalmers.se/~appro/linux/DVD+RW/tools/dvd+rw-tools-"
366 version ".tar.gz"))
367 (sha256
368 (base32
369 "1jkjvvnjcyxpql97xjjx0kwvy70kxpiznr2zpjy2hhci5s10zmpq"))
370 (patches (search-patches "dvd+rw-tools-add-include.patch"))))
371 (build-system gnu-build-system)
372 (inputs
373 (list cdrtools))
374 (native-inputs
375 (list m4))
376 (arguments
377 `(#:tests? #f ; No tests.
378 #:phases
379 (modify-phases %standard-phases
380 (add-after 'unpack 'fix-glibc-compatability
381 (lambda* (#:key inputs #:allow-other-keys)
382 ;; We use sed --in-place because substitute* cannot handle the
383 ;; character encoding used by growisofs.c.
384 (invoke "sed" "-i" "-e"
385 (string-append
386 "s,<sys/stat.h>,"
387 "<sys/stat.h>\\\n#include <sys/sysmacros.h>,")
388 "growisofs.c")))
389 (replace 'configure
390 (lambda _ (setenv "prefix" (assoc-ref %outputs "out")) #t))
391 (add-before 'build 'embed-mkisofs
392 (lambda* (#:key inputs #:allow-other-keys)
393 ;; We use sed --in-place because substitute* cannot handle the
394 ;; character encoding used by growisofs.c.
395 (invoke "sed" "-i" "-e"
396 (string-append
397 "s,\"mkisofs\","
398 "\"" (which "mkisofs") "\",")
399 "growisofs.c"))))))
400 (home-page "http://fy.chalmers.se/~appro/linux/DVD+RW/")
401 (synopsis "DVD and Blu-ray Disc burning tools")
402 (description "dvd+rw-tools, mostly known for its command
403 @command{growisofs}, is a collection of DVD and Blu-ray Disc burning tools.
404 It requires another program, such as @command{mkisofs}, @command{genisoimage},
405 or @command{xorrisofs} to create ISO 9660 images.")
406 (license gpl2)))
407
408 (define-public dvdisaster
409 (package
410 (name "dvdisaster")
411 (version "0.79.10")
412 (source
413 (origin
414 (method url-fetch)
415 (uri (string-append "https://dvdisaster.jcea.es/downloads/dvdisaster-"
416 version ".tar.bz2"))
417 (sha256
418 (base32 "1s3z4098ixdjr3gjs36fg7rykqs0zz1rnvz2v9rvyj0s5zv9y2nx"))))
419 (build-system gnu-build-system)
420 (inputs
421 (list gtk+-2))
422 (native-inputs
423 (list gettext-minimal pkg-config which))
424 (arguments
425 `(;; Parallel builds appear to be unsafe, see
426 ;; <http://hydra.gnu.org/build/49331/nixlog/1/raw>.
427 #:parallel-build? #f
428 #:phases
429 (modify-phases %standard-phases
430 (replace 'check
431 (lambda _
432 (with-directory-excursion "regtest"
433 (substitute* "common.bash"
434 (("ISODIR=/var/tmp/regtest") "ISODIR=/tmp"))
435 (for-each invoke (find-files "." "rs.*\\.bash")))))
436 (add-after 'install 'install-desktop
437 (lambda* (#:key outputs #:allow-other-keys)
438 (let* ((datadir (string-append (assoc-ref outputs "out") "/share")))
439 (substitute* "contrib/dvdisaster.desktop"
440 (("dvdisaster48.png") "dvdisaster.png"))
441 (install-file "contrib/dvdisaster.desktop"
442 (string-append datadir "/applications"))
443 (for-each
444 (lambda (png)
445 (let* ((size (substring png
446 (string-index png char-set:digit)
447 (string-rindex png #\.)))
448 (icondir (string-append datadir "/icons/"
449 size "x" size "/apps")))
450 (mkdir-p icondir)
451 (copy-file png (string-append icondir "/dvdisaster.png"))))
452 (find-files "contrib" "dvdisaster[0-9]*\\.png"))
453 (mkdir-p (string-append datadir "/pixmaps"))
454 (copy-file "contrib/dvdisaster48.xpm"
455 (string-append datadir "/pixmaps/dvdisaster.xpm")))))
456 (add-after 'install 'remove-uninstall-script
457 (lambda* (#:key outputs #:allow-other-keys)
458 (let* ((out (assoc-ref outputs "out")))
459 (delete-file
460 (string-append out "/bin/dvdisaster-uninstall.sh"))))))))
461 (home-page "https://dvdisaster.jcea.es/")
462 (synopsis "Error correcting codes for optical media images")
463 (description "Optical media (CD,DVD,BD) keep their data only for a
464 finite time (typically for many years). After that time, data loss develops
465 slowly with read errors growing from the outer media region towards the
466 inside.
467
468 Dvdisaster stores data on CD/DVD/BD (supported media) in a way that it is
469 fully recoverable even after some read errors have developed. This enables
470 you to rescue the complete data to a new medium.
471
472 Data loss is prevented by using error correcting codes. Error correction
473 data is either added to the medium or kept in separate error correction
474 files. Dvdisaster works at the image level so that the recovery does not
475 depend on the file system of the medium. The maximum error correction
476 capacity is user-selectable.")
477 (license gpl2+)))
478
479 (define-public dvdstyler
480 (package
481 (name "dvdstyler")
482 (version "3.0.4")
483 (source
484 (origin
485 (method url-fetch)
486 (uri (string-append "mirror://sourceforge/dvdstyler/dvdstyler/"
487 version "/DVDStyler-" version ".tar.bz2"))
488 (sha256
489 (base32
490 "0lwc0hn94m9r8fi07sjqz3fr618l6lnw3zsakxw7nlgnxbjsk7pi"))))
491 (build-system gnu-build-system)
492 (arguments
493 `(#:configure-flags
494 (list (string-append "XMLTO="
495 (assoc-ref %build-inputs "xmlto")
496 "/bin/xmlto --searchpath "
497 (assoc-ref %build-inputs "docbook-xsl")
498 "/xml/xsl/docbook-xsl-" ,(package-version docbook-xsl)
499 "/htmlhelp:"
500 (assoc-ref %build-inputs "docbook-xml")
501 "/xml/dtd/docbook"))
502 #:phases
503 (modify-phases %standard-phases
504 (add-after 'install 'wrap-program
505 (lambda* (#:key inputs outputs #:allow-other-keys)
506 (wrap-program (string-append (assoc-ref outputs "out") "/bin/dvdstyler")
507 `("PATH" ":" prefix
508 (,(string-join
509 (map (lambda (in) (string-append (assoc-ref inputs in) "/bin"))
510 '("cdrtools" "dvdauthor" "dvd+rw-tools" "ffmpeg"))
511 ":"))))
512 #t)))
513 #:tests? #f)) ; No tests.
514 (inputs ; TODO package bundled wxvillalib
515 `(("wxwidgets" ,wxwidgets-3.1)
516 ("wssvg" ,wxsvg)
517 ("dbus" ,dbus)
518 ("cdrtools" ,cdrtools)
519 ("dvd+rw-tools" ,dvd+rw-tools)
520 ("dvdauthor" ,dvdauthor)
521 ("eudev" ,eudev)
522 ("fontconfig" ,fontconfig)
523 ("libexif" ,libexif)
524 ("libjpeg" ,libjpeg-turbo)
525 ("ffmpeg" ,ffmpeg-3.4)))
526 (native-inputs
527 `(("pkg-config" ,pkg-config)
528 ("flex" ,flex)
529 ("python" ,python-2)
530 ("xmlto" ,xmlto)
531 ("gettext" ,gettext-minimal)
532 ("docbook-xml" ,docbook-xml)
533 ("docbook-xsl" ,docbook-xsl)
534 ("zip" ,zip)))
535 (synopsis "DVD authoring application")
536 (description "DVDStyler is a DVD authoring application which allows users
537 to burn video files in many formats to DVD discs, complete with individually
538 designed menus. It can be used to create professional-looking DVD's with
539 custom buttons, backgrounds and animations, from within a user-friendly
540 graphical interface.")
541 (home-page "https://www.dvdstyler.org")
542 (license gpl2)))
543
544 (define-public libcue
545 (package
546 (name "libcue")
547 (version "2.2.1")
548 (source (origin
549 (method git-fetch)
550 (uri (git-reference
551 (url "https://github.com/lipnitsk/libcue")
552 (commit (string-append "v" version))))
553 (file-name (git-file-name name version))
554 (sha256
555 (base32
556 "1iqw4n01rv2jyk9lksagyxj8ml0kcfwk67n79zy1r6zv1xfp5ywm"))))
557 (build-system cmake-build-system)
558 (arguments
559 `(#:configure-flags '("-DBUILD_SHARED_LIBS=ON")))
560 (native-inputs
561 (list bison flex))
562 (home-page "https://github.com/lipnitsk/libcue")
563 (synopsis "C library to parse cue sheets")
564 (description "Libcue is a C library to parse so-called @dfn{cue sheets}
565 which contain meta-data for CD/DVD tracks. It provides an API to manipulate
566 the data.")
567 (license gpl2+)))
568
569 (define-public cd-discid
570 (package
571 (name "cd-discid")
572 (version "1.4")
573 (home-page "http://linukz.org/cd-discid.shtml")
574 (source (origin
575 (method url-fetch)
576 (uri (string-append "http://linukz.org/download/cd-discid-"
577 version ".tar.gz"))
578 (sha256
579 (base32
580 "0qrcvn7227qaayjcd5rm7z0k5q89qfy5qkdgwr5pd7ih0va8rmpz"))
581 (modules '((guix build utils)))
582 (snippet
583 '(begin
584 (substitute* "Makefile"
585 (("/usr/bin/install")
586 "install"))
587 #t))))
588 (build-system gnu-build-system)
589 (arguments
590 `(#:tests? #f
591 #:phases (modify-phases %standard-phases (delete 'configure))
592 #:make-flags (list ,(string-append "CC=" (cc-for-target))
593 (string-append "PREFIX="
594 (assoc-ref %outputs "out")))))
595 (synopsis "Get CDDB discid information from an audio CD")
596 (description
597 "cd-discid is a command-line tool to retrieve CDDB discid information
598 from an audio CD.")
599 (license gpl2+)))
600
601 (define-public abcde
602 (package
603 (name "abcde")
604 (version "2.9.3")
605 (home-page "https://abcde.einval.com/")
606 (source (origin
607 (method url-fetch)
608 (uri (string-append home-page "/download/abcde-"
609 version ".tar.gz"))
610 (sha256
611 (base32
612 "091ip2iwb6b67bhjsj05l0sxyq2whqjycbzqpkfbpm4dlyxx0v04"))
613 (modules '((guix build utils)))
614 (snippet
615 '(begin
616 (substitute* "Makefile"
617 (("/usr/bin/install")
618 "install"))
619 #t))))
620 (build-system gnu-build-system)
621 (arguments
622 '(#:phases
623 (modify-phases %standard-phases
624 (replace 'configure
625 (lambda* (#:key outputs inputs #:allow-other-keys)
626 (substitute* "Makefile"
627 (("^prefix = .*$")
628 (string-append "prefix = "
629 (assoc-ref outputs "out")
630 "\n"))
631 (("^sysconfdir = .*$")
632 (string-append "sysconfdir = "
633 (assoc-ref outputs "out")
634 "/etc/\n")))
635 #t))
636 (add-after 'install 'wrap
637 (lambda* (#:key inputs outputs #:allow-other-keys)
638 (let ((wget (assoc-ref inputs "wget"))
639 (vorbis (assoc-ref inputs "vorbis-tools"))
640 (parano (assoc-ref inputs "cdparanoia"))
641 (which (assoc-ref inputs "which"))
642 (discid (assoc-ref inputs "cd-discid"))
643 (perl-discid (assoc-ref inputs "perl-musicbrainz-discid"))
644 (perl-ws (assoc-ref inputs "perl-webservice-musicbrainz"))
645 (perl-mojo (assoc-ref inputs "perl-mojolicious"))
646 (flac (assoc-ref inputs "flac"))
647 (out (assoc-ref outputs "out")))
648 (define (wrap file)
649 (wrap-program file
650 `("PATH" ":" prefix
651 (,(string-append out "/bin:"
652 wget "/bin:"
653 flac "/bin:"
654 which "/bin:"
655 vorbis "/bin:"
656 discid "/bin:"
657 parano "/bin")))
658 `("PERL5LIB" ":" prefix
659 (,(string-append perl-discid
660 "/lib/perl5/site_perl:"
661 perl-ws
662 "/lib/perl5/site_perl:"
663 perl-mojo
664 "/lib/perl5/site_perl")))))
665
666 (for-each wrap
667 (find-files (string-append out "/bin")
668 ".*")))
669 #t)))
670 #:tests? #f)) ; no test target
671
672 (inputs (list wget
673 which
674 cdparanoia
675 cd-discid
676 vorbis-tools
677 flac
678 perl-musicbrainz-discid
679 perl-webservice-musicbrainz
680 perl-mojolicious ;indirect dependency
681 ;; A couple of Python and Perl scripts are included.
682 python
683 perl))
684
685 (synopsis "Command-line audio CD ripper")
686 (description
687 "abcde is a front-end command-line utility (actually, a shell script)
688 that grabs tracks off a CD, encodes them to Ogg/Vorbis, MP3, FLAC, Ogg/Speex
689 and/or MPP/MP+ (Musepack) format, and tags them, all in one go.")
690 (license gpl2+)))
691
692 (define-public geteltorito
693 (package
694 (name "geteltorito")
695 (version "0.6")
696 (home-page
697 "https://userpages.uni-koblenz.de/~krienke/ftp/noarch/geteltorito/")
698 (source (origin
699 (method url-fetch)
700 (uri (string-append home-page name "-" version ".tar.gz"))
701 (sha256
702 (base32
703 "1gkbm9ahj2mgqrkrfpibzclsriqgsbsvjh19fr815vpd9f6snkxv"))))
704 (build-system gnu-build-system)
705 (arguments
706 `(#:tests? #f ; No tests.
707 #:phases
708 (modify-phases %standard-phases
709 (delete 'configure)
710 (delete 'build)
711 (replace 'install
712 (lambda* (#:key outputs #:allow-other-keys)
713 (let ((out (assoc-ref outputs "out")))
714 (install-file "geteltorito"
715 (string-append out "/bin"))))))))
716 (inputs (list perl))
717 (synopsis "Extract the boot image from a CD-ROM")
718 (description
719 "@command{geteltorito} can extract the initial/default boot
720 image from CDs (and ISOs) that follow the El Torito specification
721 for bootable CD-ROMs.
722
723 Image data is written to standard output by default and all other
724 information is written to standard error.")
725 (license gpl2+)))
726
727 (define-public asunder
728 (package
729 (name "asunder")
730 (version "2.9.7")
731 (source
732 (origin
733 (method url-fetch)
734 (uri
735 (string-append "http://www.littlesvr.ca/asunder/releases/asunder-"
736 version ".tar.bz2"))
737 (sha256
738 (base32 "1x3l308ss0iqhz90qyjb94gyd8b4piyrm2nzjmg5kf049k9prjf1"))))
739 (build-system glib-or-gtk-build-system)
740 (arguments
741 '(#:out-of-source? #f
742 #:phases (modify-phases %standard-phases
743 (add-after 'install 'wrap
744 (lambda* (#:key inputs outputs #:allow-other-keys)
745 (let ((program (string-append (assoc-ref outputs "out")
746 "/bin/asunder")))
747 (define (bin-directory input-name)
748 (string-append (assoc-ref inputs input-name) "/bin"))
749 (wrap-program program
750 `("PATH" ":" prefix
751 ,(map bin-directory (list "cdparanoia"
752 "lame"
753 "vorbis-tools"
754 "flac"
755 "opus-tools"
756 "wavpack"))))))))))
757 (native-inputs (list intltool pkg-config))
758 ;; TODO: Add the necessary packages for Musepack encoding.
759 (inputs `(("gtk+-2" ,gtk+-2)
760 ("glib" ,glib)
761 ("libcddb" ,libcddb)
762 ("cdparanoia" ,cdparanoia)
763 ("lame" ,lame)
764 ("vorbis-tools" ,vorbis-tools)
765 ("flac" ,flac)
766 ("opus-tools" ,opus-tools)
767 ("wavpack" ,wavpack)))
768 (home-page "http://www.littlesvr.ca/asunder/")
769 (synopsis "Graphical audio CD ripper and encoder")
770 (description
771 "Asunder is a graphical audio CD ripper and encoder. It can save audio
772 tracks as WAV, MP3, Ogg Vorbis, FLAC, Opus, Wavpack, and Musepack. It can use
773 CDDB to name and tag each track automatically, and it allows for each track to
774 be by a different artist. Asunder can encode to multiple formats in one
775 session, and it can create M3U playlists.")
776 (license gpl2)))
777
778 (define-public ripit
779 (package
780 (name "ripit")
781 (version "3.9.0")
782 (source
783 (origin
784 (method url-fetch)
785 ;; The original suwald.com domain has expired.
786 (uri (list
787 (string-append "https://web.archive.org/web/20160327050927/"
788 "http://suwald.com/ripit/ripit-" version ".tar.gz")
789 (string-append "https://ponce.cc/slackware/sources/repo/ripit-"
790 version ".tar.gz")))
791 (sha256
792 (base32 "0ap71x477jy9c4jiqazb3y45hxdxm3jbq24x05g3vjyqzigi4x1b"))))
793 (build-system gnu-build-system)
794 (arguments
795 `(#:tests? #f ; no test suite
796 #:phases
797 (modify-phases %standard-phases
798 (delete 'configure)
799 (add-after 'unpack 'patch-usr-bin-install
800 (lambda* (#:key inputs outputs #:allow-other-keys)
801 (substitute* "Makefile"
802 (("/usr/bin/install") (string-append
803 (assoc-ref inputs "coreutils")
804 "/bin/install"))
805 (("\\$\\(DESTDIR\\)/usr/local") (assoc-ref outputs "out"))
806 (("../../etc") "etc")))))))
807 (native-inputs
808 (list coreutils))
809 (inputs
810 (list perl))
811 (propagated-inputs
812 (list cdparanoia flac vorbis-tools wavpack perl-cddb-get))
813 (home-page (string-append "https://web.archive.org/web/20170119092156/"
814 "http://www.suwald.com/ripit/about.php"))
815 (synopsis "Command-line program to extract audio CDs")
816 (description "RipIT is used to extract audio from CDs.")
817 (license gpl2)))
818
819 (define-public ccd2cue
820 (package
821 (name "ccd2cue")
822 (version "0.5")
823 (source
824 (origin
825 (method url-fetch)
826 (uri (string-append
827 "mirror://gnu/ccd2cue/ccd2cue-" version
828 ".tar.gz"))
829 (sha256
830 (base32
831 "1icrkg25hwx4gsn3dski2172ia4ywjh8m1sa17zmjclnrgdwy9c7"))))
832 (build-system gnu-build-system)
833 (synopsis "CCD to CUE sheet conversion")
834 (description
835 "GNU ccd2cue is a preprocessor for CD burning software that allows
836 the conversion of the proprietary CCD format to the CUE format, which
837 is well-supported by free software. These files are commonly
838 distributed with CD images and are used to describe how tracks are
839 laid out on the image.")
840 (home-page "https://www.gnu.org/software/ccd2cue/")
841 (license gpl3+)))
842
843 (define-public libburn
844 (package
845 (name "libburn")
846 (version "1.5.4")
847 (source (origin
848 (method url-fetch)
849 (uri (string-append "http://files.libburnia-project.org/releases/"
850 "libburn-" version ".tar.gz"))
851 (sha256
852 (base32
853 "0m1vyry6pi115nysfgb0cg313qqhnlxqdg7f920wpiar0z8mjl2j"))))
854 (build-system gnu-build-system)
855 (native-inputs
856 (list pkg-config))
857 (home-page "https://dev.lovelyhq.com/libburnia/libburn")
858 (synopsis "Library for reading and writing optical discs")
859 (description
860 "Libburn is a library for reading and writing optical discs.
861 Supported media are: CD-R, CD-RW, DVD-RAM, DVD+RW, DVD+R, DVD+R/DL,
862 DVD-RW, DVD-R, DVD-R/DL, BD-R, and BD-RE.")
863 (license gpl2)))
864
865 (define-public libisofs
866 (package
867 (name "libisofs")
868 (version "1.5.4")
869 (source (origin
870 (method url-fetch)
871 (uri (string-append "http://files.libburnia-project.org/releases/"
872 "libisofs-" version ".tar.gz"))
873 (sha256
874 (base32
875 "13m82l13cb5d7ca53dv3akma1jr9gw0hnnshdwqpj6ahly0fv85a"))))
876 (build-system gnu-build-system)
877 (inputs
878 (list zlib acl))
879 (native-inputs
880 (list pkg-config))
881 (home-page "https://dev.lovelyhq.com/libburnia/libisofs")
882 (synopsis "Library to create ISO 9660 images")
883 (description
884 "Libisofs creates ISO 9660 (also known as ECMA-119) file system images
885 which can either be written to POSIX file objects or handed over to
886 libburn for being written directly to optical media.
887 It can read metadata of ISO 9660 filesystems, manipulate them, and use them
888 to produce new complete file system images or add-on images to be appended
889 to the read file system image.
890 Supported extensions to ISO 9660 are Rock Ridge, Joliet, AAIP, zisofs.")
891 (license gpl2+)))
892
893 (define-public cdrkit-libre
894 (package
895 (name "cdrkit-libre")
896 (version "1.1.11")
897 (source (origin
898 (method url-fetch)
899 ;; cdrkit.org is dead.
900 ;;
901 ;; ‘cdrkit-libre’ removes a couple of problematic files,
902 ;; see <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=32165#14>.
903 (uri (string-append
904 "https://repo.parabola.nu/other/cdrkit-libre/cdrkit-libre-"
905 version ".tar.gz"))
906 (sha256
907 (base32
908 "0g2zyzb56czh429qy87lvaddzjnlcq8c616ddxsmsshz3clhyzrh"))
909 (patches (search-patches "cdrkit-libre-cross-compile.patch"))
910 (modules '((guix build utils)))
911 (snippet
912 #~(begin
913 ;; Fix building with gcc-10.
914 (substitute* "genisoimage/genisoimage.h"
915 (("char\t\t\\*outfile")
916 "extern char\t*outfile"))))))
917 (build-system cmake-build-system)
918 (inputs
919 (list bzip2 libcap perl zlib))
920 (arguments
921 `(#:tests? #f ;no tests
922 #:phases
923 (modify-phases %standard-phases
924 (add-after 'install 'old-cdrecord
925 (lambda* (#:key outputs #:allow-other-keys)
926 (with-directory-excursion (string-append (assoc-ref outputs "out")
927 "/bin")
928 (symlink "genisoimage" "mkisofs")
929 (symlink "wodim" "cdrecord"))
930 #t)))))
931 (home-page "https://repo.parabola.nu/other/cdrkit-libre/")
932 (synopsis "Command-line CD/DVD recorder")
933 (description "Cdrkit is a suite of programs for recording CDs and DVDs,
934 blanking CD-RW media, creating ISO-9660 file system images, extracting audio
935 CD data, and more. It's mostly compatible with @code{cdrtools}.")
936 (license gpl2+)))
937
938 (define-public libmirage
939 (package
940 (name "libmirage")
941 (version "3.2.6")
942 (source (origin
943 (method url-fetch)
944 (uri (string-append
945 "mirror://sourceforge/cdemu/libmirage/libmirage-"
946 version ".tar.xz"))
947 (sha256
948 (base32
949 "19pjdmxhzl8y3brhg8fsv99b6jg4lfnl8jvcjgm4jmqrr684czr5"))))
950 (build-system cmake-build-system)
951 (native-inputs
952 (list pkg-config intltool))
953 (inputs
954 (list glib))
955 (arguments
956 ;; No tests.
957 '(#:tests? #f))
958 (home-page "https://cdemu.sourceforge.io/")
959 (synopsis "CD-ROM image access library")
960 (description "libMirage is a CD-ROM image access library. It supports the
961 following formats: B6T, C2D, CCD, CDI, CIF, CUE, ISO, MDS, MDX, NRG, TOC. It
962 is written in C and based on GLib. Its aim is to provide uniform access to
963 the data stored in various image formats.")
964 (license gpl2+)))
965
966 (define-public cdemu-daemon
967 (package
968 (name "cdemu-daemon")
969 (version "3.2.6")
970 (source (origin
971 (method url-fetch)
972 (uri (string-append
973 "mirror://sourceforge/cdemu/cdemu-daemon/"
974 "cdemu-daemon-" version ".tar.xz"))
975 (sha256
976 (base32
977 "13vxhl7ik3h5qnfh6m0zxywb8qzx1n46akrm6rp19ikmxzih9r56"))))
978 (build-system cmake-build-system)
979 (native-inputs
980 (list pkg-config intltool))
981 (inputs
982 (list libmirage glib ao))
983 (arguments
984 ;; No tests.
985 '(#:tests? #f))
986 (home-page "https://cdemu.sourceforge.io/")
987 (synopsis "CD/DVD-ROM device emulator")
988 (description "CDemu is a software suite designed to emulate an optical
989 drive and disc (including CD-ROMs and DVD-ROMs).")
990 (license gpl2+)))
991
992 (define-public cdemu-client
993 (package
994 (name "cdemu-client")
995 (version "3.2.5")
996 (source (origin
997 (method url-fetch)
998 (uri (string-append
999 "mirror://sourceforge/cdemu/cdemu-client/cdemu-client-"
1000 version ".tar.xz"))
1001 (sha256
1002 (base32
1003 "1prrdhv0ia0axc6b73crszqzh802wlkihz6d100yvg7wbgmqabd7"))))
1004 (build-system cmake-build-system)
1005 (native-inputs
1006 (list pkg-config intltool))
1007 (inputs
1008 (list python python-pygobject cdemu-daemon))
1009 (arguments
1010 ;; No tests.
1011 `(#:tests? #f
1012 #:phases
1013 (modify-phases %standard-phases
1014 (add-after 'install 'patch-shebang
1015 (lambda* (#:key outputs #:allow-other-keys)
1016 (patch-shebang (string-append (assoc-ref outputs "out")
1017 "/bin/cdemu"))
1018 #t))
1019 (add-after 'patch-shebang 'wrap-program
1020 (lambda* (#:key outputs #:allow-other-keys)
1021 (let ((prog (string-append (assoc-ref outputs "out")
1022 "/bin/cdemu")))
1023 (wrap-program prog
1024 `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH"))))
1025 #t))))))
1026 (home-page "https://cdemu.sourceforge.io/")
1027 (synopsis "Command-line client for controlling cdemu-daemon")
1028 (description "CDEmu client is a simple command-line client for controlling
1029 CDEmu daemon.
1030
1031 It provides a way to perform the key tasks related to controlling the CDEmu
1032 daemon, such as loading and unloading devices, displaying devices' status and
1033 retrieving/setting devices' debug masks.")
1034 (license gpl2+)))