Merge branch 'staging' into core-updates
[jackhill/guix/guix.git] / gnu / packages / video.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2014, 2015, 2016 David Thompson <davet@gnu.org>
4 ;;; Copyright © 2014, 2015, 2016, 2018 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
6 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2015 Andy Patterson <ajpatter@uwaterloo.ca>
8 ;;; Copyright © 2015, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Alex Vong <alexvong1995@gmail.com>
10 ;;; Copyright © 2016, 2017 Alex Griffin <a@ajgrf.com>
11 ;;; Copyright © 2016 Kei Kebreau <kkebreau@posteo.net>
12 ;;; Copyright © 2016 Dmitry Nikolaev <cameltheman@gmail.com>
13 ;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca>
14 ;;; Copyright © 2016, 2017 Nils Gillmann <ng0@n0.is>
15 ;;; Copyright © 2016, 2018, 2019 Eric Bavier <bavier@member.fsf.org>
16 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
17 ;;; Copyright © 2017 Feng Shu <tumashu@163.com>
18 ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
19 ;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com>
20 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
21 ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
22 ;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org>
23 ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
24 ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com>
25 ;;; Copyright © 2018 Roel Janssen <roel@gnu.org>
26 ;;; Copyright © 2018, 2019 Marius Bakke <mbakke@fastmail.com>
27 ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
28 ;;; Copyright © 2018 Leo Famulari <leo@famulari.name>
29 ;;; Copyright © 2018 Brendan Tildesley <brendan.tildesley@openmailbox.org>
30 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
31 ;;; Copyright © 2018 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
32 ;;; Copyright © 2018 Mark Meyer <mark@ofosos.org>
33 ;;; Copyright © 2018 Gábor Boskovit <boskovits@gmail.com>
34 ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
35 ;;; Copyright © 2019 Timo Eisenmann <eisenmann@fn.de>
36 ;;; Copyright © 2019 Arne Babenhauserheide <arne_bab@web.de>
37 ;;;
38 ;;; This file is part of GNU Guix.
39 ;;;
40 ;;; GNU Guix is free software; you can redistribute it and/or modify it
41 ;;; under the terms of the GNU General Public License as published by
42 ;;; the Free Software Foundation; either version 3 of the License, or (at
43 ;;; your option) any later version.
44 ;;;
45 ;;; GNU Guix is distributed in the hope that it will be useful, but
46 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
47 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
48 ;;; GNU General Public License for more details.
49 ;;;
50 ;;; You should have received a copy of the GNU General Public License
51 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
52
53 (define-module (gnu packages video)
54 #:use-module (ice-9 match)
55 #:use-module (srfi srfi-1)
56 #:use-module (srfi srfi-26)
57 #:use-module ((guix licenses) #:prefix license:)
58 #:use-module (guix utils)
59 #:use-module (guix packages)
60 #:use-module (guix download)
61 #:use-module (guix git-download)
62 #:use-module (guix svn-download)
63 #:use-module (guix build-system cmake)
64 #:use-module (guix build-system gnu)
65 #:use-module (guix build-system glib-or-gtk)
66 #:use-module (guix build-system meson)
67 #:use-module (guix build-system perl)
68 #:use-module (guix build-system python)
69 #:use-module (guix build-system waf)
70 #:use-module (guix build-system trivial)
71 #:use-module (gnu packages)
72 #:use-module (gnu packages algebra)
73 #:use-module (gnu packages assembly)
74 #:use-module (gnu packages audio)
75 #:use-module (gnu packages autotools)
76 #:use-module (gnu packages avahi)
77 #:use-module (gnu packages backup)
78 #:use-module (gnu packages base)
79 #:use-module (gnu packages bison)
80 #:use-module (gnu packages boost)
81 #:use-module (gnu packages cdrom)
82 #:use-module (gnu packages check)
83 #:use-module (gnu packages cmake)
84 #:use-module (gnu packages compression)
85 #:use-module (gnu packages cpp)
86 #:use-module (gnu packages curl)
87 #:use-module (gnu packages dejagnu)
88 #:use-module (gnu packages dns)
89 #:use-module (gnu packages docbook)
90 #:use-module (gnu packages documentation)
91 #:use-module (gnu packages elf)
92 #:use-module (gnu packages file)
93 #:use-module (gnu packages flex)
94 #:use-module (gnu packages fontutils)
95 #:use-module (gnu packages freedesktop)
96 #:use-module (gnu packages fribidi)
97 #:use-module (gnu packages gettext)
98 #:use-module (gnu packages ghostscript)
99 #:use-module (gnu packages gl)
100 #:use-module (gnu packages glib)
101 #:use-module (gnu packages guile)
102 #:use-module (gnu packages gnome)
103 #:use-module (gnu packages gnunet)
104 #:use-module (gnu packages gnupg)
105 #:use-module (gnu packages gstreamer)
106 #:use-module (gnu packages gtk)
107 #:use-module (gnu packages image)
108 #:use-module (gnu packages imagemagick)
109 #:use-module (gnu packages iso-codes)
110 #:use-module (gnu packages libidn)
111 #:use-module (gnu packages libreoffice)
112 #:use-module (gnu packages linux)
113 #:use-module (gnu packages lua)
114 #:use-module (gnu packages m4)
115 #:use-module (gnu packages man)
116 #:use-module (gnu packages markup)
117 #:use-module (gnu packages mp3)
118 #:use-module (gnu packages ncurses)
119 #:use-module (gnu packages networking)
120 #:use-module (gnu packages ocr)
121 #:use-module (gnu packages perl)
122 #:use-module (gnu packages pkg-config)
123 #:use-module (gnu packages popt)
124 #:use-module (gnu packages pretty-print)
125 #:use-module (gnu packages protobuf)
126 #:use-module (gnu packages pulseaudio)
127 #:use-module (gnu packages python)
128 #:use-module (gnu packages python-crypto)
129 #:use-module (gnu packages python-web)
130 #:use-module (gnu packages python-xyz)
131 #:use-module (gnu packages qt)
132 #:use-module (gnu packages rdesktop)
133 #:use-module (gnu packages ruby)
134 #:use-module (gnu packages samba)
135 #:use-module (gnu packages sdl)
136 #:use-module (gnu packages serialization)
137 #:use-module (gnu packages shells)
138 #:use-module (gnu packages sqlite)
139 #:use-module (gnu packages ssh)
140 #:use-module (gnu packages swig)
141 #:use-module (gnu packages texinfo)
142 #:use-module (gnu packages textutils)
143 #:use-module (gnu packages tls)
144 #:use-module (gnu packages time)
145 #:use-module (gnu packages upnp)
146 #:use-module (gnu packages version-control)
147 #:use-module (gnu packages vulkan)
148 #:use-module (gnu packages web)
149 #:use-module (gnu packages webkit)
150 #:use-module (gnu packages wxwidgets)
151 #:use-module (gnu packages xdisorg)
152 #:use-module (gnu packages xiph)
153 #:use-module (gnu packages xml)
154 #:use-module (gnu packages xorg))
155
156 (define-public aalib
157 (package
158 (name "aalib")
159 (version "1.4rc5")
160 (source (origin
161 (method url-fetch)
162 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
163 version "/" name "-" version ".tar.gz"))
164 (sha256
165 (base32
166 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
167 (build-system gnu-build-system)
168 (native-inputs
169 `(("makeinfo" ,texinfo)))
170 (inputs
171 `(("ncurses" ,ncurses)))
172 (arguments
173 `(#:phases
174 (modify-phases %standard-phases
175 (replace 'configure
176 (lambda* (#:key build inputs outputs #:allow-other-keys)
177 ;; This old `configure' script doesn't support
178 ;; variables passed as arguments.
179 (let ((out (assoc-ref outputs "out"))
180 (ncurses (assoc-ref inputs "ncurses")))
181 (setenv "CONFIG_SHELL" (which "bash"))
182 (invoke "./configure"
183 (string-append "--prefix=" out)
184 (string-append "--build=" build)
185 ;; The ancient config.guess is unable to
186 ;; guess the host triplet on mips64el.
187 ,@(if (string=? "mips64el-linux"
188 (%current-system))
189 '("--host=mips64el-unknown-linux-gnu")
190 '())
191 ;; The same is also true with aarch64.
192 ,@(if (string=? "aarch64-linux"
193 (%current-system))
194 '("--host=aarch64-unknown-linux-gnu")
195 '())
196 (string-append "--with-ncurses="
197 ncurses))))))))
198 (home-page "http://aa-project.sourceforge.net/aalib/")
199 (synopsis "ASCII-art library")
200 (description
201 "AA-lib is a low level gfx library which does not require graphics device.
202 In fact, there is no graphical output possible. AA-lib replaces those
203 old-fashioned output methods with powerful ascii-art renderer.")
204 (license license:lgpl2.0+)))
205
206 (define-public liba52
207 (package
208 (name "liba52")
209 (version "0.7.4")
210 (source (origin
211 (method url-fetch)
212 (uri (string-append
213 ;; A mirror://sourceforge URI doesn't work, presumably
214 ;; because the SourceForge project is misconfigured.
215 "http://liba52.sourceforge.net/files/a52dec-" version
216 ".tar.gz"))
217 (sha256
218 (base32
219 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
220 (patches (search-patches "liba52-enable-pic.patch"
221 "liba52-set-soname.patch"
222 "liba52-use-mtune-not-mcpu.patch"
223 "liba52-link-with-libm.patch"))))
224 (build-system gnu-build-system)
225 ;; XXX We need to run ./bootstrap because of the build system fixes above.
226 (native-inputs
227 `(("autoconf" ,autoconf)
228 ("automake" ,automake)
229 ("libtool" ,libtool)))
230 (arguments `(#:configure-flags '("--enable-shared")
231 #:phases
232 (modify-phases %standard-phases
233 ;; XXX We need to run ./bootstrap because of the build
234 ;; system fixes above.
235 (replace 'bootstrap
236 (lambda _ (invoke "sh" "bootstrap"))))))
237 (home-page "http://liba52.sourceforge.net/")
238 (synopsis "ATSC A/52 stream decoder")
239 (description "liba52 is a library for decoding ATSC A/52 streams. The
240 A/52 standard is used in a variety of applications, including digital
241 television and DVD. It is also known as AC-3.")
242 (license license:gpl2+)))
243
244 (define-public libaom
245 ;; The 1.0.0-errata1 release installs a broken pkg-config .pc file. This
246 ;; is fixed in libaom commit 0ddc150, but we use an even later commit.
247 (let ((commit "22b150bf040608028a56d8bf39e72f771383d836")
248 (revision "0"))
249 (package
250 (name "libaom")
251 (version (git-version "1.0.0-errata1" revision commit))
252 (source (origin
253 (method git-fetch)
254 (uri (git-reference
255 (url "https://aomedia.googlesource.com/aom/")
256 (commit commit)))
257 (file-name (git-file-name name version))
258 (sha256
259 (base32
260 "1pdd5h3n42607n6qmggz4yv8izhjr2kl6knb3kh7gh4v0vy47h1r"))))
261 (build-system cmake-build-system)
262 (native-inputs
263 `(("perl" ,perl)
264 ("pkg-config" ,pkg-config)
265 ("python" ,python))) ; to detect the version
266 (arguments
267 `(#:tests? #f ;no check target
268 #:configure-flags
269 ;; build dynamic library
270 (list "-DBUILD_SHARED_LIBS=YES"
271 "-DENABLE_PIC=TRUE"
272 "-DAOM_TARGET_CPU=generic"
273 (string-append "-DCMAKE_INSTALL_PREFIX="
274 (assoc-ref %outputs "out")))))
275 (home-page "https://aomedia.googlesource.com/aom/")
276 (synopsis "AV1 video codec")
277 (description "Libaom is the reference implementation of AV1. It includes
278 a shared library and encoder and decoder command-line executables.")
279 (license license:bsd-2))))
280
281 (define-public libmpeg2
282 (package
283 (name "libmpeg2")
284 (version "0.5.1")
285 (source (origin
286 (method url-fetch)
287 ;; A mirror://sourceforge URI doesn't work, presumably
288 ;; because the SourceForge project is misconfigured.
289 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
290 name "-" version ".tar.gz"))
291 (sha256
292 (base32
293 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
294 (inputs
295 `(("libx11" ,libx11)
296 ("libxext" ,libxext)
297 ("libxv" ,libxv)
298 ("libsm" ,libsm)
299 ("libice" ,libice)
300 ("sdl" ,sdl)))
301 (build-system gnu-build-system)
302 (home-page "http://libmpeg2.sourceforge.net/")
303 (synopsis "MPEG1 and MPEG2 video decoder library")
304 (description
305 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
306 (license license:gpl2+)))
307
308 (define-public libx264
309 (package
310 (name "libx264")
311 (version "20180810-2245")
312 (source (origin
313 (method url-fetch)
314 (uri (string-append "https://download.videolan.org/pub/x264/snapshots/"
315 "x264-snapshot-" version "-stable.tar.bz2"))
316 (sha256
317 (base32
318 "0f25f39imas9pcqm7lnaa0shhjmf42hdx7jxzcnvxc7qsb7lh1bv"))))
319 (build-system gnu-build-system)
320 (native-inputs
321 `(("pkg-config" ,pkg-config)
322 ("nasm" ,nasm)))
323 ;; TODO: Add gpac input
324 (arguments
325 `(#:tests? #f ;no check target
326 #:configure-flags '("--enable-shared"
327 ;; Don't build the command-line program. If we
328 ;; want it later, we should do so in a different
329 ;; package to avoid a circular dependency (the x264
330 ;; program depends on ffmpeg and ffmpeg depends on
331 ;; libx264).
332 "--disable-cli"
333
334 ;; On MIPS, we must pass "--disable-asm" or else
335 ;; configure fails after printing: "You specified a
336 ;; pre-MSA CPU in your CFLAGS. If you really want
337 ;; to run on such a CPU, configure with
338 ;; --disable-asm."
339 ,@(if (string-prefix? "mips"
340 (or (%current-target-system)
341 (%current-system)))
342 '("--disable-asm")
343 '()))))
344 (home-page "https://www.videolan.org/developers/x264.html")
345 (synopsis "H.264 video coding library")
346 (description "libx264 is an advanced encoding library for creating
347 H.264 (MPEG-4 AVC) video streams.")
348 (license (list license:gpl2+ ;most files
349 license:isc ;common/x86/x86inc.asm
350 license:lgpl2.1+ ;extras/getopt.c
351 license:bsd-3 ;extras/inttypes.h
352 (license:non-copyleft ;extras/cl*.h
353 "file://extras/cl.h"
354 "See extras/cl.h in the distribution.")))))
355
356 (define-public mkvtoolnix
357 (package
358 (name "mkvtoolnix")
359 (version "31.0.0")
360 (source
361 (origin
362 (method url-fetch)
363 (uri (string-append "https://mkvtoolnix.download/sources/"
364 name "-" version ".tar.xz"))
365 (sha256
366 (base32
367 "0d8va2iamzc7y3wi71z8mk2vnqvnkgwb2p7casdfp37400x8r2pr"))
368 (modules '((guix build utils)))
369 (snippet '(begin
370 ;; Delete bundled libraries.
371 (for-each delete-file-recursively
372 '("lib/fmt"
373 "lib/libebml"
374 "lib/libmatroska"
375 "lib/nlohmann-json"
376 "lib/pugixml"
377 "lib/utf8-cpp"))
378 #t))))
379 (build-system gnu-build-system)
380 (inputs
381 `(("boost" ,boost)
382 ("bzip2" ,bzip2)
383 ("cmark" ,cmark)
384 ("libebml" ,libebml)
385 ("file" ,file)
386 ("flac" ,flac)
387 ("fmt" ,fmt)
388 ("libmatroska" ,libmatroska)
389 ("libogg" ,libogg)
390 ("libvorbis" ,libvorbis)
391 ("lzo" ,lzo)
392 ("pugixml" ,pugixml)
393 ("qtbase" ,qtbase)
394 ("qtmultimedia" ,qtmultimedia)
395 ("utfcpp" ,utfcpp)
396 ("zlib" ,zlib)))
397 (native-inputs
398 `(("docbook-xsl" ,docbook-xsl)
399 ("gettext" ,gettext-minimal)
400 ("googletest" ,googletest)
401 ("libxslt" ,libxslt)
402 ("nlohmann-json-cpp" ,nlohmann-json-cpp)
403 ("perl" ,perl)
404 ("pkg-config" ,pkg-config)
405 ("po4a" ,po4a)
406 ("qttools" ,qttools)
407 ("ruby" ,ruby)))
408 (arguments
409 `(#:configure-flags
410 (list (string-append "--with-boost="
411 (assoc-ref %build-inputs "boost"))
412 (string-append "--with-docbook-xsl-root="
413 (assoc-ref %build-inputs "docbook-xsl")
414 "/xml/xsl/docbook-xsl-"
415 ,(package-version docbook-xsl))
416 "--enable-update-check=no"
417 "--enable-precompiled-headers=no")
418 #:phases
419 (modify-phases %standard-phases
420 (add-before 'configure 'add-googletest
421 (lambda* (#:key inputs #:allow-other-keys)
422 (symlink
423 (string-append (assoc-ref inputs "googletest")
424 "/include/gtest") "lib/gtest")
425 #t))
426 (replace 'build
427 (lambda _
428 (let ((-j (list "-j" (number->string (parallel-job-count)))))
429 (apply invoke "rake" -j))))
430 (replace 'check
431 (lambda _
432 (invoke "rake" "tests/unit")))
433 (replace 'install
434 (lambda _
435 (invoke "rake" "install"))))))
436 (home-page "https://mkvtoolnix.download")
437 (synopsis "Tools to create, alter and inspect Matroska files")
438 (description
439 "MKVToolNix provides tools for getting information about Matroska files
440 (@code{mkvinfo}), extracting tracks/data from Matroska files (@code{mkvextract})
441 and creating Matroska files from other media files (@code{mkvmerge}).")
442 (license license:gpl2)))
443
444 (define-public x265
445 (package
446 (name "x265")
447 (version "3.0")
448 (outputs '("out" "static"))
449 (source
450 (origin
451 (method url-fetch)
452 (uri (string-append "https://download.videolan.org/videolan/x265/"
453 "x265_" version ".tar.gz"))
454 (sha256
455 (base32
456 "0qh65wdpasrspkm1y0dlfa123myax568yi0sas0lmg5b1hkgrff5"))
457 (patches (search-patches "x265-arm-flags.patch"))
458 (modules '((guix build utils)))
459 (snippet '(begin
460 (delete-file-recursively "source/compat/getopt")
461 #t))))
462 (build-system cmake-build-system)
463 (arguments
464 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
465 #:configure-flags
466 ;; Ensure position independent code for everyone.
467 (list "-DENABLE_PIC=TRUE"
468 ,@(if (string-prefix? "armhf" (or (%current-system)
469 (%current-target-system)))
470 '("-DENABLE_ASSEMBLY=OFF")
471 '())
472 (string-append "-DCMAKE_INSTALL_PREFIX="
473 (assoc-ref %outputs "out")))
474 #:phases
475 (modify-phases %standard-phases
476 (add-after 'unpack 'prepare-build
477 (lambda _
478 (delete-file-recursively "build")
479 (chdir "source")
480 ;; recognize armv8 in 32-bit mode as ARM
481 (substitute* "CMakeLists.txt"
482 (("armv6l") "armv8l"))
483 #t))
484 (add-before 'configure 'build-12-bit
485 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
486 (mkdir "../build-12bit")
487 (with-directory-excursion "../build-12bit"
488 (apply invoke
489 "cmake" "../source"
490 "-DHIGH_BIT_DEPTH=ON"
491 "-DEXPORT_C_API=OFF"
492 "-DENABLE_CLI=OFF"
493 "-DMAIN12=ON"
494 configure-flags)
495 (substitute* (cons "cmake_install.cmake"
496 (append
497 (find-files "CMakeFiles/x265-shared.dir" ".")
498 (find-files "CMakeFiles/x265-static.dir" ".")))
499 (("libx265") "libx265_main12"))
500 (invoke "make"))))
501 (add-before 'configure 'build-10-bit
502 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
503 (mkdir "../build-10bit")
504 (with-directory-excursion "../build-10bit"
505 (apply invoke
506 "cmake" "../source"
507 "-DHIGH_BIT_DEPTH=ON"
508 "-DEXPORT_C_API=OFF"
509 "-DENABLE_CLI=OFF"
510 configure-flags)
511 (substitute* (cons "cmake_install.cmake"
512 (append
513 (find-files "CMakeFiles/x265-shared.dir" ".")
514 (find-files "CMakeFiles/x265-static.dir" ".")))
515 (("libx265") "libx265_main10"))
516 (invoke "make"))))
517 (add-after 'install 'install-more-libs
518 (lambda _
519 (with-directory-excursion "../build-12bit"
520 (invoke "make" "install"))
521 (with-directory-excursion "../build-10bit"
522 (invoke "make" "install"))))
523 (add-before 'strip 'move-static-libs
524 (lambda* (#:key outputs #:allow-other-keys)
525 (let ((out (assoc-ref outputs "out"))
526 (static (assoc-ref outputs "static")))
527 (mkdir-p (string-append static "/lib"))
528 (with-directory-excursion
529 (string-append out "/lib")
530 (for-each
531 (lambda (file)
532 (rename-file file
533 (string-append static "/lib/" file)))
534 (find-files "." "\\.a$"))))
535 #t)))))
536 (home-page "http://x265.org/")
537 (synopsis "Library for encoding h.265/HEVC video streams")
538 (description "x265 is a H.265 / HEVC video encoder application library,
539 designed to encode video or images into an H.265 / HEVC encoded bitstream.")
540 (license license:gpl2+)))
541
542 (define-public libass
543 (package
544 (name "libass")
545 (version "0.14.0")
546 (source (origin
547 (method url-fetch)
548 (uri (string-append
549 "https://github.com/libass/libass/releases/download/"
550 version "/libass-" version ".tar.xz"))
551 (sha256
552 (base32
553 "18iqznl4mabhj9ywfsz4kwvbsplcv1jjxq50nxssvbj8my1267w8"))))
554 (build-system gnu-build-system)
555 (native-inputs
556 `(("pkg-config" ,pkg-config)
557 ("nasm" ,nasm)))
558 (propagated-inputs
559 `(("freetype" ,freetype)
560 ("fribidi" ,fribidi)
561 ("fontconfig" ,fontconfig)
562 ("harfbuzz" ,harfbuzz)
563 ("enca" ,enca)))
564 (home-page "https://github.com/libass/libass")
565 (synopsis "Subtitle rendering library for the ASS/SSA format")
566 (description "libass is a subtitle rendering library for the
567 ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
568 (license license:isc)))
569
570 (define-public libcaca
571 (package
572 (name "libcaca")
573 (version "0.99.beta19")
574 (source (origin
575 (method url-fetch)
576 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
577 version ".tar.gz"))
578 (sha256
579 (base32
580 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))))
581 (build-system gnu-build-system)
582 (native-inputs `(("pkg-config" ,pkg-config)))
583 (inputs
584 `(("freeglut" ,freeglut)
585 ("ftgl" ,ftgl)
586 ("imlib2" ,imlib2)
587 ("libx11" ,libx11)
588 ("mesa" ,mesa)
589 ("ncurses" ,ncurses)
590 ("zlib" ,zlib)))
591 (home-page "http://caca.zoy.org/wiki/libcaca")
592 (synopsis "Colour ASCII-art library")
593 (description "libcaca is a graphics library that outputs text instead of
594 pixels, so that it can work on older video cards or text terminals. It
595 supports Unicode, 2048 colors, dithering of color images, and advanced text
596 canvas operations.")
597 (license (license:fsf-free "file://COPYING")))) ;WTFPL version 2
598
599 (define-public libdca
600 (package
601 (name "libdca")
602 (version "0.0.6")
603 (source (origin
604 (method url-fetch)
605 (uri (string-append
606 "https://download.videolan.org/pub/videolan/libdca/"
607 version "/libdca-" version ".tar.bz2"))
608 (sha256
609 (base32
610 "0h0zvcn97i9kyljdpifzi8in9xnw31fx3b3ggj96p8h0l2d8mycq"))))
611 (build-system gnu-build-system)
612 (home-page "https://www.videolan.org/developers/libdca.html")
613 (synopsis "DTS Coherent Acoustics decoder")
614 (description "libdca is a library for decoding DTS Coherent Acoustics
615 streams.")
616 (license license:gpl2+)))
617
618 (define-public libdv
619 (package
620 (name "libdv")
621 (version "1.0.0")
622 (source (origin
623 (method url-fetch)
624 (uri (string-append
625 "mirror://sourceforge/" name "/" name "/"
626 version "/" name "-" version ".tar.gz"))
627 (sha256
628 (base32
629 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
630 (build-system gnu-build-system)
631 (native-inputs `(("pkg-config" ,pkg-config)))
632 (inputs `(("libxv" ,libxv)))
633 (home-page "http://libdv.sourceforge.net/")
634 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
635 (description "The Quasar DV codec (libdv) is a software codec for DV
636 video, the encoding format used by most digital camcorders, typically those
637 that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
638 developed according to the official standards for DV video: IEC 61834 and
639 SMPTE 314M.")
640 (license license:lgpl2.1+)))
641
642 (define-public libmatroska
643 (package
644 (name "libmatroska")
645 (version "1.4.9")
646 (source
647 (origin
648 (method url-fetch)
649 (uri (string-append "https://dl.matroska.org/downloads/"
650 name "/" name "-" version ".tar.xz"))
651 (sha256
652 (base32
653 "1j4mjzx6mjzfjf9hz8g4w84krf5jccmr5cyynll0j1vwv3aiv9iq"))))
654 (build-system cmake-build-system)
655 (inputs
656 `(("libebml" ,libebml)))
657 (arguments
658 `(#:configure-flags
659 (list "-DBUILD_SHARED_LIBS=YES")
660 #:tests? #f)) ; no test suite
661 (home-page "https://www.matroska.org")
662 (synopsis "C++ library to parse Matroska files (.mkv and .mka)")
663 (description
664 "Matroska aims to become the standard of multimedia container formats.
665 It is based on @dfn{EBML} (Extensible Binary Meta Language), a binary derivative
666 of XML. EBML enables the Matroska Development Team to gain significant
667 advantages in terms of future format extensibility, without breaking file
668 support in old parsers.
669 libebml is a C++ library to read and write EBML files.")
670 (license license:lgpl2.1)))
671
672 (define-public libva
673 (package
674 (name "libva")
675 (version "2.4.0")
676 (source
677 (origin
678 (method url-fetch)
679 (uri (list
680 ;; Newer releases are only available on GitHub.
681 (string-append "https://github.com/01org/libva/releases/download/"
682 version "/libva-" version ".tar.bz2")
683 ;; Keep the old URL around for compatibility.
684 (string-append "https://www.freedesktop.org/software/vaapi/releases/"
685 "libva/libva-" version "/libva-" version ".tar.bz2")))
686 (sha256
687 (base32 "14ckq67z3pcd7jrnrm3ckss440g6dzp2m0ff5rps54qmq9b309lr"))))
688 (build-system gnu-build-system)
689 (native-inputs
690 `(("pkg-config" ,pkg-config)))
691 (inputs
692 `(("libdrm" ,libdrm)
693 ("libx11" ,libx11)
694 ("libxext" ,libxext)
695 ("libxfixes" ,libxfixes)
696 ("mesa" ,mesa)
697 ("wayland" ,wayland)))
698 (arguments
699 `(#:phases
700 (modify-phases %standard-phases
701 (add-before
702 'build 'fix-dlopen-paths
703 (lambda* (#:key outputs #:allow-other-keys)
704 (let ((out (assoc-ref outputs "out")))
705 (substitute* "va/drm/va_drm_auth_x11.c"
706 (("\"libva-x11\\.so\\.%d\"")
707 (string-append "\"" out "/lib/libva-x11.so.%d\"")))
708 #t))))
709 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
710 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
711 #:configure-flags
712 (list (string-append "--with-drivers-path="
713 (assoc-ref %build-inputs "mesa") "/lib/dri"))
714 ;; However, we can't write to mesa's store directory, so override the
715 ;; following make variable to install the dummy driver to libva's
716 ;; $prefix/lib/dri directory.
717 #:make-flags
718 (list (string-append "dummy_drv_video_ladir="
719 (assoc-ref %outputs "out") "/lib/dri"))))
720 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
721 (synopsis "Video acceleration library")
722 (description "The main motivation for VA-API (Video Acceleration API) is
723 to enable hardware accelerated video decode/encode at various
724 entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
725 standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
726 (license license:expat)))
727
728 (define-public ffmpeg
729 (package
730 (name "ffmpeg")
731 (version "4.1.1")
732 (source (origin
733 (method url-fetch)
734 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
735 version ".tar.xz"))
736 (sha256
737 (base32
738 "11id9pm4azfrhpa4vr2yaw31dzgd55kl1zsxwn24sczx9n14jdrp"))))
739 (build-system gnu-build-system)
740 (inputs
741 `(("fontconfig" ,fontconfig)
742 ("freetype" ,freetype)
743 ("frei0r-plugins" ,frei0r-plugins)
744 ("gnutls" ,gnutls)
745 ("opus" ,opus)
746 ("ladspa" ,ladspa)
747 ("lame" ,lame)
748 ("libaom" ,libaom)
749 ("libass" ,libass)
750 ("libbluray" ,libbluray)
751 ("libcaca" ,libcaca)
752 ("libcdio-paranoia" ,libcdio-paranoia)
753 ("libdrm" ,libdrm)
754 ("libtheora" ,libtheora)
755 ("libva" ,libva)
756 ("libvdpau" ,libvdpau)
757 ("libvorbis" ,libvorbis)
758 ("libvpx" ,libvpx)
759 ("libx11" ,libx11)
760 ("libx264" ,libx264)
761 ("mesa" ,mesa)
762 ("openal" ,openal)
763 ("pulseaudio" ,pulseaudio)
764 ("sdl" ,sdl2)
765 ("soxr" ,soxr)
766 ("speex" ,speex)
767 ("twolame" ,twolame)
768 ("vidstab" ,vidstab)
769 ("x265" ,x265)
770 ("xvid" ,xvid)
771 ("zlib" ,zlib)))
772 (native-inputs
773 `(("bc" ,bc)
774 ("perl" ,perl)
775 ("pkg-config" ,pkg-config)
776 ("texinfo" ,texinfo)
777 ("python" ,python-2) ; scripts use interpreter python2
778 ("speex" ,speex)
779 ("yasm" ,yasm)))
780 (arguments
781 `(#:test-target "fate"
782 #:configure-flags
783 ;; possible additional inputs:
784 ;; --enable-avisynth enable reading of AviSynth script
785 ;; files [no]
786 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
787 ;; --enable-libcelt enable CELT decoding via libcelt [no]
788 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
789 ;; and libraw1394 [no]
790 ;; --enable-libfaac enable AAC encoding via libfaac [no]
791 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
792 ;; --enable-libflite enable flite (voice synthesis) support via
793 ;; libflite [no]
794 ;; --enable-libgme enable Game Music Emu via libgme [no]
795 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
796 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
797 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
798 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
799 ;; --enable-libnut enable NUT (de)muxing via libnut,
800 ;; native (de)muxer exists [no]
801 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
802 ;; libopencore-amrnb [no]
803 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
804 ;; libopencore-amrwb [no]
805 ;; --enable-libopencv enable video filtering via libopencv [no]
806 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
807 ;; OpenJPEG [no]
808 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
809 ;; --enable-libschroedinger enable Dirac de/encoding via
810 ;; libschroedinger [no]
811 ;; --enable-libshine enable fixed-point MP3 encoding via
812 ;; libshine [no]
813 ;; --enable-libssh enable SFTP protocol via libssh [no]
814 ;; (libssh2 does not work)
815 ;; --enable-libstagefright-h264 enable H.264 decoding via
816 ;; libstagefright [no]
817 ;; --enable-libutvideo enable Ut Video encoding and decoding via
818 ;; libutvideo [no]
819 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
820 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
821 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
822 ;; libvo-amrwbenc [no]
823 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
824 ;; --enable-libxavs enable AVS encoding via xavs [no]
825 ;; --enable-libzmq enable message passing via libzmq [no]
826 ;; --enable-libzvbi enable teletext support via libzvbi [no]
827 ;; --enable-opencl enable OpenCL code
828 '("--enable-avresample"
829 "--enable-gpl" ; enable optional gpl licensed parts
830 "--enable-shared"
831 "--enable-frei0r"
832 "--enable-fontconfig"
833 "--enable-gnutls"
834 "--enable-ladspa"
835 "--enable-libaom"
836 "--enable-libass"
837 "--enable-libbluray"
838 "--enable-libcaca"
839 "--enable-libcdio"
840 "--enable-libfreetype"
841 "--enable-libmp3lame"
842 "--enable-libopus"
843 "--enable-libpulse"
844 "--enable-libsoxr"
845 "--enable-libspeex"
846 "--enable-libtheora"
847 "--enable-libtwolame"
848 "--enable-libvidstab"
849 "--enable-libvorbis"
850 "--enable-libvpx"
851 "--enable-libxvid"
852 "--enable-libx264"
853 "--enable-libx265"
854 "--enable-openal"
855 "--enable-opengl"
856 "--enable-libdrm"
857
858 "--enable-runtime-cpudetect"
859
860 ;; The HTML pages take 7.2 MiB
861 "--disable-htmlpages"
862
863 ;; The static libraries are 23 MiB
864 "--disable-static"
865
866 ;; Runtime cpu detection is not implemented on
867 ;; MIPS, so we disable some features.
868 "--disable-mips32r2"
869 "--disable-mipsdsp"
870 "--disable-mipsdspr2"
871 "--disable-mipsfpu")
872 #:phases
873 (modify-phases %standard-phases
874 (replace
875 'configure
876 ;; configure does not work followed by "SHELL=..." and
877 ;; "CONFIG_SHELL=..."; set environment variables instead
878 (lambda* (#:key outputs configure-flags #:allow-other-keys)
879 (let ((out (assoc-ref outputs "out")))
880 (substitute* "configure"
881 (("#! /bin/sh") (string-append "#!" (which "sh"))))
882 (setenv "SHELL" (which "bash"))
883 (setenv "CONFIG_SHELL" (which "bash"))
884 (apply invoke
885 "./configure"
886 (string-append "--prefix=" out)
887 ;; Add $libdir to the RUNPATH of all the binaries.
888 (string-append "--extra-ldflags=-Wl,-rpath="
889 out "/lib")
890 configure-flags))))
891 (add-before
892 'check 'set-ld-library-path
893 (lambda _
894 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
895 ;; running tests.
896 (let* ((dso (find-files "." "\\.so$"))
897 (path (string-join (map dirname dso) ":")))
898 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
899 (setenv "LD_LIBRARY_PATH" path)
900 #t))))))
901 (home-page "https://www.ffmpeg.org/")
902 (synopsis "Audio and video framework")
903 (description "FFmpeg is a complete, cross-platform solution to record,
904 convert and stream audio and video. It includes the libavcodec
905 audio/video codec library.")
906 (license license:gpl2+)))
907
908 (define-public ffmpeg-3.4
909 (package
910 (inherit ffmpeg)
911 (version "3.4.5")
912 (source (origin
913 (method url-fetch)
914 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
915 version ".tar.xz"))
916 (sha256
917 (base32
918 "0b59qk5wpc5ksiha76jbhb859g5gxa4w0k6afh3kgvgajiivs73l"))))
919 (arguments
920 (substitute-keyword-arguments (package-arguments ffmpeg)
921 ((#:configure-flags flags)
922 `(delete "--enable-libaom" ,flags))))
923 (inputs (alist-delete "libaom"
924 (package-inputs ffmpeg)))))
925
926 (define-public ffmpeg-for-stepmania
927 (hidden-package
928 (package
929 (inherit ffmpeg)
930 (version "2.1.3")
931 (source
932 (origin
933 (method git-fetch)
934 (uri (git-reference
935 (url "https://github.com/stepmania/ffmpeg.git")
936 (commit "eda6effcabcf9c238e4635eb058d72371336e09b")))
937 (sha256
938 (base32 "1by8rmbva8mfrivdbbkr2gx4kga89zqygkd4cfjl76nr8mdcdamb"))
939 (file-name (git-file-name "ffmpeg" version))))
940 (arguments
941 (substitute-keyword-arguments (package-arguments ffmpeg)
942 ((#:configure-flags flags)
943 '(list "--disable-programs"
944 "--disable-doc"
945 "--disable-debug"
946 "--disable-avdevice"
947 "--disable-swresample"
948 "--disable-postproc"
949 "--disable-avfilter"
950 "--disable-shared"
951 "--enable-static"))))
952 (inputs '()))))
953
954 (define-public ffmpegthumbnailer
955 (package
956 (name "ffmpegthumbnailer")
957 (version "2.2.0")
958 (source (origin
959 (method git-fetch)
960 (uri (git-reference
961 (url "https://github.com/dirkvdb/ffmpegthumbnailer.git")
962 (commit version)))
963 (file-name (git-file-name name version))
964 (sha256
965 (base32
966 "0kl8aa547icy9b05njps02a8sw4yn4f8fzs228kig247sn09s4cp"))))
967 (build-system cmake-build-system)
968 (native-inputs
969 `(("pkg-config" ,pkg-config)))
970 (inputs
971 `(("ffmpeg" ,ffmpeg)
972 ("libjpeg-turbo" ,libjpeg-turbo)
973 ("libpng" ,libpng)
974 ("gvfs" ,gvfs)))
975 (arguments
976 `(#:configure-flags (list "-DENABLE_GIO=ON" "-DENABLE_THUMBNAILER=ON")))
977 (home-page "https://github.com/dirkvdb/ffmpegthumbnailer")
978 (synopsis "Create thumbnails from video files")
979 (description "FFmpegthumbnailer is a lightweight video thumbnailer that
980 can be used by file managers to create thumbnails for your video files. The
981 thumbnailer uses ffmpeg to decode frames from the video files, so supported
982 videoformats depend on the configuration flags of ffmpeg.")
983 (license license:gpl2+)))
984
985 (define-public vlc
986 (package
987 (name "vlc")
988 (version "3.0.6")
989 (source (origin
990 (method url-fetch)
991 (uri (string-append
992 "https://download.videolan.org/pub/videolan/vlc/"
993 (car (string-split version #\-))
994 "/vlc-" version ".tar.xz"))
995 (sha256
996 (base32
997 "1lvyyahv6g9zv7m5g5qinyrwmw47zdsd5ysimb862j7kw15nvh8q"))))
998 (build-system gnu-build-system)
999 (native-inputs
1000 `(("flex" ,flex)
1001 ("bison" ,bison)
1002 ("gettext" ,gettext-minimal)
1003 ("git" ,git) ; needed for a test
1004 ("pkg-config" ,pkg-config)))
1005 ;; FIXME: Add optional inputs once available.
1006 (inputs
1007 `(("alsa-lib" ,alsa-lib)
1008 ("avahi" ,avahi)
1009 ("dbus" ,dbus)
1010 ("eudev" ,eudev)
1011 ("flac" ,flac)
1012 ("ffmpeg" ,ffmpeg)
1013 ("fontconfig" ,fontconfig)
1014 ("freetype" ,freetype)
1015 ("fribidi" ,fribidi)
1016 ("gnutls" ,gnutls)
1017 ("liba52" ,liba52)
1018 ("libarchive" ,libarchive)
1019 ("libass" ,libass)
1020 ("libavc1394" ,libavc1394)
1021 ("libbluray" ,libbluray)
1022 ("libcaca" ,libcaca)
1023 ("libcddb" ,libcddb)
1024 ("libdca" ,libdca)
1025 ("libdvbpsi" ,libdvbpsi)
1026 ("libdvdnav" ,libdvdnav)
1027 ("libdvdread" ,libdvdread)
1028 ("libebml" ,libebml)
1029 ("libgcrypt" ,libgcrypt)
1030 ("libidn" ,libidn)
1031 ("libkate" ,libkate)
1032 ("libmad" ,libmad)
1033 ("libmatroska" ,libmatroska)
1034 ("libmicrodns" ,libmicrodns)
1035 ("libmodplug" ,libmodplug)
1036 ("libmpeg2" ,libmpeg2)
1037 ("libogg" ,libogg)
1038 ("libpng" ,libpng)
1039 ("libraw1394" ,libraw1394)
1040 ("librsvg" ,librsvg)
1041 ("libsamplerate" ,libsamplerate)
1042 ("libsecret" ,libsecret)
1043 ("libssh2" ,libssh2)
1044 ("libupnp" ,libupnp)
1045 ("libva" ,libva)
1046 ("libvdpau" ,libvdpau)
1047 ("libvorbis" ,libvorbis)
1048 ("libvpx" ,libvpx-1.7)
1049 ("libtheora" ,libtheora)
1050 ("libx264" ,libx264)
1051 ("libxext" ,libxext)
1052 ("libxi" ,libxi)
1053 ("libxinerama" ,libxinerama)
1054 ("libxml2" ,libxml2)
1055 ("libxpm" ,libxpm)
1056 ("livemedia-utils" ,livemedia-utils)
1057 ("lua" ,lua-5.2)
1058 ("mesa" ,mesa)
1059 ("opus" ,opus)
1060 ("perl" ,perl)
1061 ("pulseaudio" ,pulseaudio)
1062 ("protobuf" ,protobuf)
1063 ("python" ,python-wrapper)
1064 ("qtbase" ,qtbase)
1065 ("qtsvg" ,qtsvg)
1066 ("qtx11extras" ,qtx11extras)
1067 ("samba" ,samba)
1068 ("sdl" ,sdl)
1069 ("sdl-image" ,sdl-image)
1070 ("speex" ,speex)
1071 ("speexdsp" ,speexdsp)
1072 ("taglib" ,taglib)
1073 ("twolame" ,twolame)
1074 ("unzip" ,unzip)
1075 ("wayland" ,wayland)
1076 ("wayland-protocols" ,wayland-protocols)
1077 ("x265" ,x265)
1078 ("xcb-util-keysyms" ,xcb-util-keysyms)))
1079 (arguments
1080 `(#:configure-flags
1081 `("CXXFLAGS=-std=gnu++11"
1082 "BUILDCC=gcc"
1083 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
1084 (assoc-ref %build-inputs "ffmpeg")
1085 "/lib")) ;needed for the tests
1086
1087 #:phases
1088 (modify-phases %standard-phases
1089 (add-after 'unpack 'patch-source
1090 (lambda* (#:key inputs #:allow-other-keys)
1091 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
1092 (substitute* "configure"
1093 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
1094 (string-append "LIVE555_PREFIX=" livemedia-utils)))
1095 ;; Some of the tests require using the display to test out VLC,
1096 ;; which fails in our sandboxed build system
1097 (substitute* "test/run_vlc.sh"
1098 (("./vlc --ignore-config") "echo"))
1099
1100 ;; modules/text_renderer/freetype/text_layout.c uses a
1101 ;; now-deprecated interface 'fribidi_get_par_embedding_levels'
1102 ;; from fribidi.h, so for now we enable the use of deprecated
1103 ;; fribidi interfaces from this file.
1104 ;; FIXME: Try removing this for vlc >= 3.0.3.
1105 (substitute* "modules/text_renderer/freetype/text_layout.c"
1106 (("# define FRIBIDI_NO_DEPRECATED 1") ""))
1107
1108 ;; Fix build against Qt 5.11.
1109 (substitute* "modules/gui/qt/actions_manager.cpp"
1110 (("#include <vlc_keys.h>") "#include <vlc_keys.h>
1111 #include <QAction>"))
1112 (substitute* "modules/gui/qt/components/simple_preferences.cpp"
1113 (("#include <QFont>") "#include <QFont>
1114 #include <QButtonGroup>"))
1115 #t)))
1116 (add-after 'strip 'regenerate-plugin-cache
1117 (lambda* (#:key outputs #:allow-other-keys)
1118 ;; The 'install-exec-hook' rule in the top-level Makefile.am
1119 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
1120 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
1121 ;; it references. Thus, we first reset the timestamps of all
1122 ;; these files, and then regenerate the cache such that the
1123 ;; mtimes it includes are always zero instead of being dependent
1124 ;; on the build time.
1125 (let* ((out (assoc-ref outputs "out"))
1126 (pkglibdir (string-append out "/lib/vlc"))
1127 (plugindir (string-append pkglibdir "/plugins"))
1128 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
1129 ;; TODO: Factorize 'reset-timestamps'.
1130 (for-each (lambda (file)
1131 (let ((s (lstat file)))
1132 (unless (eq? (stat:type s) 'symlink)
1133 (utime file 1 1))))
1134 (find-files plugindir))
1135 (invoke cachegen plugindir))))
1136 (add-after 'install 'wrap-executable
1137 (lambda* (#:key outputs #:allow-other-keys)
1138 (let ((out (assoc-ref outputs "out"))
1139 (plugin-path (getenv "QT_PLUGIN_PATH")))
1140 (wrap-program (string-append out "/bin/vlc")
1141 `("QT_PLUGIN_PATH" ":" prefix (,plugin-path))))
1142 #t)))))
1143 (home-page "https://www.videolan.org/")
1144 (synopsis "Audio and video framework")
1145 (description "VLC is a cross-platform multimedia player and framework
1146 that plays most multimedia files as well as DVD, Audio CD, VCD, and various
1147 streaming protocols.")
1148 (license license:gpl2+)))
1149
1150 (define-public mplayer
1151 (package
1152 (name "mplayer")
1153 (version "1.3.0")
1154 (source (origin
1155 (method url-fetch)
1156 (uri (string-append
1157 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
1158 version ".tar.xz"))
1159 (sha256
1160 (base32
1161 "0hwqn04bdknb2ic88xd75smffxx63scvz0zvwvjb56nqj9n89l1s"))))
1162 (build-system gnu-build-system)
1163 ;; FIXME: Add additional inputs once available.
1164 (native-inputs
1165 `(("pkg-config" ,pkg-config)))
1166 (inputs
1167 `(("alsa-lib" ,alsa-lib)
1168 ("cdparanoia" ,cdparanoia)
1169 ("ffmpeg" ,ffmpeg-3.4)
1170 ("fontconfig" ,fontconfig)
1171 ("freetype" ,freetype)
1172 ;; ("giflib" ,giflib) ; uses QuantizeBuffer, requires version >= 5
1173 ("lame" ,lame)
1174 ("libass" ,libass)
1175 ("libdvdcss" ,libdvdcss)
1176 ("libdvdnav" ,libdvdnav)
1177 ("libjpeg" ,libjpeg)
1178 ("libmpeg2" ,libmpeg2)
1179 ("libmpg123" ,mpg123) ; audio codec for MP3
1180 ("libpng" ,libpng)
1181 ("libtheora" ,libtheora)
1182 ("libvdpau" ,libvdpau)
1183 ("libvorbis" ,libvorbis)
1184 ("libx11" ,libx11)
1185 ("libx264" ,libx264)
1186 ("libxinerama" ,libxinerama)
1187 ("libxv" ,libxv)
1188 ("libxxf86dga" ,libxxf86dga)
1189 ("mesa" ,mesa)
1190 ("opus" ,opus)
1191 ("perl" ,perl)
1192 ("pulseaudio" ,pulseaudio)
1193 ("python" ,python-wrapper)
1194 ("sdl" ,sdl)
1195 ("speex" ,speex)
1196 ("yasm" ,yasm)
1197 ("zlib" ,zlib)))
1198 (arguments
1199 `(#:tests? #f ; no test target
1200 #:phases
1201 (modify-phases %standard-phases
1202 (replace 'configure
1203 ;; configure does not work followed by "SHELL=..." and
1204 ;; "CONFIG_SHELL=..."; set environment variables instead
1205 (lambda* (#:key inputs outputs #:allow-other-keys)
1206 (let ((out (assoc-ref outputs "out"))
1207 (libx11 (assoc-ref inputs "libx11")))
1208 (substitute* "configure"
1209 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1210 (setenv "SHELL" (which "bash"))
1211 (setenv "CONFIG_SHELL" (which "bash"))
1212 (invoke "./configure"
1213 (string-append "--extra-cflags=-I"
1214 libx11 "/include") ; to detect libx11
1215 "--disable-ffmpeg_a" ; disables bundled ffmpeg
1216 (string-append "--prefix=" out)
1217 ;; Enable runtime cpu detection where supported,
1218 ;; and choose a suitable target.
1219 ,@(match (or (%current-target-system)
1220 (%current-system))
1221 ("x86_64-linux"
1222 '("--enable-runtime-cpudetection"
1223 "--target=x86_64-linux"))
1224 ("i686-linux"
1225 '("--enable-runtime-cpudetection"
1226 "--target=i686-linux"))
1227 ("mips64el-linux"
1228 '("--target=mips3-linux"))
1229 (_ (list (string-append
1230 "--target="
1231 (or (%current-target-system)
1232 (nix-system->gnu-triplet
1233 (%current-system)))))))
1234 "--disable-iwmmxt")))))))
1235 (home-page "https://www.mplayerhq.hu/design7/news.html")
1236 (synopsis "Audio and video player")
1237 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
1238 Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
1239 NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
1240 SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
1241 (license license:gpl2)))
1242
1243 (define-public mpv
1244 (package
1245 (name "mpv")
1246 (version "0.29.1")
1247 (source (origin
1248 (method git-fetch)
1249 (uri (git-reference
1250 (url "https://github.com/mpv-player/mpv.git")
1251 (commit (string-append "v" version))))
1252 (file-name (git-file-name name version))
1253 (sha256
1254 (base32
1255 "138921kx8g6qprim558xin09xximjhsj9ss8b71ifg2m6kclym8m"))))
1256 (build-system waf-build-system)
1257 (native-inputs
1258 `(("perl" ,perl) ; for zsh completion file
1259 ("pkg-config" ,pkg-config)
1260 ("python-docutils" ,python-docutils)))
1261 ;; Missing features: libguess, V4L2
1262 (inputs
1263 `(("alsa-lib" ,alsa-lib)
1264 ("enca" ,enca)
1265 ("ffmpeg" ,ffmpeg)
1266 ("jack" ,jack-1)
1267 ("ladspa" ,ladspa)
1268 ("lcms" ,lcms)
1269 ("libass" ,libass)
1270 ("libbluray" ,libbluray)
1271 ("libcaca" ,libcaca)
1272 ("libbs2b" ,libbs2b)
1273 ("libcdio-paranoia" ,libcdio-paranoia)
1274 ("libdvdread" ,libdvdread)
1275 ("libdvdnav" ,libdvdnav)
1276 ("libjpeg" ,libjpeg)
1277 ("libva" ,libva)
1278 ("libvdpau" ,libvdpau)
1279 ("libx11" ,libx11)
1280 ("libxext" ,libxext)
1281 ("libxinerama" ,libxinerama)
1282 ("libxrandr" ,libxrandr)
1283 ("libxscrnsaver" ,libxscrnsaver)
1284 ("libxv" ,libxv)
1285 ;; XXX: lua > 5.2 is not currently supported; see
1286 ;; waftools/checks/custom.py
1287 ("lua" ,lua-5.2)
1288 ("mesa" ,mesa)
1289 ("mpg123" ,mpg123)
1290 ("pulseaudio" ,pulseaudio)
1291 ("rsound" ,rsound)
1292 ("shaderc" ,shaderc)
1293 ("vulkan-headers" ,vulkan-headers)
1294 ("vulkan-loader" ,vulkan-loader)
1295 ("waf" ,python-waf)
1296 ("wayland" ,wayland)
1297 ("wayland-protocols" ,wayland-protocols)
1298 ("libxkbcommon" ,libxkbcommon)
1299 ("youtube-dl" ,youtube-dl)
1300 ("zlib" ,zlib)))
1301 (arguments
1302 '(#:phases
1303 (modify-phases %standard-phases
1304 (add-before
1305 'configure 'setup-waf
1306 (lambda* (#:key inputs #:allow-other-keys)
1307 (let ((waf (assoc-ref inputs "waf")))
1308 (copy-file (string-append waf "/bin/waf") "waf"))
1309 (setenv "CC" "gcc")
1310 #t)))
1311 #:configure-flags (list "--enable-libmpv-shared"
1312 "--enable-cdda"
1313 "--enable-dvdread"
1314 "--enable-dvdnav"
1315 "--enable-zsh-comp"
1316 "--disable-build-date")
1317 ;; No check function defined.
1318 #:tests? #f))
1319 (home-page "https://mpv.io/")
1320 (synopsis "Audio and video player")
1321 (description "mpv is a general-purpose audio and video player. It is a
1322 fork of mplayer2 and MPlayer. It shares some features with the former
1323 projects while introducing many more.")
1324 (license license:gpl2+)))
1325
1326 (define-public gnome-mpv
1327 (package
1328 (name "gnome-mpv")
1329 (version "0.16")
1330 (source
1331 (origin
1332 (method url-fetch)
1333 (uri (string-append "https://github.com/gnome-mpv/gnome-mpv/releases"
1334 "/download/v" version "/gnome-mpv-" version
1335 ".tar.xz"))
1336 (sha256
1337 (base32
1338 "0jzdzvhcqp5jp1inwk2466zf7r8iimk3x69066gl8mzaay98mk92"))))
1339 (native-inputs
1340 `(("intltool" ,intltool)
1341 ("pkg-config" ,pkg-config)))
1342 (inputs
1343 `(("gtk+" ,gtk+)
1344 ("libepoxy" ,libepoxy)
1345 ("mpv" ,mpv)))
1346 (build-system glib-or-gtk-build-system)
1347 (home-page "https://github.com/gnome-mpv/gnome-mpv")
1348 (synopsis "GTK+ frontend for the mpv media player")
1349 (description "GNOME MPV is a simple GTK+ frontend for the mpv media player.
1350 GNOME MPV interacts with mpv via the client API exported by libmpv, allowing
1351 access to mpv's powerful playback capabilities.")
1352 (license license:gpl3+)))
1353
1354 (define-public libvpx
1355 (package
1356 (name "libvpx")
1357 (version "1.8.0")
1358 (source (origin
1359 ;; XXX: Upstream does not provide tarballs for > 1.6.1.
1360 (method git-fetch)
1361 (uri (git-reference
1362 (url "https://chromium.googlesource.com/webm/libvpx")
1363 (commit (string-append "v" version))))
1364 (file-name (git-file-name name version))
1365 (sha256
1366 (base32
1367 "079pb80am08lj8y5rx99vdr99mdqis9067f172zq12alkz849n93"))
1368 (patches (search-patches "libvpx-CVE-2016-2818.patch"))))
1369 (build-system gnu-build-system)
1370 (arguments
1371 `(#:configure-flags (list "--enable-shared"
1372 "--as=yasm"
1373 ;; Limit size to avoid CVE-2015-1258
1374 "--size-limit=16384x16384"
1375 (string-append "--prefix=" (assoc-ref %outputs "out")))
1376 #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
1377 (assoc-ref %outputs "out") "/lib"))
1378 #:phases (modify-phases %standard-phases
1379 (replace 'configure
1380 (lambda* (#:key configure-flags #:allow-other-keys)
1381 ;; The configure script does not understand some of the GNU
1382 ;; options, so we only add the flags specified above.
1383 (apply invoke "./configure" configure-flags))))
1384 #:tests? #f)) ; no check target
1385 (native-inputs
1386 `(("perl" ,perl)
1387 ("yasm" ,yasm)))
1388 (synopsis "VP8/VP9 video codec")
1389 (description "libvpx is a codec for the VP8/VP9 video compression format.")
1390 (license license:bsd-3)
1391 (home-page "https://www.webmproject.org/")))
1392
1393 ;; GNU IceCat fails to build against 1.8.0, so keep this version for now.
1394 (define-public libvpx-1.7
1395 (package
1396 (inherit libvpx)
1397 (version "1.7.0")
1398 (source (origin
1399 (inherit (package-source libvpx))
1400 (uri (git-reference
1401 (url "https://chromium.googlesource.com/webm/libvpx")
1402 (commit (string-append "v" version))))
1403 (file-name (git-file-name "libvpx" version))
1404 (sha256
1405 (base32
1406 "0vvh89hvp8qg9an9vcmwb7d9k3nixhxaz6zi65qdjnd0i56kkcz6"))
1407 (patches
1408 (append
1409 (origin-patches (package-source libvpx))
1410 (search-patches "libvpx-use-after-free-in-postproc.patch")))))))
1411
1412 (define-public youtube-dl
1413 (package
1414 (name "youtube-dl")
1415 (version "2019.03.01")
1416 (source (origin
1417 (method url-fetch)
1418 (uri (string-append "https://github.com/rg3/youtube-dl/releases/"
1419 "download/" version "/youtube-dl-"
1420 version ".tar.gz"))
1421 (sha256
1422 (base32
1423 "0bxk6adyppdv50jnp5cika8wc6wfgd6d8zbg1njgmcs1pxskllmf"))))
1424 (build-system python-build-system)
1425 (arguments
1426 ;; The problem here is that the directory for the man page and completion
1427 ;; files is relative, and for some reason, setup.py uses the
1428 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
1429 ;; So, we need pass the prefix directly. In addition, make sure the Bash
1430 ;; completion file is called 'youtube-dl' rather than
1431 ;; 'youtube-dl.bash-completion'.
1432 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
1433 #:phases (modify-phases %standard-phases
1434 (add-before 'install 'fix-the-data-directories
1435 (lambda* (#:key outputs #:allow-other-keys)
1436 (let ((prefix (assoc-ref outputs "out")))
1437 (mkdir "bash-completion")
1438 (rename-file "youtube-dl.bash-completion"
1439 "bash-completion/youtube-dl")
1440 (substitute* "setup.py"
1441 (("youtube-dl\\.bash-completion")
1442 "bash-completion/youtube-dl")
1443 (("'etc/")
1444 (string-append "'" prefix "/etc/"))
1445 (("'share/")
1446 (string-append "'" prefix "/share/")))
1447 #t))))))
1448 (synopsis "Download videos from YouTube.com and other sites")
1449 (description
1450 "Youtube-dl is a small command-line program to download videos from
1451 YouTube.com and many more sites.")
1452 (home-page "https://yt-dl.org")
1453 (license license:public-domain)))
1454
1455 (define-public youtube-dl-gui
1456 (package
1457 (name "youtube-dl-gui")
1458 (version "0.3.8")
1459 (source
1460 (origin
1461 (method url-fetch)
1462 (uri (pypi-uri "Youtube-DLG" version))
1463 (sha256
1464 (base32
1465 "0napxwzgls5ik1bxbp99vly32l23xpc4ng5kr24hfhf21ypjyadb"))))
1466 (build-system python-build-system)
1467 (arguments
1468 ;; In Guix, wxpython has not yet been packaged for Python 3.
1469 `(#:python ,python-2
1470 ;; This package has no tests.
1471 #:tests? #f
1472 #:phases
1473 (modify-phases %standard-phases
1474 (add-before 'build 'patch-source
1475 (lambda* (#:key inputs #:allow-other-keys)
1476 ;; The youtube-dl-gui program lets you configure options. Some of
1477 ;; them are problematic, so we change their defaults.
1478 (substitute* "youtube_dl_gui/optionsmanager.py"
1479 ;; When this is true, the builder process will try (and fail) to
1480 ;; write logs to the builder user's home directory.
1481 (("'enable_log': True") "'enable_log': False")
1482 ;; This determines which youtube-dl program youtube-dl-gui will
1483 ;; run. If we don't set this, then youtube-dl-gui might download
1484 ;; an arbitrary copy from the Internet into the user's home
1485 ;; directory and run it, so let's make sure youtube-dl-gui uses
1486 ;; the youtube-dl from the inputs by default.
1487 (("'youtubedl_path': self.config_path")
1488 (string-append "'youtubedl_path': '"
1489 (assoc-ref inputs "youtube-dl")
1490 "/bin'"))
1491 ;; When this is True, when youtube-dl-gui is finished downloading
1492 ;; a file, it will try (and possibly fail) to open the directory
1493 ;; containing the downloaded file. This can fail because it
1494 ;; assumes that xdg-open is in PATH. Unfortunately, simply
1495 ;; adding xdg-utils to the propagated inputs is not enough to
1496 ;; make this work, so for now we set the default to False.
1497 (("'open_dl_dir': True") "'open_dl_dir': False"))
1498 ;; The youtube-dl program from the inputs is actually a wrapper
1499 ;; script written in bash, so attempting to invoke it as a python
1500 ;; script will fail.
1501 (substitute* "youtube_dl_gui/downloaders.py"
1502 (("cmd = \\['python', self\\.youtubedl_path\\]")
1503 "cmd = [self.youtubedl_path]"))
1504 ;; Use relative paths for installing data files so youtube-dl-gui
1505 ;; installs the files relative to its prefix in the store, rather
1506 ;; than relative to /. Also, instead of installing data files into
1507 ;; $prefix/usr/share, install them into $prefix/share for
1508 ;; consistency (see: (standards) Directory Variables).
1509 (substitute* "setup.py"
1510 (("= '/usr/share") "= 'share"))
1511 ;; Update get_locale_file() so it finds the installed localization
1512 ;; files.
1513 (substitute* "youtube_dl_gui/utils.py"
1514 (("os\\.path\\.join\\('/usr', 'share'")
1515 (string-append "os.path.join('"
1516 (assoc-ref %outputs "out")
1517 "', 'share'")))
1518 #t)))))
1519 (inputs
1520 `(("python2-wxpython" ,python2-wxpython)
1521 ("youtube-dl" ,youtube-dl)))
1522 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
1523 (synopsis
1524 "GUI (Graphical User Interface) for @command{youtube-dl}")
1525 (description
1526 "Youtube-dlG is a GUI (Graphical User Interface) for
1527 @command{youtube-dl}. You can use it to download videos from YouTube and any
1528 other site that youtube-dl supports.")
1529 (license license:unlicense)))
1530
1531 (define-public you-get
1532 (package
1533 (name "you-get")
1534 (version "0.4.1256")
1535 (source (origin
1536 (method git-fetch)
1537 (uri (git-reference
1538 (url "https://github.com/soimort/you-get.git")
1539 (commit (string-append "v" version))))
1540 (file-name (git-file-name name version))
1541 (sha256
1542 (base32
1543 "1hzr7ha1jvbc0v2bwl7s08ymwdmvb0f2jz4xp1fi6agq5y3ca1iv"))))
1544 (build-system python-build-system)
1545 (inputs
1546 `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos
1547 (arguments
1548 `(#:phases
1549 (modify-phases %standard-phases
1550 (add-after 'unpack 'qualify-input-references
1551 ;; Explicitly invoke the input ffmpeg, instead of whichever one
1552 ;; happens to be in the user's $PATH at run time.
1553 (lambda* (#:key inputs #:allow-other-keys)
1554 (let ((ffmpeg (string-append (assoc-ref inputs "ffmpeg")
1555 "/bin/ffmpeg")))
1556 (substitute* "src/you_get/processor/ffmpeg.py"
1557 ;; Don't blindly replace all occurrences of ‘'ffmpeg'’: the
1558 ;; same string is also used when sniffing ffmpeg's output.
1559 (("(FFMPEG == |\\()'ffmpeg'" _ prefix)
1560 (string-append prefix "'" ffmpeg "'")))
1561 #t))))
1562 #:tests? #f)) ; XXX some tests need Internet access
1563 (synopsis "Download videos, audio, or images from Web sites")
1564 (description
1565 "You-Get is a command-line utility to download media contents (videos,
1566 audio, images) from the Web. It can use either mpv or vlc for playback.")
1567 (home-page "https://you-get.org/")
1568 (license license:expat)))
1569
1570 (define-public youtube-viewer
1571 (package
1572 (name "youtube-viewer")
1573 (version "3.5.4")
1574 (source (origin
1575 (method git-fetch)
1576 (uri (git-reference
1577 (url "https://github.com/trizen/youtube-viewer.git")
1578 (commit version)))
1579 (file-name (git-file-name name version))
1580 (sha256
1581 (base32
1582 "1j782m9rximybamd0qsc43hi7hgk333x9gy3ypzb61s0sifs0i6m"))))
1583 (build-system perl-build-system)
1584 (native-inputs
1585 `(("perl-module-build" ,perl-module-build)))
1586 ;; FIXME: Add optional dependencies once available:
1587 ;; perl-lwp-useragent-cached and perl-term-readline-gnu
1588 (inputs
1589 `(("perl-data-dump" ,perl-data-dump)
1590 ("perl-file-sharedir" ,perl-file-sharedir)
1591 ("perl-gtk2" ,perl-gtk2)
1592 ("perl-json" ,perl-json)
1593 ("perl-libwww" ,perl-libwww)
1594 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
1595 ("perl-mozilla-ca" ,perl-mozilla-ca)
1596 ("perl-unicode-linebreak" ,perl-unicode-linebreak)))
1597 (arguments
1598 `(#:modules ((guix build perl-build-system)
1599 (guix build utils)
1600 (srfi srfi-26))
1601 #:module-build-flags '("--gtk")
1602 #:phases
1603 (modify-phases %standard-phases
1604 (add-after 'install 'install-desktop
1605 (lambda* (#:key outputs #:allow-other-keys)
1606 (let* ((out (assoc-ref outputs "out"))
1607 (sharedir (string-append out "/share")))
1608 (install-file "share/gtk-youtube-viewer.desktop"
1609 (string-append sharedir "/applications"))
1610 (install-file "share/icons/gtk-youtube-viewer.png"
1611 (string-append sharedir "/pixmaps"))
1612 #t)))
1613 (add-after 'install 'wrap-program
1614 (lambda* (#:key outputs #:allow-other-keys)
1615 (let* ((out (assoc-ref outputs "out"))
1616 (bin-dir (string-append out "/bin/"))
1617 (site-dir (string-append out "/lib/perl5/site_perl/"))
1618 (lib-path (getenv "PERL5LIB")))
1619 (for-each (cut wrap-program <>
1620 `("PERL5LIB" ":" prefix (,lib-path ,site-dir)))
1621 (find-files bin-dir))
1622 #t))))))
1623 (synopsis
1624 "Lightweight application for searching and streaming videos from YouTube")
1625 (description
1626 "Youtube-viewer searches and plays YouTube videos in a native player.
1627 It comes with various search options; it can search for videos, playlists
1628 and/or channels. The videos are streamed directly in a selected video player
1629 at the best resolution (customizable) and with closed-captions (if available).
1630 Both command-line and GTK2 interface are available.")
1631 (home-page "https://github.com/trizen/youtube-viewer")
1632 (license license:perl-license)))
1633
1634 (define-public libbluray
1635 (package
1636 (name "libbluray")
1637 (version "1.0.2")
1638 (source (origin
1639 (method url-fetch)
1640 (uri (string-append "https://download.videolan.org/videolan/"
1641 name "/" version "/"
1642 name "-" version ".tar.bz2"))
1643 (sha256
1644 (base32
1645 "1zxfnw1xbghcj7b3zz5djndv6gwssxda19cz1lrlqrkg8577r7kd"))))
1646 (build-system gnu-build-system)
1647 (arguments
1648 `(#:configure-flags '("--disable-bdjava-jar")
1649 #:phases
1650 (modify-phases %standard-phases
1651 (add-after 'unpack 'refer-to-libxml2-in-.pc-file
1652 ;; Avoid the need to propagate libxml2 by referring to it
1653 ;; directly, as is already done for fontconfig & freetype.
1654 (lambda* (#:key inputs #:allow-other-keys)
1655 (let ((libxml2 (assoc-ref inputs "libxml2")))
1656 (substitute* "configure"
1657 ((" libxml-2.0") ""))
1658 (substitute* "src/libbluray.pc.in"
1659 (("^Libs.private:" field)
1660 (string-append field " -L" libxml2 "/lib -lxml2")))
1661 #t)))
1662 (add-before 'build 'fix-dlopen-paths
1663 (lambda* (#:key inputs #:allow-other-keys)
1664 (let ((libaacs (assoc-ref inputs "libaacs"))
1665 (libbdplus (assoc-ref inputs "libbdplus")))
1666 (substitute* "src/libbluray/disc/aacs.c"
1667 (("\"libaacs\"")
1668 (string-append "\"" libaacs "/lib/libaacs\"")))
1669 (substitute* "src/libbluray/disc/bdplus.c"
1670 (("\"libbdplus\"")
1671 (string-append "\"" libbdplus "/lib/libbdplus\"")))
1672 #t))))))
1673 (native-inputs `(("pkg-config" ,pkg-config)))
1674 (inputs
1675 `(("fontconfig" ,fontconfig)
1676 ("freetype" ,freetype)
1677 ("libaacs" ,libaacs)
1678 ("libbdplus" ,libbdplus)
1679 ("libxml2" ,libxml2)))
1680 (home-page "https://www.videolan.org/developers/libbluray.html")
1681 (synopsis "Blu-Ray Disc playback library")
1682 (description
1683 "libbluray is a library designed for Blu-Ray Disc playback for media
1684 players, like VLC or MPlayer.")
1685 (license license:lgpl2.1+)))
1686
1687 (define-public libdvdread
1688 (package
1689 (name "libdvdread")
1690 (version "6.0.1")
1691 (source (origin
1692 (method url-fetch)
1693 (uri (string-append "https://download.videolan.org/videolan/"
1694 "libdvdread/" version "/"
1695 "libdvdread-" version ".tar.bz2"))
1696 (sha256
1697 (base32
1698 "1gfmh8ii3s2fw1c8vn57piwxc0smd3va4h7xgp9s8g48cc04zki8"))))
1699 (build-system gnu-build-system)
1700 (arguments
1701 `(#:configure-flags '("--with-libdvdcss=yes")))
1702 (native-inputs
1703 `(("pkg-config" ,pkg-config)))
1704 (propagated-inputs
1705 `(("libdvdcss" ,libdvdcss)))
1706 (home-page "http://dvdnav.mplayerhq.hu/")
1707 (synopsis "Library for reading video DVDs")
1708 (description
1709 "Libdvdread provides a simple foundation for reading DVD video
1710 disks. It provides the functionality that is required to access many
1711 DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
1712 authentication and descrambling (if an external libdvdcss library is
1713 installed).")
1714 (license license:gpl2+)))
1715
1716 (define-public dvdauthor
1717 (package
1718 (name "dvdauthor")
1719 (version "0.7.2")
1720 (source
1721 (origin
1722 (method url-fetch)
1723 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
1724 version ".tar.gz"))
1725 (sha256
1726 (base32
1727 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
1728 (build-system gnu-build-system)
1729 (inputs
1730 `(("libdvdread" ,libdvdread)
1731 ("libpng" ,libpng)
1732 ("imagemagick" ,imagemagick)
1733 ("libxml2" ,libxml2)
1734 ("freetype" ,freetype)))
1735 (native-inputs
1736 `(("pkg-config" ,pkg-config)))
1737 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
1738 (description "@command{dvdauthor} will generate a DVD-Video movie from a
1739 MPEG-2 stream containing VOB packets.")
1740 (home-page "http://dvdauthor.sourceforge.net")
1741 (license license:gpl3+)))
1742
1743 (define-public libdvdnav
1744 (package
1745 (name "libdvdnav")
1746 (version "6.0.0")
1747 (source (origin
1748 (method url-fetch)
1749 (uri (string-append "https://download.videolan.org/videolan/"
1750 name "/" version "/"
1751 name "-" version ".tar.bz2"))
1752 (sha256
1753 (base32
1754 "062njcksmpgw9yv3737qkf93r2pzhaxi9szqjabpa8d010dp38ph"))))
1755 (build-system gnu-build-system)
1756 (native-inputs
1757 `(("pkg-config" ,pkg-config)))
1758 (inputs
1759 `(("libdvdread" ,libdvdread)))
1760 (home-page "http://dvdnav.mplayerhq.hu/")
1761 (synopsis "Library for video DVD navigation features")
1762 (description
1763 "Libdvdnav is a library for developers of multimedia
1764 applications. It allows easy use of sophisticated DVD navigation features
1765 such as DVD menus, multiangle playback and even interactive DVD games. All
1766 this functionality is provided through a simple API which provides the DVD
1767 playback as a single logical stream of blocks, intermitted by special
1768 dvdnav events to report certain conditions. The main usage of libdvdnav is
1769 a loop regularly calling a function to get the next block, surrounded by
1770 additional calls to tell the library of user interaction. The whole
1771 DVD virtual machine and internal playback states are completely
1772 encapsulated.")
1773 (license license:gpl2+)))
1774
1775 (define-public libdvdcss
1776 (package
1777 (name "libdvdcss")
1778 (version "1.4.2")
1779 (source (origin
1780 (method url-fetch)
1781 (uri (string-append "https://download.videolan.org/pub/"
1782 name "/" version "/"
1783 name "-" version ".tar.bz2"))
1784 (sha256
1785 (base32
1786 "0x957zzpf4w2cp8zlk29prj8i2q6hay3lzdzsyz8y3cwxivyvhkq"))))
1787 (build-system gnu-build-system)
1788 (home-page "https://www.videolan.org/developers/libdvdcss.html")
1789 (synopsis "Library for accessing DVDs as block devices")
1790 (description
1791 "libdvdcss is a simple library designed for accessing DVDs like a block
1792 device without having to bother about the decryption.")
1793 (license license:gpl2+)))
1794
1795 (define-public srt2vtt
1796 (package
1797 (name "srt2vtt")
1798 (version "0.1")
1799 (source (origin
1800 (method url-fetch)
1801 (uri (string-append
1802 "https://files.dthompson.us/srt2vtt/srt2vtt-"
1803 version ".tar.gz"))
1804 (sha256
1805 (base32
1806 "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif"))))
1807 (build-system gnu-build-system)
1808 (inputs
1809 `(("guile" ,guile-2.0)))
1810 (synopsis "SubRip to WebVTT subtitle converter")
1811 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
1812 for use with HTML5 video.")
1813 (home-page "https://dthompson.us/projects/srt2vtt.html")
1814 (license license:gpl3+)))
1815
1816 (define-public avidemux
1817 (package
1818 (name "avidemux")
1819 (version "2.7.1")
1820 (source (origin
1821 (method url-fetch)
1822 (uri (string-append
1823 "mirror://sourceforge/" name "/" name "/" version "/"
1824 name "_" version ".tar.gz"))
1825 (sha256
1826 (base32
1827 "15g9h791qbnmycabbbl7s2b3n3xpvygm88qrfk35g2cw6957ik9w"))
1828 (patches (search-patches "avidemux-install-to-lib.patch"))))
1829 (build-system cmake-build-system)
1830 (native-inputs
1831 `(("pkg-config" ,pkg-config)))
1832 ;; FIXME: Once packaged, add libraries not found during the build.
1833 (inputs
1834 `(("alsa-lib" ,alsa-lib)
1835 ("fontconfig" ,fontconfig)
1836 ("freetype" ,freetype)
1837 ("fribidi" ,fribidi)
1838 ("glu" ,glu)
1839 ("jack" ,jack-1)
1840 ("lame" ,lame)
1841 ("libva" ,libva)
1842 ("libvdpau" ,libvdpau)
1843 ("libvorbis" ,libvorbis)
1844 ("libvpx" ,libvpx)
1845 ("libxv" ,libxv)
1846 ("perl" ,perl)
1847 ("pulseaudio" ,pulseaudio)
1848 ("python" ,python-wrapper)
1849 ("qtbase" ,qtbase)
1850 ("qttools" ,qttools)
1851 ("sdl" ,sdl)
1852 ("sqlite" ,sqlite)
1853 ("yasm" ,yasm)
1854 ("zlib" ,zlib)))
1855 (arguments
1856 `(#:tests? #f ; no check target
1857 #:phases
1858 ;; Make sure files inside the included ffmpeg tarball are
1859 ;; patch-shebanged.
1860 (modify-phases %standard-phases
1861 (add-before 'patch-source-shebangs 'unpack-ffmpeg
1862 (lambda _
1863 (with-directory-excursion "avidemux_core/ffmpeg_package"
1864 (invoke "tar" "xf" "ffmpeg-3.3.7.tar.bz2")
1865 (delete-file "ffmpeg-3.3.7.tar.bz2"))
1866 #t))
1867 (add-after 'patch-source-shebangs 'repack-ffmpeg
1868 (lambda _
1869 (with-directory-excursion "avidemux_core/ffmpeg_package"
1870 (substitute* "ffmpeg-3.3.7/configure"
1871 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1872 (invoke "tar" "cjf" "ffmpeg-3.3.7.tar.bz2" "ffmpeg-3.3.7"
1873 ;; avoid non-determinism in the archive
1874 "--sort=name" "--mtime=@0"
1875 "--owner=root:0" "--group=root:0")
1876 (delete-file-recursively "ffmpeg-3.3.7"))
1877 #t))
1878 (replace 'configure
1879 (lambda _
1880 ;; Copy-paste settings from the cmake build system.
1881 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
1882 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))
1883 #t))
1884 (replace 'build
1885 (lambda* (#:key inputs outputs #:allow-other-keys)
1886 (let* ((out (assoc-ref outputs "out"))
1887 (lib (string-append out "/lib"))
1888 (top (getcwd))
1889 (sdl (assoc-ref inputs "sdl"))
1890 (build_component
1891 (lambda* (component srcdir #:optional (args '()))
1892 (let ((builddir (string-append "build_" component)))
1893 (mkdir builddir)
1894 (with-directory-excursion builddir
1895 (apply invoke "cmake"
1896 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
1897 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
1898 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
1899 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
1900 "\"-Wl,-rpath=" lib "\"")
1901 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
1902 (string-append "-DSDL_INCLUDE_DIR="
1903 sdl "/include/SDL")
1904 (string-append "../" srcdir)
1905 "-DENABLE_QT5=True"
1906 args)
1907 (invoke "make" "-j"
1908 (number->string (parallel-job-count)))
1909 (invoke "make" "install"))))))
1910 (mkdir out)
1911 (build_component "core" "avidemux_core")
1912 (build_component "cli" "avidemux/cli")
1913 (build_component "qt4" "avidemux/qt4")
1914 (build_component "plugins_common" "avidemux_plugins"
1915 '("-DPLUGIN_UI=COMMON"))
1916 (build_component "plugins_cli" "avidemux_plugins"
1917 '("-DPLUGIN_UI=CLI"))
1918 (build_component "plugins_qt4" "avidemux_plugins"
1919 '("-DPLUGIN_UI=QT4"))
1920 (build_component "plugins_settings" "avidemux_plugins"
1921 '("-DPLUGIN_UI=SETTINGS"))
1922 ;; Remove .exe and .dll file.
1923 (delete-file-recursively
1924 (string-append out "/share/ADM6_addons"))
1925 #t)))
1926 (delete 'install))))
1927 (home-page "http://fixounet.free.fr/avidemux/")
1928 (synopsis "Video editor")
1929 (description "Avidemux is a video editor designed for simple cutting,
1930 filtering and encoding tasks. It supports many file types, including AVI,
1931 DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
1932 can be automated using projects, job queue and powerful scripting
1933 capabilities.")
1934 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
1935 ;; Software with various licenses is included, see License.txt.
1936 (license license:gpl2+)))
1937
1938 (define-public vapoursynth
1939 (package
1940 (name "vapoursynth")
1941 (version "37")
1942 (source (origin
1943 (method git-fetch)
1944 (uri (git-reference
1945 (url "https://github.com/vapoursynth/vapoursynth.git")
1946 (commit (string-append "R" version))))
1947 (file-name (git-file-name name version))
1948 (sha256
1949 (base32
1950 "1ma2s7dxk6y6l04qj1jvgwia4xj7999ny3a1yx2vbk5l83giam2p"))))
1951 (build-system gnu-build-system)
1952 (native-inputs
1953 `(("autoconf" ,autoconf)
1954 ("automake" ,automake)
1955 ("cython" ,python-cython)
1956 ("libtool" ,libtool)
1957 ("pkg-config" ,pkg-config)
1958 ("python" ,python)
1959 ("yasm" ,yasm)))
1960 (inputs
1961 `(("ffmpeg" ,ffmpeg)
1962 ("libass" ,libass)
1963 ("tesseract-ocr" ,tesseract-ocr)
1964 ("zimg" ,zimg)))
1965 (arguments
1966 '(#:phases
1967 (modify-phases %standard-phases
1968 (add-after 'unpack 'autogen
1969 (lambda _
1970 (invoke "sh" "autogen.sh"))))))
1971 (home-page "http://www.vapoursynth.com/")
1972 (synopsis "Video processing framework")
1973 (description "VapourSynth is a C++ library and Python module for video
1974 manipulation. It aims to be a modern rewrite of Avisynth, supporting
1975 multithreading, generalized colorspaces, per frame properties, and videos with
1976 format changes.")
1977 ;; src/core/cpufeatures only allows x86, ARM or PPC
1978 (supported-systems (fold delete %supported-systems
1979 '("mips64el-linux" "aarch64-linux")))
1980 ;; As seen from the source files.
1981 (license license:lgpl2.1+)))
1982
1983 (define-public xvid
1984 (package
1985 (name "xvid")
1986 (version "1.3.4")
1987 (source (origin
1988 (method url-fetch)
1989 (uri (string-append
1990 "http://downloads.xvid.org/downloads/xvidcore-"
1991 version ".tar.bz2"))
1992 (sha256
1993 (base32
1994 "1xwbmp9wqshc0ckm970zdpi0yvgqxlqg0s8bkz98mnr8p2067bsz"))))
1995 (build-system gnu-build-system)
1996 (native-inputs `(("yasm" ,yasm)))
1997 (arguments
1998 '(#:phases
1999 (modify-phases %standard-phases
2000 (add-before
2001 'configure 'pre-configure
2002 (lambda _
2003 (chdir "build/generic")
2004 (substitute* "configure"
2005 (("#! /bin/sh") (string-append "#!" (which "sh"))))
2006 #t)))
2007 ;; No 'check' target.
2008 #:tests? #f))
2009 (home-page "https://www.xvid.com/")
2010 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
2011 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
2012 codec library. It uses ASP features such as b-frames, global and quarter
2013 pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
2014 and custom quantization matrices.")
2015 (license license:gpl2+)))
2016
2017 (define-public streamlink
2018 (package
2019 (name "streamlink")
2020 (version "0.14.2")
2021 (source
2022 (origin
2023 (method url-fetch)
2024 (uri (pypi-uri "streamlink" version))
2025 (sha256
2026 (base32
2027 "0l2145fd60i76afjisfxd48cwhwyir07i7s3bnimdq5db2kzkix8"))
2028 (patches (search-patches "streamlink-update-test.patch"))))
2029 (build-system python-build-system)
2030 (home-page "https://github.com/streamlink/streamlink")
2031 (native-inputs
2032 `(("python-freezegun" ,python-freezegun)
2033 ("python-pytest" ,python-pytest)
2034 ("python-mock" ,python-mock)
2035 ("python-requests-mock" ,python-requests-mock)))
2036 (propagated-inputs
2037 `(("python-pysocks" ,python-pysocks)
2038 ("python-websocket-client" ,python-websocket-client)
2039 ("python-iso3166" ,python-iso3166)
2040 ("python-iso639" ,python-iso639)
2041 ("python-isodate" ,python-isodate)
2042 ("python-pycryptodome" ,python-pycryptodome)
2043 ("python-requests" ,python-requests)
2044 ("python-urllib3" ,python-urllib3)))
2045 (synopsis "Extract streams from various services")
2046 (description "Streamlink is command-line utility that extracts streams
2047 from sites like Twitch.tv and pipes them into a video player of choice.")
2048 (license license:bsd-2)))
2049
2050 (define-public livestreamer
2051 (deprecated-package "livestreamer" streamlink))
2052
2053 (define-public twitchy
2054 (let ((commit "9beb36d80b16662414129693e74fa3a2fd97554e")) ; 3.4 has no tag
2055 (package
2056 (name "twitchy")
2057 (version (git-version "3.4" "1" commit))
2058 (source
2059 (origin
2060 (method git-fetch)
2061 (uri (git-reference
2062 (url "https://github.com/BasioMeusPuga/twitchy.git")
2063 (commit commit)))
2064 (file-name (git-file-name name version))
2065 (sha256
2066 (base32
2067 "0di03h1j9ipp2bbnxxlxz07v87icyg2hmnsr4s7184z5ql8kpzr7"))))
2068 (build-system python-build-system)
2069 (arguments
2070 '(#:phases
2071 (modify-phases %standard-phases
2072 (add-after 'unpack 'patch-paths
2073 (lambda* (#:key inputs #:allow-other-keys)
2074 (substitute* "twitchy/twitchy_play.py"
2075 (("\"streamlink ")
2076 (string-append "\"" (assoc-ref inputs "streamlink")
2077 "/bin/streamlink ")))
2078 #t))
2079 (add-before 'check 'check-setup
2080 (lambda _
2081 (setenv "HOME" (getcwd)) ;Needs to write to ‘$HOME’.
2082 #t))
2083 (add-after 'install 'install-rofi-plugin
2084 (lambda* (#:key outputs #:allow-other-keys)
2085 (install-file "plugins/rofi-twitchy"
2086 (string-append (assoc-ref outputs "out")
2087 "/bin"))
2088 #t)))))
2089 (inputs
2090 `(("python-requests" ,python-requests)
2091 ("streamlink" ,streamlink)))
2092 (home-page "https://github.com/BasioMeusPuga/twitchy")
2093 (synopsis "Command-line interface for Twitch.tv")
2094 (description
2095 "This package provides a command-line interface for Twitch.tv")
2096 (license license:gpl3+))))
2097
2098 (define-public mlt
2099 (package
2100 (name "mlt")
2101 (version "6.12.0")
2102 (source (origin
2103 (method git-fetch)
2104 (uri (git-reference
2105 (url "https://github.com/mltframework/mlt.git")
2106 (commit (string-append "v" version))))
2107 (file-name (git-file-name name version))
2108 (sha256
2109 (base32
2110 "0pzm3mjbbdl2rkbswgyfkx552xlxh2qrwzsi2a4dicfr92rfgq6w"))))
2111 (build-system gnu-build-system)
2112 (arguments
2113 `(#:tests? #f ; no tests
2114 #:make-flags '("CC=gcc" "CXX=g++ -std=gnu++11")
2115 #:configure-flags
2116 (list "--enable-gpl3"
2117 "--enable-gpl")
2118 #:phases
2119 (modify-phases %standard-phases
2120 (add-after
2121 'configure 'override-LDFLAGS
2122 (lambda* (#:key outputs #:allow-other-keys)
2123 (substitute* "config.mak"
2124 (("LDFLAGS\\+=")
2125 (string-append "LDFLAGS+=-Wl,-rpath="
2126 (assoc-ref outputs "out")
2127 "/lib ")))
2128 #t)))))
2129 (inputs
2130 `(("alsa-lib" ,alsa-lib)
2131 ("ffmpeg" ,ffmpeg-3.4)
2132 ("fftw" ,fftw)
2133 ("frei0r-plugins" ,frei0r-plugins)
2134 ("gdk-pixbuf" ,gdk-pixbuf)
2135 ("gtk+" ,gtk+-2)
2136 ("libxml2" ,libxml2)
2137 ("jack" ,jack-1)
2138 ("ladspa" ,ladspa)
2139 ("libsamplerate" ,libsamplerate)
2140 ("pulseaudio" ,pulseaudio)
2141 ("qtbase" ,qtbase)
2142 ("qtsvg" ,qtsvg)
2143 ("sdl" ,sdl)
2144 ("sox" ,sox)))
2145 (native-inputs
2146 `(("pkg-config" ,pkg-config)))
2147 (home-page "https://www.mltframework.org/")
2148 (synopsis "Author, manage, and run multitrack audio/video compositions")
2149 (description
2150 "MLT is a multimedia framework, designed and developed for television
2151 broadcasting. It provides a toolkit for broadcasters, video editors, media
2152 players, transcoders, web streamers and many more types of applications. The
2153 functionality of the system is provided via an assortment of ready to use
2154 tools, XML authoring components, and an extensible plug-in based API.")
2155 (license license:gpl3)))
2156
2157 (define-public v4l-utils
2158 (package
2159 (name "v4l-utils")
2160 (version "1.12.5")
2161 (source (origin
2162 (method url-fetch)
2163 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
2164 "/v4l-utils-" version ".tar.bz2"))
2165 (sha256
2166 (base32
2167 "03g2b4rivrilimcp57mwrlsa3qvrxmk4sza08mygwmqbvcnic606"))))
2168 (build-system gnu-build-system)
2169 (arguments
2170 '(#:configure-flags
2171 (list (string-append "--with-udevdir="
2172 (assoc-ref %outputs "out")
2173 "/lib/udev")
2174 "CXXFLAGS=-std=gnu++11")))
2175 (native-inputs
2176 `(("perl" ,perl)
2177 ("pkg-config" ,pkg-config)))
2178 (inputs
2179 `(("alsa-lib" ,alsa-lib)
2180 ("glu" ,glu)
2181 ("libjpeg" ,libjpeg)
2182 ("libx11" ,libx11)
2183 ("qtbase" ,qtbase)
2184 ("eudev" ,eudev)))
2185 (synopsis "Realtime video capture utilities for Linux")
2186 (description "The v4l-utils provide a series of libraries and utilities to
2187 be used for realtime video capture via Linux-specific APIs.")
2188 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
2189 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
2190 (license (list license:lgpl2.1+ license:gpl2))))
2191
2192 (define-public obs
2193 (package
2194 (name "obs")
2195 (version "22.0.3")
2196 (source (origin
2197 (method git-fetch)
2198 (uri (git-reference
2199 (url "https://github.com/obsproject/obs-studio.git")
2200 (commit version)))
2201 (file-name (git-file-name name version))
2202 (sha256
2203 (base32
2204 "0ri9qkqk3h71b1a5bwpjzqdr21bbmfqbykg48l779d20zln23n1i"))))
2205 (build-system cmake-build-system)
2206 (arguments
2207 `(#:tests? #f)) ; no tests
2208 (native-inputs
2209 `(("pkg-config" ,pkg-config)))
2210 (inputs
2211 `(("alsa-lib" ,alsa-lib)
2212 ("curl" ,curl)
2213 ("eudev" ,eudev)
2214 ("ffmpeg" ,ffmpeg)
2215 ("fontconfig" ,fontconfig)
2216 ("freetype" ,freetype)
2217 ("jack" ,jack-1)
2218 ("jansson" ,jansson)
2219 ("libx264" ,libx264)
2220 ("libxcomposite" ,libxcomposite)
2221 ("mesa" ,mesa)
2222 ("pulseaudio" ,pulseaudio)
2223 ("qtbase" ,qtbase)
2224 ("qtx11extras" ,qtx11extras)
2225 ("speex" ,speex)
2226 ("v4l-utils" ,v4l-utils)
2227 ("zlib" ,zlib)))
2228 (synopsis "Live streaming software")
2229 (description "Open Broadcaster Software provides a graphical interface for
2230 video recording and live streaming. OBS supports capturing audio and video
2231 from many input sources such as webcams, X11 (for screencasting), PulseAudio,
2232 and JACK.")
2233 (home-page "https://obsproject.com")
2234 (supported-systems '("x86_64-linux" "i686-linux"))
2235 (license license:gpl2+)))
2236
2237 (define-public libvdpau
2238 (package
2239 (name "libvdpau")
2240 (version "1.2")
2241 (source
2242 (origin
2243 (method url-fetch)
2244 (uri (string-append "https://gitlab.freedesktop.org/vdpau/libvdpau"
2245 "/uploads/14b620084c027d546fa0b3f083b800c6/"
2246 "libvdpau-" version ".tar.bz2"))
2247 (sha256
2248 (base32
2249 "01ps6g6p6q7j2mjm9vn44pmzq3g75mm7mdgmnhb1qkjjdwc9njba"))))
2250 (build-system gnu-build-system)
2251 (native-inputs
2252 `(("pkg-config" ,pkg-config)))
2253 (inputs
2254 `(("libx11" ,libx11 "out")
2255 ("libxext" ,libxext)
2256 ("xorgproto" ,xorgproto)))
2257 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
2258 (synopsis "Video Decode and Presentation API")
2259 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
2260 provides an interface to video decode acceleration and presentation hardware
2261 present in modern GPUs.")
2262 (license (license:x11-style "file://COPYING"))))
2263
2264 (define-public vdpauinfo
2265 (package
2266 (name "vdpauinfo")
2267 (version "1.0")
2268 (source
2269 (origin
2270 (method url-fetch)
2271 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
2272 name "-" version ".tar.gz"))
2273 (sha256
2274 (base32
2275 "1i2b0k9h8r0lnxlrkgqzmrjakgaw3f1ygqqwzx8w6676g85rcm20"))))
2276 (build-system gnu-build-system)
2277 (native-inputs
2278 `(("pkg-config" ,pkg-config)
2279 ("libx11" ,libx11)))
2280 (propagated-inputs
2281 `(("libvdpau" ,libvdpau)))
2282 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
2283 (synopsis "Tool to query the capabilities of a VDPAU implementation")
2284 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
2285 implementation.")
2286 (license (license:x11-style "file://COPYING"))))
2287
2288 (define-public libvdpau-va-gl
2289 (package
2290 (name "libvdpau-va-gl")
2291 (version "0.4.2")
2292 (source
2293 (origin
2294 (method url-fetch)
2295 (uri (string-append "https://github.com/i-rinat/libvdpau-va-gl/"
2296 "releases/download/v" version "/libvdpau-va-gl-"
2297 version ".tar.gz"))
2298 (sha256
2299 (base32
2300 "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
2301 (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
2302 (modules '((guix build utils)))
2303 (snippet '(begin (delete-file-recursively "3rdparty")
2304 #t))))
2305 (build-system cmake-build-system)
2306 (arguments
2307 '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
2308 (native-inputs
2309 `(("libvdpau" ,libvdpau)
2310 ("pkg-config" ,pkg-config)))
2311 (inputs
2312 `(("libva" ,libva)
2313 ("mesa" ,mesa)))
2314 (home-page "https://github.com/i-rinat/libvdpau-va-gl")
2315 (synopsis "VDPAU driver with VA-API/OpenGL backend")
2316 (description
2317 "Many applications can use VDPAU to accelerate portions of the video
2318 decoding process and video post-processing to the GPU video hardware. Since
2319 there is no VDPAU available on Intel chips, they fall back to different drawing
2320 techniques. This driver uses OpenGL under the hood to accelerate drawing and
2321 scaling and VA-API (if available) to accelerate video decoding.")
2322 (license license:expat)))
2323
2324 (define-public recordmydesktop
2325 (package
2326 (name "recordmydesktop")
2327 (version "0.3.8.1")
2328 (source (origin
2329 (method url-fetch)
2330 (uri (string-append "mirror://sourceforge/" name "/" name "/"
2331 version "/recordmydesktop-" version ".tar.gz"))
2332 (sha256
2333 (base32
2334 "133kkl5j0r877d41bzj7kj0vf3xm8x80yyx2n8nqxrva304f58ik"))))
2335 (build-system gnu-build-system)
2336 (inputs `(("popt" ,popt)
2337 ("zlib" ,zlib)
2338 ("libx11" ,libx11)
2339 ("libice" ,libice)
2340 ("libsm" ,libsm)
2341 ("libxfixes" ,libxfixes)
2342 ("libxdamage" ,libxdamage)
2343 ("libxext" ,libxext)
2344 ("alsa-lib" ,alsa-lib)
2345 ("libvorbis" ,libvorbis)
2346 ("libtheora" ,libtheora)))
2347 (home-page "http://recordmydesktop.sourceforge.net/")
2348 (synopsis "Desktop session video recorder")
2349 (description
2350 "recordMyDesktop is a command-line tool that captures the activity in
2351 your graphical desktop and encodes it as a video. This is a useful tool for
2352 making @dfn{screencasts}.")
2353 (license license:gpl2+)))
2354
2355 (define-public simplescreenrecorder
2356 (package
2357 (name "simplescreenrecorder")
2358 (version "0.3.11")
2359 (source
2360 (origin
2361 (method git-fetch)
2362 (uri (git-reference
2363 (url "https://github.com/MaartenBaert/ssr.git")
2364 (commit version)))
2365 (file-name (git-file-name name version))
2366 (sha256
2367 (base32
2368 "0n702dnv4qshgn3b90ixvplfafjhgz6040yir5vy8khjdpciysq4"))))
2369 (build-system cmake-build-system)
2370 ;; Although libx11, libxfixes, libxext are listed as build dependencies in
2371 ;; README.md, the program builds and functions properly without them.
2372 ;; As a result, they are omitted. Please add them back if problems appear.
2373 (inputs
2374 `(("alsa-lib" ,alsa-lib)
2375 ("ffmpeg" ,ffmpeg)
2376 ("glu" ,glu)
2377 ("jack" ,jack-1)
2378 ("libxi" ,libxi)
2379 ("pulseaudio" ,pulseaudio)
2380 ("qtbase" ,qtbase)
2381 ("qtx11extras" ,qtx11extras)))
2382 (native-inputs `(("pkg-config" ,pkg-config)))
2383 (arguments
2384 `(#:configure-flags
2385 (list "-DWITH_QT5=TRUE")
2386 #:tests? #f)) ; no test suite
2387 ;; Using HTTPS causes part of the page to be displayed improperly.
2388 (home-page "http://www.maartenbaert.be/simplescreenrecorder/")
2389 (synopsis "Screen recorder")
2390 (description "SimpleScreenRecorder is an easy to use screen recorder with
2391 a graphical user interface. It supports recording the entire screen, or a
2392 part of it, and allows encoding in many different codecs and file formats.
2393 Other features include a live preview and live streaming.")
2394 (license (list license:gpl3+ ; most files
2395 license:zlib ; glinject/elfhacks.*
2396 license:isc ; glinject/*
2397 license:x11)))) ; build-aux/install-sh
2398
2399 (define-public libsmpeg
2400 (package
2401 (name "libsmpeg")
2402 (version "0.4.5-401")
2403 (source (origin
2404 (method svn-fetch)
2405 (uri (svn-reference
2406 (url "svn://svn.icculus.org/smpeg/trunk/")
2407 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
2408 (file-name (string-append name "-" version "-checkout"))
2409 (sha256
2410 (base32
2411 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
2412 (build-system gnu-build-system)
2413 (arguments
2414 `(#:phases
2415 (modify-phases %standard-phases
2416 (add-after 'unpack 'autogen.sh
2417 (lambda _
2418 (invoke "sh" "autogen.sh"))))))
2419 (native-inputs
2420 `(("autoconf" ,autoconf)
2421 ("automake" ,automake)))
2422 (inputs
2423 `(("sdl" ,sdl2)))
2424 (home-page "http://icculus.org/smpeg/")
2425 (synopsis "SDL MPEG decoding library")
2426 (description
2427 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
2428 with sound support. Video playback is based on the ubiquitous Berkeley MPEG
2429 player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
2430 library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
2431 and MPEG system streams.")
2432 (license (list license:expat
2433 license:lgpl2.1
2434 license:lgpl2.1+
2435 license:gpl2))))
2436
2437 ;; for btanks
2438 (define-public libsmpeg-with-sdl1
2439 (package (inherit libsmpeg)
2440 (name "libsmpeg")
2441 (version "0.4.5-399")
2442 (source (origin
2443 (method svn-fetch)
2444 (uri (svn-reference
2445 (url "svn://svn.icculus.org/smpeg/trunk/")
2446 (revision 399))) ; tagged release 0.4.5
2447 (file-name (string-append name "-" version "-checkout"))
2448 (sha256
2449 (base32
2450 "0jfi085rf3fa5xsn0vd3nqf32my8ph9c6a9445y7a8lrlz4dms64"))))
2451 (inputs
2452 `(("sdl" ,sdl)))))
2453
2454 (define-public libbdplus
2455 (package
2456 (name "libbdplus")
2457 (version "0.1.2")
2458 (source
2459 (origin
2460 (method url-fetch)
2461 (uri (string-append "https://ftp.videolan.org/pub/videolan/libbdplus/"
2462 version "/" name "-" version ".tar.bz2"))
2463 (sha256
2464 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
2465 (inputs
2466 `(("libgcrypt" ,libgcrypt)))
2467 (build-system gnu-build-system)
2468 (home-page "https://www.videolan.org/developers/libbdplus.html")
2469 (synopsis "Library for decrypting certain Blu-Ray discs")
2470 (description "libbdplus is a library which implements the BD+ System
2471 specifications.")
2472 (license license:lgpl2.1+)))
2473
2474 (define-public libaacs
2475 (package
2476 (name "libaacs")
2477 (version "0.9.0")
2478 (source
2479 (origin
2480 (method url-fetch)
2481 (uri (string-append "https://ftp.videolan.org/pub/videolan/libaacs/"
2482 version "/" name "-" version ".tar.bz2"))
2483 (sha256
2484 (base32 "1kms92i0c7i1yl659kqjf19lm8172pnpik5lsxp19xphr74vvq27"))))
2485 (inputs
2486 `(("libgcrypt" ,libgcrypt)))
2487 (native-inputs
2488 `(("bison" ,bison)
2489 ("flex" ,flex)))
2490 (build-system gnu-build-system)
2491 (home-page "https://www.videolan.org/developers/libaacs.html")
2492 (synopsis "Library for decrypting certain Blu-Ray discs")
2493 (description "libaacs is a library which implements the Advanced Access
2494 Content System specification.")
2495 (license license:lgpl2.1+)))
2496
2497 (define-public mps-youtube
2498 (package
2499 (name "mps-youtube")
2500 (version "0.2.8")
2501 (source
2502 (origin
2503 (method git-fetch)
2504 (uri (git-reference
2505 (url "https://github.com/mps-youtube/mps-youtube.git")
2506 (commit (string-append "v" version))))
2507 (file-name (git-file-name name version))
2508 (sha256
2509 (base32
2510 "1w1jhw9rg3dx7vp97cwrk5fymipkcy2wrbl1jaa38ivcjhqg596y"))))
2511 (build-system python-build-system)
2512 (arguments
2513 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
2514 ;; test suite results differ depending on the country and also introduce
2515 ;; non-determinism in the tests.
2516 ;; https://github.com/mps-youtube/mps-youtube/issues/556
2517 `(#:tests? #f))
2518 (propagated-inputs
2519 `(("python-pafy" ,python-pafy)
2520 ("python-pygobject" ,python-pygobject))) ; For mpris2 support
2521 (home-page "https://github.com/mps-youtube/mps-youtube")
2522 (synopsis "Terminal based YouTube player and downloader")
2523 (description
2524 "@code{mps-youtube} is based on mps, a terminal based program to
2525 search, stream and download music. This implementation uses YouTube as
2526 a source of content and can play and download video as well as audio.
2527 It can use either mpv or mplayer for playback, and for conversion of
2528 formats ffmpeg or libav is used. Users should install one of the
2529 supported players in addition to this package.")
2530 (license license:gpl3+)))
2531
2532 (define-public handbrake
2533 (package
2534 (name "handbrake")
2535 (version "1.2.0")
2536 (source (origin
2537 (method url-fetch)
2538 (uri (string-append "https://download.handbrake.fr/releases/"
2539 version "/HandBrake-" version "-source.tar.bz2"))
2540 (sha256
2541 (base32
2542 "03clkknaq3mz84p85cvr21gsy9b8vv2g4vvyfz44hz8la253jfqi"))
2543 (modules '((guix build utils)))
2544 (snippet
2545 ;; Remove "contrib" and source not necessary for
2546 ;; building/running under a GNU environment.
2547 '(begin
2548 (for-each delete-file-recursively
2549 '("contrib" "macosx" "win"))
2550 (substitute* "make/include/main.defs"
2551 ;; Disable unconditional inclusion of "contrib" libraries
2552 ;; (ffmpeg, libvpx, libdvdread, libdvdnav, and libbluray),
2553 ;; which would lead to fetching and building of these
2554 ;; libraries. Use our own instead.
2555 (("MODULES \\+= contrib") "# MODULES += contrib"))
2556 #t))
2557 (patches (search-patches "handbrake-opt-in-nvenc.patch"))))
2558 (build-system glib-or-gtk-build-system)
2559 (native-inputs
2560 `(("automake" ,automake) ;gui subpackage must be bootstrapped
2561 ("autoconf" ,autoconf)
2562 ("cmake" ,cmake) ;TODO: could probably strip check from make/configure.py
2563 ("curl" ,curl) ;not actually used, but tested for
2564 ("intltool" ,intltool)
2565 ("libtool" ,libtool)
2566 ("pkg-config" ,pkg-config)
2567 ("python" ,python-2))) ;for configuration
2568 (inputs
2569 `(("bzip2" ,bzip2)
2570 ("dbus-glib" ,dbus-glib)
2571 ("ffmpeg" ,ffmpeg)
2572 ("fontconfig" ,fontconfig)
2573 ("freetype" ,freetype)
2574 ("glib" ,glib)
2575 ("gstreamer" ,gstreamer)
2576 ("gst-plugins-base" ,gst-plugins-base)
2577 ("gtk+" ,gtk+)
2578 ("jansson" ,jansson)
2579 ("lame" ,lame)
2580 ("libass" ,libass)
2581 ("libbluray" ,libbluray)
2582 ("libdvdnav" ,libdvdnav)
2583 ("libdvdread" ,libdvdread)
2584 ("libgudev" ,libgudev)
2585 ("libmpeg2" ,libmpeg2)
2586 ("libnotify" ,libnotify)
2587 ("libogg" ,libogg)
2588 ("libopus" ,opus)
2589 ("libsamplerate" ,libsamplerate)
2590 ("libtheora" ,libtheora)
2591 ("libvorbis" ,libvorbis)
2592 ("libvpx" ,libvpx)
2593 ("libxml2" ,libxml2)
2594 ("libx264" ,libx264)
2595 ("speex" ,speex)
2596 ("x265" ,x265)
2597 ("zlib" ,zlib)))
2598 (arguments
2599 `(#:tests? #f ;tests require Ruby and claim to be unsupported
2600 #:configure-flags
2601 (list "--disable-gtk-update-checks"
2602 (string-append "CPPFLAGS=-I"
2603 (assoc-ref %build-inputs "libxml2")
2604 "/include/libxml2")
2605 "LDFLAGS=-lx265")
2606 #:phases
2607 (modify-phases %standard-phases
2608 (replace 'bootstrap
2609 ;; Run bootstrap ahead of time so that shebangs get patched.
2610 (lambda _
2611 (setenv "CONFIG_SHELL" (which "sh"))
2612 (setenv "NOCONFIGURE" "1")
2613 ;; Patch the Makefile so that it doesn't bootstrap again.
2614 (substitute* "gtk/module.rules"
2615 ((".*autogen\\.sh.*") ""))
2616 (invoke "sh" "./gtk/autogen.sh")))
2617 (replace 'configure
2618 (lambda* (#:key outputs configure-flags #:allow-other-keys)
2619 ;; 'configure' is not an autoconf-generated script, and
2620 ;; errors on unrecognized arguments,
2621 ;; e.g. --enable-fast-install
2622 (let ((out (assoc-ref outputs "out")))
2623 (apply invoke "./configure"
2624 (string-append "--prefix=" out)
2625 (or configure-flags '())))))
2626 (add-after 'configure 'chdir-build
2627 (lambda _ (chdir "./build") #t)))))
2628 (home-page "https://handbrake.fr")
2629 (synopsis "Video transcoder")
2630 (description
2631 "HandBrake is a tool for converting video from any format to a selection
2632 of modern, widely supported codecs.")
2633 ;; Some under GPLv2+, some under LGPLv2.1+, and portions under BSD3.
2634 ;; Combination under GPLv2. See LICENSE.
2635 (license license:gpl2)))
2636
2637 (define-public openh264
2638 (package
2639 (name "openh264")
2640 (version "1.8.0")
2641 (source (origin
2642 (method url-fetch)
2643 (uri (string-append "https://github.com/cisco/"
2644 name "/releases/download/v"
2645 version "/Source.Code.tar.gz.gz"))
2646 (file-name (string-append name "-" version ".tar.gz"))
2647 (sha256
2648 (base32
2649 "0niha3wnn1jsndvz9vfwy2wyql8mp9j6v75vjsipy0idwan5yzgf"))))
2650 (build-system gnu-build-system)
2651 (native-inputs
2652 `(("nasm" ,nasm)
2653 ("python" ,python)))
2654 (arguments
2655 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2656 "CC=gcc")
2657 #:test-target "test"
2658 #:phases (modify-phases %standard-phases
2659 ;; no configure script
2660 (delete 'configure))))
2661 (home-page "http://www.openh264.org/")
2662 (synopsis "H264 decoder library")
2663 (description
2664 "Openh264 is a library which can decode H264 video streams.")
2665 (license license:bsd-2)))
2666
2667 (define-public libmp4v2
2668 (package
2669 (name "libmp4v2")
2670 (version "2.0.0")
2671 (source
2672 (origin
2673 (method url-fetch)
2674 ;; XXX: The new location of upstream is uncertain and will become relevant the
2675 ;; moment when the googlecode archive shuts down. It is past the date it
2676 ;; should've been turned off. I tried to communicate with upstream, but this
2677 ;; wasn't very responsive and not very helpful. The short summary is, it is
2678 ;; chaos when it comes to the amount of forks and only time will tell where
2679 ;; the new upstream location is.
2680 (uri (string-append "https://storage.googleapis.com/google-"
2681 "code-archive-downloads/v2/"
2682 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
2683 (file-name (string-append name "-" version ".tar.bz2"))
2684 (sha256
2685 (base32
2686 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
2687 (build-system gnu-build-system)
2688 (outputs '("out"
2689 "static")) ; 3.7MiB .a file
2690 (arguments
2691 `(#:phases
2692 (modify-phases %standard-phases
2693 (add-after 'unpack 'remove-dates
2694 (lambda _
2695 ;; Make the build reproducible.
2696 (substitute* "configure"
2697 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
2698 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
2699 #t))
2700 (add-after 'install 'move-static-libraries
2701 (lambda* (#:key outputs #:allow-other-keys)
2702 ;; Move static libraries to the "static" output.
2703 (let* ((out (assoc-ref outputs "out"))
2704 (lib (string-append out "/lib"))
2705 (static (assoc-ref outputs "static"))
2706 (slib (string-append static "/lib")))
2707 (mkdir-p slib)
2708 (for-each (lambda (file)
2709 (install-file file slib)
2710 (delete-file file))
2711 (find-files lib "\\.a$"))
2712 #t))))))
2713 (native-inputs
2714 `(("help2man" ,help2man)
2715 ("dejagnu" ,dejagnu)))
2716 (home-page "https://code.google.com/archive/p/mp4v2/")
2717 (synopsis "API to create and modify mp4 files")
2718 (description
2719 "The MP4v2 library provides an API to create and modify mp4 files as defined by
2720 ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
2721 file format that has been used as a multimedia file format in a variety of platforms and
2722 applications. It is a very powerful and extensible format that can accommodate
2723 practically any type of media.")
2724 (license license:mpl1.1)))
2725
2726 (define-public libmediainfo
2727 (package
2728 (name "libmediainfo")
2729 (version "0.7.95")
2730 (source (origin
2731 (method url-fetch)
2732 (uri (string-append "https://mediaarea.net/download/source/"
2733 name "/" version"/"
2734 name "_" version ".tar.bz2"))
2735 (sha256
2736 (base32
2737 "1kchh6285b07z5nixv619hc9gml2ysdayicdiv30frrlqiyxqw4b"))))
2738 ;; TODO add a Big Buck Bunny webm for tests.
2739 (native-inputs
2740 `(("autoconf" ,autoconf)
2741 ("automake" ,automake)
2742 ("libtool" ,libtool)
2743 ("pkg-config" ,pkg-config)
2744 ("zlib" ,zlib)
2745 ("tinyxml2" ,tinyxml2)
2746 ("curl" ,curl)
2747 ("libzen" ,libzen)))
2748 (build-system gnu-build-system)
2749 (arguments
2750 '(#:tests? #f ; see above TODO
2751 #:phases
2752 ;; build scripts not in root of archive
2753 (modify-phases %standard-phases
2754 (add-after 'unpack 'change-to-build-dir
2755 (lambda _
2756 (chdir "Project/GNU/Library")
2757 #t))
2758 (add-after 'change-to-build-dir 'autogen
2759 (lambda _
2760 (invoke "sh" "autogen.sh"))))))
2761 (home-page "https://mediaarea.net/en/MediaInfo")
2762 (synopsis "Library for retrieving media metadata")
2763 (description "MediaInfo is a library used for retrieving technical
2764 information and other metadata about audio or video files. A non-exhaustive
2765 list of the information MediaInfo can retrieve from media files include:
2766
2767 @itemize
2768 @item General: title, author, director, album, track number, date, duration...
2769 @item Video: codec, aspect, fps, bitrate...
2770 @item Audio: codec, sample rate, channels, language, bitrate...
2771 @item Text: language of subtitle
2772 @item Chapters: number of chapters, list of chapters
2773 @end itemize
2774
2775 MediaInfo supports the following formats:
2776
2777 @itemize
2778 @item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
2779 MPEG-2, MPEG-4, DVD (VOB)...
2780 @item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
2781 @item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
2782 @item Subtitles: SRT, SSA, ASS, SAMI...
2783 @end itemize\n")
2784 (license license:bsd-2)))
2785
2786 ;; TODO also have a GUI version available
2787 (define-public mediainfo
2788 (package
2789 (name "mediainfo")
2790 (version "18.12")
2791 (source (origin
2792 (method url-fetch)
2793 ;; Warning: This source has proved unreliable 1 time at least.
2794 ;; Consider an alternate source or report upstream if this
2795 ;; happens again.
2796 (uri (string-append "https://mediaarea.net/download/source/"
2797 name "/" version "/"
2798 name "_" version ".tar.bz2"))
2799 (sha256
2800 (base32
2801 "1ix95ilcjlawcq6phh25cgplm3riqa2ii7ql82g8yagqs4ldqp6a"))))
2802 (native-inputs
2803 `(("autoconf" ,autoconf)
2804 ("automake" ,automake)
2805 ("libtool" ,libtool)
2806 ("pkg-config" ,pkg-config)
2807 ("zlib" ,zlib)
2808 ("libmediainfo" ,libmediainfo)
2809 ("libzen" ,libzen)))
2810 (build-system gnu-build-system)
2811 (arguments
2812 '(#:tests? #f ; lacks tests
2813 #:phases
2814 ;; build scripts not in root of archive
2815 (modify-phases %standard-phases
2816 (add-after 'unpack 'change-to-build-dir
2817 (lambda _
2818 (chdir "Project/GNU/CLI")
2819 #t)))))
2820 (home-page "https://mediaarea.net/en/MediaInfo")
2821 (synopsis "Utility for reading media metadata")
2822 (description "MediaInfo is a utility used for retrieving technical
2823 information and other metadata about audio or video files. It supports the
2824 many codecs and formats supported by libmediainfo.")
2825 (license license:bsd-2)))
2826
2827 (define-public livemedia-utils
2828 (package
2829 (name "livemedia-utils")
2830 (version "2018.10.17")
2831 (source (origin
2832 (method url-fetch)
2833 (uri (string-append
2834 "https://download.videolan.org/contrib/live555/live."
2835 version ".tar.gz"))
2836 (sha256
2837 (base32
2838 "1s69ipvdc6ldscp0cr1zpsll8xc3qcagr95nl84x7b1rbg4xjs3w"))
2839 (modules '((guix build utils)))
2840 (snippet '(begin
2841 ;; As of glibc 2.26, <xlocale.h> no longer is.
2842 (substitute* "liveMedia/include/Locale.hh"
2843 (("xlocale\\.h") "locale.h"))
2844 #t))))
2845 (build-system gnu-build-system)
2846 (arguments
2847 '(#:tests? #f ; no tests
2848 #:make-flags (list "CC=gcc"
2849 (string-append "LDFLAGS=-Wl,-rpath="
2850 (assoc-ref %outputs "out") "/lib")
2851 (string-append "PREFIX="
2852 (assoc-ref %outputs "out")))
2853 #:phases (modify-phases %standard-phases
2854 (add-before 'configure 'fix-makefiles-generation
2855 (lambda _
2856 (substitute* "genMakefiles"
2857 (("/bin/rm") "rm"))
2858 #t))
2859 (replace 'configure
2860 (lambda _
2861 (invoke "./genMakefiles"
2862 "linux-with-shared-libraries"))))))
2863 (home-page "http://www.live555.com/liveMedia/")
2864 (synopsis "Set of C++ libraries for multimedia streaming")
2865 (description "This code forms a set of C++ libraries for multimedia
2866 streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
2867 can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
2868 JPEG video, and several audio codecs. They can easily be extended to support
2869 additional (audio and/or video) codecs, and can also be used to build basic
2870 RTSP or SIP clients and servers.")
2871 (license license:lgpl3+)))
2872
2873 (define-public libdvbpsi
2874 (package
2875 (name "libdvbpsi")
2876 (version "1.3.2")
2877 (source (origin
2878 (method url-fetch)
2879 (uri (string-append
2880 "https://download.videolan.org/pub/libdvbpsi/"
2881 version "/libdvbpsi-" version ".tar.bz2"))
2882 (sha256
2883 (base32
2884 "1zn5hfv4qbahmydbwh59a3b480s3m5ss27r6ml35gqdip7r3jkmc"))))
2885 (build-system gnu-build-system)
2886 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
2887 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
2888 tables")
2889 (description "libdvbpsi is a simple library designed for decoding and
2890 generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
2891 and ITU-T H.222.0.")
2892 (license license:lgpl2.1)))
2893
2894 (define-public ffms2
2895 (package
2896 (name "ffms2")
2897 (version "2.23")
2898 (home-page "https://github.com/FFMS/ffms2")
2899 (source (origin
2900 (method git-fetch)
2901 (uri (git-reference
2902 (url "https://github.com/FFMS/ffms2.git")
2903 (commit version)))
2904 (file-name (git-file-name name version))
2905 (sha256
2906 (base32
2907 "0dkz5b3gxq5p4xz0qqg6l2sigszrlsinz3skyf0ln4wf3zrvf8m5"))))
2908 (build-system gnu-build-system)
2909 (arguments
2910 '(#:configure-flags
2911 (list "--enable-avresample")))
2912 (inputs
2913 `(("zlib" ,zlib)))
2914 (propagated-inputs
2915 `(("ffmpeg" ,ffmpeg)))
2916 (native-inputs
2917 `(("pkg-config" ,pkg-config)))
2918 (synopsis "Cross-platform wrapper around ffmpeg/libav")
2919 (description
2920 "FFMpegSource is a wrapper library around ffmpeg/libav that allows
2921 programmers to access a standard API to open and decompress media files.")
2922 ;; sources are distributed under a different license that the binary.
2923 ;; see https://github.com/FFMS/ffms2/blob/master/COPYING
2924 (license license:gpl2+))); inherits from ffmpeg
2925
2926 (define-public aegisub
2927 (package
2928 (name "aegisub")
2929 (version "3.2.2")
2930 (source (origin
2931 (method url-fetch)
2932 (uri (string-append
2933 "http://ftp.aegisub.org/pub/archives/releases/source/"
2934 name "-" version ".tar.xz"))
2935 (sha256
2936 (base32
2937 "11b83qazc8h0iidyj1rprnnjdivj1lpphvpa08y53n42bfa36pn5"))
2938 (patches (search-patches "aegisub-icu59-include-unistr.patch"
2939 "aegisub-boost68.patch"))))
2940 (build-system gnu-build-system)
2941 (arguments
2942 `(#:configure-flags
2943 (list "--disable-update-checker"
2944 "--without-portaudio"
2945 "--without-openal"
2946 "--without-oss"
2947 "CXXFLAGS=-DU_USING_ICU_NAMESPACE=1")
2948 ;; tests require busted, a lua package we don't have yet
2949 #:tests? #f
2950 #:phases
2951 (modify-phases %standard-phases
2952 (add-before 'configure 'fix-ldflags
2953 (lambda _
2954 (setenv "LDFLAGS" "-pthread")
2955 #t))
2956 (add-after 'unpack 'fix-boost-headers
2957 (lambda _
2958 (substitute*
2959 '("src/subtitles_provider_libass.cpp"
2960 "src/colour_button.cpp"
2961 "src/video_provider_dummy.cpp"
2962 "./src/video_frame.cpp")
2963 (("#include <boost/gil/gil_all.hpp>")
2964 "#include <boost/gil.hpp>"))
2965 #t)))))
2966 (inputs
2967 `(("boost" ,boost)
2968 ("desktop-file-utils" ,desktop-file-utils)
2969 ("ffms2" ,ffms2)
2970 ("fftw" ,fftw)
2971 ("hunspell" ,hunspell)
2972 ("mesa" ,mesa)
2973 ("libass" ,libass)
2974 ("alsa-lib" ,alsa-lib)
2975 ("pulseaudio" ,pulseaudio)
2976 ("libx11" ,libx11)
2977 ("freetype" ,freetype)
2978 ("wxwidgets-gtk2" ,wxwidgets-gtk2)))
2979 (native-inputs
2980 `(("intltool" ,intltool)
2981 ("pkg-config" ,pkg-config)))
2982 (home-page "http://www.aegisub.org/")
2983 (synopsis "Subtitle engine")
2984 (description
2985 "Aegisub is a tool for creating and modifying subtitles. Aegisub makes
2986 it quick and easy to time subtitles to audio, and features many powerful
2987 tools for styling them, including a built-in real-time video preview.")
2988 (license (list license:bsd-3 ; the package is licensed under the bsd-3, except
2989 license:mpl1.1 ; for vendor/universalchardet under the mpl1.1
2990 license:expat)))) ; and src/gl that is under a license similar
2991 ; the the Expat license, with a rewording (Software -> Materials). (called MIT
2992 ; by upstream). See https://github.com/Aegisub/Aegisub/blob/master/LICENCE
2993 ; src/MatroskaParser.(c|h) is under bsd-3 with permission from the author
2994
2995 (define-public gst-transcoder
2996 (package
2997 (name "gst-transcoder")
2998 (version "1.12.2")
2999 (source
3000 (origin
3001 (method git-fetch)
3002 (uri (git-reference
3003 (url "https://github.com/pitivi/gst-transcoder.git")
3004 (commit version)))
3005 (file-name (git-file-name name version))
3006 (sha256
3007 (base32
3008 "0nw1zykqc6c8xs3ri55pm00pwyz93z4y4nd880apfiwj7yv5p3az"))))
3009 (build-system meson-build-system)
3010 (inputs
3011 `(("gobject-introspection" ,gobject-introspection)
3012 ("glib" ,glib)
3013 ("gstreamer" ,gstreamer)
3014 ("gst-plugins-base" ,gst-plugins-base)))
3015 (native-inputs
3016 `(("python" ,python)
3017 ("pkg-config" ,pkg-config)))
3018 (home-page "https://github.com/pitivi/gst-transcoder/")
3019 (synopsis "GStreamer Transcoding API")
3020 (description "GStreamer Transcoding API")
3021 (license license:lgpl2.1)))
3022
3023 (define-public gavl
3024 (package
3025 (name "gavl")
3026 (version "1.4.0")
3027 (source
3028 (origin
3029 (method url-fetch)
3030 (uri (string-append "mirror://sourceforge/gmerlin/"
3031 name "/" version "/"
3032 name "-" version ".tar.gz"))
3033 (file-name (string-append name "-" version ".tar.gz"))
3034 (sha256
3035 (base32
3036 "1kikkn971a14zzm7svi7190ldc14fjai0xyhpbcmp48s750sraji"))))
3037 (build-system gnu-build-system)
3038 (arguments
3039 '(#:configure-flags '("LIBS=-lm")))
3040 (native-inputs
3041 `(("pkg-config" ,pkg-config)
3042 ("doxygen" ,doxygen)))
3043 (home-page "http://gmerlin.sourceforge.net")
3044 (synopsis "Low level library for multimedia API building")
3045 (description
3046 "Gavl is short for Gmerlin Audio Video Library. It is a low level
3047 library, upon which multimedia APIs can be built. Gavl handles all the
3048 details of audio and video formats like colorspaces, sample rates,
3049 multichannel configurations, etc. It provides standardized definitions for
3050 those formats as well as container structures for carrying audio samples or
3051 video images inside an application.
3052
3053 In addition, it handles the sometimes ugly task of converting between all
3054 these formats and provides some elementary operations (copying, scaling,
3055 alpha blending etc).")
3056 (license license:gpl3)))
3057
3058 (define-public frei0r-plugins
3059 (package
3060 (name "frei0r-plugins")
3061 (version "1.6.1")
3062 (source
3063 (origin
3064 (method url-fetch)
3065 (uri (string-append "https://files.dyne.org/frei0r/"
3066 "frei0r-plugins-" version ".tar.gz"))
3067 (sha256
3068 (base32
3069 "0pji26fpd0dqrx1akyhqi6729s394irl73dacnyxk58ijqq4dhp0"))))
3070 (build-system gnu-build-system)
3071 (arguments
3072 `(#:phases
3073 (modify-phases %standard-phases
3074 (add-after 'unpack 'autotools
3075 (lambda _
3076 (invoke "sh" "autogen.sh"))))))
3077 ;; TODO: opencv for additional face detection filters.
3078 (inputs
3079 `(("gavl" ,gavl)
3080 ("cairo" ,cairo)))
3081 (native-inputs
3082 `(("pkg-config" ,pkg-config)
3083 ("libtool" ,libtool)
3084 ("automake" ,automake)
3085 ("autoconf" ,autoconf)))
3086 (home-page "https://www.dyne.org/software/frei0r/")
3087 (synopsis "Minimalistic plugin API for video effects")
3088 (description
3089 "Frei0r is a minimalistic plugin API for video effects.
3090 The main emphasis is on simplicity for an API that will round up
3091 the most common video effects into simple filters, sources and
3092 mixers that can be controlled by parameters. Frei0r wants to
3093 provide a way to share these simple effects between many
3094 applications, avoiding their reimplementation by different projects.
3095 It counts more than 100 plugins.")
3096 (license (list license:gpl2+
3097 ;; The following files are licensed as LGPL2.1+:
3098 ;; src/generator/ising0r/ising0r.c
3099 ;; src/generator/onecol0r/onecol0r.cpp
3100 ;; src/generator/nois0r/nois0r.cpp
3101 ;; src/generator/lissajous0r/lissajous0r.cpp
3102 ;; src/filter/ndvi/gradientlut.hpp
3103 ;; src/filter/ndvi/ndvi.cpp
3104 ;; src/filter/facedetect/facedetect.cpp
3105 license:lgpl2.1+))))
3106
3107 (define-public motion
3108 (package
3109 (name "motion")
3110 (version "4.2.2")
3111 (home-page "https://motion-project.github.io/")
3112 (source (origin
3113 (method git-fetch)
3114 (uri (git-reference
3115 (url "https://github.com/Motion-Project/motion.git")
3116 (commit (string-append "release-" version))))
3117 (sha256
3118 (base32
3119 "05c1gx75xy2hw49x6vkydvwxbr80kipsc3nr906k3hq8735svx6f"))
3120 (file-name (git-file-name name version))))
3121 (build-system gnu-build-system)
3122 (native-inputs
3123 `(("autoconf" ,autoconf-wrapper)
3124 ("automake" ,automake)
3125 ("gettext" ,gettext-minimal)
3126 ("pkg-config" ,pkg-config)))
3127 (inputs
3128 `(("libjpeg" ,libjpeg)
3129 ("ffmpeg" ,ffmpeg-3.4)
3130 ("libmicrohttpd" ,libmicrohttpd)
3131 ("sqlite" ,sqlite)))
3132 (arguments
3133 '(#:phases (modify-phases %standard-phases
3134 (replace 'bootstrap
3135 (lambda _
3136 (patch-shebang "version.sh")
3137 (invoke "autoreconf" "-vfi"))))
3138 #:configure-flags '("--sysconfdir=/etc")
3139 #:make-flags (list (string-append "sysconfdir="
3140 (assoc-ref %outputs "out")
3141 "/etc"))
3142
3143 #:tests? #f)) ; no 'check' target
3144 (synopsis "Detect motion from video signals")
3145 (description
3146 "Motion is a program that monitors the video signal from one or more
3147 cameras and is able to detect if a significant part of the picture has
3148 changed. Or in other words, it can detect motion.")
3149
3150 ;; Some files say "version 2" and others "version 2 or later".
3151 (license license:gpl2)))
3152
3153 (define-public subdl
3154 (let ((commit "4cf5789b11f0ff3f863b704b336190bf968cd471")
3155 (revision "1"))
3156 (package
3157 (name "subdl")
3158 (version (git-version "1.0.3" revision commit))
3159 (source (origin
3160 (method git-fetch)
3161 (uri (git-reference
3162 (url "https://github.com/alexanderwink/subdl.git")
3163 (commit commit)))
3164 (file-name (git-file-name name version))
3165 (sha256
3166 (base32
3167 "0kmk5ck1j49q4ww0lvas2767kwnzhkq0vdwkmjypdx5zkxz73fn8"))))
3168 (build-system trivial-build-system)
3169 (arguments
3170 `(#:modules ((guix build utils))
3171 #:builder (begin
3172 (use-modules (guix build utils))
3173 (let* ((out (assoc-ref %outputs "out"))
3174 (bin (string-append out "/bin"))
3175 (source (assoc-ref %build-inputs "source"))
3176 (python (assoc-ref %build-inputs "python")))
3177 (install-file (string-append source "/subdl") bin)
3178 (patch-shebang (string-append bin "/subdl")
3179 (list (string-append python "/bin")))))))
3180 (inputs `(("python" ,python)))
3181 (synopsis "Command-line tool for downloading subtitles from opensubtitles.org")
3182 (description "Subdl is a command-line tool for downloading subtitles from
3183 opensubtitles.org. By default, it will search for English subtitles, display
3184 the results, download the highest-rated result in the requested language and
3185 save it to the appropriate filename.")
3186 (license license:gpl3+)
3187 (home-page "https://github.com/alexanderwink/subdl"))))
3188
3189 (define-public l-smash
3190 (package
3191 (name "l-smash")
3192 (version "2.14.5")
3193 (source (origin
3194 (method git-fetch)
3195 (uri (git-reference
3196 (url "https://github.com/l-smash/l-smash.git")
3197 (commit (string-append "v" version))))
3198 (file-name (git-file-name name version))
3199 (sha256
3200 (base32
3201 "0rcq9727im6kd8da8b7kzzbzxdldvmh5nsljj9pvr4m3lj484b02"))))
3202 (build-system gnu-build-system)
3203 (arguments
3204 `(#:tests? #f ;no tests
3205 #:make-flags
3206 (list (string-append "LDFLAGS=-Wl,-L.,-rpath="
3207 (assoc-ref %outputs "out") "/lib"))
3208 #:phases
3209 (modify-phases %standard-phases
3210 ;; configure fails if it is followed by CONFIG_SHELL
3211 (replace 'configure
3212 (lambda* (#:key outputs #:allow-other-keys)
3213 (let ((out (assoc-ref outputs "out")))
3214 (invoke "./configure" (string-append "--prefix=" out)
3215 "--disable-static")))))))
3216 (native-inputs
3217 `(("which" ,which)))
3218 (home-page "https://l-smash.github.io/l-smash/")
3219 (synopsis "MP4 multiplexer and demultiplexer library")
3220 (description
3221 "L-SMASH is a cross-platform library that handles the ISO base media file
3222 format and some of its derived file formats, including MP4. It operates as a
3223 multiplexer and demultiplexer, and can mux video and audio in several formats
3224 using standalone executable files.")
3225 (license license:isc)))
3226
3227 (define-public qtfaststart
3228 (package
3229 (name "qtfaststart")
3230 (version "1.8")
3231 (source (origin
3232 (method url-fetch)
3233 (uri (pypi-uri "qtfaststart" version))
3234 (sha256
3235 (base32
3236 "0hcjfik8hhb1syqvyh5c6aillpvzal26nkjflcq1270z64aj6i5h"))))
3237 (build-system python-build-system)
3238 (arguments
3239 '(#:tests? #f)) ; no test suite
3240 (synopsis "Move QuickTime and MP4 metadata to the beginning of the file")
3241 (description "qtfaststart enables streaming and pseudo-streaming of
3242 QuickTime and MP4 files by moving metadata and offset information to the
3243 beginning of the file. It can also print some useful information about the
3244 structure of the file. This program is based on qt-faststart.c from the FFmpeg
3245 project, which is released into the public domain, as well as ISO 14496-12:2005
3246 (the official spec for MP4), which can be obtained from the ISO or found
3247 online.")
3248 (home-page "https://github.com/danielgtaylor/qtfaststart")
3249 (license license:expat)))
3250
3251 (define-public vidstab
3252 (package
3253 (name "vidstab")
3254 (version "1.1.0")
3255 (source (origin
3256 (method git-fetch)
3257 (uri (git-reference
3258 (url "https://github.com/georgmartius/vid.stab.git")
3259 (commit (string-append "v" version))))
3260 (file-name (git-file-name name version))
3261 (sha256
3262 (base32
3263 "0a3frpm2kdbx7vszhg64p3alisag73bcspl7fp3a2f1kgq7rbh38"))))
3264 (build-system cmake-build-system)
3265 (arguments
3266 '(#:tests? #f)) ; tests are not run as part of standard build process
3267 (home-page "http://public.hronopik.de/vid.stab/")
3268 (synopsis "Video stabilization library")
3269 (description "Vidstab is a video stabilization library which can be used
3270 with FFmpeg. A video acquired using a hand-held camera or a camera mounted on a
3271 vehicle typically suffers from undesirable shakes and jitters. Activities such
3272 as surfing, skiing, riding and walking while shooting videos are especially
3273 prone to erratic camera shakes. Vidstab targets these video contents to help
3274 create smoother and stable videos.")
3275 (license license:gpl2+)))
3276
3277 (define-public libopenshot
3278 (package
3279 (name "libopenshot")
3280 (version "0.2.2")
3281 (source (origin
3282 (method git-fetch)
3283 (uri (git-reference
3284 (url "https://github.com/OpenShot/libopenshot")
3285 (commit (string-append "v" version))))
3286 (file-name (git-file-name name version))
3287 (sha256
3288 (base32
3289 "1x4kv05pdq1pglb6y056aa7llc6iyibyhzg93k7zwj0q08cp5ixd"))
3290 (modules '((guix build utils)))
3291 (snippet '(begin
3292 ;; Allow overriding of the python installation dir
3293 (substitute* "src/bindings/python/CMakeLists.txt"
3294 (("(SET\\(PYTHON_MODULE_PATH.*)\\)" _ set)
3295 (string-append set " CACHE PATH "
3296 "\"Python bindings directory\")")))
3297 (delete-file-recursively "thirdparty")
3298 #t))
3299 (patches (search-patches "libopenshot-fixup-tests.patch"
3300 "libopenshot-tests-with-system-libs.patch"))))
3301 (build-system cmake-build-system)
3302 (native-inputs
3303 `(("pkg-config" ,pkg-config)
3304 ("python" ,python)
3305 ("swig" ,swig)
3306 ("unittest++" ,unittest-cpp)))
3307 (propagated-inputs ;all referenced in installed headers
3308 `(("cppzmq" ,cppzmq)
3309 ("ffmpeg" ,ffmpeg)
3310 ("imagemagick" ,imagemagick)
3311 ("jsoncpp" ,jsoncpp)
3312 ("libopenshot-audio" ,libopenshot-audio)
3313 ("qtbase" ,qtbase)
3314 ("qtmultimedia" ,qtmultimedia)
3315 ("zeromq" ,zeromq)))
3316 (arguments
3317 `(#:configure-flags
3318 (list (string-append "-DPYTHON_MODULE_PATH:PATH=" %output "/lib/python"
3319 ,(version-major+minor (package-version python))
3320 "/site-packages")
3321 "-DUSE_SYSTEM_JSONCPP:BOOL=ON")
3322 #:phases
3323 (modify-phases %standard-phases
3324 (add-before 'configure 'set-vars
3325 (lambda* (#:key inputs #:allow-other-keys)
3326 (setenv "LIBOPENSHOT_AUDIO_DIR"
3327 (assoc-ref inputs "libopenshot-audio"))
3328 (setenv "ZMQDIR"
3329 (assoc-ref inputs "zeromq"))
3330 (setenv "UNITTEST_DIR"
3331 (string-append (assoc-ref inputs "unittest++")
3332 "/include/UnitTest++"))
3333 #t)))))
3334 (home-page "https://openshot.org")
3335 (synopsis "Video-editing, animation, and playback library")
3336 (description "OpenShot Library (libopenshot) is a powerful C++ video
3337 editing library with a multi-threaded and feature rich video editing
3338 API. It includes bindings for Python, Ruby, and other languages.")
3339 (license license:lgpl3+)))
3340
3341 (define-public openshot
3342 (package
3343 (name "openshot")
3344 (version "2.4.3")
3345 (source (origin
3346 (method git-fetch)
3347 (uri (git-reference
3348 (url "https://github.com/OpenShot/openshot-qt")
3349 (commit (string-append "v" version))))
3350 (file-name (git-file-name name version))
3351 (sha256
3352 (base32
3353 "1qdw1mli4y9qhrnllnkaf6ydgw5vfvdb90chs4i679k0x0jyb9a2"))))
3354 (build-system python-build-system)
3355 (inputs
3356 `(("ffmpeg" ,ffmpeg)
3357 ("libopenshot" ,libopenshot)
3358 ("python" ,python)
3359 ("python-pyqt" ,python-pyqt)
3360 ("python-pyzmq" ,python-pyzmq)
3361 ("python-requests" ,python-requests)
3362 ("qtsvg" ,qtsvg)))
3363 (arguments
3364 `(#:tests? #f ;no tests
3365 #:phases (modify-phases %standard-phases
3366 (delete 'build) ;install phase does all the work
3367 (add-before 'install 'set-tmp-home
3368 (lambda _
3369 ;; src/classes/info.py "needs" to create several
3370 ;; directories in $HOME when loaded during build
3371 (setenv "HOME" "/tmp")
3372 #t))
3373 (add-after 'install 'wrap-program
3374 (lambda* (#:key inputs outputs #:allow-other-keys)
3375 (wrap-program (string-append (assoc-ref outputs "out")
3376 "/bin/openshot-qt")
3377 `("QT_PLUGIN_PATH" prefix
3378 ,(list (string-append (assoc-ref inputs "qtsvg")
3379 "/lib/qt5/plugins/")))))))))
3380 (home-page "https://openshot.org")
3381 (synopsis "Video editor")
3382 (description "OpenShot takes your videos, photos, and music files and
3383 helps you create the film you have always dreamed of. Easily add sub-titles,
3384 transitions, and effects and then export your film to many common formats.")
3385 (license license:gpl3+)))
3386
3387 (define-public dav1d
3388 (package
3389 (name "dav1d")
3390 (version "0.2.0")
3391 (source
3392 (origin
3393 (method url-fetch)
3394 (uri (list ;; The canonical download site
3395 (string-append "https://downloads.videolan.org/pub/videolan/"
3396 "dav1d/" version "/dav1d-" version ".tar.xz")
3397
3398 ;; Auto-generated tarballs from the Git repo?
3399 (string-append "https://code.videolan.org/videolan/dav1d/-/"
3400 "archive/" version "/dav1d-" version ".tar.bz2")))
3401 (sha256
3402 (base32
3403 "0q0dbbl91syjnkygz268gh4b7mdcgl6hldj300a4cbqidsadpl5p"))))
3404 (build-system meson-build-system)
3405 (native-inputs `(("nasm" ,nasm)))
3406 (home-page "https://code.videolan.org/videolan/dav1d")
3407 (synopsis "AV1 decoder")
3408 (description "dav1d is a new AV1 cross-platform decoder, and focused on
3409 speed and correctness.")
3410 (license license:bsd-2)))
3411
3412 (define-public wlstream
3413 (let ((commit "182076a94562b128c3a97ecc53cc68905ea86838")
3414 (revision "1"))
3415 (package
3416 (name "wlstream")
3417 (version (git-version "0.0" revision commit))
3418 (source
3419 (origin
3420 (method git-fetch)
3421 (uri (git-reference
3422 (url "https://github.com/atomnuker/wlstream.git")
3423 (commit commit)))
3424 (file-name (git-file-name name version))
3425 (sha256
3426 (base32
3427 "01qbcgfl3g9kfwn1jf1z9pdj3bvf5lmg71d1vwkcllc2az24bjqp"))))
3428 (build-system meson-build-system)
3429 (native-inputs `(("libdrm" ,libdrm)
3430 ("pkg-config" ,pkg-config)))
3431 (inputs `(("ffmpeg" ,ffmpeg)
3432 ("pulseaudio" ,pulseaudio)
3433 ("wayland" ,wayland)
3434 ("wayland-protocols" ,wayland-protocols)))
3435 (home-page "https://github.com/atomnuker/wlstream")
3436 (synopsis "Screen capture tool for Wayland sessions")
3437 (description "Wlstream is a screen capture tool for recording audio and
3438 video from a Wayland session.")
3439 (license license:lgpl2.1+))))