1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2014, 2015, 2016 David Thompson <davet@gnu.org>
4 ;;; Copyright © 2014, 2015, 2016, 2018 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
6 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2015 Andy Patterson <ajpatter@uwaterloo.ca>
8 ;;; Copyright © 2015, 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Alex Vong <alexvong1995@gmail.com>
10 ;;; Copyright © 2016, 2017 Alex Griffin <a@ajgrf.com>
11 ;;; Copyright © 2016 Kei Kebreau <kkebreau@posteo.net>
12 ;;; Copyright © 2016 Dmitry Nikolaev <cameltheman@gmail.com>
13 ;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca>
14 ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
15 ;;; Copyright © 2016, 2018, 2019, 2020 Eric Bavier <bavier@posteo.net>
16 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
17 ;;; Copyright © 2017 Feng Shu <tumashu@163.com>
18 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
19 ;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com>
20 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
21 ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
22 ;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org>
23 ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
24 ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com>
25 ;;; Copyright © 2018 Roel Janssen <roel@gnu.org>
26 ;;; Copyright © 2018, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
27 ;;; Copyright © 2018, 2019, 2020 Pierre Neidhardt <mail@ambrevar.xyz>
28 ;;; Copyright © 2018, 2019, 2020 Leo Famulari <leo@famulari.name>
29 ;;; Copyright © 2018 Brendan Tildesley <mail@brendan.scot>
30 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
31 ;;; Copyright © 2018 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
32 ;;; Copyright © 2018 Mark Meyer <mark@ofosos.org>
33 ;;; Copyright © 2018 Gábor Boskovit <boskovits@gmail.com>
34 ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
35 ;;; Copyright © 2019 Timo Eisenmann <eisenmann@fn.de>
36 ;;; Copyright © 2019 Arne Babenhauserheide <arne_bab@web.de>
37 ;;; Copyright © 2019 Riku Viitanen <riku.viitanen@protonmail.com>
38 ;;; Copyright © 2020 Oleg Pykhalov <go.wigust@gmail.com>
39 ;;; Copyright © 2020 Josh Holland <josh@inv.alid.pw>
40 ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
41 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
42 ;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net>
43 ;;; Copyright © 2020 Alex McGrath <amk@amk.ie>
44 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
45 ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
46 ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org>
48 ;;; This file is part of GNU Guix.
50 ;;; GNU Guix is free software; you can redistribute it and/or modify it
51 ;;; under the terms of the GNU General Public License as published by
52 ;;; the Free Software Foundation; either version 3 of the License, or (at
53 ;;; your option) any later version.
55 ;;; GNU Guix is distributed in the hope that it will be useful, but
56 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
57 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
58 ;;; GNU General Public License for more details.
60 ;;; You should have received a copy of the GNU General Public License
61 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
63 (define-module (gnu packages video)
64 #:use-module (ice-9 match)
65 #:use-module (srfi srfi-1)
66 #:use-module (srfi srfi-26)
67 #:use-module ((guix licenses) #:prefix license:)
68 #:use-module (guix utils)
69 #:use-module (guix packages)
70 #:use-module (guix download)
71 #:use-module (guix git-download)
72 #:use-module (guix svn-download)
73 #:use-module (guix build-system cargo)
74 #:use-module (guix build-system cmake)
75 #:use-module (guix build-system copy)
76 #:use-module (guix build-system gnu)
77 #:use-module (guix build-system glib-or-gtk)
78 #:use-module (guix build-system meson)
79 #:use-module (guix build-system perl)
80 #:use-module (guix build-system python)
81 #:use-module (guix build-system waf)
82 #:use-module (guix build-system trivial)
83 #:use-module (gnu packages)
84 #:use-module (gnu packages algebra)
85 #:use-module (gnu packages assembly)
86 #:use-module (gnu packages audio)
87 #:use-module (gnu packages autotools)
88 #:use-module (gnu packages avahi)
89 #:use-module (gnu packages backup)
90 #:use-module (gnu packages base)
91 #:use-module (gnu packages bison)
92 #:use-module (gnu packages boost)
93 #:use-module (gnu packages cdrom)
94 #:use-module (gnu packages check)
95 #:use-module (gnu packages cmake)
96 #:use-module (gnu packages compression)
97 #:use-module (gnu packages cpp)
98 #:use-module (gnu packages crates-io)
99 #:use-module (gnu packages curl)
100 #:use-module (gnu packages dejagnu)
101 #:use-module (gnu packages dns)
102 #:use-module (gnu packages docbook)
103 #:use-module (gnu packages documentation)
104 #:use-module (gnu packages elf)
105 #:use-module (gnu packages file)
106 #:use-module (gnu packages flex)
107 #:use-module (gnu packages fonts)
108 #:use-module (gnu packages fontutils)
109 #:use-module (gnu packages freedesktop)
110 #:use-module (gnu packages fribidi)
111 #:use-module (gnu packages gettext)
112 #:use-module (gnu packages ghostscript)
113 #:use-module (gnu packages gl)
114 #:use-module (gnu packages glib)
115 #:use-module (gnu packages guile)
116 #:use-module (gnu packages gnome)
117 #:use-module (gnu packages gnunet)
118 #:use-module (gnu packages gnupg)
119 #:use-module (gnu packages gstreamer)
120 #:use-module (gnu packages gtk)
121 #:use-module (gnu packages image)
122 #:use-module (gnu packages imagemagick)
123 #:use-module (gnu packages iso-codes)
124 #:use-module (gnu packages libidn)
125 #:use-module (gnu packages libreoffice)
126 #:use-module (gnu packages libusb)
127 #:use-module (gnu packages linux)
128 #:use-module (gnu packages lua)
129 #:use-module (gnu packages m4)
130 #:use-module (gnu packages man)
131 #:use-module (gnu packages markup)
132 #:use-module (gnu packages maths)
133 #:use-module (gnu packages mp3)
134 #:use-module (gnu packages ncurses)
135 #:use-module (gnu packages networking)
136 #:use-module (gnu packages ocr)
137 #:use-module (gnu packages perl)
138 #:use-module (gnu packages perl-check)
139 #:use-module (gnu packages perl-web)
140 #:use-module (gnu packages photo)
141 #:use-module (gnu packages pkg-config)
142 #:use-module (gnu packages popt)
143 #:use-module (gnu packages pretty-print)
144 #:use-module (gnu packages protobuf)
145 #:use-module (gnu packages pulseaudio)
146 #:use-module (gnu packages python)
147 #:use-module (gnu packages python-crypto)
148 #:use-module (gnu packages python-web)
149 #:use-module (gnu packages python-xyz)
150 #:use-module (gnu packages qt)
151 #:use-module (gnu packages rdesktop)
152 #:use-module (gnu packages ruby)
153 #:use-module (gnu packages rust-apps)
154 #:use-module (gnu packages samba)
155 #:use-module (gnu packages sdl)
156 #:use-module (gnu packages serialization)
157 #:use-module (gnu packages shells)
158 #:use-module (gnu packages sqlite)
159 #:use-module (gnu packages ssh)
160 #:use-module (gnu packages swig)
161 #:use-module (gnu packages texinfo)
162 #:use-module (gnu packages textutils)
163 #:use-module (gnu packages tls)
164 #:use-module (gnu packages time)
165 #:use-module (gnu packages upnp)
166 #:use-module (gnu packages vulkan)
167 #:use-module (gnu packages web)
168 #:use-module (gnu packages webkit)
169 #:use-module (gnu packages wxwidgets)
170 #:use-module (gnu packages xdisorg)
171 #:use-module (gnu packages xiph)
172 #:use-module (gnu packages xml)
173 #:use-module (gnu packages xorg))
175 (define-public svt-hevc
184 (url "https://github.com/OpenVisualCloud/SVT-HEVC.git")
185 (commit (string-append "v" version))))
186 (file-name (git-file-name name version))
188 (base32 "1sqh3dciqm2p1b66kngcpxqy5fx3ramxlxy8gfcbdwn2i3rsqhs7"))))
189 (build-system cmake-build-system)
191 `(#:tests? #f)) ; Test script is stand-alone
194 (synopsis "SVT HEVC encoder")
195 (description "Scalable Video Technology (SVT) is a software-based video
196 coding technology that is highly optimized for Intel's Xeon processors. Using
197 the SVT-HEVC encoder, it is possible to spread video encoding processing across
198 multiple Intel's Xeon processors to achieve a real advantage of processing
200 (home-page "https://01.org/svt")
201 (license (license:non-copyleft "file:///LICENSE.md"))))
203 (define-public mediasdk
212 (url "https://github.com/Intel-Media-SDK/MediaSDK.git")
213 (commit (string-append "intel-" name "-" version))))
214 (file-name (git-file-name name version))
216 (base32 "0blwcxr5j8762nylx2cxrq0h53bpgnk859dbs6crq4wr9fcxlx9z"))))
217 (build-system cmake-build-system)
222 "-DENABLE_X11_DRI3=ON"
223 "-DENABLE_WAYLAND=ON"
224 "-DENABLE_TEXTLOG=ON"
228 (string-append "-DCMAKE_EXE_LINKER_FLAGS=-Wl,-rpath="
229 (assoc-ref %outputs "out") "/lib"))))
231 `(("pkg-config" ,pkg-config)
232 ("python" ,python-wrapper)))
236 ("pciaccess" ,libpciaccess)
239 (synopsis "Intel Media SDK")
240 (description "MediaSDK provides a plain C API to access hardware-accelerated
241 video decode, encode and filtering on Intel's Gen graphics hardware platforms.")
242 (home-page "http://mediasdk.intel.com/")
243 (license (license:non-copyleft "file:///LICENSE"))))
245 (define-public schroedinger
247 (name "schroedinger")
253 (string-append "https://launchpad.net/" name "/trunk/" version
254 "/+download/" name "-" version ".tar.gz"))
256 (base32 "04prr667l4sn4zx256v1z36a0nnkxfdqyln48rbwlamr6l3jlmqy"))))
257 (build-system gnu-build-system)
258 (outputs '("out" "doc"))
261 (modify-phases %standard-phases
262 (add-after 'install 'move-docs
263 (lambda* (#:key outputs #:allow-other-keys)
264 (let* ((out (assoc-ref outputs "out"))
265 (doc (assoc-ref outputs "doc")))
266 (mkdir-p (string-append doc "/share"))
268 (string-append out "/share/gtk-doc")
269 (string-append doc "/share/gtk-doc"))
274 ("pkg-config" ,pkg-config)))
280 (synopsis "Dirac video codec")
281 (description "Schroedinger is a project implementing the Dirac video codec in
282 ANSI C code. It is meant to be highly optimized and portable. It is developed
283 as a joint effort between the BBC and Fluendo.")
284 (home-page "https://launchpad.net/schroedinger")
286 ;; This library is licensed under 4 different licenses,
287 ;; and you can choose to use it under the terms of any one of them.
294 (define-public libquicktime
296 (name "libquicktime")
302 (string-append "https://sourceforge.net/projects/" name "/files/"
303 name "/" version "/" name "-" version ".tar.gz"))
305 (base32 "0s3kshzl3zfjw3phzv73r91fkr9z8q8kc3dhsys4f4xk6ff3alqw"))
307 (search-patches "libquicktime-ffmpeg.patch"))))
308 (build-system gnu-build-system)
310 `(("gettext" ,gettext-minimal)
312 ("pkg-config" ,pkg-config)))
319 ("libjpeg" ,libjpeg-turbo)
321 ("libvorbis" ,libvorbis)
323 ("schroedinger" ,schroedinger)
328 (synopsis "Quick Time Library")
329 (description "The goal of this project is to enhance the quicktime4linux
331 (home-page "http://libquicktime.sourceforge.net/")
332 (license license:lgpl2.1+)))
334 (define-public mjpegtools
342 (string-append "https://sourceforge.net/projects/" name "/files/"
343 name "/" version "/" name "-" version ".tar.gz"))
345 (base32 "0kvhxr5hkabj9v7ah2rzkbirndfqdijd9hp8v52c1z6bxddf019w"))))
346 (build-system gnu-build-system)
351 ("libquicktime" ,libquicktime)
353 (synopsis "Tools for handling MPEG")
354 (description "Mjpeg tools is a suite of programs which support video capture,
355 editing, playback, and compression to MPEG of MJPEG video. Edit, play and
356 compression software is hardware independent.")
357 (home-page "http://mjpeg.sourceforge.net/")
358 (license license:gpl2+)))
360 (define-public libmms
368 (string-append "https://sourceforge.net/projects/" name "/files/"
369 name "/" version "/" name "-" version ".tar.gz"))
371 (base32 "0kvhxr5hkabj9v7ah2rzkbirndfqdijd9hp8v52c1z6bxddf019w"))))
372 (build-system gnu-build-system)
373 (synopsis "MMS stream protocol library")
374 (description "Libmms is a library for streaming media files using the mmst
375 and mmsh protocols.")
376 (home-page "https://sourceforge.net/projects/libmms/")
377 (license license:lgpl2.1+)))
379 (define-public libvideogfx
388 (url "https://github.com/farindk/libvideogfx.git")
389 (commit (string-append "v" version))))
390 (file-name (git-file-name name version))
392 (base32 "154b0j8cfg879pg08xcbwvbz8z9nrfnyj31i48vxir1psas70ynq"))))
393 (build-system gnu-build-system)
396 (modify-phases %standard-phases
397 (add-after 'unpack 'fix-build-errors
399 (substitute* "libvideogfx/graphics/fileio/ffmpeg.cc"
400 (("av_close_input_file\\(")
401 "avformat_close_input(&"))
402 (substitute* "libvideogfx/graphics/fileio/png.cc"
403 (("is != NULL") "is.good()"))
406 `(("autoconf" ,autoconf)
407 ("automake" ,automake)
409 ("pkg-config" ,pkg-config)))
411 `(("ffmpeg" ,ffmpeg-2.8)
412 ("jpeg" ,libjpeg-turbo)
416 (synopsis "Video processing library")
417 (description "LibVideoGfx is a C++ library for low-level video processing.
418 It aims at speeding up the development process for image and video processing
419 applications by providing high-level classes for commonly required tasks.")
420 (home-page "https://dirk-farin.net/software/libvideogfx/index.html")
421 (license license:lgpl2.1+)))
423 (define-public libde265
432 (url "https://github.com/strukturag/libde265.git")
433 (commit (string-append "v" version))))
434 (file-name (git-file-name name version))
436 (base32 "1qisj8ryzbknam3hk81rq70fsd9mcpxm898bqygvbsmbwyvmz3pg"))))
437 (build-system gnu-build-system)
439 `(("autoconf" ,autoconf)
440 ("automake" ,automake)
442 ("pkg-config" ,pkg-config)
443 ("python" ,python-wrapper)))
445 `(;; XXX: Build fails with libvideogfx.
446 ;; ("libvideogfx" ,libvideogfx)
449 (synopsis "H.265 video codec implementation")
450 (description "Libde265 is an implementation of the h.265 video codec. It is
451 written from scratch and has a plain C API to enable a simple integration into
453 (home-page "https://www.libde265.org/")
470 (url "https://github.com/libts/tslib.git")
472 (file-name (git-file-name name version))
474 (base32 "1ph51vpfp92rpa2vs6wkz1b1pcs3z334p1i33sprsi8mjlwvkbzc"))))
475 (build-system gnu-build-system)
477 `(#:test-target "tests"
482 `(("autoconf" ,autoconf)
483 ("automake" ,automake)
485 ("pkg-config" ,pkg-config)))
487 `(("linux-headers" ,linux-libre-headers)
489 (synopsis "Touchscreen access library")
490 (description "TSLib is a cross-platform library that provides access to
491 touchscreen devices and the ability to apply filters to their input events.")
492 (home-page "http://www.tslib.org/")
493 (license license:lgpl2.1+)))
495 (define-public libmpeg3
503 (string-append "https://sourceforge.net/projects/heroines/files/"
504 "releases/081108/" name "-" version "-src.tar.bz2"))
506 (base32 "1i53vv0wm5qfwgg1z7j9g14s6c7gxxkiy4vbdkq3lijjyyz50vv5"))))
507 (build-system gnu-build-system)
509 `(#:test-target "test"
512 (string-append "A52DIR=" (assoc-ref %build-inputs "liba52"))
513 (string-append "DST=" (assoc-ref %outputs "out") "/bin"))
515 (modify-phases %standard-phases
516 (add-after 'unpack 'delete-bundled-a52dec
518 (delete-file-recursively "a52dec-0.7.3")
519 (substitute* "Makefile"
520 (("include Makefile\\.a52")
522 (("\\(A52DIR\\)/include")
523 "(A52DIR)/include/a52dec")
525 (string-append match "-la52 ")))
527 (add-before 'install 'create-destination-directory
528 (lambda* (#:key outputs #:allow-other-keys)
529 (let* ((out (string-append (assoc-ref outputs "out"))))
530 (mkdir-p (string-append out "/bin"))
535 `(("liba52" ,liba52)))
536 (synopsis "Advanced MPEG editing and manipulation library")
537 (description "Libmpeg3 decodes MP2, MP3, AC3, MPEG-1 video, MPEG-2 video,
538 and DVD footage in a single library. It supports many esoteric features like
539 parallel video decoding, frame-accurate editing, YUV 4:2:2, and ATSC transport
541 (home-page "http://heroinewarrior.com/libmpeg3.php")
542 (license license:gpl2+)))
550 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
551 version "/" name "-" version ".tar.gz"))
554 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
555 (build-system gnu-build-system)
557 `(("makeinfo" ,texinfo)))
559 `(("ncurses" ,ncurses)))
562 (modify-phases %standard-phases
564 (lambda* (#:key build inputs outputs #:allow-other-keys)
565 ;; This old `configure' script doesn't support
566 ;; variables passed as arguments.
567 (let ((out (assoc-ref outputs "out"))
568 (ncurses (assoc-ref inputs "ncurses")))
569 (setenv "CONFIG_SHELL" (which "bash"))
570 (invoke "./configure"
571 (string-append "--prefix=" out)
572 (string-append "--build=" build)
573 ;; The ancient config.guess is unable to
574 ;; guess the host triplet on mips64el.
575 ,@(if (string=? "mips64el-linux"
577 '("--host=mips64el-unknown-linux-gnu")
579 ;; The same is also true with aarch64.
580 ,@(if (string=? "aarch64-linux"
582 '("--host=aarch64-unknown-linux-gnu")
584 (string-append "--with-ncurses="
586 (home-page "http://aa-project.sourceforge.net/aalib/")
587 (synopsis "ASCII-art library")
589 "AA-lib is a low level gfx library which does not require graphics device.
590 In fact, there is no graphical output possible. AA-lib replaces those
591 old-fashioned output methods with powerful ascii-art renderer.")
592 (license license:lgpl2.0+)))
594 (define-public celluloid
601 (uri (string-append "https://github.com/celluloid-player/celluloid/releases"
602 "/download/v" version "/celluloid-" version ".tar.xz"))
604 (base32 "1s3qkism96gi44incvsb6rqg255qcvjvw61ya7nw30md0sapj4sl"))))
605 (build-system glib-or-gtk-build-system)
607 `(("intltool" ,intltool)
608 ("pkg-config" ,pkg-config)))
611 ("libepoxy" ,libepoxy)
613 (home-page "https://github.com/celluloid-player/celluloid")
614 (synopsis "GTK+ frontend for the mpv media player")
615 (description "Celluloid is a simple GTK+ frontend for the mpv media player.
616 It interacts with mpv via the client API exported by libmpv, allowing access to
617 mpv's powerful playback capabilities.")
618 (license license:gpl3+)))
620 (define-public liba52
627 ;; A mirror://sourceforge URI doesn't work, presumably
628 ;; because the SourceForge project is misconfigured.
629 "http://liba52.sourceforge.net/files/a52dec-" version
633 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
634 (patches (search-patches "liba52-enable-pic.patch"
635 "liba52-set-soname.patch"
636 "liba52-use-mtune-not-mcpu.patch"
637 "liba52-link-with-libm.patch"))))
638 (build-system gnu-build-system)
639 ;; XXX We need to run ./bootstrap because of the build system fixes above.
641 `(("autoconf" ,autoconf)
642 ("automake" ,automake)
643 ("libtool" ,libtool)))
644 (arguments `(#:configure-flags '("--enable-shared")
646 (modify-phases %standard-phases
647 ;; XXX We need to run ./bootstrap because of the build
648 ;; system fixes above.
650 (lambda _ (invoke "sh" "bootstrap"))))))
651 (home-page "http://liba52.sourceforge.net/")
652 (synopsis "ATSC A/52 stream decoder")
653 (description "liba52 is a library for decoding ATSC A/52 streams. The
654 A/52 standard is used in a variety of applications, including digital
655 television and DVD. It is also known as AC-3.")
656 (license license:gpl2+)))
658 (define-public libaom
665 (url "https://aomedia.googlesource.com/aom/")
666 (commit (string-append "v" version))))
667 (file-name (git-file-name name version))
670 "1616xjhj6770ykn82ml741h8hx44v507iky3s9h7a5lnk9d4cxzy"))))
671 (build-system cmake-build-system)
674 ("pkg-config" ,pkg-config)
675 ("python" ,python))) ; to detect the version
677 `(#:tests? #f ;no check target
679 ;; build dynamic library
680 (list "-DBUILD_SHARED_LIBS=YES"
682 "-DAOM_TARGET_CPU=generic"
683 (string-append "-DCMAKE_INSTALL_PREFIX="
684 (assoc-ref %outputs "out")))))
685 (home-page "https://aomedia.googlesource.com/aom/")
686 (synopsis "AV1 video codec")
687 (description "Libaom is the reference implementation of AV1. It includes a
688 shared library and encoder and decoder command-line executables.")
689 (license license:bsd-2)))
691 (define-public libmpeg2
697 ;; A mirror://sourceforge URI doesn't work, presumably
698 ;; because the SourceForge project is misconfigured.
699 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
700 name "-" version ".tar.gz"))
701 (patches (search-patches "libmpeg2-arm-private-symbols.patch"
702 "libmpeg2-global-symbol-test.patch"))
705 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
713 (build-system gnu-build-system)
714 (home-page "http://libmpeg2.sourceforge.net/")
715 (synopsis "MPEG1 and MPEG2 video decoder library")
717 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
718 (license license:gpl2+)))
720 (define-public libx264
721 ;; There are no tags in the repository, so we take the version number from
722 ;; the X264_BUILD variable defined in x264.h.
723 (let ((version "159")
724 (commit "1771b556ee45207f8711744ccbd5d42a3949b14c")
728 (version (git-version version revision commit))
732 (url "https://code.videolan.org/videolan/x264.git")
734 (file-name (git-file-name name version))
737 "0kmi78gs5101d4df33il5bmjbns54nvdjsyn44xiw60lwsg11vwz"))))
738 (build-system gnu-build-system)
740 `(("pkg-config" ,pkg-config)
742 ;; TODO: Add gpac input
744 `(#:tests? #f ;no check target
745 #:configure-flags '("--enable-shared"
746 ;; Don't build the command-line program. If we
747 ;; want it later, we should do so in a different
748 ;; package to avoid a circular dependency (the x264
749 ;; program depends on ffmpeg and ffmpeg depends on
753 ;; On MIPS, we must pass "--disable-asm" or else
754 ;; configure fails after printing: "You specified a
755 ;; pre-MSA CPU in your CFLAGS. If you really want
756 ;; to run on such a CPU, configure with
758 ,@(if (string-prefix? "mips"
759 (or (%current-target-system)
763 (home-page "https://www.videolan.org/developers/x264.html")
764 (synopsis "H.264 video coding library")
765 (description "libx264 is an advanced encoding library for creating
766 H.264 (MPEG-4 AVC) video streams.")
767 (license (list license:gpl2+ ;most files
768 license:isc ;common/x86/x86inc.asm
769 license:lgpl2.1+ ;extras/getopt.c
770 license:bsd-3 ;extras/inttypes.h
771 (license:non-copyleft ;extras/cl*.h
773 "See extras/cl.h in the distribution."))))))
775 (define-public mkvtoolnix
782 (uri (string-append "https://mkvtoolnix.download/sources/"
783 "mkvtoolnix-" version ".tar.xz"))
785 (base32 "0r4d9318ymb9a0mkc0shi9p4kjy3m70s49v4f8dmjhvj63silhix"))
786 (modules '((guix build utils)))
788 ;; Delete bundled libraries.
789 (for-each delete-file-recursively
797 (build-system gnu-build-system)
798 (outputs '("out" "gui")) ; "mkvtoolnix-gui" brings the closure size from ~300 MB to 1.5+ GB.
807 ("libmatroska" ,libmatroska)
809 ("libvorbis" ,libvorbis)
813 ("qtmultimedia" ,qtmultimedia)
817 `(("docbook-xsl" ,docbook-xsl)
818 ("gettext" ,gettext-minimal)
819 ("googletest" ,googletest)
821 ("json-modern-cxx" ,json-modern-cxx)
823 ("pkg-config" ,pkg-config)
829 (list (string-append "--with-boost="
830 (assoc-ref %build-inputs "boost"))
831 (string-append "--with-docbook-xsl-root="
832 (assoc-ref %build-inputs "docbook-xsl")
833 "/xml/xsl/docbook-xsl-"
834 ,(package-version docbook-xsl))
835 "--enable-update-check=no"
836 "--enable-precompiled-headers=no")
838 (modify-phases %standard-phases
839 (add-after 'unpack 'patch-relative-file-names
840 (lambda* (#:key outputs #:allow-other-keys)
841 (let ((out (assoc-ref outputs "out")))
842 (substitute* "src/mkvtoolnix-gui/util/settings.cpp"
844 (string-append out "/bin/" match)))
846 (add-before 'configure 'add-googletest
847 (lambda* (#:key inputs #:allow-other-keys)
849 (string-append (assoc-ref inputs "googletest")
850 "/include/gtest") "lib/gtest")
854 (let ((-j (list "-j" (number->string (parallel-job-count)))))
855 (apply invoke "rake" -j))))
858 (invoke "rake" "tests/unit")))
861 (invoke "rake" "install")))
862 (add-after 'install 'post-install
863 (lambda* (#:key outputs #:allow-other-keys)
864 ;; Move the Qt interface to "gui".
865 (let* ((out (assoc-ref outputs "out"))
866 (gui (assoc-ref outputs "gui"))
867 (strip-store-dir (lambda (path)
868 (substring path (string-prefix-length out path)))))
871 (mkdir-p (string-append gui (dirname file)))
872 (rename-file (string-append out file)
873 (string-append gui file)))
874 (append '("/bin/mkvtoolnix-gui"
875 "/share/applications/org.bunkus.mkvtoolnix-gui.desktop"
876 "/share/metainfo/org.bunkus.mkvtoolnix-gui.appdata.xml"
877 "/share/mime/packages/org.bunkus.mkvtoolnix-gui.xml")
878 (map strip-store-dir (find-files out "\\.ogg$"))
879 (map strip-store-dir (find-files out "mkvtoolnix-gui\\.png$"))
880 (map strip-store-dir (find-files out "mkvtoolnix-gui\\.1"))))
883 (delete-file-recursively (string-append out file)))
884 '("/share/applications"
887 "/share/mkvtoolnix")))
889 (home-page "https://mkvtoolnix.download")
890 (synopsis "Tools to create, alter and inspect Matroska files")
892 "MKVToolNix provides tools for getting information about Matroska files
893 (@command{mkvinfo}), extracting tracks/data from Matroska files
894 (@command{mkvextract}), and creating Matroska files from other media files
895 (@command{mkvmerge}).")
896 (license license:gpl2)))
898 (define-public straw-viewer
900 (name "straw-viewer")
906 (url "https://github.com/trizen/straw-viewer")
908 (file-name (git-file-name name version))
911 "0a9g10r56jdm2jx2yg9i8j8nczq74x78c29bhannr7ybnm2r6w2a"))))
912 (build-system perl-build-system)
914 `(("perl-module-build" ,perl-module-build)
915 ("perl-test-pod" ,perl-test-pod)))
917 `(("perl-data-dump" ,perl-data-dump)
918 ("perl-json" ,perl-json)
919 ("perl-libwww" ,perl-libwww)
920 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
921 ("perl-lwp-useragent-cached" ,perl-lwp-useragent-cached)
922 ("perl-mozilla-ca" ,perl-mozilla-ca)
923 ("perl-term-readline-gnu" ,perl-term-readline-gnu)
924 ("perl-unicode-linebreak" ,perl-unicode-linebreak)
925 ("xdg-utils" ,xdg-utils)
927 ;; Some videos play without youtube-dl, but others silently fail to.
928 ("youtube-dl" ,youtube-dl)))
930 ;; Required only when building the graphical interface (--gtk).
931 ;;("perl-file-sharedir" ,perl-file-sharedir)
933 `(#:modules ((guix build perl-build-system)
937 (modify-phases %standard-phases
938 (add-after 'unpack 'refer-to-inputs
939 (lambda* (#:key inputs #:allow-other-keys)
940 (substitute* "lib/WWW/StrawViewer.pm"
942 (format #f "'~a/bin/youtube-dl'"
943 (assoc-ref inputs "youtube-dl"))))
944 (substitute* "bin/gtk-straw-viewer"
946 (format #f "'~a/bin/xdg-open'"
947 (assoc-ref inputs "xdg-utils"))))
949 ;; (add-after 'install 'install-desktop
950 ;; (lambda* (#:key outputs #:allow-other-keys)
951 ;; (let* ((out (assoc-ref outputs "out"))
952 ;; (sharedir (string-append out "/share")))
953 ;; (install-file "share/gtk-straw-viewer.desktop"
954 ;; (string-append sharedir "/applications"))
955 ;; (install-file "share/icons/gtk-straw-viewer.png"
956 ;; (string-append sharedir "/pixmaps"))
958 (add-after 'install 'wrap-program
959 (lambda* (#:key outputs #:allow-other-keys)
960 (let* ((out (assoc-ref outputs "out"))
961 (bin-dir (string-append out "/bin/"))
962 (site-dir (string-append out "/lib/perl5/site_perl/"))
963 (lib-path (getenv "PERL5LIB")))
964 (for-each (cut wrap-program <>
965 `("PERL5LIB" ":" prefix (,lib-path ,site-dir)))
966 (find-files bin-dir))
969 "Light-weight application for searching and streaming videos from YouTube")
971 "Straw-viewer searches for YouTube videos using @uref{https://invidio.us/,
972 invidio.us} and plays them locally in a native media player like @command{vlc}
975 You can search for videos, playlists, and/or channels. The videos are streamed
976 directly to the player at the best chosen resolution and with closed captions if
978 ;; XXX Add #:module-build-flags '("--gtk") dependencies and this sentence.
979 ;; Both a command-line and a graphical interface are available.
980 (home-page "https://github.com/trizen/youtube-viewer")
981 (license license:perl-license)))
987 (outputs '("out" "static"))
991 (uri (list (string-append "https://bitbucket.org/multicoreware/x265"
992 "/downloads/x265_" version ".tar.gz")
993 (string-append "https://download.videolan.org/videolan/x265/"
994 "x265_" version ".tar.gz")))
996 (base32 "0wl62hfsdqpf3r3z3s6l9bz7pdb1rcik5ll00b3yaadplqipy162"))
997 (patches (search-patches "x265-arm-flags.patch"))
998 (modules '((guix build utils)))
1000 (delete-file-recursively "source/compat/getopt")
1002 (build-system cmake-build-system)
1004 ;; XXX: ASM optimization fails on i686-linux, see <https://bugs.gnu.org/41768>.
1005 (if (string-prefix? "i686" (%current-system))
1009 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
1011 ;; Ensure position independent code for everyone.
1012 (list "-DENABLE_PIC=TRUE"
1014 '("-DENABLE_ASSEMBLY=OFF")
1016 (string-append "-DCMAKE_INSTALL_PREFIX="
1017 (assoc-ref %outputs "out")))
1019 (modify-phases %standard-phases
1020 (add-after 'unpack 'prepare-build
1022 (delete-file-recursively "build")
1025 (add-before 'configure 'build-12-bit
1026 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
1027 (mkdir "../build-12bit")
1028 (with-directory-excursion "../build-12bit"
1031 "-DHIGH_BIT_DEPTH=ON"
1032 "-DEXPORT_C_API=OFF"
1036 (substitute* (cons "cmake_install.cmake"
1038 (find-files "CMakeFiles/x265-shared.dir" ".")
1039 (find-files "CMakeFiles/x265-static.dir" ".")))
1040 (("libx265") "libx265_main12"))
1042 (add-before 'configure 'build-10-bit
1043 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
1044 (mkdir "../build-10bit")
1045 (with-directory-excursion "../build-10bit"
1048 "-DHIGH_BIT_DEPTH=ON"
1049 "-DEXPORT_C_API=OFF"
1052 (substitute* (cons "cmake_install.cmake"
1054 (find-files "CMakeFiles/x265-shared.dir" ".")
1055 (find-files "CMakeFiles/x265-static.dir" ".")))
1056 (("libx265") "libx265_main10"))
1058 (add-after 'install 'install-more-libs
1060 (with-directory-excursion "../build-12bit"
1061 (invoke "make" "install"))
1062 (with-directory-excursion "../build-10bit"
1063 (invoke "make" "install"))))
1064 (add-before 'strip 'move-static-libs
1065 (lambda* (#:key outputs #:allow-other-keys)
1066 (let ((out (assoc-ref outputs "out"))
1067 (static (assoc-ref outputs "static")))
1068 (mkdir-p (string-append static "/lib"))
1069 (with-directory-excursion
1070 (string-append out "/lib")
1074 (string-append static "/lib/" file)))
1075 (find-files "." "\\.a$"))))
1077 (home-page "http://x265.org/")
1078 (synopsis "Library for encoding h.265/HEVC video streams")
1079 (description "x265 is a H.265 / HEVC video encoder application library,
1080 designed to encode video or images into an H.265 / HEVC encoded bitstream.")
1081 (license license:gpl2+)))
1083 (define-public libass
1090 "https://github.com/libass/libass/releases/download/"
1091 version "/libass-" version ".tar.xz"))
1094 "18iqznl4mabhj9ywfsz4kwvbsplcv1jjxq50nxssvbj8my1267w8"))))
1095 (build-system gnu-build-system)
1097 `(("pkg-config" ,pkg-config)
1100 `(("freetype" ,freetype)
1101 ("fribidi" ,fribidi)
1102 ("fontconfig" ,fontconfig)
1103 ("harfbuzz" ,harfbuzz)
1105 (home-page "https://github.com/libass/libass")
1106 (synopsis "Subtitle rendering library for the ASS/SSA format")
1107 (description "libass is a subtitle rendering library for the
1108 ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
1109 (license license:isc)))
1111 (define-public libcaca
1114 (version "0.99.beta19")
1117 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
1121 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))))
1122 (build-system gnu-build-system)
1123 (native-inputs `(("pkg-config" ,pkg-config)))
1125 `(("freeglut" ,freeglut)
1130 ("ncurses" ,ncurses)
1132 (home-page "http://caca.zoy.org/wiki/libcaca")
1133 (synopsis "Colour ASCII-art library")
1134 (description "libcaca is a graphics library that outputs text instead of
1135 pixels, so that it can work on older video cards or text terminals. It
1136 supports Unicode, 2048 colors, dithering of color images, and advanced text
1137 canvas operations.")
1138 (license license:wtfpl2)))
1140 (define-public libdca
1147 "https://download.videolan.org/pub/videolan/libdca/"
1148 version "/libdca-" version ".tar.bz2"))
1151 "0sjz0s0nrv7jcpvh1i432x3jza0y5yycmzw84cfncb2qby0i62rs"))))
1152 (build-system gnu-build-system)
1154 `(("autoconf" ,autoconf)
1155 ("automake" ,automake)
1156 ("libtool" ,libtool)))
1157 (home-page "https://www.videolan.org/developers/libdca.html")
1158 (synopsis "DTS Coherent Acoustics decoder")
1159 (description "libdca is a library for decoding DTS Coherent Acoustics
1161 (license license:gpl2+)))
1163 (define-public libdv
1170 "mirror://sourceforge/libdv/libdv/"
1171 version "/libdv-" version ".tar.gz"))
1174 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
1175 (build-system gnu-build-system)
1176 (native-inputs `(("pkg-config" ,pkg-config)))
1177 (inputs `(("libxv" ,libxv)))
1178 (home-page "http://libdv.sourceforge.net/")
1179 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
1180 (description "The Quasar DV codec (libdv) is a software codec for DV
1181 video, the encoding format used by most digital camcorders, typically those
1182 that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
1183 developed according to the official standards for DV video: IEC 61834 and
1185 (license license:lgpl2.1+)))
1187 (define-public libmatroska
1189 (name "libmatroska")
1194 (uri (string-append "https://dl.matroska.org/downloads/"
1195 "libmatroska/libmatroska-" version ".tar.xz"))
1197 (base32 "140r3q6n4a0n11zaf76lvyxd9gp435dgm8gn7mj0gar2hjm7ji5w"))))
1198 (build-system cmake-build-system)
1200 `(("libebml" ,libebml)))
1203 (list "-DBUILD_SHARED_LIBS=YES")
1204 #:tests? #f)) ; no test suite
1205 (home-page "https://www.matroska.org")
1206 (synopsis "C++ library to parse Matroska files (.mkv and .mka)")
1208 "Matroska aims to become the standard of multimedia container formats.
1209 It is based on @dfn{EBML} (Extensible Binary Meta Language), a binary derivative
1210 of XML. EBML enables the Matroska Development Team to gain significant
1211 advantages in terms of future format extensibility, without breaking file
1212 support in old parsers.
1213 libebml is a C++ library to read and write EBML files.")
1214 (license license:lgpl2.1)))
1216 (define-public libva
1224 ;; Newer releases are only available on GitHub.
1225 (string-append "https://github.com/01org/libva/releases/download/"
1226 version "/libva-" version ".tar.bz2")
1227 ;; Keep the old URL around for compatibility.
1228 (string-append "https://www.freedesktop.org/software/vaapi/releases/"
1229 "libva/libva-" version "/libva-" version ".tar.bz2")))
1231 (base32 "014av7ayyc624xfmr63xhbgg7nw8fynsswj1g2wmk4lnkyfz23x0"))))
1232 (build-system gnu-build-system)
1234 `(("pkg-config" ,pkg-config)))
1236 `(("libdrm" ,libdrm)
1238 ("libxext" ,libxext)
1239 ("libxfixes" ,libxfixes)
1241 ("wayland" ,wayland)))
1244 (modify-phases %standard-phases
1246 'build 'fix-dlopen-paths
1247 (lambda* (#:key outputs #:allow-other-keys)
1248 (let ((out (assoc-ref outputs "out")))
1249 (substitute* "va/drm/va_drm_auth_x11.c"
1250 (("\"libva-x11\\.so\\.%d\"")
1251 (string-append "\"" out "/lib/libva-x11.so.%d\"")))
1253 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
1254 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
1256 (list (string-append "--with-drivers-path="
1257 (assoc-ref %build-inputs "mesa") "/lib/dri"))
1258 ;; However, we can't write to mesa's store directory, so override the
1259 ;; following make variable to install the dummy driver to libva's
1260 ;; $prefix/lib/dri directory.
1262 (list (string-append "dummy_drv_video_ladir="
1263 (assoc-ref %outputs "out") "/lib/dri"))))
1264 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
1265 (synopsis "Video acceleration library")
1266 (description "The main motivation for VA-API (Video Acceleration API) is
1267 to enable hardware accelerated video decode/encode at various
1268 entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
1269 standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
1270 (license license:expat)))
1272 (define-public libva-utils
1274 (name "libva-utils")
1279 (uri (string-append "https://github.com/intel/libva-utils/releases/download/"
1280 version "/libva-utils-" version ".tar.bz2"))
1282 (base32 "05rasyqnsg522zqxak1q8rrm1hys7wwbi41kd0szjq0d27awjf4j"))))
1283 (build-system gnu-build-system)
1286 (list "--enable-wayland"
1289 `(("pkg-config" ,pkg-config)))
1291 `(("libdrm" ,libdrm)
1295 ("wayland" ,wayland)))
1296 (home-page "https://01.org/linuxmedia/vaapi")
1297 (synopsis "Collection of testing utilities for VA-API")
1299 "This is a collection of utilities to query and test the @acronym{VA-API,
1300 Video Acceleration API} implemented by the libva library.
1302 These tools require a supported graphics chip, driver, and VA-API back end to
1304 (license license:expat)))
1306 (define-public ffmpeg
1312 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1316 "1yrg9nri54iav86vxy5i8pj51dhikksa04x20d77nc3fsi09405d"))))
1317 (build-system gnu-build-system)
1320 ("fontconfig" ,fontconfig)
1321 ("freetype" ,freetype)
1322 ("frei0r-plugins" ,frei0r-plugins)
1329 ("libbluray" ,libbluray)
1330 ("libcaca" ,libcaca)
1331 ("libcdio-paranoia" ,libcdio-paranoia)
1333 ("libtheora" ,libtheora)
1335 ("libvdpau" ,libvdpau)
1336 ("libvorbis" ,libvorbis)
1339 ("libx264" ,libx264)
1342 ("pulseaudio" ,pulseaudio)
1343 ;; XXX: rav1e depends on rust, which currently only works on x86_64.
1344 ;; See also the related configure flag when changing this.
1345 ,@(if (string-prefix? "x86_64" (or (%current-target-system)
1352 ("twolame" ,twolame)
1353 ("vidstab" ,vidstab)
1360 ("pkg-config" ,pkg-config)
1361 ("texinfo" ,texinfo)
1362 ("python" ,python-2) ; scripts use interpreter python2
1366 `(#:test-target "fate"
1368 ;; possible additional inputs:
1369 ;; --enable-avisynth enable reading of AviSynth script
1371 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
1372 ;; --enable-libcelt enable CELT decoding via libcelt [no]
1373 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
1374 ;; and libraw1394 [no]
1375 ;; --enable-libfaac enable AAC encoding via libfaac [no]
1376 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
1377 ;; --enable-libflite enable flite (voice synthesis) support via
1379 ;; --enable-libgme enable Game Music Emu via libgme [no]
1380 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
1381 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
1382 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
1383 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
1384 ;; --enable-libnut enable NUT (de)muxing via libnut,
1385 ;; native (de)muxer exists [no]
1386 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
1387 ;; libopencore-amrnb [no]
1388 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
1389 ;; libopencore-amrwb [no]
1390 ;; --enable-libopencv enable video filtering via libopencv [no]
1391 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
1393 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
1394 ;; --enable-libschroedinger enable Dirac de/encoding via
1395 ;; libschroedinger [no]
1396 ;; --enable-libshine enable fixed-point MP3 encoding via
1398 ;; --enable-libssh enable SFTP protocol via libssh [no]
1399 ;; (libssh2 does not work)
1400 ;; --enable-libstagefright-h264 enable H.264 decoding via
1401 ;; libstagefright [no]
1402 ;; --enable-libutvideo enable Ut Video encoding and decoding via
1404 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
1405 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
1406 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
1407 ;; libvo-amrwbenc [no]
1408 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
1409 ;; --enable-libxavs enable AVS encoding via xavs [no]
1410 ;; --enable-libzmq enable message passing via libzmq [no]
1411 ;; --enable-libzvbi enable teletext support via libzvbi [no]
1412 ;; --enable-opencl enable OpenCL code
1413 '("--enable-avresample"
1414 "--enable-gpl" ; enable optional gpl licensed parts
1417 "--enable-fontconfig"
1422 "--enable-libbluray"
1426 "--enable-libfreetype"
1427 "--enable-libmp3lame"
1430 ,@(if (string-prefix? "x86_64" (or (%current-target-system)
1432 '("--enable-librav1e")
1436 "--enable-libtheora"
1437 "--enable-libtwolame"
1438 "--enable-libvidstab"
1439 "--enable-libvorbis"
1448 "--enable-runtime-cpudetect"
1450 ;; The HTML pages take 7.2 MiB
1451 "--disable-htmlpages"
1453 ;; The static libraries are 23 MiB
1456 ;; Runtime cpu detection is not implemented on
1457 ;; MIPS, so we disable some features.
1458 "--disable-mips32r2"
1460 "--disable-mipsdspr2"
1461 "--disable-mipsfpu")
1463 (modify-phases %standard-phases
1466 ;; configure does not work followed by "SHELL=..." and
1467 ;; "CONFIG_SHELL=..."; set environment variables instead
1468 (lambda* (#:key outputs configure-flags #:allow-other-keys)
1469 (let ((out (assoc-ref outputs "out")))
1470 (substitute* "configure"
1471 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1472 (setenv "SHELL" (which "bash"))
1473 (setenv "CONFIG_SHELL" (which "bash"))
1476 (string-append "--prefix=" out)
1477 ;; Add $libdir to the RUNPATH of all the binaries.
1478 (string-append "--extra-ldflags=-Wl,-rpath="
1482 'check 'set-ld-library-path
1484 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
1486 (let* ((dso (find-files "." "\\.so$"))
1487 (path (string-join (map dirname dso) ":")))
1488 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
1489 (setenv "LD_LIBRARY_PATH" path)
1491 (home-page "https://www.ffmpeg.org/")
1492 (synopsis "Audio and video framework")
1493 (description "FFmpeg is a complete, cross-platform solution to record,
1494 convert and stream audio and video. It includes the libavcodec
1495 audio/video codec library.")
1496 (license license:gpl2+)))
1498 ;; ungoogled-chromium crashes with ffmpeg 4.3, so stick with this version for
1499 ;; now. See <https://issues.guix.gnu.org/41987>.
1500 (define-public ffmpeg-4.2
1506 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1510 "0cddkb5sma9dzy8i59sfls19rhjlq40zn9mh3x666dqkxl5ckxlx"))))
1512 (substitute-keyword-arguments (package-arguments ffmpeg)
1513 ((#:configure-flags flags)
1514 `(delete "--enable-librav1e" ,flags))))))
1516 (define-public ffmpeg-3.4
1522 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1526 "1j7mdk9szrljgv4sdx69bm1pnbb3cldbdxbkr42jbdi9zn11gl7g"))))
1528 (substitute-keyword-arguments (package-arguments ffmpeg)
1529 ((#:configure-flags flags)
1530 `(delete "--enable-libdav1d" (delete "--enable-libaom" (delete "--enable-librav1e"
1532 (inputs (alist-delete "dav1d" (alist-delete "libaom" (alist-delete "rav1e"
1533 (package-inputs ffmpeg)))))))
1535 (define-public ffmpeg-2.8
1541 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1545 "14n0xg22yz1r4apif2idm91s3avcmkz4sl8gyj5763gcy415k2bb"))))
1547 `(#:tests? #f ; XXX: Enable them later, if required
1552 "--extra-cflags=-DFF_API_OLD_ENCODE_VIDEO -DFF_API_OLD_ENCODE_AUDIO")
1554 (modify-phases %standard-phases
1556 (lambda* (#:key outputs configure-flags #:allow-other-keys)
1557 (let ((out (assoc-ref outputs "out")))
1558 (substitute* "configure"
1559 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1560 ;; configure does not work followed by "SHELL=..." and
1561 ;; "CONFIG_SHELL=..."; set environment variables instead.
1562 (setenv "SHELL" (which "bash"))
1563 (setenv "CONFIG_SHELL" (which "bash"))
1566 (string-append "--prefix=" out)
1567 ;; Add $libdir to the RUNPATH of all the binaries.
1568 (string-append "--extra-ldflags=-Wl,-rpath="
1572 'check 'set-ld-library-path
1574 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
1576 (let* ((dso (find-files "." "\\.so$"))
1577 (path (string-join (map dirname dso) ":")))
1578 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
1579 (setenv "LD_LIBRARY_PATH" path)
1582 (define-public ffmpeg-for-stepmania
1591 (url "https://github.com/stepmania/ffmpeg")
1592 (commit "eda6effcabcf9c238e4635eb058d72371336e09b")))
1594 (base32 "1by8rmbva8mfrivdbbkr2gx4kga89zqygkd4cfjl76nr8mdcdamb"))
1595 (file-name (git-file-name "ffmpeg" version))))
1597 (substitute-keyword-arguments (package-arguments ffmpeg)
1598 ((#:configure-flags flags)
1599 '(list "--disable-programs"
1602 "--disable-avdevice"
1603 "--disable-swresample"
1604 "--disable-postproc"
1605 "--disable-avfilter"
1607 "--enable-static"))))
1610 (define-public ffmpegthumbnailer
1612 (name "ffmpegthumbnailer")
1617 (url "https://github.com/dirkvdb/ffmpegthumbnailer")
1619 (file-name (git-file-name name version))
1622 "1bakbr714j7yxdal1f5iq0gcl4cxggbbgj227ihdh5kvygqlwich"))))
1623 (build-system cmake-build-system)
1625 `(("pkg-config" ,pkg-config)))
1627 `(("ffmpeg" ,ffmpeg)
1628 ("libjpeg-turbo" ,libjpeg-turbo)
1632 `(#:configure-flags (list "-DENABLE_GIO=ON" "-DENABLE_THUMBNAILER=ON")))
1633 (home-page "https://github.com/dirkvdb/ffmpegthumbnailer")
1634 (synopsis "Create thumbnails from video files")
1635 (description "FFmpegthumbnailer is a lightweight video thumbnailer that
1636 can be used by file managers to create thumbnails for your video files. The
1637 thumbnailer uses ffmpeg to decode frames from the video files, so supported
1638 videoformats depend on the configuration flags of ffmpeg.")
1639 (license license:gpl2+)))
1644 (version "3.0.11.1")
1648 "https://download.videolan.org/pub/videolan/vlc/"
1649 (car (string-split version #\-))
1650 "/vlc-" version ".tar.xz"))
1653 "1f46h0hv7fk35zg4iczlp7ib7h2jmh8m4r5klw3g2558ib9134qq"))))
1654 (build-system gnu-build-system)
1658 ("gettext" ,gettext-minimal)
1659 ("pkg-config" ,pkg-config)))
1660 ;; FIXME: Add optional inputs once available.
1662 `(("alsa-lib" ,alsa-lib)
1668 ("fontconfig" ,fontconfig)
1669 ("freetype" ,freetype)
1670 ("fribidi" ,fribidi)
1673 ("libarchive" ,libarchive)
1675 ("libavc1394" ,libavc1394)
1676 ("libbluray" ,libbluray)
1677 ("libcaca" ,libcaca)
1678 ("libcddb" ,libcddb)
1680 ("libdvbpsi" ,libdvbpsi)
1681 ("libdvdnav" ,libdvdnav)
1682 ("libdvdread" ,libdvdread)
1683 ("libebml" ,libebml)
1684 ("libgcrypt" ,libgcrypt)
1686 ("libkate" ,libkate)
1688 ("libmatroska" ,libmatroska)
1689 ("libmicrodns" ,libmicrodns)
1690 ("libmodplug" ,libmodplug)
1691 ("libmpeg2" ,libmpeg2)
1694 ("libraw1394" ,libraw1394)
1695 ("librsvg" ,librsvg)
1696 ("libsamplerate" ,libsamplerate)
1697 ("libsecret" ,libsecret)
1698 ("libssh2" ,libssh2)
1699 ("libupnp" ,libupnp)
1701 ("libvdpau" ,libvdpau)
1702 ("libvorbis" ,libvorbis)
1704 ("libtheora" ,libtheora)
1705 ("libx264" ,libx264)
1706 ("libxext" ,libxext)
1708 ("libxinerama" ,libxinerama)
1709 ("libxml2" ,libxml2)
1711 ("livemedia-utils" ,livemedia-utils)
1716 ("pulseaudio" ,pulseaudio)
1717 ("protobuf" ,protobuf)
1718 ("python" ,python-wrapper)
1721 ("qtx11extras" ,qtx11extras)
1724 ("sdl-image" ,sdl-image)
1726 ("speexdsp" ,speexdsp)
1728 ("twolame" ,twolame)
1730 ("wayland" ,wayland)
1731 ("wayland-protocols" ,wayland-protocols)
1733 ("xcb-util-keysyms" ,xcb-util-keysyms)))
1737 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
1738 (assoc-ref %build-inputs "ffmpeg")
1739 "/lib")) ;needed for the tests
1742 (modify-phases %standard-phases
1743 (add-after 'unpack 'patch-source
1744 (lambda* (#:key inputs #:allow-other-keys)
1745 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
1746 (substitute* "configure"
1747 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
1748 (string-append "LIVE555_PREFIX=" livemedia-utils)))
1749 ;; Some of the tests require using the display to test out VLC,
1750 ;; which fails in our sandboxed build system
1751 (substitute* "test/run_vlc.sh"
1752 (("./vlc --ignore-config") "echo"))
1754 (add-after 'strip 'regenerate-plugin-cache
1755 (lambda* (#:key outputs #:allow-other-keys)
1756 ;; The 'install-exec-hook' rule in the top-level Makefile.am
1757 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
1758 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
1759 ;; it references. Thus, we first reset the timestamps of all
1760 ;; these files, and then regenerate the cache such that the
1761 ;; mtimes it includes are always zero instead of being dependent
1762 ;; on the build time.
1763 (let* ((out (assoc-ref outputs "out"))
1764 (pkglibdir (string-append out "/lib/vlc"))
1765 (plugindir (string-append pkglibdir "/plugins"))
1766 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
1767 ;; TODO: Factorize 'reset-timestamps'.
1768 (for-each (lambda (file)
1769 (let ((s (lstat file)))
1770 (unless (eq? (stat:type s) 'symlink)
1772 (find-files plugindir))
1773 (invoke cachegen plugindir))))
1774 (add-after 'install 'wrap-executable
1775 (lambda* (#:key outputs #:allow-other-keys)
1776 (let ((out (assoc-ref outputs "out"))
1777 (plugin-path (getenv "QT_PLUGIN_PATH")))
1778 (wrap-program (string-append out "/bin/vlc")
1779 `("QT_PLUGIN_PATH" ":" prefix (,plugin-path))))
1781 (home-page "https://www.videolan.org/")
1782 (synopsis "Audio and video framework")
1783 (description "VLC is a cross-platform multimedia player and framework
1784 that plays most multimedia files as well as DVD, Audio CD, VCD, and various
1785 streaming protocols.")
1786 (license license:gpl2+)))
1788 (define-public mplayer
1795 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
1799 "0j5mflr0wnklxsvnpmxvk704hscyn2785hvvihj2i3a7b3anwnc2"))))
1800 (build-system gnu-build-system)
1801 ;; FIXME: Add additional inputs once available.
1803 `(("pkg-config" ,pkg-config)
1806 `(("alsa-lib" ,alsa-lib)
1807 ("cdparanoia" ,cdparanoia)
1809 ("fontconfig" ,fontconfig)
1810 ("freetype" ,freetype)
1814 ("libdvdcss" ,libdvdcss)
1815 ("libdvdnav" ,libdvdnav) ; ignored without libdvdread
1816 ("libdvdread" ,libdvdread) ; ignored without libdvdnav
1817 ("libjpeg" ,libjpeg-turbo)
1818 ("libmpeg2" ,libmpeg2)
1819 ("libmpg123" ,mpg123) ; audio codec for MP3
1821 ("libtheora" ,libtheora)
1822 ("libvdpau" ,libvdpau)
1823 ("libvorbis" ,libvorbis)
1825 ("libx264" ,libx264)
1826 ("libxinerama" ,libxinerama)
1828 ("libxxf86dga" ,libxxf86dga)
1832 ("pulseaudio" ,pulseaudio)
1833 ("python" ,python-wrapper)
1838 `(#:tests? #f ; no test target
1840 (modify-phases %standard-phases
1842 ;; configure does not work followed by "SHELL=..." and
1843 ;; "CONFIG_SHELL=..."; set environment variables instead
1844 (lambda* (#:key inputs outputs #:allow-other-keys)
1845 (let ((out (assoc-ref outputs "out"))
1846 (libx11 (assoc-ref inputs "libx11")))
1847 (substitute* "configure"
1848 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1849 (setenv "SHELL" (which "bash"))
1850 (setenv "CONFIG_SHELL" (which "bash"))
1851 (invoke "./configure"
1852 (string-append "--extra-cflags=-I"
1853 libx11 "/include") ; to detect libx11
1854 "--disable-ffmpeg_a" ; disables bundled ffmpeg
1855 (string-append "--prefix=" out)
1856 ;; Enable runtime cpu detection where supported,
1857 ;; and choose a suitable target.
1858 ,@(match (or (%current-target-system)
1861 '("--enable-runtime-cpudetection"
1862 "--target=x86_64-linux"))
1864 '("--enable-runtime-cpudetection"
1865 "--target=i686-linux"))
1867 '("--target=mips3-linux"))
1868 (_ (list (string-append
1870 (or (%current-target-system)
1871 (nix-system->gnu-triplet
1872 (%current-system)))))))
1873 "--disable-iwmmxt")))))))
1874 (home-page "https://www.mplayerhq.hu")
1875 (synopsis "Audio and video player")
1876 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
1877 Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
1878 NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
1879 SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
1880 (license license:gpl2)))
1889 (url "https://github.com/mpv-player/mpv")
1890 (commit (string-append "v" version))))
1891 (file-name (git-file-name name version))
1894 "0kmy1q0hp87vq4rpv7py04x8bpg1wmlzaibavmkf713jqp6qy596"))))
1895 (build-system waf-build-system)
1897 `(("perl" ,perl) ; for zsh completion file
1898 ("pkg-config" ,pkg-config)
1899 ("python-docutils" ,python-docutils)))
1900 ;; Missing features: libguess, V4L2
1902 `(("alsa-lib" ,alsa-lib)
1909 ("libbluray" ,libbluray)
1910 ("libcaca" ,libcaca)
1911 ("libbs2b" ,libbs2b)
1912 ("libcdio-paranoia" ,libcdio-paranoia)
1913 ("libdvdread" ,libdvdread)
1914 ("libdvdnav" ,libdvdnav)
1915 ("libjpeg" ,libjpeg-turbo)
1917 ("libvdpau" ,libvdpau)
1919 ("libxext" ,libxext)
1920 ("libxinerama" ,libxinerama)
1921 ("libxrandr" ,libxrandr)
1922 ("libxscrnsaver" ,libxscrnsaver)
1924 ;; XXX: lua > 5.2 is not currently supported; see
1925 ;; waftools/checks/custom.py
1929 ("pulseaudio" ,pulseaudio)
1931 ("shaderc" ,shaderc)
1932 ("vulkan-headers" ,vulkan-headers)
1933 ("vulkan-loader" ,vulkan-loader)
1935 ("wayland" ,wayland)
1936 ("wayland-protocols" ,wayland-protocols)
1937 ("libxkbcommon" ,libxkbcommon)
1938 ("youtube-dl" ,youtube-dl)
1942 (modify-phases %standard-phases
1944 'unpack 'patch-paths
1945 (lambda* (#:key inputs #:allow-other-keys)
1946 (let ((ytdl (assoc-ref inputs "youtube-dl")))
1947 (substitute* "player/lua/ytdl_hook.lua"
1948 (("\"youtube-dl\",")
1949 (string-append "\"" ytdl "/bin/youtube-dl\",")))
1951 (add-before 'configure 'build-reproducibly
1953 ;; Somewhere in the build system library dependencies are enumerated
1954 ;; and passed as linker flags, but the order in which they are added
1955 ;; varies. See <https://github.com/mpv-player/mpv/issues/7855>.
1956 ;; Set PYTHONHASHSEED as a workaround for deterministic results.
1957 (setenv "PYTHONHASHSEED" "1")
1960 'configure 'setup-waf
1961 (lambda* (#:key inputs #:allow-other-keys)
1962 (let ((waf (assoc-ref inputs "waf")))
1963 (copy-file (string-append waf "/bin/waf") "waf"))
1966 #:configure-flags (list "--enable-libmpv-shared"
1969 "--disable-build-date")
1970 ;; No check function defined.
1972 (home-page "https://mpv.io/")
1973 (synopsis "Audio and video player")
1974 (description "mpv is a general-purpose audio and video player. It is a
1975 fork of mplayer2 and MPlayer. It shares some features with the former
1976 projects while introducing many more.")
1977 (license license:gpl2+)))
1979 (define-public gnome-mpv
1980 (deprecated-package "gnome-mpv" celluloid))
1982 (define-public mpv-mpris
1990 (url "https://github.com/hoyon/mpv-mpris")
1992 (file-name (git-file-name name version))
1995 "07p6li5z38pkfd40029ag2jqx917vyl3ng5p2i4v5a0af14slcnk"))))
1996 (build-system copy-build-system)
1999 '(("mpris.so" "lib/"))
2001 (modify-phases %standard-phases
2002 (add-before 'install 'build
2004 (setenv "CC" (which "gcc"))
2005 (invoke "make"))))))
2007 `(("pkg-config" ,pkg-config)))
2011 (home-page "https://github.com/hoyon/mpv-mpris")
2012 (synopsis "MPRIS plugin for mpv")
2013 (description "This package provides an @dfn{MPRIS} (Media Player Remote
2014 Interfacing Specification) plugin for the @code{mpv} media player. It implements
2015 @code{org.mpris.MediaPlayer2} and @code{org.mpris.MediaPlayer2.Player} D-Bus
2018 To load this plugin, specify the following option when starting mpv:
2019 @code{--script $GUIX_PROFILE/lib/mpris.so} or link it into
2020 @file{$HOME/.config/mpv/scripts}.")
2021 (license license:expat)))
2023 (define-public libvpx
2028 ;; XXX: Upstream does not provide tarballs for > 1.6.1.
2031 (url "https://chromium.googlesource.com/webm/libvpx")
2032 (commit (string-append "v" version))))
2033 (file-name (git-file-name name version))
2036 "0gyq4fkbd2fv7m1mm9xrvn6rk6f4jsmbv8bnlhingmnrvyncnmnr"))
2037 (patches (search-patches "libvpx-CVE-2016-2818.patch"))))
2038 (build-system gnu-build-system)
2040 `(#:configure-flags (list "--enable-shared"
2043 ;; Limit size to avoid CVE-2015-1258
2044 "--size-limit=16384x16384"
2045 (string-append "--prefix=" (assoc-ref %outputs "out")))
2046 #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
2047 (assoc-ref %outputs "out") "/lib"))
2048 #:phases (modify-phases %standard-phases
2050 (lambda* (#:key configure-flags #:allow-other-keys)
2051 ;; The configure script does not understand some of the GNU
2052 ;; options, so we only add the flags specified above.
2053 (apply invoke "./configure" configure-flags))))
2054 #:tests? #f)) ; no check target
2058 (synopsis "VP8/VP9 video codec")
2059 (description "libvpx is a codec for the VP8/VP9 video compression format.")
2060 (license license:bsd-3)
2061 (home-page "https://www.webmproject.org/")))
2063 (define-public youtube-dl
2066 (version "2020.07.28")
2069 (uri (string-append "https://github.com/ytdl-org/youtube-dl/"
2070 "releases/download/" version "/youtube-dl-"
2074 "1if7xyi7g9rpni1jbs7gv5m12s34qdb15dpfbbjn8120h16y7cqz"))))
2075 (build-system python-build-system)
2077 ;; The problem here is that the directory for the man page and completion
2078 ;; files is relative, and for some reason, setup.py uses the
2079 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
2080 ;; So, we need pass the prefix directly. In addition, make sure the Bash
2081 ;; completion file is called 'youtube-dl' rather than
2082 ;; 'youtube-dl.bash-completion'.
2083 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
2084 #:phases (modify-phases %standard-phases
2085 (add-before 'install 'fix-the-data-directories
2086 (lambda* (#:key outputs #:allow-other-keys)
2087 (let ((prefix (assoc-ref outputs "out")))
2088 (mkdir "bash-completion")
2089 (rename-file "youtube-dl.bash-completion"
2090 "bash-completion/youtube-dl")
2091 (substitute* "setup.py"
2092 (("youtube-dl\\.bash-completion")
2093 "bash-completion/youtube-dl")
2095 (string-append "'" prefix "/etc/"))
2097 (string-append "'" prefix "/share/")))
2099 (add-after 'install 'install-completion
2100 (lambda* (#:key outputs #:allow-other-keys)
2101 (let* ((out (assoc-ref outputs "out"))
2102 (zsh (string-append out
2103 "/share/zsh/site-functions")))
2105 (copy-file "youtube-dl.zsh"
2106 (string-append zsh "/_youtube-dl"))
2108 (synopsis "Download videos from YouTube.com and other sites")
2110 "Youtube-dl is a small command-line program to download videos from
2111 YouTube.com and many more sites.")
2112 (home-page "https://yt-dl.org")
2113 (license license:public-domain)))
2115 (define-public youtube-dl-gui
2117 (name "youtube-dl-gui")
2122 (uri (pypi-uri "Youtube-DLG" version))
2125 "0napxwzgls5ik1bxbp99vly32l23xpc4ng5kr24hfhf21ypjyadb"))))
2126 (build-system python-build-system)
2128 ;; In Guix, wxpython has not yet been packaged for Python 3.
2129 `(#:python ,python-2
2130 ;; This package has no tests.
2133 (modify-phases %standard-phases
2134 (add-before 'build 'patch-source
2135 (lambda* (#:key inputs #:allow-other-keys)
2136 ;; The youtube-dl-gui program lets you configure options. Some of
2137 ;; them are problematic, so we change their defaults.
2138 (substitute* "youtube_dl_gui/optionsmanager.py"
2139 ;; When this is true, the builder process will try (and fail) to
2140 ;; write logs to the builder user's home directory.
2141 (("'enable_log': True") "'enable_log': False")
2142 ;; This determines which youtube-dl program youtube-dl-gui will
2143 ;; run. If we don't set this, then youtube-dl-gui might download
2144 ;; an arbitrary copy from the Internet into the user's home
2145 ;; directory and run it, so let's make sure youtube-dl-gui uses
2146 ;; the youtube-dl from the inputs by default.
2147 (("'youtubedl_path': self.config_path")
2148 (string-append "'youtubedl_path': '"
2149 (assoc-ref inputs "youtube-dl")
2151 ;; When this is True, when youtube-dl-gui is finished downloading
2152 ;; a file, it will try (and possibly fail) to open the directory
2153 ;; containing the downloaded file. This can fail because it
2154 ;; assumes that xdg-open is in PATH. Unfortunately, simply
2155 ;; adding xdg-utils to the propagated inputs is not enough to
2156 ;; make this work, so for now we set the default to False.
2157 (("'open_dl_dir': True") "'open_dl_dir': False"))
2158 ;; The youtube-dl program from the inputs is actually a wrapper
2159 ;; script written in bash, so attempting to invoke it as a python
2160 ;; script will fail.
2161 (substitute* "youtube_dl_gui/downloaders.py"
2162 (("cmd = \\['python', self\\.youtubedl_path\\]")
2163 "cmd = [self.youtubedl_path]"))
2164 ;; Use relative paths for installing data files so youtube-dl-gui
2165 ;; installs the files relative to its prefix in the store, rather
2166 ;; than relative to /. Also, instead of installing data files into
2167 ;; $prefix/usr/share, install them into $prefix/share for
2168 ;; consistency (see: (standards) Directory Variables).
2169 (substitute* "setup.py"
2170 (("= '/usr/share") "= 'share"))
2171 ;; Update get_locale_file() so it finds the installed localization
2173 (substitute* "youtube_dl_gui/utils.py"
2174 (("os\\.path\\.join\\('/usr', 'share'")
2175 (string-append "os.path.join('"
2176 (assoc-ref %outputs "out")
2179 (add-after 'install 'create-desktop-file
2180 (lambda* (#:key outputs #:allow-other-keys)
2181 (let* ((out (assoc-ref outputs "out"))
2182 (applications (string-append out "/share/applications")))
2183 (mkdir-p applications)
2184 (call-with-output-file
2185 (string-append applications "/youtube-dl-gui.desktop")
2190 Name=Youtube-dl GUI~@
2191 Comment=Graphical interface to download video with youtube-dl~@
2192 Exec=youtube-dl-gui~@
2193 TryExec=youtube-dl-gui~@
2195 Icon=youtube-dl-gui~@
2197 Categories=AudioVideo;Audio;Video;Network~%")))
2200 `(("python2-wxpython" ,python2-wxpython)
2201 ("youtube-dl" ,youtube-dl)))
2202 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
2204 "GUI (Graphical User Interface) for @command{youtube-dl}")
2206 "Youtube-dlG is a GUI (Graphical User Interface) for
2207 @command{youtube-dl}. You can use it to download videos from YouTube and any
2208 other site that youtube-dl supports.")
2209 (license license:unlicense)))
2211 (define-public you-get
2214 (version "0.4.1456")
2218 (url "https://github.com/soimort/you-get")
2219 (commit (string-append "v" version))))
2220 (file-name (git-file-name name version))
2223 "0n6h5qkhjwsxy8rf6n4i8hd8dah38hbvchh9272c53gydgp9lp29"))))
2224 (build-system python-build-system)
2226 `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos
2229 (modify-phases %standard-phases
2230 (add-after 'unpack 'qualify-input-references
2231 ;; Explicitly invoke the input ffmpeg, instead of whichever one
2232 ;; happens to be in the user's $PATH at run time.
2233 (lambda* (#:key inputs #:allow-other-keys)
2234 (let ((ffmpeg (string-append (assoc-ref inputs "ffmpeg")
2236 (substitute* "src/you_get/processor/ffmpeg.py"
2237 ;; Don't blindly replace all occurrences of ‘'ffmpeg'’: the
2238 ;; same string is also used when sniffing ffmpeg's output.
2239 (("(FFMPEG == |\\()'ffmpeg'" _ prefix)
2240 (string-append prefix "'" ffmpeg "'")))
2242 #:tests? #f)) ; XXX some tests need Internet access
2243 (synopsis "Download videos, audio, or images from Web sites")
2245 "You-Get is a command-line utility to download media contents (videos,
2246 audio, images) from the Web. It can use either mpv or vlc for playback.")
2247 (home-page "https://you-get.org/")
2248 (license license:expat)))
2250 (define-public youtube-viewer
2252 (name "youtube-viewer")
2257 (url "https://github.com/trizen/youtube-viewer")
2259 (file-name (git-file-name name version))
2262 "1gc1b1zm55w2w62ayc6k51l31fswk17b072lpbq65is3ngjg6c98"))))
2263 (build-system perl-build-system)
2265 `(("perl-module-build" ,perl-module-build)))
2267 `(("perl-data-dump" ,perl-data-dump)
2268 ("perl-file-sharedir" ,perl-file-sharedir)
2269 ("perl-gtk2" ,perl-gtk2)
2270 ("perl-json" ,perl-json)
2271 ("perl-json-xs" ,perl-json-xs)
2272 ("perl-libwww" ,perl-libwww)
2273 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
2274 ("perl-lwp-useragent-cached" ,perl-lwp-useragent-cached)
2275 ("perl-mozilla-ca" ,perl-mozilla-ca)
2276 ("perl-term-readline-gnu" ,perl-term-readline-gnu)
2277 ("perl-unicode-linebreak" ,perl-unicode-linebreak)
2278 ("xdg-utils" ,xdg-utils)
2280 ;; Some videos play without youtube-dl, but others silently fail to.
2281 ("youtube-dl" ,youtube-dl)))
2283 `(#:modules ((guix build perl-build-system)
2286 ;; gtk-2/3 variants are both installed by default but the gtk3 variant
2287 ;; is broken without perl-gtk3.
2288 #:module-build-flags '("--gtk2")
2290 (modify-phases %standard-phases
2291 (add-after 'unpack 'refer-to-inputs
2292 (lambda* (#:key inputs #:allow-other-keys)
2293 (substitute* "lib/WWW/YoutubeViewer.pm"
2295 (format #f "'~a/bin/youtube-dl'"
2296 (assoc-ref inputs "youtube-dl"))))
2297 (substitute* '("bin/gtk2-youtube-viewer"
2298 "bin/gtk3-youtube-viewer")
2300 (format #f "'~a/bin/xdg-open'"
2301 (assoc-ref inputs "xdg-utils"))))
2303 (add-after 'install 'install-desktop
2304 (lambda* (#:key outputs #:allow-other-keys)
2305 (let* ((out (assoc-ref outputs "out"))
2306 (sharedir (string-append out "/share")))
2307 (install-file "share/gtk-youtube-viewer.desktop"
2308 (string-append sharedir "/applications"))
2309 (install-file "share/icons/gtk-youtube-viewer.png"
2310 (string-append sharedir "/pixmaps"))
2312 (add-after 'install 'wrap-program
2313 (lambda* (#:key outputs #:allow-other-keys)
2314 (let* ((out (assoc-ref outputs "out"))
2315 (bin-dir (string-append out "/bin/"))
2316 (site-dir (string-append out "/lib/perl5/site_perl/"))
2317 (lib-path (getenv "PERL5LIB")))
2318 (for-each (cut wrap-program <>
2319 `("PERL5LIB" ":" prefix (,lib-path ,site-dir)))
2320 (find-files bin-dir))
2323 "Lightweight application for searching and streaming videos from YouTube")
2325 "Youtube-viewer searches and plays YouTube videos in a native player.
2326 It comes with various search options; it can search for videos, playlists
2327 and/or channels. The videos are streamed directly in a selected video player
2328 at the best resolution (customizable) and with closed-captions (if available).
2329 Both command-line and GTK2 interface are available.")
2330 (home-page "https://github.com/trizen/youtube-viewer")
2331 (license license:perl-license)))
2333 (define-public libbluray
2339 (uri (string-append "https://download.videolan.org/videolan/"
2340 name "/" version "/"
2341 name "-" version ".tar.bz2"))
2344 "1zxfnw1xbghcj7b3zz5djndv6gwssxda19cz1lrlqrkg8577r7kd"))))
2345 (build-system gnu-build-system)
2347 `(#:configure-flags '("--disable-bdjava-jar")
2349 (modify-phases %standard-phases
2350 (add-after 'unpack 'refer-to-libxml2-in-.pc-file
2351 ;; Avoid the need to propagate libxml2 by referring to it
2352 ;; directly, as is already done for fontconfig & freetype.
2353 (lambda* (#:key inputs #:allow-other-keys)
2354 (let ((libxml2 (assoc-ref inputs "libxml2")))
2355 (substitute* "configure"
2356 ((" libxml-2.0") ""))
2357 (substitute* "src/libbluray.pc.in"
2358 (("^Libs.private:" field)
2359 (string-append field " -L" libxml2 "/lib -lxml2")))
2361 (add-before 'build 'fix-dlopen-paths
2362 (lambda* (#:key inputs #:allow-other-keys)
2363 (let ((libaacs (assoc-ref inputs "libaacs"))
2364 (libbdplus (assoc-ref inputs "libbdplus")))
2365 (substitute* "src/libbluray/disc/aacs.c"
2367 (string-append "\"" libaacs "/lib/libaacs\"")))
2368 (substitute* "src/libbluray/disc/bdplus.c"
2370 (string-append "\"" libbdplus "/lib/libbdplus\"")))
2372 (native-inputs `(("pkg-config" ,pkg-config)))
2374 `(("fontconfig" ,fontconfig)
2375 ("freetype" ,freetype)
2376 ("libaacs" ,libaacs)
2377 ("libbdplus" ,libbdplus)
2378 ("libxml2" ,libxml2)))
2379 (home-page "https://www.videolan.org/developers/libbluray.html")
2380 (synopsis "Blu-Ray Disc playback library")
2382 "libbluray is a library designed for Blu-Ray Disc playback for media
2383 players, like VLC or MPlayer.")
2384 (license license:lgpl2.1+)))
2386 (define-public libdvdread
2392 (uri (string-append "https://download.videolan.org/videolan/"
2393 "libdvdread/" version "/"
2394 "libdvdread-" version ".tar.bz2"))
2397 "1c7yqqn67m3y3n7nfrgrnzz034zjaw5caijbwbfrq89v46ph257r"))))
2398 (build-system gnu-build-system)
2400 `(#:configure-flags '("--with-libdvdcss=yes")))
2402 `(("pkg-config" ,pkg-config)))
2404 `(("libdvdcss" ,libdvdcss)))
2405 (home-page "http://dvdnav.mplayerhq.hu/")
2406 (synopsis "Library for reading video DVDs")
2408 "Libdvdread provides a simple foundation for reading DVD video
2409 disks. It provides the functionality that is required to access many
2410 DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
2411 authentication and descrambling (if an external libdvdcss library is
2413 (license license:gpl2+)))
2415 (define-public dvdauthor
2422 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
2426 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
2427 (build-system gnu-build-system)
2429 `(("libdvdread" ,libdvdread)
2431 ("imagemagick" ,imagemagick)
2432 ("libxml2" ,libxml2)
2433 ("freetype" ,freetype)))
2435 `(("pkg-config" ,pkg-config)))
2436 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
2437 (description "@command{dvdauthor} will generate a DVD-Video movie from a
2438 MPEG-2 stream containing VOB packets.")
2439 (home-page "http://dvdauthor.sourceforge.net")
2440 (license license:gpl3+)))
2442 (define-public libdvdnav
2448 (uri (string-append "https://download.videolan.org/videolan/"
2449 "libdvdnav/" version "/"
2450 "libdvdnav-" version ".tar.bz2"))
2453 "0cv7j8irsv1n2dadlnhr6i1b8pann2ah6xpxic41f04my6ba6rp5"))))
2454 (build-system gnu-build-system)
2456 `(("pkg-config" ,pkg-config)))
2458 `(("libdvdread" ,libdvdread)))
2459 (home-page "http://dvdnav.mplayerhq.hu/")
2460 (synopsis "Library for video DVD navigation features")
2462 "Libdvdnav is a library for developers of multimedia
2463 applications. It allows easy use of sophisticated DVD navigation features
2464 such as DVD menus, multiangle playback and even interactive DVD games. All
2465 this functionality is provided through a simple API which provides the DVD
2466 playback as a single logical stream of blocks, intermitted by special
2467 dvdnav events to report certain conditions. The main usage of libdvdnav is
2468 a loop regularly calling a function to get the next block, surrounded by
2469 additional calls to tell the library of user interaction. The whole
2470 DVD virtual machine and internal playback states are completely
2472 (license license:gpl2+)))
2474 (define-public libdvdcss
2480 (uri (string-append "https://download.videolan.org/pub/"
2481 name "/" version "/"
2482 name "-" version ".tar.bz2"))
2485 "0x957zzpf4w2cp8zlk29prj8i2q6hay3lzdzsyz8y3cwxivyvhkq"))))
2486 (build-system gnu-build-system)
2487 (home-page "https://www.videolan.org/developers/libdvdcss.html")
2488 (synopsis "Library for accessing DVDs as block devices")
2490 "libdvdcss is a simple library designed for accessing DVDs like a block
2491 device without having to bother about the decryption.")
2492 (license license:gpl2+)))
2494 (define-public srt2vtt
2501 "https://files.dthompson.us/srt2vtt/srt2vtt-"
2505 "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif"))))
2506 (build-system gnu-build-system)
2508 `(("guile" ,guile-2.0)))
2509 (synopsis "SubRip to WebVTT subtitle converter")
2510 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
2511 for use with HTML5 video.")
2512 (home-page "https://dthompson.us/projects/srt2vtt.html")
2513 (license license:gpl3+)))
2515 (define-public avidemux
2522 "mirror://sourceforge/avidemux/avidemux/" version "/"
2523 "avidemux_" version ".tar.gz"))
2526 "1acdb3m37vdzzbm8mwyibcn8msi7birb5v30qfi7jli5r00src3x"))
2527 (patches (search-patches "avidemux-install-to-lib.patch"))))
2528 (build-system cmake-build-system)
2531 ("pkg-config" ,pkg-config)
2532 ("python" ,python-wrapper)
2533 ("qttools" ,qttools)
2535 ;; FIXME: Once packaged, add libraries not found during the build.
2537 `(("alsa-lib" ,alsa-lib)
2538 ("fontconfig" ,fontconfig)
2539 ("freetype" ,freetype)
2540 ("fribidi" ,fribidi)
2545 ("libvdpau" ,libvdpau)
2546 ("libvorbis" ,libvorbis)
2549 ("pulseaudio" ,pulseaudio)
2554 `(#:tests? #f ; no check target
2556 ;; Make sure files inside the included ffmpeg tarball are
2558 (let ((ffmpeg "ffmpeg-4.1.4"))
2559 (modify-phases %standard-phases
2560 (add-before 'patch-source-shebangs 'unpack-ffmpeg
2562 (with-directory-excursion "avidemux_core/ffmpeg_package"
2563 (invoke "tar" "xf" (string-append ffmpeg ".tar.bz2"))
2564 (delete-file (string-append ffmpeg ".tar.bz2")))
2566 (add-after 'patch-source-shebangs 'repack-ffmpeg
2568 (with-directory-excursion "avidemux_core/ffmpeg_package"
2569 (substitute* (string-append ffmpeg "/configure")
2570 (("#! /bin/sh") (string-append "#!" (which "sh"))))
2571 (invoke "tar" "cjf" (string-append ffmpeg ".tar.bz2") ffmpeg
2572 ;; avoid non-determinism in the archive
2573 "--sort=name" "--mtime=@0"
2574 "--owner=root:0" "--group=root:0")
2575 (delete-file-recursively ffmpeg))
2579 ;; Copy-paste settings from the cmake build system.
2580 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
2581 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))
2584 (lambda* (#:key inputs outputs #:allow-other-keys)
2585 (let* ((out (assoc-ref outputs "out"))
2586 (lib (string-append out "/lib"))
2589 (lambda* (component srcdir #:optional (args '()))
2590 (let ((builddir (string-append "build_" component)))
2592 (with-directory-excursion builddir
2593 (apply invoke "cmake"
2594 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
2595 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
2596 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
2597 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
2598 "\"-Wl,-rpath=" lib "\"")
2599 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
2600 (string-append "../" srcdir)
2604 (number->string (parallel-job-count)))
2605 (invoke "make" "install"))))))
2607 (build_component "core" "avidemux_core")
2608 (build_component "cli" "avidemux/cli")
2609 (build_component "qt4" "avidemux/qt4")
2610 (build_component "plugins_common" "avidemux_plugins"
2611 '("-DPLUGIN_UI=COMMON"))
2612 (build_component "plugins_cli" "avidemux_plugins"
2613 '("-DPLUGIN_UI=CLI"))
2614 (build_component "plugins_qt4" "avidemux_plugins"
2615 '("-DPLUGIN_UI=QT4"))
2616 (build_component "plugins_settings" "avidemux_plugins"
2617 '("-DPLUGIN_UI=SETTINGS"))
2618 ;; Remove .exe and .dll file.
2619 (delete-file-recursively
2620 (string-append out "/share/ADM6_addons"))
2622 (delete 'install)))))
2623 (home-page "http://fixounet.free.fr/avidemux/")
2624 (synopsis "Video editor")
2625 (description "Avidemux is a video editor designed for simple cutting,
2626 filtering and encoding tasks. It supports many file types, including AVI,
2627 DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
2628 can be automated using projects, job queue and powerful scripting
2630 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
2631 ;; Software with various licenses is included, see License.txt.
2632 (license license:gpl2+)))
2634 (define-public vapoursynth
2636 (name "vapoursynth")
2641 (url "https://github.com/vapoursynth/vapoursynth")
2642 (commit (string-append "R" version))))
2643 (file-name (git-file-name name version))
2646 "1d298mlb24nlc2x7pixfbkd0qbpv4c706c32idsgpi96z1spkhvl"))))
2647 (build-system gnu-build-system)
2649 `(("autoconf" ,autoconf)
2650 ("automake" ,automake)
2651 ("cython" ,python-cython)
2652 ("libtool" ,libtool)
2653 ("pkg-config" ,pkg-config)
2657 `(("ffmpeg" ,ffmpeg)
2659 ("tesseract-ocr" ,tesseract-ocr)
2661 (home-page "http://www.vapoursynth.com/")
2662 (synopsis "Video processing framework")
2663 (description "VapourSynth is a C++ library and Python module for video
2664 manipulation. It aims to be a modern rewrite of Avisynth, supporting
2665 multithreading, generalized colorspaces, per frame properties, and videos with
2667 ;; src/core/cpufeatures only allows x86, ARM or PPC
2668 (supported-systems (fold delete %supported-systems
2669 '("mips64el-linux" "aarch64-linux")))
2670 ;; As seen from the source files.
2671 (license license:lgpl2.1+)))
2680 "http://downloads.xvid.com/downloads/xvidcore-"
2681 version ".tar.bz2"))
2684 "1xyg3amgg27zf7188kss7y248s0xhh1vv8rrk0j9bcsd5nasxsmf"))))
2685 (build-system gnu-build-system)
2686 (native-inputs `(("yasm" ,yasm)))
2689 (modify-phases %standard-phases
2690 (add-before 'configure 'pre-configure
2692 (chdir "build/generic")
2693 (substitute* "configure"
2694 (("#! /bin/sh") (string-append "#!" (which "sh"))))
2696 #:tests? #f)) ; no test suite
2697 (home-page "https://www.xvid.com/")
2698 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
2699 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
2700 codec library. It uses ASP features such as b-frames, global and quarter
2701 pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
2702 and custom quantization matrices.")
2703 (license license:gpl2+)))
2705 (define-public streamlink
2712 (uri (pypi-uri "streamlink" version))
2715 "1s458k8z1lv0w8i82sxs8dys66fwm4yr9j1m7fzp7r0piz8phcpd"))))
2716 (build-system python-build-system)
2717 (home-page "https://github.com/streamlink/streamlink")
2719 `(("python-freezegun" ,python-freezegun)
2720 ("python-pytest" ,python-pytest)
2721 ("python-mock" ,python-mock)
2722 ("python-requests-mock" ,python-requests-mock)))
2724 `(("python-pysocks" ,python-pysocks)
2725 ("python-websocket-client" ,python-websocket-client)
2726 ("python-iso3166" ,python-iso3166)
2727 ("python-iso639" ,python-iso639)
2728 ("python-isodate" ,python-isodate)
2729 ("python-pycryptodome" ,python-pycryptodome)
2730 ("python-requests" ,python-requests)
2731 ("python-urllib3" ,python-urllib3)))
2732 (synopsis "Extract streams from various services")
2733 (description "Streamlink is command-line utility that extracts streams
2734 from sites like Twitch.tv and pipes them into a video player of choice.")
2735 (license license:bsd-2)))
2737 (define-public twitchy
2738 (let ((commit "9beb36d80b16662414129693e74fa3a2fd97554e")) ; 3.4 has no tag
2741 (version (git-version "3.4" "1" commit))
2746 (url "https://github.com/BasioMeusPuga/twitchy")
2748 (file-name (git-file-name name version))
2751 "0di03h1j9ipp2bbnxxlxz07v87icyg2hmnsr4s7184z5ql8kpzr7"))))
2752 (build-system python-build-system)
2755 (modify-phases %standard-phases
2756 (add-after 'unpack 'patch-paths
2757 (lambda* (#:key inputs #:allow-other-keys)
2758 (substitute* "twitchy/twitchy_play.py"
2760 (string-append "\"" (assoc-ref inputs "streamlink")
2761 "/bin/streamlink ")))
2763 (add-before 'check 'check-setup
2765 (setenv "HOME" (getcwd)) ;Needs to write to ‘$HOME’.
2767 (add-after 'install 'install-rofi-plugin
2768 (lambda* (#:key outputs #:allow-other-keys)
2769 (install-file "plugins/rofi-twitchy"
2770 (string-append (assoc-ref outputs "out")
2774 `(("python-requests" ,python-requests)
2775 ("streamlink" ,streamlink)))
2776 (home-page "https://github.com/BasioMeusPuga/twitchy")
2777 (synopsis "Command-line interface for Twitch.tv")
2779 "This package provides a command-line interface for Twitch.tv")
2780 (license license:gpl3+))))
2789 (url "https://github.com/mltframework/mlt")
2790 (commit (string-append "v" version))))
2791 (file-name (git-file-name name version))
2794 "0jxv848ykw0csbnayrd710ylw46m0picfv7rpzsxz1vh4jzs395k"))))
2795 (build-system gnu-build-system)
2797 `(#:tests? #f ; no tests
2798 #:make-flags '("CC=gcc" "CXX=g++")
2800 (list "--enable-gpl3"
2803 (modify-phases %standard-phases
2805 'configure 'override-LDFLAGS
2806 (lambda* (#:key outputs #:allow-other-keys)
2807 (substitute* "config.mak"
2809 (string-append "LDFLAGS+=-Wl,-rpath="
2810 (assoc-ref outputs "out")
2814 `(("alsa-lib" ,alsa-lib)
2817 ("frei0r-plugins" ,frei0r-plugins)
2818 ("gdk-pixbuf" ,gdk-pixbuf)
2820 ("libxml2" ,libxml2)
2823 ("libexif" ,libexif)
2824 ("libvorbis" ,libvorbis)
2825 ("rubberband" ,rubberband)
2826 ("libsamplerate" ,libsamplerate)
2827 ("pulseaudio" ,pulseaudio)
2833 `(("pkg-config" ,pkg-config)))
2834 (home-page "https://www.mltframework.org/")
2835 (synopsis "Author, manage, and run multitrack audio/video compositions")
2837 "MLT is a multimedia framework, designed and developed for television
2838 broadcasting. It provides a toolkit for broadcasters, video editors, media
2839 players, transcoders, web streamers and many more types of applications. The
2840 functionality of the system is provided via an assortment of ready to use
2841 tools, XML authoring components, and an extensible plug-in based API.")
2842 (license license:gpl3)))
2844 (define-public v4l-utils
2850 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
2851 "/v4l-utils-" version ".tar.bz2"))
2854 "1bkqlrizx0j2rd6ybam2x17bjrpwzl4v4szmnzm3cmixis3w3npr"))))
2855 (build-system gnu-build-system)
2858 (list (string-append "--with-udevdir="
2859 (assoc-ref %outputs "out")
2863 ("pkg-config" ,pkg-config)))
2865 `(("alsa-lib" ,alsa-lib)
2867 ("libjpeg" ,libjpeg-turbo)
2871 (synopsis "Realtime video capture utilities for Linux")
2872 (description "The v4l-utils provide a series of libraries and utilities to
2873 be used for realtime video capture via Linux-specific APIs.")
2874 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
2875 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
2876 (license (list license:lgpl2.1+ license:gpl2))))
2885 (url "https://github.com/obsproject/obs-studio")
2887 (file-name (git-file-name name version))
2890 "0j2k65q3wfyfxhvkl6icz4qy0s3kfqhksizy2i3ah7yml266axbj"))))
2891 (build-system cmake-build-system)
2893 `(#:tests? #f ; no test suite
2895 (list (string-append "-DOBS_VERSION_OVERRIDE=" ,version))))
2897 `(("pkg-config" ,pkg-config)))
2899 `(("alsa-lib" ,alsa-lib)
2903 ("fontconfig" ,fontconfig)
2904 ("freetype" ,freetype)
2906 ("jansson" ,jansson)
2907 ("libx264" ,libx264)
2908 ("libxcomposite" ,libxcomposite)
2909 ("mbedtls" ,mbedtls-apache)
2911 ("pulseaudio" ,pulseaudio)
2914 ("qtx11extras" ,qtx11extras)
2916 ("v4l-utils" ,v4l-utils)
2918 (synopsis "Live streaming software")
2919 (description "Open Broadcaster Software provides a graphical interface for
2920 video recording and live streaming. OBS supports capturing audio and video
2921 from many input sources such as webcams, X11 (for screencasting), PulseAudio,
2923 (home-page "https://obsproject.com")
2924 (supported-systems '("x86_64-linux" "i686-linux"))
2925 (license license:gpl2+)))
2927 (define-public libvdpau
2935 (url "https://gitlab.freedesktop.org/vdpau/libvdpau.git")
2937 (file-name (git-file-name name version))
2940 "1fb1nh5apr9kzx9bm2lysjwpyva1s60b2l2p230nqgvb11q25hd2"))))
2941 (build-system meson-build-system)
2943 `(("pkg-config" ,pkg-config)))
2945 `(("libx11" ,libx11 "out")
2946 ("libxext" ,libxext)
2947 ("xorgproto" ,xorgproto)))
2948 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
2949 (synopsis "Video Decode and Presentation API")
2950 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
2951 provides an interface to video decode acceleration and presentation hardware
2952 present in modern GPUs.")
2953 (license (license:x11-style "file://COPYING"))))
2955 (define-public vdpauinfo
2962 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
2963 name "-" version ".tar.gz"))
2966 "1i2b0k9h8r0lnxlrkgqzmrjakgaw3f1ygqqwzx8w6676g85rcm20"))))
2967 (build-system gnu-build-system)
2969 `(("pkg-config" ,pkg-config)
2970 ("libx11" ,libx11)))
2972 `(("libvdpau" ,libvdpau)))
2973 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
2974 (synopsis "Tool to query the capabilities of a VDPAU implementation")
2975 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
2977 (license (license:x11-style "file://COPYING"))))
2979 (define-public libvdpau-va-gl
2981 (name "libvdpau-va-gl")
2986 (uri (string-append "https://github.com/i-rinat/libvdpau-va-gl/"
2987 "releases/download/v" version "/libvdpau-va-gl-"
2991 "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
2992 (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
2993 (modules '((guix build utils)))
2994 (snippet '(begin (delete-file-recursively "3rdparty")
2996 (build-system cmake-build-system)
2998 '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
3000 `(("libvdpau" ,libvdpau)
3001 ("pkg-config" ,pkg-config)))
3005 (home-page "https://github.com/i-rinat/libvdpau-va-gl")
3006 (synopsis "VDPAU driver with VA-API/OpenGL backend")
3008 "Many applications can use VDPAU to accelerate portions of the video
3009 decoding process and video post-processing to the GPU video hardware. Since
3010 there is no VDPAU available on Intel chips, they fall back to different drawing
3011 techniques. This driver uses OpenGL under the hood to accelerate drawing and
3012 scaling and VA-API (if available) to accelerate video decoding.")
3013 (license license:expat)))
3015 (define-public recordmydesktop
3017 (name "recordmydesktop")
3021 (uri (string-append "mirror://sourceforge/" name "/" name "/"
3022 version "/recordmydesktop-" version ".tar.gz"))
3025 "133kkl5j0r877d41bzj7kj0vf3xm8x80yyx2n8nqxrva304f58ik"))))
3026 (build-system gnu-build-system)
3027 (inputs `(("popt" ,popt)
3032 ("libxfixes" ,libxfixes)
3033 ("libxdamage" ,libxdamage)
3034 ("libxext" ,libxext)
3035 ("alsa-lib" ,alsa-lib)
3036 ("libvorbis" ,libvorbis)
3037 ("libtheora" ,libtheora)))
3038 (home-page "http://recordmydesktop.sourceforge.net/")
3039 (synopsis "Desktop session video recorder")
3041 "recordMyDesktop is a command-line tool that captures the activity in
3042 your graphical desktop and encodes it as a video. This is a useful tool for
3043 making @dfn{screencasts}.")
3044 (license license:gpl2+)))
3046 (define-public simplescreenrecorder
3048 (name "simplescreenrecorder")
3054 (url "https://github.com/MaartenBaert/ssr")
3056 (file-name (git-file-name name version))
3059 "1dzp5yzqlha65crzklx2qlan6ssw1diwzfpc4svd7gnr858q2292"))))
3060 (build-system cmake-build-system)
3061 ;; Although libx11, libxfixes, libxext are listed as build dependencies in
3062 ;; README.md, the program builds and functions properly without them.
3063 ;; As a result, they are omitted. Please add them back if problems appear.
3065 `(("alsa-lib" ,alsa-lib)
3070 ("libxinerama" ,libxinerama)
3071 ("pulseaudio" ,pulseaudio)
3073 ("qtx11extras" ,qtx11extras)))
3074 (native-inputs `(("pkg-config" ,pkg-config)))
3077 (list "-DWITH_QT5=TRUE")
3078 #:tests? #f)) ; no test suite
3079 ;; Using HTTPS causes part of the page to be displayed improperly.
3080 (home-page "https://www.maartenbaert.be/simplescreenrecorder/")
3081 (synopsis "Screen recorder")
3082 (description "SimpleScreenRecorder is an easy to use screen recorder with
3083 a graphical user interface. It supports recording the entire screen, or a
3084 part of it, and allows encoding in many different codecs and file formats.
3085 Other features include a live preview and live streaming.")
3086 (license (list license:gpl3+ ; most files
3087 license:zlib ; glinject/elfhacks.*
3088 license:isc ; glinject/*
3089 license:x11)))) ; build-aux/install-sh
3091 (define-public libsmpeg
3094 (version "0.4.5-401")
3098 (url "svn://svn.icculus.org/smpeg/trunk/")
3099 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
3100 (file-name (string-append name "-" version "-checkout"))
3103 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
3104 (build-system gnu-build-system)
3106 ;; libsmpeg fails to build with -std=c++11, which is the default with
3107 ;; GCC 7. Also, 'configure' does CXXFLAGS=$CFLAGS, hence this hack.
3108 '(#:configure-flags '("CFLAGS=-O2 -g -std=c++03")))
3110 `(("autoconf" ,autoconf)
3111 ("automake" ,automake)))
3114 (home-page "https://icculus.org/smpeg/")
3115 (synopsis "SDL MPEG decoding library")
3117 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
3118 with sound support. Video playback is based on the ubiquitous Berkeley MPEG
3119 player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
3120 library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
3121 and MPEG system streams.")
3122 (license (list license:expat
3128 (define-public libsmpeg-with-sdl1
3129 (package (inherit libsmpeg)
3131 (version "0.4.5-399")
3135 (url "svn://svn.icculus.org/smpeg/trunk/")
3136 (revision 399))) ; tagged release 0.4.5
3137 (file-name (string-append name "-" version "-checkout"))
3140 "0jfi085rf3fa5xsn0vd3nqf32my8ph9c6a9445y7a8lrlz4dms64"))))
3144 (define-public libbdplus
3151 (uri (string-append "https://ftp.videolan.org/pub/videolan/libbdplus/"
3152 version "/" name "-" version ".tar.bz2"))
3154 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
3156 `(("libgcrypt" ,libgcrypt)))
3157 (build-system gnu-build-system)
3158 (home-page "https://www.videolan.org/developers/libbdplus.html")
3159 (synopsis "Library for decrypting certain Blu-Ray discs")
3160 (description "libbdplus is a library which implements the BD+ System
3162 (license license:lgpl2.1+)))
3164 (define-public libaacs
3171 (uri (string-append "https://ftp.videolan.org/pub/videolan/libaacs/"
3172 version "/libaacs-" version ".tar.bz2"))
3174 (base32 "11skjqjlldmbjkyxdcz4fmcn6y4p95r1xagbcnjy4ndnzf0l723d"))))
3176 `(("libgcrypt" ,libgcrypt)))
3180 (build-system gnu-build-system)
3181 (home-page "https://www.videolan.org/developers/libaacs.html")
3182 (synopsis "Library for decrypting certain Blu-Ray discs")
3183 (description "libaacs is a library which implements the Advanced Access
3184 Content System specification.")
3185 (license license:lgpl2.1+)))
3187 (define-public mps-youtube
3189 (name "mps-youtube")
3195 (url "https://github.com/mps-youtube/mps-youtube")
3196 (commit (string-append "v" version))))
3197 (file-name (git-file-name name version))
3200 "1w1jhw9rg3dx7vp97cwrk5fymipkcy2wrbl1jaa38ivcjhqg596y"))))
3201 (build-system python-build-system)
3203 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
3204 ;; test suite results differ depending on the country and also introduce
3205 ;; non-determinism in the tests.
3206 ;; https://github.com/mps-youtube/mps-youtube/issues/556
3209 `(("python-pafy" ,python-pafy)
3210 ("python-pygobject" ,python-pygobject))) ; For mpris2 support
3211 (home-page "https://github.com/mps-youtube/mps-youtube")
3212 (synopsis "Terminal based YouTube player and downloader")
3214 "@code{mps-youtube} is based on mps, a terminal based program to
3215 search, stream and download music. This implementation uses YouTube as
3216 a source of content and can play and download video as well as audio.
3217 It can use either mpv or mplayer for playback, and for conversion of
3218 formats ffmpeg or libav is used. Users should install one of the
3219 supported players in addition to this package.")
3220 (license license:gpl3+)))
3222 (define-public handbrake
3228 (uri (string-append "https://github.com/HandBrake/HandBrake/"
3229 "releases/download/" version "/"
3230 "HandBrake-" version "-source.tar.bz2"))
3233 "11bzhyp052bmng5119x74xvdj5632smx6qsk537ygda8bzckg2i1"))
3234 (modules '((guix build utils)))
3236 ;; Remove "contrib" and source not necessary for
3237 ;; building/running under a GNU environment.
3239 (for-each delete-file-recursively
3240 '("contrib" "macosx" "win")) ; 540KiB, 11MiB, 5.9MiB resp.
3241 (substitute* "make/include/main.defs"
3242 ;; Disable unconditional inclusion of "contrib" libraries
3243 ;; (ffmpeg, libvpx, libdvdread, libdvdnav, and libbluray),
3244 ;; which would lead to fetching and building of these
3245 ;; libraries. Use our own instead.
3246 (("MODULES \\+= contrib") "# MODULES += contrib"))
3248 (build-system glib-or-gtk-build-system)
3250 `(("automake" ,automake) ; GUI subpackage must be bootstrapped
3251 ("autoconf" ,autoconf)
3252 ("intltool" ,intltool)
3253 ("libtool" ,libtool)
3254 ("pkg-config" ,pkg-config)
3255 ("python" ,python-2))) ; For configuration
3258 ("dbus-glib" ,dbus-glib)
3260 ("fontconfig" ,fontconfig)
3261 ("freetype" ,freetype)
3263 ("gstreamer" ,gstreamer)
3264 ("gst-plugins-base" ,gst-plugins-base)
3266 ("jansson" ,jansson)
3269 ("libbluray" ,libbluray)
3271 ("libdvdnav" ,libdvdnav)
3272 ("libdvdread" ,libdvdread)
3273 ("libgudev" ,libgudev)
3274 ("libmpeg2" ,libmpeg2)
3275 ("libnotify" ,libnotify)
3276 ("libnuma" ,numactl)
3279 ("libsamplerate" ,libsamplerate)
3280 ("libtheora" ,libtheora)
3281 ("libvorbis" ,libvorbis)
3283 ("libxml2" ,libxml2)
3284 ("libx264" ,libx264)
3289 `(#:tests? #f ;tests require Ruby and claim to be unsupported
3291 (list "--disable-gtk-update-checks"
3293 (string-append "CPPFLAGS=-I"
3294 (assoc-ref %build-inputs "libxml2")
3298 (modify-phases %standard-phases
3300 ;; Run bootstrap ahead of time so that shebangs get patched.
3302 (setenv "CONFIG_SHELL" (which "sh"))
3303 ;; Patch the Makefile so that it doesn't bootstrap again.
3304 (substitute* "gtk/module.rules"
3305 ((".*autoreconf.*") ""))
3306 (with-directory-excursion "gtk"
3307 (invoke "autoreconf" "-fiv"))))
3308 (add-before 'configure 'patch-SHELL
3310 (substitute* "gtk/po/Makefile.in.in"
3311 (("SHELL = /bin/sh") "SHELL = @SHELL@"))
3313 (add-before 'configure 'relax-reqs
3315 (substitute* "make/configure.py"
3316 ;; cmake is checked for so that it can be used to build
3317 ;; contrib/harfbuzz and contrib/x265, but we get these as
3318 ;; inputs, so don't abort if it's not found. Similarly, meson
3319 ;; and ninja are only needed for contrib/libdav1d, and nasm
3321 (("((cmake|meson|ninja|nasm) *=.*abort=)True" _ &)
3322 (string-append & "False")))
3325 (lambda* (#:key outputs configure-flags #:allow-other-keys)
3326 ;; 'configure' is not an autoconf-generated script, and
3327 ;; errors on unrecognized arguments,
3328 ;; e.g. --enable-fast-install
3329 (let ((out (assoc-ref outputs "out")))
3330 (apply invoke "./configure"
3331 (string-append "--prefix=" out)
3332 (or configure-flags '())))))
3333 (add-after 'configure 'chdir-build
3334 (lambda _ (chdir "./build") #t)))))
3335 (home-page "https://handbrake.fr")
3336 (synopsis "Video transcoder")
3338 "HandBrake is a tool for converting video from any format to a selection
3339 of modern, widely supported codecs.")
3340 ;; Some under GPLv2+, some under LGPLv2.1+, and portions under BSD3.
3341 ;; Combination under GPLv2. See LICENSE.
3342 (license license:gpl2)))
3344 (define-public intel-vaapi-driver
3346 (name "intel-vaapi-driver")
3352 (url "https://github.com/intel/intel-vaapi-driver")
3355 (base32 "1cidki3av9wnkgwi7fklxbg3bh6kysf8w3fk2qadjr05a92mx3zp"))
3356 (file-name (git-file-name name version))))
3357 (build-system gnu-build-system)
3359 `(("autoconf" ,autoconf)
3360 ("automake" ,automake)
3361 ("libtool" ,libtool)
3362 ("pkg-config" ,pkg-config)))
3364 `(("libdrm" ,libdrm)
3366 ("libx11" ,libx11)))
3369 (modify-phases %standard-phases
3370 (add-before 'configure 'set-target-directory
3371 (lambda* (#:key outputs #:allow-other-keys)
3372 (let ((out (assoc-ref outputs "out")))
3373 (setenv "LIBVA_DRIVERS_PATH" (string-append out "/lib/dri"))
3375 ;; XXX Because of <https://issues.guix.gnu.org/issue/22138>, we need to add
3376 ;; this to all VA-API back ends instead of once to libva.
3377 (native-search-paths
3378 (list (search-path-specification
3379 (variable "LIBVA_DRIVERS_PATH")
3380 (files '("lib/dri")))))
3381 (supported-systems '("i686-linux" "x86_64-linux"))
3382 (home-page "https://01.org/linuxmedia/vaapi")
3383 (synopsis "VA-API video acceleration driver for Intel GEN Graphics devices")
3385 "This is the @acronym{VA-API, Video Acceleration API} back end required for
3386 hardware-accelerated video processing on Intel GEN Graphics devices supported by
3387 the i915 driver, such as integrated Intel HD Graphics. It provides access to
3388 both hardware and shader functionality for faster encoding, decoding, and
3389 post-processing of video formats like MPEG2, H.264/AVC, and VC-1.")
3390 (license (list license:bsd-2 ; src/gen9_vp9_const_def.c
3391 license:expat)))) ; the rest, excluding the test suite
3393 (define-public openh264
3400 (url "https://github.com/cisco/openh264")
3401 (commit (string-append "v" version))))
3402 (file-name (git-file-name name version))
3405 "0ffav46pz3sbj92nipd62z03fibyqgclfq9w8lgr80s6za6zdk5s"))))
3406 (build-system gnu-build-system)
3409 ("python" ,python)))
3411 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
3413 #:test-target "test"
3414 #:phases (modify-phases %standard-phases
3415 ;; no configure script
3416 (delete 'configure))))
3417 (home-page "https://www.openh264.org/")
3418 (synopsis "H264 decoder library")
3420 "Openh264 is a library which can decode H264 video streams.")
3421 (license license:bsd-2)))
3423 (define-public libmp4v2
3430 ;; XXX: The new location of upstream is uncertain and will become relevant the
3431 ;; moment when the googlecode archive shuts down. It is past the date it
3432 ;; should've been turned off. I tried to communicate with upstream, but this
3433 ;; wasn't very responsive and not very helpful. The short summary is, it is
3434 ;; chaos when it comes to the amount of forks and only time will tell where
3435 ;; the new upstream location is.
3436 (uri (string-append "https://storage.googleapis.com/google-"
3437 "code-archive-downloads/v2/"
3438 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
3439 (file-name (string-append name "-" version ".tar.bz2"))
3440 (patches (search-patches "libmp4v2-c++11.patch"))
3443 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
3444 (build-system gnu-build-system)
3446 "static")) ; 3.7MiB .a file
3449 (modify-phases %standard-phases
3450 (add-after 'unpack 'remove-dates
3452 ;; Make the build reproducible.
3453 (substitute* "configure"
3454 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
3455 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
3457 (add-after 'install 'move-static-libraries
3458 (lambda* (#:key outputs #:allow-other-keys)
3459 ;; Move static libraries to the "static" output.
3460 (let* ((out (assoc-ref outputs "out"))
3461 (lib (string-append out "/lib"))
3462 (static (assoc-ref outputs "static"))
3463 (slib (string-append static "/lib")))
3465 (for-each (lambda (file)
3466 (install-file file slib)
3468 (find-files lib "\\.a$"))
3471 `(("help2man" ,help2man)
3472 ("dejagnu" ,dejagnu)))
3473 (home-page "https://code.google.com/archive/p/mp4v2/")
3474 (synopsis "API to create and modify mp4 files")
3476 "The MP4v2 library provides an API to create and modify mp4 files as defined by
3477 ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
3478 file format that has been used as a multimedia file format in a variety of platforms and
3479 applications. It is a very powerful and extensible format that can accommodate
3480 practically any type of media.")
3481 (license license:mpl1.1)))
3483 (define-public libmediainfo
3485 (name "libmediainfo")
3489 (uri (string-append "https://mediaarea.net/download/source/"
3490 name "/" version "/"
3491 name "_" version ".tar.xz"))
3494 "19n8h9jq42b6r3dbag77fzwfksfywszmzpi636w87fvc1nqldlqj"))))
3495 ;; TODO add a Big Buck Bunny webm for tests.
3497 `(("autoconf" ,autoconf)
3498 ("automake" ,automake)
3499 ("libtool" ,libtool)
3500 ("pkg-config" ,pkg-config)
3502 ("tinyxml2" ,tinyxml2)
3504 ("libzen" ,libzen)))
3505 (build-system gnu-build-system)
3507 '(#:tests? #f ; see above TODO
3509 ;; build scripts not in root of archive
3510 (modify-phases %standard-phases
3511 (add-after 'unpack 'change-to-build-dir
3513 (chdir "Project/GNU/Library")
3515 (home-page "https://mediaarea.net/en/MediaInfo")
3516 (synopsis "Library for retrieving media metadata")
3517 (description "MediaInfo is a library used for retrieving technical
3518 information and other metadata about audio or video files. A non-exhaustive
3519 list of the information MediaInfo can retrieve from media files include:
3522 @item General: title, author, director, album, track number, date, duration...
3523 @item Video: codec, aspect, fps, bitrate...
3524 @item Audio: codec, sample rate, channels, language, bitrate...
3525 @item Text: language of subtitle
3526 @item Chapters: number of chapters, list of chapters
3529 MediaInfo supports the following formats:
3532 @item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
3533 MPEG-2, MPEG-4, DVD (VOB)...
3534 @item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
3535 @item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
3536 @item Subtitles: SRT, SSA, ASS, SAMI...
3538 (license license:bsd-2)))
3540 ;; TODO also have a GUI version available
3541 (define-public mediainfo
3547 ;; Warning: This source has proved unreliable 1 time at least.
3548 ;; Consider an alternate source or report upstream if this
3550 (uri (string-append "https://mediaarea.net/download/source/"
3551 name "/" version "/"
3552 name "_" version ".tar.xz"))
3555 "1baf2dj5s3g1x4ssqli1b2r1203syk42m09zhp36qcinmfixv11l"))))
3557 `(("autoconf" ,autoconf)
3558 ("automake" ,automake)
3559 ("libtool" ,libtool)
3560 ("pkg-config" ,pkg-config)
3562 ("libmediainfo" ,libmediainfo)
3563 ("libzen" ,libzen)))
3564 (build-system gnu-build-system)
3566 '(#:tests? #f ; lacks tests
3568 ;; build scripts not in root of archive
3569 (modify-phases %standard-phases
3570 (add-after 'unpack 'change-to-build-dir
3572 (chdir "Project/GNU/CLI")
3574 (home-page "https://mediaarea.net/en/MediaInfo")
3575 (synopsis "Utility for reading media metadata")
3576 (description "MediaInfo is a utility used for retrieving technical
3577 information and other metadata about audio or video files. It supports the
3578 many codecs and formats supported by libmediainfo.")
3579 (license license:bsd-2)))
3581 (define-public livemedia-utils
3583 (name "livemedia-utils")
3584 (version "2019.05.29")
3588 "https://download.videolan.org/contrib/live555/live."
3592 "08i63jr8ihn1xiq5z5n3yls3yz6li5sg0s454l56p5bcvbrw81my"))))
3593 (build-system gnu-build-system)
3595 '(#:tests? #f ; no tests
3596 #:make-flags (list "CC=gcc"
3597 (string-append "LDFLAGS=-Wl,-rpath="
3598 (assoc-ref %outputs "out") "/lib")
3599 (string-append "PREFIX="
3600 (assoc-ref %outputs "out")))
3601 #:phases (modify-phases %standard-phases
3602 (add-before 'configure 'fix-makefiles-generation
3604 (substitute* "genMakefiles"
3609 (invoke "./genMakefiles"
3610 "linux-with-shared-libraries"))))))
3611 (home-page "http://www.live555.com/liveMedia/")
3612 (synopsis "Set of C++ libraries for multimedia streaming")
3613 (description "This code forms a set of C++ libraries for multimedia
3614 streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
3615 can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
3616 JPEG video, and several audio codecs. They can easily be extended to support
3617 additional (audio and/or video) codecs, and can also be used to build basic
3618 RTSP or SIP clients and servers.")
3619 (license license:lgpl3+)))
3621 (define-public libdvbpsi
3628 "https://download.videolan.org/pub/libdvbpsi/"
3629 version "/libdvbpsi-" version ".tar.bz2"))
3632 "04h1l3vrkrdsrvkgzcr51adk10g6hxcxvgjphyyxz718ry5rkd82"))))
3633 (build-system gnu-build-system)
3634 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
3635 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
3637 (description "libdvbpsi is a simple library designed for decoding and
3638 generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
3639 and ITU-T H.222.0.")
3640 (license license:lgpl2.1)))
3642 (define-public ffms2
3646 (home-page "https://github.com/FFMS/ffms2")
3650 (url "https://github.com/FFMS/ffms2")
3652 (file-name (git-file-name name version))
3655 "0dkz5b3gxq5p4xz0qqg6l2sigszrlsinz3skyf0ln4wf3zrvf8m5"))))
3656 (build-system gnu-build-system)
3659 (list "--enable-avresample")))
3663 `(("ffmpeg" ,ffmpeg)))
3665 `(("pkg-config" ,pkg-config)))
3666 (synopsis "Cross-platform wrapper around ffmpeg/libav")
3668 "FFMpegSource is a wrapper library around ffmpeg/libav that allows
3669 programmers to access a standard API to open and decompress media files.")
3670 ;; sources are distributed under a different license that the binary.
3671 ;; see https://github.com/FFMS/ffms2/blob/master/COPYING
3672 (license license:gpl2+))); inherits from ffmpeg
3674 (define-public aegisub
3681 "http://ftp.aegisub.org/pub/archives/releases/source/"
3682 name "-" version ".tar.xz"))
3685 "11b83qazc8h0iidyj1rprnnjdivj1lpphvpa08y53n42bfa36pn5"))
3686 (patches (search-patches "aegisub-icu59-include-unistr.patch"
3687 "aegisub-make43.patch"
3688 "aegisub-boost68.patch"))))
3689 (build-system gnu-build-system)
3692 (list "--disable-update-checker"
3693 "--without-portaudio"
3696 "CXXFLAGS=-DU_USING_ICU_NAMESPACE=1")
3697 ;; tests require busted, a lua package we don't have yet
3700 (modify-phases %standard-phases
3701 (add-before 'configure 'fix-ldflags
3703 (setenv "LDFLAGS" "-pthread")
3705 (add-after 'unpack 'fix-boost-headers
3708 '("src/subtitles_provider_libass.cpp"
3709 "src/colour_button.cpp"
3710 "src/video_provider_dummy.cpp"
3711 "./src/video_frame.cpp")
3712 (("#include <boost/gil/gil_all.hpp>")
3713 "#include <boost/gil.hpp>"))
3719 ("hunspell" ,hunspell)
3722 ("alsa-lib" ,alsa-lib)
3723 ("pulseaudio" ,pulseaudio)
3725 ("freetype" ,freetype)
3726 ("wxwidgets-gtk2" ,wxwidgets-gtk2)))
3728 `(("intltool" ,intltool)
3729 ("desktop-file-utils" ,desktop-file-utils)
3730 ("pkg-config" ,pkg-config)))
3731 (home-page "http://www.aegisub.org/")
3732 (synopsis "Subtitle engine")
3734 "Aegisub is a tool for creating and modifying subtitles. Aegisub makes
3735 it quick and easy to time subtitles to audio, and features many powerful
3736 tools for styling them, including a built-in real-time video preview.")
3737 (license (list license:bsd-3 ; the package is licensed under the bsd-3, except
3738 license:mpl1.1 ; for vendor/universalchardet under the mpl1.1
3739 license:expat)))) ; and src/gl that is under a license similar
3740 ; the the Expat license, with a rewording (Software -> Materials). (called MIT
3741 ; by upstream). See https://github.com/Aegisub/Aegisub/blob/master/LICENCE
3742 ; src/MatroskaParser.(c|h) is under bsd-3 with permission from the author
3744 (define-public gst-transcoder
3746 (name "gst-transcoder")
3752 (url "https://github.com/pitivi/gst-transcoder")
3754 (file-name (git-file-name name version))
3757 "0nw1zykqc6c8xs3ri55pm00pwyz93z4y4nd880apfiwj7yv5p3az"))))
3758 (build-system meson-build-system)
3760 `(("gobject-introspection" ,gobject-introspection)
3762 ("gstreamer" ,gstreamer)
3763 ("gst-plugins-base" ,gst-plugins-base)))
3765 `(("python" ,python)
3766 ("pkg-config" ,pkg-config)))
3767 (home-page "https://github.com/pitivi/gst-transcoder/")
3768 (synopsis "GStreamer Transcoding API")
3769 (description "GStreamer Transcoding API")
3770 (license license:lgpl2.1)))
3779 (uri (string-append "mirror://sourceforge/gmerlin/"
3780 name "/" version "/"
3781 name "-" version ".tar.gz"))
3782 (file-name (string-append name "-" version ".tar.gz"))
3785 "1kikkn971a14zzm7svi7190ldc14fjai0xyhpbcmp48s750sraji"))))
3786 (build-system gnu-build-system)
3788 '(#:configure-flags '("LIBS=-lm")))
3790 `(("pkg-config" ,pkg-config)
3791 ("doxygen" ,doxygen)))
3792 (home-page "http://gmerlin.sourceforge.net")
3793 (synopsis "Low level library for multimedia API building")
3795 "Gavl is short for Gmerlin Audio Video Library. It is a low level
3796 library, upon which multimedia APIs can be built. Gavl handles all the
3797 details of audio and video formats like colorspaces, sample rates,
3798 multichannel configurations, etc. It provides standardized definitions for
3799 those formats as well as container structures for carrying audio samples or
3800 video images inside an application.
3802 In addition, it handles the sometimes ugly task of converting between all
3803 these formats and provides some elementary operations (copying, scaling,
3804 alpha blending etc).")
3805 (license license:gpl3)))
3807 (define-public frei0r-plugins
3809 (name "frei0r-plugins")
3814 (uri (string-append "https://files.dyne.org/frei0r/"
3815 "frei0r-plugins-" version ".tar.gz"))
3818 "0fjji3060r4fwr7vn91lwfzl80lg3my9lkp94kbyw8xwz7qgh7qv"))))
3819 (build-system gnu-build-system)
3822 (modify-phases %standard-phases
3823 (add-after 'unpack 'patch-Makefile
3825 ;; XXX: The 1.7.0 Makefile looks for files that have slightly different
3826 ;; names in the tarball. Try removing this for future versions.
3827 (substitute* "Makefile.in"
3828 (("README\\.md ChangeLog TODO AUTHORS")
3829 "README.txt ChangeLog.txt TODO.txt AUTHORS.txt"))
3831 ;; TODO: opencv for additional face detection filters.
3836 `(("pkg-config" ,pkg-config)))
3837 (home-page "https://www.dyne.org/software/frei0r/")
3838 (synopsis "Minimalistic plugin API for video effects")
3840 "Frei0r is a minimalistic plugin API for video effects.
3841 The main emphasis is on simplicity for an API that will round up
3842 the most common video effects into simple filters, sources and
3843 mixers that can be controlled by parameters. Frei0r wants to
3844 provide a way to share these simple effects between many
3845 applications, avoiding their reimplementation by different projects.
3846 It counts more than 100 plugins.")
3847 (license (list license:gpl2+
3848 ;; The following files are licensed as LGPL2.1+:
3849 ;; src/generator/ising0r/ising0r.c
3850 ;; src/generator/onecol0r/onecol0r.cpp
3851 ;; src/generator/nois0r/nois0r.cpp
3852 ;; src/generator/lissajous0r/lissajous0r.cpp
3853 ;; src/filter/ndvi/gradientlut.hpp
3854 ;; src/filter/ndvi/ndvi.cpp
3855 ;; src/filter/facedetect/facedetect.cpp
3856 license:lgpl2.1+))))
3858 (define-public motion
3862 (home-page "https://motion-project.github.io/")
3866 (url "https://github.com/Motion-Project/motion")
3867 (commit (string-append "release-" version))))
3870 "05c1gx75xy2hw49x6vkydvwxbr80kipsc3nr906k3hq8735svx6f"))
3871 (file-name (git-file-name name version))))
3872 (build-system gnu-build-system)
3874 `(("autoconf" ,autoconf-wrapper)
3875 ("automake" ,automake)
3876 ("gettext" ,gettext-minimal)
3877 ("pkg-config" ,pkg-config)))
3879 `(("libjpeg" ,libjpeg-turbo)
3881 ("libmicrohttpd" ,libmicrohttpd)
3882 ("sqlite" ,sqlite)))
3884 '(#:phases (modify-phases %standard-phases
3887 (patch-shebang "version.sh")
3888 (invoke "autoreconf" "-vfi"))))
3889 #:configure-flags '("--sysconfdir=/etc")
3890 #:make-flags (list (string-append "sysconfdir="
3891 (assoc-ref %outputs "out")
3894 #:tests? #f)) ; no 'check' target
3895 (synopsis "Detect motion from video signals")
3897 "Motion is a program that monitors the video signal from one or more
3898 cameras and is able to detect if a significant part of the picture has
3899 changed. Or in other words, it can detect motion.")
3901 ;; Some files say "version 2" and others "version 2 or later".
3902 (license license:gpl2)))
3904 (define-public subdl
3905 (let ((commit "4cf5789b11f0ff3f863b704b336190bf968cd471")
3909 (version (git-version "1.0.3" revision commit))
3913 (url "https://github.com/alexanderwink/subdl")
3915 (file-name (git-file-name name version))
3918 "0kmk5ck1j49q4ww0lvas2767kwnzhkq0vdwkmjypdx5zkxz73fn8"))))
3919 (build-system trivial-build-system)
3921 `(#:modules ((guix build utils))
3923 (use-modules (guix build utils))
3924 (let* ((out (assoc-ref %outputs "out"))
3925 (bin (string-append out "/bin"))
3926 (source (assoc-ref %build-inputs "source"))
3927 (python (assoc-ref %build-inputs "python")))
3928 (install-file (string-append source "/subdl") bin)
3929 (patch-shebang (string-append bin "/subdl")
3930 (list (string-append python "/bin")))))))
3931 (inputs `(("python" ,python)))
3932 (synopsis "Command-line tool for downloading subtitles from opensubtitles.org")
3933 (description "Subdl is a command-line tool for downloading subtitles from
3934 opensubtitles.org. By default, it will search for English subtitles, display
3935 the results, download the highest-rated result in the requested language and
3936 save it to the appropriate filename.")
3937 (license license:gpl3+)
3938 (home-page "https://github.com/alexanderwink/subdl"))))
3940 (define-public l-smash
3947 (url "https://github.com/l-smash/l-smash")
3948 (commit (string-append "v" version))))
3949 (file-name (git-file-name name version))
3952 "0rcq9727im6kd8da8b7kzzbzxdldvmh5nsljj9pvr4m3lj484b02"))))
3953 (build-system gnu-build-system)
3955 `(#:tests? #f ;no tests
3957 (list (string-append "LDFLAGS=-Wl,-L.,-rpath="
3958 (assoc-ref %outputs "out") "/lib"))
3960 (modify-phases %standard-phases
3961 ;; configure fails if it is followed by CONFIG_SHELL
3963 (lambda* (#:key outputs #:allow-other-keys)
3964 (let ((out (assoc-ref outputs "out")))
3965 (invoke "./configure" (string-append "--prefix=" out)
3966 "--disable-static")))))))
3968 `(("which" ,which)))
3969 (home-page "https://l-smash.github.io/l-smash/")
3970 (synopsis "MP4 multiplexer and demultiplexer library")
3972 "L-SMASH is a cross-platform library that handles the ISO base media file
3973 format and some of its derived file formats, including MP4. It operates as a
3974 multiplexer and demultiplexer, and can mux video and audio in several formats
3975 using standalone executable files.")
3976 (license license:isc)))
3978 (define-public qtfaststart
3980 (name "qtfaststart")
3984 (uri (pypi-uri "qtfaststart" version))
3987 "0hcjfik8hhb1syqvyh5c6aillpvzal26nkjflcq1270z64aj6i5h"))))
3988 (build-system python-build-system)
3990 '(#:tests? #f)) ; no test suite
3991 (synopsis "Move QuickTime and MP4 metadata to the beginning of the file")
3992 (description "qtfaststart enables streaming and pseudo-streaming of
3993 QuickTime and MP4 files by moving metadata and offset information to the
3994 beginning of the file. It can also print some useful information about the
3995 structure of the file. This program is based on qt-faststart.c from the FFmpeg
3996 project, which is released into the public domain, as well as ISO 14496-12:2005
3997 (the official spec for MP4), which can be obtained from the ISO or found
3999 (home-page "https://github.com/danielgtaylor/qtfaststart")
4000 (license license:expat)))
4002 (define-public vidstab
4003 (let ((commit "aeabc8daa7904f9edf7441a11f293965a5ef53b8")
4007 (version (git-version "1.1.0" revision commit))
4011 (url "https://github.com/georgmartius/vid.stab")
4013 (file-name (git-file-name name version))
4016 "042iy0f3khwzr68djzvqgn301sy21ljvkf52rnc2c73q7ircnzzn"))))
4017 (build-system cmake-build-system)
4019 '(#:tests? #f)) ; tests are not run as part of standard build process
4020 (home-page "http://public.hronopik.de/vid.stab/")
4021 (synopsis "Video stabilization library")
4022 (description "Vidstab is a video stabilization library which can be used
4023 with FFmpeg. A video acquired using a hand-held camera or a camera mounted on a
4024 vehicle typically suffers from undesirable shakes and jitters. Activities such
4025 as surfing, skiing, riding and walking while shooting videos are especially
4026 prone to erratic camera shakes. Vidstab targets these video contents to help
4027 create smoother and stable videos.")
4028 (license license:gpl2+))))
4030 (define-public libopenshot
4032 (name "libopenshot")
4037 (url "https://github.com/OpenShot/libopenshot")
4038 (commit (string-append "v" version))))
4039 (file-name (git-file-name name version))
4042 "1mxjkgjmjzgf628y3rscc6rqf55hxgjpmvwxlncfk1216i5xskwp"))
4043 (modules '((guix build utils)))
4045 ;; Allow overriding of the python installation dir
4046 (substitute* "src/bindings/python/CMakeLists.txt"
4047 (("(SET\\(PYTHON_MODULE_PATH.*)\\)" _ set)
4048 (string-append set " CACHE PATH "
4049 "\"Python bindings directory\")")))
4050 (delete-file-recursively "thirdparty")
4052 (build-system cmake-build-system)
4054 `(("pkg-config" ,pkg-config)
4057 ("unittest++" ,unittest-cpp)))
4058 (propagated-inputs ;all referenced in installed headers
4059 `(("cppzmq" ,cppzmq)
4061 ("imagemagick" ,imagemagick)
4062 ("jsoncpp" ,jsoncpp)
4063 ("libopenshot-audio" ,libopenshot-audio)
4065 ("qtmultimedia" ,qtmultimedia)
4066 ("zeromq" ,zeromq)))
4069 (list (string-append "-DPYTHON_MODULE_PATH:PATH=" %output "/lib/python"
4070 ,(version-major+minor (package-version python))
4072 "-DUSE_SYSTEM_JSONCPP:BOOL=ON")
4074 (modify-phases %standard-phases
4075 (add-before 'configure 'set-vars
4076 (lambda* (#:key inputs #:allow-other-keys)
4077 (setenv "LIBOPENSHOT_AUDIO_DIR"
4078 (assoc-ref inputs "libopenshot-audio"))
4080 (assoc-ref inputs "zeromq"))
4081 (setenv "UNITTEST_DIR"
4082 (string-append (assoc-ref inputs "unittest++")
4083 "/include/UnitTest++"))
4085 (home-page "https://openshot.org")
4086 (synopsis "Video-editing, animation, and playback library")
4087 (description "OpenShot Library (libopenshot) is a powerful C++ video
4088 editing library with a multi-threaded and feature rich video editing
4089 API. It includes bindings for Python, Ruby, and other languages.")
4090 (license license:lgpl3+)))
4092 (define-public openshot
4099 (url "https://github.com/OpenShot/openshot-qt")
4100 (commit (string-append "v" version))))
4101 (file-name (git-file-name name version))
4104 "0qc5i0ay6j2wab1whl41sjb71cj02pg6y79drf7asrprq8b2rmfq"))
4105 (modules '((guix build utils)))
4108 ;; TODO: Unbundle jquery and others from src/timeline/media
4109 (delete-file-recursively "src/images/fonts") #t))))
4110 (build-system python-build-system)
4112 `(("ffmpeg" ,ffmpeg)
4113 ("font-ubuntu" ,font-ubuntu)
4114 ("libopenshot" ,libopenshot)
4116 ("python-pyqt" ,python-pyqt)
4117 ("python-pyzmq" ,python-pyzmq)
4118 ("python-requests" ,python-requests)
4121 `(#:modules ((guix build python-build-system)
4122 (guix build qt-utils)
4124 #:imported-modules (,@%python-build-system-modules
4125 (guix build qt-utils))
4126 #:phases (modify-phases %standard-phases
4127 (delete 'build) ;install phase does all the work
4130 (setenv "QT_QPA_PLATFORM" "offscreen")
4131 (invoke "python" "src/tests/query_tests.py")))
4132 (add-after 'unpack 'patch-font-location
4133 (lambda* (#:key inputs #:allow-other-keys)
4134 (let ((font (assoc-ref inputs "font-ubuntu")))
4135 (substitute* "src/classes/app.py"
4136 (("info.IMAGES_PATH") (string-append "\"" font "\""))
4137 (("fonts") "share/fonts/truetype")))
4139 (add-before 'install 'set-tmp-home
4141 ;; src/classes/info.py "needs" to create several
4142 ;; directories in $HOME when loaded during build
4143 (setenv "HOME" "/tmp")
4145 (add-after 'install 'wrap-program
4146 (lambda* (#:key outputs #:allow-other-keys)
4147 (let ((out (assoc-ref outputs "out")))
4148 (wrap-qt-program out "openshot-qt"))
4150 (home-page "https://www.openshot.org/")
4151 (synopsis "Video editor")
4152 (description "OpenShot takes your videos, photos, and music files and
4153 helps you create the film you have always dreamed of. Easily add sub-titles,
4154 transitions, and effects and then export your film to many common formats.")
4155 (license license:gpl3+)))
4157 (define-public dav1d
4164 (uri (string-append "https://downloads.videolan.org/pub/videolan"
4165 "/dav1d/" version "/dav1d-" version ".tar.xz"))
4168 "1hnkfcg57bv5rib6cnj39dy1jx0q7zi5fb2fz52hf2y0bv8bad1k"))))
4169 (build-system meson-build-system)
4170 (native-inputs `(("nasm" ,nasm)))
4171 (home-page "https://code.videolan.org/videolan/dav1d")
4172 (synopsis "AV1 decoder")
4173 (description "dav1d is a new AV1 cross-platform decoder, and focused on
4174 speed and correctness.")
4175 (license license:bsd-2)))
4177 (define-public wlstream
4178 (let ((commit "182076a94562b128c3a97ecc53cc68905ea86838")
4182 (version (git-version "0.0" revision commit))
4187 (url "https://github.com/atomnuker/wlstream")
4189 (file-name (git-file-name name version))
4192 "01qbcgfl3g9kfwn1jf1z9pdj3bvf5lmg71d1vwkcllc2az24bjqp"))))
4193 (build-system meson-build-system)
4194 (native-inputs `(("libdrm" ,libdrm)
4195 ("pkg-config" ,pkg-config)))
4196 (inputs `(("ffmpeg" ,ffmpeg)
4197 ("pulseaudio" ,pulseaudio)
4198 ("wayland" ,wayland)
4199 ("wayland-protocols" ,wayland-protocols)))
4200 (home-page "https://github.com/atomnuker/wlstream")
4201 (synopsis "Screen capture tool for Wayland sessions")
4202 (description "Wlstream is a screen capture tool for recording audio and
4203 video from a Wayland session.")
4204 (license license:lgpl2.1+))))
4206 (define-public gaupol
4213 (url "https://github.com/otsaloma/gaupol/")
4215 (file-name (git-file-name name version))
4218 "1cp0ka8hzma1dxiisdhl2fznxklj2pl63vkdqcd91lrblghdj6x9"))))
4219 (build-system python-build-system)
4221 `(("gettext" ,gettext-minimal)
4222 ("pkg-config" ,pkg-config)))
4224 `(("python-pygobject" ,python-pygobject)
4226 ("python-pycairo" ,python-pycairo) ; Required or else clicking on a subtitle line fails.
4227 ("python-chardet" ,python-chardet) ; Optional: Character encoding detection.
4228 ("gtkspell3" ,gtkspell3) ; Optional: Inline spell-checking.
4229 ("iso-codes" ,iso-codes) ; Optional: Translations.
4230 ("gstreamer" ,gstreamer)
4231 ("gst-libav" ,gst-libav)
4232 ("gst-plugins-base" ,gst-plugins-base)
4233 ("gst-plugins-good" ,gst-plugins-good)
4234 ("gst-plugins-bad" ,gst-plugins-bad)
4235 ("gst-plugins-ugly" ,gst-plugins-ugly)))
4237 `(#:tests? #f ; Tests seem to require networking.
4239 (modify-phases %standard-phases
4240 ;; gaupol's setup.py script does not support one of the Python build
4241 ;; system's default flags, "--single-version-externally-managed".
4243 (lambda* (#:key outputs #:allow-other-keys)
4244 (invoke "python" "setup.py" "install"
4245 (string-append "--prefix=" (assoc-ref outputs "out"))
4247 (add-after 'install 'wrap-gaupol
4248 (lambda* (#:key outputs #:allow-other-keys)
4249 (let ((out (assoc-ref outputs "out"))
4250 (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH"))
4251 (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
4252 (wrap-program (string-append out "/bin/gaupol")
4253 `("GST_PLUGIN_SYSTEM_PATH" ":" prefix (,gst-plugin-path))
4254 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))))
4256 (add-after 'unpack 'patch-data-dir
4257 ;; Fix some path variables that setup.py seems to garble.
4258 (lambda* (#:key outputs #:allow-other-keys)
4259 (let ((out (assoc-ref outputs "out")))
4260 (substitute* "setup.py"
4261 (("DATA_DIR = \\{!r\\}\"\\.format\\(data_dir\\)")
4262 (string-append "DATA_DIR = '" out "/share/gaupol'\""))
4263 (("LOCALE_DIR = \\{!r\\}\"\\.format\\(locale_dir\\)")
4264 (string-append "LOCALE_DIR = '" out "/share/locale'\"")))
4266 (synopsis "Editor for text-based subtitles")
4268 "Gaupol supports multiple subtitle file formats and provides means of
4269 creating subtitles, editing texts and timing subtitles to match video. The
4270 user interface features a builtin video player and is designed with attention
4271 to convenience of translating and batch processing of multiple documents.")
4272 (home-page "https://otsaloma.io/gaupol/")
4273 (license license:gpl3+)))
4275 (define-public theorafile
4276 (let ((commit "404b14d7602b5918d117eaa64e8aa6601ede8593"))
4279 (version (git-version "0.0.0" "1" commit))
4284 (url "https://github.com/FNA-XNA/Theorafile")
4286 (file-name (git-file-name name version))
4288 (base32 "128c3pjzqbgrj020glm5jd6ss18vl19471lj615w2brjwb7c1f0z"))))
4289 (build-system gnu-build-system)
4291 '(#:make-flags '("CC=gcc")
4293 (modify-phases %standard-phases
4298 (invoke "make" "test")))
4300 (lambda* (#:key outputs #:allow-other-keys)
4301 (let ((out (assoc-ref outputs "out")))
4302 (install-file "libtheorafile.so" (string-append out "/lib"))
4303 (install-file "theorafile.h" (string-append out "/include")))
4308 (home-page "https://github.com/FNA-XNA/Theorafile")
4309 (synopsis "Ogg Theora Video Decoder Library")
4310 (description "Theorafile is a library for quickly and easily decoding Ogg
4311 Theora videos. Theorafile was written to be used for FNA's VideoPlayer.")
4312 (license license:zlib))))
4314 (define-public dvdbackup
4321 (uri (string-append "mirror://sourceforge/dvdbackup/dvdbackup/"
4322 "dvdbackup-" version "/"
4323 "dvdbackup-" version ".tar.xz"))
4325 (base32 "1rl3h7waqja8blmbpmwy01q9fgr5r0c32b8dy3pbf59bp3xmd37g"))))
4326 (build-system gnu-build-system)
4328 `(("libdvdcss" ,libdvdcss)
4329 ("libdvdread" ,libdvdread)))
4330 (home-page "http://dvdbackup.sourceforge.net")
4331 (synopsis "DVD video ripper")
4333 "A simple command line tool to backup video from a DVD. Decrypts the
4334 DVD using @command{libdvdcss}, but does @strong{not} demux, remux,
4335 transcode or reformat the videos in any way, producing perfect backups.")
4336 (license license:gpl3+)))
4338 (define-public svt-av1
4345 (url "https://github.com/OpenVisualCloud/SVT-AV1")
4346 (commit (string-append "v" version))))
4347 (file-name (git-file-name name version))
4350 "0xad35q9sv5w0iihcf9q1f1m7br5anl3vsyx9svnx128iqf0n997"))))
4351 (build-system cmake-build-system)
4352 ;; SVT-AV1 only supports Intel-compatible CPUs.
4353 (supported-systems '("x86_64-linux" "i686-linux"))
4355 ;; The test suite tries to download test data and git clone a 3rd-party
4356 ;; fork of libaom. Skip it.
4359 (modify-phases %standard-phases
4360 (add-after 'install 'install-documentation
4361 (lambda* (#:key outputs #:allow-other-keys)
4362 (let* ((out (assoc-ref %outputs "out"))
4363 (doc (string-append out "/share/doc/svt-av1-" ,version)))
4364 (copy-recursively "../source/Docs" doc)
4368 (synopsis "AV1 video codec")
4369 (description "SVT-AV1 is an AV1 codec implementation. The encoder is a
4370 work-in-progress, aiming to support video-on-demand and live streaming
4371 applications. It only supports Intel-compatible CPUs (x86).")
4372 (home-page "https://github.com/OpenVisualCloud/SVT-AV1")
4373 (license license:bsd-2)))
4375 (define-public w-scan
4378 (version "20170107")
4382 (uri (string-append "https://www.gen2vdr.de/wirbel/w_scan/w_scan-"
4383 version ".tar.bz2"))
4385 (base32 "1zkgnj2sfvckix360wwk1v5s43g69snm45m0drnzyv7hgf5g7q1q"))))
4386 (build-system gnu-build-system)
4387 (synopsis "Scan ATSC/DVB-C/DVB-S/DVB-T channels")
4389 "This is a small command line utility used to perform frequency scans for
4390 DVB and ATSC transmissions without initial tuning data. It can print the
4391 result in several formats:
4393 @item VDR channels.conf,
4394 @item czap/tzap/xine/mplayer channels.conf,
4395 @item Gstreamer dvbsrc plugin,
4396 @item VLC xspf playlist,
4398 @item initial tuning data for scan or dvbv5-scan.
4400 (home-page "https://www.gen2vdr.de/wirbel/w_scan/index2.html")
4401 (license license:gpl2+)))
4403 (define-public rav1e
4410 (uri (crate-uri "rav1e" version))
4412 (string-append name "-" version ".tar.gz"))
4415 "053bh8hc6jj81ydq4gcak01b0ady59hvkl7d87im3y8nafg7xzb4"))))
4416 (build-system cargo-build-system)
4419 (("rust-aom-sys" ,rust-aom-sys-0.1)
4420 ("rust-arbitrary" ,rust-arbitrary-0.2)
4421 ("rust-arg-enum-proc-macro" ,rust-arg-enum-proc-macro-0.3)
4422 ("rust-arrayvec" ,rust-arrayvec-0.5)
4423 ("rust-backtrace" ,rust-backtrace-0.3)
4424 ("rust-bitstream-io" ,rust-bitstream-io-0.8)
4425 ("rust-byteorder" ,rust-byteorder-1.3)
4426 ("rust-cfg-if" ,rust-cfg-if-0.1)
4427 ("rust-clap" ,rust-clap-2)
4428 ("rust-console" ,rust-console-0.11)
4429 ("rust-dav1d-sys" ,rust-dav1d-sys-0.3)
4430 ("rust-fern" ,rust-fern-0.6)
4431 ("rust-image" ,rust-image-0.23)
4432 ("rust-interpolate-name" ,rust-interpolate-name-0.2)
4433 ("rust-itertools" ,rust-itertools-0.9)
4434 ("rust-ivf" ,rust-ivf-0.1)
4435 ("rust-libc" ,rust-libc-0.2)
4436 ("rust-log" ,rust-log-0.4)
4437 ("rust-noop-proc-macro" ,rust-noop-proc-macro-0.2)
4438 ("rust-num-derive" ,rust-num-derive-0.3)
4439 ("rust-num-traits" ,rust-num-traits-0.2)
4440 ("rust-paste" ,rust-paste-0.1)
4441 ("rust-rand" ,rust-rand-0.7)
4442 ("rust-rand-chacha" ,rust-rand-chacha-0.2)
4443 ("rust-rayon" ,rust-rayon-1)
4444 ("rust-rust-hawktracer" ,rust-rust-hawktracer-0.7)
4445 ("rust-scan-fmt" ,rust-scan-fmt-0.2)
4446 ("rust-serde" ,rust-serde-1)
4447 ("rust-signal-hook" ,rust-signal-hook-0.1)
4448 ("rust-simd-helpers" ,rust-simd-helpers-0.1)
4449 ("rust-thiserror" ,rust-thiserror-1.0)
4450 ("rust-toml" ,rust-toml-0.5)
4451 ("rust-y4m" ,rust-y4m-0.5)
4452 ("rust-cc" ,rust-cc-1)
4453 ("rust-nasm-rs" ,rust-nasm-rs-0.1)
4454 ("rust-rustc-version" ,rust-rustc-version-0.2)
4455 ("rust-vergen" ,rust-vergen-3.1))
4456 #:cargo-development-inputs
4457 (("rust-assert-cmd" ,rust-assert-cmd-1)
4458 ("rust-criterion" ,rust-criterion-0.3)
4459 ("rust-interpolate-name" ,rust-interpolate-name-0.2)
4460 ("rust-pretty-assertions" ,rust-pretty-assertions-0.6)
4461 ("rust-rand" ,rust-rand-0.7)
4462 ("rust-rand-chacha" ,rust-rand-chacha-0.2)
4463 ("rust-semver" ,rust-semver-0.9))
4465 (modify-phases %standard-phases
4467 (lambda* (#:key outputs #:allow-other-keys)
4468 (let ((out (assoc-ref outputs "out")))
4469 (invoke "cargo" "cinstall" "--release"
4470 (string-append "--prefix=" out))))))))
4472 `(("cargo-c" ,rust-cargo-c)))
4475 (home-page "https://github.com/xiph/rav1e/")
4476 (synopsis "The fastest and safest AV1 encoder")
4478 "The fastest and safest AV1 encoder.")
4479 (license license:bsd-2)))
4489 (url "https://github.com/phw/peek")
4491 (file-name (git-file-name name version))
4493 (base32 "1xwlfizga6hvjqq127py8vabaphsny928ar7mwqj9cyqfl6fx41x"))))
4494 (build-system meson-build-system)
4495 (arguments '(#:glib-or-gtk? #t))
4499 `(("desktop-file-utils" ,desktop-file-utils) ; for update-desktop-database
4500 ("gettext" ,gettext-minimal)
4501 ("glib:bin" ,glib "bin") ; for glib-compile-resources
4502 ("gtk+-bin" ,gtk+ "bin") ; For gtk-update-icon-cache
4503 ("pkg-config" ,pkg-config)
4505 (home-page "https://github.com/phw/peek")
4506 (synopsis "Simple animated GIF screen recorder")
4508 "Peek makes it easy to create short screencasts of a screen area. It was
4509 built for the specific use case of recording screen areas, e.g. for easily
4510 showing UI features of your own apps or for showing a bug in bug reports.
4511 With Peek, you simply place the Peek window over the area you want to record
4512 and press \"Record\". Peek is optimized for generating animated GIFs, but you
4513 can also directly record to WebM or MP4 if you prefer.")
4514 (license license:gpl3+)))
4516 (define-public wf-recorder
4518 (name "wf-recorder")
4523 (url "https://github.com/ammen99/wf-recorder")
4524 (commit (string-append "v" version))))
4525 (file-name (git-file-name name version))
4528 "1cw6kpcbl33wh95pvy32xrsrm6kkk1awccr3phyh885xjs3b3iim"))))
4529 (build-system meson-build-system)
4531 `(("pkg-config" ,pkg-config)))
4533 `(("ffmpeg" ,ffmpeg)
4534 ("pulseaudio" ,pulseaudio)
4535 ("wayland" ,wayland)
4536 ("wayland-protocols" ,wayland-protocols)
4537 ("libx264" ,libx264)))
4538 (home-page "https://github.com/ammen99/wf-recorder")
4539 (synopsis "Screen recorder for wlroots-based compositors")
4541 "@code{wf-recorder} is a utility program for screen recording of
4542 wlroots-based compositors. More specifically, those that support
4543 @code{wlr-screencopy-v1} and @code{xdg-output}.")
4544 (license license:expat)))
4546 (define-public guvcview
4552 (uri (string-append "mirror://sourceforge/guvcview/source/guvcview-"
4553 "src-" version ".tar.gz"))
4556 "11byyfpkcik7wvf2qic77zjamfr2rhji97dpj1gy2fg1bvpiqf4m"))))
4557 (build-system gnu-build-system)
4559 ;; There are no tests and "make check" would fail on an intltool error.
4562 `(("pkg-config" ,pkg-config)
4563 ("intltool" ,intltool)))
4568 ("v4l-utils" ,v4l-utils) ;libv4l2
4569 ("ffmpeg" ,ffmpeg) ;libavcodec, libavutil
4572 ("portaudio" ,portaudio)
4573 ("alsa-lib" ,alsa-lib)))
4574 (home-page "http://guvcview.sourceforge.net/")
4575 (synopsis "Control your webcam and capture videos and images")
4577 "GTK+ UVC Viewer (guvcview) is a graphical application to control a
4578 webcam accessible with Video4Linux (V4L2) and to capture videos and images.
4579 It provides control over precise settings of the webcam such as exposure,
4580 brightness, contrast, and frame rate.")
4582 ;; 'COPYING' is GPLv3 but source headers say GPLv2+.
4583 (license license:gpl2+)))
4585 (define-public get-iplayer
4587 (name "get-iplayer")
4593 (url "https://github.com/get-iplayer/get_iplayer")
4594 (commit (string-append "v" version))))
4595 (file-name (git-file-name name version))
4598 "0lsz5hz1ia5j612540rb0f31y7j2k5gf7x5i43l8k06b90wi73d6"))))
4599 (build-system perl-build-system)
4601 `(#:tests? #f ; no tests
4603 (modify-phases %standard-phases
4607 (lambda* (#:key outputs #:allow-other-keys)
4608 (let* ((out (assoc-ref outputs "out"))
4609 (bin (string-append out "/bin"))
4610 (man (string-append out "/share/man/man1")))
4611 (install-file "get_iplayer" bin)
4612 (install-file "get_iplayer.cgi" bin)
4613 (install-file "get_iplayer.1" man))
4615 (add-after 'install 'wrap-program
4616 (lambda* (#:key inputs outputs #:allow-other-keys)
4617 (let* ((out (assoc-ref outputs "out"))
4618 (perllib (string-append out "/lib/perl5/site_perl/"
4619 ,(package-version perl))))
4620 (wrap-program (string-append out "/bin/get_iplayer")
4622 prefix (,(string-append perllib ":" (getenv "PERL5LIB")))))
4623 (wrap-program (string-append out "/bin/get_iplayer.cgi")
4625 prefix (,(string-append perllib ":" (getenv "PERL5LIB")))))
4628 `(("perl-mojolicious" ,perl-mojolicious)
4629 ("perl-lwp-protocol-https" ,perl-lwp-protocol-https)
4630 ("perl-xml-libxml" ,perl-xml-libxml)))
4631 (home-page "https://github.com/get-iplayer/get_iplayer")
4632 (synopsis "Download or stream available BBC iPlayer TV and radio programmes")
4633 (description "@code{get_iplayer} lists, searches and records BBC iPlayer
4634 TV/Radio, BBC Podcast programmes. Other third-party plugins may be available.
4635 @code{get_iplayer} has three modes: recording a complete programme for later
4636 playback, streaming a programme directly to a playback application, such as
4637 mplayer; and as a @dfn{Personal Video Recorder} (PVR), subscribing to search
4638 terms and recording programmes automatically. It can also stream or record live
4639 BBC iPlayer output.")
4640 (license license:gpl3+)))
4642 (define-public ogmtools
4648 (uri (string-append "https://www.bunkus.org/videotools/ogmtools/ogmtools-"
4653 "1spx81p5wf59ksl3r3gvf78d77sh7gj8a6lw773iv67bphfivmn8"))))
4654 (build-system gnu-build-system)
4656 `(("libvorbis" ,libvorbis)
4657 ("libdvdread" ,libdvdread)))
4658 (synopsis "Information, extraction or creation for OGG media streams")
4660 "These tools allow information about (@code{ogminfo}) or extraction from
4661 \(@code{ogmdemux}) or creation of (@code{ogmmerge}) OGG media streams. It
4662 includes @code{dvdxchap} tool for extracting chapter information from DVD.")
4663 (license license:gpl2)
4664 (home-page "https://www.bunkus.org/videotools/ogmtools/")))