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 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
6 ;;; Copyright © 2015, 2016, 2017 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 Alex Vong <alexvong1995@gmail.com>
10 ;;; Copyright © 2016, 2017 Alex Griffin <a@ajgrf.com>
11 ;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
12 ;;; Copyright © 2016 Dmitry Nikolaev <cameltheman@gmail.com>
13 ;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca>
14 ;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net>
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 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 Clément Lassieur <clement@lassieur.org>
23 ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
25 ;;; This file is part of GNU Guix.
27 ;;; GNU Guix is free software; you can redistribute it and/or modify it
28 ;;; under the terms of the GNU General Public License as published by
29 ;;; the Free Software Foundation; either version 3 of the License, or (at
30 ;;; your option) any later version.
32 ;;; GNU Guix is distributed in the hope that it will be useful, but
33 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
34 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
35 ;;; GNU General Public License for more details.
37 ;;; You should have received a copy of the GNU General Public License
38 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40 (define-module (gnu packages video)
41 #:use-module (ice-9 match)
42 #:use-module (srfi srfi-1)
43 #:use-module ((guix licenses) #:prefix license:)
44 #:use-module (guix utils)
45 #:use-module (guix packages)
46 #:use-module (guix download)
47 #:use-module (guix git-download)
48 #:use-module (guix svn-download)
49 #:use-module (guix build-system cmake)
50 #:use-module (guix build-system gnu)
51 #:use-module (guix build-system glib-or-gtk)
52 #:use-module (guix build-system python)
53 #:use-module (guix build-system waf)
54 #:use-module (gnu packages)
55 #:use-module (gnu packages algebra)
56 #:use-module (gnu packages audio)
57 #:use-module (gnu packages autotools)
58 #:use-module (gnu packages avahi)
59 #:use-module (gnu packages base)
60 #:use-module (gnu packages bison)
61 #:use-module (gnu packages boost)
62 #:use-module (gnu packages cdrom)
63 #:use-module (gnu packages check)
64 #:use-module (gnu packages cmake)
65 #:use-module (gnu packages compression)
66 #:use-module (gnu packages cpp)
67 #:use-module (gnu packages curl)
68 #:use-module (gnu packages databases)
69 #:use-module (gnu packages dejagnu)
70 #:use-module (gnu packages docbook)
71 #:use-module (gnu packages elf)
72 #:use-module (gnu packages file)
73 #:use-module (gnu packages flex)
74 #:use-module (gnu packages fontutils)
75 #:use-module (gnu packages freedesktop)
76 #:use-module (gnu packages fribidi)
77 #:use-module (gnu packages gettext)
78 #:use-module (gnu packages ghostscript)
79 #:use-module (gnu packages gl)
80 #:use-module (gnu packages glib)
81 #:use-module (gnu packages guile)
82 #:use-module (gnu packages gnome)
83 #:use-module (gnu packages gnupg)
84 #:use-module (gnu packages gstreamer)
85 #:use-module (gnu packages gtk)
86 #:use-module (gnu packages image)
87 #:use-module (gnu packages imagemagick)
88 #:use-module (gnu packages linux)
89 #:use-module (gnu packages lua)
90 #:use-module (gnu packages m4)
91 #:use-module (gnu packages man)
92 #:use-module (gnu packages mp3)
93 #:use-module (gnu packages ncurses)
94 #:use-module (gnu packages ocr)
95 #:use-module (gnu packages perl)
96 #:use-module (gnu packages pkg-config)
97 #:use-module (gnu packages popt)
98 #:use-module (gnu packages pulseaudio)
99 #:use-module (gnu packages python)
100 #:use-module (gnu packages qt)
101 #:use-module (gnu packages ruby)
102 #:use-module (gnu packages sdl)
103 #:use-module (gnu packages serialization)
104 #:use-module (gnu packages shells)
105 #:use-module (gnu packages ssh)
106 #:use-module (gnu packages texinfo)
107 #:use-module (gnu packages textutils)
108 #:use-module (gnu packages tls)
109 #:use-module (gnu packages version-control)
110 #:use-module (gnu packages web)
111 #:use-module (gnu packages webkit)
112 #:use-module (gnu packages wxwidgets)
113 #:use-module (gnu packages xdisorg)
114 #:use-module (gnu packages xiph)
115 #:use-module (gnu packages xml)
116 #:use-module (gnu packages xorg)
117 #:use-module (gnu packages assembly))
125 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
126 version "/" name "-" version ".tar.gz"))
129 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
130 (build-system gnu-build-system)
132 `(("makeinfo" ,texinfo)))
134 `(("ncurses" ,ncurses)))
137 (modify-phases %standard-phases
139 (lambda* (#:key build inputs outputs #:allow-other-keys)
140 ;; This old `configure' script doesn't support
141 ;; variables passed as arguments.
142 (let ((out (assoc-ref outputs "out"))
143 (ncurses (assoc-ref inputs "ncurses")))
144 (setenv "CONFIG_SHELL" (which "bash"))
145 (zero? (system* "./configure"
146 (string-append "--prefix=" out)
147 (string-append "--build=" build)
148 ;; The ancient config.guess is unable to
149 ;; guess the host triplet on mips64el.
150 ,@(if (string=? "mips64el-linux"
152 '("--host=mips64el-unknown-linux-gnu")
154 ;; The same is also true with aarch64.
155 ,@(if (string=? "aarch64-linux"
157 '("--host=aarch64-unknown-linux-gnu")
159 (string-append "--with-ncurses="
161 (home-page "http://aa-project.sourceforge.net/aalib/")
162 (synopsis "ASCII-art library")
164 "AA-lib is a low level gfx library which does not require graphics device.
165 In fact, there is no graphical output possible. AA-lib replaces those
166 old-fashioned output methods with powerful ascii-art renderer.")
167 (license license:lgpl2.0+)))
169 (define-public liba52
176 ;; A mirror://sourceforge URI doesn't work, presumably
177 ;; because the SourceForge project is misconfigured.
178 "http://liba52.sourceforge.net/files/a52dec-" version
182 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
183 (patches (search-patches "liba52-enable-pic.patch"
184 "liba52-set-soname.patch"
185 "liba52-use-mtune-not-mcpu.patch"
186 "liba52-link-with-libm.patch"))))
187 (build-system gnu-build-system)
188 ;; XXX We need to run ./bootstrap because of the build system fixes above.
190 `(("autoconf" ,autoconf)
191 ("automake" ,automake)
192 ("libtool" ,libtool)))
193 (arguments `(#:configure-flags '("--enable-shared")
195 (modify-phases %standard-phases
196 ;; XXX We need to run ./bootstrap because of the build
197 ;; system fixes above.
200 (lambda _ (zero? (system* "sh" "bootstrap")))))))
201 (home-page "http://liba52.sourceforge.net/")
202 (synopsis "ATSC A/52 stream decoder")
203 (description "liba52 is a library for decoding ATSC A/52 streams. The
204 A/52 standard is used in a variety of applications, including digital
205 television and DVD. It is also known as AC-3.")
206 (license license:gpl2+)))
208 (define-public libmpeg2
214 ;; A mirror://sourceforge URI doesn't work, presumably
215 ;; because the SourceForge project is misconfigured.
216 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
217 name "-" version ".tar.gz"))
220 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
228 (build-system gnu-build-system)
229 (home-page "http://libmpeg2.sourceforge.net/")
230 (synopsis "MPEG1 and MPEG2 video decoder library")
232 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
233 (license license:gpl2+)))
235 (define-public libx264
238 (version "20170316-2245")
241 (uri (string-append "https://download.videolan.org/pub/x264/snapshots/"
242 "x264-snapshot-" version ".tar.bz2"))
245 "1s1nnvl3axz38sv4g09skijl6k9mbbngbb1nsh26w4dr2w2gyzad"))))
246 (build-system gnu-build-system)
248 `(("pkg-config" ,pkg-config)
250 ;; TODO: Add gpac input
252 `(#:tests? #f ;no check target
253 #:configure-flags '("--enable-shared"
254 ;; Don't build the command-line program. If we
255 ;; want it later, we should do so in a different
256 ;; package to avoid a circular dependency (the x264
257 ;; program depends on ffmpeg and ffmpeg depends on
261 ;; On MIPS, we must pass "--disable-asm" or else
262 ;; configure fails after printing: "You specified a
263 ;; pre-MSA CPU in your CFLAGS. If you really want
264 ;; to run on such a CPU, configure with
266 ,@(if (string-prefix? "mips"
267 (or (%current-target-system)
271 (home-page "https://www.videolan.org/developers/x264.html")
272 (synopsis "H.264 video coding library")
273 (description "libx264 is an advanced encoding library for creating
274 H.264 (MPEG-4 AVC) video streams.")
275 (license (list license:gpl2+ ;most files
276 license:isc ;common/x86/x86inc.asm
277 license:lgpl2.1+ ;extras/getopt.c
278 license:bsd-3 ;extras/inttypes.h
279 (license:non-copyleft ;extras/cl*.h
281 "See extras/cl.h in the distribution.")))))
283 (define-public mkvtoolnix
290 (uri (string-append "https://mkvtoolnix.download/sources/"
291 name "-" version ".tar.xz"))
294 "0hknnnnx9661igm1r73dc7aqxnnrl5a8yvyvr1nhd9ymn2klwpl5"))
295 (modules '((guix build utils)))
298 ;; Delete bundled libraries.
299 (for-each delete-file-recursively
305 (build-system gnu-build-system)
312 ("libmatroska" ,libmatroska)
314 ("libvorbis" ,libvorbis)
321 `(("docbook-xsl" ,docbook-xsl)
322 ("gettext" ,gettext-minimal)
323 ("googletest" ,googletest)
325 ("nlohmann-json-cpp" ,nlohmann-json-cpp)
327 ("pkg-config" ,pkg-config)
332 (list (string-append "--with-boost="
333 (assoc-ref %build-inputs "boost"))
334 (string-append "--with-docbook-xsl-root="
335 (assoc-ref %build-inputs "docbook-xsl")
336 "/xml/xsl/docbook-xsl-"
337 ,(package-version docbook-xsl))
338 (string-append "--with-extra-includes="
339 (assoc-ref %build-inputs "nlohmann-json-cpp")
340 "/include/nlohmann"))
342 (modify-phases %standard-phases
343 (add-before 'configure 'add-googletest
346 (string-append (assoc-ref %build-inputs "googletest")
347 "/include/gtest") "lib/gtest")
351 (let ((-j (list "-j" (number->string (parallel-job-count)))))
352 (zero? (apply system* "rake" -j)))))
355 (zero? (system* "rake" "tests/unit"))))
358 (zero? (system* "rake" "install")))))))
359 (home-page "https://mkvtoolnix.download")
360 (synopsis "Tools to create, alter and inspect Matroska files")
362 "MKVToolNix provides tools for getting information about Matroska files
363 (@code{mkvinfo}), extracting tracks/data from Matroska files (@code{mkvextract})
364 and creating Matroska files from other media files (@code{mkvmerge}).")
365 (license license:gpl2)))
374 (uri (string-append "https://download.videolan.org/videolan/x265/"
375 "x265_" version ".tar.gz"))
378 "0afp0xlk0fb4q6j4sh3hyvjnjccdp61sn21zg3fyqvwgswcafalw"))
379 (modules '((guix build utils)))
381 '(delete-file-recursively "source/compat/getopt"))))
382 (build-system cmake-build-system)
384 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
385 ;; Currently the source code doesn't check for aarch64
386 ,@(if (string-prefix? "aarch64" (or (%current-target-system) (%current-system)))
387 '(#:configure-flags '("-DENABLE_PIC=TRUE"))
390 (modify-phases %standard-phases
391 (add-before 'configure 'prepare-build
393 (delete-file-recursively "build")
396 (home-page "http://x265.org/")
397 (synopsis "Library for encoding h.265/HEVC video streams")
398 (description "x265 is a H.265 / HEVC video encoder application library,
399 designed to encode video or images into an H.265 / HEVC encoded bitstream.")
400 (license license:gpl2+)))
402 (define-public libass
409 "https://github.com/libass/libass/releases/download/"
410 version "/libass-" version ".tar.xz"))
413 "17byv926w1mxn56n896sxvdq4m0yv1l7qbm688h6zr3nzgsyarbh"))))
414 (build-system gnu-build-system)
416 `(("pkg-config" ,pkg-config)
419 `(("freetype" ,freetype)
421 ("fontconfig" ,fontconfig)
422 ("harfbuzz" ,harfbuzz)
424 (home-page "https://github.com/libass/libass")
425 (synopsis "Subtitle rendering library for the ASS/SSA format")
426 (description "libass is a subtitle rendering library for the
427 ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
428 (license license:isc)))
430 (define-public libcaca
433 (version "0.99.beta19")
436 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
440 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))))
441 (build-system gnu-build-system)
442 (native-inputs `(("pkg-config" ,pkg-config)))
444 `(("freeglut" ,freeglut)
451 (home-page "http://caca.zoy.org/wiki/libcaca")
452 (synopsis "Colour ASCII-art library")
453 (description "libcaca is a graphics library that outputs text instead of
454 pixels, so that it can work on older video cards or text terminals. It
455 supports Unicode, 2048 colors, dithering of color images, and advanced text
457 (license (license:fsf-free "file://COPYING")))) ;WTFPL version 2
459 (define-public libdca
466 "https://download.videolan.org/pub/videolan/libdca/"
467 version "/libdca-" version ".tar.bz2"))
470 "0hh6a7l8vvccsd5i1fkv9av2gzv9fy8m0b8jpsn5p6hh4bh2586v"))))
471 (build-system gnu-build-system)
472 (home-page "https://www.videolan.org/developers/libdca.html")
473 (synopsis "DTS Coherent Acoustics decoder")
474 (description "libdca is a library for decoding DTS Coherent Acoustics
476 (license license:gpl2+)))
485 "mirror://sourceforge/" name "/" name "/"
486 version "/" name "-" version ".tar.gz"))
489 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
490 (build-system gnu-build-system)
491 (native-inputs `(("pkg-config" ,pkg-config)))
492 (inputs `(("libxv" ,libxv)))
493 (home-page "http://libdv.sourceforge.net/")
494 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
495 (description "The Quasar DV codec (libdv) is a software codec for DV
496 video, the encoding format used by most digital camcorders, typically those
497 that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
498 developed according to the official standards for DV video: IEC 61834 and
500 (license license:lgpl2.1+)))
502 (define-public libmatroska
509 (uri (string-append "https://dl.matroska.org/downloads/"
510 name "/" name "-" version ".tar.bz2"))
513 "1yi5cnv13nhl27xyqayd5l3sf0j3swfj3apzibv71yg9pariwi26"))))
514 (build-system gnu-build-system)
516 `(("pkg-config" ,pkg-config)))
518 `(("libebml" ,libebml)))
519 (home-page "https://www.matroska.org")
520 (synopsis "C++ libary to parse Matroska files (.mkv and .mka)")
522 "Matroska aims to become the standard of multimedia container formats.
523 It is based on EBML (Extensible Binary Meta Language), a binary derivative
524 of XML. EBML enables the Matroska Development Team to gain significant
525 advantages in terms of future format extensibility, without breaking file
526 support in old parsers.
527 libebml is a C++ library to read and write EBML files.")
528 (license license:lgpl2.1)))
538 "https://www.freedesktop.org/software/vaapi/releases/libva/libva-"
541 (base32 "1pnfl3q7dzxs26l3jk9xi97gr0qwnaz6dhvf9ifp2yplr3fy7lwy"))))
542 (build-system gnu-build-system)
544 `(("pkg-config" ,pkg-config)))
549 ("libxfixes" ,libxfixes)
553 (modify-phases %standard-phases
555 'build 'fix-dlopen-paths
556 (lambda* (#:key outputs #:allow-other-keys)
557 (let ((out (assoc-ref outputs "out")))
558 (substitute* "va/drm/va_drm_auth_x11.c"
559 (("\"libva-x11\\.so\\.%d\"")
560 (string-append "\"" out "/lib/libva-x11.so.%d\"")))))))
561 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
562 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
564 (list (string-append "--with-drivers-path="
565 (assoc-ref %build-inputs "mesa") "/lib/dri"))
566 ;; However, we can't write to mesa's store directory, so override the
567 ;; following make variable to install the dummy driver to libva's
568 ;; $prefix/lib/dri directory.
570 (list (string-append "dummy_drv_video_ladir="
571 (assoc-ref %outputs "out") "/lib/dri"))))
572 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
573 (synopsis "Video acceleration library")
574 (description "The main motivation for VA-API (Video Acceleration API) is
575 to enable hardware accelerated video decode/encode at various
576 entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
577 standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
578 (license license:expat)))
580 (define-public ffmpeg
586 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
590 "11974vcfsy8w0i6f4lfwqmg80xkfybqw7vw6zzrcn5i6ncddx60r"))))
591 (build-system gnu-build-system)
593 `(("fontconfig" ,fontconfig)
594 ("freetype" ,freetype)
600 ("libbluray" ,libbluray)
602 ("libcdio-paranoia" ,libcdio-paranoia)
603 ("libtheora" ,libtheora)
605 ("libvdpau" ,libvdpau)
606 ("libvorbis" ,libvorbis)
612 ("pulseaudio" ,pulseaudio)
623 ("pkg-config" ,pkg-config)
625 ("python" ,python-2) ; scripts use interpreter python2
629 `(#:test-target "fate"
631 ;; possible additional inputs:
632 ;; --enable-avisynth enable reading of AviSynth script
634 ;; --enable-frei0r enable frei0r video filtering
635 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
636 ;; --enable-libcelt enable CELT decoding via libcelt [no]
637 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
638 ;; and libraw1394 [no]
639 ;; --enable-libfaac enable AAC encoding via libfaac [no]
640 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
641 ;; --enable-libflite enable flite (voice synthesis) support via
643 ;; --enable-libgme enable Game Music Emu via libgme [no]
644 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
645 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
646 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
647 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
648 ;; --enable-libnut enable NUT (de)muxing via libnut,
649 ;; native (de)muxer exists [no]
650 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
651 ;; libopencore-amrnb [no]
652 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
653 ;; libopencore-amrwb [no]
654 ;; --enable-libopencv enable video filtering via libopencv [no]
655 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
657 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
658 ;; --enable-libschroedinger enable Dirac de/encoding via
659 ;; libschroedinger [no]
660 ;; --enable-libshine enable fixed-point MP3 encoding via
662 ;; --enable-libssh enable SFTP protocol via libssh [no]
663 ;; (libssh2 does not work)
664 ;; --enable-libstagefright-h264 enable H.264 decoding via
665 ;; libstagefright [no]
666 ;; --enable-libutvideo enable Ut Video encoding and decoding via
668 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
669 ;; --enable-libvidstab enable video stabilization using
671 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
672 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
673 ;; libvo-amrwbenc [no]
674 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
675 ;; --enable-libxavs enable AVS encoding via xavs [no]
676 ;; --enable-libzmq enable message passing via libzmq [no]
677 ;; --enable-libzvbi enable teletext support via libzvbi [no]
678 ;; --enable-opencl enable OpenCL code
679 '("--enable-avresample"
680 "--enable-gpl" ; enable optional gpl licensed parts
682 "--enable-fontconfig"
689 "--enable-libfreetype"
690 "--enable-libmp3lame"
696 "--enable-libtwolame"
705 "--enable-runtime-cpudetect"
707 ;; Runtime cpu detection is not implemented on
708 ;; MIPS, so we disable some features.
711 "--disable-mipsdspr2"
714 (modify-phases %standard-phases
717 ;; configure does not work followed by "SHELL=..." and
718 ;; "CONFIG_SHELL=..."; set environment variables instead
719 (lambda* (#:key outputs configure-flags #:allow-other-keys)
720 (let ((out (assoc-ref outputs "out")))
721 (substitute* "configure"
722 (("#! /bin/sh") (string-append "#!" (which "sh"))))
723 (setenv "SHELL" (which "bash"))
724 (setenv "CONFIG_SHELL" (which "bash"))
725 (zero? (apply system*
727 (string-append "--prefix=" out)
728 ;; Add $libdir to the RUNPATH of all the binaries.
729 (string-append "--extra-ldflags=-Wl,-rpath="
733 'check 'set-ld-library-path
735 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
737 (let* ((dso (find-files "." "\\.so$"))
738 (path (string-join (map dirname dso) ":")))
739 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
740 (setenv "LD_LIBRARY_PATH" path)
742 (home-page "https://www.ffmpeg.org/")
743 (synopsis "Audio and video framework")
744 (description "FFmpeg is a complete, cross-platform solution to record,
745 convert and stream audio and video. It includes the libavcodec
746 audio/video codec library.")
747 (license license:gpl2+)))
749 (define-public ffmpeg-2.8
755 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
759 "1gc32akvdms3rywphnap94lqqici8l5898a09ir1ad5rif5g24v2"))))
761 (substitute-keyword-arguments (package-arguments ffmpeg)
762 ((#:configure-flags flags)
764 (if (string=? flag "--disable-mipsdsp")
765 "--disable-mipsdspr1"
776 "https://download.videolan.org/pub/videolan/vlc/"
777 version "/vlc-" version ".tar.xz"))
780 "1a22b913p2227ljz89c4fgjlyln5gcz8z58w32r0wh4srnnd60y4"))))
781 (build-system gnu-build-system)
783 `(("autoconf" ,autoconf)
784 ("automake" ,automake)
785 ("git" ,git) ; needed for a test
787 ("pkg-config" ,pkg-config)))
788 ;; FIXME: Add optional inputs once available.
790 `(("alsa-lib" ,alsa-lib)
794 ("ffmpeg" ,ffmpeg-2.8) ;fails to build against ffmpeg 3.0
795 ("fontconfig" ,fontconfig)
796 ("freetype" ,freetype)
800 ("libdvbpsi" ,libdvbpsi)
801 ("libgcrypt" ,libgcrypt)
806 ("libsamplerate" ,libsamplerate)
808 ("libvorbis" ,libvorbis)
809 ("libtheora" ,libtheora)
812 ("libxinerama" ,libxinerama)
815 ("livemedia-utils" ,livemedia-utils)
820 ("pulseaudio" ,pulseaudio)
821 ("python" ,python-wrapper)
822 ("qt" ,qt) ; FIXME: reenable modular qt after update - requires building
823 ;("qtbase" ,qtbase) with -std=gnu++11.
824 ;("qtx11extras" ,qtx11extras)
826 ("sdl-image" ,sdl-image)
829 ("xcb-util-keysyms" ,xcb-util-keysyms)))
832 `(;; Gross workaround for <https://trac.videolan.org/vlc/ticket/16907>.
833 ;; In our case, this led to a test failure:
834 ;; test_libvlc_equalizer: libvlc/equalizer.c:122: test_equalizer: Assertion `isnan(libvlc_audio_equalizer_get_amp_at_index (equalizer, u_bands))' failed.
835 "ac_cv_c_fast_math=no"
837 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
838 (assoc-ref %build-inputs "ffmpeg")
839 "/lib")) ;needed for the tests
842 (modify-phases %standard-phases
843 (add-before 'configure 'bootstrap
844 (lambda _ (zero? (system* "sh" "bootstrap"))))
845 (add-before 'bootstrap 'fix-livemedia-utils-prefix
846 (lambda* (#:key inputs #:allow-other-keys)
847 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
848 (substitute* "configure.ac"
849 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
850 (string-append "LIVE555_PREFIX=" livemedia-utils)))
852 (add-before 'configure 'remove-visual-tests
853 ;; Some of the tests require using the display to test out VLC,
854 ;; which fails in our sandboxed build system
856 (substitute* "test/run_vlc.sh"
857 (("./vlc --ignore-config") "echo"))
859 (add-after 'install 'regenerate-plugin-cache
860 (lambda* (#:key outputs #:allow-other-keys)
861 ;; The 'install-exec-hook' rule in the top-level Makefile.am
862 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
863 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
864 ;; it references. Thus, we first reset the timestamps of all
865 ;; these files, and then regenerate the cache such that the
866 ;; mtimes it includes are always zero instead of being dependent
867 ;; on the build time.
868 (let* ((out (assoc-ref outputs "out"))
869 (pkglibdir (string-append out "/lib/vlc"))
870 (plugindir (string-append pkglibdir "/plugins"))
871 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
872 ;; TODO: Factorize 'reset-timestamps'.
873 (for-each (lambda (file)
874 (let ((s (lstat file)))
875 (unless (eq? (stat:type s) 'symlink)
876 (utime file 0 0 0 0))))
877 (find-files plugindir))
878 (zero? (system* cachegen plugindir))))))))
879 (home-page "https://www.videolan.org/")
880 (synopsis "Audio and video framework")
881 (description "VLC is a cross-platform multimedia player and framework
882 that plays most multimedia files as well as DVD, Audio CD, VCD, and various
883 treaming protocols.")
884 (license license:gpl2+)))
886 (define-public mplayer
893 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
897 "0hwqn04bdknb2ic88xd75smffxx63scvz0zvwvjb56nqj9n89l1s"))))
898 (build-system gnu-build-system)
899 ;; FIXME: Add additional inputs once available.
901 `(("pkg-config" ,pkg-config)))
903 `(("alsa-lib" ,alsa-lib)
904 ("cdparanoia" ,cdparanoia)
906 ("fontconfig" ,fontconfig)
907 ("freetype" ,freetype)
908 ;; ("giflib" ,giflib) ; uses QuantizeBuffer, requires version >= 5
911 ("libdvdcss" ,libdvdcss)
912 ("libdvdnav" ,libdvdnav)
914 ("libmpeg2" ,libmpeg2)
915 ("libmpg123" ,mpg123) ; audio codec for MP3
917 ("libtheora" ,libtheora)
918 ("libvdpau" ,libvdpau)
919 ("libvorbis" ,libvorbis)
922 ("libxinerama" ,libxinerama)
924 ("libxxf86dga" ,libxxf86dga)
928 ("pulseaudio" ,pulseaudio)
929 ("python" ,python-wrapper)
935 `(#:tests? #f ; no test target
937 (modify-phases %standard-phases
939 ;; configure does not work followed by "SHELL=..." and
940 ;; "CONFIG_SHELL=..."; set environment variables instead
941 (lambda* (#:key inputs outputs #:allow-other-keys)
942 (let ((out (assoc-ref outputs "out"))
943 (libx11 (assoc-ref inputs "libx11")))
944 (substitute* "configure"
945 (("#! /bin/sh") (string-append "#!" (which "sh"))))
946 (setenv "SHELL" (which "bash"))
947 (setenv "CONFIG_SHELL" (which "bash"))
950 (string-append "--extra-cflags=-I"
951 libx11 "/include") ; to detect libx11
952 "--disable-ffmpeg_a" ; disables bundled ffmpeg
953 (string-append "--prefix=" out)
954 ;; Enable runtime cpu detection where supported,
955 ;; and choose a suitable target.
956 ,@(match (or (%current-target-system)
959 '("--enable-runtime-cpudetection"
960 "--target=x86_64-linux"))
962 '("--enable-runtime-cpudetection"
963 "--target=i686-linux"))
965 '("--target=mips3-linux"))
966 (_ (list (string-append
968 (or (%current-target-system)
969 (nix-system->gnu-triplet
970 (%current-system)))))))
971 "--disable-iwmmxt"))))))))
972 (home-page "https://www.mplayerhq.hu/design7/news.html")
973 (synopsis "Audio and video player")
974 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
975 Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
976 NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
977 SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
978 (license license:gpl2)))
987 "https://github.com/mpv-player/mpv/archive/v" version
991 "1khb7c4fdj1aak46lwyb3lq14w5jpxzws0zp6bdc87ljsvx3yhh7"))
992 (file-name (string-append name "-" version ".tar.gz"))))
993 (build-system waf-build-system)
995 `(("perl" ,perl) ; for zsh completion file
996 ("pkg-config" ,pkg-config)
997 ("python-docutils" ,python-docutils)))
998 ;; Missing features: libguess, Wayland, V4L2
1000 `(("alsa-lib" ,alsa-lib)
1007 ("libbluray" ,libbluray)
1008 ("libcaca" ,libcaca)
1009 ("libbs2b" ,libbs2b)
1010 ("libcdio-paranoia" ,libcdio-paranoia)
1011 ("libdvdread" ,libdvdread)
1012 ("libdvdnav" ,libdvdnav)
1013 ("libjpeg" ,libjpeg)
1015 ("libvdpau" ,libvdpau)
1017 ("libxext" ,libxext)
1018 ("libxinerama" ,libxinerama)
1019 ("libxrandr" ,libxrandr)
1020 ("libxscrnsaver" ,libxscrnsaver)
1022 ;; XXX: lua > 5.2 is not currently supported; see
1023 ;; waftools/checks/custom.py
1027 ("pulseaudio" ,pulseaudio)
1030 ("youtube-dl" ,youtube-dl)
1034 (modify-phases %standard-phases
1036 'configure 'setup-waf
1037 (lambda* (#:key inputs #:allow-other-keys)
1038 (copy-file (assoc-ref inputs "waf") "waf")
1039 (setenv "CC" "gcc"))))
1040 #:configure-flags (list "--enable-libmpv-shared"
1045 "--disable-build-date")
1046 ;; No check function defined.
1048 (home-page "https://mpv.io/")
1049 (synopsis "Audio and video player")
1050 (description "mpv is a general-purpose audio and video player. It is a
1051 fork of mplayer2 and MPlayer. It shares some features with the former
1052 projects while introducing many more.")
1053 (license license:gpl2+)))
1055 (define-public gnome-mpv
1062 (uri (string-append "https://github.com/gnome-mpv/gnome-mpv/releases"
1063 "/download/v" version "/gnome-mpv-" version
1067 "1hn3mpsxbrwf2m0nz4vzji4i6i896y8kqjb9kijqpk04cnrs3fgz"))))
1069 `(("intltool" ,intltool)
1070 ("pkg-config" ,pkg-config)))
1073 ("libepoxy" ,libepoxy)
1075 (build-system glib-or-gtk-build-system)
1076 (home-page "https://github.com/gnome-mpv/gnome-mpv")
1077 (synopsis "GTK+ frontend for the mpv media player")
1078 (description "GNOME MPV is a simple GTK+ frontend for the mpv media player.
1079 GNOME MPV interacts with mpv via the client API exported by libmpv, allowing
1080 access to mpv's powerful playback capabilities.")
1081 (license license:gpl3+)))
1083 (define-public libvpx
1089 (uri (string-append "http://storage.googleapis.com/"
1090 "downloads.webmproject.org/releases/webm/"
1091 name "-" version ".tar.bz2"))
1094 "06d8hqjkfs6wl45qf4pwh1kpbvkx6cwywd5y8d4lgagvjwm0qb0w"))
1095 (patches (search-patches "libvpx-CVE-2016-2818.patch"))))
1096 (build-system gnu-build-system)
1099 (modify-phases %standard-phases
1101 (lambda* (#:key outputs #:allow-other-keys)
1102 (setenv "CONFIG_SHELL" (which "bash"))
1103 (let ((out (assoc-ref outputs "out")))
1105 (string-append "-Wl,-rpath=" out "/lib"))
1106 (zero? (system* "./configure"
1109 ;; Limit size to avoid CVE-2015-1258
1110 "--size-limit=16384x16384"
1111 (string-append "--prefix=" out)))))))
1112 #:tests? #f)) ; no check target
1116 (synopsis "VP8/VP9 video codec")
1117 (description "libvpx is a codec for the VP8/VP9 video compression format.")
1118 (license license:bsd-3)
1119 (home-page "http://www.webmproject.org/")))
1121 (define-public youtube-dl
1124 (version "2017.07.09")
1127 (uri (string-append "https://yt-dl.org/downloads/"
1128 version "/youtube-dl-"
1132 "0phrfby2nk5y5x5173bbg3jcr2ajk849al3zji5y39z39dj36ba2"))))
1133 (build-system python-build-system)
1135 ;; The problem here is that the directory for the man page and completion
1136 ;; files is relative, and for some reason, setup.py uses the
1137 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
1138 ;; So, we need pass the prefix directly. In addition, make sure the Bash
1139 ;; completion file is called 'youtube-dl' rather than
1140 ;; 'youtube-dl.bash-completion'.
1141 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
1142 #:phases (modify-phases %standard-phases
1143 (add-before 'install 'fix-the-data-directories
1144 (lambda* (#:key outputs #:allow-other-keys)
1145 (let ((prefix (assoc-ref outputs "out")))
1146 (mkdir "bash-completion")
1147 (rename-file "youtube-dl.bash-completion"
1148 "bash-completion/youtube-dl")
1149 (substitute* "setup.py"
1150 (("youtube-dl\\.bash-completion")
1151 "bash-completion/youtube-dl")
1153 (string-append "'" prefix "/etc/"))
1155 (string-append "'" prefix "/share/")))))))))
1156 (synopsis "Download videos from YouTube.com and other sites")
1158 "Youtube-dl is a small command-line program to download videos from
1159 YouTube.com and a few more sites.")
1160 (home-page "https://yt-dl.org")
1161 (license license:public-domain)))
1163 (define-public youtube-dl-gui
1165 (name "youtube-dl-gui")
1170 (uri (pypi-uri "Youtube-DLG" version))
1173 "0napxwzgls5ik1bxbp99vly32l23xpc4ng5kr24hfhf21ypjyadb"))))
1174 (build-system python-build-system)
1176 ;; In Guix, wxpython has not yet been packaged for Python 3.
1177 `(#:python ,python-2
1178 ;; This package has no tests.
1181 (modify-phases %standard-phases
1182 (add-before 'build 'patch-source
1183 (lambda* (#:key inputs #:allow-other-keys)
1184 ;; The youtube-dl-gui program lets you configure options. Some of
1185 ;; them are problematic, so we change their defaults.
1186 (substitute* "youtube_dl_gui/optionsmanager.py"
1187 ;; When this is true, the builder process will try (and fail) to
1188 ;; write logs to the builder user's home directory.
1189 (("'enable_log': True") "'enable_log': False")
1190 ;; This determines which youtube-dl program youtube-dl-gui will
1191 ;; run. If we don't set this, then youtube-dl-gui might download
1192 ;; an arbitrary copy from the Internet into the user's home
1193 ;; directory and run it, so let's make sure youtube-dl-gui uses
1194 ;; the youtube-dl from the inputs by default.
1195 (("'youtubedl_path': self.config_path")
1196 (string-append "'youtubedl_path': '"
1197 (assoc-ref inputs "youtube-dl")
1199 ;; When this is True, when youtube-dl-gui is finished downloading
1200 ;; a file, it will try (and possibly fail) to open the directory
1201 ;; containing the downloaded file. This can fail because it
1202 ;; assumes that xdg-open is in PATH. Unfortunately, simply
1203 ;; adding xdg-utils to the propagated inputs is not enough to
1204 ;; make this work, so for now we set the default to False.
1205 (("'open_dl_dir': True") "'open_dl_dir': False"))
1206 ;; The youtube-dl program from the inputs is actually a wrapper
1207 ;; script written in bash, so attempting to invoke it as a python
1208 ;; script will fail.
1209 (substitute* "youtube_dl_gui/downloaders.py"
1210 (("cmd = \\['python', self\\.youtubedl_path\\]")
1211 "cmd = [self.youtubedl_path]"))
1212 ;; Use relative paths for installing data files so youtube-dl-gui
1213 ;; installs the files relative to its prefix in the store, rather
1214 ;; than relative to /. Also, instead of installing data files into
1215 ;; $prefix/usr/share, install them into $prefix/share for
1216 ;; consistency (see: (standards) Directory Variables).
1217 (substitute* "setup.py"
1218 (("= '/usr/share") "= 'share"))
1219 ;; Update get_locale_file() so it finds the installed localization
1221 (substitute* "youtube_dl_gui/utils.py"
1222 (("os\\.path\\.join\\('/usr', 'share'")
1223 (string-append "os.path.join('"
1224 (assoc-ref %outputs "out")
1225 "', 'share'"))))))))
1227 `(("python2-wxpython" ,python2-wxpython)
1228 ("youtube-dl" ,youtube-dl)))
1229 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
1231 "GUI (Graphical User Interface) for @command{youtube-dl}")
1233 "Youtube-dlG is a GUI (Graphical User Interface) for
1234 @command{youtube-dl}. You can use it to download videos from YouTube and any
1235 other site that youtube-dl supports.")
1236 (license license:unlicense)))
1238 (define-public you-get
1245 "https://github.com/soimort/you-get/archive/v"
1247 (file-name (string-append name "-" version ".tar.gz"))
1250 "1pjjv42c9bysnj8s3c6v0g6b00lr7b21y8ypibnzd6z0jxlsq7sz"))))
1251 (build-system python-build-system)
1256 `(("ffmpeg" ,ffmpeg)))
1257 (synopsis "Download videos, audios, or images from Web sites")
1259 "You-Get is a command-line utility to download media contents (videos,
1260 audio, images) from the Web. It can use either mpv or vlc for playback.")
1261 (home-page "https://you-get.org/")
1262 (license license:expat)))
1264 (define-public libbluray
1270 (uri (string-append "https://download.videolan.org/videolan/"
1271 name "/" version "/"
1272 name "-" version ".tar.bz2"))
1275 "0fl5cxfj870rwqmmz3s04wh7wnabb7rnynfj1v3sz37ln8frm7qg"))))
1276 (build-system gnu-build-system)
1278 `(#:configure-flags '("--disable-bdjava-jar")
1280 (modify-phases %standard-phases
1281 (add-before 'build 'fix-dlopen-paths
1282 (lambda* (#:key inputs #:allow-other-keys)
1283 (let ((libaacs (assoc-ref inputs "libaacs"))
1284 (libbdplus (assoc-ref inputs "libbdplus")))
1285 (substitute* "src/libbluray/disc/aacs.c"
1287 (string-append "\"" libaacs "/lib/libaacs\"")))
1288 (substitute* "src/libbluray/disc/bdplus.c"
1290 (string-append "\"" libbdplus "/lib/libbdplus\"")))
1292 (native-inputs `(("pkg-config" ,pkg-config)))
1294 `(("fontconfig" ,fontconfig)
1295 ("freetype" ,freetype)
1296 ("libaacs" ,libaacs)
1297 ("libbdplus" ,libbdplus)
1298 ("libxml2" ,libxml2)))
1299 (home-page "https://www.videolan.org/developers/libbluray.html")
1300 (synopsis "Blu-Ray Disc playback library")
1302 "libbluray is a library designed for Blu-Ray Disc playback for media
1303 players, like VLC or MPlayer.")
1304 (license license:lgpl2.1+)))
1306 (define-public libdvdread
1312 (uri (string-append "https://download.videolan.org/videolan/"
1313 name "/" version "/"
1314 name "-" version ".tar.bz2"))
1317 "0ayqiq0psq18rcp6f5pz82sxsq66v0kwv0y55dbrcg68plnxy71j"))))
1318 (build-system gnu-build-system)
1319 (home-page "http://dvdnav.mplayerhq.hu/")
1320 (synopsis "Library for reading video DVDs")
1322 "Libdvdread provides a simple foundation for reading DVD video
1323 disks. It provides the functionality that is required to access many
1324 DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
1325 authentication and descrambling (if an external libdvdcss library is
1327 (license license:gpl2+)))
1329 (define-public dvdauthor
1336 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
1340 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
1341 (build-system gnu-build-system)
1343 `(("libdvdread" ,libdvdread)
1345 ("imagemagick" ,imagemagick)
1346 ("libxml2" ,libxml2)
1347 ("freetype" ,freetype)))
1349 `(("pkg-config" ,pkg-config)))
1350 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
1351 (description "@command{dvdauthor} will generate a DVD-Video movie from a
1352 MPEG-2 stream containing VOB packets.")
1353 (home-page "http://dvdauthor.sourceforge.net")
1354 (license license:gpl3+)))
1356 (define-public libdvdnav
1362 (uri (string-append "https://download.videolan.org/videolan/"
1363 name "/" version "/"
1364 name "-" version ".tar.bz2"))
1367 "0v8byv5z598k06rqzdmj7739vc86xq3zf79zfr698dib7lz055sh"))))
1368 (build-system gnu-build-system)
1370 `(("pkg-config" ,pkg-config)))
1372 `(("libdvdread" ,libdvdread)))
1373 (home-page "http://dvdnav.mplayerhq.hu/")
1374 (synopsis "Library for video DVD navigation features")
1376 "Libdvdnav is a library for developers of multimedia
1377 applications. It allows easy use of sophisticated DVD navigation features
1378 such as DVD menus, multiangle playback and even interactive DVD games. All
1379 this functionality is provided through a simple API which provides the DVD
1380 playback as a single logical stream of blocks, intermitted by special
1381 dvdnav events to report certain conditions. The main usage of libdvdnav is
1382 a loop regularly calling a function to get the next block, surrounded by
1383 additional calls to tell the library of user interaction. The whole
1384 DVD virtual machine and internal playback states are completely
1386 (license license:gpl2+)))
1388 (define-public libdvdnav-4
1396 "https://download.videolan.org/videolan/libdvdnav/libdvdnav-"
1400 "0wi3gy408c8xj0ism0hckv5jbfh3lg4pmgxv87gbch9jrhp2gjkz"))))
1402 `(("pkg-config" ,pkg-config)
1403 ("autoconf" ,autoconf)
1404 ("automake" ,automake)
1405 ("libtool" ,libtool)))
1411 (zero? (system* "autoreconf" "-vif")))
1412 %standard-phases)))))
1414 (define-public libdvdcss
1420 (uri (string-append "https://download.videolan.org/pub/"
1421 name "/" version "/"
1422 name "-" version ".tar.bz2"))
1425 "0nl45ifc4xcb196snv9d6hinfw614cqpzcqp92dg43c0hickg290"))))
1426 (build-system gnu-build-system)
1427 (home-page "https://www.videolan.org/developers/libdvdcss.html")
1428 (synopsis "Library for accessing DVDs as block devices")
1430 "libdvdcss is a simple library designed for accessing DVDs like a block
1431 device without having to bother about the decryption.")
1432 (license license:gpl2+)))
1434 (define-public srt2vtt
1441 "http://dthompson.us/releases/srt2vtt/srt2vtt-"
1445 "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif"))))
1446 (build-system gnu-build-system)
1448 `(("guile" ,guile-2.0)))
1449 (synopsis "SubRip to WebVTT subtitle converter")
1450 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
1451 for use with HTML5 video.")
1452 (home-page "http://dthompson.us/pages/software/srt2vtt")
1453 (license license:gpl3+)))
1455 (define-public avidemux
1462 "mirror://sourceforge/" name "/" name "/" version "/"
1463 name "_" version ".tar.gz"))
1466 "0nz52yih8sff53inndkh2dba759xjzsh4b8xjww419lcpk0qp6kn"))
1467 (patches (search-patches "avidemux-install-to-lib.patch"))))
1468 (build-system cmake-build-system)
1470 `(("pkg-config" ,pkg-config)))
1471 ;; FIXME: Once packaged, add libraries not found during the build.
1473 `(("alsa-lib" ,alsa-lib)
1474 ("fontconfig" ,fontconfig)
1475 ("freetype" ,freetype)
1476 ("fribidi" ,fribidi)
1481 ("libvdpau" ,libvdpau)
1482 ("libvorbis" ,libvorbis)
1486 ("pulseaudio" ,pulseaudio)
1487 ("python" ,python-wrapper)
1488 ("qt" ,qt) ; FIXME: reenable modular qt after update - requires building
1489 ;("qtbase" ,qtbase) with -std=gnu++11.
1490 ;("qttools" ,qttools)
1496 `(#:tests? #f ; no check target
1498 ;; Make sure files inside the included ffmpeg tarball are
1500 (modify-phases %standard-phases
1501 (add-before 'patch-source-shebangs 'unpack-ffmpeg
1503 (with-directory-excursion "avidemux_core/ffmpeg_package"
1504 (system* "tar" "xf" "ffmpeg-2.7.6.tar.bz2")
1505 (delete-file "ffmpeg-2.7.6.tar.bz2"))))
1506 (add-after 'patch-source-shebangs 'repack-ffmpeg
1508 (with-directory-excursion "avidemux_core/ffmpeg_package"
1509 (substitute* "ffmpeg-2.7.6/configure"
1510 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1511 (system* "tar" "cjf" "ffmpeg-2.7.6.tar.bz2" "ffmpeg-2.7.6"
1512 ;; avoid non-determinism in the archive
1513 "--sort=name" "--mtime=@0"
1514 "--owner=root:0" "--group=root:0")
1515 (delete-file-recursively "ffmpeg-2.7.6"))))
1518 ;; Copy-paste settings from the cmake build system.
1519 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
1520 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))))
1522 (lambda* (#:key inputs outputs #:allow-other-keys)
1524 ((out (assoc-ref outputs "out"))
1525 (lib (string-append out "/lib"))
1527 (sdl (assoc-ref inputs "sdl"))
1529 (lambda* (component srcdir #:optional (args '()))
1530 (let ((builddir (string-append "build_" component)))
1532 (with-directory-excursion builddir
1535 (apply system* "cmake"
1536 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
1537 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
1538 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
1539 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
1540 "\"-Wl,-rpath=" lib "\"")
1541 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
1542 (string-append "-DSDL_INCLUDE_DIR="
1544 (string-append "../" srcdir)
1547 (system* "make" "-j"
1548 (number->string (parallel-job-count)))
1549 (system* "make" "install"))))))))
1551 (and (build_component "core" "avidemux_core")
1552 (build_component "cli" "avidemux/cli")
1553 (build_component "qt4" "avidemux/qt4")
1554 (build_component "plugins_common" "avidemux_plugins"
1555 '("-DPLUGIN_UI=COMMON"))
1556 (build_component "plugins_cli" "avidemux_plugins"
1557 '("-DPLUGIN_UI=CLI"))
1558 (build_component "plugins_qt4" "avidemux_plugins"
1559 '("-DPLUGIN_UI=QT4"))
1560 (build_component "plugins_settings" "avidemux_plugins"
1561 '("-DPLUGIN_UI=SETTINGS")))
1562 ;; Remove .exe and .dll file.
1563 (delete-file-recursively
1564 (string-append out "/share/ADM6_addons")))))
1565 (delete 'install))))
1566 (home-page "http://fixounet.free.fr/avidemux/")
1567 (synopsis "Video editor")
1568 (description "Avidemux is a video editor designed for simple cutting,
1569 filtering and encoding tasks. It supports many file types, including AVI,
1570 DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
1571 can be automated using projects, job queue and powerful scripting
1573 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
1574 ;; Software with various licenses is included, see License.txt.
1575 (license license:gpl2+)))
1577 (define-public vapoursynth
1579 (name "vapoursynth")
1584 "https://github.com/vapoursynth/vapoursynth/archive/R"
1586 (file-name (string-append name "-" version ".tar.gz"))
1589 "1g3hc079jw4mz1cmkv2y28pdb556wqc8ql7iravgh1rg8j3f1zi5"))))
1590 (build-system gnu-build-system)
1592 `(("autoconf" ,autoconf)
1593 ("automake" ,automake)
1594 ("cython" ,python-cython)
1595 ("libtool" ,libtool)
1596 ("pkg-config" ,pkg-config)
1600 `(("ffmpeg" ,ffmpeg)
1602 ("tesseract-ocr" ,tesseract-ocr)
1606 (modify-phases %standard-phases
1610 (zero? (system* "sh" "autogen.sh")))))))
1611 (home-page "http://www.vapoursynth.com/")
1612 (synopsis "Video processing framework")
1613 (description "VapourSynth is a C++ library and Python module for video
1614 manipulation. It aims to be a modern rewrite of Avisynth, supporting
1615 multithreading, generalized colorspaces, per frame properties, and videos with
1617 ;; src/core/cpufeatures only allows x86, ARM or PPC
1618 (supported-systems (delete "mips64el-linux" %supported-systems))
1619 ;; As seen from the source files.
1620 (license license:lgpl2.1+)))
1629 "http://downloads.xvid.org/downloads/xvidcore-"
1630 version ".tar.bz2"))
1633 "1xwbmp9wqshc0ckm970zdpi0yvgqxlqg0s8bkz98mnr8p2067bsz"))))
1634 (build-system gnu-build-system)
1635 (native-inputs `(("yasm" ,yasm)))
1638 (modify-phases %standard-phases
1640 'configure 'pre-configure
1642 (chdir "build/generic")
1643 (substitute* "configure"
1644 (("#! /bin/sh") (string-append "#!" (which "sh")))))))
1645 ;; No 'check' target.
1647 (home-page "https://www.xvid.com/")
1648 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
1649 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
1650 codec library. It uses ASP features such as b-frames, global and quarter
1651 pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
1652 and custom quantization matrices.")
1653 (license license:gpl2+)))
1655 (define-public livestreamer
1657 (name "livestreamer")
1662 "https://github.com/chrippa/livestreamer/archive/v"
1664 (file-name (string-append "livestreamer-" version ".tar.gz"))
1667 "1fp3d3z2grb1ls97smjkraazpxnvajda2d1g1378s6gzmda2jvjd"))))
1668 (build-system python-build-system)
1670 '(#:tests? #f)) ; tests rely on external web servers
1672 `(("python-requests" ,python-requests)))
1673 (synopsis "Internet video stream viewer")
1674 (description "Livestreamer is a command-line utility that extracts streams
1675 from various services and pipes them into a video playing application.")
1676 (home-page "http://livestreamer.io/")
1677 (license license:bsd-2)))
1685 (uri (string-append "https://github.com/mltframework/mlt/"
1686 "archive/v" version ".tar.gz"))
1687 (file-name (string-append name "-" version ".tar.gz"))
1690 "10m3ry0b2pvqx3bk34qh5dq337nn8pkc2gzfyhsj4nv9abskln47"))))
1691 (build-system gnu-build-system)
1693 `(#:tests? #f ; no tests
1694 #:make-flags '("CC=gcc")
1696 (list "--enable-gpl3"
1699 (modify-phases %standard-phases
1701 'configure 'override-LDFLAGS
1702 (lambda* (#:key outputs #:allow-other-keys)
1703 (substitute* "config.mak"
1705 (string-append "LDFLAGS+=-Wl,-rpath="
1706 (assoc-ref outputs "out")
1710 `(("alsa-lib" ,alsa-lib)
1712 ("libxml2" ,libxml2)
1715 ("libsamplerate" ,libsamplerate)
1716 ("pulseaudio" ,pulseaudio)
1720 `(("pkg-config" ,pkg-config)))
1721 (home-page "https://www.mltframework.org/")
1722 (synopsis "Author, manage, and run multitrack audio/video compositions")
1724 "MLT is a multimedia framework, designed and developed for television
1725 broadcasting. It provides a toolkit for broadcasters, video editors, media
1726 players, transcoders, web streamers and many more types of applications. The
1727 functionality of the system is provided via an assortment of ready to use
1728 tools, XML authoring components, and an extensible plug-in based API.")
1729 (license license:lgpl2.1+)))
1731 (define-public v4l-utils
1737 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
1738 "/v4l-utils-" version ".tar.bz2"))
1741 "03g2b4rivrilimcp57mwrlsa3qvrxmk4sza08mygwmqbvcnic606"))))
1742 (build-system gnu-build-system)
1745 (list (string-append "--with-udevdir="
1746 (assoc-ref %outputs "out")
1748 "CXXFLAGS=-std=gnu++11")))
1751 ("pkg-config" ,pkg-config)))
1753 `(("alsa-lib" ,alsa-lib)
1755 ("libjpeg" ,libjpeg)
1759 (synopsis "Realtime video capture utilities for Linux")
1760 (description "The v4l-utils provide a series of libraries and utilities to
1761 be used for realtime video capture via Linux-specific APIs.")
1762 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
1763 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
1764 (license (list license:lgpl2.1+ license:gpl2))))
1772 (uri (string-append "https://github.com/jp9000/obs-studio"
1773 "/archive/" version ".tar.gz"))
1774 (file-name (string-append name "-" version ".tar.gz"))
1777 "02pbiyvf5x0zh448h5rpmyn33qnsqk694xxlyns83mdi74savyqw"))))
1778 (build-system cmake-build-system)
1780 `(#:tests? #f)) ; no tests
1782 `(("pkg-config" ,pkg-config)))
1784 `(("alsa-lib" ,alsa-lib)
1788 ("fontconfig" ,fontconfig)
1789 ("freetype" ,freetype)
1791 ("jansson" ,jansson)
1792 ("libx264" ,libx264)
1793 ("libxcomposite" ,libxcomposite)
1795 ("pulseaudio" ,pulseaudio)
1797 ("qtx11extras" ,qtx11extras)
1799 ("v4l-utils" ,v4l-utils)
1801 (synopsis "Live streaming software")
1802 (description "Open Broadcaster Software provides a graphical interface for
1803 video recording and live streaming. OBS supports capturing audio and video
1804 from many input sources such as webcams, X11 (for screencasting), PulseAudio,
1806 (home-page "https://obsproject.com")
1807 (supported-systems '("x86_64-linux" "i686-linux"))
1808 (license license:gpl2+)))
1810 (define-public libvdpau
1817 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
1818 name "-" version ".tar.bz2"))
1821 "0dnpb0yh7v6rvckx82kxg045rd9rbsw25wjv7ad5n8h94s9h2yl5"))))
1822 (build-system gnu-build-system)
1824 `(("pkg-config" ,pkg-config)))
1826 `(("dri2proto" ,dri2proto)
1827 ("libx11" ,libx11 "out")
1828 ("libxext" ,libxext)))
1829 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
1830 (synopsis "Video Decode and Presentation API")
1831 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
1832 provides an interface to video decode acceleration and presentation hardware
1833 present in modern GPUs.")
1834 (license (license:x11-style "file://COPYING"))))
1836 (define-public vdpauinfo
1843 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
1844 name "-" version ".tar.gz"))
1847 "1i2b0k9h8r0lnxlrkgqzmrjakgaw3f1ygqqwzx8w6676g85rcm20"))))
1848 (build-system gnu-build-system)
1850 `(("pkg-config" ,pkg-config)
1851 ("libx11" ,libx11)))
1853 `(("libvdpau" ,libvdpau)))
1854 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
1855 (synopsis "Tool to query the capabilities of a VDPAU implementation")
1856 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
1858 (license (license:x11-style "file://COPYING"))))
1860 (define-public recordmydesktop
1862 (name "recordmydesktop")
1866 (uri (string-append "mirror://sourceforge/" name "/" name "/"
1867 version "/recordmydesktop-" version ".tar.gz"))
1870 "133kkl5j0r877d41bzj7kj0vf3xm8x80yyx2n8nqxrva304f58ik"))))
1871 (build-system gnu-build-system)
1872 (inputs `(("popt" ,popt)
1877 ("libxfixes" ,libxfixes)
1878 ("libxdamage" ,libxdamage)
1879 ("libxext" ,libxext)
1880 ("alsa-lib" ,alsa-lib)
1881 ("libvorbis" ,libvorbis)
1882 ("libtheora" ,libtheora)))
1883 (home-page "http://recordmydesktop.sourceforge.net/")
1884 (synopsis "Desktop session video recorder")
1886 "recordMyDesktop is a command-line tool that captures the activity in
1887 your graphical desktop and encodes it as a video. This is a useful tool for
1888 making @dfn{screencasts}.")
1889 (license license:gpl2+)))
1891 (define-public libsmpeg
1898 (url "svn://svn.icculus.org/smpeg/trunk/")
1899 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
1900 (file-name (string-append name "-" version "-checkout"))
1903 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
1904 (build-system gnu-build-system)
1906 `(#:phases (modify-phases %standard-phases
1907 (add-after 'unpack 'autogen.sh
1909 (zero? (system* "sh" "autogen.sh")))))))
1911 `(("autoconf" ,autoconf)
1912 ("automake" ,automake)))
1915 (home-page "http://icculus.org/smpeg/")
1916 (synopsis "SDL MPEG decoding library")
1918 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
1919 with sound support. Video playback is based on the ubiquitous Berkeley MPEG
1920 player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
1921 library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
1922 and MPEG system streams.")
1923 (license (list license:expat
1928 (define-public libbdplus
1935 (uri (string-append "ftp://ftp.videolan.org/pub/videolan/libbdplus/"
1936 version "/" name "-" version ".tar.bz2"))
1938 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
1940 `(("libgcrypt" ,libgcrypt)))
1941 (build-system gnu-build-system)
1942 (home-page "https://www.videolan.org/developers/libbdplus.html")
1943 (synopsis "Library for decrypting certain Blu-Ray discs")
1944 (description "libbdplus is a library which implements the BD+ System
1946 (license license:lgpl2.1+)))
1948 (define-public libaacs
1955 (uri (string-append "ftp://ftp.videolan.org/pub/videolan/libaacs/"
1956 version "/" name "-" version ".tar.bz2"))
1958 (base32 "1kms92i0c7i1yl659kqjf19lm8172pnpik5lsxp19xphr74vvq27"))))
1960 `(("libgcrypt" ,libgcrypt)))
1964 (build-system gnu-build-system)
1965 (home-page "https://www.videolan.org/developers/libaacs.html")
1966 (synopsis "Library for decrypting certain Blu-Ray discs")
1967 (description "libaacs is a library which implements the Advanced Access
1968 Content System specification.")
1969 (license license:lgpl2.1+)))
1971 (define-public mps-youtube
1973 (name "mps-youtube")
1978 (uri (string-append "https://github.com/mps-youtube/mps-youtube/"
1979 "archive/v" version ".tar.gz"))
1980 (file-name (string-append name "-" version ".tar.gz"))
1983 "1s7h35yx6f0szf8mm8612ic913w3v05m2kwphjfcxnpq0ammhyci"))))
1984 (build-system python-build-system)
1986 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
1987 ;; test suite results differ depending on the country and also introduce
1988 ;; non-determinism in the tests.
1989 ;; https://github.com/mps-youtube/mps-youtube/issues/556
1992 `(("python-pafy" ,python-pafy)
1993 ("python-pygobject" ,python-pygobject))) ; For mpris2 support
1994 (home-page "https://github.com/mps-youtube/mps-youtube")
1995 (synopsis "Terminal based YouTube player and downloader")
1997 "@code{mps-youtube} is based on mps, a terminal based program to
1998 search, stream and download music. This implementation uses YouTube as
1999 a source of content and can play and download video as well as audio.
2000 It can use either mpv or mplayer for playback, and for conversion of
2001 formats ffmpeg or libav is used. Users should install one of the
2002 supported players in addition to this package.")
2003 (license license:gpl3+)))
2005 (define-public handbrake
2011 (uri (string-append "https://handbrake.fr/rotation.php?file="
2012 "HandBrake-" version ".tar.bz2"))
2013 (file-name (string-append "handbrake-" version ".tar.bz2"))
2016 "1w720y3bplkz187wgvy4a4xm0vpppg45mlni55l6yi8v2bfk14pv"))
2017 (patches (search-patches "handbrake-pkg-config-path.patch"))
2018 (modules '((guix build utils)))
2020 ;; Remove bundled libraries and source not necessary for
2021 ;; running under a GNU environment.
2023 (for-each delete-file-recursively '("contrib" "macosx" "win"))
2025 (build-system glib-or-gtk-build-system)
2027 `(("automake" ,automake) ;gui subpackage must be bootstrapped
2028 ("autoconf" ,autoconf)
2029 ("curl" ,curl) ;not actually used, but tested for
2030 ("intltool" ,intltool)
2031 ("libtool" ,libtool)
2032 ("pkg-config" ,pkg-config)
2033 ("python" ,python-2))) ;for configuration
2036 ("dbus-glib" ,dbus-glib)
2038 ("fontconfig" ,fontconfig)
2039 ("freetype" ,freetype)
2041 ("gstreamer" ,gstreamer)
2042 ("gst-plugins-base" ,gst-plugins-base)
2046 ("libbluray" ,libbluray)
2047 ("libdvdnav" ,libdvdnav)
2048 ("libdvdread" ,libdvdread)
2049 ("libgudev" ,libgudev)
2050 ("libmpeg2" ,libmpeg2)
2051 ("libnotify" ,libnotify)
2053 ("libsamplerate" ,libsamplerate)
2054 ("libtheora" ,libtheora)
2055 ("libvorbis" ,libvorbis)
2057 ("libxml2" ,libxml2)
2058 ("libx264" ,libx264)
2062 `(#:tests? #f ;tests require Ruby and claim to be unsupported
2064 (modify-phases %standard-phases
2065 (add-before 'patch-source-shebangs 'bootstrap-gtk
2066 ;; Run bootstrap ahead of time so that shebangs get patched.
2068 (setenv "CONFIG_SHELL" (which "sh"))
2069 (setenv "NOCONFIGURE" "1")
2070 ;; Patch the Makefile so that it doesn't bootstrap again.
2071 (substitute* "gtk/module.rules"
2072 ((".*autogen\\.sh.*") ""))
2073 (zero? (system* "sh" "./gtk/autogen.sh"))))
2074 (add-before 'configure 'disable-contrib
2076 (substitute* "make/include/main.defs"
2077 ;; Disable unconditional inclusion of some "contrib"
2078 ;; libraries (ffmpeg, libvpx, libdvdread, libdvdnav,
2079 ;; and libbluray), which would lead to fetching and
2080 ;; building of these libraries. Use our own instead.
2081 (("MODULES \\+= contrib") "# MODULES += contrib"))
2083 (add-before 'configure 'fix-x265-linking
2085 (substitute* "test/module.defs"
2086 ;; Fix missing library during linking error
2087 (("TEST.GCC.l =") "TEST.GCC.l = x265"))
2090 (lambda* (#:key outputs configure-flags #:allow-other-keys)
2091 ;; 'configure' is not an autoconf-generated script, and
2092 ;; errors on unrecognized arguments,
2093 ;; e.g. --enable-fast-install
2094 (let ((out (assoc-ref outputs "out")))
2095 (zero? (apply system* "./configure"
2096 (string-append "--prefix=" out)
2097 (or configure-flags '()))))))
2098 (add-after 'configure 'chdir-build
2099 (lambda _ (chdir "./build") #t)))))
2100 (home-page "https://handbrake.fr")
2101 (synopsis "Video transcoder")
2103 "HandBrake is a tool for converting video from any format to a selection
2104 of modern, widely supported codecs.")
2105 ;; Most under GPL version 2 or later, and portions under BSD 3 Clause
2106 (license (list license:gpl2+ license:bsd-3))))
2108 (define-public openh264
2114 (uri (string-append "https://github.com/cisco/"
2115 name "/archive/v" version ".tar.gz"))
2116 (file-name (string-append name "-" version ".tar.gz"))
2119 "1ix2fhk62i4q4kbnkl0gfk4x53vxqavsn0pck1pashr566zhglv5"))))
2120 (build-system gnu-build-system)
2123 ("python" ,python)))
2125 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2127 #:test-target "test"
2128 #:phases (modify-phases %standard-phases
2129 ;; no configure script
2130 (delete 'configure))))
2131 (home-page "http://www.openh264.org/")
2132 (synopsis "H264 decoder library")
2134 "Openh264 is a library which can decode H264 video streams.")
2135 (license license:bsd-2)))
2137 (define-public libmp4v2
2144 ;; XXX: The new location of upstream is uncertain and will become relevant the
2145 ;; moment when the googlecode archive shuts down. It is past the date it
2146 ;; should've been turned off. I tried to communicate with upstream, but this
2147 ;; wasn't very responsive and not very helpful. The short summary is, it is
2148 ;; chaos when it comes to the amount of forks and only time will tell where
2149 ;; the new upstream location is.
2150 (uri (string-append "https://storage.googleapis.com/google-"
2151 "code-archive-downloads/v2/"
2152 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
2153 (file-name (string-append name "-" version ".tar.bz2"))
2156 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
2157 (build-system gnu-build-system)
2159 "static")) ; 3.7MiB .a file
2162 (modify-phases %standard-phases
2163 (add-after 'unpack 'remove-dates
2165 ;; Make the build reproducible.
2166 (substitute* "configure"
2167 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
2168 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
2170 (add-after 'install 'move-static-libraries
2171 (lambda* (#:key outputs #:allow-other-keys)
2172 ;; Move static libraries to the "static" output.
2173 (let* ((out (assoc-ref outputs "out"))
2174 (lib (string-append out "/lib"))
2175 (static (assoc-ref outputs "static"))
2176 (slib (string-append static "/lib")))
2178 (for-each (lambda (file)
2179 (install-file file slib)
2181 (find-files lib "\\.a$"))
2184 `(("help2man" ,help2man)
2185 ("dejagnu" ,dejagnu)))
2186 (home-page "https://code.google.com/archive/p/mp4v2/")
2187 (synopsis "API to create and modify mp4 files")
2189 "The MP4v2 library provides an API to create and modify mp4 files as defined by
2190 ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
2191 file format that has been used as a multimedia file format in a variety of platforms and
2192 applications. It is a very powerful and extensible format that can accommodate
2193 practically any type of media.")
2194 (license license:mpl1.1)))
2196 (define-public libmediainfo
2198 (name "libmediainfo")
2202 (uri (string-append "https://mediaarea.net/download/source/"
2204 name "_" version ".tar.bz2"))
2207 "1kchh6285b07z5nixv619hc9gml2ysdayicdiv30frrlqiyxqw4b"))))
2208 ;; TODO add a Big Buck Bunny webm for tests.
2210 `(("autoconf" ,autoconf)
2211 ("automake" ,automake)
2212 ("libtool" ,libtool)
2213 ("pkg-config" ,pkg-config)
2215 ("tinyxml2" ,tinyxml2)
2217 ("libzen" ,libzen)))
2218 (build-system gnu-build-system)
2220 '(#:tests? #f ; see above TODO
2222 ;; build scripts not in root of archive
2223 (modify-phases %standard-phases
2224 (add-before 'configure 'pre-configure
2226 (chdir "Project/GNU/Library")))
2227 (add-before 'configure 'autogen
2229 (zero? (system* "./autogen.sh")))))))
2230 (home-page "https://mediaarea.net/en/MediaInfo")
2231 (synopsis "Library for retrieving media metadata")
2232 (description "MediaInfo is a library used for retrieving technical
2233 information and other metadata about audio or video files. A non-exhaustive
2234 list of the information MediaInfo can retrieve from media files include:
2237 @item General: title, author, director, album, track number, date, duration...
2238 @item Video: codec, aspect, fps, bitrate...
2239 @item Audio: codec, sample rate, channels, language, bitrate...
2240 @item Text: language of subtitle
2241 @item Chapters: number of chapters, list of chapters
2244 MediaInfo supports the following formats:
2247 @item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
2248 MPEG-2, MPEG-4, DVD (VOB)...
2249 @item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
2250 @item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
2251 @item Subtitles: SRT, SSA, ASS, SAMI...
2253 (license license:bsd-2)))
2255 ;; TODO also have a GUI version available
2256 (define-public mediainfo
2262 (uri (string-append "https://mediaarea.net/download/source/"
2263 name "/" version "/"
2264 name "_" version ".tar.bz2"))
2267 "0dy51a3i79jppmg1gi4f6h7jx4hcgnkmfim4d7d3gmnlbkjh8anv"))))
2269 `(("autoconf" ,autoconf)
2270 ("automake" ,automake)
2271 ("libtool" ,libtool)
2272 ("pkg-config" ,pkg-config)
2274 ("libmediainfo", libmediainfo)
2275 ("libzen" ,libzen)))
2276 (build-system gnu-build-system)
2278 '(#:tests? #f ; lacks tests
2280 ;; build scripts not in root of archive
2281 (modify-phases %standard-phases
2282 (add-before 'configure 'pre-configure
2284 (chdir "Project/GNU/CLI")))
2285 (add-before 'configure 'autogen
2287 (zero? (system* "./autogen.sh")))))))
2288 (home-page "https://mediaarea.net/en/MediaInfo")
2289 (synopsis "Utility for reading media metadata")
2290 (description "MediaInfo is a utility used for retrieving technical
2291 information and other metadata about audio or video files. It supports the
2292 many codecs and formats supported by libmediainfo.")
2293 (license license:bsd-2)))
2295 (define-public livemedia-utils
2297 (name "livemedia-utils")
2298 (version "2017.06.04")
2302 "https://download.videolan.org/contrib/live555/live."
2306 "0xf3vynxqpxpd762zni0jkblnjlgbqxjx99m83m7gqx6zriph271"))))
2307 (build-system gnu-build-system)
2309 '(#:tests? #f ; no tests
2310 #:make-flags (list "CC=gcc"
2311 (string-append "LDFLAGS=-Wl,-rpath="
2312 (assoc-ref %outputs "out") "/lib")
2313 (string-append "PREFIX="
2314 (assoc-ref %outputs "out")))
2315 #:phases (modify-phases %standard-phases
2316 (add-before 'configure 'fix-makefiles-generation
2318 (substitute* "genMakefiles"
2323 (zero? (system* "./genMakefiles"
2324 "linux-with-shared-libraries")))))))
2325 (home-page "http://www.live555.com/liveMedia/")
2326 (synopsis "Set of C++ libraries for multimedia streaming")
2327 (description "This code forms a set of C++ libraries for multimedia
2328 streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
2329 can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
2330 JPEG video, and several audio codecs. They can easily be extended to support
2331 additional (audio and/or video) codecs, and can also be used to build basic
2332 RTSP or SIP clients and servers.")
2333 (license license:lgpl3+)))
2335 (define-public libdvbpsi
2342 "https://download.videolan.org/pub/libdvbpsi/"
2343 version "/libdvbpsi-" version ".tar.bz2"))
2346 "0824r08kaspbrrg2dd5d46s475zb7j59brqkm2y6x3mdsnpng0yn"))))
2347 (build-system gnu-build-system)
2348 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
2349 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
2351 (description "libdvbpsi is a simple library designed for decoding and
2352 generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
2353 and ITU-T H.222.0.")
2354 (license license:lgpl2.1)))