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 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2015 Andy Patterson <ajpatter@uwaterloo.ca>
8 ;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2015, 2016, 2017, 2018 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 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 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 Rutger Helling <rhelling@mykolab.com>
25 ;;; Copyright © 2018 Roel Janssen <roel@gnu.org>
26 ;;; Copyright © 2018 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>
33 ;;; This file is part of GNU Guix.
35 ;;; GNU Guix is free software; you can redistribute it and/or modify it
36 ;;; under the terms of the GNU General Public License as published by
37 ;;; the Free Software Foundation; either version 3 of the License, or (at
38 ;;; your option) any later version.
40 ;;; GNU Guix is distributed in the hope that it will be useful, but
41 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
42 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
43 ;;; GNU General Public License for more details.
45 ;;; You should have received a copy of the GNU General Public License
46 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
48 (define-module (gnu packages video)
49 #:use-module (ice-9 match)
50 #:use-module (srfi srfi-1)
51 #:use-module (srfi srfi-26)
52 #:use-module ((guix licenses) #:prefix license:)
53 #:use-module (guix utils)
54 #:use-module (guix packages)
55 #:use-module (guix download)
56 #:use-module (guix git-download)
57 #:use-module (guix svn-download)
58 #:use-module (guix build-system cmake)
59 #:use-module (guix build-system gnu)
60 #:use-module (guix build-system glib-or-gtk)
61 #:use-module (guix build-system meson)
62 #:use-module (guix build-system perl)
63 #:use-module (guix build-system python)
64 #:use-module (guix build-system waf)
65 #:use-module (guix build-system trivial)
66 #:use-module (gnu packages)
67 #:use-module (gnu packages algebra)
68 #:use-module (gnu packages audio)
69 #:use-module (gnu packages autotools)
70 #:use-module (gnu packages avahi)
71 #:use-module (gnu packages backup)
72 #:use-module (gnu packages base)
73 #:use-module (gnu packages bison)
74 #:use-module (gnu packages boost)
75 #:use-module (gnu packages cdrom)
76 #:use-module (gnu packages check)
77 #:use-module (gnu packages cmake)
78 #:use-module (gnu packages compression)
79 #:use-module (gnu packages cpp)
80 #:use-module (gnu packages curl)
81 #:use-module (gnu packages databases)
82 #:use-module (gnu packages dejagnu)
83 #:use-module (gnu packages docbook)
84 #:use-module (gnu packages documentation)
85 #:use-module (gnu packages elf)
86 #:use-module (gnu packages file)
87 #:use-module (gnu packages flex)
88 #:use-module (gnu packages fontutils)
89 #:use-module (gnu packages freedesktop)
90 #:use-module (gnu packages fribidi)
91 #:use-module (gnu packages gettext)
92 #:use-module (gnu packages ghostscript)
93 #:use-module (gnu packages gl)
94 #:use-module (gnu packages glib)
95 #:use-module (gnu packages guile)
96 #:use-module (gnu packages gnome)
97 #:use-module (gnu packages gnupg)
98 #:use-module (gnu packages gstreamer)
99 #:use-module (gnu packages gtk)
100 #:use-module (gnu packages image)
101 #:use-module (gnu packages imagemagick)
102 #:use-module (gnu packages iso-codes)
103 #:use-module (gnu packages libidn)
104 #:use-module (gnu packages libreoffice)
105 #:use-module (gnu packages linux)
106 #:use-module (gnu packages lua)
107 #:use-module (gnu packages m4)
108 #:use-module (gnu packages man)
109 #:use-module (gnu packages mp3)
110 #:use-module (gnu packages ncurses)
111 #:use-module (gnu packages ocr)
112 #:use-module (gnu packages perl)
113 #:use-module (gnu packages pkg-config)
114 #:use-module (gnu packages popt)
115 #:use-module (gnu packages pulseaudio)
116 #:use-module (gnu packages python)
117 #:use-module (gnu packages python-crypto)
118 #:use-module (gnu packages python-web)
119 #:use-module (gnu packages qt)
120 #:use-module (gnu packages rdesktop)
121 #:use-module (gnu packages ruby)
122 #:use-module (gnu packages samba)
123 #:use-module (gnu packages sdl)
124 #:use-module (gnu packages serialization)
125 #:use-module (gnu packages shells)
126 #:use-module (gnu packages ssh)
127 #:use-module (gnu packages texinfo)
128 #:use-module (gnu packages textutils)
129 #:use-module (gnu packages tls)
130 #:use-module (gnu packages time)
131 #:use-module (gnu packages upnp)
132 #:use-module (gnu packages version-control)
133 #:use-module (gnu packages vulkan)
134 #:use-module (gnu packages web)
135 #:use-module (gnu packages webkit)
136 #:use-module (gnu packages wxwidgets)
137 #:use-module (gnu packages xdisorg)
138 #:use-module (gnu packages xiph)
139 #:use-module (gnu packages xml)
140 #:use-module (gnu packages xorg)
141 #:use-module (gnu packages assembly))
149 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
150 version "/" name "-" version ".tar.gz"))
153 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
154 (build-system gnu-build-system)
156 `(("makeinfo" ,texinfo)))
158 `(("ncurses" ,ncurses)))
161 (modify-phases %standard-phases
163 (lambda* (#:key build inputs outputs #:allow-other-keys)
164 ;; This old `configure' script doesn't support
165 ;; variables passed as arguments.
166 (let ((out (assoc-ref outputs "out"))
167 (ncurses (assoc-ref inputs "ncurses")))
168 (setenv "CONFIG_SHELL" (which "bash"))
169 (invoke "./configure"
170 (string-append "--prefix=" out)
171 (string-append "--build=" build)
172 ;; The ancient config.guess is unable to
173 ;; guess the host triplet on mips64el.
174 ,@(if (string=? "mips64el-linux"
176 '("--host=mips64el-unknown-linux-gnu")
178 ;; The same is also true with aarch64.
179 ,@(if (string=? "aarch64-linux"
181 '("--host=aarch64-unknown-linux-gnu")
183 (string-append "--with-ncurses="
185 (home-page "http://aa-project.sourceforge.net/aalib/")
186 (synopsis "ASCII-art library")
188 "AA-lib is a low level gfx library which does not require graphics device.
189 In fact, there is no graphical output possible. AA-lib replaces those
190 old-fashioned output methods with powerful ascii-art renderer.")
191 (license license:lgpl2.0+)))
193 (define-public liba52
200 ;; A mirror://sourceforge URI doesn't work, presumably
201 ;; because the SourceForge project is misconfigured.
202 "http://liba52.sourceforge.net/files/a52dec-" version
206 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
207 (patches (search-patches "liba52-enable-pic.patch"
208 "liba52-set-soname.patch"
209 "liba52-use-mtune-not-mcpu.patch"
210 "liba52-link-with-libm.patch"))))
211 (build-system gnu-build-system)
212 ;; XXX We need to run ./bootstrap because of the build system fixes above.
214 `(("autoconf" ,autoconf)
215 ("automake" ,automake)
216 ("libtool" ,libtool)))
217 (arguments `(#:configure-flags '("--enable-shared")
219 (modify-phases %standard-phases
220 ;; XXX We need to run ./bootstrap because of the build
221 ;; system fixes above.
223 (lambda _ (invoke "sh" "bootstrap"))))))
224 (home-page "http://liba52.sourceforge.net/")
225 (synopsis "ATSC A/52 stream decoder")
226 (description "liba52 is a library for decoding ATSC A/52 streams. The
227 A/52 standard is used in a variety of applications, including digital
228 television and DVD. It is also known as AC-3.")
229 (license license:gpl2+)))
231 (define-public libmpeg2
237 ;; A mirror://sourceforge URI doesn't work, presumably
238 ;; because the SourceForge project is misconfigured.
239 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
240 name "-" version ".tar.gz"))
243 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
251 (build-system gnu-build-system)
252 (home-page "http://libmpeg2.sourceforge.net/")
253 (synopsis "MPEG1 and MPEG2 video decoder library")
255 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
256 (license license:gpl2+)))
258 (define-public libx264
261 (version "20180810-2245")
264 (uri (string-append "https://download.videolan.org/pub/x264/snapshots/"
265 "x264-snapshot-" version "-stable.tar.bz2"))
268 "0f25f39imas9pcqm7lnaa0shhjmf42hdx7jxzcnvxc7qsb7lh1bv"))))
269 (build-system gnu-build-system)
271 `(("pkg-config" ,pkg-config)
273 ;; TODO: Add gpac input
275 `(#:tests? #f ;no check target
276 #:configure-flags '("--enable-shared"
277 ;; Don't build the command-line program. If we
278 ;; want it later, we should do so in a different
279 ;; package to avoid a circular dependency (the x264
280 ;; program depends on ffmpeg and ffmpeg depends on
284 ;; On MIPS, we must pass "--disable-asm" or else
285 ;; configure fails after printing: "You specified a
286 ;; pre-MSA CPU in your CFLAGS. If you really want
287 ;; to run on such a CPU, configure with
289 ,@(if (string-prefix? "mips"
290 (or (%current-target-system)
294 (home-page "https://www.videolan.org/developers/x264.html")
295 (synopsis "H.264 video coding library")
296 (description "libx264 is an advanced encoding library for creating
297 H.264 (MPEG-4 AVC) video streams.")
298 (license (list license:gpl2+ ;most files
299 license:isc ;common/x86/x86inc.asm
300 license:lgpl2.1+ ;extras/getopt.c
301 license:bsd-3 ;extras/inttypes.h
302 (license:non-copyleft ;extras/cl*.h
304 "See extras/cl.h in the distribution.")))))
306 (define-public mkvtoolnix
313 (uri (string-append "https://mkvtoolnix.download/sources/"
314 name "-" version ".tar.xz"))
317 "0hknnnnx9661igm1r73dc7aqxnnrl5a8yvyvr1nhd9ymn2klwpl5"))
318 (modules '((guix build utils)))
320 ;; Delete bundled libraries.
321 (for-each delete-file-recursively
328 (build-system gnu-build-system)
335 ("libmatroska" ,libmatroska)
337 ("libvorbis" ,libvorbis)
344 `(("docbook-xsl" ,docbook-xsl)
345 ("gettext" ,gettext-minimal)
346 ("googletest" ,googletest)
348 ("nlohmann-json-cpp" ,nlohmann-json-cpp)
350 ("pkg-config" ,pkg-config)
355 (list (string-append "--with-boost="
356 (assoc-ref %build-inputs "boost"))
357 (string-append "--with-docbook-xsl-root="
358 (assoc-ref %build-inputs "docbook-xsl")
359 "/xml/xsl/docbook-xsl-"
360 ,(package-version docbook-xsl))
361 (string-append "--with-extra-includes="
362 (assoc-ref %build-inputs "nlohmann-json-cpp")
363 "/include/nlohmann"))
365 (modify-phases %standard-phases
366 (add-before 'configure 'add-googletest
369 (string-append (assoc-ref %build-inputs "googletest")
370 "/include/gtest") "lib/gtest")
374 (let ((-j (list "-j" (number->string (parallel-job-count)))))
375 (apply invoke "rake" -j))))
378 (invoke "rake" "tests/unit")))
381 (invoke "rake" "install"))))))
382 (home-page "https://mkvtoolnix.download")
383 (synopsis "Tools to create, alter and inspect Matroska files")
385 "MKVToolNix provides tools for getting information about Matroska files
386 (@code{mkvinfo}), extracting tracks/data from Matroska files (@code{mkvextract})
387 and creating Matroska files from other media files (@code{mkvmerge}).")
388 (license license:gpl2)))
397 (uri (string-append "https://download.videolan.org/videolan/x265/"
398 "x265_" version ".tar.gz"))
401 "0qx8mavwdzdpkkby7n29i9av7zsnklavacwfz537mf62q2pzjnbf"))
402 (patches (search-patches "x265-fix-ppc64le-build.patch"
403 "x265-arm-asm-primitives.patch"))
404 (modules '((guix build utils)))
406 (delete-file-recursively "source/compat/getopt")
408 (build-system cmake-build-system)
410 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
411 ;; Currently the source code doesn't check for aarch64.
412 ,@(if (any (cute string-prefix? <> (or (%current-system)
413 (%current-target-system)))
414 '("armhf" "aarch64"))
415 '(#:configure-flags '("-DENABLE_PIC=TRUE"))
418 (modify-phases %standard-phases
419 (add-before 'configure 'prepare-build
421 (delete-file-recursively "build")
424 (home-page "http://x265.org/")
425 (synopsis "Library for encoding h.265/HEVC video streams")
426 (description "x265 is a H.265 / HEVC video encoder application library,
427 designed to encode video or images into an H.265 / HEVC encoded bitstream.")
428 (license license:gpl2+)))
430 (define-public libass
437 "https://github.com/libass/libass/releases/download/"
438 version "/libass-" version ".tar.xz"))
441 "18iqznl4mabhj9ywfsz4kwvbsplcv1jjxq50nxssvbj8my1267w8"))))
442 (build-system gnu-build-system)
444 `(("pkg-config" ,pkg-config)
447 `(("freetype" ,freetype)
449 ("fontconfig" ,fontconfig)
450 ("harfbuzz" ,harfbuzz)
452 (home-page "https://github.com/libass/libass")
453 (synopsis "Subtitle rendering library for the ASS/SSA format")
454 (description "libass is a subtitle rendering library for the
455 ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
456 (license license:isc)))
458 (define-public libcaca
461 (version "0.99.beta19")
464 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
468 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))))
469 (build-system gnu-build-system)
470 (native-inputs `(("pkg-config" ,pkg-config)))
472 `(("freeglut" ,freeglut)
479 (home-page "http://caca.zoy.org/wiki/libcaca")
480 (synopsis "Colour ASCII-art library")
481 (description "libcaca is a graphics library that outputs text instead of
482 pixels, so that it can work on older video cards or text terminals. It
483 supports Unicode, 2048 colors, dithering of color images, and advanced text
485 (license (license:fsf-free "file://COPYING")))) ;WTFPL version 2
487 (define-public libdca
494 "https://download.videolan.org/pub/videolan/libdca/"
495 version "/libdca-" version ".tar.bz2"))
498 "0h0zvcn97i9kyljdpifzi8in9xnw31fx3b3ggj96p8h0l2d8mycq"))))
499 (build-system gnu-build-system)
500 (home-page "https://www.videolan.org/developers/libdca.html")
501 (synopsis "DTS Coherent Acoustics decoder")
502 (description "libdca is a library for decoding DTS Coherent Acoustics
504 (license license:gpl2+)))
513 "mirror://sourceforge/" name "/" name "/"
514 version "/" name "-" version ".tar.gz"))
517 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
518 (build-system gnu-build-system)
519 (native-inputs `(("pkg-config" ,pkg-config)))
520 (inputs `(("libxv" ,libxv)))
521 (home-page "http://libdv.sourceforge.net/")
522 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
523 (description "The Quasar DV codec (libdv) is a software codec for DV
524 video, the encoding format used by most digital camcorders, typically those
525 that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
526 developed according to the official standards for DV video: IEC 61834 and
528 (license license:lgpl2.1+)))
530 (define-public libmatroska
537 (uri (string-append "https://dl.matroska.org/downloads/"
538 name "/" name "-" version ".tar.xz"))
541 "1j4mjzx6mjzfjf9hz8g4w84krf5jccmr5cyynll0j1vwv3aiv9iq"))))
542 (build-system cmake-build-system)
544 `(("libebml" ,libebml)))
547 (list "-DBUILD_SHARED_LIBS=YES")
548 #:tests? #f)) ; no test suite
549 (home-page "https://www.matroska.org")
550 (synopsis "C++ library to parse Matroska files (.mkv and .mka)")
552 "Matroska aims to become the standard of multimedia container formats.
553 It is based on @dfn{EBML} (Extensible Binary Meta Language), a binary derivative
554 of XML. EBML enables the Matroska Development Team to gain significant
555 advantages in terms of future format extensibility, without breaking file
556 support in old parsers.
557 libebml is a C++ library to read and write EBML files.")
558 (license license:lgpl2.1)))
568 ;; Newer releases are only available on GitHub.
569 (string-append "https://github.com/01org/libva/releases/download/"
570 version "/libva-" version ".tar.bz2")
571 ;; Keep the old URL around for compatibility.
572 (string-append "https://www.freedesktop.org/software/vaapi/releases/"
573 "libva/libva-" version "/libva-" version ".tar.bz2")))
575 (base32 "1wjfrs261fp9wkhgpmrlz5smnhxrmsk31way646x6i2mg16a0v3g"))))
576 (build-system gnu-build-system)
578 `(("pkg-config" ,pkg-config)))
583 ("libxfixes" ,libxfixes)
585 ("wayland" ,wayland)))
588 (modify-phases %standard-phases
590 'build 'fix-dlopen-paths
591 (lambda* (#:key outputs #:allow-other-keys)
592 (let ((out (assoc-ref outputs "out")))
593 (substitute* "va/drm/va_drm_auth_x11.c"
594 (("\"libva-x11\\.so\\.%d\"")
595 (string-append "\"" out "/lib/libva-x11.so.%d\"")))
597 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
598 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
600 (list (string-append "--with-drivers-path="
601 (assoc-ref %build-inputs "mesa") "/lib/dri"))
602 ;; However, we can't write to mesa's store directory, so override the
603 ;; following make variable to install the dummy driver to libva's
604 ;; $prefix/lib/dri directory.
606 (list (string-append "dummy_drv_video_ladir="
607 (assoc-ref %outputs "out") "/lib/dri"))))
608 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
609 (synopsis "Video acceleration library")
610 (description "The main motivation for VA-API (Video Acceleration API) is
611 to enable hardware accelerated video decode/encode at various
612 entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
613 standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
614 (license license:expat)))
616 (define-public ffmpeg
622 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
626 "15rgzcmdccy4flajs63gkz4n3k24wkkg50r13l1r83lrxg4hqp59"))))
627 (build-system gnu-build-system)
629 `(("fontconfig" ,fontconfig)
630 ("freetype" ,freetype)
631 ("frei0r-plugins" ,frei0r-plugins)
637 ("libbluray" ,libbluray)
639 ("libcdio-paranoia" ,libcdio-paranoia)
640 ("libtheora" ,libtheora)
642 ("libvdpau" ,libvdpau)
643 ("libvorbis" ,libvorbis)
649 ("pulseaudio" ,pulseaudio)
661 ("pkg-config" ,pkg-config)
663 ("python" ,python-2) ; scripts use interpreter python2
667 `(#:test-target "fate"
669 ;; possible additional inputs:
670 ;; --enable-avisynth enable reading of AviSynth script
672 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
673 ;; --enable-libcelt enable CELT decoding via libcelt [no]
674 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
675 ;; and libraw1394 [no]
676 ;; --enable-libfaac enable AAC encoding via libfaac [no]
677 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
678 ;; --enable-libflite enable flite (voice synthesis) support via
680 ;; --enable-libgme enable Game Music Emu via libgme [no]
681 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
682 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
683 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
684 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
685 ;; --enable-libnut enable NUT (de)muxing via libnut,
686 ;; native (de)muxer exists [no]
687 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
688 ;; libopencore-amrnb [no]
689 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
690 ;; libopencore-amrwb [no]
691 ;; --enable-libopencv enable video filtering via libopencv [no]
692 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
694 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
695 ;; --enable-libschroedinger enable Dirac de/encoding via
696 ;; libschroedinger [no]
697 ;; --enable-libshine enable fixed-point MP3 encoding via
699 ;; --enable-libssh enable SFTP protocol via libssh [no]
700 ;; (libssh2 does not work)
701 ;; --enable-libstagefright-h264 enable H.264 decoding via
702 ;; libstagefright [no]
703 ;; --enable-libutvideo enable Ut Video encoding and decoding via
705 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
706 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
707 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
708 ;; libvo-amrwbenc [no]
709 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
710 ;; --enable-libxavs enable AVS encoding via xavs [no]
711 ;; --enable-libzmq enable message passing via libzmq [no]
712 ;; --enable-libzvbi enable teletext support via libzvbi [no]
713 ;; --enable-opencl enable OpenCL code
714 '("--enable-avresample"
715 "--enable-gpl" ; enable optional gpl licensed parts
718 "--enable-fontconfig"
725 "--enable-libfreetype"
726 "--enable-libmp3lame"
732 "--enable-libtwolame"
733 "--enable-libvidstab"
742 "--enable-runtime-cpudetect"
744 ;; The HTML pages take 7.2 MiB
745 "--disable-htmlpages"
747 ;; The static libraries are 23 MiB
750 ;; Runtime cpu detection is not implemented on
751 ;; MIPS, so we disable some features.
754 "--disable-mipsdspr2"
757 (modify-phases %standard-phases
760 ;; configure does not work followed by "SHELL=..." and
761 ;; "CONFIG_SHELL=..."; set environment variables instead
762 (lambda* (#:key outputs configure-flags #:allow-other-keys)
763 (let ((out (assoc-ref outputs "out")))
764 (substitute* "configure"
765 (("#! /bin/sh") (string-append "#!" (which "sh"))))
766 (setenv "SHELL" (which "bash"))
767 (setenv "CONFIG_SHELL" (which "bash"))
770 (string-append "--prefix=" out)
771 ;; Add $libdir to the RUNPATH of all the binaries.
772 (string-append "--extra-ldflags=-Wl,-rpath="
776 'check 'set-ld-library-path
778 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
780 (let* ((dso (find-files "." "\\.so$"))
781 (path (string-join (map dirname dso) ":")))
782 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
783 (setenv "LD_LIBRARY_PATH" path)
785 (home-page "https://www.ffmpeg.org/")
786 (synopsis "Audio and video framework")
787 (description "FFmpeg is a complete, cross-platform solution to record,
788 convert and stream audio and video. It includes the libavcodec
789 audio/video codec library.")
790 (license license:gpl2+)))
792 (define-public ffmpeg-3.4
798 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
802 "1iizgnhjbhar9y1ykqlj1czqanlv24knkfq5vvfnppv5x00pcvrq"))))))
804 (define-public ffmpeg-2.8
810 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
814 "065xbvnfmxfbfrc14cavpqyd2slil99vcjksw4ndb7w8zdh0wp3v"))))
816 (substitute-keyword-arguments (package-arguments ffmpeg)
817 ((#:configure-flags flags)
819 (if (string=? flag "--disable-mipsdsp")
820 "--disable-mipsdspr1"
824 (define-public ffmpegthumbnailer
826 (name "ffmpegthumbnailer")
830 (uri (string-append "https://github.com/dirkvdb/"
831 name "/archive/" version ".tar.gz"))
834 "13qs4iwd4l3iiim30s5051n80z0vgsnikym8vsn321cnm9algiwb"))))
835 (build-system cmake-build-system)
837 `(("pkg-config" ,pkg-config)))
840 ("libjpeg-turbo" ,libjpeg-turbo)
844 `(#:configure-flags (list "-DENABLE_GIO=ON" "-DENABLE_THUMBNAILER=ON")))
845 (home-page "https://github.com/dirkvdb/ffmpegthumbnailer")
846 (synopsis "Create thumbnails from video files")
847 (description "FFmpegthumbnailer is a lightweight video thumbnailer that
848 can be used by file managers to create thumbnails for your video files. The
849 thumbnailer uses ffmpeg to decode frames from the video files, so supported
850 videoformats depend on the configuration flags of ffmpeg.")
851 (license license:gpl2+)))
853 ;; Fix build with newer x264.
854 (define %vlc-libx264-compat.patch
857 (uri (string-append "https://git.videolan.org/?p=vlc.git;a=patch;h="
858 "a8953ba707cca1f2de372ca24513296bcfcdaaa8"))
859 (file-name "vlc-libx264-compat.patch")
862 "04igckbdp3sbp8vh0ihmhcf3yjyyk9r3cd5dm9mn9j6vipi1dg3g"))))
871 "https://download.videolan.org/pub/videolan/vlc/"
872 (car (string-split version #\-))
873 "/vlc-" version ".tar.xz"))
874 (patches (list %vlc-libx264-compat.patch))
877 "17jsq0zqpqyxw4ckvjba0hf6zk8ywc4wf8sy3z03hh3ij0vxpwq1"))))
878 (build-system gnu-build-system)
882 ("gettext" ,gettext-minimal)
883 ("git" ,git) ; needed for a test
884 ("pkg-config" ,pkg-config)))
885 ;; FIXME: Add optional inputs once available.
887 `(("alsa-lib" ,alsa-lib)
893 ("fontconfig" ,fontconfig)
894 ("freetype" ,freetype)
898 ("libarchive" ,libarchive)
900 ("libavc1394" ,libavc1394)
901 ("libbluray" ,libbluray)
905 ("libdvbpsi" ,libdvbpsi)
906 ("libdvdnav" ,libdvdnav)
907 ("libdvdread" ,libdvdread)
909 ("libgcrypt" ,libgcrypt)
913 ("libmatroska" ,libmatroska)
914 ("libmodplug" ,libmodplug)
915 ("libmpeg2" ,libmpeg2)
918 ("libraw1394" ,libraw1394)
920 ("libsamplerate" ,libsamplerate)
921 ("libsecret" ,libsecret)
925 ("libvdpau" ,libvdpau)
926 ("libvorbis" ,libvorbis)
928 ("libtheora" ,libtheora)
932 ("libxinerama" ,libxinerama)
935 ("livemedia-utils" ,livemedia-utils)
940 ("pulseaudio" ,pulseaudio)
941 ("python" ,python-wrapper)
944 ("qtx11extras" ,qtx11extras)
947 ("sdl-image" ,sdl-image)
949 ("speexdsp" ,speexdsp)
954 ("wayland-protocols" ,wayland-protocols)
956 ("xcb-util-keysyms" ,xcb-util-keysyms)))
959 `("CXXFLAGS=-std=gnu++11"
961 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
962 (assoc-ref %build-inputs "ffmpeg")
963 "/lib")) ;needed for the tests
966 (modify-phases %standard-phases
967 (add-after 'unpack 'patch-source
968 (lambda* (#:key inputs #:allow-other-keys)
969 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
970 (substitute* "configure"
971 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
972 (string-append "LIVE555_PREFIX=" livemedia-utils)))
973 ;; Some of the tests require using the display to test out VLC,
974 ;; which fails in our sandboxed build system
975 (substitute* "test/run_vlc.sh"
976 (("./vlc --ignore-config") "echo"))
978 ;; modules/text_renderer/freetype/text_layout.c uses a
979 ;; now-deprecated interface 'fribidi_get_par_embedding_levels'
980 ;; from fribidi.h, so for now we enable the use of deprecated
981 ;; fribidi interfaces from this file.
982 ;; FIXME: Try removing this for vlc >= 3.0.3.
983 (substitute* "modules/text_renderer/freetype/text_layout.c"
984 (("# define FRIBIDI_NO_DEPRECATED 1") ""))
986 ;; Fix build against Qt 5.11.
987 (substitute* "modules/gui/qt/actions_manager.cpp"
988 (("#include <vlc_keys.h>") "#include <vlc_keys.h>
989 #include <QAction>"))
990 (substitute* "modules/gui/qt/components/simple_preferences.cpp"
991 (("#include <QFont>") "#include <QFont>
992 #include <QButtonGroup>"))
994 (add-after 'strip 'regenerate-plugin-cache
995 (lambda* (#:key outputs #:allow-other-keys)
996 ;; The 'install-exec-hook' rule in the top-level Makefile.am
997 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
998 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
999 ;; it references. Thus, we first reset the timestamps of all
1000 ;; these files, and then regenerate the cache such that the
1001 ;; mtimes it includes are always zero instead of being dependent
1002 ;; on the build time.
1003 (let* ((out (assoc-ref outputs "out"))
1004 (pkglibdir (string-append out "/lib/vlc"))
1005 (plugindir (string-append pkglibdir "/plugins"))
1006 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
1007 ;; TODO: Factorize 'reset-timestamps'.
1008 (for-each (lambda (file)
1009 (let ((s (lstat file)))
1010 (unless (eq? (stat:type s) 'symlink)
1012 (find-files plugindir))
1013 (invoke cachegen plugindir))))
1014 (add-after 'install 'wrap-executable
1015 (lambda* (#:key outputs #:allow-other-keys)
1016 (let ((out (assoc-ref outputs "out"))
1017 (plugin-path (getenv "QT_PLUGIN_PATH")))
1018 (wrap-program (string-append out "/bin/vlc")
1019 `("QT_PLUGIN_PATH" ":" prefix (,plugin-path))))
1021 (home-page "https://www.videolan.org/")
1022 (synopsis "Audio and video framework")
1023 (description "VLC is a cross-platform multimedia player and framework
1024 that plays most multimedia files as well as DVD, Audio CD, VCD, and various
1025 treaming protocols.")
1026 (license license:gpl2+)))
1028 (define-public mplayer
1035 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
1039 "0hwqn04bdknb2ic88xd75smffxx63scvz0zvwvjb56nqj9n89l1s"))))
1040 (build-system gnu-build-system)
1041 ;; FIXME: Add additional inputs once available.
1043 `(("pkg-config" ,pkg-config)))
1045 `(("alsa-lib" ,alsa-lib)
1046 ("cdparanoia" ,cdparanoia)
1047 ("ffmpeg" ,ffmpeg-3.4)
1048 ("fontconfig" ,fontconfig)
1049 ("freetype" ,freetype)
1050 ;; ("giflib" ,giflib) ; uses QuantizeBuffer, requires version >= 5
1053 ("libdvdcss" ,libdvdcss)
1054 ("libdvdnav" ,libdvdnav)
1055 ("libjpeg" ,libjpeg)
1056 ("libmpeg2" ,libmpeg2)
1057 ("libmpg123" ,mpg123) ; audio codec for MP3
1059 ("libtheora" ,libtheora)
1060 ("libvdpau" ,libvdpau)
1061 ("libvorbis" ,libvorbis)
1063 ("libx264" ,libx264)
1064 ("libxinerama" ,libxinerama)
1066 ("libxxf86dga" ,libxxf86dga)
1070 ("pulseaudio" ,pulseaudio)
1071 ("python" ,python-wrapper)
1077 `(#:tests? #f ; no test target
1079 (modify-phases %standard-phases
1081 ;; configure does not work followed by "SHELL=..." and
1082 ;; "CONFIG_SHELL=..."; set environment variables instead
1083 (lambda* (#:key inputs outputs #:allow-other-keys)
1084 (let ((out (assoc-ref outputs "out"))
1085 (libx11 (assoc-ref inputs "libx11")))
1086 (substitute* "configure"
1087 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1088 (setenv "SHELL" (which "bash"))
1089 (setenv "CONFIG_SHELL" (which "bash"))
1090 (invoke "./configure"
1091 (string-append "--extra-cflags=-I"
1092 libx11 "/include") ; to detect libx11
1093 "--disable-ffmpeg_a" ; disables bundled ffmpeg
1094 (string-append "--prefix=" out)
1095 ;; Enable runtime cpu detection where supported,
1096 ;; and choose a suitable target.
1097 ,@(match (or (%current-target-system)
1100 '("--enable-runtime-cpudetection"
1101 "--target=x86_64-linux"))
1103 '("--enable-runtime-cpudetection"
1104 "--target=i686-linux"))
1106 '("--target=mips3-linux"))
1107 (_ (list (string-append
1109 (or (%current-target-system)
1110 (nix-system->gnu-triplet
1111 (%current-system)))))))
1112 "--disable-iwmmxt")))))))
1113 (home-page "https://www.mplayerhq.hu/design7/news.html")
1114 (synopsis "Audio and video player")
1115 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
1116 Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
1117 NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
1118 SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
1119 (license license:gpl2)))
1128 "https://github.com/mpv-player/mpv/archive/v" version
1132 "06bk8836brzik1qmq8kycwg5n35r438sd2176k6msjg5rrwghakp"))
1133 (file-name (string-append name "-" version ".tar.gz"))))
1134 (build-system waf-build-system)
1136 `(("perl" ,perl) ; for zsh completion file
1137 ("pkg-config" ,pkg-config)
1138 ("python-docutils" ,python-docutils)))
1139 ;; Missing features: libguess, V4L2
1141 `(("alsa-lib" ,alsa-lib)
1148 ("libbluray" ,libbluray)
1149 ("libcaca" ,libcaca)
1150 ("libbs2b" ,libbs2b)
1151 ("libcdio-paranoia" ,libcdio-paranoia)
1152 ("libdvdread" ,libdvdread)
1153 ("libdvdnav" ,libdvdnav)
1154 ("libjpeg" ,libjpeg)
1156 ("libvdpau" ,libvdpau)
1158 ("libxext" ,libxext)
1159 ("libxinerama" ,libxinerama)
1160 ("libxrandr" ,libxrandr)
1161 ("libxscrnsaver" ,libxscrnsaver)
1163 ;; XXX: lua > 5.2 is not currently supported; see
1164 ;; waftools/checks/custom.py
1168 ("pulseaudio" ,pulseaudio)
1170 ("shaderc" ,shaderc)
1171 ("vulkan-headers" ,vulkan-headers)
1172 ("vulkan-loader" ,vulkan-loader)
1174 ("wayland" ,wayland)
1175 ("wayland-protocols" ,wayland-protocols)
1176 ("libxkbcommon" ,libxkbcommon)
1177 ("youtube-dl" ,youtube-dl)
1181 (modify-phases %standard-phases
1183 'configure 'setup-waf
1184 (lambda* (#:key inputs #:allow-other-keys)
1185 (copy-file (assoc-ref inputs "waf") "waf")
1188 #:configure-flags (list "--enable-libmpv-shared"
1193 "--disable-build-date")
1194 ;; No check function defined.
1196 (home-page "https://mpv.io/")
1197 (synopsis "Audio and video player")
1198 (description "mpv is a general-purpose audio and video player. It is a
1199 fork of mplayer2 and MPlayer. It shares some features with the former
1200 projects while introducing many more.")
1201 (license license:gpl2+)))
1203 (define-public gnome-mpv
1210 (uri (string-append "https://github.com/gnome-mpv/gnome-mpv/releases"
1211 "/download/v" version "/gnome-mpv-" version
1215 "1y47abkidxh1il0bvq8r3dglwn3ggsy41x2n7ic3x23wvvcqmq74"))))
1217 `(("intltool" ,intltool)
1218 ("pkg-config" ,pkg-config)))
1221 ("libepoxy" ,libepoxy)
1223 (build-system glib-or-gtk-build-system)
1224 (home-page "https://github.com/gnome-mpv/gnome-mpv")
1225 (synopsis "GTK+ frontend for the mpv media player")
1226 (description "GNOME MPV is a simple GTK+ frontend for the mpv media player.
1227 GNOME MPV interacts with mpv via the client API exported by libmpv, allowing
1228 access to mpv's powerful playback capabilities.")
1229 (license license:gpl3+)))
1231 (define-public libvpx
1236 ;; XXX: Upstream does not provide tarballs for > 1.6.1.
1239 (url "https://chromium.googlesource.com/webm/libvpx")
1240 (commit (string-append "v" version))))
1241 (file-name (git-file-name name version))
1244 "0vvh89hvp8qg9an9vcmwb7d9k3nixhxaz6zi65qdjnd0i56kkcz6"))
1245 (patches (search-patches "libvpx-use-after-free-in-postproc.patch"
1246 "libvpx-CVE-2016-2818.patch"))))
1247 (build-system gnu-build-system)
1249 `(#:configure-flags (list "--enable-shared"
1251 ;; Limit size to avoid CVE-2015-1258
1252 "--size-limit=16384x16384"
1253 (string-append "--prefix=" (assoc-ref %outputs "out")))
1254 #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
1255 (assoc-ref %outputs "out") "/lib"))
1256 #:phases (modify-phases %standard-phases
1258 (lambda* (#:key configure-flags #:allow-other-keys)
1259 ;; The configure script does not understand some of the GNU
1260 ;; options, so we only add the flags specified above.
1261 (apply invoke "./configure" configure-flags))))
1262 #:tests? #f)) ; no check target
1266 (synopsis "VP8/VP9 video codec")
1267 (description "libvpx is a codec for the VP8/VP9 video compression format.")
1268 (license license:bsd-3)
1269 (home-page "https://www.webmproject.org/")))
1271 (define-public youtube-dl
1274 (version "2018.09.08")
1277 (uri (string-append "https://yt-dl.org/downloads/"
1278 version "/youtube-dl-"
1282 "0vwc4faqdddrb3nm4fzmkr60n5rc2zwyy8jwrrjad60kcp8isf05"))))
1283 (build-system python-build-system)
1285 ;; The problem here is that the directory for the man page and completion
1286 ;; files is relative, and for some reason, setup.py uses the
1287 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
1288 ;; So, we need pass the prefix directly. In addition, make sure the Bash
1289 ;; completion file is called 'youtube-dl' rather than
1290 ;; 'youtube-dl.bash-completion'.
1291 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
1292 #:phases (modify-phases %standard-phases
1293 (add-before 'install 'fix-the-data-directories
1294 (lambda* (#:key outputs #:allow-other-keys)
1295 (let ((prefix (assoc-ref outputs "out")))
1296 (mkdir "bash-completion")
1297 (rename-file "youtube-dl.bash-completion"
1298 "bash-completion/youtube-dl")
1299 (substitute* "setup.py"
1300 (("youtube-dl\\.bash-completion")
1301 "bash-completion/youtube-dl")
1303 (string-append "'" prefix "/etc/"))
1305 (string-append "'" prefix "/share/")))
1307 (synopsis "Download videos from YouTube.com and other sites")
1309 "Youtube-dl is a small command-line program to download videos from
1310 YouTube.com and many more sites.")
1311 (home-page "https://yt-dl.org")
1312 (license license:public-domain)))
1314 (define-public youtube-dl-gui
1316 (name "youtube-dl-gui")
1321 (uri (pypi-uri "Youtube-DLG" version))
1324 "0napxwzgls5ik1bxbp99vly32l23xpc4ng5kr24hfhf21ypjyadb"))))
1325 (build-system python-build-system)
1327 ;; In Guix, wxpython has not yet been packaged for Python 3.
1328 `(#:python ,python-2
1329 ;; This package has no tests.
1332 (modify-phases %standard-phases
1333 (add-before 'build 'patch-source
1334 (lambda* (#:key inputs #:allow-other-keys)
1335 ;; The youtube-dl-gui program lets you configure options. Some of
1336 ;; them are problematic, so we change their defaults.
1337 (substitute* "youtube_dl_gui/optionsmanager.py"
1338 ;; When this is true, the builder process will try (and fail) to
1339 ;; write logs to the builder user's home directory.
1340 (("'enable_log': True") "'enable_log': False")
1341 ;; This determines which youtube-dl program youtube-dl-gui will
1342 ;; run. If we don't set this, then youtube-dl-gui might download
1343 ;; an arbitrary copy from the Internet into the user's home
1344 ;; directory and run it, so let's make sure youtube-dl-gui uses
1345 ;; the youtube-dl from the inputs by default.
1346 (("'youtubedl_path': self.config_path")
1347 (string-append "'youtubedl_path': '"
1348 (assoc-ref inputs "youtube-dl")
1350 ;; When this is True, when youtube-dl-gui is finished downloading
1351 ;; a file, it will try (and possibly fail) to open the directory
1352 ;; containing the downloaded file. This can fail because it
1353 ;; assumes that xdg-open is in PATH. Unfortunately, simply
1354 ;; adding xdg-utils to the propagated inputs is not enough to
1355 ;; make this work, so for now we set the default to False.
1356 (("'open_dl_dir': True") "'open_dl_dir': False"))
1357 ;; The youtube-dl program from the inputs is actually a wrapper
1358 ;; script written in bash, so attempting to invoke it as a python
1359 ;; script will fail.
1360 (substitute* "youtube_dl_gui/downloaders.py"
1361 (("cmd = \\['python', self\\.youtubedl_path\\]")
1362 "cmd = [self.youtubedl_path]"))
1363 ;; Use relative paths for installing data files so youtube-dl-gui
1364 ;; installs the files relative to its prefix in the store, rather
1365 ;; than relative to /. Also, instead of installing data files into
1366 ;; $prefix/usr/share, install them into $prefix/share for
1367 ;; consistency (see: (standards) Directory Variables).
1368 (substitute* "setup.py"
1369 (("= '/usr/share") "= 'share"))
1370 ;; Update get_locale_file() so it finds the installed localization
1372 (substitute* "youtube_dl_gui/utils.py"
1373 (("os\\.path\\.join\\('/usr', 'share'")
1374 (string-append "os.path.join('"
1375 (assoc-ref %outputs "out")
1376 "', 'share'"))))))))
1378 `(("python2-wxpython" ,python2-wxpython)
1379 ("youtube-dl" ,youtube-dl)))
1380 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
1382 "GUI (Graphical User Interface) for @command{youtube-dl}")
1384 "Youtube-dlG is a GUI (Graphical User Interface) for
1385 @command{youtube-dl}. You can use it to download videos from YouTube and any
1386 other site that youtube-dl supports.")
1387 (license license:unlicense)))
1389 (define-public you-get
1392 (version "0.4.1077")
1396 "https://github.com/soimort/you-get/archive/v"
1398 (file-name (string-append name "-" version ".tar.gz"))
1401 "04vxc91k627qgsqs8dhqajrb6vpj4pw21jlwbha28qakfiz2x11k"))))
1402 (build-system python-build-system)
1404 `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos
1407 (modify-phases %standard-phases
1408 (add-after 'unpack 'qualify-input-references
1409 ;; Explicitly invoke the input ffmpeg, instead of whichever one
1410 ;; happens to be in the user's $PATH at run time.
1411 (lambda* (#:key inputs #:allow-other-keys)
1412 (let ((ffmpeg (string-append (assoc-ref inputs "ffmpeg")
1414 (substitute* "src/you_get/processor/ffmpeg.py"
1415 ;; Don't blindly replace all occurrences of ‘'ffmpeg'’: the
1416 ;; same string is also used when sniffing ffmpeg's output.
1417 (("(FFMPEG == |\\()'ffmpeg'" _ prefix)
1418 (string-append prefix "'" ffmpeg "'")))
1420 #:tests? #f)) ; XXX some tests need Internet access
1421 (synopsis "Download videos, audio, or images from Web sites")
1423 "You-Get is a command-line utility to download media contents (videos,
1424 audio, images) from the Web. It can use either mpv or vlc for playback.")
1425 (home-page "https://you-get.org/")
1426 (license license:expat)))
1428 (define-public youtube-viewer
1430 (name "youtube-viewer")
1435 (url "https://github.com/trizen/youtube-viewer.git")
1437 (file-name (git-file-name name version))
1440 "0axgb95lx81psgrb2a5rfdd8gl4mhsrzf41jas6l58d1xkaj54ri"))))
1441 (build-system perl-build-system)
1443 `(("perl-module-build" ,perl-module-build)))
1444 ;; FIXME: Add optional dependencies once available:
1445 ;; perl-lwp-useragent-cached and perl-term-readline-gnu
1447 `(("perl-data-dump" ,perl-data-dump)
1448 ("perl-file-sharedir" ,perl-file-sharedir)
1449 ("perl-gtk2" ,perl-gtk2)
1450 ("perl-json" ,perl-json)
1451 ("perl-libwww" ,perl-libwww)
1452 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
1453 ("perl-mozilla-ca" ,perl-mozilla-ca)
1454 ("perl-unicode-linebreak" ,perl-unicode-linebreak)))
1456 `(#:modules ((guix build perl-build-system)
1459 #:module-build-flags '("--gtk")
1461 (modify-phases %standard-phases
1462 (add-after 'install 'wrap-program
1463 (lambda* (#:key outputs #:allow-other-keys)
1464 (let* ((out (assoc-ref outputs "out"))
1465 (bin-dir (string-append out "/bin/"))
1466 (site-dir (string-append out "/lib/perl5/site_perl/"))
1467 (lib-path (getenv "PERL5LIB")))
1468 (for-each (cut wrap-program <>
1469 `("PERL5LIB" ":" prefix (,lib-path ,site-dir)))
1470 (find-files bin-dir))
1473 "Lightweight application for searching and streaming videos from YouTube")
1475 "Youtube-viewer searches and plays YouTube videos in a native player.
1476 It comes with various search options; it can search for videos, playlists
1477 and/or channels. The videos are streamed directly in a selected video player
1478 at the best resolution (customizable) and with closed-captions (if available).
1479 Both command-line and GTK2 interface are available.")
1480 (home-page "https://github.com/trizen/youtube-viewer")
1481 (license license:perl-license)))
1483 (define-public libbluray
1489 (uri (string-append "https://download.videolan.org/videolan/"
1490 name "/" version "/"
1491 name "-" version ".tar.bz2"))
1494 "1zxfnw1xbghcj7b3zz5djndv6gwssxda19cz1lrlqrkg8577r7kd"))))
1495 (build-system gnu-build-system)
1497 `(#:configure-flags '("--disable-bdjava-jar")
1499 (modify-phases %standard-phases
1500 (add-after 'unpack 'refer-to-libxml2-in-.pc-file
1501 ;; Avoid the need to propagate libxml2 by referring to it
1502 ;; directly, as is already done for fontconfig & freetype.
1503 (lambda* (#:key inputs #:allow-other-keys)
1504 (let ((libxml2 (assoc-ref inputs "libxml2")))
1505 (substitute* "configure"
1506 ((" libxml-2.0") ""))
1507 (substitute* "src/libbluray.pc.in"
1508 (("^Libs.private:" field)
1509 (string-append field " -L" libxml2 "/lib -lxml2")))
1511 (add-before 'build 'fix-dlopen-paths
1512 (lambda* (#:key inputs #:allow-other-keys)
1513 (let ((libaacs (assoc-ref inputs "libaacs"))
1514 (libbdplus (assoc-ref inputs "libbdplus")))
1515 (substitute* "src/libbluray/disc/aacs.c"
1517 (string-append "\"" libaacs "/lib/libaacs\"")))
1518 (substitute* "src/libbluray/disc/bdplus.c"
1520 (string-append "\"" libbdplus "/lib/libbdplus\"")))
1522 (native-inputs `(("pkg-config" ,pkg-config)))
1524 `(("fontconfig" ,fontconfig)
1525 ("freetype" ,freetype)
1526 ("libaacs" ,libaacs)
1527 ("libbdplus" ,libbdplus)
1528 ("libxml2" ,libxml2)))
1529 (home-page "https://www.videolan.org/developers/libbluray.html")
1530 (synopsis "Blu-Ray Disc playback library")
1532 "libbluray is a library designed for Blu-Ray Disc playback for media
1533 players, like VLC or MPlayer.")
1534 (license license:lgpl2.1+)))
1536 (define-public libdvdread
1542 (uri (string-append "https://download.videolan.org/videolan/"
1543 name "/" version "/"
1544 name "-" version ".tar.bz2"))
1547 "0dgr23fzcjhb7ck54xkr9zmf4jcq3ph0dz3fbyvla1c6ni9ijfxk"))))
1548 (build-system gnu-build-system)
1550 `(#:configure-flags '("--with-libdvdcss=yes")))
1552 `(("pkg-config" ,pkg-config)))
1554 `(("libdvdcss" ,libdvdcss)))
1555 (home-page "http://dvdnav.mplayerhq.hu/")
1556 (synopsis "Library for reading video DVDs")
1558 "Libdvdread provides a simple foundation for reading DVD video
1559 disks. It provides the functionality that is required to access many
1560 DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
1561 authentication and descrambling (if an external libdvdcss library is
1563 (license license:gpl2+)))
1565 (define-public dvdauthor
1572 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
1576 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
1577 (build-system gnu-build-system)
1579 `(("libdvdread" ,libdvdread)
1581 ("imagemagick" ,imagemagick)
1582 ("libxml2" ,libxml2)
1583 ("freetype" ,freetype)))
1585 `(("pkg-config" ,pkg-config)))
1586 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
1587 (description "@command{dvdauthor} will generate a DVD-Video movie from a
1588 MPEG-2 stream containing VOB packets.")
1589 (home-page "http://dvdauthor.sourceforge.net")
1590 (license license:gpl3+)))
1592 (define-public libdvdnav
1598 (uri (string-append "https://download.videolan.org/videolan/"
1599 name "/" version "/"
1600 name "-" version ".tar.bz2"))
1603 "062njcksmpgw9yv3737qkf93r2pzhaxi9szqjabpa8d010dp38ph"))))
1604 (build-system gnu-build-system)
1606 `(("pkg-config" ,pkg-config)))
1608 `(("libdvdread" ,libdvdread)))
1609 (home-page "http://dvdnav.mplayerhq.hu/")
1610 (synopsis "Library for video DVD navigation features")
1612 "Libdvdnav is a library for developers of multimedia
1613 applications. It allows easy use of sophisticated DVD navigation features
1614 such as DVD menus, multiangle playback and even interactive DVD games. All
1615 this functionality is provided through a simple API which provides the DVD
1616 playback as a single logical stream of blocks, intermitted by special
1617 dvdnav events to report certain conditions. The main usage of libdvdnav is
1618 a loop regularly calling a function to get the next block, surrounded by
1619 additional calls to tell the library of user interaction. The whole
1620 DVD virtual machine and internal playback states are completely
1622 (license license:gpl2+)))
1624 (define-public libdvdcss
1630 (uri (string-append "https://download.videolan.org/pub/"
1631 name "/" version "/"
1632 name "-" version ".tar.bz2"))
1635 "0x957zzpf4w2cp8zlk29prj8i2q6hay3lzdzsyz8y3cwxivyvhkq"))))
1636 (build-system gnu-build-system)
1637 (home-page "https://www.videolan.org/developers/libdvdcss.html")
1638 (synopsis "Library for accessing DVDs as block devices")
1640 "libdvdcss is a simple library designed for accessing DVDs like a block
1641 device without having to bother about the decryption.")
1642 (license license:gpl2+)))
1644 (define-public srt2vtt
1651 "https://files.dthompson.us/srt2vtt/srt2vtt-"
1655 "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif"))))
1656 (build-system gnu-build-system)
1658 `(("guile" ,guile-2.0)))
1659 (synopsis "SubRip to WebVTT subtitle converter")
1660 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
1661 for use with HTML5 video.")
1662 (home-page "https://dthompson.us/projects/srt2vtt.html")
1663 (license license:gpl3+)))
1665 (define-public avidemux
1672 "mirror://sourceforge/" name "/" name "/" version "/"
1673 name "_" version ".tar.gz"))
1676 "0nz52yih8sff53inndkh2dba759xjzsh4b8xjww419lcpk0qp6kn"))
1677 (patches (search-patches "avidemux-install-to-lib.patch"))))
1678 (build-system cmake-build-system)
1680 `(("pkg-config" ,pkg-config)))
1681 ;; FIXME: Once packaged, add libraries not found during the build.
1683 `(("alsa-lib" ,alsa-lib)
1684 ("fontconfig" ,fontconfig)
1685 ("freetype" ,freetype)
1686 ("fribidi" ,fribidi)
1691 ("libvdpau" ,libvdpau)
1692 ("libvorbis" ,libvorbis)
1696 ("pulseaudio" ,pulseaudio)
1697 ("python" ,python-wrapper)
1698 ("qt" ,qt) ; FIXME: reenable modular qt after update - requires building
1699 ;("qtbase" ,qtbase) with -std=gnu++11.
1700 ;("qttools" ,qttools)
1706 `(#:tests? #f ; no check target
1708 ;; Make sure files inside the included ffmpeg tarball are
1710 (modify-phases %standard-phases
1711 (add-before 'patch-source-shebangs 'unpack-ffmpeg
1713 (with-directory-excursion "avidemux_core/ffmpeg_package"
1714 (system* "tar" "xf" "ffmpeg-2.7.6.tar.bz2")
1715 (delete-file "ffmpeg-2.7.6.tar.bz2"))))
1716 (add-after 'patch-source-shebangs 'repack-ffmpeg
1718 (with-directory-excursion "avidemux_core/ffmpeg_package"
1719 (substitute* "ffmpeg-2.7.6/configure"
1720 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1721 (system* "tar" "cjf" "ffmpeg-2.7.6.tar.bz2" "ffmpeg-2.7.6"
1722 ;; avoid non-determinism in the archive
1723 "--sort=name" "--mtime=@0"
1724 "--owner=root:0" "--group=root:0")
1725 (delete-file-recursively "ffmpeg-2.7.6"))))
1728 ;; Copy-paste settings from the cmake build system.
1729 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
1730 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))))
1732 (lambda* (#:key inputs outputs #:allow-other-keys)
1734 ((out (assoc-ref outputs "out"))
1735 (lib (string-append out "/lib"))
1737 (sdl (assoc-ref inputs "sdl"))
1739 (lambda* (component srcdir #:optional (args '()))
1740 (let ((builddir (string-append "build_" component)))
1742 (with-directory-excursion builddir
1745 (apply system* "cmake"
1746 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
1747 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
1748 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
1749 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
1750 "\"-Wl,-rpath=" lib "\"")
1751 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
1752 (string-append "-DSDL_INCLUDE_DIR="
1754 (string-append "../" srcdir)
1757 (system* "make" "-j"
1758 (number->string (parallel-job-count)))
1759 (system* "make" "install"))))))))
1761 (and (build_component "core" "avidemux_core")
1762 (build_component "cli" "avidemux/cli")
1763 (build_component "qt4" "avidemux/qt4")
1764 (build_component "plugins_common" "avidemux_plugins"
1765 '("-DPLUGIN_UI=COMMON"))
1766 (build_component "plugins_cli" "avidemux_plugins"
1767 '("-DPLUGIN_UI=CLI"))
1768 (build_component "plugins_qt4" "avidemux_plugins"
1769 '("-DPLUGIN_UI=QT4"))
1770 (build_component "plugins_settings" "avidemux_plugins"
1771 '("-DPLUGIN_UI=SETTINGS")))
1772 ;; Remove .exe and .dll file.
1773 (delete-file-recursively
1774 (string-append out "/share/ADM6_addons")))))
1775 (delete 'install))))
1776 (home-page "http://fixounet.free.fr/avidemux/")
1777 (synopsis "Video editor")
1778 (description "Avidemux is a video editor designed for simple cutting,
1779 filtering and encoding tasks. It supports many file types, including AVI,
1780 DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
1781 can be automated using projects, job queue and powerful scripting
1783 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
1784 ;; Software with various licenses is included, see License.txt.
1785 (license license:gpl2+)))
1787 (define-public vapoursynth
1789 (name "vapoursynth")
1794 "https://github.com/vapoursynth/vapoursynth/archive/R"
1796 (file-name (string-append name "-" version ".tar.gz"))
1799 "1g3hc079jw4mz1cmkv2y28pdb556wqc8ql7iravgh1rg8j3f1zi5"))))
1800 (build-system gnu-build-system)
1802 `(("autoconf" ,autoconf)
1803 ("automake" ,automake)
1804 ("cython" ,python-cython)
1805 ("libtool" ,libtool)
1806 ("pkg-config" ,pkg-config)
1810 `(("ffmpeg" ,ffmpeg)
1812 ("tesseract-ocr" ,tesseract-ocr)
1816 (modify-phases %standard-phases
1817 (add-after 'unpack 'autogen
1819 (invoke "sh" "autogen.sh"))))))
1820 (home-page "http://www.vapoursynth.com/")
1821 (synopsis "Video processing framework")
1822 (description "VapourSynth is a C++ library and Python module for video
1823 manipulation. It aims to be a modern rewrite of Avisynth, supporting
1824 multithreading, generalized colorspaces, per frame properties, and videos with
1826 ;; src/core/cpufeatures only allows x86, ARM or PPC
1827 (supported-systems (fold delete %supported-systems
1828 '("mips64el-linux" "aarch64-linux")))
1829 ;; As seen from the source files.
1830 (license license:lgpl2.1+)))
1839 "http://downloads.xvid.org/downloads/xvidcore-"
1840 version ".tar.bz2"))
1843 "1xwbmp9wqshc0ckm970zdpi0yvgqxlqg0s8bkz98mnr8p2067bsz"))))
1844 (build-system gnu-build-system)
1845 (native-inputs `(("yasm" ,yasm)))
1848 (modify-phases %standard-phases
1850 'configure 'pre-configure
1852 (chdir "build/generic")
1853 (substitute* "configure"
1854 (("#! /bin/sh") (string-append "#!" (which "sh")))))))
1855 ;; No 'check' target.
1857 (home-page "https://www.xvid.com/")
1858 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
1859 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
1860 codec library. It uses ASP features such as b-frames, global and quarter
1861 pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
1862 and custom quantization matrices.")
1863 (license license:gpl2+)))
1865 (define-public streamlink
1866 ;; Release tarball doesn't contain ‘tests/resources/dash/’ directory.
1867 (let ((commit "2dca7930a938f60b48d8e23260963ea7c49d979f"))
1870 (version (git-version "0.13.0" "1" commit))
1875 (url "https://github.com/streamlink/streamlink.git")
1877 (file-name (git-file-name name version))
1880 "0vq19aspshim63aj8yl2p64ykrbk2mwwlawdx427b3j2djlc5qhw"))))
1881 (build-system python-build-system)
1882 (home-page "https://github.com/streamlink/streamlink")
1884 `(("python-freezegun" ,python-freezegun)
1885 ("python-pytest" ,python-pytest)
1886 ("python-mock" ,python-mock)
1887 ("python-requests-mock" ,python-requests-mock)))
1889 `(("python-pysocks" ,python-pysocks)
1890 ("python-websocket-client" ,python-websocket-client)
1891 ("python-iso3166" ,python-iso3166)
1892 ("python-iso639" ,python-iso639)
1893 ("python-isodate", python-isodate)
1894 ("python-pycryptodome" ,python-pycryptodome)
1895 ("python-requests" ,python-requests)
1896 ("python-urllib3" ,python-urllib3)))
1897 (synopsis "Extract streams from various services")
1898 (description "Streamlink is command-line utility that extracts streams
1899 from sites like Twitch.tv and pipes them into a video player of choice.")
1900 (license license:bsd-2))))
1902 (define-public livestreamer
1903 (deprecated-package "livestreamer" streamlink))
1905 (define-public twitchy
1906 (let ((commit "0c0f925b9c7ff2aed4a3b0046561cb794143c398")) ;Fixes tests.
1909 (version (git-version "3.2" "1" commit))
1914 (url "https://github.com/BasioMeusPuga/twitchy.git")
1916 (file-name (git-file-name name version))
1919 "02aizvsr744sh8bdqvwwsmp2qpczlzn8fy76h5dyd3517n9nlcz9"))))
1920 (build-system python-build-system)
1923 (modify-phases %standard-phases
1924 (add-before 'check 'check-setup
1926 (setenv "HOME" (getcwd)) ;Needs to write to ‘$HOME’.
1928 (add-after 'install 'install-rofi-plugin
1929 (lambda* (#:key outputs #:allow-other-keys)
1930 (install-file "plugins/rofi-twitchy"
1931 (string-append (assoc-ref outputs "out")
1934 `(("python-requests" ,python-requests)
1935 ("streamlink" ,streamlink)))
1936 (home-page "https://github.com/BasioMeusPuga/twitchy")
1937 (synopsis "Command-line interface for Twitch.tv")
1939 "This package provides a command-line interface for Twitch.tv")
1940 (license license:gpl3+))))
1948 (uri (string-append "https://github.com/mltframework/mlt/"
1949 "archive/v" version ".tar.gz"))
1950 (file-name (string-append name "-" version ".tar.gz"))
1953 "10m3ry0b2pvqx3bk34qh5dq337nn8pkc2gzfyhsj4nv9abskln47"))
1954 (modules '((guix build utils)))
1956 ;; As of glibc 2.26, <xlocale.h> no longer is.
1957 (substitute* "src/framework/mlt_property.h"
1958 (("xlocale\\.h") "locale.h"))
1960 (build-system gnu-build-system)
1962 `(#:tests? #f ; no tests
1963 #:make-flags '("CC=gcc")
1965 (list "--enable-gpl3"
1968 (modify-phases %standard-phases
1970 'configure 'override-LDFLAGS
1971 (lambda* (#:key outputs #:allow-other-keys)
1972 (substitute* "config.mak"
1974 (string-append "LDFLAGS+=-Wl,-rpath="
1975 (assoc-ref outputs "out")
1979 `(("alsa-lib" ,alsa-lib)
1980 ("ffmpeg" ,ffmpeg-3.4)
1982 ("libxml2" ,libxml2)
1985 ("libsamplerate" ,libsamplerate)
1986 ("pulseaudio" ,pulseaudio)
1990 `(("pkg-config" ,pkg-config)))
1991 (home-page "https://www.mltframework.org/")
1992 (synopsis "Author, manage, and run multitrack audio/video compositions")
1994 "MLT is a multimedia framework, designed and developed for television
1995 broadcasting. It provides a toolkit for broadcasters, video editors, media
1996 players, transcoders, web streamers and many more types of applications. The
1997 functionality of the system is provided via an assortment of ready to use
1998 tools, XML authoring components, and an extensible plug-in based API.")
1999 (license license:gpl3)))
2001 (define-public v4l-utils
2007 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
2008 "/v4l-utils-" version ".tar.bz2"))
2011 "03g2b4rivrilimcp57mwrlsa3qvrxmk4sza08mygwmqbvcnic606"))))
2012 (build-system gnu-build-system)
2015 (list (string-append "--with-udevdir="
2016 (assoc-ref %outputs "out")
2018 "CXXFLAGS=-std=gnu++11")))
2021 ("pkg-config" ,pkg-config)))
2023 `(("alsa-lib" ,alsa-lib)
2025 ("libjpeg" ,libjpeg)
2029 (synopsis "Realtime video capture utilities for Linux")
2030 (description "The v4l-utils provide a series of libraries and utilities to
2031 be used for realtime video capture via Linux-specific APIs.")
2032 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
2033 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
2034 (license (list license:lgpl2.1+ license:gpl2))))
2042 (uri (string-append "https://github.com/jp9000/obs-studio"
2043 "/archive/" version ".tar.gz"))
2044 (file-name (string-append name "-" version ".tar.gz"))
2047 "1g5z6z050v25whc7n3xvg6l238wmg5crp7ihvk73qngvzxr8bg28"))))
2048 (build-system cmake-build-system)
2050 `(#:tests? #f)) ; no tests
2052 `(("pkg-config" ,pkg-config)))
2054 `(("alsa-lib" ,alsa-lib)
2058 ("fontconfig" ,fontconfig)
2059 ("freetype" ,freetype)
2061 ("jansson" ,jansson)
2062 ("libx264" ,libx264)
2063 ("libxcomposite" ,libxcomposite)
2065 ("pulseaudio" ,pulseaudio)
2067 ("qtx11extras" ,qtx11extras)
2069 ("v4l-utils" ,v4l-utils)
2071 (synopsis "Live streaming software")
2072 (description "Open Broadcaster Software provides a graphical interface for
2073 video recording and live streaming. OBS supports capturing audio and video
2074 from many input sources such as webcams, X11 (for screencasting), PulseAudio,
2076 (home-page "https://obsproject.com")
2077 (supported-systems '("x86_64-linux" "i686-linux"))
2078 (license license:gpl2+)))
2080 (define-public libvdpau
2087 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
2088 name "-" version ".tar.bz2"))
2091 "0dnpb0yh7v6rvckx82kxg045rd9rbsw25wjv7ad5n8h94s9h2yl5"))))
2092 (build-system gnu-build-system)
2094 `(("pkg-config" ,pkg-config)))
2096 `(("libx11" ,libx11 "out")
2097 ("libxext" ,libxext)
2098 ("xorgproto" ,xorgproto)))
2099 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
2100 (synopsis "Video Decode and Presentation API")
2101 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
2102 provides an interface to video decode acceleration and presentation hardware
2103 present in modern GPUs.")
2104 (license (license:x11-style "file://COPYING"))))
2106 (define-public vdpauinfo
2113 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
2114 name "-" version ".tar.gz"))
2117 "1i2b0k9h8r0lnxlrkgqzmrjakgaw3f1ygqqwzx8w6676g85rcm20"))))
2118 (build-system gnu-build-system)
2120 `(("pkg-config" ,pkg-config)
2121 ("libx11" ,libx11)))
2123 `(("libvdpau" ,libvdpau)))
2124 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
2125 (synopsis "Tool to query the capabilities of a VDPAU implementation")
2126 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
2128 (license (license:x11-style "file://COPYING"))))
2130 (define-public libvdpau-va-gl
2132 (name "libvdpau-va-gl")
2137 (uri (string-append "https://github.com/i-rinat/libvdpau-va-gl/"
2138 "releases/download/v" version "/libvdpau-va-gl-"
2142 "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
2143 (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
2144 (modules '((guix build utils)))
2145 (snippet '(begin (delete-file-recursively "3rdparty")
2147 (build-system cmake-build-system)
2149 '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
2151 `(("libvdpau" ,libvdpau)
2152 ("pkg-config" ,pkg-config)))
2156 (home-page "https://github.com/i-rinat/libvdpau-va-gl")
2157 (synopsis "VDPAU driver with VA-API/OpenGL backend")
2159 "Many applications can use VDPAU to accelerate portions of the video
2160 decoding process and video post-processing to the GPU video hardware. Since
2161 there is no VDPAU available on Intel chips, they fall back to different drawing
2162 techniques. This driver uses OpenGL under the hood to accelerate drawing and
2163 scaling and VA-API (if available) to accelerate video decoding.")
2164 (license license:expat)))
2166 (define-public recordmydesktop
2168 (name "recordmydesktop")
2172 (uri (string-append "mirror://sourceforge/" name "/" name "/"
2173 version "/recordmydesktop-" version ".tar.gz"))
2176 "133kkl5j0r877d41bzj7kj0vf3xm8x80yyx2n8nqxrva304f58ik"))))
2177 (build-system gnu-build-system)
2178 (inputs `(("popt" ,popt)
2183 ("libxfixes" ,libxfixes)
2184 ("libxdamage" ,libxdamage)
2185 ("libxext" ,libxext)
2186 ("alsa-lib" ,alsa-lib)
2187 ("libvorbis" ,libvorbis)
2188 ("libtheora" ,libtheora)))
2189 (home-page "http://recordmydesktop.sourceforge.net/")
2190 (synopsis "Desktop session video recorder")
2192 "recordMyDesktop is a command-line tool that captures the activity in
2193 your graphical desktop and encodes it as a video. This is a useful tool for
2194 making @dfn{screencasts}.")
2195 (license license:gpl2+)))
2197 (define-public simplescreenrecorder
2199 (name "simplescreenrecorder")
2204 (uri (string-append "https://github.com/MaartenBaert/ssr/archive/"
2206 (file-name (string-append name "-" version ".tar.gz"))
2209 "0l6irdadqpajvv0dj3ngs1231n559l0y1pykhs2h7526qm4w7xal"))))
2210 (build-system cmake-build-system)
2211 ;; Although libx11, libxfixes, libxext are listed as build dependencies in
2212 ;; README.md, the program builds and functions properly without them.
2213 ;; As a result, they are omitted. Please add them back if problems appear.
2215 `(("alsa-lib" ,alsa-lib)
2220 ("pulseaudio" ,pulseaudio)
2222 ("qtx11extras" ,qtx11extras)))
2223 (native-inputs `(("pkg-config" ,pkg-config)))
2226 (list "-DWITH_QT5=TRUE")
2227 #:tests? #f)) ; no test suite
2228 ;; Using HTTPS causes part of the page to be displayed improperly.
2229 (home-page "http://www.maartenbaert.be/simplescreenrecorder/")
2230 (synopsis "Screen recorder")
2231 (description "SimpleScreenRecorder is an easy to use screen recorder with
2232 a graphical user interface. It supports recording the entire screen, or a
2233 part of it, and allows encoding in many different codecs and file formats.
2234 Other features include a live preview and live streaming.")
2235 (license (list license:gpl3+ ; most files
2236 license:zlib ; glinject/elfhacks.*
2237 license:isc ; glinject/*
2238 license:x11)))) ; build-aux/install-sh
2240 (define-public libsmpeg
2247 (url "svn://svn.icculus.org/smpeg/trunk/")
2248 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
2249 (file-name (string-append name "-" version "-checkout"))
2252 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
2253 (build-system gnu-build-system)
2256 (modify-phases %standard-phases
2257 (add-after 'unpack 'autogen.sh
2259 (invoke "sh" "autogen.sh"))))))
2261 `(("autoconf" ,autoconf)
2262 ("automake" ,automake)))
2265 (home-page "http://icculus.org/smpeg/")
2266 (synopsis "SDL MPEG decoding library")
2268 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
2269 with sound support. Video playback is based on the ubiquitous Berkeley MPEG
2270 player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
2271 library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
2272 and MPEG system streams.")
2273 (license (list license:expat
2278 (define-public libbdplus
2285 (uri (string-append "https://ftp.videolan.org/pub/videolan/libbdplus/"
2286 version "/" name "-" version ".tar.bz2"))
2288 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
2290 `(("libgcrypt" ,libgcrypt)))
2291 (build-system gnu-build-system)
2292 (home-page "https://www.videolan.org/developers/libbdplus.html")
2293 (synopsis "Library for decrypting certain Blu-Ray discs")
2294 (description "libbdplus is a library which implements the BD+ System
2296 (license license:lgpl2.1+)))
2298 (define-public libaacs
2305 (uri (string-append "https://ftp.videolan.org/pub/videolan/libaacs/"
2306 version "/" name "-" version ".tar.bz2"))
2308 (base32 "1kms92i0c7i1yl659kqjf19lm8172pnpik5lsxp19xphr74vvq27"))))
2310 `(("libgcrypt" ,libgcrypt)))
2314 (build-system gnu-build-system)
2315 (home-page "https://www.videolan.org/developers/libaacs.html")
2316 (synopsis "Library for decrypting certain Blu-Ray discs")
2317 (description "libaacs is a library which implements the Advanced Access
2318 Content System specification.")
2319 (license license:lgpl2.1+)))
2321 (define-public mps-youtube
2323 (name "mps-youtube")
2328 (uri (string-append "https://github.com/mps-youtube/mps-youtube/"
2329 "archive/v" version ".tar.gz"))
2330 (file-name (string-append name "-" version ".tar.gz"))
2333 "0x7cmfh199q9j396v7bz81nnvanfllhsg86489i5dw2p3yyc9wnm"))))
2334 (build-system python-build-system)
2336 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
2337 ;; test suite results differ depending on the country and also introduce
2338 ;; non-determinism in the tests.
2339 ;; https://github.com/mps-youtube/mps-youtube/issues/556
2342 `(("python-pafy" ,python-pafy)
2343 ("python-pygobject" ,python-pygobject))) ; For mpris2 support
2344 (home-page "https://github.com/mps-youtube/mps-youtube")
2345 (synopsis "Terminal based YouTube player and downloader")
2347 "@code{mps-youtube} is based on mps, a terminal based program to
2348 search, stream and download music. This implementation uses YouTube as
2349 a source of content and can play and download video as well as audio.
2350 It can use either mpv or mplayer for playback, and for conversion of
2351 formats ffmpeg or libav is used. Users should install one of the
2352 supported players in addition to this package.")
2353 (license license:gpl3+)))
2355 (define-public handbrake
2361 (uri (string-append "https://handbrake.fr/rotation.php?file="
2362 "HandBrake-" version ".tar.bz2"))
2363 (file-name (string-append "handbrake-" version ".tar.bz2"))
2366 "1w720y3bplkz187wgvy4a4xm0vpppg45mlni55l6yi8v2bfk14pv"))
2367 (patches (search-patches "handbrake-pkg-config-path.patch"))
2368 (modules '((guix build utils)))
2370 ;; Remove bundled libraries and source not necessary for
2371 ;; running under a GNU environment.
2373 (for-each delete-file-recursively '("contrib" "macosx" "win"))
2375 (build-system glib-or-gtk-build-system)
2377 `(("automake" ,automake) ;gui subpackage must be bootstrapped
2378 ("autoconf" ,autoconf)
2379 ("curl" ,curl) ;not actually used, but tested for
2380 ("intltool" ,intltool)
2381 ("libtool" ,libtool)
2382 ("pkg-config" ,pkg-config)
2383 ("python" ,python-2))) ;for configuration
2386 ("dbus-glib" ,dbus-glib)
2387 ("ffmpeg" ,ffmpeg-3.4) ;compilation errors with ffmpeg-4
2388 ("fontconfig" ,fontconfig)
2389 ("freetype" ,freetype)
2391 ("gstreamer" ,gstreamer)
2392 ("gst-plugins-base" ,gst-plugins-base)
2396 ("libbluray" ,libbluray)
2397 ("libdvdnav" ,libdvdnav)
2398 ("libdvdread" ,libdvdread)
2399 ("libgudev" ,libgudev)
2400 ("libmpeg2" ,libmpeg2)
2401 ("libnotify" ,libnotify)
2403 ("libsamplerate" ,libsamplerate)
2404 ("libtheora" ,libtheora)
2405 ("libvorbis" ,libvorbis)
2407 ("libxml2" ,libxml2)
2408 ("libx264" ,libx264)
2412 `(#:tests? #f ;tests require Ruby and claim to be unsupported
2414 (modify-phases %standard-phases
2416 ;; Run bootstrap ahead of time so that shebangs get patched.
2418 (setenv "CONFIG_SHELL" (which "sh"))
2419 (setenv "NOCONFIGURE" "1")
2420 ;; Patch the Makefile so that it doesn't bootstrap again.
2421 (substitute* "gtk/module.rules"
2422 ((".*autogen\\.sh.*") ""))
2423 (invoke "sh" "./gtk/autogen.sh")))
2424 (add-before 'configure 'disable-contrib
2426 (substitute* "make/include/main.defs"
2427 ;; Disable unconditional inclusion of some "contrib"
2428 ;; libraries (ffmpeg, libvpx, libdvdread, libdvdnav,
2429 ;; and libbluray), which would lead to fetching and
2430 ;; building of these libraries. Use our own instead.
2431 (("MODULES \\+= contrib") "# MODULES += contrib"))
2433 (add-before 'configure 'fix-x265-linking
2435 (substitute* "test/module.defs"
2436 ;; Fix missing library during linking error
2437 (("TEST.GCC.l =") "TEST.GCC.l = x265"))
2440 (lambda* (#:key outputs configure-flags #:allow-other-keys)
2441 ;; 'configure' is not an autoconf-generated script, and
2442 ;; errors on unrecognized arguments,
2443 ;; e.g. --enable-fast-install
2444 (let ((out (assoc-ref outputs "out")))
2445 (apply invoke "./configure"
2446 (string-append "--prefix=" out)
2447 (or configure-flags '())))))
2448 (add-after 'configure 'chdir-build
2449 (lambda _ (chdir "./build") #t)))))
2450 (home-page "https://handbrake.fr")
2451 (synopsis "Video transcoder")
2453 "HandBrake is a tool for converting video from any format to a selection
2454 of modern, widely supported codecs.")
2455 ;; Most under GPL version 2 or later, and portions under BSD 3 Clause
2456 (license (list license:gpl2+ license:bsd-3))))
2458 (define-public openh264
2464 (uri (string-append "https://github.com/cisco/"
2465 name "/releases/download/v"
2466 version "/Source.Code.tar.gz.gz"))
2467 (file-name (string-append name "-" version ".tar.gz"))
2470 "0niha3wnn1jsndvz9vfwy2wyql8mp9j6v75vjsipy0idwan5yzgf"))))
2471 (build-system gnu-build-system)
2474 ("python" ,python)))
2476 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2478 #:test-target "test"
2479 #:phases (modify-phases %standard-phases
2480 ;; no configure script
2481 (delete 'configure))))
2482 (home-page "http://www.openh264.org/")
2483 (synopsis "H264 decoder library")
2485 "Openh264 is a library which can decode H264 video streams.")
2486 (license license:bsd-2)))
2488 (define-public libmp4v2
2495 ;; XXX: The new location of upstream is uncertain and will become relevant the
2496 ;; moment when the googlecode archive shuts down. It is past the date it
2497 ;; should've been turned off. I tried to communicate with upstream, but this
2498 ;; wasn't very responsive and not very helpful. The short summary is, it is
2499 ;; chaos when it comes to the amount of forks and only time will tell where
2500 ;; the new upstream location is.
2501 (uri (string-append "https://storage.googleapis.com/google-"
2502 "code-archive-downloads/v2/"
2503 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
2504 (file-name (string-append name "-" version ".tar.bz2"))
2507 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
2508 (build-system gnu-build-system)
2510 "static")) ; 3.7MiB .a file
2513 (modify-phases %standard-phases
2514 (add-after 'unpack 'remove-dates
2516 ;; Make the build reproducible.
2517 (substitute* "configure"
2518 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
2519 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
2521 (add-after 'install 'move-static-libraries
2522 (lambda* (#:key outputs #:allow-other-keys)
2523 ;; Move static libraries to the "static" output.
2524 (let* ((out (assoc-ref outputs "out"))
2525 (lib (string-append out "/lib"))
2526 (static (assoc-ref outputs "static"))
2527 (slib (string-append static "/lib")))
2529 (for-each (lambda (file)
2530 (install-file file slib)
2532 (find-files lib "\\.a$"))
2535 `(("help2man" ,help2man)
2536 ("dejagnu" ,dejagnu)))
2537 (home-page "https://code.google.com/archive/p/mp4v2/")
2538 (synopsis "API to create and modify mp4 files")
2540 "The MP4v2 library provides an API to create and modify mp4 files as defined by
2541 ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
2542 file format that has been used as a multimedia file format in a variety of platforms and
2543 applications. It is a very powerful and extensible format that can accommodate
2544 practically any type of media.")
2545 (license license:mpl1.1)))
2547 (define-public libmediainfo
2549 (name "libmediainfo")
2553 (uri (string-append "https://mediaarea.net/download/source/"
2555 name "_" version ".tar.bz2"))
2558 "1kchh6285b07z5nixv619hc9gml2ysdayicdiv30frrlqiyxqw4b"))))
2559 ;; TODO add a Big Buck Bunny webm for tests.
2561 `(("autoconf" ,autoconf)
2562 ("automake" ,automake)
2563 ("libtool" ,libtool)
2564 ("pkg-config" ,pkg-config)
2566 ("tinyxml2" ,tinyxml2)
2568 ("libzen" ,libzen)))
2569 (build-system gnu-build-system)
2571 '(#:tests? #f ; see above TODO
2573 ;; build scripts not in root of archive
2574 (modify-phases %standard-phases
2575 (add-after 'unpack 'change-to-build-dir
2577 (chdir "Project/GNU/Library")
2579 (add-after 'change-to-build-dir 'autogen
2581 (invoke "sh" "autogen.sh"))))))
2582 (home-page "https://mediaarea.net/en/MediaInfo")
2583 (synopsis "Library for retrieving media metadata")
2584 (description "MediaInfo is a library used for retrieving technical
2585 information and other metadata about audio or video files. A non-exhaustive
2586 list of the information MediaInfo can retrieve from media files include:
2589 @item General: title, author, director, album, track number, date, duration...
2590 @item Video: codec, aspect, fps, bitrate...
2591 @item Audio: codec, sample rate, channels, language, bitrate...
2592 @item Text: language of subtitle
2593 @item Chapters: number of chapters, list of chapters
2596 MediaInfo supports the following formats:
2599 @item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
2600 MPEG-2, MPEG-4, DVD (VOB)...
2601 @item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
2602 @item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
2603 @item Subtitles: SRT, SSA, ASS, SAMI...
2605 (license license:bsd-2)))
2607 ;; TODO also have a GUI version available
2608 (define-public mediainfo
2614 (uri (string-append "https://mediaarea.net/download/source/"
2615 name "/" version "/"
2616 name "_" version ".tar.bz2"))
2619 "0dy51a3i79jppmg1gi4f6h7jx4hcgnkmfim4d7d3gmnlbkjh8anv"))))
2621 `(("autoconf" ,autoconf)
2622 ("automake" ,automake)
2623 ("libtool" ,libtool)
2624 ("pkg-config" ,pkg-config)
2626 ("libmediainfo" ,libmediainfo)
2627 ("libzen" ,libzen)))
2628 (build-system gnu-build-system)
2630 '(#:tests? #f ; lacks tests
2632 ;; build scripts not in root of archive
2633 (modify-phases %standard-phases
2634 (add-after 'unpack 'change-to-build-dir
2636 (chdir "Project/GNU/CLI")
2638 (add-after 'change-to-build-dir 'autogen
2640 (invoke "sh" "autogen.sh"))))))
2641 (home-page "https://mediaarea.net/en/MediaInfo")
2642 (synopsis "Utility for reading media metadata")
2643 (description "MediaInfo is a utility used for retrieving technical
2644 information and other metadata about audio or video files. It supports the
2645 many codecs and formats supported by libmediainfo.")
2646 (license license:bsd-2)))
2648 (define-public livemedia-utils
2650 (name "livemedia-utils")
2651 (version "2017.10.28")
2655 "https://download.videolan.org/contrib/live555/live."
2659 "0f5kxpayqn3yhabqrd2cqlc74i6x2xr01jfkank1lcilxnfyrsnq"))
2660 (modules '((guix build utils)))
2662 ;; As of glibc 2.26, <xlocale.h> no longer is.
2663 (substitute* "liveMedia/include/Locale.hh"
2664 (("xlocale\\.h") "locale.h"))
2666 (build-system gnu-build-system)
2668 '(#:tests? #f ; no tests
2669 #:make-flags (list "CC=gcc"
2670 (string-append "LDFLAGS=-Wl,-rpath="
2671 (assoc-ref %outputs "out") "/lib")
2672 (string-append "PREFIX="
2673 (assoc-ref %outputs "out")))
2674 #:phases (modify-phases %standard-phases
2675 (add-before 'configure 'fix-makefiles-generation
2677 (substitute* "genMakefiles"
2682 (invoke "./genMakefiles"
2683 "linux-with-shared-libraries"))))))
2684 (home-page "http://www.live555.com/liveMedia/")
2685 (synopsis "Set of C++ libraries for multimedia streaming")
2686 (description "This code forms a set of C++ libraries for multimedia
2687 streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
2688 can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
2689 JPEG video, and several audio codecs. They can easily be extended to support
2690 additional (audio and/or video) codecs, and can also be used to build basic
2691 RTSP or SIP clients and servers.")
2692 (license license:lgpl3+)))
2694 (define-public libdvbpsi
2701 "https://download.videolan.org/pub/libdvbpsi/"
2702 version "/libdvbpsi-" version ".tar.bz2"))
2705 "1zn5hfv4qbahmydbwh59a3b480s3m5ss27r6ml35gqdip7r3jkmc"))))
2706 (build-system gnu-build-system)
2707 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
2708 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
2710 (description "libdvbpsi is a simple library designed for decoding and
2711 generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
2712 and ITU-T H.222.0.")
2713 (license license:lgpl2.1)))
2715 (define-public ffms2
2719 (home-page "https://github.com/FFMS/ffms2")
2722 (uri (string-append home-page "/archive/" version ".tar.gz"))
2723 (file-name (string-append name "-" version ".tar.gz"))
2726 "1vbkab8vrplxz5xgag8ggzkwp4f7nf285pd0l2a7zy66n6i2m6xh"))))
2727 (build-system gnu-build-system)
2730 (list "--enable-avresample")))
2734 `(("ffmpeg" ,ffmpeg)))
2736 `(("pkg-config" ,pkg-config)))
2737 (synopsis "Cross-platform wrapper around ffmpeg/libav")
2739 "FFMpegSource is a wrapper library around ffmpeg/libav that allows
2740 programmers to access a standard API to open and decompress media files.")
2741 ;; sources are distributed under a different license that the binary.
2742 ;; see https://github.com/FFMS/ffms2/blob/master/COPYING
2743 (license license:gpl2+))); inherits from ffmpeg
2745 (define-public aegisub
2752 "http://ftp.aegisub.org/pub/archives/releases/source/"
2753 name "-" version ".tar.xz"))
2756 "11b83qazc8h0iidyj1rprnnjdivj1lpphvpa08y53n42bfa36pn5"))
2757 (patches (search-patches "aegisub-icu59-include-unistr.patch"))))
2758 (build-system gnu-build-system)
2761 (list "--disable-update-checker"
2762 "--without-portaudio"
2765 "CXXFLAGS=-DU_USING_ICU_NAMESPACE=1")
2766 ;; tests require busted, a lua package we don't have yet
2769 (modify-phases %standard-phases
2770 (add-before 'configure 'fix-ldflags
2772 (setenv "LDFLAGS" "-pthread")
2776 ("desktop-file-utils" ,desktop-file-utils)
2779 ("hunspell" ,hunspell)
2782 ("alsa-lib" ,alsa-lib)
2783 ("pulseaudio" ,pulseaudio)
2785 ("freetype" ,freetype)
2786 ("wxwidgets-gtk2" ,wxwidgets-gtk2)))
2788 `(("intltool" ,intltool)
2789 ("pkg-config" ,pkg-config)))
2790 (home-page "http://www.aegisub.org/")
2791 (synopsis "Subtitle engine")
2793 "Aegisub is a tool for creating and modifying subtitles. Aegisub makes
2794 it quick and easy to time subtitles to audio, and features many powerful
2795 tools for styling them, including a built-in real-time video preview.")
2796 (license (list license:bsd-3 ; the package is licensed under the bsd-3, except
2797 license:mpl1.1 ; for vendor/universalchardet under the mpl1.1
2798 license:expat)))) ; and src/gl that is under a license similar
2799 ; the the Expat license, with a rewording (Software -> Materials). (called MIT
2800 ; by upstream). See https://github.com/Aegisub/Aegisub/blob/master/LICENCE
2801 ; src/MatroskaParser.(c|h) is under bsd-3 with permission from the author
2803 (define-public gst-transcoder
2805 (name "gst-transcoder")
2810 (uri (string-append "https://github.com/pitivi/gst-transcoder/"
2811 "archive/" version ".tar.gz"))
2812 (file-name (string-append name "-" version ".tar.gz"))
2815 "0cnwmrsd321s02ff91m3j27ydj7f8wks0jvmp5admlhka6z7zxm9"))))
2816 (build-system meson-build-system)
2818 `(("gobject-introspection" ,gobject-introspection)
2820 ("gstreamer" ,gstreamer)
2821 ("gst-plugins-base" ,gst-plugins-base)))
2823 `(("python" ,python)
2824 ("pkg-config" ,pkg-config)))
2825 (home-page "https://github.com/pitivi/gst-transcoder/")
2826 (synopsis "GStreamer Transcoding API")
2827 (description "GStreamer Transcoding API")
2828 (license license:lgpl2.1)))
2837 (uri (string-append "mirror://sourceforge/gmerlin/"
2838 name "/" version "/"
2839 name "-" version ".tar.gz"))
2840 (file-name (string-append name "-" version ".tar.gz"))
2843 "1kikkn971a14zzm7svi7190ldc14fjai0xyhpbcmp48s750sraji"))))
2844 (build-system gnu-build-system)
2846 '(#:configure-flags '("LIBS=-lm")))
2848 `(("pkg-config" ,pkg-config)
2849 ("doxygen" ,doxygen)))
2850 (home-page "http://gmerlin.sourceforge.net")
2851 (synopsis "Low level library for multimedia API building")
2853 "Gavl is short for Gmerlin Audio Video Library. It is a low level
2854 library, upon which multimedia APIs can be built. Gavl handles all the
2855 details of audio and video formats like colorspaces, sample rates,
2856 multichannel configurations, etc. It provides standardized definitions for
2857 those formats as well as container structures for carrying audio samples or
2858 video images inside an application.
2860 In addition, it handles the sometimes ugly task of converting between all
2861 these formats and provides some elementary operations (copying, scaling,
2862 alpha blending etc).")
2863 (license license:gpl3)))
2865 (define-public frei0r-plugins
2867 (name "frei0r-plugins")
2872 (uri (string-append "https://files.dyne.org/frei0r/"
2873 "frei0r-plugins-" version ".tar.gz"))
2876 "0pji26fpd0dqrx1akyhqi6729s394irl73dacnyxk58ijqq4dhp0"))))
2877 (build-system gnu-build-system)
2880 (modify-phases %standard-phases
2881 (add-after 'unpack 'autotools
2883 (invoke "sh" "autogen.sh"))))))
2884 ;; TODO: opencv for additional face detection filters.
2889 `(("pkg-config" ,pkg-config)
2890 ("libtool" ,libtool)
2891 ("automake" ,automake)
2892 ("autoconf" ,autoconf)))
2893 (home-page "https://www.dyne.org/software/frei0r/")
2894 (synopsis "Minimalistic plugin API for video effects")
2896 "Frei0r is a minimalistic plugin API for video effects.
2897 The main emphasis is on simplicity for an API that will round up
2898 the most common video effects into simple filters, sources and
2899 mixers that can be controlled by parameters. Frei0r wants to
2900 provide a way to share these simple effects between many
2901 applications, avoiding their reimplementation by different projects.
2902 It counts more than 100 plugins.")
2903 (license (list license:gpl2+
2904 ;; The following files are licensed as LGPL2.1+:
2905 ;; src/generator/ising0r/ising0r.c
2906 ;; src/generator/onecol0r/onecol0r.cpp
2907 ;; src/generator/nois0r/nois0r.cpp
2908 ;; src/generator/lissajous0r/lissajous0r.cpp
2909 ;; src/filter/ndvi/gradientlut.hpp
2910 ;; src/filter/ndvi/ndvi.cpp
2911 ;; src/filter/facedetect/facedetect.cpp
2912 license:lgpl2.1+))))
2914 (define-public motion
2918 (home-page "https://motion-project.github.io/")
2922 "https://github.com/Motion-Project/motion/archive/"
2923 "release-" version ".tar.gz"))
2926 "1qm4i8zrqafl60sv2frhixvkd0wh0r5jfcrj5i6gha7yplsvjx10"))
2927 (file-name (string-append name "-" version ".tar.gz"))))
2928 (build-system gnu-build-system)
2930 `(("autoconf" ,autoconf-wrapper)
2931 ("automake" ,automake)
2932 ("pkg-config" ,pkg-config)))
2934 `(("libjpeg" ,libjpeg)
2935 ("ffmpeg" ,ffmpeg-3.4)
2936 ("sqlite" ,sqlite)))
2938 '(#:phases (modify-phases %standard-phases
2941 (patch-shebang "version.sh")
2942 (invoke "autoreconf" "-vfi"))))
2943 #:configure-flags '("--sysconfdir=/etc")
2944 #:make-flags (list (string-append "sysconfdir="
2945 (assoc-ref %outputs "out")
2948 #:tests? #f)) ;no 'check' target
2949 (synopsis "Detect motion from video signals")
2951 "Motion is a program that monitors the video signal from one or more
2952 cameras and is able to detect if a significant part of the picture has
2953 changed. Or in other words, it can detect motion.")
2955 ;; Some files say "version 2" and others "version 2 or later".
2956 (license license:gpl2)))
2958 (define-public subdl
2959 (let ((commit "4cf5789b11f0ff3f863b704b336190bf968cd471")
2963 (version (git-version "1.0.3" revision commit))
2967 (url "https://github.com/alexanderwink/subdl.git")
2969 (file-name (git-file-name name version))
2972 "0kmk5ck1j49q4ww0lvas2767kwnzhkq0vdwkmjypdx5zkxz73fn8"))))
2973 (build-system trivial-build-system)
2975 `(#:modules ((guix build utils))
2977 (use-modules (guix build utils))
2978 (let* ((out (assoc-ref %outputs "out"))
2979 (bin (string-append out "/bin"))
2980 (source (assoc-ref %build-inputs "source"))
2981 (python (assoc-ref %build-inputs "python")))
2982 (install-file (string-append source "/subdl") bin)
2983 (patch-shebang (string-append bin "/subdl")
2984 (list (string-append python "/bin")))))))
2985 (inputs `(("python" ,python)))
2986 (synopsis "Command-line tool for downloading subtitles from opensubtitles.org")
2987 (description "Subdl is a command-line tool for downloading subtitles from
2988 opensubtitles.org. By default, it will search for English subtitles, display
2989 the results, download the highest-rated result in the requested language and
2990 save it to the appropriate filename.")
2991 (license license:gpl3+)
2992 (home-page "https://github.com/alexanderwink/subdl"))))
2994 (define-public l-smash
3001 "https://github.com/" name "/" name "/archive/v"
3003 (file-name (string-append name "-" version ".tar.gz"))
3006 "0dary0h65kq6sv93iabv25djlvzr5ckdcp3ywagbix44wqfw7xz6"))))
3007 (build-system gnu-build-system)
3009 `(#:tests? #f ;no tests
3011 (list (string-append "LDFLAGS=-Wl,-L.,-rpath="
3012 (assoc-ref %outputs "out") "/lib"))
3014 (modify-phases %standard-phases
3015 ;; configure fails if it is followed by CONFIG_SHELL
3017 (lambda* (#:key outputs #:allow-other-keys)
3018 (let ((out (assoc-ref outputs "out")))
3019 (invoke "./configure" (string-append "--prefix=" out)
3020 "--disable-static")))))))
3022 `(("which" ,which)))
3023 (home-page "https://l-smash.github.io/l-smash/")
3024 (synopsis "MP4 multiplexer and demultiplexer library")
3026 "L-SMASH is a cross-platform library that handles the ISO base media file
3027 format and some of its derived file formats, including MP4. It operates as a
3028 multiplexer and demultiplexer, and can mux video and audio in several formats
3029 using standalone executable files.")
3030 (license license:isc)))
3032 (define-public qtfaststart
3034 (name "qtfaststart")
3038 (uri (pypi-uri "qtfaststart" version))
3041 "0hcjfik8hhb1syqvyh5c6aillpvzal26nkjflcq1270z64aj6i5h"))))
3042 (build-system python-build-system)
3044 '(#:tests? #f)) ; no test suite
3045 (synopsis "Move QuickTime and MP4 metadata to the beginning of the file")
3046 (description "qtfaststart enables streaming and pseudo-streaming of
3047 QuickTime and MP4 files by moving metadata and offset information to the
3048 beginning of the file. It can also print some useful information about the
3049 structure of the file. This program is based on qt-faststart.c from the FFmpeg
3050 project, which is released into the public domain, as well as ISO 14496-12:2005
3051 (the official spec for MP4), which can be obtained from the ISO or found
3053 (home-page "https://github.com/danielgtaylor/qtfaststart")
3054 (license license:expat)))
3056 (define-public vidstab
3062 (uri (string-append "https://github.com/georgmartius/vid.stab/"
3063 "archive/v" version ".tar.gz"))
3066 "1fy03n343djfdi19msac81833v5iivpv635yjzrx9nkfwm9s1lhl"))))
3067 (build-system cmake-build-system)
3069 '(#:tests? #f)) ; tests are not run as part of standard build process
3070 (home-page "http://public.hronopik.de/vid.stab/")
3071 (synopsis "Video stabilization library")
3072 (description "Vidstab is a video stabilization library which can be used
3073 with FFmpeg. A video acquired using a hand-held camera or a camera mounted on a
3074 vehicle typically suffers from undesirable shakes and jitters. Activities such
3075 as surfing, skiing, riding and walking while shooting videos are especially
3076 prone to erratic camera shakes. Vidstab targets these video contents to help
3077 create smoother and stable videos.")
3078 (license license:gpl2+)))