1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
4 ;;; Copyright © 2013 David Thompson <dthompson2@worcester.edu>
5 ;;; Copyright © 2014 Sree Harsha Totakura <sreeharsha@totakura.in>
6 ;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
7 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
8 ;;; Copyright © 2015, 2016, 2017, 2019 Efraim Flashner <efraim@flashner.co.il>
9 ;;; Copyright © 2017, 2018 Marius Bakke <mbakke@fastmail.com>
10 ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2018 Leo Famulari <leo@famulari.name>
13 ;;; This file is part of GNU Guix.
15 ;;; GNU Guix is free software; you can redistribute it and/or modify it
16 ;;; under the terms of the GNU General Public License as published by
17 ;;; the Free Software Foundation; either version 3 of the License, or (at
18 ;;; your option) any later version.
20 ;;; GNU Guix is distributed in the hope that it will be useful, but
21 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
22 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 ;;; GNU General Public License for more details.
25 ;;; You should have received a copy of the GNU General Public License
26 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28 (define-module (gnu packages xiph)
29 #:use-module (gnu packages)
30 #:use-module (gnu packages bison)
31 #:use-module (gnu packages compression)
32 #:use-module (gnu packages curl)
33 #:use-module (gnu packages documentation)
34 #:use-module (gnu packages image)
35 #:use-module (gnu packages pkg-config)
36 #:use-module (gnu packages python)
37 #:use-module (gnu packages linux)
38 #:use-module (gnu packages pulseaudio)
39 #:use-module (gnu packages tls)
40 #:use-module (gnu packages xml)
41 #:use-module ((guix licenses) #:prefix license:)
42 #:use-module (guix packages)
43 #:use-module (guix download)
44 #:use-module (guix build-system gnu)
64 (uri (string-append "https://downloads.xiph.org/releases/ogg/libogg-"
68 "022wjlzn8fx7mfby4pcgyjwx8zir7jr7cizichh3jgaki8bwcgsg"))))
69 (build-system gnu-build-system)
70 (synopsis "Library for manipulating the ogg multimedia format")
72 "The libogg library allows to manipulate the ogg multimedia container
73 format, which encapsulates raw compressed data and allows the interleaving of
74 audio and video data. In addition to encapsulation and interleaving of
75 multiple data streams, ogg provides packet framing, error detection, and
76 periodic timestamps for seeking.")
77 (license (license:non-copyleft "file://COPYING"
78 "See COPYING in the distribution."))
79 (home-page "https://xiph.org/ogg/")))
87 (uri (string-append "https://downloads.xiph.org/releases/vorbis/"
88 "libvorbis-" version ".tar.xz"))
91 "05dlzjkdpv46zb837wysxqyn8l636x3dw8v8ymlrwz2fg1dbn05g"))))
92 (build-system gnu-build-system)
93 (propagated-inputs `(("libogg" ,libogg)))
94 (arguments `(#:configure-flags '("LDFLAGS=-lm")
95 #:parallel-tests? #f))
96 (synopsis "Library implementing the vorbis audio format")
98 "The libvorbis library implements the ogg vorbis audio format,
99 a fully open, non-proprietary, patent-and-royalty-free, general-purpose
100 compressed audio format for mid to high quality (8kHz-48.0kHz, 16+ bit,
101 polyphonic) audio and music at fixed and variable bitrates from 16 to
103 (license (license:non-copyleft "file://COPYING"
104 "See COPYING in the distribution."))
105 (home-page "https://xiph.org/vorbis/")))
113 (uri (string-append "https://downloads.xiph.org/releases/theora/"
114 "libtheora-" version ".tar.xz"))
117 "0q8wark9ribij57dciym5vdikg2464p8q2mgqvfb78ksjh4s8vgk"))
118 (patches (search-patches "libtheora-config-guess.patch"))))
119 (build-system gnu-build-system)
120 (inputs `(("libvorbis" ,libvorbis)))
121 ;; The .pc files refer to libogg.
122 (propagated-inputs `(("libogg" ,libogg)))
123 (synopsis "Library implementing the Theora video format")
125 "The libtheora library implements the ogg theora video format,
126 a fully open, non-proprietary, patent-and-royalty-free, general-purpose
127 compressed video format.")
128 (license license:bsd-3)
129 (home-page "https://xiph.org/theora/")))
138 (uri (string-append "https://downloads.xiph.org/releases/speex/speex-"
142 "150047wnllz4r94whb9r73l5qf0z5z3rlhy98bawfbblmkq8mbpa"))))
143 (build-system gnu-build-system)
145 `(("pkg-config" ,pkg-config)))
148 ("speexdsp" ,speexdsp)))
149 (home-page "https://gnu.org/software/speex")
150 (synopsis "Library for patent-free audio compression format")
152 "GNU Speex is a patent-free audio compression codec specially designed
153 for speech. It is well-adapted to internet applications, such as VoIP. It
154 features compression of different bands in the same bitstream, intensity
155 stereo encoding, and voice activity detection.")
156 ;; 'src/getopt.c' is under LGPLv2+
157 (license (license:non-copyleft "file://COPYING"
158 "See COPYING in the distribution."))))
166 (uri (string-append "https://downloads.xiph.org/releases/speex/"
167 "speexdsp-" version ".tar.gz"))
170 "0wa7sqpk3x61zz99m7lwkgr6yv62ml6lfgs5xja65vlvdzy44838"))))
171 (build-system gnu-build-system)
173 `(#:configure-flags '(,@(if (string=? "aarch64-linux"
175 '("--enable-neon=no") ; neon defaults to armv7-a
177 (home-page "https://speex.org/")
178 (synopsis "Speex processing library")
180 "SpeexDSP is a @dfn{DSP} (Digital Signal Processing) library based on
181 work from the @code{speex} codec.")
182 (license (license:non-copyleft "file://COPYING"
183 "See COPYING in the distribution."))))
192 (uri (string-append "https://downloads.xiph.org/releases/ao/libao-"
196 "1bwwv1g9lchaq6qmhvj1pp3hnyqr64ydd4j38x94pmprs4d27b83"))))
197 (build-system gnu-build-system)
198 ;; FIXME: Add further backends, see the summary printed after configure.
199 ;; XXX: Should back-ends be pushed to different outputs? For instance,
200 ;; "out" would include only the ALSA back-end, while "pulse" would
201 ;; contain 'lib/ao/plugins-4/libpulse.*'.
203 `(("alsa-lib" ,alsa-lib)
204 ("pulseaudio" ,pulseaudio)))
206 `(("pkg-config" ,pkg-config)))
207 (synopsis "Cross platform audio library")
209 "Libao is a cross-platform audio library that allows programs to
210 output audio using a simple API on a wide variety of platforms.
211 It currently supports:
213 @item Null output (handy for testing without a sound device),
217 @item OSS (Open Sound System, used on Linux and FreeBSD),
218 @item ALSA (Advanced Linux Sound Architecture),
219 @item aRts (Analog RealTime Synth, used by KDE),
220 @item PulseAudio (next generation GNOME sound server),
221 @item esd (EsounD or Enlightened Sound Daemon),
223 @item Windows (98 and later),
225 @item Sun/NetBSD/OpenBSD,
227 @item NAS (Network Audio Server),
228 @item RoarAudio (Modern, multi-OS, networked Sound System),
229 @item OpenBSD's sndio.
232 (license license:gpl2+)
233 (home-page "https://www.xiph.org/ao/")))
241 (uri (string-append "https://downloads.xiph.org/releases/flac/flac-"
245 "0gymm2j3276kr9nz6vmgfwsdfrq6c449n40a0mzz8h6wc7nw7kwi"))
246 (patches (search-patches "flac-CVE-2017-6888.patch"))))
247 (build-system gnu-build-system)
249 `(#:parallel-tests? #f))
250 ;; FIXME: configure also looks for xmms, input could be added once it exists
251 (propagated-inputs `(("libogg" ,libogg))) ; required by flac.pc
252 (synopsis "Free lossless audio codec")
254 "FLAC stands for Free Lossless Audio Codec, an audio format that is lossless,
255 meaning that audio is compressed in FLAC without any loss in quality.")
256 (license (license:non-copyleft "file://COPYING"
257 "See COPYING in the distribution.")) ; and LGPL and GPL
258 (home-page "https://xiph.org/flac/")))
266 (uri (string-append "https://downloads.xiph.org/releases/kate/"
267 "libkate-" version ".tar.gz"))
270 "0s3vr2nxfxlf1k75iqpp4l78yf4gil3f0v778kvlngbchvaq23n4"))))
271 (build-system gnu-build-system)
272 (native-inputs `(("doxygen" ,doxygen)
273 ("pkg-config" ,pkg-config)))
274 ;; FIXME: Add optional input liboggz
275 (inputs `(("bison" ,bison)
278 ("python" ,python-wrapper)
280 (synopsis "Karaoke and text codec for embedding in ogg")
282 "Kate is an overlay codec, originally designed for karaoke and text,
283 that can be multiplixed in Ogg. Text and images can be carried by a Kate
284 stream, and animated. Most of the time, this would be multiplexed with
285 audio/video to carry subtitles, song lyrics (with or without karaoke data),
286 etc., but doesn't have to be.
288 Series of curves (splines, segments, etc.) may be attached to various
289 properties (text position, font size, etc.) to create animated overlays.
290 This allows scrolling or fading text to be defined. This can even be used
291 to draw arbitrary shapes, so hand drawing can also be represented by a
293 (license license:bsd-3)
294 (home-page "https://wiki.xiph.org/OggKate")))
298 (name "vorbis-tools")
302 (uri (string-append "https://downloads.xiph.org/releases/vorbis/"
303 "vorbis-tools-" version ".tar.gz"))
306 "1g12bnh5ah08v529y72kfdz5lhvy75iaz7f9jskyby23m9dkk2d3"))
307 (patches (search-patches
308 "vorbis-tools-CVE-2014-9638+CVE-2014-9639.patch"
309 "vorbis-tools-CVE-2014-9640.patch"
310 "vorbis-tools-CVE-2015-6749.patch"))))
311 (build-system gnu-build-system)
317 ("libvorbis" ,libvorbis)
319 (native-inputs `(("pkg-config" ,pkg-config)))
320 (synopsis "Ogg vorbis tools")
322 "Ogg vorbis is a non-proprietary, patent-and-royalty-free,
323 general-purpose compressed audio format.
325 The package vorbis-tools contains
326 ogg123, an ogg vorbis command line audio player;
327 oggenc, the ogg vorbis encoder;
328 oggdec, a simple, portable command line decoder (to wav and raw);
329 ogginfo, to obtain information (tags, bitrate, length, etc.) about
330 an ogg vorbis file.")
331 (license license:gpl2)
332 (home-page "https://xiph.org/vorbis/")))
340 (uri (string-append "https://archive.mozilla.org/pub/opus/opus-"
344 "17gz8kxs4i7icsc1gj713gadiapyklynlwqlf0ai98dj4lg8xdb5"))))
345 (build-system gnu-build-system)
346 (synopsis "Versatile audio codec")
348 "Opus is a totally open, royalty-free, highly versatile audio codec. Opus
349 is unmatched for interactive speech and music transmission over the Internet,
350 but is also intended for storage and streaming applications. It is
351 standardized by the Internet Engineering Task Force (IETF) as RFC 6716 which
352 incorporated technology from Skype's SILK codec and Xiph.Org's CELT codec.")
353 (license license:bsd-3)
354 (home-page "https://www.opus-codec.org")))
363 "https://downloads.xiph.org/releases/opus/opus-tools-"
367 "11pzl27s4vcz4m18ch72nivbhww2zmzn56wspb7rll1y1nq6rrdl"))))
368 (build-system gnu-build-system)
370 ;; The package developers misuse pkg-config such that it doesn't work
371 ;; when cross compiling. Therefore we avoid it completly and set the
372 ;; necessary flags ourselves.
373 `(#:configure-flags (list (string-append "CFLAGS=-I"
374 (assoc-ref %build-inputs "libogg")
376 (assoc-ref %build-inputs "opus")
379 `(("pkg-config" ,pkg-config)))
381 `(("libopusenc" ,libopusenc)
382 ("opusfile" ,opusfile)
385 "Command line utilities to encode, inspect, and decode .opus files")
386 (description "Opus is a royalty-free, highly versatile audio codec.
387 Opus-tools provide command line utilities for creating, inspecting and
388 decoding .opus files.")
389 (license license:bsd-3)
390 (home-page "https://www.opus-codec.org")))
399 "https://downloads.xiph.org/releases/opus/opusfile-" version
403 "1gq3aszzl5glgbajw5p1f5a1kdyf23w5vjdmwwrk246syin9pkkl"))))
404 (build-system gnu-build-system)
405 ;; Required by opusfile.pc and opusurl.pc.
411 `(("pkg-config" ,pkg-config)))
412 (synopsis "Versatile audio codec")
414 "The opusfile library provides seeking, decode, and playback of Opus
415 streams in the Ogg container (.opus files) including over http(s) on posix and
417 (license license:bsd-3)
418 (home-page "https://www.opus-codec.org")))
420 (define-public libopusenc
426 (uri (string-append "https://archive.mozilla.org/pub/opus/"
427 "libopusenc-" version ".tar.gz"))
430 "1ffb0vhlymlsq70pxsjj0ksz77yfm2x0a1x8q50kxmnkm1hxp642"))))
431 (build-system gnu-build-system)
433 `(("pkg-config" ,pkg-config)))
436 (synopsis "Library for encoding Opus audio files and streams ")
437 (description "The libopusenc libraries provide a high-level API for
438 encoding Opus files and streams.")
439 (home-page "https://www.opus-codec.org/")
440 (license license:bsd-3)))
442 (define-public icecast
449 "https://downloads.xiph.org/releases/icecast/icecast-"
453 "0i2d9rhav0x6js2qhjf5iy6j2a7f0d11ail0lfv40hb1kygrgda9"))))
454 (build-system gnu-build-system)
456 `(("pkg-config" ,pkg-config)))
458 `(("libxslt" ,libxslt)
463 ("libvorbis" ,libvorbis)
464 ("libtheora" ,libtheora)
466 (synopsis "Streaming media server")
467 (description "Icecast is a streaming media server which currently supports
468 Ogg (Vorbis and Theora), Opus, WebM and MP3 audio streams. It can be used to
469 create an Internet radio station or a privately running jukebox and many
471 (home-page "https://icecast.org/")
472 (license license:gpl2)))
474 (define-public libshout
481 "https://downloads.xiph.org/releases/libshout/"
482 "libshout-" version ".tar.gz"))
485 "0qgwarqp2p6jy3zadds6dzj8z1jfb2mbwc3lsdlidf527h0a86ym"))))
486 (build-system gnu-build-system)
488 `(("pkg-config" ,pkg-config)))
490 ;; shout.pc refers to all these.
491 `(("libtheora" ,libtheora)
492 ("libvorbis" ,libvorbis)
494 (home-page "https://icecast.org/")
495 (synopsis "Audio streaming library for icecast encoders")
497 "Libshout is a library for communicating with and sending data to an
498 icecast server. It handles the socket connection, the timing of the data,
499 and prevents bad data from getting to the icecast server.")
500 (license license:gpl2+)))