gnu: gst-plugins-ugly: Update to 1.8.2.
[jackhill/guix/guix.git] / gnu / packages / gstreamer.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2014 John Darrington <jmd@gnu.org>
4 ;;; Copyright © 2015, 2016 Sou Bunnbu <iyzsong@gmail.com>
5 ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
6 ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
7 ;;;
8 ;;; This file is part of GNU Guix.
9 ;;;
10 ;;; GNU Guix is free software; you can redistribute it and/or modify it
11 ;;; under the terms of the GNU General Public License as published by
12 ;;; the Free Software Foundation; either version 3 of the License, or (at
13 ;;; your option) any later version.
14 ;;;
15 ;;; GNU Guix is distributed in the hope that it will be useful, but
16 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;;; GNU General Public License for more details.
19 ;;;
20 ;;; You should have received a copy of the GNU General Public License
21 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
22
23 (define-module (gnu packages gstreamer)
24 #:use-module ((guix licenses) #:select (lgpl2.0+ lgpl2.1+ bsd-2 bsd-3 gpl2+))
25 #:use-module (guix packages)
26 #:use-module (guix download)
27 #:use-module (guix build-system gnu)
28 #:use-module (guix utils)
29 #:use-module (gnu packages)
30 #:use-module (gnu packages audio)
31 #:use-module (gnu packages bison)
32 #:use-module (gnu packages cdrom)
33 #:use-module (gnu packages curl)
34 #:use-module (gnu packages compression)
35 #:use-module (gnu packages flex)
36 #:use-module (gnu packages freedesktop)
37 #:use-module (gnu packages gl)
38 #:use-module (gnu packages glib)
39 #:use-module (gnu packages gnome)
40 #:use-module (gnu packages gnupg)
41 #:use-module (gnu packages graphics)
42 #:use-module (gnu packages gtk)
43 #:use-module (gnu packages image)
44 #:use-module (gnu packages libusb)
45 #:use-module (gnu packages linux)
46 #:use-module (gnu packages mp3)
47 #:use-module (gnu packages perl)
48 #:use-module (gnu packages pulseaudio)
49 #:use-module (gnu packages qt)
50 #:use-module (gnu packages rdf)
51 #:use-module (gnu packages video)
52 #:use-module (gnu packages xorg)
53 #:use-module (gnu packages xiph)
54 #:use-module (gnu packages pkg-config)
55 #:use-module (gnu packages python)
56 #:use-module (gnu packages ssh)
57 #:use-module (gnu packages telephony)
58 #:use-module (gnu packages tls)
59 #:use-module (gnu packages version-control)
60 #:use-module (gnu packages assembly)
61 #:use-module (gnu packages xml))
62
63 (define-public orc
64 (package
65 (name "orc")
66 (version "0.4.25")
67 (source (origin
68 (method url-fetch)
69 (uri (string-append "https://gstreamer.freedesktop.org/data/src/"
70 "orc/orc-" version ".tar.xz"))
71 (sha256
72 (base32
73 "1lak3hyvvb0w9avzmf0a8vayb7vqhj4m709q1czlhvgjb15dbcf1"))))
74 (build-system gnu-build-system)
75 (arguments `(#:phases
76 (alist-cons-before
77 'check 'disable-faulty-test
78 (lambda _
79 ;; XXX Disable the 'test-limits' and 'exec_opcodes_sys'
80 ;; tests, which fail on some machines. See:
81 ;; https://bugzilla.gnome.org/show_bug.cgi?id=735273
82 (substitute* '("testsuite/test-limits.c"
83 "testsuite/exec_opcodes_sys.c")
84 (("if \\(error\\) return 1;")
85 "if (error) return 77;")))
86 %standard-phases)))
87 (home-page "http://code.entropywave.com/orc/")
88 (synopsis "Oil runtime compiler")
89 (description
90 "Orc is a just-in-time compiler implemented as a library and set of
91 associated tools for compiling and executing simple programs that operate on
92 arrays of data.")
93 ;; The source code implementing the Marsenne Twister algorithm is licensed
94 ;; under the 3-clause BSD license, the rest is under 2-clause BSD license.
95 (license (list bsd-2 bsd-3))))
96
97 (define-public gstreamer
98 (package
99 (name "gstreamer")
100 (version "1.8.2")
101 (source
102 (origin
103 (method url-fetch)
104 (uri (string-append
105 "https://gstreamer.freedesktop.org/src/gstreamer/gstreamer-"
106 version ".tar.xz"))
107 (sha256
108 (base32
109 "0hc3j684nx209p10ampvnkza3gna2yiryr7jyx701ciakh3vxglx"))))
110 (build-system gnu-build-system)
111 (outputs '("out" "doc"))
112 (arguments
113 `(#:configure-flags
114 (list (string-append "--with-html-dir="
115 (assoc-ref %outputs "doc")
116 "/share/gtk-doc/html"))))
117 (propagated-inputs `(("glib" ,glib))) ; required by gstreamer-1.0.pc.
118 (native-inputs
119 `(("bison" ,bison)
120 ("flex" ,flex)
121 ("glib" ,glib "bin")
122 ("gobject-introspection" ,gobject-introspection)
123 ("perl" ,perl)
124 ("pkg-config" ,pkg-config)
125 ("python-wrapper" ,python-wrapper)))
126 (native-search-paths
127 (list (search-path-specification
128 (variable "GST_PLUGIN_SYSTEM_PATH")
129 (files '("lib/gstreamer-1.0")))))
130 (home-page "https://gstreamer.freedesktop.org/")
131 (synopsis "Multimedia library")
132 (description
133 "GStreamer is a library for constructing graphs of media-handling
134 components. The applications it supports range from simple Ogg/Vorbis
135 playback, audio/video streaming to complex audio mixing and video
136 non-linear editing.
137
138 Applications can take advantage of advances in codec and filter technology
139 transparently. Developers can add new codecs and filters by writing a
140 simple plugin with a clean, generic interface.
141
142 This package provides the core library and elements.")
143 (license lgpl2.0+)))
144
145 (define-public gst-plugins-base
146 (package
147 (name "gst-plugins-base")
148 (version "1.8.2")
149 (source
150 (origin
151 (method url-fetch)
152 (uri (string-append "https://gstreamer.freedesktop.org/src/" name "/"
153 name "-" version ".tar.xz"))
154 (sha256
155 (base32
156 "13fk751vvfrfhbm4ip28vxyvlsm4b4y0bc0pvf7fqp8azg40jwcx"))))
157 (build-system gnu-build-system)
158 (outputs '("out" "doc"))
159 (propagated-inputs
160 `(("gstreamer" ,gstreamer))) ; required by gstreamer-plugins-base-1.0.pc
161 (inputs
162 `(("cdparanoia" ,cdparanoia)
163 ("orc" ,orc)
164 ("pango" ,pango)
165 ("libogg" ,libogg)
166 ("libtheora" ,libtheora)
167 ("libvorbis" ,libvorbis)
168 ("libx11" ,libx11)
169 ("zlib" ,zlib)
170 ("libXext" ,libxext)
171 ("libxv" ,libxv)
172 ("alsa-lib" ,alsa-lib)))
173 (native-inputs
174 `(("pkg-config" ,pkg-config)
175 ("glib" ,glib "bin")
176 ("gobject-introspection" ,gobject-introspection)
177 ("python-wrapper" ,python-wrapper)))
178 (arguments
179 `(#:parallel-tests? #f ; 'pipelines/tcp' fails in parallel
180 #:configure-flags
181 (list (string-append "--with-html-dir="
182 (assoc-ref %outputs "doc")
183 "/share/gtk-doc/html"))
184 #:phases
185 (modify-phases %standard-phases
186 (add-before 'configure 'patch
187 (lambda _
188 (substitute* "tests/check/libs/pbutils.c"
189 (("/bin/sh") (which "sh"))))))))
190 (home-page "https://gstreamer.freedesktop.org/")
191 (synopsis
192 "Plugins for the GStreamer multimedia library")
193 (description "This package provides an essential exemplary set of plug-ins
194 for the GStreamer multimedia library.")
195 (license lgpl2.0+)))
196
197
198 (define-public gst-plugins-good
199 (package
200 (name "gst-plugins-good")
201 (version "1.8.2")
202 (source
203 (origin
204 (method url-fetch)
205 (uri (string-append
206 "https://gstreamer.freedesktop.org/src/" name "/"
207 name "-" version ".tar.xz"))
208 (sha256
209 (base32
210 "0i1rlbbx3m6ykvcdyaidsd8wa2b7nq2qmcvbrsg00yivi88ljxcd"))))
211 (build-system gnu-build-system)
212 (inputs
213 `(("aalib" ,aalib)
214 ("cairo" ,cairo)
215 ("flac" ,flac)
216 ("gdk-pixbuf" ,gdk-pixbuf)
217 ("gst-plugins-base" ,gst-plugins-base)
218 ("jack" ,jack-1)
219 ("libavc1394" ,libavc1394)
220 ("libcaca" ,libcaca)
221 ("libdv" ,libdv)
222 ("libiec61883" ,libiec61883)
223 ("libjpeg" ,libjpeg)
224 ("libpng" ,libpng)
225 ("libshout" ,libshout)
226 ("libsoup" ,libsoup)
227 ("libvpx" ,libvpx)
228 ("orc" ,orc)
229 ("pulseaudio" ,pulseaudio)
230 ("speex" ,speex)
231 ("taglib" ,taglib)
232 ("wavpack" ,wavpack)))
233 (native-inputs
234 `(("glib:bin" ,glib "bin")
235 ("pkg-config" ,pkg-config)
236 ("python-wrapper" ,python-wrapper)))
237 (arguments
238 `(#:phases
239 (modify-phases %standard-phases
240 (add-after
241 'unpack 'disable-failing-tests
242 (lambda _
243 ;; Disable tests that fail non-deterministically.
244 ;; XXX FIXME: Try removing this for version > 1.8.0.
245 (substitute* "tests/check/elements/rtprtx.c"
246 (("tcase_add_test \\(tc_chain, test_push_forward_seq\\);" all)
247 (string-append "/* " all " */"))
248 (("tcase_add_test \
249 \\(tc_chain, test_rtxreceive_data_reconstruction\\);" all)
250 (string-append "/* " all " */")))
251 (substitute* "tests/check/elements/splitmux.c"
252 (("tcase_add_test \\(tc_chain, test_splitmuxsink\\);" all)
253 (string-append "/* " all " */")))
254 #t)))))
255 (home-page "https://gstreamer.freedesktop.org/")
256 (synopsis
257 "Plugins for the GStreamer multimedia library")
258 (description "GStreamer Good Plug-ins is a set of plug-ins for the
259 GStreamer multimedia library. This set contains those plug-ins which the
260 developers consider to have good quality code and correct functionality.")
261 (license lgpl2.0+)))
262
263 (define-public gst-plugins-bad
264 (package
265 (name "gst-plugins-bad")
266 (version "1.6.3")
267 (source (origin
268 (method url-fetch)
269 (uri (string-append "https://gstreamer.freedesktop.org/src/"
270 name "/" name "-" version ".tar.xz"))
271 (sha256
272 (base32
273 "0q9s5da54819gwncmdi95l5qzx97l9vxk6adx4zmx73a3l82j6wp"))))
274 (outputs '("out" "doc"))
275 (build-system gnu-build-system)
276 (arguments
277 '(#:tests? #f ; XXX: 11 of 54 tests fail
278 #:configure-flags
279 (list (string-append "--with-html-dir="
280 (assoc-ref %outputs "doc")
281 "/share/gtk-doc/html"))))
282 (propagated-inputs
283 `(("gst-plugins-base" ,gst-plugins-base)))
284 (native-inputs
285 `(("glib:bin" ,glib "bin") ; for glib-mkenums, etc.
286 ("gobject-introspection" ,gobject-introspection)
287 ("pkg-config" ,pkg-config)
288 ("python" ,python)))
289 (inputs
290 ;; XXX: The following dependencies are missing:
291 ;; vo-amrwbenc, vo-aacenc, bs2b, chromaprint, directfb, daala, libdts,
292 ;; faac, flite, libgsm, libde265, libmms, libmimic, mjpegtools,
293 ;; mpeg2enc, libofa, opencv, openh264, openni2, libtimemmgr, wildmidi,
294 ;; openspc, gme, sbc, schroedinger, zbar, librtmp, spandsp, x265
295 `(("bluez" ,bluez)
296 ("curl" ,curl)
297 ("faad2" ,faad2)
298 ("fluidsynth" ,fluidsynth)
299 ("gtk+" ,gtk+)
300 ("ladspa" ,ladspa)
301 ("libass" ,libass)
302 ("libdvdnav" ,libdvdnav)
303 ("libdvdread" ,libdvdread)
304 ("libgcrypt" ,libgcrypt)
305 ("libgudev" ,libgudev)
306 ("libkate" ,libkate)
307 ("libmodplug" ,libmodplug)
308 ("librsvg" ,librsvg)
309 ("libsndfile" ,libsndfile)
310 ("libsrtp" ,libsrtp)
311 ("libssh2" ,libssh2)
312 ("libusb" ,libusb)
313 ("libvdpau" ,libvdpau)
314 ("libwebp" ,libwebp)
315 ("libxml2" ,libxml2)
316 ("lrdf" ,lrdf)
317 ("mesa" ,mesa)
318 ("mpg123" ,mpg123)
319 ("neon" ,neon)
320 ("openal" ,openal)
321 ("openexr" ,openexr)
322 ("openjpeg" ,openjpeg)
323 ("openssl" ,openssl)
324 ("opus" ,opus)
325 ("orc" ,orc)
326 ("qt" ,qt)
327 ("soundtouch" ,soundtouch)
328 ("wayland" ,wayland)))
329 (home-page "http://gstreamer.freedesktop.org/")
330 (synopsis "Plugins for the GStreamer multimedia library")
331 (description
332 "GStreamer Bad Plug-ins is a set of plug-ins whose quality aren't up to
333 par compared to the rest.")
334 (license lgpl2.0+)))
335
336 (define-public gst-plugins-ugly
337 (package
338 (name "gst-plugins-ugly")
339 (version "1.8.2")
340 (source
341 (origin
342 (method url-fetch)
343 (uri (string-append "https://gstreamer.freedesktop.org/src/"
344 name "/" name "-" version ".tar.xz"))
345 (sha256
346 (base32
347 "1b58s7z430cbbaw8mgy87kslbpmj3xmm66wsr7bddhcgm6i36nww"))))
348 (build-system gnu-build-system)
349 (inputs
350 `(("gst-plugins-base" ,gst-plugins-base)
351 ("liba52" ,liba52)
352 ("libmad" ,libmad)
353 ("lame" ,lame)
354 ("libcdio" ,libcdio)
355 ("twolame" ,twolame)
356 ("libmpeg2" ,libmpeg2)
357 ("libdvdread" ,libdvdread)
358 ("libx264" ,libx264)
359 ;; TODO:
360 ;; * opencore-amr (for the AMR-NB decoder and encoder and the
361 ;; AMR-WB decoder) <http://sourceforge.net/projects/opencore-amr/>
362 ("orc" ,orc)))
363 (native-inputs
364 `(("glib:bin" ,glib "bin")
365 ("pkg-config" ,pkg-config)
366 ("python-wrapper" ,python-wrapper)))
367 (home-page "https://gstreamer.freedesktop.org/")
368 (synopsis "GStreamer plugins from the \"ugly\" set")
369 (description "GStreamer Ugly Plug-ins. This set contains those plug-ins
370 which the developers consider to have good quality code but that might pose
371 distribution problems in some jurisdictions, e.g. due to patent threats.")
372 (license lgpl2.0+)))
373
374 (define-public gst-libav
375 (package
376 (name "gst-libav")
377 (version "1.8.0")
378 (source (origin
379 (method url-fetch)
380 (uri (string-append
381 "https://gstreamer.freedesktop.org/src/" name "/"
382 name "-" version ".tar.xz"))
383 (sha256
384 (base32
385 "0719njp8aarhvn038pijq6dmsnli0zlg146hyfs3rsdffs4f472s"))))
386 (build-system gnu-build-system)
387 (arguments
388 '(#:configure-flags '("--with-system-libav")
389 #:phases
390 (modify-phases %standard-phases
391 (add-before 'configure 'patch-/bin/sh
392 (lambda _
393 (substitute* "gst-libs/ext/libav/configure"
394 (("#! /bin/sh")
395 (string-append "#! "(which "sh")))))))))
396 (native-inputs
397 `(("pkg-config" ,pkg-config)
398 ("python" ,python)))
399 (inputs
400 `(("gst-plugins-base" ,gst-plugins-base)
401 ("ffmpeg" ,ffmpeg)
402 ("orc" ,orc)
403 ("zlib" ,zlib)))
404 (home-page "http://gstreamer.freedesktop.org/")
405 (synopsis "Plugins for the GStreamer multimedia library")
406 (description
407 "This GStreamer plugin supports a large number of audio and video
408 compression formats through the use of the libav library.")
409 (license gpl2+)))
410
411 (define-public python-gst
412 (package
413 (name "python-gst")
414 (version "1.8.0")
415 (source (origin
416 (method url-fetch)
417 (uri (string-append
418 "https://gstreamer.freedesktop.org/src/gst-python/"
419 "gst-python-" version ".tar.xz"))
420 (sha256
421 (base32
422 "1spn49x7yaj69df6mxh9wwcs0y3abswkfpk84njs71lzqlbzyiff"))))
423 (build-system gnu-build-system)
424 (arguments
425 ;; XXX: Factorize python-sitedir with python-build-system.
426 `(#:imported-modules (,@%gnu-build-system-modules
427 (guix build python-build-system))
428 #:configure-flags
429 (let* ((python (assoc-ref %build-inputs "python"))
430 (python-version ((@@ (guix build python-build-system)
431 get-python-version)
432 python))
433 (python-sitedir (string-append
434 "lib/python" python-version "/site-packages")))
435 (list (string-append
436 "--with-pygi-overrides-dir=" %output "/" python-sitedir
437 "/gi/overrides")))))
438 (native-inputs
439 `(("pkg-config" ,pkg-config)
440 ("python" ,python)))
441 (propagated-inputs
442 `(("gst-plugins-base" ,gst-plugins-base)
443 ("python-pygobject" ,python-pygobject)))
444 (home-page "https://gstreamer.freedesktop.org/")
445 (synopsis "GStreamer GObject Introspection overrides for Python")
446 (description
447 "This package contains GObject Introspection overrides for Python that can
448 be used by Python applications using GStreamer.")
449 (license lgpl2.1+)
450 (properties `((python2-variant . ,(delay python2-gst))))))
451
452 (define-public python2-gst
453 (package (inherit python-gst)
454 (name "python2-gst")
455 (native-inputs
456 `(("pkg-config" ,pkg-config)
457 ("python" ,python-2)))
458 (propagated-inputs
459 `(("gst-plugins-base" ,gst-plugins-base)
460 ("python-pygobject" ,python2-pygobject)))))