gnu: openvpn: Update to 2.4.6.
[jackhill/guix/guix.git] / gnu / packages / video.scm
CommitLineData
39efcc9b 1;;; GNU Guix --- Functional package management for GNU
71ee51a0 2;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
945d985a 3;;; Copyright © 2014, 2015, 2016 David Thompson <davet@gnu.org>
ca3f9952 4;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
cda163cd 5;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
1373ce7c 6;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
12f92e38 7;;; Copyright © 2015 Andy Patterson <ajpatter@uwaterloo.ca>
307ad140 8;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
e61da2e8 9;;; Copyright © 2015, 2016, 2017, 2018 Alex Vong <alexvong1995@gmail.com>
2b841707 10;;; Copyright © 2016, 2017 Alex Griffin <a@ajgrf.com>
3c8ba11a 11;;; Copyright © 2016 Kei Kebreau <kkebreau@posteo.net>
ed6ba9cc 12;;; Copyright © 2016 Dmitry Nikolaev <cameltheman@gmail.com>
4df07622 13;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca>
4a78fd46 14;;; Copyright © 2016, 2017 Nils Gillmann <ng0@n0.is>
fe047e13 15;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
590abe01 16;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
72fa6667 17;;; Copyright © 2017 Feng Shu <tumashu@163.com>
50b97d1a 18;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
794223bc 19;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com>
b5b20bda 20;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
e0c40707 21;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
eb88e2c1 22;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org>
2973ebf5 23;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
8bbd4b01 24;;; Copyright © 2017, 2018 Rutger Helling <rhelling@mykolab.com>
e21f3473 25;;; Copyright © 2018 Roel Janssen <roel@gnu.org>
e896c227 26;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com>
f27f264e 27;;; Copyright © 2018 Pierre Neidhardt <ambrevar@gmail.com>
39efcc9b
AE
28;;;
29;;; This file is part of GNU Guix.
30;;;
31;;; GNU Guix is free software; you can redistribute it and/or modify it
32;;; under the terms of the GNU General Public License as published by
33;;; the Free Software Foundation; either version 3 of the License, or (at
34;;; your option) any later version.
35;;;
36;;; GNU Guix is distributed in the hope that it will be useful, but
37;;; WITHOUT ANY WARRANTY; without even the implied warranty of
38;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
39;;; GNU General Public License for more details.
40;;;
41;;; You should have received a copy of the GNU General Public License
42;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
43
44(define-module (gnu packages video)
fe138965 45 #:use-module (ice-9 match)
08858812 46 #:use-module (srfi srfi-1)
ae0bdd81 47 #:use-module ((guix licenses) #:prefix license:)
e930c2a3 48 #:use-module (guix utils)
39efcc9b
AE
49 #:use-module (guix packages)
50 #:use-module (guix download)
38829eac 51 #:use-module (guix git-download)
d8841cc5 52 #:use-module (guix svn-download)
44726031 53 #:use-module (guix build-system cmake)
39efcc9b 54 #:use-module (guix build-system gnu)
0e74bb5b 55 #:use-module (guix build-system glib-or-gtk)
635f981b 56 #:use-module (guix build-system meson)
6f45e45d 57 #:use-module (guix build-system perl)
615215a5 58 #:use-module (guix build-system python)
1c1178cd 59 #:use-module (guix build-system waf)
f27f264e 60 #:use-module (guix build-system trivial)
3b02429c 61 #:use-module (gnu packages)
39efcc9b 62 #:use-module (gnu packages algebra)
72bfebf5 63 #:use-module (gnu packages audio)
f1044010 64 #:use-module (gnu packages autotools)
d5a748e8 65 #:use-module (gnu packages avahi)
38829eac 66 #:use-module (gnu packages base)
8dd6fc51 67 #:use-module (gnu packages bison)
2973ebf5 68 #:use-module (gnu packages boost)
d5a748e8 69 #:use-module (gnu packages cdrom)
2973ebf5 70 #:use-module (gnu packages check)
fe047e13 71 #:use-module (gnu packages cmake)
39efcc9b 72 #:use-module (gnu packages compression)
e0c40707 73 #:use-module (gnu packages cpp)
f464016d 74 #:use-module (gnu packages curl)
44726031 75 #:use-module (gnu packages databases)
3a44c7bb 76 #:use-module (gnu packages dejagnu)
2973ebf5 77 #:use-module (gnu packages docbook)
e37bdc0f 78 #:use-module (gnu packages documentation)
f22e0e26 79 #:use-module (gnu packages elf)
2973ebf5 80 #:use-module (gnu packages file)
8dd6fc51 81 #:use-module (gnu packages flex)
39efcc9b 82 #:use-module (gnu packages fontutils)
c161c22a 83 #:use-module (gnu packages freedesktop)
44726031
AE
84 #:use-module (gnu packages fribidi)
85 #:use-module (gnu packages gettext)
38829eac 86 #:use-module (gnu packages ghostscript)
d5a748e8
AE
87 #:use-module (gnu packages gl)
88 #:use-module (gnu packages glib)
2cd85cf9 89 #:use-module (gnu packages guile)
fe047e13 90 #:use-module (gnu packages gnome)
d5a748e8 91 #:use-module (gnu packages gnupg)
fe047e13 92 #:use-module (gnu packages gstreamer)
44726031 93 #:use-module (gnu packages gtk)
e55354b8 94 #:use-module (gnu packages image)
b5b20bda 95 #:use-module (gnu packages imagemagick)
f48feaa2 96 #:use-module (gnu packages iso-codes)
c812f460 97 #:use-module (gnu packages libreoffice)
d5a748e8
AE
98 #:use-module (gnu packages linux)
99 #:use-module (gnu packages lua)
fe047e13 100 #:use-module (gnu packages m4)
3a44c7bb 101 #:use-module (gnu packages man)
d5a748e8 102 #:use-module (gnu packages mp3)
4d94b93c 103 #:use-module (gnu packages ncurses)
6f6c8b65 104 #:use-module (gnu packages ocr)
39efcc9b
AE
105 #:use-module (gnu packages perl)
106 #:use-module (gnu packages pkg-config)
a7d94b54 107 #:use-module (gnu packages popt)
d5a748e8 108 #:use-module (gnu packages pulseaudio)
39efcc9b 109 #:use-module (gnu packages python)
f48feaa2 110 #:use-module (gnu packages python-crypto)
589e3f4e 111 #:use-module (gnu packages python-web)
d5a748e8 112 #:use-module (gnu packages qt)
2973ebf5 113 #:use-module (gnu packages ruby)
d5a748e8 114 #:use-module (gnu packages sdl)
2973ebf5
GG
115 #:use-module (gnu packages serialization)
116 #:use-module (gnu packages shells)
d5a748e8 117 #:use-module (gnu packages ssh)
6b2c6be0 118 #:use-module (gnu packages texinfo)
c426e61e 119 #:use-module (gnu packages textutils)
a7fd7b68 120 #:use-module (gnu packages tls)
d5a748e8 121 #:use-module (gnu packages version-control)
870541d6 122 #:use-module (gnu packages vulkan)
bb470bd3 123 #:use-module (gnu packages web)
fe047e13 124 #:use-module (gnu packages webkit)
794223bc 125 #:use-module (gnu packages wxwidgets)
ee3b55ea 126 #:use-module (gnu packages xdisorg)
54ff0b7d 127 #:use-module (gnu packages xiph)
d5a748e8
AE
128 #:use-module (gnu packages xml)
129 #:use-module (gnu packages xorg)
148585c2 130 #:use-module (gnu packages assembly))
39efcc9b 131
6b2c6be0
SB
132(define-public aalib
133 (package
134 (name "aalib")
135 (version "1.4rc5")
136 (source (origin
137 (method url-fetch)
de67e922
LF
138 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
139 version "/" name "-" version ".tar.gz"))
6b2c6be0
SB
140 (sha256
141 (base32
142 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
143 (build-system gnu-build-system)
144 (native-inputs
145 `(("makeinfo" ,texinfo)))
146 (inputs
147 `(("ncurses" ,ncurses)))
148 (arguments
c437922a 149 `(#:phases
6b2c6be0 150 (modify-phases %standard-phases
3a4de6b2 151 (replace 'configure
014cbde6 152 (lambda* (#:key build inputs outputs #:allow-other-keys)
6b2c6be0
SB
153 ;; This old `configure' script doesn't support
154 ;; variables passed as arguments.
155 (let ((out (assoc-ref outputs "out"))
156 (ncurses (assoc-ref inputs "ncurses")))
157 (setenv "CONFIG_SHELL" (which "bash"))
158 (zero? (system* "./configure"
159 (string-append "--prefix=" out)
014cbde6 160 (string-append "--build=" build)
c437922a
MW
161 ;; The ancient config.guess is unable to
162 ;; guess the host triplet on mips64el.
163 ,@(if (string=? "mips64el-linux"
164 (%current-system))
165 '("--host=mips64el-unknown-linux-gnu")
166 '())
64465558
EF
167 ;; The same is also true with aarch64.
168 ,@(if (string=? "aarch64-linux"
169 (%current-system))
170 '("--host=aarch64-unknown-linux-gnu")
171 '())
6b2c6be0
SB
172 (string-append "--with-ncurses="
173 ncurses)))))))))
174 (home-page "http://aa-project.sourceforge.net/aalib/")
175 (synopsis "ASCII-art library")
176 (description
177 "AA-lib is a low level gfx library which does not require graphics device.
178In fact, there is no graphical output possible. AA-lib replaces those
179old-fashioned output methods with powerful ascii-art renderer.")
180 (license license:lgpl2.0+)))
181
cda163cd
TUBK
182(define-public liba52
183 (package
184 (name "liba52")
185 (version "0.7.4")
186 (source (origin
187 (method url-fetch)
8c056935
TUBK
188 (uri (string-append
189 ;; A mirror://sourceforge URI doesn't work, presumably
190 ;; because the SourceForge project is misconfigured.
191 "http://liba52.sourceforge.net/files/a52dec-" version
192 ".tar.gz"))
cda163cd
TUBK
193 (sha256
194 (base32
23da88f6 195 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
fc1adab1
AK
196 (patches (search-patches "liba52-enable-pic.patch"
197 "liba52-set-soname.patch"
198 "liba52-use-mtune-not-mcpu.patch"
199 "liba52-link-with-libm.patch"))))
cda163cd 200 (build-system gnu-build-system)
23da88f6
MW
201 ;; XXX We need to run ./bootstrap because of the build system fixes above.
202 (native-inputs
203 `(("autoconf" ,autoconf)
204 ("automake" ,automake)
205 ("libtool" ,libtool)))
412a2422 206 (arguments `(#:configure-flags '("--enable-shared")
23da88f6
MW
207 #:phases
208 (modify-phases %standard-phases
209 ;; XXX We need to run ./bootstrap because of the build
210 ;; system fixes above.
211 (add-after
212 'unpack 'bootstrap
213 (lambda _ (zero? (system* "sh" "bootstrap")))))))
cda163cd
TUBK
214 (home-page "http://liba52.sourceforge.net/")
215 (synopsis "ATSC A/52 stream decoder")
216 (description "liba52 is a library for decoding ATSC A/52 streams. The
217A/52 standard is used in a variety of applications, including digital
218television and DVD. It is also known as AC-3.")
ae0bdd81 219 (license license:gpl2+)))
cda163cd 220
e0884109
MW
221(define-public libmpeg2
222 (package
223 (name "libmpeg2")
224 (version "0.5.1")
225 (source (origin
226 (method url-fetch)
227 ;; A mirror://sourceforge URI doesn't work, presumably
228 ;; because the SourceForge project is misconfigured.
229 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
230 name "-" version ".tar.gz"))
231 (sha256
232 (base32
233 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
234 (inputs
235 `(("libx11" ,libx11)
236 ("libxext" ,libxext)
237 ("libxv" ,libxv)
238 ("libsm" ,libsm)
239 ("libice" ,libice)
240 ("sdl" ,sdl)))
241 (build-system gnu-build-system)
242 (home-page "http://libmpeg2.sourceforge.net/")
243 (synopsis "MPEG1 and MPEG2 video decoder library")
244 (description
245 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
246 (license license:gpl2+)))
247
82712597
MW
248(define-public libx264
249 (package
250 (name "libx264")
a33727db 251 (version "20180219-2245")
82712597
MW
252 (source (origin
253 (method url-fetch)
4ff71cac 254 (uri (string-append "https://download.videolan.org/pub/x264/snapshots/"
bb2a9558 255 "x264-snapshot-" version "-stable.tar.bz2"))
82712597
MW
256 (sha256
257 (base32
bb2a9558 258 "1x0cg8l30wp84mr7q0ddp06jclm0kjrszazrx87d4k7js3qxjy8m"))))
82712597
MW
259 (build-system gnu-build-system)
260 (native-inputs
261 `(("pkg-config" ,pkg-config)
a0343008 262 ("nasm" ,nasm)))
82712597
MW
263 ;; TODO: Add gpac input
264 (arguments
265 `(#:tests? #f ;no check target
266 #:configure-flags '("--enable-shared"
267 ;; Don't build the command-line program. If we
268 ;; want it later, we should do so in a different
269 ;; package to avoid a circular dependency (the x264
270 ;; program depends on ffmpeg and ffmpeg depends on
271 ;; libx264).
cb50d0c2
MW
272 "--disable-cli"
273
274 ;; On MIPS, we must pass "--disable-asm" or else
275 ;; configure fails after printing: "You specified a
276 ;; pre-MSA CPU in your CFLAGS. If you really want
277 ;; to run on such a CPU, configure with
278 ;; --disable-asm."
279 ,@(if (string-prefix? "mips"
280 (or (%current-target-system)
281 (%current-system)))
282 '("--disable-asm")
283 '()))))
4ff71cac 284 (home-page "https://www.videolan.org/developers/x264.html")
82712597
MW
285 (synopsis "H.264 video coding library")
286 (description "libx264 is an advanced encoding library for creating
287H.264 (MPEG-4 AVC) video streams.")
288 (license (list license:gpl2+ ;most files
289 license:isc ;common/x86/x86inc.asm
290 license:lgpl2.1+ ;extras/getopt.c
291 license:bsd-3 ;extras/inttypes.h
292 (license:non-copyleft ;extras/cl*.h
293 "file://extras/cl.h"
294 "See extras/cl.h in the distribution.")))))
295
2973ebf5
GG
296(define-public mkvtoolnix
297 (package
298 (name "mkvtoolnix")
299 (version "13.0.0")
300 (source
301 (origin
302 (method url-fetch)
303 (uri (string-append "https://mkvtoolnix.download/sources/"
304 name "-" version ".tar.xz"))
305 (sha256
306 (base32
307 "0hknnnnx9661igm1r73dc7aqxnnrl5a8yvyvr1nhd9ymn2klwpl5"))
308 (modules '((guix build utils)))
309 (snippet
310 '(begin
311 ;; Delete bundled libraries.
312 (for-each delete-file-recursively
313 '("lib/libebml"
314 "lib/libmatroska"
315 "lib/nlohmann-json"
316 "lib/pugixml"
317 "lib/utf8-cpp"))))))
318 (build-system gnu-build-system)
319 (inputs
320 `(("boost" ,boost)
321 ("bzip2" ,bzip2)
322 ("libebml" ,libebml)
323 ("flac" ,flac)
324 ("file" ,file)
325 ("libmatroska" ,libmatroska)
326 ("libogg" ,libogg)
327 ("libvorbis" ,libvorbis)
328 ("lzo" ,lzo)
329 ("pugixml" ,pugixml)
330 ("qt" ,qt)
331 ("utfcpp" ,utfcpp)
332 ("zlib" ,zlib)))
333 (native-inputs
334 `(("docbook-xsl" ,docbook-xsl)
335 ("gettext" ,gettext-minimal)
336 ("googletest" ,googletest)
337 ("libxslt" ,libxslt)
338 ("nlohmann-json-cpp" ,nlohmann-json-cpp)
339 ("perl" ,perl)
340 ("pkg-config" ,pkg-config)
341 ("po4a" ,po4a)
342 ("ruby" ,ruby)))
343 (arguments
344 `(#:configure-flags
345 (list (string-append "--with-boost="
346 (assoc-ref %build-inputs "boost"))
347 (string-append "--with-docbook-xsl-root="
348 (assoc-ref %build-inputs "docbook-xsl")
349 "/xml/xsl/docbook-xsl-"
350 ,(package-version docbook-xsl))
351 (string-append "--with-extra-includes="
352 (assoc-ref %build-inputs "nlohmann-json-cpp")
353 "/include/nlohmann"))
354 #:phases
355 (modify-phases %standard-phases
356 (add-before 'configure 'add-googletest
357 (lambda _
358 (symlink
359 (string-append (assoc-ref %build-inputs "googletest")
360 "/include/gtest") "lib/gtest")
361 #t))
362 (replace 'build
363 (lambda _
364 (let ((-j (list "-j" (number->string (parallel-job-count)))))
365 (zero? (apply system* "rake" -j)))))
366 (replace 'check
367 (lambda _
368 (zero? (system* "rake" "tests/unit"))))
369 (replace 'install
370 (lambda _
371 (zero? (system* "rake" "install")))))))
372 (home-page "https://mkvtoolnix.download")
373 (synopsis "Tools to create, alter and inspect Matroska files")
374 (description
375 "MKVToolNix provides tools for getting information about Matroska files
376(@code{mkvinfo}), extracting tracks/data from Matroska files (@code{mkvextract})
377and creating Matroska files from other media files (@code{mkvmerge}).")
378 (license license:gpl2)))
379
7bc7ffc2
EF
380(define-public x265
381 (package
382 (name "x265")
975c715a 383 (version "2.6")
7bc7ffc2
EF
384 (source
385 (origin
386 (method url-fetch)
387 (uri (string-append "https://download.videolan.org/videolan/x265/"
388 "x265_" version ".tar.gz"))
389 (sha256
390 (base32
975c715a 391 "1gyd94jkwdii9308m07nymsbxrmrcl81c0j8i10zhslr2mj07w0v"))
7bc7ffc2
EF
392 (modules '((guix build utils)))
393 (snippet
394 '(delete-file-recursively "source/compat/getopt"))))
395 (build-system cmake-build-system)
396 (arguments
397 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
a160778c
EF
398 ;; Currently the source code doesn't check for aarch64
399 ,@(if (string-prefix? "aarch64" (or (%current-target-system) (%current-system)))
400 '(#:configure-flags '("-DENABLE_PIC=TRUE"))
401 '())
7bc7ffc2
EF
402 #:phases
403 (modify-phases %standard-phases
404 (add-before 'configure 'prepare-build
405 (lambda _
406 (delete-file-recursively "build")
407 (chdir "source")
408 #t)))))
409 (home-page "http://x265.org/")
410 (synopsis "Library for encoding h.265/HEVC video streams")
411 (description "x265 is a H.265 / HEVC video encoder application library,
412designed to encode video or images into an H.265 / HEVC encoded bitstream.")
413 (license license:gpl2+)))
414
c426e61e
TUBK
415(define-public libass
416 (package
417 (name "libass")
449ad88b 418 (version "0.14.0")
c426e61e
TUBK
419 (source (origin
420 (method url-fetch)
421 (uri (string-append
422 "https://github.com/libass/libass/releases/download/"
423 version "/libass-" version ".tar.xz"))
424 (sha256
425 (base32
449ad88b 426 "18iqznl4mabhj9ywfsz4kwvbsplcv1jjxq50nxssvbj8my1267w8"))))
c426e61e
TUBK
427 (build-system gnu-build-system)
428 (native-inputs
429 `(("pkg-config" ,pkg-config)
449ad88b 430 ("nasm" ,nasm)))
c426e61e
TUBK
431 (propagated-inputs
432 `(("freetype" ,freetype)
433 ("fribidi" ,fribidi)
434 ("fontconfig" ,fontconfig)
435 ("harfbuzz" ,harfbuzz)
436 ("enca" ,enca)))
437 (home-page "https://github.com/libass/libass")
438 (synopsis "Subtitle rendering library for the ASS/SSA format")
439 (description "libass is a subtitle rendering library for the
440ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
ae0bdd81 441 (license license:isc)))
c426e61e 442
4d94b93c
TUBK
443(define-public libcaca
444 (package
445 (name "libcaca")
446 (version "0.99.beta19")
447 (source (origin
448 (method url-fetch)
449 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
450 version ".tar.gz"))
451 (sha256
452 (base32
453 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))))
454 (build-system gnu-build-system)
455 (native-inputs `(("pkg-config" ,pkg-config)))
456 (inputs
457 `(("freeglut" ,freeglut)
458 ("ftgl" ,ftgl)
43d51239 459 ("imlib2" ,imlib2)
4d94b93c
TUBK
460 ("libx11" ,libx11)
461 ("mesa" ,mesa)
462 ("ncurses" ,ncurses)
463 ("zlib" ,zlib)))
464 (home-page "http://caca.zoy.org/wiki/libcaca")
465 (synopsis "Colour ASCII-art library")
466 (description "libcaca is a graphics library that outputs text instead of
467pixels, so that it can work on older video cards or text terminals. It
468supports Unicode, 2048 colors, dithering of color images, and advanced text
469canvas operations.")
ae0bdd81 470 (license (license:fsf-free "file://COPYING")))) ;WTFPL version 2
4d94b93c 471
3bfb78dc
TUBK
472(define-public libdca
473 (package
474 (name "libdca")
475 (version "0.0.5")
476 (source (origin
477 (method url-fetch)
478 (uri (string-append
b8a31908 479 "https://download.videolan.org/pub/videolan/libdca/"
3bfb78dc
TUBK
480 version "/libdca-" version ".tar.bz2"))
481 (sha256
482 (base32
483 "0hh6a7l8vvccsd5i1fkv9av2gzv9fy8m0b8jpsn5p6hh4bh2586v"))))
484 (build-system gnu-build-system)
b8a31908 485 (home-page "https://www.videolan.org/developers/libdca.html")
3bfb78dc
TUBK
486 (synopsis "DTS Coherent Acoustics decoder")
487 (description "libdca is a library for decoding DTS Coherent Acoustics
488streams.")
ae0bdd81 489 (license license:gpl2+)))
3bfb78dc 490
99d4c455
TUBK
491(define-public libdv
492 (package
493 (name "libdv")
494 (version "1.0.0")
495 (source (origin
496 (method url-fetch)
497 (uri (string-append
de67e922
LF
498 "mirror://sourceforge/" name "/" name "/"
499 version "/" name "-" version ".tar.gz"))
99d4c455
TUBK
500 (sha256
501 (base32
502 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
503 (build-system gnu-build-system)
504 (native-inputs `(("pkg-config" ,pkg-config)))
505 (inputs `(("libxv" ,libxv)))
506 (home-page "http://libdv.sourceforge.net/")
507 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
508 (description "The Quasar DV codec (libdv) is a software codec for DV
509video, the encoding format used by most digital camcorders, typically those
510that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
511developed according to the official standards for DV video: IEC 61834 and
512SMPTE 314M.")
ae0bdd81 513 (license license:lgpl2.1+)))
99d4c455 514
15f1d02a
GG
515(define-public libmatroska
516 (package
517 (name "libmatroska")
0dfc7612 518 (version "1.4.8")
15f1d02a
GG
519 (source
520 (origin
521 (method url-fetch)
522 (uri (string-append "https://dl.matroska.org/downloads/"
0dfc7612 523 name "/" name "-" version ".tar.xz"))
15f1d02a
GG
524 (sha256
525 (base32
0dfc7612 526 "14n9sw974prr3yp4yjb7aadi6x2yz5a0hjw8fs3qigy5shh2piyq"))))
15f1d02a
GG
527 (build-system gnu-build-system)
528 (native-inputs
529 `(("pkg-config" ,pkg-config)))
530 (inputs
531 `(("libebml" ,libebml)))
532 (home-page "https://www.matroska.org")
cb778117 533 (synopsis "C++ library to parse Matroska files (.mkv and .mka)")
15f1d02a
GG
534 (description
535 "Matroska aims to become the standard of multimedia container formats.
cb778117 536It is based on @dfn{EBML} (Extensible Binary Meta Language), a binary derivative
15f1d02a
GG
537of XML. EBML enables the Matroska Development Team to gain significant
538advantages in terms of future format extensibility, without breaking file
539support in old parsers.
540libebml is a C++ library to read and write EBML files.")
541 (license license:lgpl2.1)))
542
ee3b55ea
TUBK
543(define-public libva
544 (package
545 (name "libva")
2c01c42e 546 (version "2.1.0")
ee3b55ea
TUBK
547 (source
548 (origin
549 (method url-fetch)
7035d2dd
MB
550 (uri (list
551 ;; Newer releases are only available on GitHub.
552 (string-append "https://github.com/01org/libva/releases/download/"
553 version "/libva-" version ".tar.bz2")
554 ;; Keep the old URL around for compatibility.
555 (string-append "https://www.freedesktop.org/software/vaapi/releases/"
556 "libva/libva-" version "/libva-" version ".tar.bz2")))
ee3b55ea 557 (sha256
2c01c42e 558 (base32 "03sb1b3fxw8myf9kz6rxw5f3v1p0vfmk34779qx0q8fk24x9bypk"))))
ee3b55ea
TUBK
559 (build-system gnu-build-system)
560 (native-inputs
561 `(("pkg-config" ,pkg-config)))
562 (inputs
563 `(("libdrm" ,libdrm)
564 ("libx11" ,libx11)
565 ("libxext" ,libxext)
566 ("libxfixes" ,libxfixes)
567 ("mesa" ,mesa)))
372cf039
TUBK
568 (arguments
569 `(#:phases
570 (modify-phases %standard-phases
571 (add-before
572 'build 'fix-dlopen-paths
573 (lambda* (#:key outputs #:allow-other-keys)
574 (let ((out (assoc-ref outputs "out")))
575 (substitute* "va/drm/va_drm_auth_x11.c"
576 (("\"libva-x11\\.so\\.%d\"")
577 (string-append "\"" out "/lib/libva-x11.so.%d\"")))))))
578 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
579 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
580 #:configure-flags
581 (list (string-append "--with-drivers-path="
582 (assoc-ref %build-inputs "mesa") "/lib/dri"))
583 ;; However, we can't write to mesa's store directory, so override the
584 ;; following make variable to install the dummy driver to libva's
585 ;; $prefix/lib/dri directory.
586 #:make-flags
587 (list (string-append "dummy_drv_video_ladir="
588 (assoc-ref %outputs "out") "/lib/dri"))))
5c1c2254 589 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
ee3b55ea
TUBK
590 (synopsis "Video acceleration library")
591 (description "The main motivation for VA-API (Video Acceleration API) is
592to enable hardware accelerated video decode/encode at various
593entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
594standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
ae0bdd81 595 (license license:expat)))
ee3b55ea 596
39efcc9b
AE
597(define-public ffmpeg
598 (package
599 (name "ffmpeg")
06079c19 600 (version "4.0")
39efcc9b
AE
601 (source (origin
602 (method url-fetch)
a1121a7f
EF
603 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
604 version ".tar.xz"))
39efcc9b
AE
605 (sha256
606 (base32
06079c19 607 "0gx4ngnhi5glmxh38603qy5n6vq8bl1cr4sqd1xff95i82pmv57d"))))
39efcc9b
AE
608 (build-system gnu-build-system)
609 (inputs
c4c4cc05 610 `(("fontconfig" ,fontconfig)
39efcc9b 611 ("freetype" ,freetype)
8fd43200 612 ("frei0r-plugins" ,frei0r-plugins)
c8dab7f4 613 ("gnutls" ,gnutls)
e816b348 614 ("opus" ,opus)
71241192 615 ("ladspa" ,ladspa)
d4f12db8 616 ("lame" ,lame)
c426e61e 617 ("libass" ,libass)
5d3609e4 618 ("libbluray" ,libbluray)
4d94b93c 619 ("libcaca" ,libcaca)
cc6c0170 620 ("libcdio-paranoia" ,libcdio-paranoia)
39efcc9b 621 ("libtheora" ,libtheora)
bb3df15e 622 ("libva" ,libva)
f88f0d20 623 ("libvdpau" ,libvdpau)
39efcc9b 624 ("libvorbis" ,libvorbis)
dc55b8b2 625 ("libvpx" ,libvpx)
f88f0d20 626 ("libx11" ,libx11)
549381d6 627 ("libx264" ,libx264)
f88f0d20 628 ("mesa" ,mesa)
71241192 629 ("openal" ,openal)
71241192 630 ("pulseaudio" ,pulseaudio)
85bc5434 631 ("sdl" ,sdl2)
72bfebf5 632 ("soxr" ,soxr)
c4c4cc05 633 ("speex" ,speex)
72bfebf5 634 ("twolame" ,twolame)
d505801a 635 ("x265" ,x265)
67932f86 636 ("xvid" ,xvid)
b3546174 637 ("zlib" ,zlib)))
c4c4cc05
JD
638 (native-inputs
639 `(("bc" ,bc)
39efcc9b
AE
640 ("perl" ,perl)
641 ("pkg-config" ,pkg-config)
824d9dc3 642 ("texinfo" ,texinfo)
39efcc9b
AE
643 ("python" ,python-2) ; scripts use interpreter python2
644 ("speex" ,speex)
c4c4cc05 645 ("yasm" ,yasm)))
39efcc9b 646 (arguments
31f9322e 647 `(#:test-target "fate"
12f92e38
AP
648 #:configure-flags
649 ;; possible additional inputs:
650 ;; --enable-avisynth enable reading of AviSynth script
651 ;; files [no]
12f92e38
AP
652 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
653 ;; --enable-libcelt enable CELT decoding via libcelt [no]
654 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
655 ;; and libraw1394 [no]
656 ;; --enable-libfaac enable AAC encoding via libfaac [no]
657 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
658 ;; --enable-libflite enable flite (voice synthesis) support via
659 ;; libflite [no]
660 ;; --enable-libgme enable Game Music Emu via libgme [no]
661 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
662 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
663 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
664 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
665 ;; --enable-libnut enable NUT (de)muxing via libnut,
666 ;; native (de)muxer exists [no]
667 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
668 ;; libopencore-amrnb [no]
669 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
670 ;; libopencore-amrwb [no]
671 ;; --enable-libopencv enable video filtering via libopencv [no]
672 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
673 ;; OpenJPEG [no]
674 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
675 ;; --enable-libschroedinger enable Dirac de/encoding via
676 ;; libschroedinger [no]
677 ;; --enable-libshine enable fixed-point MP3 encoding via
678 ;; libshine [no]
679 ;; --enable-libssh enable SFTP protocol via libssh [no]
680 ;; (libssh2 does not work)
681 ;; --enable-libstagefright-h264 enable H.264 decoding via
682 ;; libstagefright [no]
683 ;; --enable-libutvideo enable Ut Video encoding and decoding via
684 ;; libutvideo [no]
685 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
686 ;; --enable-libvidstab enable video stabilization using
687 ;; vid.stab [no]
688 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
689 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
690 ;; libvo-amrwbenc [no]
691 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
692 ;; --enable-libxavs enable AVS encoding via xavs [no]
693 ;; --enable-libzmq enable message passing via libzmq [no]
694 ;; --enable-libzvbi enable teletext support via libzvbi [no]
695 ;; --enable-opencl enable OpenCL code
12f92e38
AP
696 '("--enable-avresample"
697 "--enable-gpl" ; enable optional gpl licensed parts
698 "--enable-shared"
8fd43200 699 "--enable-frei0r"
12f92e38 700 "--enable-fontconfig"
c8dab7f4 701 "--enable-gnutls"
12f92e38
AP
702 "--enable-ladspa"
703 "--enable-libass"
704 "--enable-libbluray"
705 "--enable-libcaca"
706 "--enable-libcdio"
707 "--enable-libfreetype"
708 "--enable-libmp3lame"
709 "--enable-libopus"
710 "--enable-libpulse"
12f92e38
AP
711 "--enable-libsoxr"
712 "--enable-libspeex"
713 "--enable-libtheora"
714 "--enable-libtwolame"
715 "--enable-libvorbis"
716 "--enable-libvpx"
717 "--enable-libxvid"
718 "--enable-libx264"
d505801a 719 "--enable-libx265"
12f92e38 720 "--enable-openal"
f88f0d20 721 "--enable-opengl"
12f92e38
AP
722
723 "--enable-runtime-cpudetect"
724
1e2a36e1
EF
725 ;; The HTML pages take 7.2 MiB
726 "--disable-htmlpages"
727
728 ;; The static libraries are 23 MiB
729 "--disable-static"
730
12f92e38
AP
731 ;; Runtime cpu detection is not implemented on
732 ;; MIPS, so we disable some features.
733 "--disable-mips32r2"
c5e1fcd0 734 "--disable-mipsdsp"
12f92e38
AP
735 "--disable-mipsdspr2"
736 "--disable-mipsfpu")
31f9322e 737 #:phases
f2feb0ce
LC
738 (modify-phases %standard-phases
739 (replace
39efcc9b
AE
740 'configure
741 ;; configure does not work followed by "SHELL=..." and
742 ;; "CONFIG_SHELL=..."; set environment variables instead
743 (lambda* (#:key outputs configure-flags #:allow-other-keys)
744 (let ((out (assoc-ref outputs "out")))
745 (substitute* "configure"
47734a56 746 (("#! /bin/sh") (string-append "#!" (which "sh"))))
39efcc9b
AE
747 (setenv "SHELL" (which "bash"))
748 (setenv "CONFIG_SHELL" (which "bash"))
12f92e38
AP
749 (zero? (apply system*
750 "./configure"
751 (string-append "--prefix=" out)
752 ;; Add $libdir to the RUNPATH of all the binaries.
753 (string-append "--extra-ldflags=-Wl,-rpath="
754 out "/lib")
755 configure-flags)))))
457e528e
LC
756 (add-before
757 'check 'set-ld-library-path
758 (lambda _
759 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
760 ;; running tests.
761 (let* ((dso (find-files "." "\\.so$"))
762 (path (string-join (map dirname dso) ":")))
763 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
764 (setenv "LD_LIBRARY_PATH" path)
27350ef8 765 #t))))))
702bfbf1 766 (home-page "https://www.ffmpeg.org/")
39efcc9b
AE
767 (synopsis "Audio and video framework")
768 (description "FFmpeg is a complete, cross-platform solution to record,
769convert and stream audio and video. It includes the libavcodec
770audio/video codec library.")
ae0bdd81 771 (license license:gpl2+)))
d5a748e8 772
06079c19
RH
773(define-public ffmpeg-3.4
774 (package
775 (inherit ffmpeg)
776 (version "3.4.2")
777 (source (origin
778 (method url-fetch)
779 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
780 version ".tar.xz"))
781 (sha256
782 (base32
783 "0h6prjn1ijkzzhkyj8mazp0wpx7m0n9ycadjxagf9czqirbyk4ib"))))))
784
940778c7
LC
785(define-public ffmpeg-2.8
786 (package
787 (inherit ffmpeg)
4dc159bb 788 (version "2.8.14")
940778c7
LC
789 (source (origin
790 (method url-fetch)
791 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
792 version ".tar.xz"))
793 (sha256
794 (base32
4dc159bb 795 "05m1272r5qa2r0ym5vq4figdfnpvcys1fgb1026n5s6xdjd1s1pg"))))
940778c7
LC
796 (arguments
797 (substitute-keyword-arguments (package-arguments ffmpeg)
798 ((#:configure-flags flags)
799 `(map (lambda (flag)
800 (if (string=? flag "--disable-mipsdsp")
801 "--disable-mipsdspr1"
802 flag))
803 ,flags))))))
804
d5a748e8
AE
805(define-public vlc
806 (package
807 (name "vlc")
f137f849 808 (version "2.2.8")
d5a748e8
AE
809 (source (origin
810 (method url-fetch)
811 (uri (string-append
a134cc8e 812 "https://download.videolan.org/pub/videolan/vlc/"
d5a748e8
AE
813 version "/vlc-" version ".tar.xz"))
814 (sha256
815 (base32
f137f849 816 "1v32snw46rkgbdqdy3dssl2y13i8p2cr1cw1i18r6vdmiy24dw4v"))))
d5a748e8
AE
817 (build-system gnu-build-system)
818 (native-inputs
2d2e97bd 819 `(("git" ,git) ; needed for a test
d5a748e8
AE
820 ("pkg-config" ,pkg-config)))
821 ;; FIXME: Add optional inputs once available.
822 (inputs
823 `(("alsa-lib" ,alsa-lib)
824 ("avahi" ,avahi)
825 ("dbus" ,dbus)
826 ("flac" ,flac)
b4dff935 827 ("ffmpeg" ,ffmpeg-2.8) ;fails to build against ffmpeg 3.0
d5a748e8
AE
828 ("fontconfig" ,fontconfig)
829 ("freetype" ,freetype)
830 ("gnutls" ,gnutls)
8824da4c 831 ("liba52" ,liba52)
d5a748e8 832 ("libcddb" ,libcddb)
72b6a894 833 ("libdvbpsi" ,libdvbpsi)
d5a748e8
AE
834 ("libgcrypt" ,libgcrypt)
835 ("libkate" ,libkate)
836 ("libmad" ,libmad)
837 ("libogg" ,libogg)
838 ("libpng" ,libpng)
839 ("libsamplerate" ,libsamplerate)
840 ("libssh2" ,libssh2)
841 ("libvorbis" ,libvorbis)
842 ("libtheora" ,libtheora)
843 ("libxext" ,libxext)
c161c22a 844 ("libxi" ,libxi)
d5a748e8
AE
845 ("libxinerama" ,libxinerama)
846 ("libxml2" ,libxml2)
847 ("libxpm" ,libxpm)
2aaa5729 848 ("livemedia-utils" ,livemedia-utils)
d5a748e8
AE
849 ("lua" ,lua-5.1)
850 ("mesa" ,mesa)
851 ("opus" ,opus)
852 ("perl" ,perl)
853 ("pulseaudio" ,pulseaudio)
854 ("python" ,python-wrapper)
552c3e95
MB
855 ("qtbase" ,qtbase)
856 ("qtx11extras" ,qtx11extras)
d5a748e8
AE
857 ("sdl" ,sdl)
858 ("sdl-image" ,sdl-image)
859 ("speex" ,speex)
8f5f6c92 860 ("x265" ,x265)
d5a748e8
AE
861 ("xcb-util-keysyms" ,xcb-util-keysyms)))
862 (arguments
863 `(#:configure-flags
eb1f2420 864 `("CXXFLAGS=-std=gnu++11"
d5a748e8
AE
865 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
866 (assoc-ref %build-inputs "ffmpeg")
cd76fbde
LC
867 "/lib")) ;needed for the tests
868
869 #:phases
870 (modify-phases %standard-phases
2d2e97bd 871 (add-after 'unpack 'patch-source
2aaa5729
CL
872 (lambda* (#:key inputs #:allow-other-keys)
873 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
2d2e97bd 874 (substitute* "configure"
2aaa5729
CL
875 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
876 (string-append "LIVE555_PREFIX=" livemedia-utils)))
2d2e97bd
MB
877 ;; Some of the tests require using the display to test out VLC,
878 ;; which fails in our sandboxed build system
879 (substitute* "test/run_vlc.sh"
880 (("./vlc --ignore-config") "echo"))
881 ;; XXX Likely not needed for >2.2.6.
882 (substitute* "modules/gui/qt4/components/interface_widgets.cpp"
883 (("<qx11info_x11.h>") "<QtX11Extras/qx11info_x11.h>"))
2aaa5729 884 #t)))
cd76fbde
LC
885 (add-after 'install 'regenerate-plugin-cache
886 (lambda* (#:key outputs #:allow-other-keys)
887 ;; The 'install-exec-hook' rule in the top-level Makefile.am
888 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
889 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
890 ;; it references. Thus, we first reset the timestamps of all
891 ;; these files, and then regenerate the cache such that the
892 ;; mtimes it includes are always zero instead of being dependent
893 ;; on the build time.
894 (let* ((out (assoc-ref outputs "out"))
895 (pkglibdir (string-append out "/lib/vlc"))
896 (plugindir (string-append pkglibdir "/plugins"))
897 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
898 ;; TODO: Factorize 'reset-timestamps'.
899 (for-each (lambda (file)
900 (let ((s (lstat file)))
901 (unless (eq? (stat:type s) 'symlink)
902 (utime file 0 0 0 0))))
903 (find-files plugindir))
904 (zero? (system* cachegen plugindir))))))))
d5a748e8
AE
905 (home-page "https://www.videolan.org/")
906 (synopsis "Audio and video framework")
907 (description "VLC is a cross-platform multimedia player and framework
908that plays most multimedia files as well as DVD, Audio CD, VCD, and various
909treaming protocols.")
ae0bdd81 910 (license license:gpl2+)))
ace69243
AE
911
912(define-public mplayer
913 (package
914 (name "mplayer")
e71b20e5 915 (version "1.3.0")
ace69243
AE
916 (source (origin
917 (method url-fetch)
918 (uri (string-append
ebde7c7a 919 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
ace69243
AE
920 version ".tar.xz"))
921 (sha256
922 (base32
e71b20e5 923 "0hwqn04bdknb2ic88xd75smffxx63scvz0zvwvjb56nqj9n89l1s"))))
ace69243
AE
924 (build-system gnu-build-system)
925 ;; FIXME: Add additional inputs once available.
926 (native-inputs
927 `(("pkg-config" ,pkg-config)))
928 (inputs
929 `(("alsa-lib" ,alsa-lib)
930 ("cdparanoia" ,cdparanoia)
b3546174 931 ("ffmpeg" ,ffmpeg)
778a6a8b 932 ("fontconfig" ,fontconfig)
ace69243 933 ("freetype" ,freetype)
778a6a8b 934;; ("giflib" ,giflib) ; uses QuantizeBuffer, requires version >= 5
ace69243 935 ("lame" ,lame)
778a6a8b 936 ("libass" ,libass)
b3546174
MW
937 ("libdvdcss" ,libdvdcss)
938 ("libdvdnav" ,libdvdnav)
ace69243 939 ("libjpeg" ,libjpeg)
778a6a8b
EF
940 ("libmpeg2" ,libmpeg2)
941 ("libmpg123" ,mpg123) ; audio codec for MP3
ace69243
AE
942 ("libpng" ,libpng)
943 ("libtheora" ,libtheora)
778a6a8b 944 ("libvdpau" ,libvdpau)
ace69243
AE
945 ("libvorbis" ,libvorbis)
946 ("libx11" ,libx11)
778a6a8b 947 ("libx264" ,libx264)
ace69243
AE
948 ("libxinerama" ,libxinerama)
949 ("libxv" ,libxv)
778a6a8b 950 ("libxxf86dga" ,libxxf86dga)
ace69243 951 ("mesa" ,mesa)
778a6a8b 952 ("opus" ,opus)
ace69243
AE
953 ("perl" ,perl)
954 ("pulseaudio" ,pulseaudio)
955 ("python" ,python-wrapper)
956 ("sdl" ,sdl)
957 ("speex" ,speex)
958 ("yasm" ,yasm)
959 ("zlib" ,zlib)))
960 (arguments
961 `(#:tests? #f ; no test target
962 #:phases
ebde7c7a
EF
963 (modify-phases %standard-phases
964 (replace 'configure
ace69243
AE
965 ;; configure does not work followed by "SHELL=..." and
966 ;; "CONFIG_SHELL=..."; set environment variables instead
967 (lambda* (#:key inputs outputs #:allow-other-keys)
968 (let ((out (assoc-ref outputs "out"))
969 (libx11 (assoc-ref inputs "libx11")))
970 (substitute* "configure"
2564b7c2 971 (("#! /bin/sh") (string-append "#!" (which "sh"))))
ace69243
AE
972 (setenv "SHELL" (which "bash"))
973 (setenv "CONFIG_SHELL" (which "bash"))
974 (zero? (system*
975 "./configure"
976 (string-append "--extra-cflags=-I"
977 libx11 "/include") ; to detect libx11
ebde7c7a 978 "--disable-ffmpeg_a" ; disables bundled ffmpeg
ace69243 979 (string-append "--prefix=" out)
fe138965
MW
980 ;; Enable runtime cpu detection where supported,
981 ;; and choose a suitable target.
982 ,@(match (or (%current-target-system)
983 (%current-system))
984 ("x86_64-linux"
985 '("--enable-runtime-cpudetection"
986 "--target=x86_64-linux"))
987 ("i686-linux"
988 '("--enable-runtime-cpudetection"
989 "--target=i686-linux"))
990 ("mips64el-linux"
f0d6d835
MW
991 '("--target=mips3-linux"))
992 (_ (list (string-append
993 "--target="
994 (or (%current-target-system)
995 (nix-system->gnu-triplet
996 (%current-system)))))))
ebde7c7a
EF
997 "--disable-iwmmxt"))))))))
998 (home-page "https://www.mplayerhq.hu/design7/news.html")
ace69243
AE
999 (synopsis "Audio and video player")
1000 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
1001Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
1002NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
1003SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
ae0bdd81 1004 (license license:gpl2)))
d0ed39be 1005
1c1178cd
TUBK
1006(define-public mpv
1007 (package
1008 (name "mpv")
c2957cb7 1009 (version "0.28.2")
1c1178cd
TUBK
1010 (source (origin
1011 (method url-fetch)
1012 (uri (string-append
1013 "https://github.com/mpv-player/mpv/archive/v" version
1014 ".tar.gz"))
1015 (sha256
1016 (base32
c2957cb7 1017 "15fp4sa5glqhgidd54vs6knf9dp809wszzsqiqz5nyri4ph19nma"))
1c1178cd
TUBK
1018 (file-name (string-append name "-" version ".tar.gz"))))
1019 (build-system waf-build-system)
1020 (native-inputs
832d60dc 1021 `(("perl" ,perl) ; for zsh completion file
1c1178cd
TUBK
1022 ("pkg-config" ,pkg-config)
1023 ("python-docutils" ,python-docutils)))
3440f12a 1024 ;; Missing features: libguess, V4L2
1c1178cd
TUBK
1025 (inputs
1026 `(("alsa-lib" ,alsa-lib)
1027 ("enca" ,enca)
06079c19 1028 ("ffmpeg" ,ffmpeg)
2d8781a4 1029 ("jack" ,jack-1)
1c1178cd
TUBK
1030 ("ladspa" ,ladspa)
1031 ("lcms" ,lcms)
1032 ("libass" ,libass)
1033 ("libbluray" ,libbluray)
1034 ("libcaca" ,libcaca)
1035 ("libbs2b" ,libbs2b)
1036 ("libcdio-paranoia" ,libcdio-paranoia)
1037 ("libdvdread" ,libdvdread)
1038 ("libdvdnav" ,libdvdnav)
1039 ("libjpeg" ,libjpeg)
1040 ("libva" ,libva)
81c29ccc 1041 ("libvdpau" ,libvdpau)
1c1178cd
TUBK
1042 ("libx11" ,libx11)
1043 ("libxext" ,libxext)
1044 ("libxinerama" ,libxinerama)
1045 ("libxrandr" ,libxrandr)
1046 ("libxscrnsaver" ,libxscrnsaver)
1047 ("libxv" ,libxv)
e66f0dd2
AP
1048 ;; XXX: lua > 5.2 is not currently supported; see
1049 ;; waftools/checks/custom.py
1050 ("lua" ,lua-5.2)
1c1178cd
TUBK
1051 ("mesa" ,mesa)
1052 ("mpg123" ,mpg123)
1053 ("pulseaudio" ,pulseaudio)
1054 ("rsound" ,rsound)
870541d6
RH
1055 ("shaderc" ,shaderc)
1056 ("vulkan-icd-loader" ,vulkan-icd-loader)
f0b8d83a 1057 ("waf" ,python-waf)
3440f12a 1058 ("wayland" ,wayland)
abc5ef5a 1059 ("wayland-protocols" ,wayland-protocols)
c695fb76 1060 ("libxkbcommon" ,libxkbcommon)
1c1178cd
TUBK
1061 ("youtube-dl" ,youtube-dl)
1062 ("zlib" ,zlib)))
1063 (arguments
1064 '(#:phases
1065 (modify-phases %standard-phases
1066 (add-before
f8503e2b 1067 'configure 'setup-waf
1c1178cd
TUBK
1068 (lambda* (#:key inputs #:allow-other-keys)
1069 (copy-file (assoc-ref inputs "waf") "waf")
599fd842 1070 (setenv "CC" "gcc"))))
98c8b963 1071 #:configure-flags (list "--enable-libmpv-shared"
43ba5dd4
EF
1072 "--enable-cdda"
1073 "--enable-dvdread"
1074 "--enable-dvdnav"
98c8b963
EF
1075 "--enable-zsh-comp"
1076 "--disable-build-date")
1c1178cd
TUBK
1077 ;; No check function defined.
1078 #:tests? #f))
581873b5 1079 (home-page "https://mpv.io/")
1c1178cd
TUBK
1080 (synopsis "Audio and video player")
1081 (description "mpv is a general-purpose audio and video player. It is a
1082fork of mplayer2 and MPlayer. It shares some features with the former
1083projects while introducing many more.")
ae0bdd81 1084 (license license:gpl2+)))
1c1178cd 1085
0e74bb5b
AG
1086(define-public gnome-mpv
1087 (package
1088 (name "gnome-mpv")
f136c8f2 1089 (version "0.14")
0e74bb5b
AG
1090 (source
1091 (origin
1092 (method url-fetch)
1093 (uri (string-append "https://github.com/gnome-mpv/gnome-mpv/releases"
1094 "/download/v" version "/gnome-mpv-" version
1095 ".tar.xz"))
1096 (sha256
1097 (base32
f136c8f2 1098 "03kjwd5jq0i5ajnvhjwf5019bjjaa16xkdrhdkiz1k58ipjvvj93"))))
0e74bb5b
AG
1099 (native-inputs
1100 `(("intltool" ,intltool)
1101 ("pkg-config" ,pkg-config)))
1102 (inputs
1103 `(("gtk+" ,gtk+)
1104 ("libepoxy" ,libepoxy)
1105 ("mpv" ,mpv)))
1106 (build-system glib-or-gtk-build-system)
1107 (home-page "https://github.com/gnome-mpv/gnome-mpv")
1108 (synopsis "GTK+ frontend for the mpv media player")
1109 (description "GNOME MPV is a simple GTK+ frontend for the mpv media player.
1110GNOME MPV interacts with mpv via the client API exported by libmpv, allowing
1111access to mpv's powerful playback capabilities.")
1112 (license license:gpl3+)))
1113
d0ed39be
DT
1114(define-public libvpx
1115 (package
1116 (name "libvpx")
8a464433 1117 (version "1.7.0")
d0ed39be 1118 (source (origin
8a464433
MB
1119 ;; XXX: Upstream does not provide tarballs for > 1.6.1.
1120 (method git-fetch)
1121 (uri (git-reference
1122 (url "https://chromium.googlesource.com/webm/libvpx")
1123 (commit (string-append "v" version))))
1124 (file-name (git-file-name name version))
d0ed39be
DT
1125 (sha256
1126 (base32
8a464433 1127 "0vvh89hvp8qg9an9vcmwb7d9k3nixhxaz6zi65qdjnd0i56kkcz6"))
c7c49446 1128 (patches (search-patches "libvpx-CVE-2016-2818.patch"))))
d0ed39be
DT
1129 (build-system gnu-build-system)
1130 (arguments
e896c227 1131 `(#:configure-flags (list "--enable-shared"
0e47b4e7
EF
1132 "--as=yasm"
1133 ;; Limit size to avoid CVE-2015-1258
1134 "--size-limit=16384x16384"
e896c227
MB
1135 (string-append "--prefix=" (assoc-ref %outputs "out")))
1136 #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
1137 (assoc-ref %outputs "out") "/lib"))
1138 #:phases (modify-phases %standard-phases
1139 (replace 'configure
1140 (lambda* (#:key configure-flags #:allow-other-keys)
1141 ;; The configure script does not understand some of the GNU
1142 ;; options, so we only add the flags specified above.
1143 (apply invoke "./configure" configure-flags))))
4f8f15cd 1144 #:tests? #f)) ; no check target
d0ed39be
DT
1145 (native-inputs
1146 `(("perl" ,perl)
1147 ("yasm" ,yasm)))
1148 (synopsis "VP8/VP9 video codec")
1149 (description "libvpx is a codec for the VP8/VP9 video compression format.")
ae0bdd81 1150 (license license:bsd-3)
ad7664f6 1151 (home-page "https://www.webmproject.org/")))
615215a5
LC
1152
1153(define-public youtube-dl
1154 (package
1155 (name "youtube-dl")
fe355a1f 1156 (version "2018.04.25")
615215a5
LC
1157 (source (origin
1158 (method url-fetch)
39dc7032 1159 (uri (string-append "https://yt-dl.org/downloads/"
615215a5
LC
1160 version "/youtube-dl-"
1161 version ".tar.gz"))
1162 (sha256
1163 (base32
fe355a1f 1164 "17zxgwfcy7c6gdyxdgh02f5zi52gvmy0zpccfj6zjkhw5iqj1vbw"))))
615215a5 1165 (build-system python-build-system)
2ad9515c
AV
1166 (arguments
1167 ;; The problem here is that the directory for the man page and completion
1168 ;; files is relative, and for some reason, setup.py uses the
1169 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
1170 ;; So, we need pass the prefix directly. In addition, make sure the Bash
1171 ;; completion file is called 'youtube-dl' rather than
1172 ;; 'youtube-dl.bash-completion'.
31c58006
LF
1173 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
1174 #:phases (modify-phases %standard-phases
2ad9515c
AV
1175 (add-before 'install 'fix-the-data-directories
1176 (lambda* (#:key outputs #:allow-other-keys)
1177 (let ((prefix (assoc-ref outputs "out")))
1178 (mkdir "bash-completion")
1179 (rename-file "youtube-dl.bash-completion"
1180 "bash-completion/youtube-dl")
1181 (substitute* "setup.py"
1182 (("youtube-dl\\.bash-completion")
1183 "bash-completion/youtube-dl")
1184 (("'etc/")
1185 (string-append "'" prefix "/etc/"))
1186 (("'share/")
caa8de70
TGR
1187 (string-append "'" prefix "/share/")))
1188 #t))))))
615215a5
LC
1189 (synopsis "Download videos from YouTube.com and other sites")
1190 (description
b798dfde 1191 "Youtube-dl is a small command-line program to download videos from
1c911690 1192YouTube.com and many more sites.")
39dc7032 1193 (home-page "https://yt-dl.org")
ae0bdd81 1194 (license license:public-domain)))
e6bdb36a 1195
794223bc
CM
1196(define-public youtube-dl-gui
1197 (package
1198 (name "youtube-dl-gui")
1199 (version "0.3.8")
1200 (source
1201 (origin
1202 (method url-fetch)
1203 (uri (pypi-uri "Youtube-DLG" version))
1204 (sha256
1205 (base32
1206 "0napxwzgls5ik1bxbp99vly32l23xpc4ng5kr24hfhf21ypjyadb"))))
1207 (build-system python-build-system)
1208 (arguments
1209 ;; In Guix, wxpython has not yet been packaged for Python 3.
1210 `(#:python ,python-2
1211 ;; This package has no tests.
1212 #:tests? #f
1213 #:phases
1214 (modify-phases %standard-phases
1215 (add-before 'build 'patch-source
1216 (lambda* (#:key inputs #:allow-other-keys)
1217 ;; The youtube-dl-gui program lets you configure options. Some of
1218 ;; them are problematic, so we change their defaults.
1219 (substitute* "youtube_dl_gui/optionsmanager.py"
1220 ;; When this is true, the builder process will try (and fail) to
1221 ;; write logs to the builder user's home directory.
1222 (("'enable_log': True") "'enable_log': False")
1223 ;; This determines which youtube-dl program youtube-dl-gui will
1224 ;; run. If we don't set this, then youtube-dl-gui might download
1225 ;; an arbitrary copy from the Internet into the user's home
1226 ;; directory and run it, so let's make sure youtube-dl-gui uses
1227 ;; the youtube-dl from the inputs by default.
1228 (("'youtubedl_path': self.config_path")
1229 (string-append "'youtubedl_path': '"
1230 (assoc-ref inputs "youtube-dl")
1231 "/bin'"))
1232 ;; When this is True, when youtube-dl-gui is finished downloading
1233 ;; a file, it will try (and possibly fail) to open the directory
1234 ;; containing the downloaded file. This can fail because it
1235 ;; assumes that xdg-open is in PATH. Unfortunately, simply
1236 ;; adding xdg-utils to the propagated inputs is not enough to
1237 ;; make this work, so for now we set the default to False.
1238 (("'open_dl_dir': True") "'open_dl_dir': False"))
1239 ;; The youtube-dl program from the inputs is actually a wrapper
1240 ;; script written in bash, so attempting to invoke it as a python
1241 ;; script will fail.
1242 (substitute* "youtube_dl_gui/downloaders.py"
1243 (("cmd = \\['python', self\\.youtubedl_path\\]")
1244 "cmd = [self.youtubedl_path]"))
1245 ;; Use relative paths for installing data files so youtube-dl-gui
1246 ;; installs the files relative to its prefix in the store, rather
1247 ;; than relative to /. Also, instead of installing data files into
1248 ;; $prefix/usr/share, install them into $prefix/share for
1249 ;; consistency (see: (standards) Directory Variables).
1250 (substitute* "setup.py"
1251 (("= '/usr/share") "= 'share"))
1252 ;; Update get_locale_file() so it finds the installed localization
1253 ;; files.
1254 (substitute* "youtube_dl_gui/utils.py"
1255 (("os\\.path\\.join\\('/usr', 'share'")
1256 (string-append "os.path.join('"
1257 (assoc-ref %outputs "out")
1258 "', 'share'"))))))))
1259 (inputs
1260 `(("python2-wxpython" ,python2-wxpython)
1261 ("youtube-dl" ,youtube-dl)))
1262 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
1263 (synopsis
1264 "GUI (Graphical User Interface) for @command{youtube-dl}")
1265 (description
1266 "Youtube-dlG is a GUI (Graphical User Interface) for
1267@command{youtube-dl}. You can use it to download videos from YouTube and any
1268other site that youtube-dl supports.")
1269 (license license:unlicense)))
1270
72fa6667
FS
1271(define-public you-get
1272 (package
1273 (name "you-get")
3e34ba43 1274 (version "0.4.1060")
72fa6667
FS
1275 (source (origin
1276 (method url-fetch)
1277 (uri (string-append
e2155f58
FS
1278 "https://github.com/soimort/you-get/archive/v"
1279 version ".tar.gz"))
1280 (file-name (string-append name "-" version ".tar.gz"))
72fa6667
FS
1281 (sha256
1282 (base32
3e34ba43 1283 "1pq7c2ay42aan7ykpmddzh6ylq0qsq8a27pk68m5imaxi6abbwsz"))))
72fa6667 1284 (build-system python-build-system)
72fa6667 1285 (inputs
5e84eab0
TGR
1286 `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos
1287 (arguments
1288 `(#:phases
1289 (modify-phases %standard-phases
1290 (add-after 'unpack 'qualify-input-references
1291 ;; Explicitly invoke the input ffmpeg, instead of whichever one
1292 ;; happens to be in the user's $PATH at run time.
1293 (lambda* (#:key inputs #:allow-other-keys)
1294 (let ((ffmpeg (string-append (assoc-ref inputs "ffmpeg")
1295 "/bin/ffmpeg")))
1296 (substitute* "src/you_get/processor/ffmpeg.py"
1297 ;; Don't blindly replace all occurrences of ‘'ffmpeg'’: the
1298 ;; same string is also used when sniffing ffmpeg's output.
1299 (("(FFMPEG == |\\()'ffmpeg'" _ prefix)
1300 (string-append prefix "'" ffmpeg "'")))
1301 #t))))
1302 #:tests? #f)) ; XXX some tests need Internet access
817e91bc 1303 (synopsis "Download videos, audio, or images from Web sites")
72fa6667
FS
1304 (description
1305 "You-Get is a command-line utility to download media contents (videos,
1306audio, images) from the Web. It can use either mpv or vlc for playback.")
1307 (home-page "https://you-get.org/")
1308 (license license:expat)))
1309
6f45e45d
AV
1310(define-public youtube-viewer
1311 (package
1312 (name "youtube-viewer")
1313 (version "3.3.3")
1314 (source (origin
1315 (method url-fetch)
1316 (uri (string-append
1317 "https://github.com/trizen/youtube-viewer/archive/"
1318 version ".tar.gz"))
1319 (file-name (string-append name "-" version ".tar.gz"))
1320 (sha256
1321 (base32
1322 "1j572his6qmazlmyrbnfq62s9bqml875ay7wy26byy9hfc7m0vgk"))))
1323 (build-system perl-build-system)
1324 (native-inputs
1325 `(("perl-module-build" ,perl-module-build)))
1326 ;; FIXME: Add optional dependencies once available:
1327 ;; perl-lwp-useragent-cached and perl-term-readline-gnu
1328 (inputs
1329 `(("perl-data-dump" ,perl-data-dump)
1330 ("perl-file-sharedir" ,perl-file-sharedir)
1331 ("perl-gtk2" ,perl-gtk2)
1332 ("perl-json" ,perl-json)
1333 ("perl-libwww" ,perl-libwww)
1334 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
1335 ("perl-mozilla-ca" ,perl-mozilla-ca)
1336 ("perl-unicode-linebreak" ,perl-unicode-linebreak)))
1337 (arguments
1338 `(#:modules ((guix build perl-build-system)
1339 (guix build utils)
1340 (srfi srfi-26))
1341 #:module-build-flags '("--gtk")
63d99002
AV
1342 #:phases
1343 (modify-phases %standard-phases
1344 (add-after 'install 'wrap-program
1345 (lambda* (#:key outputs #:allow-other-keys)
1346 (let* ((out (assoc-ref outputs "out"))
1347 (bin-dir (string-append out "/bin/"))
1348 (site-dir (string-append out "/lib/perl5/site_perl/"))
1349 (lib-path (getenv "PERL5LIB")))
1350 (for-each (cut wrap-program <>
1351 `("PERL5LIB" ":" prefix (,lib-path ,site-dir)))
1352 (find-files bin-dir))
1353 #t))))))
6f45e45d
AV
1354 (synopsis
1355 "Lightweight application for searching and streaming videos from YouTube")
1356 (description
1357 "Youtube-viewer searches and plays YouTube videos in a native player.
1358It comes with various search options; it can search for videos, playlists
1359and/or channels. The videos are streamed directly in a selected video player
1360at the best resolution (customizable) and with closed-captions (if available).
1361Both command-line and GTK2 interface are available.")
1362 (home-page "https://github.com/trizen/youtube-viewer")
1363 (license license:perl-license)))
1364
5d3609e4
TUBK
1365(define-public libbluray
1366 (package
1367 (name "libbluray")
004450f4 1368 (version "1.0.2")
5d3609e4
TUBK
1369 (source (origin
1370 (method url-fetch)
5e3f68e6 1371 (uri (string-append "https://download.videolan.org/videolan/"
5d3609e4
TUBK
1372 name "/" version "/"
1373 name "-" version ".tar.bz2"))
1374 (sha256
1375 (base32
004450f4 1376 "1zxfnw1xbghcj7b3zz5djndv6gwssxda19cz1lrlqrkg8577r7kd"))))
5d3609e4 1377 (build-system gnu-build-system)
6c0cd765 1378 (arguments
d76e2634 1379 `(#:configure-flags '("--disable-bdjava-jar")
6c0cd765
AP
1380 #:phases
1381 (modify-phases %standard-phases
004450f4
TGR
1382 (add-after 'unpack 'refer-to-libxml2-in-.pc-file
1383 ;; Avoid the need to propagate libxml2 by referring to it
1384 ;; directly, as is already done for fontconfig & freetype.
1385 (lambda* (#:key inputs #:allow-other-keys)
1386 (let ((libxml2 (assoc-ref inputs "libxml2")))
1387 (substitute* "configure"
1388 ((" libxml-2.0") ""))
1389 (substitute* "src/libbluray.pc.in"
1390 (("^Libs.private:" field)
1391 (string-append field " -L" libxml2 "/lib -lxml2")))
1392 #t)))
6c0cd765
AP
1393 (add-before 'build 'fix-dlopen-paths
1394 (lambda* (#:key inputs #:allow-other-keys)
1395 (let ((libaacs (assoc-ref inputs "libaacs"))
1396 (libbdplus (assoc-ref inputs "libbdplus")))
1397 (substitute* "src/libbluray/disc/aacs.c"
1398 (("\"libaacs\"")
1399 (string-append "\"" libaacs "/lib/libaacs\"")))
1400 (substitute* "src/libbluray/disc/bdplus.c"
1401 (("\"libbdplus\"")
1402 (string-append "\"" libbdplus "/lib/libbdplus\"")))
1403 #t))))))
2da45ebe 1404 (native-inputs `(("pkg-config" ,pkg-config)))
5d3609e4 1405 (inputs
71ee51a0 1406 `(("fontconfig" ,fontconfig)
5d3609e4 1407 ("freetype" ,freetype)
6c0cd765
AP
1408 ("libaacs" ,libaacs)
1409 ("libbdplus" ,libbdplus)
71ee51a0 1410 ("libxml2" ,libxml2)))
5e3f68e6 1411 (home-page "https://www.videolan.org/developers/libbluray.html")
5d3609e4
TUBK
1412 (synopsis "Blu-Ray Disc playback library")
1413 (description
1414 "libbluray is a library designed for Blu-Ray Disc playback for media
1415players, like VLC or MPlayer.")
ae0bdd81 1416 (license license:lgpl2.1+)))
5d3609e4 1417
e6bdb36a
AE
1418(define-public libdvdread
1419 (package
1420 (name "libdvdread")
3c9deb0b 1421 (version "6.0.0")
e6bdb36a
AE
1422 (source (origin
1423 (method url-fetch)
b8a31908 1424 (uri (string-append "https://download.videolan.org/videolan/"
e6bdb36a
AE
1425 name "/" version "/"
1426 name "-" version ".tar.bz2"))
1427 (sha256
1428 (base32
3c9deb0b 1429 "0dgr23fzcjhb7ck54xkr9zmf4jcq3ph0dz3fbyvla1c6ni9ijfxk"))))
e6bdb36a 1430 (build-system gnu-build-system)
e21f3473
RJ
1431 (arguments
1432 `(#:configure-flags '("--with-libdvdcss=yes")))
1433 (native-inputs
1434 `(("pkg-config" ,pkg-config)))
1435 (propagated-inputs
1436 `(("libdvdcss" ,libdvdcss)))
e6bdb36a
AE
1437 (home-page "http://dvdnav.mplayerhq.hu/")
1438 (synopsis "Library for reading video DVDs")
1439 (description
1440 "Libdvdread provides a simple foundation for reading DVD video
1441disks. It provides the functionality that is required to access many
1442DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
1443authentication and descrambling (if an external libdvdcss library is
1444installed).")
ae0bdd81 1445 (license license:gpl2+)))
b027d919 1446
b5b20bda
TD
1447(define-public dvdauthor
1448 (package
1449 (name "dvdauthor")
1450 (version "0.7.2")
1451 (source
1452 (origin
1453 (method url-fetch)
1454 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
1455 version ".tar.gz"))
1456 (sha256
1457 (base32
1458 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
1459 (build-system gnu-build-system)
1460 (inputs
1461 `(("libdvdread" ,libdvdread)
1462 ("libpng" ,libpng)
1463 ("imagemagick" ,imagemagick)
1464 ("libxml2" ,libxml2)
1465 ("freetype" ,freetype)))
1466 (native-inputs
1467 `(("pkg-config" ,pkg-config)))
1468 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
1469 (description "@command{dvdauthor} will generate a DVD-Video movie from a
1470MPEG-2 stream containing VOB packets.")
1471 (home-page "http://dvdauthor.sourceforge.net")
1472 (license license:gpl3+)))
1473
b027d919
AE
1474(define-public libdvdnav
1475 (package
1476 (name "libdvdnav")
0976ea38 1477 (version "6.0.0")
b027d919
AE
1478 (source (origin
1479 (method url-fetch)
b8a31908 1480 (uri (string-append "https://download.videolan.org/videolan/"
b027d919
AE
1481 name "/" version "/"
1482 name "-" version ".tar.bz2"))
1483 (sha256
1484 (base32
0976ea38 1485 "062njcksmpgw9yv3737qkf93r2pzhaxi9szqjabpa8d010dp38ph"))))
b027d919
AE
1486 (build-system gnu-build-system)
1487 (native-inputs
1488 `(("pkg-config" ,pkg-config)))
1489 (inputs
1490 `(("libdvdread" ,libdvdread)))
1491 (home-page "http://dvdnav.mplayerhq.hu/")
1492 (synopsis "Library for video DVD navigation features")
1493 (description
1494 "Libdvdnav is a library for developers of multimedia
1495applications. It allows easy use of sophisticated DVD navigation features
1496such as DVD menus, multiangle playback and even interactive DVD games. All
1497this functionality is provided through a simple API which provides the DVD
1498playback as a single logical stream of blocks, intermitted by special
1499dvdnav events to report certain conditions. The main usage of libdvdnav is
1500a loop regularly calling a function to get the next block, surrounded by
1501additional calls to tell the library of user interaction. The whole
1502DVD virtual machine and internal playback states are completely
1503encapsulated.")
ae0bdd81 1504 (license license:gpl2+)))
2cd85cf9 1505
a6f710ec
TUBK
1506(define-public libdvdcss
1507 (package
1508 (name "libdvdcss")
c77fb2d6 1509 (version "1.4.2")
a6f710ec
TUBK
1510 (source (origin
1511 (method url-fetch)
b8a31908 1512 (uri (string-append "https://download.videolan.org/pub/"
a6f710ec
TUBK
1513 name "/" version "/"
1514 name "-" version ".tar.bz2"))
1515 (sha256
1516 (base32
c77fb2d6 1517 "0x957zzpf4w2cp8zlk29prj8i2q6hay3lzdzsyz8y3cwxivyvhkq"))))
a6f710ec 1518 (build-system gnu-build-system)
b8a31908 1519 (home-page "https://www.videolan.org/developers/libdvdcss.html")
a6f710ec
TUBK
1520 (synopsis "Library for accessing DVDs as block devices")
1521 (description
1522 "libdvdcss is a simple library designed for accessing DVDs like a block
1523device without having to bother about the decryption.")
ae0bdd81 1524 (license license:gpl2+)))
a6f710ec 1525
2cd85cf9
DT
1526(define-public srt2vtt
1527 (package
1528 (name "srt2vtt")
1529 (version "0.1")
1530 (source (origin
1531 (method url-fetch)
1532 (uri (string-append
152fc959 1533 "https://files.dthompson.us/srt2vtt/srt2vtt-"
2cd85cf9
DT
1534 version ".tar.gz"))
1535 (sha256
1536 (base32
1537 "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif"))))
1538 (build-system gnu-build-system)
1539 (inputs
1540 `(("guile" ,guile-2.0)))
1541 (synopsis "SubRip to WebVTT subtitle converter")
1542 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
1543for use with HTML5 video.")
1544 (home-page "http://dthompson.us/pages/software/srt2vtt")
ae0bdd81 1545 (license license:gpl3+)))
44726031
AE
1546
1547(define-public avidemux
1548 (package
1549 (name "avidemux")
9e786e8b 1550 (version "2.6.12")
44726031
AE
1551 (source (origin
1552 (method url-fetch)
1553 (uri (string-append
de67e922
LF
1554 "mirror://sourceforge/" name "/" name "/" version "/"
1555 name "_" version ".tar.gz"))
44726031
AE
1556 (sha256
1557 (base32
9e786e8b 1558 "0nz52yih8sff53inndkh2dba759xjzsh4b8xjww419lcpk0qp6kn"))
fc1adab1 1559 (patches (search-patches "avidemux-install-to-lib.patch"))))
44726031
AE
1560 (build-system cmake-build-system)
1561 (native-inputs
1562 `(("pkg-config" ,pkg-config)))
1563 ;; FIXME: Once packaged, add libraries not found during the build.
1564 (inputs
1565 `(("alsa-lib" ,alsa-lib)
1566 ("fontconfig" ,fontconfig)
1567 ("freetype" ,freetype)
1568 ("fribidi" ,fribidi)
1569 ("glu" ,glu)
44726031
AE
1570 ("jack" ,jack-1)
1571 ("lame" ,lame)
4cafe8ad
EF
1572 ("libva" ,libva)
1573 ("libvdpau" ,libvdpau)
44726031
AE
1574 ("libvorbis" ,libvorbis)
1575 ("libvpx" ,libvpx)
1576 ("libxv" ,libxv)
1577 ("perl" ,perl)
1578 ("pulseaudio" ,pulseaudio)
1579 ("python" ,python-wrapper)
a2c24bf5
DC
1580 ("qt" ,qt) ; FIXME: reenable modular qt after update - requires building
1581 ;("qtbase" ,qtbase) with -std=gnu++11.
1582 ;("qttools" ,qttools)
44726031
AE
1583 ("sdl" ,sdl)
1584 ("sqlite" ,sqlite)
1585 ("yasm" ,yasm)
1586 ("zlib" ,zlib)))
1587 (arguments
1588 `(#:tests? #f ; no check target
1589 #:phases
1590 ;; Make sure files inside the included ffmpeg tarball are
1591 ;; patch-shebanged.
1898900f
EF
1592 (modify-phases %standard-phases
1593 (add-before 'patch-source-shebangs 'unpack-ffmpeg
44726031
AE
1594 (lambda _
1595 (with-directory-excursion "avidemux_core/ffmpeg_package"
1898900f
EF
1596 (system* "tar" "xf" "ffmpeg-2.7.6.tar.bz2")
1597 (delete-file "ffmpeg-2.7.6.tar.bz2"))))
1598 (add-after 'patch-source-shebangs 'repack-ffmpeg
44726031
AE
1599 (lambda _
1600 (with-directory-excursion "avidemux_core/ffmpeg_package"
9e786e8b 1601 (substitute* "ffmpeg-2.7.6/configure"
2fed4042 1602 (("#! /bin/sh") (string-append "#!" (which "sh"))))
9e786e8b 1603 (system* "tar" "cjf" "ffmpeg-2.7.6.tar.bz2" "ffmpeg-2.7.6"
c09e6a5f 1604 ;; avoid non-determinism in the archive
92226a47
MW
1605 "--sort=name" "--mtime=@0"
1606 "--owner=root:0" "--group=root:0")
1898900f
EF
1607 (delete-file-recursively "ffmpeg-2.7.6"))))
1608 (replace 'configure
1609 (lambda _
1610 ;; Copy-paste settings from the cmake build system.
1611 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
1612 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))))
1613 (replace 'build
1614 (lambda* (#:key inputs outputs #:allow-other-keys)
1615 (let*
1616 ((out (assoc-ref outputs "out"))
1617 (lib (string-append out "/lib"))
1618 (top (getcwd))
1619 (sdl (assoc-ref inputs "sdl"))
1620 (build_component
1621 (lambda* (component srcdir #:optional (args '()))
1622 (let ((builddir (string-append "build_" component)))
1623 (mkdir builddir)
1624 (with-directory-excursion builddir
1625 (zero?
1626 (and
44726031
AE
1627 (apply system* "cmake"
1628 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
1629 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
1630 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
c687f731
AE
1631 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
1632 "\"-Wl,-rpath=" lib "\"")
44726031
AE
1633 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
1634 (string-append "-DSDL_INCLUDE_DIR="
1635 sdl "/include/SDL")
1636 (string-append "../" srcdir)
aab56ab7 1637 "-DENABLE_QT5=True"
44726031 1638 args)
1898900f
EF
1639 (system* "make" "-j"
1640 (number->string (parallel-job-count)))
1641 (system* "make" "install"))))))))
1642 (mkdir out)
1643 (and (build_component "core" "avidemux_core")
1644 (build_component "cli" "avidemux/cli")
1645 (build_component "qt4" "avidemux/qt4")
1646 (build_component "plugins_common" "avidemux_plugins"
1647 '("-DPLUGIN_UI=COMMON"))
1648 (build_component "plugins_cli" "avidemux_plugins"
1649 '("-DPLUGIN_UI=CLI"))
1650 (build_component "plugins_qt4" "avidemux_plugins"
1651 '("-DPLUGIN_UI=QT4"))
1652 (build_component "plugins_settings" "avidemux_plugins"
1653 '("-DPLUGIN_UI=SETTINGS")))
1654 ;; Remove .exe and .dll file.
1655 (delete-file-recursively
1656 (string-append out "/share/ADM6_addons")))))
1657 (delete 'install))))
44726031
AE
1658 (home-page "http://fixounet.free.fr/avidemux/")
1659 (synopsis "Video editor")
1660 (description "Avidemux is a video editor designed for simple cutting,
1661filtering and encoding tasks. It supports many file types, including AVI,
1662DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
1663can be automated using projects, job queue and powerful scripting
1664capabilities.")
afd9ed5c 1665 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
44726031 1666 ;; Software with various licenses is included, see License.txt.
ae0bdd81 1667 (license license:gpl2+)))
44726031 1668
6f6c8b65
TUBK
1669(define-public vapoursynth
1670 (package
1671 (name "vapoursynth")
4f7a9e0b 1672 (version "37")
6f6c8b65
TUBK
1673 (source (origin
1674 (method url-fetch)
1675 (uri (string-append
1676 "https://github.com/vapoursynth/vapoursynth/archive/R"
1677 version ".tar.gz"))
0b37c4cd 1678 (file-name (string-append name "-" version ".tar.gz"))
6f6c8b65
TUBK
1679 (sha256
1680 (base32
4f7a9e0b 1681 "1g3hc079jw4mz1cmkv2y28pdb556wqc8ql7iravgh1rg8j3f1zi5"))))
6f6c8b65
TUBK
1682 (build-system gnu-build-system)
1683 (native-inputs
1684 `(("autoconf" ,autoconf)
1685 ("automake" ,automake)
1686 ("cython" ,python-cython)
1687 ("libtool" ,libtool)
1688 ("pkg-config" ,pkg-config)
1689 ("python" ,python)
1690 ("yasm" ,yasm)))
1691 (inputs
1692 `(("ffmpeg" ,ffmpeg)
1693 ("libass" ,libass)
f80d5fe0
EF
1694 ("tesseract-ocr" ,tesseract-ocr)
1695 ("zimg" ,zimg)))
6f6c8b65
TUBK
1696 (arguments
1697 '(#:phases
1698 (modify-phases %standard-phases
1699 (add-after
f8503e2b 1700 'unpack 'autogen
6f6c8b65
TUBK
1701 (lambda _
1702 (zero? (system* "sh" "autogen.sh")))))))
1703 (home-page "http://www.vapoursynth.com/")
1704 (synopsis "Video processing framework")
1705 (description "VapourSynth is a C++ library and Python module for video
1706manipulation. It aims to be a modern rewrite of Avisynth, supporting
1707multithreading, generalized colorspaces, per frame properties, and videos with
1708format changes.")
9a078f48 1709 ;; src/core/cpufeatures only allows x86, ARM or PPC
cda20ee8
EF
1710 (supported-systems (fold delete %supported-systems
1711 '("mips64el-linux" "aarch64-linux")))
6f6c8b65 1712 ;; As seen from the source files.
ae0bdd81 1713 (license license:lgpl2.1+)))
6f6c8b65 1714
67932f86
TUBK
1715(define-public xvid
1716 (package
1717 (name "xvid")
e05035c7 1718 (version "1.3.4")
67932f86
TUBK
1719 (source (origin
1720 (method url-fetch)
1721 (uri (string-append
1722 "http://downloads.xvid.org/downloads/xvidcore-"
1723 version ".tar.bz2"))
1724 (sha256
1725 (base32
e05035c7 1726 "1xwbmp9wqshc0ckm970zdpi0yvgqxlqg0s8bkz98mnr8p2067bsz"))))
67932f86
TUBK
1727 (build-system gnu-build-system)
1728 (native-inputs `(("yasm" ,yasm)))
1729 (arguments
1730 '(#:phases
62fe2d47
EF
1731 (modify-phases %standard-phases
1732 (add-before
1733 'configure 'pre-configure
1734 (lambda _
1735 (chdir "build/generic")
1736 (substitute* "configure"
1737 (("#! /bin/sh") (string-append "#!" (which "sh")))))))
67932f86
TUBK
1738 ;; No 'check' target.
1739 #:tests? #f))
1740 (home-page "https://www.xvid.com/")
1741 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
1742 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
1743codec library. It uses ASP features such as b-frames, global and quarter
1744pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
1745and custom quantization matrices.")
ae0bdd81 1746 (license license:gpl2+)))
e16fde14 1747
f48feaa2 1748(define-public streamlink
e16fde14 1749 (package
f48feaa2 1750 (name "streamlink")
bba66e7a 1751 (version "0.11.0")
f48feaa2
OP
1752 (source
1753 (origin
1754 (method url-fetch)
1755 (uri (pypi-uri "streamlink" version))
1756 (sha256
1757 (base32
bba66e7a 1758 "02h8b3k8l5zz4vjm0nhxvl1pm924jms8y7sjl40fbybrzvsa4mg2"))))
e16fde14 1759 (build-system python-build-system)
f48feaa2
OP
1760 (home-page "https://github.com/streamlink/streamlink")
1761 (native-inputs
1762 `(("python-pytest" ,python-pytest)
1763 ("python-mock" ,python-mock)
1764 ("python-requests-mock" ,python-requests-mock)))
e16fde14 1765 (propagated-inputs
f48feaa2
OP
1766 `(("python-pysocks" ,python-pysocks)
1767 ("python-websocket-client" ,python-websocket-client)
1768 ("python-iso3166" ,python-iso3166)
1769 ("python-iso639" ,python-iso639)
1770 ("python-pycryptodome" ,python-pycryptodome)
bba66e7a
OP
1771 ("python-requests" ,python-requests)
1772 ("python-urllib3" ,python-urllib3)))
f48feaa2
OP
1773 (synopsis "Extract streams from various services")
1774 (description "Streamlink is command-line utility that extracts streams
1775from sites like Twitch.tv and pipes them into a video player of choice.")
e16fde14 1776 (license license:bsd-2)))
307ad140 1777
d84e2257
OP
1778(define-public livestreamer
1779 (deprecated-package "livestreamer" streamlink))
1780
e5e5eb1f
OP
1781(define-public twitchy
1782 (let ((commit "0c0f925b9c7ff2aed4a3b0046561cb794143c398")) ;Fixes tests.
1783 (package
1784 (name "twitchy")
1785 (version (git-version "3.2" "1" commit))
1786 (source
1787 (origin
1788 (method git-fetch)
1789 (uri (git-reference
1790 (url "https://github.com/BasioMeusPuga/twitchy.git")
1791 (commit commit)))
1792 (file-name (git-file-name name version))
1793 (sha256
1794 (base32
1795 "02aizvsr744sh8bdqvwwsmp2qpczlzn8fy76h5dyd3517n9nlcz9"))))
1796 (build-system python-build-system)
1797 (arguments
1798 '(#:phases
1799 (modify-phases %standard-phases
1800 (add-before 'check 'check-setup
1801 (lambda _
1802 (setenv "HOME" (getcwd)) ;Needs to write to ‘$HOME’.
1803 #t)))))
1804 (inputs
1805 `(("python-requests" ,python-requests)
1806 ("streamlink" ,streamlink)))
1807 (home-page "https://github.com/BasioMeusPuga/twitchy")
1808 (synopsis "Command-line interface for Twitch.tv")
1809 (description
1810 "This package provides a command-line interface for Twitch.tv")
1811 (license license:gpl3+))))
1812
307ad140
RW
1813(define-public mlt
1814 (package
1815 (name "mlt")
f05f5b30 1816 (version "6.4.1")
307ad140
RW
1817 (source (origin
1818 (method url-fetch)
4c7729dc
EF
1819 (uri (string-append "https://github.com/mltframework/mlt/"
1820 "archive/v" version ".tar.gz"))
1821 (file-name (string-append name "-" version ".tar.gz"))
307ad140
RW
1822 (sha256
1823 (base32
fd7da5b9
OP
1824 "10m3ry0b2pvqx3bk34qh5dq337nn8pkc2gzfyhsj4nv9abskln47"))
1825 (modules '((guix build utils)))
1826 (snippet
1827 ;; As of glibc 2.26, <xlocale.h> no longer is.
1828 '(substitute* "src/framework/mlt_property.h"
1829 (("xlocale\\.h") "locale.h")))))
307ad140
RW
1830 (build-system gnu-build-system)
1831 (arguments
1832 `(#:tests? #f ; no tests
1833 #:make-flags '("CC=gcc")
1834 #:configure-flags
1835 (list "--enable-gpl3"
1836 "--enable-gpl")
1837 #:phases
1838 (modify-phases %standard-phases
1839 (add-after
1840 'configure 'override-LDFLAGS
1841 (lambda* (#:key outputs #:allow-other-keys)
1842 (substitute* "config.mak"
1843 (("LDFLAGS\\+=")
1844 (string-append "LDFLAGS+=-Wl,-rpath="
1845 (assoc-ref outputs "out")
1846 "/lib ")))
1847 #t)))))
1848 (inputs
1849 `(("alsa-lib" ,alsa-lib)
bb5c508c 1850 ("ffmpeg" ,ffmpeg-3.4)
307ad140
RW
1851 ("fftw" ,fftw)
1852 ("libxml2" ,libxml2)
1853 ("jack" ,jack-1)
1854 ("ladspa" ,ladspa)
1855 ("libsamplerate" ,libsamplerate)
4c7729dc 1856 ("pulseaudio" ,pulseaudio)
307ad140
RW
1857 ("sdl" ,sdl)
1858 ("sox" ,sox)))
1859 (native-inputs
1860 `(("pkg-config" ,pkg-config)))
4c7729dc 1861 (home-page "https://www.mltframework.org/")
307ad140
RW
1862 (synopsis "Author, manage, and run multitrack audio/video compositions")
1863 (description
1864 "MLT is a multimedia framework, designed and developed for television
1865broadcasting. It provides a toolkit for broadcasters, video editors, media
1866players, transcoders, web streamers and many more types of applications. The
1867functionality of the system is provided via an assortment of ready to use
1868tools, XML authoring components, and an extensible plug-in based API.")
42b9541c 1869 (license license:gpl3)))
f464016d 1870
945d985a
DT
1871(define-public v4l-utils
1872 (package
1873 (name "v4l-utils")
f1d1ef71 1874 (version "1.12.5")
945d985a
DT
1875 (source (origin
1876 (method url-fetch)
1d4ac724 1877 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
945d985a
DT
1878 "/v4l-utils-" version ".tar.bz2"))
1879 (sha256
1880 (base32
f1d1ef71 1881 "03g2b4rivrilimcp57mwrlsa3qvrxmk4sza08mygwmqbvcnic606"))))
945d985a
DT
1882 (build-system gnu-build-system)
1883 (arguments
1884 '(#:configure-flags
1885 (list (string-append "--with-udevdir="
1886 (assoc-ref %outputs "out")
2cef0f7c
DC
1887 "/lib/udev")
1888 "CXXFLAGS=-std=gnu++11")))
945d985a 1889 (native-inputs
4ca077d5
TGR
1890 `(("perl" ,perl)
1891 ("pkg-config" ,pkg-config)))
945d985a
DT
1892 (inputs
1893 `(("alsa-lib" ,alsa-lib)
1894 ("glu" ,glu)
1895 ("libjpeg" ,libjpeg)
1896 ("libx11" ,libx11)
b37662e2 1897 ("qtbase" ,qtbase)
945d985a
DT
1898 ("eudev" ,eudev)))
1899 (synopsis "Realtime video capture utilities for Linux")
1900 (description "The v4l-utils provide a series of libraries and utilities to
1901be used for realtime video capture via Linux-specific APIs.")
1902 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
1903 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
1904 (license (list license:lgpl2.1+ license:gpl2))))
1905
f464016d
DT
1906(define-public obs
1907 (package
1908 (name "obs")
48a716c4 1909 (version "20.1.3")
f464016d
DT
1910 (source (origin
1911 (method url-fetch)
1912 (uri (string-append "https://github.com/jp9000/obs-studio"
1913 "/archive/" version ".tar.gz"))
1914 (file-name (string-append name "-" version ".tar.gz"))
1915 (sha256
1916 (base32
48a716c4 1917 "1g5z6z050v25whc7n3xvg6l238wmg5crp7ihvk73qngvzxr8bg28"))))
f464016d 1918 (build-system cmake-build-system)
08858812 1919 (arguments
f3bd1728 1920 `(#:tests? #f)) ; no tests
f464016d
DT
1921 (native-inputs
1922 `(("pkg-config" ,pkg-config)))
1923 (inputs
4f98c3c5
EF
1924 `(("alsa-lib" ,alsa-lib)
1925 ("curl" ,curl)
f464016d
DT
1926 ("eudev" ,eudev)
1927 ("ffmpeg" ,ffmpeg)
4f98c3c5 1928 ("fontconfig" ,fontconfig)
f464016d
DT
1929 ("freetype" ,freetype)
1930 ("jack" ,jack-1)
1931 ("jansson" ,jansson)
1932 ("libx264" ,libx264)
1933 ("libxcomposite" ,libxcomposite)
1934 ("mesa" ,mesa)
1935 ("pulseaudio" ,pulseaudio)
90a2309b
EF
1936 ("qtbase" ,qtbase)
1937 ("qtx11extras" ,qtx11extras)
4f98c3c5 1938 ("speex" ,speex)
d4df2032 1939 ("v4l-utils" ,v4l-utils)
f464016d
DT
1940 ("zlib" ,zlib)))
1941 (synopsis "Live streaming software")
1942 (description "Open Broadcaster Software provides a graphical interface for
1943video recording and live streaming. OBS supports capturing audio and video
1944from many input sources such as webcams, X11 (for screencasting), PulseAudio,
1945and JACK.")
1946 (home-page "https://obsproject.com")
f3bd1728 1947 (supported-systems '("x86_64-linux" "i686-linux"))
f464016d 1948 (license license:gpl2+)))
d5650f86
EF
1949
1950(define-public libvdpau
1951 (package
1952 (name "libvdpau")
1953 (version "1.1.1")
1954 (source
1955 (origin
1956 (method url-fetch)
1957 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
1958 name "-" version ".tar.bz2"))
1959 (sha256
1960 (base32
1961 "0dnpb0yh7v6rvckx82kxg045rd9rbsw25wjv7ad5n8h94s9h2yl5"))))
1962 (build-system gnu-build-system)
1963 (native-inputs
1964 `(("pkg-config" ,pkg-config)))
1965 (inputs
1966 `(("dri2proto" ,dri2proto)
1967 ("libx11" ,libx11 "out")
1968 ("libxext" ,libxext)))
1969 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
1970 (synopsis "Video Decode and Presentation API")
1971 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
1972provides an interface to video decode acceleration and presentation hardware
1973present in modern GPUs.")
1974 (license (license:x11-style "file://COPYING"))))
3161d32d
EF
1975
1976(define-public vdpauinfo
1977 (package
1978 (name "vdpauinfo")
1979 (version "1.0")
1980 (source
1981 (origin
1982 (method url-fetch)
1983 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
1984 name "-" version ".tar.gz"))
1985 (sha256
1986 (base32
1987 "1i2b0k9h8r0lnxlrkgqzmrjakgaw3f1ygqqwzx8w6676g85rcm20"))))
1988 (build-system gnu-build-system)
1989 (native-inputs
1990 `(("pkg-config" ,pkg-config)
1991 ("libx11" ,libx11)))
1992 (propagated-inputs
1993 `(("libvdpau" ,libvdpau)))
1994 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
1995 (synopsis "Tool to query the capabilities of a VDPAU implementation")
1996 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
1997implementation.")
1998 (license (license:x11-style "file://COPYING"))))
a7d94b54 1999
67df7164
EF
2000(define-public libvdpau-va-gl
2001 (package
2002 (name "libvdpau-va-gl")
2003 (version "0.4.2")
2004 (source
2005 (origin
2006 (method url-fetch)
2007 (uri (string-append "https://github.com/i-rinat/libvdpau-va-gl/"
2008 "releases/download/v" version "/libvdpau-va-gl-"
2009 version ".tar.gz"))
2010 (sha256
2011 (base32
2012 "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
2013 (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
2014 (modules '((guix build utils)))
2015 (snippet '(delete-file-recursively "3rdparty"))))
2016 (build-system cmake-build-system)
2017 (arguments
2018 '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
2019 (native-inputs
2020 `(("libvdpau" ,libvdpau)
2021 ("pkg-config" ,pkg-config)))
2022 (inputs
2023 `(("libva" ,libva)
2024 ("mesa" ,mesa)))
2025 (home-page "https://github.com/i-rinat/libvdpau-va-gl")
2026 (synopsis "VDPAU driver with VA-API/OpenGL backend")
2027 (description
2028 "Many applications can use VDPAU to accelerate portions of the video
2029decoding process and video post-processing to the GPU video hardware. Since
2030there is no VDPAU available on Intel chips, they fall back to different drawing
2031techniques. This driver uses OpenGL under the hood to accelerate drawing and
2032scaling and VA-API (if available) to accelerate video decoding.")
2033 (license license:expat)))
2034
a7d94b54
LC
2035(define-public recordmydesktop
2036 (package
2037 (name "recordmydesktop")
2038 (version "0.3.8.1")
2039 (source (origin
2040 (method url-fetch)
2041 (uri (string-append "mirror://sourceforge/" name "/" name "/"
2042 version "/recordmydesktop-" version ".tar.gz"))
2043 (sha256
2044 (base32
2045 "133kkl5j0r877d41bzj7kj0vf3xm8x80yyx2n8nqxrva304f58ik"))))
2046 (build-system gnu-build-system)
2047 (inputs `(("popt" ,popt)
2048 ("zlib" ,zlib)
2049 ("libx11" ,libx11)
2050 ("libice" ,libice)
2051 ("libsm" ,libsm)
2052 ("libxfixes" ,libxfixes)
2053 ("libxdamage" ,libxdamage)
2054 ("libxext" ,libxext)
ed6ba9cc 2055 ("alsa-lib" ,alsa-lib)
a7d94b54
LC
2056 ("libvorbis" ,libvorbis)
2057 ("libtheora" ,libtheora)))
2058 (home-page "http://recordmydesktop.sourceforge.net/")
2059 (synopsis "Desktop session video recorder")
2060 (description
2061 "recordMyDesktop is a command-line tool that captures the activity in
2062your graphical desktop and encodes it as a video. This is a useful tool for
2063making @dfn{screencasts}.")
2064 (license license:gpl2+)))
d8841cc5 2065
63cd4d53
AV
2066(define-public simplescreenrecorder
2067 (package
2068 (name "simplescreenrecorder")
186cef9e 2069 (version "0.3.10")
63cd4d53
AV
2070 (source
2071 (origin
2072 (method url-fetch)
2073 (uri (string-append "https://github.com/MaartenBaert/ssr/archive/"
2074 version ".tar.gz"))
2075 (file-name (string-append name "-" version ".tar.gz"))
2076 (sha256
2077 (base32
186cef9e 2078 "02rl9yyx3hlz9fqvgzv7ipmvx2qahj7ws5wx2m7zs3lssq3qag3g"))))
83c92882 2079 (build-system cmake-build-system)
63cd4d53
AV
2080 ;; Although libx11, libxfixes, libxext are listed as build dependencies in
2081 ;; README.md, the program builds and functions properly without them.
2082 ;; As a result, they are omitted. Please add them back if problems appear.
2083 (inputs
2084 `(("alsa-lib" ,alsa-lib)
bb5c508c 2085 ("ffmpeg" ,ffmpeg-3.4)
63cd4d53
AV
2086 ("glu" ,glu)
2087 ("jack" ,jack-1)
2088 ("libxi" ,libxi)
2089 ("pulseaudio" ,pulseaudio)
83c92882 2090 ("qt" ,qt)))
63cd4d53 2091 (native-inputs `(("pkg-config" ,pkg-config)))
83c92882
TGR
2092 (arguments
2093 `(#:configure-flags
2094 (list "-DWITH_QT5=TRUE")
2095 #:tests? #f)) ; no test suite
63cd4d53
AV
2096 ;; Using HTTPS causes part of the page to be displayed improperly.
2097 (home-page "http://www.maartenbaert.be/simplescreenrecorder/")
2098 (synopsis "Screen recorder")
2099 (description "SimpleScreenRecorder is an easy to use screen recorder with
2100a graphical user interface. It supports recording the entire screen, or a
2101part of it, and allows encoding in many different codecs and file formats.
2102Other features include a live preview and live streaming.")
2103 (license (list license:gpl3+ ; most files
2104 license:zlib ; glinject/elfhacks.*
2105 license:isc ; glinject/*
2106 license:x11)))) ; build-aux/install-sh
2107
d8841cc5
KK
2108(define-public libsmpeg
2109 (package
2110 (name "libsmpeg")
2111 (version "0.4.5")
2112 (source (origin
2113 (method svn-fetch)
2114 (uri (svn-reference
2115 (url "svn://svn.icculus.org/smpeg/trunk/")
2116 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
b9af0564 2117 (file-name (string-append name "-" version "-checkout"))
d8841cc5
KK
2118 (sha256
2119 (base32
2120 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
2121 (build-system gnu-build-system)
2122 (arguments
2123 `(#:phases (modify-phases %standard-phases
2124 (add-after 'unpack 'autogen.sh
2125 (lambda _
2126 (zero? (system* "sh" "autogen.sh")))))))
2127 (native-inputs
2128 `(("autoconf" ,autoconf)
2129 ("automake" ,automake)))
2130 (inputs
2131 `(("sdl" ,sdl2)))
2132 (home-page "http://icculus.org/smpeg/")
2133 (synopsis "SDL MPEG decoding library")
2134 (description
2135 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
2136with sound support. Video playback is based on the ubiquitous Berkeley MPEG
2137player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
2138library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
2139and MPEG system streams.")
2140 (license (list license:expat
2141 license:lgpl2.1
2142 license:lgpl2.1+
2143 license:gpl2))))
4df07622
AP
2144
2145(define-public libbdplus
2146 (package
2147 (name "libbdplus")
2148 (version "0.1.2")
2149 (source
2150 (origin
2151 (method url-fetch)
6f13c4fd 2152 (uri (string-append "https://ftp.videolan.org/pub/videolan/libbdplus/"
4df07622
AP
2153 version "/" name "-" version ".tar.bz2"))
2154 (sha256
2155 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
2156 (inputs
2157 `(("libgcrypt" ,libgcrypt)))
2158 (build-system gnu-build-system)
b8a31908 2159 (home-page "https://www.videolan.org/developers/libbdplus.html")
4df07622
AP
2160 (synopsis "Library for decrypting certain Blu-Ray discs")
2161 (description "libbdplus is a library which implements the BD+ System
2162specifications.")
2163 (license license:lgpl2.1+)))
8dd6fc51
AP
2164
2165(define-public libaacs
2166 (package
2167 (name "libaacs")
ba58886a 2168 (version "0.9.0")
8dd6fc51
AP
2169 (source
2170 (origin
2171 (method url-fetch)
6c2481ef 2172 (uri (string-append "https://ftp.videolan.org/pub/videolan/libaacs/"
8dd6fc51
AP
2173 version "/" name "-" version ".tar.bz2"))
2174 (sha256
ba58886a 2175 (base32 "1kms92i0c7i1yl659kqjf19lm8172pnpik5lsxp19xphr74vvq27"))))
8dd6fc51
AP
2176 (inputs
2177 `(("libgcrypt" ,libgcrypt)))
2178 (native-inputs
2179 `(("bison" ,bison)
2180 ("flex" ,flex)))
2181 (build-system gnu-build-system)
b8a31908 2182 (home-page "https://www.videolan.org/developers/libaacs.html")
8dd6fc51
AP
2183 (synopsis "Library for decrypting certain Blu-Ray discs")
2184 (description "libaacs is a library which implements the Advanced Access
2185Content System specification.")
2186 (license license:lgpl2.1+)))
05234973 2187
2188(define-public mps-youtube
2189 (package
2190 (name "mps-youtube")
2191 (version "0.2.7.1")
2192 (source
2193 (origin
2194 (method url-fetch)
2195 (uri (string-append "https://github.com/mps-youtube/mps-youtube/"
2196 "archive/v" version ".tar.gz"))
2197 (file-name (string-append name "-" version ".tar.gz"))
2198 (sha256
2199 (base32
2200 "1s7h35yx6f0szf8mm8612ic913w3v05m2kwphjfcxnpq0ammhyci"))))
2201 (build-system python-build-system)
175d6264 2202 (arguments
2203 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
2204 ;; test suite results differ depending on the country and also introduce
2205 ;; non-determinism in the tests.
2206 ;; https://github.com/mps-youtube/mps-youtube/issues/556
2207 `(#:tests? #f))
05234973 2208 (propagated-inputs
2209 `(("python-pafy" ,python-pafy)
2210 ("python-pygobject" ,python-pygobject))) ; For mpris2 support
2211 (home-page "https://github.com/mps-youtube/mps-youtube")
2212 (synopsis "Terminal based YouTube player and downloader")
2213 (description
2214 "@code{mps-youtube} is based on mps, a terminal based program to
2215search, stream and download music. This implementation uses YouTube as
2216a source of content and can play and download video as well as audio.
2217It can use either mpv or mplayer for playback, and for conversion of
2218formats ffmpeg or libav is used. Users should install one of the
2219supported players in addition to this package.")
2220 (license license:gpl3+)))
fe047e13
EB
2221
2222(define-public handbrake
2223 (package
2224 (name "handbrake")
2225 (version "0.10.5")
2226 (source (origin
2227 (method url-fetch)
2228 (uri (string-append "https://handbrake.fr/rotation.php?file="
2229 "HandBrake-" version ".tar.bz2"))
2230 (file-name (string-append "handbrake-" version ".tar.bz2"))
2231 (sha256
2232 (base32
2233 "1w720y3bplkz187wgvy4a4xm0vpppg45mlni55l6yi8v2bfk14pv"))
2234 (patches (search-patches "handbrake-pkg-config-path.patch"))
2235 (modules '((guix build utils)))
2236 (snippet
2237 ;; Remove bundled libraries and source not necessary for
2238 ;; running under a GNU environment.
2239 '(begin
2240 (for-each delete-file-recursively '("contrib" "macosx" "win"))
2241 #t))))
2242 (build-system glib-or-gtk-build-system)
2243 (native-inputs
2244 `(("automake" ,automake) ;gui subpackage must be bootstrapped
2245 ("autoconf" ,autoconf)
2246 ("curl" ,curl) ;not actually used, but tested for
2247 ("intltool" ,intltool)
2248 ("libtool" ,libtool)
2249 ("pkg-config" ,pkg-config)
2250 ("python" ,python-2))) ;for configuration
2251 (inputs
2252 `(("bzip2" ,bzip2)
2253 ("dbus-glib" ,dbus-glib)
2254 ("ffmpeg" ,ffmpeg)
2255 ("fontconfig" ,fontconfig)
2256 ("freetype" ,freetype)
2257 ("glib" ,glib)
2258 ("gstreamer" ,gstreamer)
2259 ("gst-plugins-base" ,gst-plugins-base)
2260 ("gtk+" ,gtk+)
2261 ("lame" ,lame)
2262 ("libass" ,libass)
2263 ("libbluray" ,libbluray)
2264 ("libdvdnav" ,libdvdnav)
2265 ("libdvdread" ,libdvdread)
2266 ("libgudev" ,libgudev)
2267 ("libmpeg2" ,libmpeg2)
2268 ("libnotify" ,libnotify)
2269 ("libogg" ,libogg)
2270 ("libsamplerate" ,libsamplerate)
2271 ("libtheora" ,libtheora)
2272 ("libvorbis" ,libvorbis)
2273 ("libvpx" ,libvpx)
2274 ("libxml2" ,libxml2)
2275 ("libx264" ,libx264)
2276 ("x265" ,x265)
2277 ("zlib" ,zlib)))
2278 (arguments
2279 `(#:tests? #f ;tests require Ruby and claim to be unsupported
2280 #:phases
2281 (modify-phases %standard-phases
2282 (add-before 'patch-source-shebangs 'bootstrap-gtk
2283 ;; Run bootstrap ahead of time so that shebangs get patched.
2284 (lambda _
2285 (setenv "CONFIG_SHELL" (which "sh"))
2286 (setenv "NOCONFIGURE" "1")
2287 ;; Patch the Makefile so that it doesn't bootstrap again.
2288 (substitute* "gtk/module.rules"
2289 ((".*autogen\\.sh.*") ""))
2290 (zero? (system* "sh" "./gtk/autogen.sh"))))
2291 (add-before 'configure 'disable-contrib
2292 (lambda _
2293 (substitute* "make/include/main.defs"
2294 ;; Disable unconditional inclusion of some "contrib"
2295 ;; libraries (ffmpeg, libvpx, libdvdread, libdvdnav,
2296 ;; and libbluray), which would lead to fetching and
2297 ;; building of these libraries. Use our own instead.
2298 (("MODULES \\+= contrib") "# MODULES += contrib"))
2299 #t))
2300 (add-before 'configure 'fix-x265-linking
2301 (lambda _
2302 (substitute* "test/module.defs"
2303 ;; Fix missing library during linking error
2304 (("TEST.GCC.l =") "TEST.GCC.l = x265"))
2305 #t))
2306 (replace 'configure
2307 (lambda* (#:key outputs configure-flags #:allow-other-keys)
2308 ;; 'configure' is not an autoconf-generated script, and
2309 ;; errors on unrecognized arguments,
2310 ;; e.g. --enable-fast-install
2311 (let ((out (assoc-ref outputs "out")))
2312 (zero? (apply system* "./configure"
2313 (string-append "--prefix=" out)
2314 (or configure-flags '()))))))
2315 (add-after 'configure 'chdir-build
2316 (lambda _ (chdir "./build") #t)))))
2317 (home-page "https://handbrake.fr")
2318 (synopsis "Video transcoder")
2319 (description
2320 "HandBrake is a tool for converting video from any format to a selection
2321of modern, widely supported codecs.")
2322 ;; Most under GPL version 2 or later, and portions under BSD 3 Clause
2323 (license (list license:gpl2+ license:bsd-3))))
590abe01
JN
2324
2325(define-public openh264
2326 (package
2327 (name "openh264")
1a34ca0e 2328 (version "1.7.0")
590abe01
JN
2329 (source (origin
2330 (method url-fetch)
2331 (uri (string-append "https://github.com/cisco/"
2332 name "/archive/v" version ".tar.gz"))
2333 (file-name (string-append name "-" version ".tar.gz"))
2334 (sha256
2335 (base32
1a34ca0e 2336 "0gv571bqkxk7ic64dmavs1q8nr7p59mcf4ibqp4lc070gn6w61ww"))))
590abe01
JN
2337 (build-system gnu-build-system)
2338 (native-inputs
2339 `(("nasm" ,nasm)
2340 ("python" ,python)))
2341 (arguments
8363a835
EF
2342 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2343 "CC=gcc")
590abe01
JN
2344 #:test-target "test"
2345 #:phases (modify-phases %standard-phases
2346 ;; no configure script
2347 (delete 'configure))))
2348 (home-page "http://www.openh264.org/")
2349 (synopsis "H264 decoder library")
2350 (description
2351 "Openh264 is a library which can decode H264 video streams.")
2352 (license license:bsd-2)))
3a44c7bb 2353
2354(define-public libmp4v2
2355 (package
2356 (name "libmp4v2")
2357 (version "2.0.0")
2358 (source
2359 (origin
2360 (method url-fetch)
2361 ;; XXX: The new location of upstream is uncertain and will become relevant the
2362 ;; moment when the googlecode archive shuts down. It is past the date it
2363 ;; should've been turned off. I tried to communicate with upstream, but this
2364 ;; wasn't very responsive and not very helpful. The short summary is, it is
2365 ;; chaos when it comes to the amount of forks and only time will tell where
2366 ;; the new upstream location is.
2367 (uri (string-append "https://storage.googleapis.com/google-"
2368 "code-archive-downloads/v2/"
2369 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
2370 (file-name (string-append name "-" version ".tar.bz2"))
2371 (sha256
2372 (base32
2373 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
2374 (build-system gnu-build-system)
2375 (outputs '("out"
2376 "static")) ; 3.7MiB .a file
2377 (arguments
2378 `(#:phases
2379 (modify-phases %standard-phases
2380 (add-after 'unpack 'remove-dates
2381 (lambda _
2382 ;; Make the build reproducible.
2383 (substitute* "configure"
2384 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
2385 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
2386 #t))
2387 (add-after 'install 'move-static-libraries
2388 (lambda* (#:key outputs #:allow-other-keys)
2389 ;; Move static libraries to the "static" output.
2390 (let* ((out (assoc-ref outputs "out"))
2391 (lib (string-append out "/lib"))
2392 (static (assoc-ref outputs "static"))
2393 (slib (string-append static "/lib")))
2394 (mkdir-p slib)
2395 (for-each (lambda (file)
2396 (install-file file slib)
2397 (delete-file file))
2398 (find-files lib "\\.a$"))
2399 #t))))))
2400 (native-inputs
2401 `(("help2man" ,help2man)
2402 ("dejagnu" ,dejagnu)))
2403 (home-page "https://code.google.com/archive/p/mp4v2/")
2404 (synopsis "API to create and modify mp4 files")
2405 (description
2406 "The MP4v2 library provides an API to create and modify mp4 files as defined by
2407ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
2408file format that has been used as a multimedia file format in a variety of platforms and
2409applications. It is a very powerful and extensible format that can accommodate
2410practically any type of media.")
2411 (license license:mpl1.1)))
e0c40707
EJ
2412
2413(define-public libmediainfo
2414 (package
2415 (name "libmediainfo")
2416 (version "0.7.95")
2417 (source (origin
2418 (method url-fetch)
2419 (uri (string-append "https://mediaarea.net/download/source/"
2420 name "/" version"/"
2421 name "_" version ".tar.bz2"))
2422 (sha256
2423 (base32
2424 "1kchh6285b07z5nixv619hc9gml2ysdayicdiv30frrlqiyxqw4b"))))
2425 ;; TODO add a Big Buck Bunny webm for tests.
2426 (native-inputs
2427 `(("autoconf" ,autoconf)
2428 ("automake" ,automake)
2429 ("libtool" ,libtool)
2430 ("pkg-config" ,pkg-config)
2431 ("zlib" ,zlib)
2432 ("tinyxml2" ,tinyxml2)
2433 ("curl" ,curl)
2434 ("libzen" ,libzen)))
2435 (build-system gnu-build-system)
2436 (arguments
2437 '(#:tests? #f ; see above TODO
2438 #:phases
2439 ;; build scripts not in root of archive
2440 (modify-phases %standard-phases
0cae36b5 2441 (add-after 'unpack 'change-to-build-dir
e0c40707 2442 (lambda _
0cae36b5
EF
2443 (chdir "Project/GNU/Library")
2444 #t))
2445 (add-after 'change-to-build-dir 'autogen
e0c40707 2446 (lambda _
d10092b8 2447 (zero? (system* "sh" "autogen.sh")))))))
e0c40707
EJ
2448 (home-page "https://mediaarea.net/en/MediaInfo")
2449 (synopsis "Library for retrieving media metadata")
2450 (description "MediaInfo is a library used for retrieving technical
2451information and other metadata about audio or video files. A non-exhaustive
2452list of the information MediaInfo can retrieve from media files include:
2453
2454@itemize
2455@item General: title, author, director, album, track number, date, duration...
2456@item Video: codec, aspect, fps, bitrate...
2457@item Audio: codec, sample rate, channels, language, bitrate...
2458@item Text: language of subtitle
2459@item Chapters: number of chapters, list of chapters
2460@end itemize
2461
2462MediaInfo supports the following formats:
2463
2464@itemize
2465@item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
2466MPEG-2, MPEG-4, DVD (VOB)...
2467@item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
2468@item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
2469@item Subtitles: SRT, SSA, ASS, SAMI...
2470@end itemize\n")
2471 (license license:bsd-2)))
2472
d5fa2777
EJ
2473;; TODO also have a GUI version available
2474(define-public mediainfo
2475 (package
2476 (name "mediainfo")
2477 (version "0.7.95")
2478 (source (origin
2479 (method url-fetch)
2480 (uri (string-append "https://mediaarea.net/download/source/"
2481 name "/" version "/"
2482 name "_" version ".tar.bz2"))
2483 (sha256
2484 (base32
2485 "0dy51a3i79jppmg1gi4f6h7jx4hcgnkmfim4d7d3gmnlbkjh8anv"))))
2486 (native-inputs
2487 `(("autoconf" ,autoconf)
2488 ("automake" ,automake)
2489 ("libtool" ,libtool)
2490 ("pkg-config" ,pkg-config)
2491 ("zlib" ,zlib)
c695fb76 2492 ("libmediainfo" ,libmediainfo)
d5fa2777
EJ
2493 ("libzen" ,libzen)))
2494 (build-system gnu-build-system)
2495 (arguments
2496 '(#:tests? #f ; lacks tests
2497 #:phases
2498 ;; build scripts not in root of archive
2499 (modify-phases %standard-phases
2f17187f 2500 (add-after 'unpack 'change-to-build-dir
d5fa2777 2501 (lambda _
2f17187f
EF
2502 (chdir "Project/GNU/CLI")
2503 #t))
2504 (add-after 'change-to-build-dir 'autogen
d5fa2777 2505 (lambda _
d10092b8 2506 (zero? (system* "sh" "autogen.sh")))))))
d5fa2777
EJ
2507 (home-page "https://mediaarea.net/en/MediaInfo")
2508 (synopsis "Utility for reading media metadata")
2509 (description "MediaInfo is a utility used for retrieving technical
2510information and other metadata about audio or video files. It supports the
2511many codecs and formats supported by libmediainfo.")
2512 (license license:bsd-2)))
fa379a5b
CL
2513
2514(define-public livemedia-utils
2515 (package
2516 (name "livemedia-utils")
7342edf3 2517 (version "2017.10.28")
fa379a5b
CL
2518 (source (origin
2519 (method url-fetch)
2520 (uri (string-append
517c66c0 2521 "https://download.videolan.org/contrib/live555/live."
fa379a5b
CL
2522 version ".tar.gz"))
2523 (sha256
2524 (base32
7342edf3 2525 "0f5kxpayqn3yhabqrd2cqlc74i6x2xr01jfkank1lcilxnfyrsnq"))
156c14c1
LC
2526 (modules '((guix build utils)))
2527 (snippet
2528 ;; As of glibc 2.26, <xlocale.h> no longer is.
2529 '(substitute* "liveMedia/include/Locale.hh"
2530 (("xlocale\\.h") "locale.h")))))
fa379a5b
CL
2531 (build-system gnu-build-system)
2532 (arguments
2533 '(#:tests? #f ; no tests
2534 #:make-flags (list "CC=gcc"
2535 (string-append "LDFLAGS=-Wl,-rpath="
2536 (assoc-ref %outputs "out") "/lib")
2537 (string-append "PREFIX="
2538 (assoc-ref %outputs "out")))
2539 #:phases (modify-phases %standard-phases
2540 (add-before 'configure 'fix-makefiles-generation
2541 (lambda _
2542 (substitute* "genMakefiles"
2543 (("/bin/rm") "rm"))
2544 #t))
2545 (replace 'configure
2546 (lambda _
2547 (zero? (system* "./genMakefiles"
2548 "linux-with-shared-libraries")))))))
2549 (home-page "http://www.live555.com/liveMedia/")
2550 (synopsis "Set of C++ libraries for multimedia streaming")
2551 (description "This code forms a set of C++ libraries for multimedia
2552streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
2553can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
2554JPEG video, and several audio codecs. They can easily be extended to support
2555additional (audio and/or video) codecs, and can also be used to build basic
2556RTSP or SIP clients and servers.")
2557 (license license:lgpl3+)))
0dff4dd9
CL
2558
2559(define-public libdvbpsi
2560 (package
2561 (name "libdvbpsi")
74b977d7 2562 (version "1.3.2")
0dff4dd9
CL
2563 (source (origin
2564 (method url-fetch)
2565 (uri (string-append
2566 "https://download.videolan.org/pub/libdvbpsi/"
2567 version "/libdvbpsi-" version ".tar.bz2"))
2568 (sha256
2569 (base32
74b977d7 2570 "1zn5hfv4qbahmydbwh59a3b480s3m5ss27r6ml35gqdip7r3jkmc"))))
0dff4dd9
CL
2571 (build-system gnu-build-system)
2572 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
2573 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
2574tables")
2575 (description "libdvbpsi is a simple library designed for decoding and
2576generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
2577and ITU-T H.222.0.")
2578 (license license:lgpl2.1)))
6779ae27
JL
2579
2580(define-public ffms2
2581 (package
2582 (name "ffms2")
2583 (version "2.23")
b1eaede0 2584 (home-page "https://github.com/FFMS/ffms2")
6779ae27
JL
2585 (source (origin
2586 (method url-fetch)
b1eaede0 2587 (uri (string-append home-page "/archive/" version ".tar.gz"))
6779ae27
JL
2588 (file-name (string-append name "-" version ".tar.gz"))
2589 (sha256
2590 (base32
2591 "1vbkab8vrplxz5xgag8ggzkwp4f7nf285pd0l2a7zy66n6i2m6xh"))))
2592 (build-system gnu-build-system)
2593 (arguments
2594 '(#:configure-flags
2595 (list "--enable-avresample")))
2596 (inputs
2597 `(("zlib" ,zlib)))
2598 (propagated-inputs
2599 `(("ffmpeg" ,ffmpeg)))
2600 (native-inputs
2601 `(("pkg-config" ,pkg-config)))
2602 (synopsis "Cross-platform wrapper around ffmpeg/libav")
2603 (description
2604 "FFMpegSource is a wrapper library around ffmpeg/libav that allows
2605programmers to access a standard API to open and decompress media files.")
2606 ;; sources are distributed under a different license that the binary.
2607 ;; see https://github.com/FFMS/ffms2/blob/master/COPYING
2608 (license license:gpl2+))); inherits from ffmpeg
c812f460
JL
2609
2610(define-public aegisub
2611 (package
2612 (name "aegisub")
2613 (version "3.2.2")
2614 (source (origin
2615 (method url-fetch)
2616 (uri (string-append
2617 "http://ftp.aegisub.org/pub/archives/releases/source/"
2618 name "-" version ".tar.xz"))
2619 (sha256
2620 (base32
2621 "11b83qazc8h0iidyj1rprnnjdivj1lpphvpa08y53n42bfa36pn5"))))
2622 (build-system gnu-build-system)
2623 (arguments
2624 `(#:configure-flags
2625 (list "--disable-update-checker"
2626 "--without-portaudio"
2627 "--without-openal"
2628 "--without-oss")
2629 ;; tests require busted, a lua package we don't have yet
2630 #:tests? #f
2631 #:phases
2632 (modify-phases %standard-phases
2633 (add-before 'configure 'fix-ldflags
2634 (lambda _
2635 (setenv "LDFLAGS" "-pthread"))))))
2636 (inputs
2637 `(("boost" ,boost)
2638 ("desktop-file-utils" ,desktop-file-utils)
2639 ("ffms2" ,ffms2)
2640 ("fftw" ,fftw)
2641 ("hunspell" ,hunspell)
2642 ("mesa" ,mesa)
2643 ("libass" ,libass)
2644 ("alsa-lib" ,alsa-lib)
2645 ("pulseaudio" ,pulseaudio)
2646 ("libx11" ,libx11)
2647 ("freetype" ,freetype)
2648 ("wxwidgets-gtk2" ,wxwidgets-gtk2)))
2649 (native-inputs
2650 `(("intltool" ,intltool)
2651 ("pkg-config" ,pkg-config)))
2652 (home-page "http://www.aegisub.org/")
2653 (synopsis "Subtitle engine")
2654 (description
2655 "Aegisub is a tool for creating and modifying subtitles. Aegisub makes
2656it quick and easy to time subtitles to audio, and features many powerful
2657tools for styling them, including a built-in real-time video preview.")
2658 (license (list license:bsd-3 ; the package is licensed under the bsd-3, except
2659 license:mpl1.1 ; for vendor/universalchardet under the mpl1.1
2660 license:expat)))) ; and src/gl that is under a license similar
2661 ; the the Expat license, with a rewording (Software -> Materials). (called MIT
2662 ; by upstream). See https://github.com/Aegisub/Aegisub/blob/master/LICENCE
2663 ; src/MatroskaParser.(c|h) is under bsd-3 with permission from the author
2664
635f981b 2665(define-public gst-transcoder
2666 (package
2667 (name "gst-transcoder")
2668 (version "1.12.2")
2669 (source
2670 (origin
2671 (method url-fetch)
2672 (uri (string-append "https://github.com/pitivi/gst-transcoder/"
2673 "archive/" version ".tar.gz"))
2674 (file-name (string-append name "-" version ".tar.gz"))
2675 (sha256
2676 (base32
2677 "0cnwmrsd321s02ff91m3j27ydj7f8wks0jvmp5admlhka6z7zxm9"))))
2678 (build-system meson-build-system)
2679 (inputs
2680 `(("gobject-introspection" ,gobject-introspection)
2681 ("glib" ,glib)
2682 ("gstreamer" ,gstreamer)
2683 ("gst-plugins-base" ,gst-plugins-base)))
2684 (native-inputs
2685 `(("python" ,python)
2686 ("pkg-config" ,pkg-config)))
2687 (home-page "https://github.com/pitivi/gst-transcoder/")
2688 (synopsis "GStreamer Transcoding API")
2689 (description "GStreamer Transcoding API")
2690 (license license:lgpl2.1)))
e37bdc0f 2691
2692(define-public gavl
2693 (package
2694 (name "gavl")
2695 (version "1.4.0")
2696 (source
2697 (origin
2698 (method url-fetch)
2699 (uri (string-append "mirror://sourceforge/gmerlin/"
2700 name "/" version "/"
2701 name "-" version ".tar.gz"))
2702 (file-name (string-append name "-" version ".tar.gz"))
2703 (sha256
2704 (base32
2705 "1kikkn971a14zzm7svi7190ldc14fjai0xyhpbcmp48s750sraji"))))
2706 (build-system gnu-build-system)
c178aa34
EF
2707 (arguments
2708 '(#:configure-flags '("LIBS=-lm")))
e37bdc0f 2709 (native-inputs
2710 `(("pkg-config" ,pkg-config)
2711 ("doxygen" ,doxygen)))
2712 (home-page "http://gmerlin.sourceforge.net")
2713 (synopsis "Low level library for multimedia API building")
2714 (description
2715 "Gavl is short for Gmerlin Audio Video Library. It is a low level
2716library, upon which multimedia APIs can be built. Gavl handles all the
2717details of audio and video formats like colorspaces, sample rates,
2718multichannel configurations, etc. It provides standardized definitions for
2719those formats as well as container structures for carrying audio samples or
2720video images inside an application.
2721
2722In addition, it handles the sometimes ugly task of converting between all
2723these formats and provides some elementary operations (copying, scaling,
2724alpha blending etc).")
2725 (license license:gpl3)))
49e1d76d 2726
2727(define-public frei0r-plugins
2728 (package
2729 (name "frei0r-plugins")
2730 (version "1.6.1")
2731 (source
2732 (origin
2733 (method url-fetch)
2734 (uri (string-append "https://files.dyne.org/frei0r/"
2735 "frei0r-plugins-" version ".tar.gz"))
2736 (sha256
2737 (base32
2738 "0pji26fpd0dqrx1akyhqi6729s394irl73dacnyxk58ijqq4dhp0"))))
2739 (build-system gnu-build-system)
2740 (arguments
2741 `(#:phases
2742 (modify-phases %standard-phases
2743 (add-after 'unpack 'autotools
2744 (lambda _
2745 (zero? (system* "sh" "autogen.sh")))))))
2746 ;; TODO: opencv for additional face detection filters
2747 (inputs
2748 `(("gavl" ,gavl)
2749 ("cairo" ,cairo)))
2750 (native-inputs
2751 `(("pkg-config" ,pkg-config)
2752 ("libtool" ,libtool)
2753 ("automake" ,automake)
2754 ("autoconf" ,autoconf)))
2755 (home-page "https://www.dyne.org/software/frei0r/")
2756 (synopsis "Minimalistic plugin API for video effects")
2757 (description
2758 "Frei0r is a minimalistic plugin API for video effects.
2759The main emphasis is on simplicity for an API that will round up
2760the most common video effects into simple filters, sources and
2761mixers that can be controlled by parameters. Frei0r wants to
2762provide a way to share these simple effects between many
2763applications, avoiding their reimplementation by different projects.
2764It counts more than 100 plugins.")
2765 (license (list license:gpl2+
2766 ;; The following files are licensed as LGPL2.1+:
2767 ;; src/generator/ising0r/ising0r.c
2768 ;; src/generator/onecol0r/onecol0r.cpp
2769 ;; src/generator/nois0r/nois0r.cpp
2770 ;; src/generator/lissajous0r/lissajous0r.cpp
2771 ;; src/filter/ndvi/gradientlut.hpp
2772 ;; src/filter/ndvi/ndvi.cpp
2773 ;; src/filter/facedetect/facedetect.cpp
2774 license:lgpl2.1+))))
eb3e41c9
LC
2775
2776(define-public motion
2777 (package
2778 (name "motion")
2779 (version "4.1.1")
2780 (home-page "https://motion-project.github.io/")
2781 (source (origin
2782 (method url-fetch)
2783 (uri (string-append
2784 "https://github.com/Motion-Project/motion/archive/"
2785 "release-" version ".tar.gz"))
2786 (sha256
2787 (base32
2788 "1qm4i8zrqafl60sv2frhixvkd0wh0r5jfcrj5i6gha7yplsvjx10"))
2789 (file-name (string-append name "-" version ".tar.gz"))))
2790 (build-system gnu-build-system)
2791 (native-inputs
464f5447 2792 `(("autoconf" ,autoconf-wrapper)
eb3e41c9
LC
2793 ("automake" ,automake)
2794 ("pkg-config" ,pkg-config)))
2795 (inputs
2796 `(("libjpeg" ,libjpeg)
bb5c508c 2797 ("ffmpeg" ,ffmpeg-3.4)
eb3e41c9
LC
2798 ("sqlite" ,sqlite)))
2799 (arguments
2800 '(#:phases (modify-phases %standard-phases
2801 (add-after 'unpack 'bootstrap
2802 (lambda _
2803 (patch-shebang "version.sh")
2804 (invoke "autoreconf" "-vfi"))))
2805 #:configure-flags '("--sysconfdir=/etc")
2806 #:make-flags (list (string-append "sysconfdir="
2807 (assoc-ref %outputs "out")
2808 "/etc"))
2809
2810 #:tests? #f)) ;no 'check' target
2811 (synopsis "Detect motion from video signals")
2812 (description
2813 "Motion is a program that monitors the video signal from one or more
2814cameras and is able to detect if a significant part of the picture has
2815changed. Or in other words, it can detect motion.")
2816
2817 ;; Some files say "version 2" and others "version 2 or later".
2818 (license license:gpl2)))
f27f264e
PN
2819
2820(define-public subdl
2821 (let ((commit "4cf5789b11f0ff3f863b704b336190bf968cd471")
2822 (revision "1"))
2823 (package
2824 (name "subdl")
2825 (version (git-version "1.0.3" revision commit))
2826 (source (origin
2827 (method git-fetch)
2828 (uri (git-reference
2829 (url "https://github.com/alexanderwink/subdl.git")
2830 (commit commit)))
2831 (file-name (git-file-name name version))
2832 (sha256
2833 (base32
2834 "0kmk5ck1j49q4ww0lvas2767kwnzhkq0vdwkmjypdx5zkxz73fn8"))))
2835 (build-system trivial-build-system)
2836 (arguments
2837 `(#:modules ((guix build utils))
2838 #:builder (begin
2839 (use-modules (guix build utils))
2840 (let* ((out (assoc-ref %outputs "out"))
2841 (bin (string-append out "/bin"))
2842 (source (assoc-ref %build-inputs "source"))
2843 (python (assoc-ref %build-inputs "python")))
2844 (install-file (string-append source "/subdl") bin)
2845 (patch-shebang (string-append bin "/subdl")
2846 (list (string-append python "/bin")))))))
2847 (inputs `(("python" ,python)))
2848 (synopsis "Command-line tool for downloading subtitles from opensubtitles.org")
2849 (description "Subdl is a command-line tool for downloading subtitles from
2850opensubtitles.org. By default, it will search for English subtitles, display
2851the results, download the highest-rated result in the requested language and
2852save it to the appropriate filename.")
2853 (license license:gpl3+)
2854 (home-page "https://github.com/alexanderwink/subdl"))))
eb88e2c1
CL
2855
2856(define-public l-smash
2857 (package
2858 (name "l-smash")
2859 (version "2.14.5")
2860 (source (origin
2861 (method url-fetch)
2862 (uri (string-append
2863 "https://github.com/" name "/" name "/archive/v"
2864 version ".tar.gz"))
2865 (file-name (string-append name "-" version ".tar.gz"))
2866 (sha256
2867 (base32
2868 "0dary0h65kq6sv93iabv25djlvzr5ckdcp3ywagbix44wqfw7xz6"))))
2869 (build-system gnu-build-system)
2870 (arguments
2871 `(#:tests? #f ;no tests
2872 #:make-flags
2873 (list (string-append "LDFLAGS=-Wl,-L.,-rpath="
2874 (assoc-ref %outputs "out") "/lib"))
2875 #:phases
2876 (modify-phases %standard-phases
2877 ;; configure fails if it is followed by CONFIG_SHELL
2878 (replace 'configure
2879 (lambda* (#:key outputs #:allow-other-keys)
2880 (let ((out (assoc-ref outputs "out")))
2881 (invoke "./configure" (string-append "--prefix=" out)
2882 "--disable-static")))))))
2883 (native-inputs
2884 `(("which" ,which)))
2885 (home-page "https://l-smash.github.io/l-smash/")
2886 (synopsis "MP4 multiplexer and demultiplexer library")
2887 (description
2888 "L-SMASH is a cross-platform library that handles the ISO base media file
2889format and some of its derived file formats, including MP4. It operates as a
2890multiplexer and demultiplexer, and can mux video and audio in several formats
2891using standalone executable files.")
2892 (license license:isc)))