gnu: python-pandas: Fix build on 32-bit.
[jackhill/guix/guix.git] / gnu / packages / xiph.scm
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 Efraim Flashner <efraim@flashner.co.il>
9 ;;;
10 ;;; This file is part of GNU Guix.
11 ;;;
12 ;;; GNU Guix is free software; you can redistribute it and/or modify it
13 ;;; under the terms of the GNU General Public License as published by
14 ;;; the Free Software Foundation; either version 3 of the License, or (at
15 ;;; your option) any later version.
16 ;;;
17 ;;; GNU Guix is distributed in the hope that it will be useful, but
18 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ;;; GNU General Public License for more details.
21 ;;;
22 ;;; You should have received a copy of the GNU General Public License
23 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24
25 (define-module (gnu packages xiph)
26 #:use-module (gnu packages)
27 #:use-module (gnu packages bison)
28 #:use-module (gnu packages compression)
29 #:use-module (gnu packages curl)
30 #:use-module (gnu packages documentation)
31 #:use-module (gnu packages image)
32 #:use-module (gnu packages pkg-config)
33 #:use-module (gnu packages python)
34 #:use-module (gnu packages linux)
35 #:use-module (gnu packages pulseaudio)
36 #:use-module (gnu packages tls)
37 #:use-module (gnu packages xml)
38 #:use-module ((guix licenses) #:prefix license:)
39 #:use-module (guix packages)
40 #:use-module (guix download)
41 #:use-module (guix build-system gnu)
42 #:export (libogg
43 libvorbis
44 libtheora
45 speex
46 ao
47 flac
48 libkate
49 vorbis-tools
50 opus
51 opusfile
52 opus-tools))
53
54 (define libogg
55 (package
56 (name "libogg")
57 (version "1.3.2")
58 (source (origin
59 (method url-fetch)
60 (uri (string-append "http://downloads.xiph.org/releases/ogg/libogg-"
61 version ".tar.xz"))
62 (sha256
63 (base32
64 "16z74q422jmprhyvy7c9x909li8cqzmvzyr8cgbm52xcsp6pqs1z"))))
65 (build-system gnu-build-system)
66 (synopsis "Library for manipulating the ogg multimedia format")
67 (description
68 "The libogg library allows to manipulate the ogg multimedia container
69 format, which encapsulates raw compressed data and allows the interleaving of
70 audio and video data. In addition to encapsulation and interleaving of
71 multiple data streams, ogg provides packet framing, error detection, and
72 periodic timestamps for seeking.")
73 (license (license:non-copyleft "file://COPYING"
74 "See COPYING in the distribution."))
75 (home-page "http://xiph.org/ogg/")))
76
77 (define libvorbis
78 (package
79 (name "libvorbis")
80 (version "1.3.5")
81 (source (origin
82 (method url-fetch)
83 (uri (string-append "http://downloads.xiph.org/releases/vorbis/"
84 "libvorbis-" version ".tar.xz"))
85 (sha256
86 (base32
87 "1lg1n3a6r41492r7in0fpvzc7909mc5ir9z0gd3qh2pz4yalmyal"))))
88 (build-system gnu-build-system)
89 (propagated-inputs `(("libogg" ,libogg)))
90 (arguments `(#:configure-flags '("LDFLAGS=-lm")
91 #:parallel-tests? #f))
92 (synopsis "Library implementing the vorbis audio format")
93 (description
94 "The libvorbis library implements the ogg vorbis audio format,
95 a fully open, non-proprietary, patent-and-royalty-free, general-purpose
96 compressed audio format for mid to high quality (8kHz-48.0kHz, 16+ bit,
97 polyphonic) audio and music at fixed and variable bitrates from 16 to
98 128 kbps/channel.")
99 (license (license:non-copyleft "file://COPYING"
100 "See COPYING in the distribution."))
101 (home-page "http://xiph.org/vorbis/")))
102
103 (define libtheora
104 (package
105 (name "libtheora")
106 (version "1.1.1")
107 (source (origin
108 (method url-fetch)
109 (uri (string-append "http://downloads.xiph.org/releases/theora/"
110 "libtheora-" version ".tar.xz"))
111 (sha256
112 (base32
113 "0q8wark9ribij57dciym5vdikg2464p8q2mgqvfb78ksjh4s8vgk"))
114 (patches (search-patches "libtheora-config-guess.patch"))))
115 (build-system gnu-build-system)
116 (inputs `(("libvorbis" ,libvorbis)))
117 ;; The .pc files refer to libogg.
118 (propagated-inputs `(("libogg" ,libogg)))
119 (synopsis "Library implementing the Theora video format")
120 (description
121 "The libtheora library implements the ogg theora video format,
122 a fully open, non-proprietary, patent-and-royalty-free, general-purpose
123 compressed video format.")
124 (license license:bsd-3)
125 (home-page "http://xiph.org/theora/")))
126
127 (define speex
128 (package
129 (name "speex")
130 (version "1.2rc1")
131 (source
132 (origin
133 (method url-fetch)
134 (uri (string-append "http://downloads.xiph.org/releases/speex/speex-"
135 version ".tar.gz"))
136 (sha256
137 (base32
138 "19mpkhbz3s08snvndn0h1dk2j139max6b0rr86nnsjmxazf30brl"))))
139 (build-system gnu-build-system)
140 (inputs `(("libogg" ,libogg)))
141 (home-page "https://gnu.org/software/speex")
142 (synopsis "Library for patent-free audio compression format")
143 (description
144 "GNU Speex is a patent-free audio compression codec specially designed
145 for speech. It is well-adapted to internet applications, such as VoIP. It
146 features compression of different bands in the same bitstream, intensity
147 stereo encoding, and voice activity detection.")
148 ;; 'src/getopt.c' is under LGPLv2+
149 (license (license:non-copyleft "file://COPYING"
150 "See COPYING in the distribution."))))
151
152 (define ao
153 (package
154 (name "ao")
155 (version "1.2.0")
156 (source
157 (origin
158 (method url-fetch)
159 (uri (string-append "http://downloads.xiph.org/releases/ao/libao-"
160 version ".tar.gz"))
161 (sha256
162 (base32
163 "1bwwv1g9lchaq6qmhvj1pp3hnyqr64ydd4j38x94pmprs4d27b83"))))
164 (build-system gnu-build-system)
165 ;; FIXME: Add further backends, see the summary printed after configure.
166 ;; XXX: Should back-ends be pushed to different outputs? For instance,
167 ;; "out" would include only the ALSA back-end, while "pulse" would
168 ;; contain 'lib/ao/plugins-4/libpulse.*'.
169 (inputs
170 `(("alsa-lib" ,alsa-lib)
171 ("pulseaudio" ,pulseaudio)))
172 (native-inputs
173 `(("pkg-config" ,pkg-config)))
174 (synopsis "Cross platform audio library")
175 (description
176 "Libao is a cross-platform audio library that allows programs to
177 output audio using a simple API on a wide variety of platforms.
178 It currently supports:
179 @enumerate
180 @item Null output (handy for testing without a sound device),
181 @item WAV files,
182 @item AU files,
183 @item RAW files,
184 @item OSS (Open Sound System, used on Linux and FreeBSD),
185 @item ALSA (Advanced Linux Sound Architecture),
186 @item aRts (Analog RealTime Synth, used by KDE),
187 @item PulseAudio (next generation GNOME sound server),
188 @item esd (EsounD or Enlightened Sound Daemon),
189 @item Mac OS X,
190 @item Windows (98 and later),
191 @item AIX,
192 @item Sun/NetBSD/OpenBSD,
193 @item IRIX,
194 @item NAS (Network Audio Server),
195 @item RoarAudio (Modern, multi-OS, networked Sound System),
196 @item OpenBSD's sndio.
197 @end enumerate
198 ")
199 (license license:gpl2+)
200 (home-page "http://www.xiph.org/ao/")))
201
202 (define flac
203 (package
204 (name "flac")
205 (version "1.3.1")
206 (source (origin
207 (method url-fetch)
208 (uri (string-append "http://downloads.xiph.org/releases/flac/flac-"
209 version ".tar.xz"))
210 (sha256
211 (base32
212 "0v65w7ph6ldwp5a8fbhp0a3w8f737ck468fr7yb7sxmskl4w0ws7"))))
213 (build-system gnu-build-system)
214 (arguments
215 `(#:parallel-tests? #f))
216 ;; FIXME: configure also looks for xmms, input could be added once it exists
217 (propagated-inputs `(("libogg" ,libogg))) ; required by flac.pc
218 (synopsis "Free lossless audio codec")
219 (description
220 "FLAC stands for Free Lossless Audio Codec, an audio format that is lossless,
221 meaning that audio is compressed in FLAC without any loss in quality.")
222 (license (license:non-copyleft "file://COPYING"
223 "See COPYING in the distribution.")) ; and LGPL and GPL
224 (home-page "http://xiph.org/flac/")))
225
226 (define libkate
227 (package
228 (name "libkate")
229 (version "0.4.1")
230 (source (origin
231 (method url-fetch)
232 (uri (string-append "http://downloads.xiph.org/releases/kate/"
233 "libkate-" version ".tar.gz"))
234 (sha256
235 (base32
236 "0s3vr2nxfxlf1k75iqpp4l78yf4gil3f0v778kvlngbchvaq23n4"))))
237 (build-system gnu-build-system)
238 (native-inputs `(("doxygen" ,doxygen)
239 ("pkg-config" ,pkg-config)))
240 ;; FIXME: Add optional input liboggz
241 (inputs `(("bison" ,bison)
242 ("libogg" ,libogg)
243 ("libpng" ,libpng)
244 ("python" ,python-wrapper)
245 ("zlib" ,zlib)))
246 (synopsis "Karaoke and text codec for embedding in ogg")
247 (description
248 "Kate is an overlay codec, originally designed for karaoke and text,
249 that can be multiplixed in Ogg. Text and images can be carried by a Kate
250 stream, and animated. Most of the time, this would be multiplexed with
251 audio/video to carry subtitles, song lyrics (with or without karaoke data),
252 etc., but doesn't have to be.
253
254 Series of curves (splines, segments, etc.) may be attached to various
255 properties (text position, font size, etc.) to create animated overlays.
256 This allows scrolling or fading text to be defined. This can even be used
257 to draw arbitrary shapes, so hand drawing can also be represented by a
258 Kate stream.")
259 (license license:bsd-3)
260 (home-page "https://wiki.xiph.org/OggKate")))
261
262 (define vorbis-tools
263 (package
264 (name "vorbis-tools")
265 (version "1.4.0")
266 (source (origin
267 (method url-fetch)
268 (uri (string-append "http://downloads.xiph.org/releases/vorbis/"
269 "vorbis-tools-" version ".tar.gz"))
270 (sha256
271 (base32
272 "1g12bnh5ah08v529y72kfdz5lhvy75iaz7f9jskyby23m9dkk2d3"))
273 (patches (search-patches
274 "vorbis-tools-CVE-2014-9638+CVE-2014-9639.patch"
275 "vorbis-tools-CVE-2014-9640.patch"
276 "vorbis-tools-CVE-2015-6749.patch"))))
277 (build-system gnu-build-system)
278 (inputs `(("ao" ,ao)
279 ("curl" ,curl)
280 ("flac" ,flac)
281 ("libkate" ,libkate)
282 ("libogg" ,libogg)
283 ("libvorbis" ,libvorbis)
284 ("speex" ,speex)))
285 (native-inputs `(("pkg-config" ,pkg-config)))
286 (synopsis "Ogg vorbis tools")
287 (description
288 "Ogg vorbis is a non-proprietary, patent-and-royalty-free,
289 general-purpose compressed audio format.
290
291 The package vorbis-tools contains
292 ogg123, an ogg vorbis command line audio player;
293 oggenc, the ogg vorbis encoder;
294 oggdec, a simple, portable command line decoder (to wav and raw);
295 ogginfo, to obtain information (tags, bitrate, length, etc.) about
296 an ogg vorbis file.")
297 (license license:gpl2)
298 (home-page "http://xiph.org/vorbis/")))
299
300 (define opus
301 (package
302 (name "opus")
303 (version "1.1.4")
304 (source (origin
305 (method url-fetch)
306 (uri (string-append
307 "http://downloads.xiph.org/releases/opus/opus-" version
308 ".tar.gz"))
309 (sha256
310 (base32
311 "14l6kpapmcnvl7p9hrmbqcnzj13zfzyppyc9a5kd4788h2rvc8li"))))
312 (build-system gnu-build-system)
313 (synopsis "Versatile audio codec")
314 (description
315 "Opus is a totally open, royalty-free, highly versatile audio codec. Opus
316 is unmatched for interactive speech and music transmission over the Internet,
317 but is also intended for storage and streaming applications. It is
318 standardized by the Internet Engineering Task Force (IETF) as RFC 6716 which
319 incorporated technology from Skype's SILK codec and Xiph.Org's CELT codec.")
320 (license license:bsd-3)
321 (home-page "http://www.opus-codec.org")))
322
323 (define opus-tools
324 (package
325 (name "opus-tools")
326 (version "0.1.9")
327 (source (origin
328 (method url-fetch)
329 (uri (string-append
330 "http://downloads.xiph.org/releases/opus/opus-tools-"
331 version ".tar.gz"))
332 (sha256
333 (base32
334 "0fk4nknvl111k89j5yckmyrh6b2wvgyhrqfncp7rig3zikbkv1xi"))))
335 (build-system gnu-build-system)
336 (arguments
337 ;; The package developers misuse pkg-config such that it doesn't work
338 ;; when cross compiling. Therefore we avoid it completly and set the
339 ;; necessary flags ourselves.
340 `(#:configure-flags (list (string-append "CFLAGS=-I"
341 (assoc-ref %build-inputs "libogg")
342 "/include -I"
343 (assoc-ref %build-inputs "opus")
344 "/include/opus"))))
345 (inputs `(("libogg" ,libogg)
346 ("opus" ,opus)
347 ("flac" ,flac)))
348 (synopsis
349 "Command line utilities to encode, inspect, and decode .opus files")
350 (description "Opus is a royalty-free, highly versatile audio codec.
351 Opus-tools provide command line utilities for creating, inspecting and
352 decoding .opus files.")
353 (license license:bsd-3)
354 (home-page "http://www.opus-codec.org")))
355
356 (define opusfile
357 (package
358 (name "opusfile")
359 (version "0.8")
360 (source (origin
361 (method url-fetch)
362 (uri (string-append
363 "http://downloads.xiph.org/releases/opus/opusfile-" version
364 ".tar.gz"))
365 (sha256
366 (base32
367 "192mp2jgn5s9815h31ybzsfipmbppmdhwx1dymrk26xarz9iw8rc"))))
368 (build-system gnu-build-system)
369 (propagated-inputs
370 `(("opus" ,opus)))
371 (native-inputs
372 `(("pkg-config" ,pkg-config)))
373 (inputs
374 `(("libogg" ,libogg)
375 ("openssl" ,openssl)))
376 (synopsis "Versatile audio codec")
377 (description
378 "The opusfile library provides seeking, decode, and playback of Opus
379 streams in the Ogg container (.opus files) including over http(s) on posix and
380 windows systems.")
381 (license license:bsd-3)
382 (home-page "http://www.opus-codec.org")))
383
384 (define-public icecast
385 (package
386 (name "icecast")
387 (version "2.4.3")
388 (source (origin
389 (method url-fetch)
390 (uri (string-append
391 "http://downloads.xiph.org/releases/icecast/icecast-"
392 version ".tar.gz"))
393 (sha256
394 (base32
395 "14n5vm2xnyn8y7kl46lnnlgv6v5fjykhc57ffdsh0qaxfs6a8p68"))))
396 (build-system gnu-build-system)
397 (native-inputs
398 `(("pkg-config" ,pkg-config)))
399 (inputs
400 `(("libxslt" ,libxslt)
401 ("libxml2" ,libxml2)
402 ("openssl" ,openssl)
403 ("curl" ,curl)
404 ("libogg" ,libogg)
405 ("libvorbis" ,libvorbis)
406 ("libtheora" ,libtheora)
407 ("speex" ,speex)))
408 (synopsis "Streaming media server")
409 (description "Icecast is a streaming media server which currently supports
410 Ogg (Vorbis and Theora), Opus, WebM and MP3 audio streams. It can be used to
411 create an Internet radio station or a privately running jukebox and many
412 things in between.")
413 (home-page "http://icecast.org/")
414 (license license:gpl2)))
415
416 (define-public libshout
417 (package
418 (name "libshout")
419 (version "2.4.1")
420 (source (origin
421 (method url-fetch)
422 (uri (string-append
423 "http://downloads.xiph.org/releases/libshout/"
424 name "-" version ".tar.gz"))
425 (sha256
426 (base32
427 "0kgjpf8jkgyclw11nilxi8vyjk4s8878x23qyxnvybbgqbgbib7k"))))
428 (build-system gnu-build-system)
429 (native-inputs
430 `(("pkg-config" ,pkg-config)))
431 (propagated-inputs
432 ;; shout.pc refers to all these.
433 `(("libtheora" ,libtheora)
434 ("libvorbis" ,libvorbis)
435 ("speex" ,speex)))
436 (home-page "http://www.icecast.org/")
437 (synopsis "Audio streaming library for icecast encoders")
438 (description
439 "Libshout is a library for communicating with and sending data to an
440 icecast server. It handles the socket connection, the timing of the data,
441 and prevents bad data from getting to the icecast server.")
442 (license license:gpl2+)))