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, 2020 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, 2021, 2022 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2015, 2016 Andy Patterson <ajpatter@uwaterloo.ca>
8 ;;; Copyright © 2015, 2018, 2019, 2020, 2021 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, 2017 Nikita <nikita@n0.is>
14 ;;; Copyright © 2016, 2018, 2019, 2020, 2021 Eric Bavier <bavier@posteo.net>
15 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
16 ;;; Copyright © 2017 Feng Shu <tumashu@163.com>
17 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
18 ;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com>
19 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
20 ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com>
21 ;;; Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org>
22 ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
23 ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com>
24 ;;; Copyright © 2018 Roel Janssen <roel@gnu.org>
25 ;;; Copyright © 2018, 2019, 2020, 2021 Marius Bakke <marius@gnu.org>
26 ;;; Copyright © 2018, 2019, 2020 Pierre Neidhardt <mail@ambrevar.xyz>
27 ;;; Copyright © 2018, 2019, 2020 Leo Famulari <leo@famulari.name>
28 ;;; Copyright © 2018 Brendan Tildesley <mail@brendan.scot>
29 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
30 ;;; Copyright © 2018 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
31 ;;; Copyright © 2018 Mark Meyer <mark@ofosos.org>
32 ;;; Copyright © 2018 Gábor Boskovit <boskovits@gmail.com>
33 ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
34 ;;; Copyright © 2019 Timo Eisenmann <eisenmann@fn.de>
35 ;;; Copyright © 2019 Arne Babenhauserheide <arne_bab@web.de>
36 ;;; Copyright © 2019 Riku Viitanen <riku.viitanen@protonmail.com>
37 ;;; Copyright © 2020, 2021 Oleg Pykhalov <go.wigust@gmail.com>
38 ;;; Copyright © 2020 Josh Holland <josh@inv.alid.pw>
39 ;;; Copyright © 2020, 2021 Brice Waegeneire <brice@waegenei.re>
40 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
41 ;;; Copyright © 2020, 2021 Guillaume Le Vaillant <glv@posteo.net>
42 ;;; Copyright © 2020 Alex McGrath <amk@amk.ie>
43 ;;; Copyright © 2020, 2021 Michael Rohleder <mike@rohleder.de>
44 ;;; Copyright © 2020, 2021, 2022 Vinicius Monego <monego@posteo.net>
45 ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org>
46 ;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407@posteo.ro>
47 ;;; Copyright © 2020 Ivan Kozlov <kanichos@yandex.ru>
48 ;;; Copyright © 2020 Antoine Côté <antoine.cote@posteo.net>
49 ;;; Copyright © 2021 Alexey Abramov <levenson@mmer.org>
50 ;;; Copyright © 2021 Andrew Tropin <andrew@trop.in>
51 ;;; Copyright © 2021 David Wilson <david@daviwil.com>
52 ;;; Copyright © 2021,2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
53 ;;; Copyright © 2020 Hartmut Goebel <h.goebel@crazy-compilers.com>
54 ;;; Copyright © 2021 Raghav Gururajan <rg@raghavgururajan.name>
55 ;;; Copyright © 2021 Thiago Jung Bauermann <bauermann@kolabnow.com>
56 ;;; Copyright © 2021 Petr Hodina <phodina@protonmail.com>
57 ;;; Copyright © 2021 Robin Templeton <robin@terpri.org>
58 ;;; Copyright © 2021 Aleksandr Vityazev <avityazev@posteo.org>
59 ;;; Copyright © 2021 Pradana Aumars <paumars@courrier.dev>
60 ;;; Copyright © 2022 Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
62 ;;; This file is part of GNU Guix.
64 ;;; GNU Guix is free software; you can redistribute it and/or modify it
65 ;;; under the terms of the GNU General Public License as published by
66 ;;; the Free Software Foundation; either version 3 of the License, or (at
67 ;;; your option) any later version.
69 ;;; GNU Guix is distributed in the hope that it will be useful, but
70 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
71 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
72 ;;; GNU General Public License for more details.
74 ;;; You should have received a copy of the GNU General Public License
75 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
77 (define-module (gnu packages video)
78 #:use-module (ice-9 match)
79 #:use-module ((srfi srfi-1) #:hide (zip))
80 #:use-module (srfi srfi-26)
81 #:use-module ((guix licenses) #:prefix license:)
82 #:use-module (guix utils)
83 #:use-module (guix packages)
84 #:use-module (guix download)
85 #:use-module (guix gexp)
86 #:use-module (guix git-download)
87 #:use-module (guix svn-download)
88 #:use-module (guix hg-download)
89 #:use-module (guix build-system cargo)
90 #:use-module (guix build-system cmake)
91 #:use-module (guix build-system copy)
92 #:use-module (guix build-system gnu)
93 #:use-module (guix build-system glib-or-gtk)
94 #:use-module (guix build-system meson)
95 #:use-module (guix build-system perl)
96 #:use-module (guix build-system python)
97 #:use-module (guix build-system qt)
98 #:use-module (guix build-system waf)
99 #:use-module (guix build-system trivial)
100 #:use-module (gnu packages)
101 #:use-module (gnu packages algebra)
102 #:use-module (gnu packages assembly)
103 #:use-module (gnu packages audio)
104 #:use-module (gnu packages autotools)
105 #:use-module (gnu packages avahi)
106 #:use-module (gnu packages backup)
107 #:use-module (gnu packages base)
108 #:use-module (gnu packages bash)
109 #:use-module (gnu packages bison)
110 #:use-module (gnu packages boost)
111 #:use-module (gnu packages build-tools)
112 #:use-module (gnu packages cdrom)
113 #:use-module (gnu packages check)
114 #:use-module (gnu packages cmake)
115 #:use-module (gnu packages compression)
116 #:use-module (gnu packages cpp)
117 #:use-module (gnu packages crates-io)
118 #:use-module (gnu packages crates-graphics)
119 #:use-module (gnu packages curl)
120 #:use-module (gnu packages dejagnu)
121 #:use-module (gnu packages dns)
122 #:use-module (gnu packages docbook)
123 #:use-module (gnu packages documentation)
124 #:use-module (gnu packages elf)
125 #:use-module (gnu packages file)
126 #:use-module (gnu packages flex)
127 #:use-module (gnu packages fonts)
128 #:use-module (gnu packages fontutils)
129 #:use-module (gnu packages freedesktop)
130 #:use-module (gnu packages fribidi)
131 #:use-module (gnu packages gettext)
132 #:use-module (gnu packages ghostscript)
133 #:use-module (gnu packages gl)
134 #:use-module (gnu packages glib)
135 #:use-module (gnu packages guile)
136 #:use-module (gnu packages gnome)
137 #:use-module (gnu packages gnunet)
138 #:use-module (gnu packages gnupg)
139 #:use-module (gnu packages gstreamer)
140 #:use-module (gnu packages gtk)
141 #:use-module (gnu packages image)
142 #:use-module (gnu packages imagemagick)
143 #:use-module (gnu packages iso-codes)
144 #:use-module (gnu packages libidn)
145 #:use-module (gnu packages libreoffice)
146 #:use-module (gnu packages libusb)
147 #:use-module (gnu packages linux)
148 #:use-module (gnu packages llvm)
149 #:use-module (gnu packages lua)
150 #:use-module (gnu packages m4)
151 #:use-module (gnu packages man)
152 #:use-module (gnu packages markup)
153 #:use-module (gnu packages maths)
154 #:use-module (gnu packages music)
155 #:use-module (gnu packages mp3)
156 #:use-module (gnu packages ncurses)
157 #:use-module (gnu packages networking)
158 #:use-module (gnu packages ocr)
159 #:use-module (gnu packages pcre)
160 #:use-module (gnu packages perl)
161 #:use-module (gnu packages perl-check)
162 #:use-module (gnu packages perl-web)
163 #:use-module (gnu packages photo)
164 #:use-module (gnu packages pkg-config)
165 #:use-module (gnu packages popt)
166 #:use-module (gnu packages pretty-print)
167 #:use-module (gnu packages protobuf)
168 #:use-module (gnu packages pulseaudio)
169 #:use-module (gnu packages python)
170 #:use-module (gnu packages python-crypto)
171 #:use-module (gnu packages python-web)
172 #:use-module (gnu packages python-xyz)
173 #:use-module (gnu packages qt)
174 #:use-module (gnu packages rdesktop)
175 #:use-module (gnu packages re2c)
176 #:use-module (gnu packages ruby)
177 #:use-module (gnu packages rust-apps)
178 #:use-module (gnu packages samba)
179 #:use-module (gnu packages sdl)
180 #:use-module (gnu packages serialization)
181 #:use-module (gnu packages shells)
182 #:use-module (gnu packages sqlite)
183 #:use-module (gnu packages ssh)
184 #:use-module (gnu packages swig)
185 #:use-module (gnu packages texinfo)
186 #:use-module (gnu packages textutils)
187 #:use-module (gnu packages tls)
188 #:use-module (gnu packages time)
189 #:use-module (gnu packages upnp)
190 #:use-module (gnu packages vulkan)
191 #:use-module (gnu packages web)
192 #:use-module (gnu packages webkit)
193 #:use-module (gnu packages wget)
194 #:use-module (gnu packages wxwidgets)
195 #:use-module (gnu packages xdisorg)
196 #:use-module (gnu packages xiph)
197 #:use-module (gnu packages xml)
198 #:use-module (gnu packages xorg))
200 (define-public transcode
208 (string-append "https://sources.archlinux.org/other/community/"
209 name "/" name "-" version ".tar.bz2"))
211 (base32 "14ha9xjsjrj131f35jd56z5v1jb4rbsrj1nril5shqnxw3c74khy"))
213 (search-patches "transcode-ffmpeg.patch"))))
214 (build-system gnu-build-system)
218 "CFLAGS=-O2 -g -fcommon"
220 ;; Undeclared variables 'sys_nerr' and 'sys_errlist'.
221 ;; "--enable-libv4l2"
223 "--enable-libmpeg2convert"
225 ;; Undeclared variables 'sys_nerr' and 'sys_errlist'.
227 ;;; XXX: Not available.
232 ;;; XXX: Not available.
233 ;"--enable-libpostproc"
240 ;;; XXX: Not available.
243 "--enable-libquicktime"
248 ;;; XXX: Not available.
250 ;;"--enable-mjpegtools"
252 "--enable-imagemagick"
253 ;;; XXX: Not available.
254 ;"--enable-libjpegmmx"
255 "--enable-libjpeg")))
256 ;;; XXX: Not available.
261 `(("autoconf" ,autoconf)
262 ("automake" ,automake)
267 ("pkg-config" ,pkg-config)
268 ("python" ,python-wrapper)))
270 `(("alsa-lib" ,alsa-lib)
273 ("freetype" ,freetype)
274 ("imagemagick" ,imagemagick)
278 ("libdvdread" ,libdvdread)
279 ("libjpeg" ,libjpeg-turbo)
280 ("libmpeg2" ,libmpeg2)
282 ("libquicktime" ,libquicktime)
283 ("libtheora" ,libtheora)
284 ("libvorbis" ,libvorbis)
286 ("mjepgtools" ,mjpegtools)
288 ;; ("v4l-utils" ,v4l-utils)
297 (synopsis "Audio/Video Transcoder")
298 (description "Transcode is a fast, versatile and command-line based
299 audio/video everything to everything converter primarily focused on producing
300 AVI video files with MP3 audio, but also including a program to read all the
301 video and audio streams from a DVD.")
303 "http://linuxfromscratch.org/blfs/view/svn/multimedia/transcode.html")
304 (license license:gpl2+)))
306 (define-public svt-hevc
315 (url "https://github.com/OpenVisualCloud/SVT-HEVC")
316 (commit (string-append "v" version))))
317 (file-name (git-file-name name version))
319 (base32 "1cv6vcf5yxcwdvj5yqcckbixqrvvdxk7ibincnnv80pz6wh527sv"))))
320 (build-system cmake-build-system)
322 `(#:tests? #f)) ; Test script is stand-alone
325 (synopsis "SVT HEVC encoder")
326 (description "Scalable Video Technology (SVT) is a software-based video
327 coding technology that is highly optimized for Intel's Xeon processors. Using
328 the SVT-HEVC encoder, it is possible to spread video encoding processing across
329 multiple Intel's Xeon processors to achieve a real advantage of processing
331 (home-page "https://01.org/svt")
332 (license (license:non-copyleft "file:///LICENSE.md"))))
334 (define-public mediasdk
343 (url "https://github.com/Intel-Media-SDK/MediaSDK")
344 (commit (string-append "intel-" name "-" version))))
345 (file-name (git-file-name name version))
347 (base32 "0blwcxr5j8762nylx2cxrq0h53bpgnk859dbs6crq4wr9fcxlx9z"))))
348 (build-system cmake-build-system)
353 "-DENABLE_X11_DRI3=ON"
354 "-DENABLE_WAYLAND=ON"
355 "-DENABLE_TEXTLOG=ON"
359 (string-append "-DCMAKE_EXE_LINKER_FLAGS=-Wl,-rpath="
360 (assoc-ref %outputs "out") "/lib"))))
362 `(("pkg-config" ,pkg-config)
363 ("python" ,python-wrapper)))
367 ("pciaccess" ,libpciaccess)
370 (synopsis "Intel Media SDK")
371 (description "MediaSDK provides a plain C API to access hardware-accelerated
372 video decode, encode and filtering on Intel's Gen graphics hardware platforms.")
373 (home-page "http://mediasdk.intel.com/")
374 (license (license:non-copyleft "file:///LICENSE"))))
376 (define-public schroedinger
378 (name "schroedinger")
384 (string-append "https://launchpad.net/" name "/trunk/" version
385 "/+download/" name "-" version ".tar.gz"))
387 (base32 "04prr667l4sn4zx256v1z36a0nnkxfdqyln48rbwlamr6l3jlmqy"))))
388 (build-system gnu-build-system)
389 (outputs '("out" "doc"))
392 (modify-phases %standard-phases
393 (add-after 'install 'move-docs
394 (lambda* (#:key outputs #:allow-other-keys)
395 (let* ((out (assoc-ref outputs "out"))
396 (doc (assoc-ref outputs "doc")))
397 (mkdir-p (string-append doc "/share"))
399 (string-append out "/share/gtk-doc")
400 (string-append doc "/share/gtk-doc"))
403 (list dash gtk-doc/stable pkg-config))
409 (synopsis "Dirac video codec")
410 (description "Schroedinger is a project implementing the Dirac video codec in
411 ANSI C code. It is meant to be highly optimized and portable. It is developed
412 as a joint effort between the BBC and Fluendo.")
413 (home-page "https://launchpad.net/schroedinger")
415 ;; This library is licensed under 4 different licenses,
416 ;; and you can choose to use it under the terms of any one of them.
423 (define-public libquicktime
425 (name "libquicktime")
431 (string-append "https://sourceforge.net/projects/" name "/files/"
432 name "/" version "/" name "-" version ".tar.gz"))
434 (base32 "0s3kshzl3zfjw3phzv73r91fkr9z8q8kc3dhsys4f4xk6ff3alqw"))
436 (search-patches "libquicktime-ffmpeg.patch"))))
437 (build-system gnu-build-system)
439 (list gettext-minimal doxygen pkg-config))
455 (synopsis "Quick Time Library")
456 (description "The goal of this project is to enhance the quicktime4linux
458 (home-page "http://libquicktime.sourceforge.net/")
459 (license license:lgpl2.1+)))
461 (define-public mjpg-streamer
463 (name "mjpg-streamer")
468 (url "https://github.com/jacksonliam/mjpg-streamer")
469 (commit (string-append "v" version))))
470 (file-name (git-file-name name version))
473 "0w81pg228154blzbzr590xwhcll9baxyqxl6wxrgqsi9cd7pzq23"))
474 (modules '((guix build utils)))
477 (with-directory-excursion "mjpg-streamer-experimental/www"
478 (for-each delete-file-recursively
484 "jquery.ui.core.min.js"
485 "jquery.ui.custom.css"
486 "jquery.ui.tabs.min.js"
487 "jquery.ui.widget.min.js")))))))
488 (build-system cmake-build-system)
490 '(#:tests? #f ; no test suite
492 (modify-phases %standard-phases
493 (add-after 'unpack 'chdir
495 (chdir "mjpg-streamer-experimental"))))))
496 (inputs (list libjpeg-turbo))
497 (synopsis "Stream JPEG over IP network")
498 (description "Command line application that copies JPEG frames from one or
499 more input plugins to multiple output plugins. It can be used to stream JPEG
500 files over an IP-based network from a webcam to various types of viewers such
501 as Chrome, Firefox, Cambozola, VLC, mplayer, and other software capable of
502 receiving MJPG streams.")
503 (home-page "https://github.com/jacksonliam/mjpg-streamer")
504 (license license:gpl2+)))
506 (define-public mjpegtools
514 (string-append "https://sourceforge.net/projects/mjpeg/files/"
515 name "/" version "/" name "-" version ".tar.gz"))
517 (base32 "16pl22ra3x2mkp8p3awslhlhj46b1nq9g89301gb0q4rgmnm705i"))))
518 (build-system gnu-build-system)
520 (list gtk+-2 libdv libjpeg-turbo libpng libquicktime sdl))
523 (synopsis "Tools for handling MPEG")
524 (description "Mjpeg tools is a suite of programs which support video capture,
525 editing, playback, and compression to MPEG of MJPEG video. Edit, play and
526 compression software is hardware independent.")
527 (home-page "http://mjpeg.sourceforge.net/")
528 (license license:gpl2+)))
530 (define-public libmms
538 (string-append "https://sourceforge.net/projects/" name "/files/"
539 name "/" version "/" name "-" version ".tar.gz"))
541 (base32 "0kvhxr5hkabj9v7ah2rzkbirndfqdijd9hp8v52c1z6bxddf019w"))))
542 (build-system gnu-build-system)
543 (synopsis "MMS stream protocol library")
544 (description "Libmms is a library for streaming media files using the mmst
545 and mmsh protocols.")
546 (home-page "https://sourceforge.net/projects/libmms/")
547 (license license:lgpl2.1+)))
549 (define-public libvideogfx
558 (url "https://github.com/farindk/libvideogfx")
559 (commit (string-append "v" version))))
560 (file-name (git-file-name name version))
562 (base32 "154b0j8cfg879pg08xcbwvbz8z9nrfnyj31i48vxir1psas70ynq"))))
563 (build-system gnu-build-system)
566 (modify-phases %standard-phases
567 (add-after 'unpack 'fix-build-errors
569 (substitute* "libvideogfx/graphics/fileio/ffmpeg.cc"
570 (("av_close_input_file\\(")
571 "avformat_close_input(&"))
572 (substitute* "libvideogfx/graphics/fileio/png.cc"
573 (("is != NULL") "is.good()"))
576 (list autoconf automake libtool pkg-config))
578 `(("ffmpeg" ,ffmpeg-2.8)
579 ("jpeg" ,libjpeg-turbo)
583 (synopsis "Video processing library")
584 (description "LibVideoGfx is a C++ library for low-level video processing.
585 It aims at speeding up the development process for image and video processing
586 applications by providing high-level classes for commonly required tasks.")
587 (home-page "https://dirk-farin.net/software/libvideogfx/index.html")
588 (license license:lgpl2.1+)))
590 (define-public libde265
599 (url "https://github.com/strukturag/libde265")
600 (commit (string-append "v" version))))
601 (file-name (git-file-name name version))
603 (base32 "1dzflqbk248lz5ws0ni5acmf32b3rmnq5gsfaz7691qqjxkl1zml"))))
604 (build-system gnu-build-system)
607 (list "--disable-static")))
609 `(("autoconf" ,autoconf)
610 ("automake" ,automake)
612 ("pkg-config" ,pkg-config)
613 ("python" ,python-wrapper)))
615 `(;; XXX: Build fails with libvideogfx.
616 ;; ("libvideogfx" ,libvideogfx)
619 (synopsis "H.265 video codec implementation")
620 (description "Libde265 is an implementation of the h.265 video codec. It is
621 written from scratch and has a plain C API to enable a simple integration into
623 (home-page "https://www.libde265.org/")
640 (url "https://github.com/libts/tslib")
642 (file-name (git-file-name name version))
644 (base32 "197p6vy539wvfrv23agbvmay4rjya1jnisi46llm0nx4cvqh48by"))))
645 (build-system gnu-build-system)
647 `(#:test-target "tests"
649 (list "--with-sdl2")))
651 (list autoconf automake libtool pkg-config))
654 (synopsis "Touchscreen access library")
655 (description "TSLib is a cross-platform library that provides access to
656 touchscreen devices and the ability to apply filters to their input events.")
657 (home-page "http://www.tslib.org/")
658 (license license:lgpl2.1+)))
660 (define-public libmpeg3
668 (string-append "https://sourceforge.net/projects/heroines/files/"
669 "releases/081108/" name "-" version "-src.tar.bz2"))
671 (base32 "1i53vv0wm5qfwgg1z7j9g14s6c7gxxkiy4vbdkq3lijjyyz50vv5"))))
672 (build-system gnu-build-system)
674 `(#:test-target "test"
677 (string-append "A52DIR=" (assoc-ref %build-inputs "liba52"))
678 (string-append "DST=" (assoc-ref %outputs "out") "/bin"))
680 (modify-phases %standard-phases
681 (add-after 'unpack 'delete-bundled-a52dec
683 (delete-file-recursively "a52dec-0.7.3")
684 (substitute* "Makefile"
685 (("include Makefile\\.a52")
687 (("\\(A52DIR\\)/include")
688 "(A52DIR)/include/a52dec")
690 (string-append match "-la52 ")))
692 (add-before 'install 'create-destination-directory
693 (lambda* (#:key outputs #:allow-other-keys)
694 (let* ((out (string-append (assoc-ref outputs "out"))))
695 (mkdir-p (string-append out "/bin"))
701 (synopsis "Advanced MPEG editing and manipulation library")
702 (description "Libmpeg3 decodes MP2, MP3, AC3, MPEG-1 video, MPEG-2 video,
703 and DVD footage in a single library. It supports many esoteric features like
704 parallel video decoding, frame-accurate editing, YUV 4:2:2, and ATSC transport
706 (home-page "http://heroinewarrior.com/libmpeg3.php")
707 (license license:gpl2+)))
715 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
716 version "/" name "-" version ".tar.gz"))
719 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
720 (build-system gnu-build-system)
723 ("makeinfo" ,texinfo)))
728 (modify-phases %standard-phases
729 (add-after 'unpack 'update-config-scripts
730 (lambda* (#:key inputs native-inputs #:allow-other-keys)
731 ;; Replace outdated config.guess and config.sub.
732 (for-each (lambda (file)
735 (or native-inputs inputs)
736 (string-append "/bin/" file)) "."))
737 '("config.guess" "config.sub"))))
739 (lambda* (#:key build inputs outputs #:allow-other-keys)
740 ;; This old `configure' script doesn't support
741 ;; variables passed as arguments.
742 (let ((out (assoc-ref outputs "out"))
743 (ncurses (assoc-ref inputs "ncurses")))
744 (setenv "CONFIG_SHELL" (which "bash"))
745 (invoke "./configure"
746 (string-append "--prefix=" out)
747 (string-append "--build=" build)
748 (string-append "--with-ncurses="
750 (home-page "http://aa-project.sourceforge.net/aalib/")
751 (synopsis "ASCII-art library")
753 "AA-lib is a low level gfx library which does not require graphics device.
754 In fact, there is no graphical output possible. AA-lib replaces those
755 old-fashioned output methods with powerful ascii-art renderer.")
756 (license license:lgpl2.0+)))
758 (define-public celluloid
765 (uri (string-append "https://github.com/celluloid-player/celluloid"
766 "/releases/download/v" version
767 "/celluloid-" version ".tar.xz"))
769 (base32 "18g596ja8g0fy79pmxqdlzqzb0f9xq69ik4bah8g2ppipfvxbpjz"))))
770 (build-system glib-or-gtk-build-system)
772 (list intltool pkg-config))
774 (list gtk libepoxy mpv))
775 (home-page "https://github.com/celluloid-player/celluloid")
776 (synopsis "GTK+ frontend for the mpv media player")
777 (description "Celluloid is a simple GTK+ frontend for the mpv media player.
778 It interacts with mpv via the client API exported by libmpv, allowing access to
779 mpv's powerful playback capabilities.")
780 (license license:gpl3+)))
782 (define-public liba52
789 ;; A mirror://sourceforge URI doesn't work, presumably
790 ;; because the SourceForge project is misconfigured.
791 "http://liba52.sourceforge.net/files/a52dec-" version
795 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
796 (patches (search-patches "liba52-enable-pic.patch"
797 "liba52-set-soname.patch"
798 "liba52-use-mtune-not-mcpu.patch"
799 "liba52-link-with-libm.patch"))))
800 (build-system gnu-build-system)
801 ;; XXX We need to run ./bootstrap because of the build system fixes above.
803 (list autoconf automake libtool))
804 (arguments `(#:configure-flags '("--enable-shared")
806 (modify-phases %standard-phases
807 ;; XXX We need to run ./bootstrap because of the build
808 ;; system fixes above.
810 (lambda _ (invoke "sh" "bootstrap"))))))
811 (home-page "http://liba52.sourceforge.net/")
812 (synopsis "ATSC A/52 audio stream decoder")
813 (description "liba52 is a library for decoding ATSC A/52 audio streams.
814 The A/52 standard is used in a variety of applications, including digital
815 television and DVD. It is also known as AC-3.")
816 (license license:gpl2+)))
818 (define-public libaom
825 (url "https://aomedia.googlesource.com/aom/")
826 (commit (string-append "v" version))))
827 (file-name (git-file-name name version))
830 "0fmnbzpl481i7kchx4hbvb507r5pfgyrzfrlrs7jk3bicycm75qv"))))
831 (build-system cmake-build-system)
833 (list perl pkg-config python)) ; to detect the version
835 `(#:tests? #f ; downloads many video clips
837 (list "-DBUILD_SHARED_LIBS=YES"
839 "-DAOM_TARGET_CPU=generic"
840 (string-append "-DCMAKE_INSTALL_PREFIX="
841 (assoc-ref %outputs "out")))
843 (modify-phases %standard-phases
844 (add-after 'install 'delete-static-libraries
845 (lambda* (#:key outputs #:allow-other-keys)
846 (let* ((out (assoc-ref outputs "out"))
847 (lib (string-append out "/lib")))
848 (for-each delete-file
849 (find-files lib "\\.a$"))))))))
850 (home-page "https://aomedia.googlesource.com/aom/")
851 (synopsis "AV1 video codec")
852 (description "Libaom is the reference implementation of AV1. It includes a
853 shared library and encoder and decoder command-line executables.")
854 (license license:bsd-2)))
856 (define-public libmpeg2
862 ;; A mirror://sourceforge URI doesn't work, presumably
863 ;; because the SourceForge project is misconfigured.
864 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
865 name "-" version ".tar.gz"))
866 (patches (search-patches "libmpeg2-arm-private-symbols.patch"
867 "libmpeg2-global-symbol-test.patch"))
870 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
878 (build-system gnu-build-system)
879 (home-page "http://libmpeg2.sourceforge.net/")
880 (synopsis "MPEG1 and MPEG2 video decoder library")
882 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
883 (license license:gpl2+)))
885 (define-public libx264
886 ;; There are no tags in the repository, so we take the version number from
887 ;; the X264_BUILD variable defined in x264.h.
888 (let ((version "161")
889 (commit "4c2aafd864dd201832ec2be0fef4484925146650")
893 (version (git-version version revision commit))
897 (url "https://code.videolan.org/videolan/x264.git")
899 (file-name (git-file-name name version))
902 "1i6v9h3xx9pi0zmlj3anwwjxqa63sbhy9crrif8dphipwfn9hyg5"))))
903 (build-system gnu-build-system)
905 (list pkg-config nasm))
906 ;; TODO: Add gpac input
908 `(#:tests? #f ;no check target
909 #:configure-flags '("--enable-shared"
910 ;; Don't build the command-line program. If we
911 ;; want it later, we should do so in a different
912 ;; package to avoid a circular dependency (the x264
913 ;; program depends on ffmpeg and ffmpeg depends on
917 ;; On MIPS, we must pass "--disable-asm" or else
918 ;; configure fails after printing: "You specified a
919 ;; pre-MSA CPU in your CFLAGS. If you really want
920 ;; to run on such a CPU, configure with
922 ,@(if (string-prefix? "mips"
923 (or (%current-target-system)
927 (home-page "https://www.videolan.org/developers/x264.html")
928 (synopsis "H.264 video coding library")
929 (description "libx264 is an advanced encoding library for creating
930 H.264 (MPEG-4 AVC) video streams.")
931 (license (list license:gpl2+ ;most files
932 license:isc ;common/x86/x86inc.asm
933 license:lgpl2.1+ ;extras/getopt.c
934 license:bsd-3 ;extras/inttypes.h
935 (license:non-copyleft ;extras/cl*.h
937 "See extras/cl.h in the distribution."))))))
939 (define-public mkvtoolnix
946 (uri (string-append "https://mkvtoolnix.download/sources/"
947 "mkvtoolnix-" version ".tar.xz"))
949 (base32 "15y7ahlifsclnkl70wn5w34dil8nwcwcjnw3k2ydqc6dz4vb0j5s"))
950 (modules '((guix build utils)))
952 ;; Delete bundled libraries.
953 (for-each delete-file-recursively
961 (build-system gnu-build-system)
962 (outputs '("out" "gui")) ; "mkvtoolnix-gui" brings the closure size from ~300 MB to 1.5+ GB.
983 `(("docbook-xsl" ,docbook-xsl)
984 ("gettext" ,gettext-minimal)
985 ("googletest" ,googletest)
987 ("json-modern-cxx" ,json-modern-cxx)
989 ("pkg-config" ,pkg-config)
995 (list (string-append "--with-boost="
996 (assoc-ref %build-inputs "boost"))
997 (string-append "--with-docbook-xsl-root="
998 (assoc-ref %build-inputs "docbook-xsl")
999 "/xml/xsl/docbook-xsl-"
1000 ,(package-version docbook-xsl))
1001 "--enable-update-check=no"
1002 "--enable-precompiled-headers=no")
1004 (modify-phases %standard-phases
1005 (add-after 'unpack 'patch-relative-file-names
1006 (lambda* (#:key outputs #:allow-other-keys)
1007 (let ((out (assoc-ref outputs "out")))
1008 (substitute* "src/mkvtoolnix-gui/util/settings.cpp"
1010 (string-append out "/bin/" match)))
1012 (add-before 'configure 'add-googletest
1013 (lambda* (#:key inputs #:allow-other-keys)
1014 (symlink (search-input-directory inputs "/include/gtest")
1018 (let ((-j (list "-j" (number->string (parallel-job-count)))))
1019 (apply invoke "rake" -j))))
1022 (invoke "rake" "tests/unit")))
1025 (invoke "rake" "install")))
1026 (add-after 'install 'post-install
1027 (lambda* (#:key outputs #:allow-other-keys)
1028 ;; Move the Qt interface to "gui".
1029 (let* ((out (assoc-ref outputs "out"))
1030 (gui (assoc-ref outputs "gui"))
1031 (strip-store-dir (lambda (path)
1032 (substring path (string-prefix-length out path)))))
1035 (mkdir-p (string-append gui (dirname file)))
1036 (rename-file (string-append out file)
1037 (string-append gui file)))
1038 (append '("/bin/mkvtoolnix-gui"
1039 "/share/applications/org.bunkus.mkvtoolnix-gui.desktop"
1040 "/share/metainfo/org.bunkus.mkvtoolnix-gui.appdata.xml"
1041 "/share/mime/packages/org.bunkus.mkvtoolnix-gui.xml")
1042 (map strip-store-dir (find-files out "\\.ogg$"))
1043 (map strip-store-dir (find-files out "mkvtoolnix-gui\\.png$"))
1044 (map strip-store-dir (find-files out "mkvtoolnix-gui\\.1"))))
1047 (delete-file-recursively (string-append out file)))
1048 '("/share/applications"
1051 "/share/mkvtoolnix")))
1053 (home-page "https://mkvtoolnix.download")
1054 (synopsis "Tools to create, alter and inspect Matroska files")
1056 "MKVToolNix provides tools for getting information about Matroska files
1057 (@command{mkvinfo}), extracting tracks/data from Matroska files
1058 (@command{mkvextract}), and creating Matroska files from other media files
1059 (@command{mkvmerge}).")
1060 (license license:gpl2)))
1062 (define-public pipe-viewer
1064 (name "pipe-viewer")
1071 (url "https://github.com/trizen/pipe-viewer")
1073 (file-name (git-file-name name version))
1075 (base32 "1fh8b77vchpsar88dszsz5h1gzd4jz0v902igp2880vnpvacmfi9"))))
1076 (build-system perl-build-system)
1078 `(#:imported-modules
1079 ((guix build copy-build-system)
1080 ,@%perl-build-system-modules)
1082 (((guix build copy-build-system)
1084 (guix build perl-build-system)
1087 #:module-build-flags
1091 (modify-phases %standard-phases
1092 (add-after 'unpack 'patch-source
1093 (lambda* (#:key inputs #:allow-other-keys)
1094 (substitute* (find-files "lib" "\\.pm$")
1096 (format #f "\"~a/bin/youtube-dl\""
1097 (assoc-ref inputs "youtube-dl")))
1099 (format #f "\"~a/bin/yt-dlp\""
1100 (assoc-ref inputs "yt-dlp"))))
1101 (substitute* (find-files "bin" ".*-viewer$")
1103 (format #f "'~a/bin/ffmpeg'"
1104 (assoc-ref inputs "ffmpeg")))
1106 (format #f "'~a/bin/wget'"
1107 (assoc-ref inputs "wget")))
1109 (format #f "'~a/bin/xdg-open'"
1110 (assoc-ref inputs "xdg-utils")))
1112 (format #f "'~a/bin/youtube-dl'"
1113 (assoc-ref inputs "youtube-dl")))
1115 (format #f "'~a/bin/yt-dlp'"
1116 (assoc-ref inputs "yt-dlp"))))))
1117 (add-after 'install 'install-xdg
1119 (apply (assoc-ref copy:%standard-phases 'install)
1121 '(("share/icons" "share/pixmaps")
1122 ("share" "share/applications"
1123 #:include-regexp ("\\.desktop$")))
1125 (add-after 'install-xdg 'wrap-programs
1126 (lambda* (#:key outputs #:allow-other-keys)
1127 (let* ((out (assoc-ref outputs "out"))
1128 (bin-dir (string-append out "/bin/"))
1129 (site-dir (string-append out "/lib/perl5/site_perl/"))
1130 (perl-lib (getenv "PERL5LIB"))
1131 (gi-typelib (getenv "GI_TYPELIB_PATH")))
1133 (cut wrap-program <>
1134 `("PERL5LIB" ":" prefix (,perl-lib ,site-dir))
1135 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib)))
1136 (find-files bin-dir))))))))
1138 (list perl-module-build perl-test-pod perl-test-simple))
1140 (list perl-data-dump
1152 perl-lwp-protocol-https
1153 perl-lwp-useragent-cached
1157 perl-scalar-list-utils
1160 perl-term-readline-gnu
1161 perl-text-parsewords
1163 perl-unicode-linebreak
1171 (home-page "https://github.com/trizen/pipe-viewer")
1172 (synopsis "CLI+GUI YouTube Client")
1173 (description "Pipe-Viewer is a lightweight application for searching and
1174 playing videos from YouTube. It parses the YouTube website directly and relies
1175 on the Invidious instances only as a fallback method.")
1176 (license license:artistic2.0)))
1178 (define-public straw-viewer
1179 (deprecated-package "straw-viewer" pipe-viewer))
1185 (outputs '("out" "static"))
1189 (uri (list (string-append "https://bitbucket.org/multicoreware/x265"
1190 "/downloads/x265_" version ".tar.gz")
1191 (string-append "https://download.videolan.org/videolan/x265/"
1192 "x265_" version ".tar.gz")))
1194 (base32 "0wl62hfsdqpf3r3z3s6l9bz7pdb1rcik5ll00b3yaadplqipy162"))
1195 (patches (search-patches "x265-arm-flags.patch"))
1196 (modules '((guix build utils)))
1198 (delete-file-recursively "source/compat/getopt")
1200 (build-system cmake-build-system)
1202 ;; XXX: ASM optimization fails on i686-linux, see <https://bugs.gnu.org/41768>.
1203 (if (string-prefix? "i686" (%current-system))
1207 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
1209 ;; Ensure position independent code for everyone.
1210 (list "-DENABLE_PIC=TRUE"
1212 '("-DENABLE_ASSEMBLY=OFF")
1214 (string-append "-DCMAKE_INSTALL_PREFIX="
1215 (assoc-ref %outputs "out")))
1217 (modify-phases %standard-phases
1218 (add-after 'unpack 'prepare-build
1220 (delete-file-recursively "build")
1223 (add-before 'configure 'build-12-bit
1224 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
1225 (mkdir "../build-12bit")
1226 (with-directory-excursion "../build-12bit"
1229 "-DHIGH_BIT_DEPTH=ON"
1230 "-DEXPORT_C_API=OFF"
1234 (substitute* (cons "cmake_install.cmake"
1236 (find-files "CMakeFiles/x265-shared.dir" ".")
1237 (find-files "CMakeFiles/x265-static.dir" ".")))
1238 (("libx265") "libx265_main12"))
1240 (add-before 'configure 'build-10-bit
1241 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
1242 (mkdir "../build-10bit")
1243 (with-directory-excursion "../build-10bit"
1246 "-DHIGH_BIT_DEPTH=ON"
1247 "-DEXPORT_C_API=OFF"
1250 (substitute* (cons "cmake_install.cmake"
1252 (find-files "CMakeFiles/x265-shared.dir" ".")
1253 (find-files "CMakeFiles/x265-static.dir" ".")))
1254 (("libx265") "libx265_main10"))
1256 (add-after 'install 'install-more-libs
1258 (with-directory-excursion "../build-12bit"
1259 (invoke "make" "install"))
1260 (with-directory-excursion "../build-10bit"
1261 (invoke "make" "install"))))
1262 (add-before 'strip 'move-static-libs
1263 (lambda* (#:key outputs #:allow-other-keys)
1264 (let ((out (assoc-ref outputs "out"))
1265 (static (assoc-ref outputs "static")))
1266 (mkdir-p (string-append static "/lib"))
1267 (with-directory-excursion
1268 (string-append out "/lib")
1272 (string-append static "/lib/" file)))
1273 (find-files "." "\\.a$"))))
1275 (home-page "http://x265.org/")
1276 (synopsis "Library for encoding h.265/HEVC video streams")
1277 (description "x265 is a H.265 / HEVC video encoder application library,
1278 designed to encode video or images into an H.265 / HEVC encoded bitstream.")
1279 (license license:gpl2+)))
1281 (define-public libass
1288 "https://github.com/libass/libass/releases/download/"
1289 version "/libass-" version ".tar.xz"))
1292 "0lwfmdizzrr4gcq3fgw4j8g9pkrqgx6h0f3pgrrnxc07s34kkp8w"))))
1293 (build-system gnu-build-system)
1295 '(#:configure-flags '("--disable-static")))
1297 (list pkg-config nasm))
1299 `(("freetype" ,freetype)
1300 ("fribidi" ,fribidi)
1301 ("fontconfig" ,fontconfig)
1302 ("harfbuzz" ,harfbuzz)))
1303 (home-page "https://github.com/libass/libass")
1304 (synopsis "Subtitle rendering library for the ASS/SSA format")
1305 (description "libass is a subtitle rendering library for the
1306 ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
1307 (license license:isc)))
1309 (define-public libcaca
1312 (version "0.99.beta19")
1315 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
1319 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))
1320 (patches (search-patches "libcaca-CVE-2021-3410-pt1.patch"
1321 "libcaca-CVE-2021-3410-pt2.patch"))))
1322 (build-system gnu-build-system)
1324 '(#:configure-flags '("--disable-static")))
1325 (native-inputs (list pkg-config))
1334 (home-page "http://caca.zoy.org/wiki/libcaca")
1335 (synopsis "Colour ASCII-art library")
1336 (description "libcaca is a graphics library that outputs text instead of
1337 pixels, so that it can work on older video cards or text terminals. It
1338 supports Unicode, 2048 colors, dithering of color images, and advanced text
1339 canvas operations.")
1340 (license license:wtfpl2)))
1342 (define-public libdca
1349 "https://download.videolan.org/pub/videolan/libdca/"
1350 version "/libdca-" version ".tar.bz2"))
1353 "0sjz0s0nrv7jcpvh1i432x3jza0y5yycmzw84cfncb2qby0i62rs"))))
1354 (build-system gnu-build-system)
1356 (list autoconf automake libtool))
1357 (home-page "https://www.videolan.org/developers/libdca.html")
1358 (synopsis "DTS Coherent Acoustics decoder")
1359 (description "libdca is a library for decoding DTS Coherent Acoustics
1361 (license license:gpl2+)))
1363 (define-public libdv
1370 "mirror://sourceforge/libdv/libdv/"
1371 version "/libdv-" version ".tar.gz"))
1374 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
1375 (build-system gnu-build-system)
1376 (native-inputs (list pkg-config))
1377 (inputs (list libxv))
1378 (home-page "http://libdv.sourceforge.net/")
1379 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
1380 (description "The Quasar DV codec (libdv) is a software codec for DV
1381 video, the encoding format used by most digital camcorders, typically those
1382 that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
1383 developed according to the official standards for DV video: IEC 61834 and
1385 (license license:lgpl2.1+)))
1387 (define-public libmatroska
1389 (name "libmatroska")
1394 (uri (string-append "https://dl.matroska.org/downloads/"
1395 "libmatroska/libmatroska-" version ".tar.xz"))
1397 (base32 "06h81sxyz2riic0gpzik6ffcnq32wrqphi8c6k55glcdymiimyfs"))))
1398 (build-system cmake-build-system)
1403 (list "-DBUILD_SHARED_LIBS=YES")
1404 #:tests? #f)) ; no test suite
1405 (home-page "https://www.matroska.org")
1406 (synopsis "C++ library to parse Matroska files (.mkv and .mka)")
1408 "Matroska aims to become the standard of multimedia container formats.
1409 It is based on @dfn{EBML} (Extensible Binary Meta Language), a binary derivative
1410 of XML. EBML enables the Matroska Development Team to gain significant
1411 advantages in terms of future format extensibility, without breaking file
1412 support in old parsers.
1413 libebml is a C++ library to read and write EBML files.")
1414 (license license:lgpl2.1)))
1416 (define-public libplacebo
1424 (url "https://code.videolan.org/videolan/libplacebo")
1425 (commit (string-append "v" version))))
1426 (file-name (git-file-name name version))
1428 (base32 "08kqsd29h8wm0vz7698wh2mdgpwv6anqc5n7d1spnnamwyfwc64h"))))
1429 (build-system meson-build-system)
1432 `("-Dopengl=enabled"
1433 ,(string-append "-Dvulkan-registry="
1434 (assoc-ref %build-inputs "vulkan-headers")
1435 "/share/vulkan/registry/vk.xml"))))
1437 (list python-mako pkg-config))
1445 (home-page "https://code.videolan.org/videolan/libplacebo")
1446 (synopsis "GPU-accelerated image/video processing library")
1447 (description "libplacebo is, in a nutshell, the core rendering algorithms
1448 and ideas of mpv rewritten as an independent library. As of today, libplacebo
1449 contains a large assortment of video processing shaders, focusing on both
1450 quality and performance.")
1451 (license license:lgpl2.1+)))
1453 (define-public libva
1460 (uri (string-append "https://github.com/intel/libva/releases/download/"
1461 version "/libva-" version ".tar.bz2"))
1463 (base32 "0q6l193x9whd80sjd5mx8cb7c0fcljb19nhfpla5h49nkzrq7lzs"))))
1464 (build-system gnu-build-system)
1476 (modify-phases %standard-phases
1478 'build 'fix-dlopen-paths
1479 (lambda* (#:key outputs #:allow-other-keys)
1480 (let ((out (assoc-ref outputs "out")))
1481 (substitute* "va/drm/va_drm_auth_x11.c"
1482 (("\"libva-x11\\.so\\.%d\"")
1483 (string-append "\"" out "/lib/libva-x11.so.%d\"")))
1485 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
1486 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
1488 (list (string-append "--with-drivers-path="
1489 (assoc-ref %build-inputs "mesa") "/lib/dri"))
1490 ;; However, we can't write to mesa's store directory, so override the
1491 ;; following make variable to install the dummy driver to libva's
1492 ;; $prefix/lib/dri directory.
1494 (list (string-append "dummy_drv_video_ladir="
1495 (assoc-ref %outputs "out") "/lib/dri"))))
1496 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
1497 (synopsis "Video acceleration library")
1498 (description "The main motivation for VA-API (Video Acceleration API) is
1499 to enable hardware accelerated video decode/encode at various
1500 entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
1501 standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
1502 (license license:expat)))
1504 (define-public libva-utils
1506 (name "libva-utils")
1511 (uri (string-append "https://github.com/intel/libva-utils/releases/download/"
1512 version "/libva-utils-" version ".tar.bz2"))
1514 (base32 "05rasyqnsg522zqxak1q8rrm1hys7wwbi41kd0szjq0d27awjf4j"))))
1515 (build-system gnu-build-system)
1518 (list "--enable-wayland"
1523 (list libdrm libva libx11 mesa wayland))
1524 (home-page "https://01.org/linuxmedia/vaapi")
1525 (synopsis "Collection of testing utilities for VA-API")
1527 "This is a collection of utilities to query and test the @acronym{VA-API,
1528 Video Acceleration API} implemented by the libva library.
1530 These tools require a supported graphics chip, driver, and VA-API back end to
1532 (license license:expat)))
1534 (define-public ffmpeg
1540 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1544 "00hfwd8ld6jnd26pl9f0wcd2mag4zacxxgqgabsja2xkkagavnza"))))
1545 (build-system gnu-build-system)
1548 ("fontconfig" ,fontconfig)
1549 ("freetype" ,freetype)
1550 ("frei0r-plugins" ,frei0r-plugins)
1557 ("libbluray" ,libbluray)
1558 ("libcaca" ,libcaca)
1559 ("libcdio-paranoia" ,libcdio-paranoia)
1561 ("libtheora" ,libtheora)
1563 ("libvdpau" ,libvdpau)
1564 ("libvorbis" ,libvorbis)
1567 ("libx264" ,libx264)
1570 ("pulseaudio" ,pulseaudio)
1571 ;; XXX: rav1e depends on rust, which currently only works on x86_64.
1572 ;; See also the related configure flag when changing this.
1573 ,@(if (string-prefix? "x86_64" (or (%current-target-system)
1581 ("twolame" ,twolame)
1582 ("vidstab" ,vidstab)
1594 `(#:test-target "fate"
1596 ;; possible additional inputs:
1597 ;; --enable-avisynth enable reading of AviSynth script
1599 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
1600 ;; --enable-libcelt enable CELT decoding via libcelt [no]
1601 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
1602 ;; and libraw1394 [no]
1603 ;; --enable-libfaac enable AAC encoding via libfaac [no]
1604 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
1605 ;; --enable-libflite enable flite (voice synthesis) support via
1607 ;; --enable-libgme enable Game Music Emu via libgme [no]
1608 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
1609 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
1610 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
1611 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
1612 ;; --enable-libnut enable NUT (de)muxing via libnut,
1613 ;; native (de)muxer exists [no]
1614 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
1615 ;; libopencore-amrnb [no]
1616 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
1617 ;; libopencore-amrwb [no]
1618 ;; --enable-libopencv enable video filtering via libopencv [no]
1619 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
1621 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
1622 ;; --enable-libschroedinger enable Dirac de/encoding via
1623 ;; libschroedinger [no]
1624 ;; --enable-libshine enable fixed-point MP3 encoding via
1626 ;; --enable-libssh enable SFTP protocol via libssh [no]
1627 ;; (libssh2 does not work)
1628 ;; --enable-libstagefright-h264 enable H.264 decoding via
1629 ;; libstagefright [no]
1630 ;; --enable-libutvideo enable Ut Video encoding and decoding via
1632 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
1633 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
1634 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
1635 ;; libvo-amrwbenc [no]
1636 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
1637 ;; --enable-libxavs enable AVS encoding via xavs [no]
1638 ;; --enable-libzmq enable message passing via libzmq [no]
1639 ;; --enable-libzvbi enable teletext support via libzvbi [no]
1640 ;; --enable-opencl enable OpenCL code
1641 '("--enable-avresample"
1642 "--enable-gpl" ; enable optional gpl licensed parts
1645 "--enable-fontconfig"
1650 "--enable-libbluray"
1654 "--enable-libfreetype"
1655 "--enable-libmp3lame"
1658 ,@(if (string-prefix? "x86_64" (or (%current-target-system)
1660 '("--enable-librav1e")
1665 "--enable-libtheora"
1666 "--enable-libtwolame"
1667 "--enable-libvidstab"
1668 "--enable-libvorbis"
1678 "--enable-runtime-cpudetect"
1680 ;; The HTML pages take 7.2 MiB
1681 "--disable-htmlpages"
1683 ;; The static libraries are 23 MiB
1686 ;; Runtime cpu detection is not implemented on
1687 ;; MIPS, so we disable some features.
1688 "--disable-mips32r2"
1690 "--disable-mipsdspr2"
1691 "--disable-mipsfpu")
1693 (modify-phases %standard-phases
1696 ;; configure does not work followed by "SHELL=..." and
1697 ;; "CONFIG_SHELL=..."; set environment variables instead
1698 (lambda* (#:key outputs configure-flags #:allow-other-keys)
1699 (let ((out (assoc-ref outputs "out")))
1700 (substitute* "configure"
1701 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1702 (setenv "SHELL" (which "bash"))
1703 (setenv "CONFIG_SHELL" (which "bash"))
1706 (string-append "--prefix=" out)
1707 ;; Add $libdir to the RUNPATH of all the binaries.
1708 (string-append "--extra-ldflags=-Wl,-rpath="
1712 'check 'set-ld-library-path
1714 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
1716 (let* ((dso (find-files "." "\\.so$"))
1717 (path (string-join (map dirname dso) ":")))
1718 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
1719 (setenv "LD_LIBRARY_PATH" path)
1721 (home-page "https://www.ffmpeg.org/")
1722 (synopsis "Audio and video framework")
1723 (description "FFmpeg is a complete, cross-platform solution to record,
1724 convert and stream audio and video. It includes the libavcodec
1725 audio/video codec library.")
1726 (license license:gpl2+)))
1728 (define-public ffmpeg-3.4
1734 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1738 "0d8nkd9c85rkjlgsq1hidmykkrksi883ygqzhhj6wh4nqflv8vs9"))))
1740 (substitute-keyword-arguments (package-arguments ffmpeg)
1741 ((#:modules modules %gnu-build-system-modules)
1744 ((#:configure-flags flags)
1747 '("--enable-libdav1d"
1750 "--enable-libsrt")))))
1751 (inputs (modify-inputs (package-inputs ffmpeg)
1752 (delete "dav1d" "libaom" "rav1e" "srt")))))
1754 (define-public ffmpeg-2.8
1760 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
1764 "0k6dq7b8rpjvdl5ncf1135qwc36x0x9va8v83aggvbfhy5d97vwn"))))
1766 `(#:tests? #f ; XXX: Enable them later, if required
1771 "--extra-cflags=-DFF_API_OLD_ENCODE_VIDEO -DFF_API_OLD_ENCODE_AUDIO")
1773 (modify-phases %standard-phases
1775 (lambda* (#:key outputs configure-flags #:allow-other-keys)
1776 (let ((out (assoc-ref outputs "out")))
1777 (substitute* "configure"
1778 (("#! /bin/sh") (string-append "#!" (which "sh"))))
1779 ;; configure does not work followed by "SHELL=..." and
1780 ;; "CONFIG_SHELL=..."; set environment variables instead.
1781 (setenv "SHELL" (which "bash"))
1782 (setenv "CONFIG_SHELL" (which "bash"))
1785 (string-append "--prefix=" out)
1786 ;; Add $libdir to the RUNPATH of all the binaries.
1787 (string-append "--extra-ldflags=-Wl,-rpath="
1791 'check 'set-ld-library-path
1793 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
1795 (let* ((dso (find-files "." "\\.so$"))
1796 (path (string-join (map dirname dso) ":")))
1797 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
1798 (setenv "LD_LIBRARY_PATH" path)
1800 (inputs (modify-inputs (package-inputs ffmpeg)
1801 (delete "dav1d" "libaom" "rav1e" "srt")))))
1803 (define-public ffmpeg-for-stepmania
1812 (url "https://github.com/stepmania/ffmpeg")
1813 (commit "eda6effcabcf9c238e4635eb058d72371336e09b")))
1815 (base32 "1by8rmbva8mfrivdbbkr2gx4kga89zqygkd4cfjl76nr8mdcdamb"))
1816 (file-name (git-file-name "ffmpeg" version))))
1818 (substitute-keyword-arguments (package-arguments ffmpeg)
1819 ((#:configure-flags flags)
1820 '(list "--disable-programs"
1823 "--disable-avdevice"
1824 "--disable-swresample"
1825 "--disable-postproc"
1826 "--disable-avfilter"
1828 "--enable-static"))))
1831 (define-public ffmpegthumbnailer
1833 (name "ffmpegthumbnailer")
1838 (url "https://github.com/dirkvdb/ffmpegthumbnailer")
1840 (file-name (git-file-name name version))
1843 "1bakbr714j7yxdal1f5iq0gcl4cxggbbgj227ihdh5kvygqlwich"))))
1844 (build-system cmake-build-system)
1848 (list ffmpeg libjpeg-turbo libpng gvfs))
1850 `(#:configure-flags (list "-DENABLE_GIO=ON" "-DENABLE_THUMBNAILER=ON")))
1851 (home-page "https://github.com/dirkvdb/ffmpegthumbnailer")
1852 (synopsis "Create thumbnails from video files")
1853 (description "FFmpegthumbnailer is a lightweight video thumbnailer that
1854 can be used by file managers to create thumbnails for your video files. The
1855 thumbnailer uses ffmpeg to decode frames from the video files, so supported
1856 videoformats depend on the configuration flags of ffmpeg.")
1857 (license license:gpl2+)))
1866 "https://download.videolan.org/pub/videolan/vlc/"
1867 (car (string-split version #\-))
1868 "/vlc-" version ".tar.xz"))
1871 "1xhhjhwihkz74dag25r5fscvw1v2byy4c8qxaxsw29gncky3bbpz"))))
1872 (build-system gnu-build-system)
1876 ("gettext" ,gettext-minimal)
1877 ("pkg-config" ,pkg-config)))
1878 ;; FIXME: Add optional inputs once available.
1880 `(("alsa-lib" ,alsa-lib)
1887 ("fontconfig" ,fontconfig)
1888 ("freetype" ,freetype)
1889 ("fribidi" ,fribidi)
1892 ("libarchive" ,libarchive)
1894 ("libavc1394" ,libavc1394)
1895 ("libbluray" ,libbluray)
1896 ("libcaca" ,libcaca)
1897 ("libcddb" ,libcddb)
1899 ("libdvbpsi" ,libdvbpsi)
1900 ("libdvdnav" ,libdvdnav)
1901 ("libdvdread" ,libdvdread)
1902 ("libebml" ,libebml)
1903 ("libgcrypt" ,libgcrypt)
1905 ("libkate" ,libkate)
1907 ("libmatroska" ,libmatroska)
1908 ("libmicrodns" ,libmicrodns)
1909 ("libmodplug" ,libmodplug)
1910 ("libmpeg2" ,libmpeg2)
1913 ("libraw1394" ,libraw1394)
1914 ("librsvg" ,(librsvg-for-system))
1915 ("libsamplerate" ,libsamplerate)
1916 ("libsecret" ,libsecret)
1917 ("libssh2" ,libssh2)
1918 ("libupnp" ,libupnp)
1920 ("libvdpau" ,libvdpau)
1921 ("libvorbis" ,libvorbis)
1923 ("libtheora" ,libtheora)
1924 ("libx264" ,libx264)
1925 ("libxext" ,libxext)
1927 ("libxinerama" ,libxinerama)
1928 ("libxml2" ,libxml2)
1930 ("livemedia-utils" ,livemedia-utils)
1935 ("pulseaudio" ,pulseaudio)
1936 ("protobuf" ,protobuf)
1937 ("python" ,python-wrapper)
1938 ("qtbase" ,qtbase-5)
1940 ("qtx11extras" ,qtx11extras)
1943 ("sdl-image" ,sdl-image)
1945 ("speexdsp" ,speexdsp)
1946 ;; VLC is not yet compatible with SRT > 1.4.1.
1949 ("twolame" ,twolame)
1951 ("wayland" ,wayland)
1952 ("wayland-protocols" ,wayland-protocols)
1954 ("xcb-util-keysyms" ,xcb-util-keysyms)))
1958 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
1959 (assoc-ref %build-inputs "ffmpeg")
1960 "/lib")) ;needed for the tests
1963 (modify-phases %standard-phases
1964 (add-after 'unpack 'patch-source
1965 (lambda* (#:key inputs #:allow-other-keys)
1966 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
1967 (substitute* "configure"
1968 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
1969 (string-append "LIVE555_PREFIX=" livemedia-utils)))
1970 ;; Some of the tests require using the display to test out VLC,
1971 ;; which fails in our sandboxed build system
1972 (substitute* "test/run_vlc.sh"
1973 (("./vlc --ignore-config") "echo"))
1975 (add-after 'strip 'regenerate-plugin-cache
1976 (lambda* (#:key outputs #:allow-other-keys)
1977 ;; The 'install-exec-hook' rule in the top-level Makefile.am
1978 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
1979 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
1980 ;; it references. Thus, we first reset the timestamps of all
1981 ;; these files, and then regenerate the cache such that the
1982 ;; mtimes it includes are always zero instead of being dependent
1983 ;; on the build time.
1984 (let* ((out (assoc-ref outputs "out"))
1985 (pkglibdir (string-append out "/lib/vlc"))
1986 (plugindir (string-append pkglibdir "/plugins"))
1987 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
1988 ;; TODO: Factorize 'reset-timestamps'.
1989 (for-each (lambda (file)
1990 (let ((s (lstat file)))
1991 (unless (eq? (stat:type s) 'symlink)
1993 (find-files plugindir))
1994 (invoke cachegen plugindir))))
1995 (add-after 'install 'wrap-executable
1996 (lambda* (#:key outputs #:allow-other-keys)
1997 (let ((out (assoc-ref outputs "out"))
1998 (plugin-path (getenv "QT_PLUGIN_PATH")))
1999 (wrap-program (string-append out "/bin/vlc")
2000 `("QT_PLUGIN_PATH" ":" prefix (,plugin-path))))
2002 (home-page "https://www.videolan.org/")
2003 (synopsis "Audio and video framework")
2004 (description "VLC is a cross-platform multimedia player and framework
2005 that plays most multimedia files as well as DVD, Audio CD, VCD, and various
2006 streaming protocols.")
2007 (license license:gpl2+)))
2009 (define-public mplayer
2016 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
2020 "0j5mflr0wnklxsvnpmxvk704hscyn2785hvvihj2i3a7b3anwnc2"))))
2021 (build-system gnu-build-system)
2022 ;; FIXME: Add additional inputs once available.
2024 (list pkg-config yasm))
2026 `(("alsa-lib" ,alsa-lib)
2027 ("cdparanoia" ,cdparanoia)
2029 ("fontconfig" ,fontconfig)
2030 ("freetype" ,freetype)
2034 ("libdvdcss" ,libdvdcss)
2035 ("libdvdnav" ,libdvdnav) ; ignored without libdvdread
2036 ("libdvdread" ,libdvdread) ; ignored without libdvdnav
2037 ("libjpeg" ,libjpeg-turbo)
2038 ("libmpeg2" ,libmpeg2)
2039 ("libmpg123" ,mpg123) ; audio codec for MP3
2041 ("libtheora" ,libtheora)
2042 ("libvdpau" ,libvdpau)
2043 ("libvorbis" ,libvorbis)
2045 ("libx264" ,libx264)
2046 ("libxinerama" ,libxinerama)
2048 ("libxxf86dga" ,libxxf86dga)
2052 ("pulseaudio" ,pulseaudio)
2053 ("python" ,python-wrapper)
2058 `(#:tests? #f ; no test target
2060 (modify-phases %standard-phases
2062 ;; configure does not work followed by "SHELL=..." and
2063 ;; "CONFIG_SHELL=..."; set environment variables instead
2064 (lambda* (#:key inputs outputs #:allow-other-keys)
2065 (let ((out (assoc-ref outputs "out"))
2066 (libx11 (assoc-ref inputs "libx11")))
2067 (substitute* "configure"
2068 (("#! /bin/sh") (string-append "#!" (which "sh"))))
2069 (setenv "SHELL" (which "bash"))
2070 (setenv "CONFIG_SHELL" (which "bash"))
2071 (invoke "./configure"
2072 (string-append "--extra-cflags=-I"
2073 libx11 "/include") ; to detect libx11
2074 "--disable-ffmpeg_a" ; disables bundled ffmpeg
2075 (string-append "--prefix=" out)
2076 ;; Enable runtime cpu detection where supported,
2077 ;; and choose a suitable target.
2078 ,@(match (or (%current-target-system)
2081 '("--enable-runtime-cpudetection"
2082 "--target=x86_64-linux"))
2084 '("--enable-runtime-cpudetection"
2085 "--target=i686-linux"))
2087 '("--target=mips3-linux"))
2088 (_ (list (string-append
2090 (or (%current-target-system)
2091 (nix-system->gnu-triplet
2092 (%current-system)))))))
2093 "--disable-iwmmxt")))))))
2094 (home-page "https://www.mplayerhq.hu")
2095 (synopsis "Audio and video player")
2096 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
2097 Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
2098 NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
2099 SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
2100 (license license:gpl2)))
2109 (url "https://github.com/mpv-player/mpv")
2110 (commit (string-append "v" version))))
2111 (file-name (git-file-name name version))
2113 (base32 "12qxwm1ww5vhjddl8yvj1xa0n1fi9z3lmzwhaiday2v59ca0qgsk"))))
2114 (build-system waf-build-system)
2116 (list perl ; for zsh completion file
2117 pkg-config python-docutils))
2118 ;; Missing features: libguess, V4L2
2120 `(("alsa-lib" ,alsa-lib)
2127 ("libbluray" ,libbluray)
2128 ("libcaca" ,libcaca)
2129 ("libbs2b" ,libbs2b)
2130 ("libcdio-paranoia" ,libcdio-paranoia)
2131 ("libdvdread" ,libdvdread)
2132 ("libdvdnav" ,libdvdnav)
2133 ("libjpeg" ,libjpeg-turbo)
2135 ("libvdpau" ,libvdpau)
2137 ("libxext" ,libxext)
2138 ("libxinerama" ,libxinerama)
2139 ("libxrandr" ,libxrandr)
2140 ("libxscrnsaver" ,libxscrnsaver)
2142 ;; XXX: lua > 5.2 is not currently supported; see
2143 ;; waftools/checks/custom.py
2147 ("pulseaudio" ,pulseaudio)
2149 ("shaderc" ,shaderc)
2150 ("vulkan-headers" ,vulkan-headers)
2151 ("vulkan-loader" ,vulkan-loader)
2153 ("wayland" ,wayland)
2154 ("wayland-protocols" ,wayland-protocols)
2155 ("libxkbcommon" ,libxkbcommon)
2160 (modify-phases %standard-phases
2161 (add-after 'unpack 'patch-paths
2162 (lambda* (#:key inputs #:allow-other-keys)
2163 (let ((ytdl (assoc-ref inputs "yt-dlp")))
2164 (substitute* "player/lua/ytdl_hook.lua"
2166 (string-append "\"" ytdl "/bin/yt-dlp\","))))))
2167 (add-before 'configure 'build-reproducibly
2169 ;; Somewhere in the build system library dependencies are enumerated
2170 ;; and passed as linker flags, but the order in which they are added
2171 ;; varies. See <https://github.com/mpv-player/mpv/issues/7855>.
2172 ;; Set PYTHONHASHSEED as a workaround for deterministic results.
2173 (setenv "PYTHONHASHSEED" "1")
2176 'configure 'setup-waf
2177 (lambda* (#:key inputs #:allow-other-keys)
2178 (let ((waf (assoc-ref inputs "waf")))
2179 (copy-file (string-append waf "/bin/waf") "waf"))
2182 #:configure-flags (list "--enable-libmpv-shared"
2185 "--disable-build-date")
2186 ;; No check function defined.
2188 (home-page "https://mpv.io/")
2189 (synopsis "Audio and video player")
2190 (description "mpv is a general-purpose audio and video player. It is a
2191 fork of mplayer2 and MPlayer. It shares some features with the former
2192 projects while introducing many more.")
2193 (license license:gpl2+)))
2195 (define-public smplayer
2202 "mirror://sourceforge/smplayer/SMPlayer/" version
2203 "/smplayer-" version ".tar.bz2"))
2206 "12nvcl0cfix1xay9hfi7856vg4lpv8y5b0a22212bsjbvl5g22rc"))))
2207 (build-system qt-build-system)
2211 (list bash-minimal qtbase-5 zlib mpv))
2213 (list #:tests? #false ; no tests
2214 #:make-flags #~(list (string-append "PREFIX=" #$output)
2215 (string-append "CC=" #+(cc-for-target))
2216 ;; A KLUDGE to turn off invoking lrelease on the
2217 ;; project for now, because it fails consistently
2218 ;; with "WARNING: Could not find qmake spec
2219 ;; 'default'". See below.
2222 #~(modify-phases %standard-phases
2224 ;; Due to the above, we must run lrelease separately on each .ts file
2225 ;; (as opposed to running `lrelease-pro smplayer.pro` for the entire
2226 ;; project, as the Makefile does normally without the above kludge).
2227 (add-after 'build 'compile-ts-files
2229 (for-each (lambda (file)
2230 (invoke "lrelease" file))
2231 (find-files "./" "\\.ts$"))))
2232 (add-after 'install 'wrap-executable
2233 (lambda* (#:key inputs outputs #:allow-other-keys)
2234 (let* ((out (assoc-ref outputs "out"))
2235 (mpv (assoc-ref inputs "mpv")))
2236 (wrap-program (string-append out "/bin/smplayer")
2238 ,(list (string-append mpv "/bin"))))))))))
2239 (home-page "https://www.smplayer.info")
2240 (synopsis "Complete front-end for MPlayer, a media player")
2241 (description "SMPlayer is a graphical user interface (GUI) for
2242 MPlayer, which is capable of playing almost all known video and audio
2243 formats. Apart from providing access for the most common and useful
2244 options of MPlayer, SMPlayer adds other interesting features like the
2245 possibility to play Youtube videos, download subtitles, remember
2246 the last played position, etc.")
2247 (license license:gpl2+)))
2249 (define-public gnome-mpv
2250 (deprecated-package "gnome-mpv" celluloid))
2252 (define-public mpv-mpris
2260 (url "https://github.com/hoyon/mpv-mpris")
2262 (file-name (git-file-name name version))
2264 (base32 "03gldk149i2108w3ylyfmci77kdq4whdzfavh7hjviwyj534101r"))))
2265 (build-system copy-build-system)
2268 '(("mpris.so" "lib/"))
2270 (modify-phases %standard-phases
2271 (add-before 'install 'build
2273 (setenv "CC" (which "gcc"))
2274 (invoke "make"))))))
2279 (home-page "https://github.com/hoyon/mpv-mpris")
2280 (synopsis "MPRIS plugin for mpv")
2281 (description "This package provides an @dfn{MPRIS} (Media Player Remote
2282 Interfacing Specification) plugin for the @code{mpv} media player. It implements
2283 @code{org.mpris.MediaPlayer2} and @code{org.mpris.MediaPlayer2.Player} D-Bus
2286 To load this plugin, specify the following option when starting mpv:
2287 @code{--script $GUIX_PROFILE/lib/mpris.so} or link it into
2288 @file{$HOME/.config/mpv/scripts}.")
2289 (license license:expat)))
2291 (define-public libvpx
2298 (url "https://chromium.googlesource.com/webm/libvpx")
2299 (commit (string-append "v" version))))
2300 (file-name (git-file-name name version))
2303 "00f1jrclai2b6ys78dpsg6r1mvcyxlna93vxcz8zjyia24c2pjsb"))
2304 (patches (search-patches "libvpx-CVE-2016-2818.patch"))))
2305 (build-system gnu-build-system)
2307 `(#:configure-flags (list "--enable-shared"
2310 ;; Limit size to avoid CVE-2015-1258
2311 "--size-limit=16384x16384"
2312 (string-append "--prefix=" (assoc-ref %outputs "out")))
2313 #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
2314 (assoc-ref %outputs "out") "/lib"))
2315 #:phases (modify-phases %standard-phases
2317 (lambda* (#:key configure-flags #:allow-other-keys)
2318 ;; The configure script does not understand some of the GNU
2319 ;; options, so we only add the flags specified above.
2320 (apply invoke "./configure" configure-flags))))
2322 ;; XXX: The test suite wants to download 871 files from a cloud storage
2323 ;; service (see test/test-data.sha1). It is possible to specify a
2324 ;; custom directory, but there seems to be no tarball with all files.
2328 (synopsis "VP8/VP9 video codec")
2329 (description "libvpx is a codec for the VP8/VP9 video compression format.")
2330 (license license:bsd-3)
2331 (home-page "https://www.webmproject.org/")))
2333 (define-public youtube-dl
2336 (version "2021.12.17")
2339 (uri (string-append "https://youtube-dl.org/downloads/latest/"
2340 "youtube-dl-" version ".tar.gz"))
2343 "1prm84ci1n1kjzhikhrsbxbgziw6br822psjnijm2ibqnz49jfwz"))
2346 ;; Delete the pre-generated files, except for the man page
2347 ;; which requires 'pandoc' to build.
2348 (for-each delete-file '("youtube-dl"
2349 ;;pandoc is needed to generate
2351 "youtube-dl.bash-completion"
2353 "youtube-dl.zsh"))))))
2354 (build-system python-build-system)
2356 ;; The problem here is that the directory for the man page and completion
2357 ;; files is relative, and for some reason, setup.py uses the
2358 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
2359 ;; So, we need pass the prefix directly. In addition, make sure the Bash
2360 ;; completion file is called 'youtube-dl' rather than
2361 ;; 'youtube-dl.bash-completion'.
2362 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
2363 #:phases (modify-phases %standard-phases
2364 (add-after 'unpack 'default-to-the-ffmpeg-input
2366 ;; See <https://issues.guix.gnu.org/43418#5>.
2367 ;; ffmpeg is big but required to request free formats
2368 ;; from, e.g., YouTube so pull it in unconditionally.
2369 ;; Continue respecting the --ffmpeg-location argument.
2370 (substitute* "youtube_dl/postprocessor/ffmpeg.py"
2371 (("\\.get\\('ffmpeg_location'\\)" match)
2372 (format #f "~a or '~a'" match (which "ffmpeg"))))))
2373 (add-before 'build 'build-generated-files
2375 ;; Avoid the make targets that require pandoc.
2379 ;;"youtube-dl.1" ; needs pandoc
2380 "youtube-dl.bash-completion"
2382 "youtube-dl.fish")))
2383 (add-before 'install 'fix-the-data-directories
2384 (lambda* (#:key outputs #:allow-other-keys)
2385 (let ((prefix (assoc-ref outputs "out")))
2386 (mkdir "bash-completion")
2387 (rename-file "youtube-dl.bash-completion"
2388 "bash-completion/youtube-dl")
2389 (substitute* "setup.py"
2390 (("youtube-dl\\.bash-completion")
2391 "bash-completion/youtube-dl")
2393 (string-append "'" prefix "/etc/"))
2395 (string-append "'" prefix "/share/"))))))
2396 (add-after 'install 'install-completion
2397 (lambda* (#:key outputs #:allow-other-keys)
2398 (let* ((out (assoc-ref outputs "out"))
2399 (zsh (string-append out
2400 "/share/zsh/site-functions")))
2402 (copy-file "youtube-dl.zsh"
2403 (string-append zsh "/_youtube-dl"))))))))
2408 (synopsis "Download videos from YouTube.com and other sites")
2410 "Youtube-dl is a small command-line program to download videos from
2411 YouTube.com and many more sites.")
2412 (home-page "https://yt-dl.org")
2413 (properties '((release-monitoring-url . "https://yt-dl.org/downloads/")))
2414 (license license:public-domain)))
2416 (define-public yt-dlp
2417 (package/inherit youtube-dl
2419 (version "2021.10.22")
2422 (uri (string-append "https://github.com/yt-dlp/yt-dlp/"
2423 "releases/download/"
2424 version "/yt-dlp.tar.gz"))
2427 "0xh4cwmvx49pxn8x07wj2dy8ynj6xg8977l5493vv0l8zc27wp87"))
2430 ;; Delete the pre-generated files, except for the man page
2431 ;; which requires 'pandoc' to build.
2432 (for-each delete-file '("yt-dlp"
2433 ;;pandoc is needed to generate
2435 "completions/bash/yt-dlp"
2436 "completions/fish/yt-dlp.fish"
2437 "completions/zsh/_yt-dlp"))
2440 (substitute-keyword-arguments (package-arguments youtube-dl)
2443 `(modify-phases ,phases
2444 ;; See the comment for the corresponding phase in youtube-dl.
2445 (replace 'default-to-the-ffmpeg-input
2447 (substitute* "yt_dlp/postprocessor/ffmpeg.py"
2448 (("\\.get_param\\('ffmpeg_location'\\)" match)
2449 (format #f "~a or '~a'" match (which "ffmpeg"))))
2451 (replace 'build-generated-files
2453 ;; Avoid the yt-dlp.1 target, which requires pandoc.
2454 (invoke "make" "PYTHON=python" "yt-dlp" "completions")))
2455 (replace 'fix-the-data-directories
2456 (lambda* (#:key outputs #:allow-other-keys)
2457 (let ((prefix (assoc-ref outputs "out")))
2458 (substitute* "setup.py"
2460 (string-append "'" prefix "/etc/"))
2462 (string-append "'" prefix "/share/"))))
2464 (delete 'install-completion)
2466 (lambda* (#:key tests? #:allow-other-keys)
2468 (invoke "pytest" "-k" "not download"))))))))
2470 `(("python-mutagen" ,python-mutagen)
2471 ("python-pycryptodomex" ,python-pycryptodomex)
2472 ("python-websockets" ,python-websockets)
2473 ,@(package-inputs youtube-dl)))
2475 `(("python-pytest" ,python-pytest)
2476 ,@(package-native-inputs youtube-dl)))
2478 "yt-dlp is a small command-line program to download videos from
2479 YouTube.com and many more sites. It is a fork of youtube-dl with a
2480 focus on adding new features while keeping up-to-date with the
2482 (properties '((release-monitoring-url . "https://pypi.org/project/yt-dlp/")))
2483 (home-page "https://github.com/yt-dlp/yt-dlp")))
2485 (define-public youtube-dl-gui
2487 (name "youtube-dl-gui")
2492 (uri (pypi-uri "Youtube-DLG" version))
2495 "1bvq2wyn6az59vpdy04dh68fs8m2qzz948xhphibbcpwpcdk00cd"))))
2496 (build-system python-build-system)
2498 ;; In Guix, wxpython has not yet been packaged for Python 3.
2499 `(#:python ,python-2
2500 ;; This package has no tests.
2503 (modify-phases %standard-phases
2504 (add-before 'build 'patch-source
2505 (lambda* (#:key inputs #:allow-other-keys)
2506 ;; The youtube-dl-gui program lets you configure options. Some of
2507 ;; them are problematic, so we change their defaults.
2508 (substitute* "youtube_dl_gui/optionsmanager.py"
2509 ;; When this is true, the builder process will try (and fail) to
2510 ;; write logs to the builder user's home directory.
2511 (("'enable_log': True") "'enable_log': False")
2512 ;; This determines which youtube-dl program youtube-dl-gui will
2513 ;; run. If we don't set this, then youtube-dl-gui might download
2514 ;; an arbitrary copy from the Internet into the user's home
2515 ;; directory and run it, so let's make sure youtube-dl-gui uses
2516 ;; the youtube-dl from the inputs by default.
2517 (("'youtubedl_path': self.config_path")
2518 (string-append "'youtubedl_path': '"
2519 (assoc-ref inputs "youtube-dl")
2521 ;; When this is True, when youtube-dl-gui is finished downloading
2522 ;; a file, it will try (and possibly fail) to open the directory
2523 ;; containing the downloaded file. This can fail because it
2524 ;; assumes that xdg-open is in PATH. Unfortunately, simply
2525 ;; adding xdg-utils to the propagated inputs is not enough to
2526 ;; make this work, so for now we set the default to False.
2527 (("'open_dl_dir': True") "'open_dl_dir': False"))
2528 ;; The youtube-dl program from the inputs is actually a wrapper
2529 ;; script written in bash, so attempting to invoke it as a python
2530 ;; script will fail.
2531 (substitute* "youtube_dl_gui/downloaders.py"
2532 (("cmd = \\['python', self\\.youtubedl_path\\]")
2533 "cmd = [self.youtubedl_path]"))
2534 ;; Use relative paths for installing data files so youtube-dl-gui
2535 ;; installs the files relative to its prefix in the store, rather
2536 ;; than relative to /. Also, instead of installing data files into
2537 ;; $prefix/usr/share, install them into $prefix/share for
2538 ;; consistency (see: (standards) Directory Variables).
2539 (substitute* "setup.py"
2540 (("= '/usr/share") "= 'share"))
2541 ;; Update get_locale_file() so it finds the installed localization
2543 (substitute* "youtube_dl_gui/utils.py"
2544 (("os\\.path\\.join\\('/usr', 'share'")
2545 (string-append "os.path.join('"
2546 (assoc-ref %outputs "out")
2549 (add-after 'install 'create-desktop-file
2550 (lambda* (#:key outputs #:allow-other-keys)
2551 (let* ((out (assoc-ref outputs "out"))
2552 (applications (string-append out "/share/applications")))
2553 (mkdir-p applications)
2554 (call-with-output-file
2555 (string-append applications "/youtube-dl-gui.desktop")
2560 Name=Youtube-dl GUI~@
2561 Comment=Graphical interface to download video with youtube-dl~@
2562 Exec=youtube-dl-gui~@
2563 TryExec=youtube-dl-gui~@
2565 Icon=youtube-dl-gui~@
2567 Categories=AudioVideo;Audio;Video;Network~%")))
2570 (list gettext-minimal))
2572 (list python2-twodict python2-wxpython youtube-dl))
2573 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
2575 "GUI (Graphical User Interface) for @command{youtube-dl}")
2577 "Youtube-dlG is a GUI (Graphical User Interface) for
2578 @command{youtube-dl}. You can use it to download videos from YouTube and any
2579 other site that youtube-dl supports.")
2580 (license license:unlicense)))
2582 (define-public you-get
2585 (version "0.4.1555")
2589 (url "https://github.com/soimort/you-get")
2590 (commit (string-append "v" version))))
2591 (file-name (git-file-name name version))
2594 "0gn86i6nfsw395r9a3i88nv2g08s5bgjps7w4qawb9gvk4h7zqap"))))
2595 (build-system python-build-system)
2597 (list ffmpeg)) ; for multi-part and >=1080p videos
2600 (modify-phases %standard-phases
2601 (add-after 'unpack 'qualify-input-references
2602 ;; Explicitly invoke the input ffmpeg, instead of whichever one
2603 ;; happens to be in the user's $PATH at run time.
2604 (lambda* (#:key inputs #:allow-other-keys)
2605 (let ((ffmpeg (search-input-file inputs "/bin/ffmpeg")))
2606 (substitute* "src/you_get/processor/ffmpeg.py"
2607 ;; Don't blindly replace all occurrences of ‘'ffmpeg'’: the
2608 ;; same string is also used when sniffing ffmpeg's output.
2609 (("(FFMPEG == |\\()'ffmpeg'" _ prefix)
2610 (string-append prefix "'" ffmpeg "'")))))))
2611 #:tests? #f)) ; XXX some tests need Internet access
2612 (synopsis "Download videos, audio, or images from Web sites")
2614 "You-Get is a command-line utility to download media contents (videos,
2615 audio, images) from the Web. It can use either mpv or vlc for playback.")
2616 (home-page "https://you-get.org/")
2617 (license license:expat)))
2619 (define-public youtube-viewer
2621 (name "youtube-viewer")
2626 (url "https://github.com/trizen/youtube-viewer")
2628 (file-name (git-file-name name version))
2631 "0xdybiihd66b79rbsawjhxs9snm78gld5ziz3gnp8vdcw0bshwz7"))))
2632 (build-system perl-build-system)
2634 (list perl-module-build))
2636 (list perl-data-dump
2642 perl-lwp-protocol-https
2643 perl-lwp-useragent-cached
2646 perl-term-readline-gnu
2647 perl-unicode-linebreak
2649 ;; Some videos play without youtube-dl, but others silently fail to.
2652 `(#:modules ((guix build perl-build-system)
2655 ;; gtk-2/3 variants are both installed by default but the gtk3 variant
2656 ;; is broken without perl-gtk3.
2657 #:module-build-flags '("--gtk2")
2659 (modify-phases %standard-phases
2660 (add-after 'unpack 'refer-to-inputs
2661 (lambda* (#:key inputs #:allow-other-keys)
2662 (substitute* "lib/WWW/YoutubeViewer.pm"
2664 (format #f "'~a/bin/youtube-dl'"
2665 (assoc-ref inputs "youtube-dl"))))
2666 (substitute* '("bin/gtk2-youtube-viewer"
2667 "bin/gtk3-youtube-viewer")
2669 (format #f "'~a/bin/xdg-open'"
2670 (assoc-ref inputs "xdg-utils"))))
2672 (add-after 'install 'install-desktop
2673 (lambda* (#:key outputs #:allow-other-keys)
2674 (let* ((out (assoc-ref outputs "out"))
2675 (sharedir (string-append out "/share")))
2676 (install-file "share/gtk-youtube-viewer.desktop"
2677 (string-append sharedir "/applications"))
2678 (install-file "share/icons/gtk-youtube-viewer.png"
2679 (string-append sharedir "/pixmaps"))
2681 (add-after 'install 'wrap-program
2682 (lambda* (#:key outputs #:allow-other-keys)
2683 (let* ((out (assoc-ref outputs "out"))
2684 (bin-dir (string-append out "/bin/"))
2685 (site-dir (string-append out "/lib/perl5/site_perl/"))
2686 (lib-path (getenv "PERL5LIB")))
2687 (for-each (cut wrap-program <>
2688 `("PERL5LIB" ":" prefix (,lib-path ,site-dir)))
2689 (find-files bin-dir))
2692 "Lightweight application for searching and streaming videos from YouTube")
2694 "Youtube-viewer searches and plays YouTube videos in a native player.
2695 It comes with various search options; it can search for videos, playlists
2696 and/or channels. The videos are streamed directly in a selected video player
2697 at the best resolution (customizable) and with closed-captions (if available).
2698 Both command-line and GTK2 interface are available.")
2699 (home-page "https://github.com/trizen/youtube-viewer")
2700 (license license:perl-license)))
2702 (define-public libbluray
2708 (uri (string-append "https://download.videolan.org/videolan/"
2709 name "/" version "/"
2710 name "-" version ".tar.bz2"))
2713 "1zxfnw1xbghcj7b3zz5djndv6gwssxda19cz1lrlqrkg8577r7kd"))))
2714 (build-system gnu-build-system)
2716 `(#:configure-flags '("--disable-bdjava-jar"
2719 (modify-phases %standard-phases
2720 (add-after 'unpack 'refer-to-libxml2-in-.pc-file
2721 ;; Avoid the need to propagate libxml2 by referring to it
2722 ;; directly, as is already done for fontconfig & freetype.
2723 (lambda* (#:key inputs #:allow-other-keys)
2724 (let ((libxml2 (assoc-ref inputs "libxml2")))
2725 (substitute* "configure"
2726 ((" libxml-2.0") ""))
2727 (substitute* "src/libbluray.pc.in"
2728 (("^Libs.private:" field)
2729 (string-append field " -L" libxml2 "/lib -lxml2")))
2731 (add-before 'build 'fix-dlopen-paths
2732 (lambda* (#:key inputs #:allow-other-keys)
2733 (let ((libaacs (assoc-ref inputs "libaacs"))
2734 (libbdplus (assoc-ref inputs "libbdplus")))
2735 (substitute* "src/libbluray/disc/aacs.c"
2737 (string-append "\"" libaacs "/lib/libaacs\"")))
2738 (substitute* "src/libbluray/disc/bdplus.c"
2740 (string-append "\"" libbdplus "/lib/libbdplus\"")))
2742 (native-inputs (list pkg-config))
2744 `(("fontconfig" ,fontconfig)
2745 ("freetype" ,freetype)
2746 ("libaacs" ,libaacs)
2747 ("libbdplus" ,libbdplus)
2748 ("libxml2" ,libxml2)))
2749 (home-page "https://www.videolan.org/developers/libbluray.html")
2750 (synopsis "Blu-Ray Disc playback library")
2752 "libbluray is a library designed for Blu-Ray Disc playback for media
2753 players, like VLC or MPlayer.")
2754 (license license:lgpl2.1+)))
2756 (define-public libdvdread
2762 (uri (string-append "https://download.videolan.org/videolan/"
2763 "libdvdread/" version "/"
2764 "libdvdread-" version ".tar.bz2"))
2767 "1c7yqqn67m3y3n7nfrgrnzz034zjaw5caijbwbfrq89v46ph257r"))))
2768 (build-system gnu-build-system)
2770 `(#:configure-flags '("--with-libdvdcss=yes")))
2775 (home-page "http://dvdnav.mplayerhq.hu/")
2776 (synopsis "Library for reading video DVDs")
2778 "Libdvdread provides a simple foundation for reading DVD video
2779 disks. It provides the functionality that is required to access many
2780 DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
2781 authentication and descrambling (if an external libdvdcss library is
2783 (license license:gpl2+)))
2785 (define-public dvdauthor
2792 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
2796 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
2797 (build-system gnu-build-system)
2799 (list libdvdread libpng imagemagick libxml2 freetype))
2802 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
2803 (description "@command{dvdauthor} will generate a DVD-Video movie from a
2804 MPEG-2 stream containing VOB packets.")
2805 (home-page "http://dvdauthor.sourceforge.net")
2806 (license license:gpl3+)))
2808 (define-public libdvdnav
2814 (uri (string-append "https://download.videolan.org/videolan/"
2815 "libdvdnav/" version "/"
2816 "libdvdnav-" version ".tar.bz2"))
2819 "0cv7j8irsv1n2dadlnhr6i1b8pann2ah6xpxic41f04my6ba6rp5"))))
2820 (build-system gnu-build-system)
2825 (home-page "http://dvdnav.mplayerhq.hu/")
2826 (synopsis "Library for video DVD navigation features")
2828 "Libdvdnav is a library for developers of multimedia
2829 applications. It allows easy use of sophisticated DVD navigation features
2830 such as DVD menus, multiangle playback and even interactive DVD games. All
2831 this functionality is provided through a simple API which provides the DVD
2832 playback as a single logical stream of blocks, intermitted by special
2833 dvdnav events to report certain conditions. The main usage of libdvdnav is
2834 a loop regularly calling a function to get the next block, surrounded by
2835 additional calls to tell the library of user interaction. The whole
2836 DVD virtual machine and internal playback states are completely
2838 (license license:gpl2+)))
2840 (define-public libdvdcss
2846 (uri (string-append "https://download.videolan.org/pub/"
2847 name "/" version "/"
2848 name "-" version ".tar.bz2"))
2851 "0y800y33spblb20s1lsjbaiybknmwwmmiczmjqx5s760blpwjg13"))))
2852 (build-system gnu-build-system)
2853 (home-page "https://www.videolan.org/developers/libdvdcss.html")
2854 (synopsis "Library for accessing DVDs as block devices")
2856 "libdvdcss is a simple library designed for accessing DVDs like a block
2857 device without having to bother about the decryption.")
2858 (license license:gpl2+)))
2860 (define-public srt2vtt
2867 "https://files.dthompson.us/srt2vtt/srt2vtt-"
2871 "1ravl635x81fcai4h2xnsn926i69pafgr6zkghq6319iprkw8ffv"))))
2872 (build-system gnu-build-system)
2875 (modify-phases %standard-phases
2876 (add-after 'install 'wrap-srt2vtt
2877 (lambda* (#:key outputs #:allow-other-keys)
2878 (let* ((out (assoc-ref outputs "out"))
2879 (bin (string-append out "/bin"))
2880 (version ,(let ((v (package-version guile-3.0)))
2881 (string-append (car (string-split v #\.))
2883 (site (string-append out "/share/guile/site/" version))
2884 (compiled (string-append
2885 out "/lib/guile/" version
2887 (wrap-program (string-append bin "/srt2vtt")
2888 `("GUILE_LOAD_PATH" ":" prefix (,site))
2889 `("GUILE_LOAD_COMPILED_PATH" ":" prefix (,compiled)))))))))
2894 (synopsis "SubRip to WebVTT subtitle converter")
2895 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
2896 for use with HTML5 video.")
2897 (home-page "https://dthompson.us/projects/srt2vtt.html")
2898 (license license:gpl3+)))
2900 (define-public avidemux
2907 "mirror://sourceforge/avidemux/avidemux/" version "/"
2908 "avidemux_" version ".tar.gz"))
2911 "00blv5455ry3bb86zyzk1xmq3rbqmbif62khc0kq3whza97l12k2"))
2912 (patches (search-patches "avidemux-install-to-lib.patch"))))
2913 (build-system cmake-build-system)
2916 ("pkg-config" ,pkg-config)
2917 ("python" ,python-wrapper)
2918 ("qttools" ,qttools)
2920 ;; FIXME: Once packaged, add libraries not found during the build.
2922 `(("alsa-lib" ,alsa-lib)
2923 ("fontconfig" ,fontconfig)
2924 ("freetype" ,freetype)
2925 ("fribidi" ,fribidi)
2931 ("libvdpau" ,libvdpau)
2932 ("libvorbis" ,libvorbis)
2935 ("pulseaudio" ,pulseaudio)
2936 ("qtbase" ,qtbase-5)
2940 `(#:tests? #f ; no check target
2942 ;; Make sure files inside the included ffmpeg tarball are
2944 (let ((ffmpeg "ffmpeg-4.2.4"))
2945 (modify-phases %standard-phases
2946 (add-before 'patch-source-shebangs 'unpack-ffmpeg
2948 (with-directory-excursion "avidemux_core/ffmpeg_package"
2949 (invoke "tar" "xf" (string-append ffmpeg ".tar.bz2"))
2950 (delete-file (string-append ffmpeg ".tar.bz2")))
2952 (add-after 'patch-source-shebangs 'repack-ffmpeg
2954 (with-directory-excursion "avidemux_core/ffmpeg_package"
2955 (substitute* (string-append ffmpeg "/configure")
2956 (("#! /bin/sh") (string-append "#!" (which "sh"))))
2957 (invoke "tar" "cjf" (string-append ffmpeg ".tar.bz2") ffmpeg
2958 ;; avoid non-determinism in the archive
2959 "--sort=name" "--mtime=@0"
2960 "--owner=root:0" "--group=root:0")
2961 (delete-file-recursively ffmpeg))
2965 ;; Copy-paste settings from the cmake build system.
2966 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
2967 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))
2970 (lambda* (#:key inputs outputs #:allow-other-keys)
2971 (let* ((out (assoc-ref outputs "out"))
2972 (lib (string-append out "/lib"))
2975 (lambda* (component srcdir #:optional (args '()))
2976 (let ((builddir (string-append "build_" component)))
2978 (with-directory-excursion builddir
2979 (apply invoke "cmake"
2980 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
2981 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
2982 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
2983 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
2984 "\"-Wl,-rpath=" lib "\"")
2985 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
2986 (string-append "../" srcdir)
2990 (number->string (parallel-job-count)))
2991 (invoke "make" "install"))))))
2993 (build_component "core" "avidemux_core")
2994 (build_component "cli" "avidemux/cli")
2995 (build_component "qt4" "avidemux/qt4")
2996 (build_component "plugins_common" "avidemux_plugins"
2997 '("-DPLUGIN_UI=COMMON"))
2998 (build_component "plugins_cli" "avidemux_plugins"
2999 '("-DPLUGIN_UI=CLI"))
3000 (build_component "plugins_qt4" "avidemux_plugins"
3001 '("-DPLUGIN_UI=QT4"))
3002 (build_component "plugins_settings" "avidemux_plugins"
3003 '("-DPLUGIN_UI=SETTINGS"))
3004 ;; Remove .exe and .dll file.
3005 (delete-file-recursively
3006 (string-append out "/share/ADM6_addons"))
3008 (delete 'install)))))
3009 (home-page "http://fixounet.free.fr/avidemux/")
3010 (synopsis "Video editor")
3011 (description "Avidemux is a video editor designed for simple cutting,
3012 filtering and encoding tasks. It supports many file types, including AVI,
3013 DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
3014 can be automated using projects, job queue and powerful scripting
3016 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
3017 ;; Software with various licenses is included, see License.txt.
3018 (license license:gpl2+)))
3020 (define-public vapoursynth
3022 (name "vapoursynth")
3027 (url "https://github.com/vapoursynth/vapoursynth")
3028 (commit (string-append "R" version))))
3029 (file-name (git-file-name name version))
3032 "0qcsfkpkry0cmvi60khjwvfz4fqhy23nqmn4pb9qrwll26sn9dcr"))))
3033 (build-system gnu-build-system)
3036 (modify-phases %standard-phases
3037 (add-after 'install 'wrap
3038 (lambda* (#:key outputs #:allow-other-keys)
3039 (let* ((out (assoc-ref outputs "out"))
3040 (site (string-append out "/lib/python"
3041 ,(version-major+minor
3042 (package-version python))
3044 (wrap-program (string-append out "/bin/vspipe")
3045 `("PYTHONPATH" ":" = (,site)))))))))
3047 `(("autoconf" ,autoconf)
3048 ("automake" ,automake)
3049 ("cython" ,python-cython)
3050 ("libtool" ,libtool)
3051 ("pkg-config" ,pkg-config)
3054 (list ffmpeg libass python tesseract-ocr zimg))
3055 (home-page "http://www.vapoursynth.com/")
3056 (synopsis "Video processing framework")
3057 (description "VapourSynth is a C++ library and Python module for video
3058 manipulation. It aims to be a modern rewrite of Avisynth, supporting
3059 multithreading, generalized colorspaces, per frame properties, and videos with
3061 ;; src/core/cpufeatures only allows x86, ARM or PPC
3062 (supported-systems (fold delete %supported-systems
3063 '("mips64el-linux" "aarch64-linux")))
3064 ;; As seen from the source files.
3065 (license license:lgpl2.1+)))
3074 "http://downloads.xvid.com/downloads/xvidcore-"
3075 version ".tar.bz2"))
3078 "1xyg3amgg27zf7188kss7y248s0xhh1vv8rrk0j9bcsd5nasxsmf"))))
3079 (build-system gnu-build-system)
3080 (native-inputs (list yasm))
3083 (modify-phases %standard-phases
3084 (add-before 'configure 'pre-configure
3086 (chdir "build/generic")
3087 (substitute* "configure"
3088 (("#! /bin/sh") (string-append "#!" (which "sh"))))
3090 #:tests? #f)) ; no test suite
3091 (home-page "https://www.xvid.com/")
3092 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
3093 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
3094 codec library. It uses ASP features such as b-frames, global and quarter
3095 pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
3096 and custom quantization matrices.")
3097 (license license:gpl2+)))
3099 (define-public streamlink
3106 (uri (pypi-uri "streamlink" version))
3109 "1nv2kj1k42a1b20ws8sdzlxk3wh1qz6pg5mxp75433b3c7lxksn0"))))
3110 (build-system python-build-system)
3111 (home-page "https://github.com/streamlink/streamlink")
3113 (list python-freezegun python-pytest python-mock
3114 python-requests-mock))
3116 (list python-pysocks
3117 python-websocket-client
3124 (synopsis "Extract streams from various services")
3125 (description "Streamlink is command-line utility that extracts streams
3126 from sites like Twitch.tv and pipes them into a video player of choice.")
3127 (license license:bsd-2)))
3129 (define-public twitchy
3130 (let ((commit "9beb36d80b16662414129693e74fa3a2fd97554e")) ; 3.4 has no tag
3133 (version (git-version "3.4" "1" commit))
3138 (url "https://github.com/BasioMeusPuga/twitchy")
3140 (file-name (git-file-name name version))
3143 "0di03h1j9ipp2bbnxxlxz07v87icyg2hmnsr4s7184z5ql8kpzr7"))))
3144 (build-system python-build-system)
3147 (modify-phases %standard-phases
3148 (add-after 'unpack 'patch-paths
3149 (lambda* (#:key inputs #:allow-other-keys)
3150 (substitute* "twitchy/twitchy_play.py"
3152 (string-append "\"" (assoc-ref inputs "streamlink")
3153 "/bin/streamlink ")))
3155 (add-before 'check 'check-setup
3157 (setenv "HOME" (getcwd)) ;Needs to write to ‘$HOME’.
3159 (add-after 'install 'install-rofi-plugin
3160 (lambda* (#:key outputs #:allow-other-keys)
3161 (install-file "plugins/rofi-twitchy"
3162 (string-append (assoc-ref outputs "out")
3166 (list python-requests streamlink))
3167 (home-page "https://github.com/BasioMeusPuga/twitchy")
3168 (synopsis "Command-line interface for Twitch.tv")
3170 "This package provides a command-line interface for Twitch.tv")
3171 (license license:gpl3+))))
3181 (url "https://github.com/mltframework/mlt")
3182 (commit (string-append "v" version))))
3183 (file-name (git-file-name name version))
3185 (base32 "17d4gs46ca3n0qg6z69hl6mmllnqj2id8ccrv8fyz8c5zm55ghqm"))))
3186 (build-system cmake-build-system)
3188 `(#:tests? #f ;requires "Kwalify"
3190 (modify-phases %standard-phases
3191 (add-before 'configure 'override-LDFLAGS
3192 (lambda* (#:key outputs #:allow-other-keys)
3196 (assoc-ref outputs "out") "/lib")))))))
3199 `(,alsa-plugins "pulseaudio")
3223 (home-page "https://www.mltframework.org/")
3224 (synopsis "Author, manage, and run multitrack audio/video compositions")
3226 "MLT is a multimedia framework, designed and developed for television
3227 broadcasting. It provides a toolkit for broadcasters, video editors, media
3228 players, transcoders, web streamers and many more types of applications. The
3229 functionality of the system is provided via an assortment of ready to use
3230 tools, XML authoring components, and an extensible plug-in based API.")
3231 (license license:lgpl2.1+)))
3233 (define-public mlt-6
3242 (url "https://github.com/mltframework/mlt")
3243 (commit (string-append "v" version))))
3244 (file-name (git-file-name name version))
3246 (base32 "1gz79xvs5jrzqhwhfk0dqdd3xiavnjp4q957h7nb02rij32byb39"))))
3249 (list (string-append "-DGTK2_GDKCONFIG_INCLUDE_DIR="
3250 (assoc-ref %build-inputs "gtk+")
3251 "/lib/gtk-2.0/include")
3252 (string-append "-DGTK2_GLIBCONFIG_INCLUDE_DIR="
3253 (assoc-ref %build-inputs "glib")
3254 "/lib/glib-2.0/include"))
3255 ,@(package-arguments mlt)))
3257 (modify-inputs (package-inputs mlt)
3258 (replace "gtk+" gtk+-2)))))
3260 (define-public v4l-utils
3266 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
3267 "/v4l-utils-" version ".tar.bz2"))
3270 "1xr66y6w422hil6s7n8d61a2vhwh4im8l267amf41jvw7xqihqcm"))))
3271 (build-system gnu-build-system)
3272 ;; Separate graphical tools in order to save almost 1 GiB on the closure
3273 ;; for the common case.
3274 (outputs '("out" "gui"))
3277 (list "--disable-static"
3278 (string-append "--with-udevdir="
3279 (assoc-ref %outputs "out")
3282 (modify-phases %standard-phases
3283 (add-after 'install 'split
3284 (lambda* (#:key outputs #:allow-other-keys)
3285 (let ((out (assoc-ref outputs "out"))
3286 (gui (assoc-ref outputs "gui")))
3287 (mkdir-p (string-append gui "/bin"))
3288 (mkdir-p (string-append gui "/share/man/man1"))
3289 (mkdir-p (string-append gui "/share/applications"))
3294 (rename-file (string-append out file)
3295 (string-append gui file)))
3297 (string-append "/bin/" prog)
3298 (string-append "/share/man/man1/" prog ".1")
3299 (string-append "/share/applications/" prog ".desktop"))))
3300 '("qv4l2" "qvidcap"))
3301 (copy-recursively (string-append out "/share/icons")
3302 (string-append gui "/share/icons"))
3303 (delete-file-recursively (string-append out "/share/icons"))
3304 (rmdir (string-append out "/share/applications"))
3307 (list perl pkg-config))
3309 `(("alsa-lib" ,alsa-lib)
3311 ("libjpeg" ,libjpeg-turbo)
3313 ("qtbase" ,qtbase-5)
3315 (synopsis "Realtime video capture utilities for Linux")
3316 (description "The v4l-utils provide a series of libraries and utilities to
3317 be used for realtime video capture via Linux-specific APIs.")
3318 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
3319 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
3320 (license (list license:lgpl2.1+ license:gpl2))))
3329 (url "https://github.com/obsproject/obs-studio")
3332 (file-name (git-file-name name version))
3335 "04fzsr9yizmxy0r7z2706crvnsnybpnv5kgfn77znknxxjacfhkn"))
3337 (search-patches "obs-modules-location.patch"))))
3338 (build-system cmake-build-system)
3341 (list (string-append "-DOBS_VERSION_OVERRIDE=" ,version)
3342 "-DENABLE_UNIT_TESTS=TRUE"
3343 ;; Browser plugin requires cef, but it is not packaged yet.
3344 ;; <https://bitbucket.org/chromiumembedded/cef/src/master/>
3345 "-DBUILD_BROWSER=FALSE")
3347 (modify-phases %standard-phases
3348 (add-after 'install 'wrap-executable
3349 (lambda* (#:key outputs #:allow-other-keys)
3350 (let ((out (assoc-ref outputs "out"))
3351 (plugin-path (getenv "QT_PLUGIN_PATH")))
3352 (wrap-program (string-append out "/bin/obs")
3353 `("QT_PLUGIN_PATH" ":" prefix (,plugin-path))))
3355 (native-search-paths
3356 (list (search-path-specification
3357 (variable "OBS_PLUGINS_DIRECTORY")
3358 (separator #f) ;single entry
3359 (files '("lib/obs-plugins")))
3360 (search-path-specification
3361 (variable "OBS_PLUGINS_DATA_DIRECTORY")
3362 (separator #f) ;single entry
3363 (files '("share/obs/obs-plugins")))))
3365 (list cmocka pkg-config))
3367 `(("alsa-lib" ,alsa-lib)
3371 ("fontconfig" ,fontconfig)
3372 ("freetype" ,freetype)
3375 ("jansson" ,jansson)
3376 ("libx264" ,libx264)
3377 ("libxcomposite" ,libxcomposite)
3378 ("mbedtls" ,mbedtls-apache)
3380 ("pipewire" ,pipewire-0.3)
3381 ("pulseaudio" ,pulseaudio)
3382 ("qtbase" ,qtbase-5)
3384 ("qtx11extras" ,qtx11extras)
3385 ("qtwayland" ,qtwayland)
3386 ("speexdsp" ,speexdsp)
3387 ("v4l-utils" ,v4l-utils)
3388 ("wayland" ,wayland)
3389 ("wayland-protocols" ,wayland-protocols)
3391 (synopsis "Live streaming software")
3392 (description "Open Broadcaster Software provides a graphical interface for
3393 video recording and live streaming. OBS supports capturing audio and video
3394 from many input sources such as webcams, X11 (for screencasting), PulseAudio,
3396 (home-page "https://obsproject.com")
3397 (license license:gpl2+)))
3399 (define-public obs-spectralizer
3401 (name "obs-spectralizer")
3407 (url "https://github.com/univrsal/spectralizer")
3408 (commit (string-append "v" version))))
3409 (file-name (git-file-name name version))
3411 ;; Remove bundled Windows DLLs.
3412 (snippet '(delete-file-recursively "fftw3"))
3413 (modules '((guix build utils)))
3417 "0q75cnyqydpvfda51zm9gxqj3wqr99ad0lxzjhw0ld67qvj1ag6i"))))
3418 (build-system cmake-build-system)
3422 (list "-DGLOBAL_INSTALLATION=ON" "-DUSE_CMAKE_LIBDIR=ON")))
3423 (inputs (list obs fftw))
3424 (home-page "https://github.com/univrsal/spectralizer")
3425 (synopsis "OBS plugin for audio visualization")
3426 (description "This OBS plugins allows you to vizualize MPD and internal
3427 OBS audio sources.")
3428 (license license:gpl2)))
3430 (define-public obs-websocket
3432 (name "obs-websocket")
3438 (url "https://github.com/Palakis/obs-websocket")
3441 (file-name (git-file-name name version))
3443 (base32 "1r47861ma1s3998clahbnbc216wcf706b1ps514k5p28h511l5w0"))))
3444 (build-system cmake-build-system)
3446 `(#:tests? #f ;no tests
3448 (modify-phases %standard-phases
3449 (add-after 'unpack 'remove-permission-change
3451 (substitute* "CMakeLists.txt"
3452 ;; Remove lines that set writeable permissions on outputs.
3453 (("set\\(CMAKE_INSTALL_DEFAULT_DIRECTORY_PERMISSIONS") "")
3454 (("OWNER_READ.*\\)") "")
3455 (("PERMISSIONS") ")"))
3458 (list obs qtbase-5))
3459 (home-page "https://github.com/Palakis/obs-websocket")
3460 (synopsis "OBS plugin for remote control via WebSockets")
3461 (description "This OBS plugin allows you to establish a WebSocket channel
3462 from within your running OBS instance so that you can control it remotely from
3463 programs on your current machine or on other machines.")
3464 (license license:gpl2+)))
3466 (define-public obs-wlrobs
3474 (url "https://hg.sr.ht/~scoopta/wlrobs")
3475 (changeset (string-append "v" version))))
3476 (file-name (git-file-name name version))
3479 "1faiq2gdb7qis3m1hilm4pz8lkmkab75vzm608dbiazahhybf96p"))))
3480 (build-system meson-build-system)
3483 (propagated-inputs `() )
3485 `(,libx11 "out") wayland wayland-protocols))
3486 (home-page "https://hg.sr.ht/~scoopta/wlrobs")
3487 (synopsis "OBS plugin for Wayland (wlroots) screen capture")
3489 "This OBS plugin allows you to capture the screen on wlroots-based
3490 Wayland compositors.")
3491 (license license:gpl3+)))
3493 (define-public libvdpau
3501 (url "https://gitlab.freedesktop.org/vdpau/libvdpau.git")
3503 (file-name (git-file-name name version))
3506 "1hc4mcrbr1yhfiy4zfd8wc2iiqbp90z6jswap0jia20vmyk5lqld"))))
3507 (build-system meson-build-system)
3511 (list `(,libx11 "out") libxext xorgproto))
3512 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
3513 (synopsis "Video Decode and Presentation API")
3514 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
3515 provides an interface to video decode acceleration and presentation hardware
3516 present in modern GPUs.")
3517 (license (license:x11-style "file://COPYING"))))
3519 (define-public vdpauinfo
3527 (url "https://gitlab.freedesktop.org/vdpau/vdpauinfo")
3529 (file-name (git-file-name name version))
3531 (base32 "0s84bavxr39w0r7zfaac7kpbfsg88hgymqyzcr0yvbj1yry3liz2"))))
3532 (build-system gnu-build-system)
3535 (modify-phases %standard-phases
3537 ;; ./autogen.sh runs ./configure too soon.
3539 (invoke "autoreconf" "-fiv"))))))
3541 (list autoconf automake libx11 pkg-config))
3544 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
3545 (synopsis "Tool to query the capabilities of a VDPAU implementation")
3546 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
3548 (license (license:x11-style "file://COPYING"))))
3550 (define-public libvdpau-va-gl
3552 (name "libvdpau-va-gl")
3557 (uri (string-append "https://github.com/i-rinat/libvdpau-va-gl/"
3558 "releases/download/v" version "/libvdpau-va-gl-"
3562 "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
3563 (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
3564 (modules '((guix build utils)))
3565 (snippet '(begin (delete-file-recursively "3rdparty")
3567 (build-system cmake-build-system)
3569 '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
3571 (list libvdpau pkg-config))
3574 (home-page "https://github.com/i-rinat/libvdpau-va-gl")
3575 (synopsis "VDPAU driver with VA-API/OpenGL backend")
3577 "Many applications can use VDPAU to accelerate portions of the video
3578 decoding process and video post-processing to the GPU video hardware. Since
3579 there is no VDPAU available on Intel chips, they fall back to different drawing
3580 techniques. This driver uses OpenGL under the hood to accelerate drawing and
3581 scaling and VA-API (if available) to accelerate video decoding.")
3582 (license license:expat)))
3584 (define-public recordmydesktop
3586 (name "recordmydesktop")
3590 (uri (string-append "https://github.com/Enselic/"
3591 name "/releases/download/v" version
3592 "/recordmydesktop-" version ".tar.gz"))
3595 "17kjgmkl45zma64a5dg1hyvnjkzk4vl8milgi6ic7hlsbmywpig7"))))
3596 (build-system gnu-build-system)
3608 (home-page "https://enselic.github.io/recordmydesktop/")
3609 (synopsis "Desktop session video recorder")
3611 "recordMyDesktop is a command-line tool that captures the activity in
3612 your graphical desktop and encodes it as a video. This is a useful tool for
3613 making @dfn{screencasts}.")
3614 (license license:gpl2+)))
3616 (define-public simplescreenrecorder
3618 (name "simplescreenrecorder")
3624 (url "https://github.com/MaartenBaert/ssr")
3626 (file-name (git-file-name name version))
3629 "1dzp5yzqlha65crzklx2qlan6ssw1diwzfpc4svd7gnr858q2292"))))
3630 (build-system cmake-build-system)
3631 ;; Although libx11, libxfixes, libxext are listed as build dependencies in
3632 ;; README.md, the program builds and functions properly without them.
3633 ;; As a result, they are omitted. Please add them back if problems appear.
3644 (native-inputs (list pkg-config))
3647 (list "-DWITH_QT5=TRUE")
3648 #:tests? #f)) ; no test suite
3649 ;; Using HTTPS causes part of the page to be displayed improperly.
3650 (home-page "https://www.maartenbaert.be/simplescreenrecorder/")
3651 (synopsis "Screen recorder")
3652 (description "SimpleScreenRecorder is an easy to use screen recorder with
3653 a graphical user interface. It supports recording the entire screen, or a
3654 part of it, and allows encoding in many different codecs and file formats.
3655 Other features include a live preview and live streaming.")
3656 (license (list license:gpl3+ ; most files
3657 license:zlib ; glinject/elfhacks.*
3658 license:isc ; glinject/*
3659 license:x11)))) ; build-aux/install-sh
3661 (define-public libsmpeg
3664 (version "0.4.5-401")
3668 (url "svn://svn.icculus.org/smpeg/trunk/")
3669 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
3670 (file-name (string-append name "-" version "-checkout"))
3673 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
3674 (build-system gnu-build-system)
3676 ;; libsmpeg fails to build with -std=c++11, which is the default with
3677 ;; GCC 7. Also, 'configure' does CXXFLAGS=$CFLAGS, hence this hack.
3678 '(#:configure-flags '("CFLAGS=-O2 -g -std=c++03")))
3680 (list autoconf automake))
3683 (home-page "https://icculus.org/smpeg/")
3684 (synopsis "SDL MPEG decoding library")
3686 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
3687 with sound support. Video playback is based on the ubiquitous Berkeley MPEG
3688 player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
3689 library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
3690 and MPEG system streams.")
3691 (license (list license:expat
3697 (define-public libsmpeg-with-sdl1
3698 (package (inherit libsmpeg)
3700 (version "0.4.5-399")
3704 (url "svn://svn.icculus.org/smpeg/trunk/")
3705 (revision 399))) ; tagged release 0.4.5
3706 (file-name (string-append name "-" version "-checkout"))
3709 "0jfi085rf3fa5xsn0vd3nqf32my8ph9c6a9445y7a8lrlz4dms64"))))
3713 (define-public libbdplus
3720 (uri (string-append "https://ftp.videolan.org/pub/videolan/libbdplus/"
3721 version "/" name "-" version ".tar.bz2"))
3723 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
3726 (build-system gnu-build-system)
3727 (home-page "https://www.videolan.org/developers/libbdplus.html")
3728 (synopsis "Library for decrypting certain Blu-Ray discs")
3729 (description "libbdplus is a library which implements the BD+ System
3731 (license license:lgpl2.1+)))
3733 (define-public libaacs
3740 (uri (string-append "https://ftp.videolan.org/pub/videolan/libaacs/"
3741 version "/libaacs-" version ".tar.bz2"))
3743 (base32 "11skjqjlldmbjkyxdcz4fmcn6y4p95r1xagbcnjy4ndnzf0l723d"))))
3748 (build-system gnu-build-system)
3749 (home-page "https://www.videolan.org/developers/libaacs.html")
3750 (synopsis "Library for decrypting certain Blu-Ray discs")
3751 (description "libaacs is a library which implements the Advanced Access
3752 Content System specification.")
3753 (license license:lgpl2.1+)))
3755 (define-public mps-youtube
3757 (name "mps-youtube")
3763 (url "https://github.com/mps-youtube/mps-youtube")
3764 (commit (string-append "v" version))))
3765 (file-name (git-file-name name version))
3768 "1w1jhw9rg3dx7vp97cwrk5fymipkcy2wrbl1jaa38ivcjhqg596y"))))
3769 (build-system python-build-system)
3771 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
3772 ;; test suite results differ depending on the country and also introduce
3773 ;; non-determinism in the tests.
3774 ;; https://github.com/mps-youtube/mps-youtube/issues/556
3776 #:phases (modify-phases %standard-phases
3777 ;; Loading this as a library will create cache directories,
3778 ;; etc; which fails in the build container.
3779 (delete 'sanity-check))))
3781 (list python-pafy python-pygobject)) ; For mpris2 support
3782 (home-page "https://github.com/mps-youtube/mps-youtube")
3783 (synopsis "Terminal based YouTube player and downloader")
3785 "@code{mps-youtube} is based on mps, a terminal based program to
3786 search, stream and download music. This implementation uses YouTube as
3787 a source of content and can play and download video as well as audio.
3788 It can use either mpv or mplayer for playback, and for conversion of
3789 formats ffmpeg or libav is used. Users should install one of the
3790 supported players in addition to this package.")
3791 (license license:gpl3+)))
3793 (define-public handbrake
3799 (uri (string-append "https://github.com/HandBrake/HandBrake/"
3800 "releases/download/" version "/"
3801 "HandBrake-" version "-source.tar.bz2"))
3804 "1w1hjj6gvdydypw4mdn281w0x163is59cfm7k6bq371hsl3gx69r"))
3805 (modules '((guix build utils)))
3807 ;; Remove "contrib" and source not necessary for
3808 ;; building/running under a GNU environment.
3810 (for-each delete-file-recursively
3811 '("contrib" "macosx" "win")) ; 540KiB, 11MiB, 5.9MiB resp.
3812 (substitute* "make/include/main.defs"
3813 ;; Disable unconditional inclusion of "contrib" libraries
3814 ;; (ffmpeg, libvpx, libdvdread, libdvdnav, and libbluray),
3815 ;; which would lead to fetching and building of these
3816 ;; libraries. Use our own instead.
3817 (("MODULES \\+= contrib") "# MODULES += contrib"))))))
3818 (build-system glib-or-gtk-build-system)
3820 `(("automake" ,automake) ; GUI subpackage must be bootstrapped
3821 ("autoconf" ,autoconf)
3822 ("intltool" ,intltool)
3823 ("libtool" ,libtool)
3824 ("pkg-config" ,pkg-config)
3825 ("python" ,python-2))) ; For configuration
3828 ("dbus-glib" ,dbus-glib)
3830 ("fontconfig" ,fontconfig)
3831 ("freetype" ,freetype)
3833 ("gstreamer" ,gstreamer)
3834 ("gst-plugins-base" ,gst-plugins-base)
3836 ("jansson" ,jansson)
3839 ("libbluray" ,libbluray)
3841 ("libdvdnav" ,libdvdnav)
3842 ("libdvdread" ,libdvdread)
3843 ("libgudev" ,libgudev)
3844 ("libjpeg-turbo" ,libjpeg-turbo)
3845 ("libmpeg2" ,libmpeg2)
3846 ("libnotify" ,libnotify)
3847 ("libnuma" ,numactl)
3850 ("libsamplerate" ,libsamplerate)
3851 ("libtheora" ,libtheora)
3852 ("libvorbis" ,libvorbis)
3854 ("libxml2" ,libxml2)
3855 ("libx264" ,libx264)
3861 `(#:tests? #f ;tests require Ruby and claim to be unsupported
3863 (list "--disable-gtk-update-checks"
3865 (string-append "CPPFLAGS=-I"
3866 (assoc-ref %build-inputs "libxml2")
3870 (modify-phases %standard-phases
3872 ;; Run bootstrap ahead of time so that shebangs get patched.
3874 (setenv "CONFIG_SHELL" (which "sh"))
3875 ;; Patch the Makefile so that it doesn't bootstrap again.
3876 (substitute* "gtk/module.rules"
3877 ((".*autoreconf.*") ""))
3878 (with-directory-excursion "gtk"
3879 (invoke "autoreconf" "-fiv"))))
3880 (add-before 'configure 'patch-SHELL
3882 (substitute* "gtk/po/Makefile.in.in"
3883 (("SHELL = /bin/sh") "SHELL = @SHELL@"))))
3884 (add-before 'configure 'relax-reqs
3886 (substitute* "make/configure.py"
3887 ;; cmake is checked for so that it can be used to build
3888 ;; contrib/harfbuzz and contrib/x265, but we get these as
3889 ;; inputs, so don't abort if it's not found. Similarly, meson
3890 ;; and ninja are only needed for contrib/libdav1d, and nasm
3892 (("((cmake|meson|ninja|nasm) *=.*abort=)True" _ &)
3893 (string-append & "False")))))
3895 (lambda* (#:key outputs configure-flags #:allow-other-keys)
3896 ;; 'configure' is not an autoconf-generated script, and
3897 ;; errors on unrecognized arguments,
3898 ;; e.g. --enable-fast-install
3899 (let ((out (assoc-ref outputs "out")))
3900 (apply invoke "./configure"
3901 (string-append "--prefix=" out)
3902 (or configure-flags '())))))
3903 (add-after 'configure 'chdir-build
3904 (lambda _ (chdir "./build"))))))
3905 (home-page "https://handbrake.fr")
3906 (synopsis "Video transcoder")
3908 "HandBrake is a tool for converting video from any format to a selection
3909 of modern, widely supported codecs.")
3910 ;; Some under GPLv2+, some under LGPLv2.1+, and portions under BSD3.
3911 ;; Combination under GPLv2. See LICENSE.
3912 (license license:gpl2)))
3914 (define-public intel-vaapi-driver
3916 (name "intel-vaapi-driver")
3922 (url "https://github.com/intel/intel-vaapi-driver")
3925 (base32 "1cidki3av9wnkgwi7fklxbg3bh6kysf8w3fk2qadjr05a92mx3zp"))
3926 (file-name (git-file-name name version))))
3927 (build-system gnu-build-system)
3929 (list autoconf automake libtool pkg-config))
3931 (list libdrm libva libx11))
3934 (modify-phases %standard-phases
3935 (add-before 'configure 'set-target-directory
3936 (lambda* (#:key outputs #:allow-other-keys)
3937 (let ((out (assoc-ref outputs "out")))
3938 (setenv "LIBVA_DRIVERS_PATH" (string-append out "/lib/dri"))
3940 ;; XXX Because of <https://issues.guix.gnu.org/issue/22138>, we need to add
3941 ;; this to all VA-API back ends instead of once to libva.
3942 (native-search-paths
3943 (list (search-path-specification
3944 (variable "LIBVA_DRIVERS_PATH")
3945 (files '("lib/dri")))))
3946 (supported-systems '("i686-linux" "x86_64-linux"))
3947 (home-page "https://01.org/linuxmedia/vaapi")
3948 (synopsis "VA-API video acceleration driver for Intel GEN Graphics devices")
3950 "This is the @acronym{VA-API, Video Acceleration API} back end required for
3951 hardware-accelerated video processing on Intel GEN Graphics devices supported by
3952 the i915 driver, such as integrated Intel HD Graphics. It provides access to
3953 both hardware and shader functionality for faster encoding, decoding, and
3954 post-processing of video formats like MPEG2, H.264/AVC, and VC-1.")
3955 (license (list license:bsd-2 ; src/gen9_vp9_const_def.c
3956 license:expat)))) ; the rest, excluding the test suite
3958 (define-public openh264
3965 (url "https://github.com/cisco/openh264")
3966 (commit (string-append "v" version))))
3967 (file-name (git-file-name name version))
3970 "0ffav46pz3sbj92nipd62z03fibyqgclfq9w8lgr80s6za6zdk5s"))))
3971 (build-system gnu-build-system)
3975 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
3977 #:test-target "test"
3978 #:phases (modify-phases %standard-phases
3979 ;; no configure script
3980 (delete 'configure))))
3981 (home-page "https://www.openh264.org/")
3982 (synopsis "H264 decoder library")
3984 "Openh264 is a library which can decode H264 video streams.")
3985 (license license:bsd-2)))
3987 (define-public libmp4v2
3994 ;; XXX: The new location of upstream is uncertain and will become relevant the
3995 ;; moment when the googlecode archive shuts down. It is past the date it
3996 ;; should've been turned off. I tried to communicate with upstream, but this
3997 ;; wasn't very responsive and not very helpful. The short summary is, it is
3998 ;; chaos when it comes to the amount of forks and only time will tell where
3999 ;; the new upstream location is.
4000 (uri (string-append "https://storage.googleapis.com/google-"
4001 "code-archive-downloads/v2/"
4002 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
4003 (file-name (string-append name "-" version ".tar.bz2"))
4004 (patches (search-patches "libmp4v2-c++11.patch"))
4007 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
4008 (build-system gnu-build-system)
4010 "static")) ; 3.7MiB .a file
4012 `(;; Build as C++2003 to avoid C++11 "narrowing conversion" errors.
4013 #:configure-flags '("CXXFLAGS=-O2 -g -std=c++03")
4016 (modify-phases %standard-phases
4017 (add-after 'unpack 'remove-dates
4019 ;; Make the build reproducible.
4020 (substitute* "configure"
4021 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
4022 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
4024 (add-after 'install 'move-static-libraries
4025 (lambda* (#:key outputs #:allow-other-keys)
4026 ;; Move static libraries to the "static" output.
4027 (let* ((out (assoc-ref outputs "out"))
4028 (lib (string-append out "/lib"))
4029 (static (assoc-ref outputs "static"))
4030 (slib (string-append static "/lib")))
4032 (for-each (lambda (file)
4033 (install-file file slib)
4035 (find-files lib "\\.a$"))
4038 (list help2man dejagnu))
4039 (home-page "https://code.google.com/archive/p/mp4v2/")
4040 (synopsis "API to create and modify mp4 files")
4042 "The MP4v2 library provides an API to create and modify mp4 files as defined by
4043 ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
4044 file format that has been used as a multimedia file format in a variety of platforms and
4045 applications. It is a very powerful and extensible format that can accommodate
4046 practically any type of media.")
4047 (license license:mpl1.1)))
4049 (define-public libmediainfo
4051 (name "libmediainfo")
4055 (uri (string-append "https://mediaarea.net/download/source/"
4056 name "/" version "/"
4057 name "_" version ".tar.xz"))
4060 "1jm4mk539wf3crgpcddgwdixshwdzm37mkb5441lifhcz2mykdsn"))))
4061 ;; TODO add a Big Buck Bunny webm for tests.
4063 (list autoconf automake libtool pkg-config))
4065 (list zlib tinyxml2 curl ; In Requires.private of libmediainfo.pc.
4067 (build-system gnu-build-system)
4069 '(#:tests? #f ; see above TODO
4071 (list "--with-libcurl" "--with-libtinyxml2")
4073 ;; build scripts not in root of archive
4074 (modify-phases %standard-phases
4075 (add-after 'unpack 'change-to-build-dir
4077 (chdir "Project/GNU/Library")
4079 (home-page "https://mediaarea.net/en/MediaInfo")
4080 (synopsis "Library for retrieving media metadata")
4081 (description "MediaInfo is a library used for retrieving technical
4082 information and other metadata about audio or video files. A non-exhaustive
4083 list of the information MediaInfo can retrieve from media files include:
4086 @item General: title, author, director, album, track number, date, duration...
4087 @item Video: codec, aspect, fps, bitrate...
4088 @item Audio: codec, sample rate, channels, language, bitrate...
4089 @item Text: language of subtitle
4090 @item Chapters: number of chapters, list of chapters
4093 MediaInfo supports the following formats:
4096 @item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
4097 MPEG-2, MPEG-4, DVD (VOB)...
4098 @item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
4099 @item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
4100 @item Subtitles: SRT, SSA, ASS, SAMI...
4102 (license license:bsd-2)))
4104 ;; TODO also have a GUI version available
4105 (define-public mediainfo
4111 ;; Warning: This source has proved unreliable 1 time at least.
4112 ;; Consider an alternate source or report upstream if this
4114 (uri (string-append "https://mediaarea.net/download/source/"
4115 name "/" version "/"
4116 name "_" version ".tar.xz"))
4119 "07h2a1lbw5ak6c9bcn8qydchl0wpgk945rf9sfcqjyv05h5wll6y"))))
4121 (list autoconf automake libtool pkg-config))
4123 (list libmediainfo))
4124 (build-system gnu-build-system)
4126 '(#:tests? #f ; lacks tests
4128 ;; build scripts not in root of archive
4129 (modify-phases %standard-phases
4130 (add-after 'unpack 'change-to-build-dir
4132 (chdir "Project/GNU/CLI")
4134 (home-page "https://mediaarea.net/en/MediaInfo")
4135 (synopsis "Utility for reading media metadata")
4136 (description "MediaInfo is a utility used for retrieving technical
4137 information and other metadata about audio or video files. It supports the
4138 many codecs and formats supported by libmediainfo.")
4139 (license license:bsd-2)))
4141 (define-public atomicparsley
4143 (name "atomicparsley")
4144 (version "20200701.154658.b0d6223")
4148 (url "https://github.com/wez/atomicparsley")
4150 (file-name (git-file-name name version))
4153 "1kym2l5y34nmbrrlkfmxsf1cwrvch64kb34jp0hpa0b89idbhwqh"))))
4154 (build-system cmake-build-system)
4156 `(#:tests? #f ;; no tests included
4158 (modify-phases %standard-phases
4159 (add-before 'configure 'set-cmake-version
4161 (substitute* "CMakeLists.txt"
4162 ;; At the time of writing, Guix has CMake at 3.16, but
4163 ;; AtomicParsley uses 3.17. This brings the required CMake
4164 ;; version down to what Guix can afford.
4165 (("VERSION 3.17") "VERSION 3.16"))
4168 (lambda* (#:key outputs #:allow-other-keys)
4169 (let* ((out (assoc-ref outputs "out"))
4170 (bin (string-append out "/bin")))
4171 (install-file "AtomicParsley" bin))
4175 (synopsis "Metadata editor for MPEG-4 files")
4176 (description "AtomicParsley is a lightweight command line program for
4177 reading, parsing and setting metadata into MPEG-4 files, in particular,
4178 iTunes-style metadata.")
4179 (home-page "https://github.com/wez/atomicparsley")
4180 (license license:gpl2+)))
4182 (define-public livemedia-utils
4184 (name "livemedia-utils")
4185 (version "2020.11.19")
4189 "https://download.videolan.org/contrib/live555/live."
4193 "16w6yxdbmjdhvffnrb752dn4llf3l0wb00dgdkyia0vqsv2qqyn7"))))
4194 (build-system gnu-build-system)
4196 `(#:tests? #f ; no tests
4197 #:make-flags (list (string-append "CC=" ,(cc-for-target))
4198 (string-append "CXX=" ,(cxx-for-target))
4199 (string-append "LDFLAGS=-Wl,-rpath="
4200 (assoc-ref %outputs "out") "/lib")
4201 (string-append "PREFIX="
4202 (assoc-ref %outputs "out")))
4203 #:phases (modify-phases %standard-phases
4204 (add-before 'configure 'fix-makefiles-generation
4206 (substitute* "genMakefiles"
4211 (invoke "./genMakefiles"
4212 "linux-with-shared-libraries"))))))
4215 (home-page "http://www.live555.com/liveMedia/")
4216 (synopsis "Set of C++ libraries for multimedia streaming")
4217 (description "This code forms a set of C++ libraries for multimedia
4218 streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
4219 can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
4220 JPEG video, and several audio codecs. They can easily be extended to support
4221 additional (audio and/or video) codecs, and can also be used to build basic
4222 RTSP or SIP clients and servers.")
4223 (license license:lgpl3+)))
4225 (define-public libdvbpsi
4232 "https://download.videolan.org/pub/libdvbpsi/"
4233 version "/libdvbpsi-" version ".tar.bz2"))
4236 "04h1l3vrkrdsrvkgzcr51adk10g6hxcxvgjphyyxz718ry5rkd82"))))
4237 (build-system gnu-build-system)
4238 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
4239 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
4241 (description "libdvbpsi is a simple library designed for decoding and
4242 generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
4243 and ITU-T H.222.0.")
4244 (license license:lgpl2.1)))
4246 (define-public ffms2
4250 (home-page "https://github.com/FFMS/ffms2")
4254 (url "https://github.com/FFMS/ffms2")
4256 (file-name (git-file-name name version))
4259 "0dkz5b3gxq5p4xz0qqg6l2sigszrlsinz3skyf0ln4wf3zrvf8m5"))))
4260 (build-system gnu-build-system)
4263 (list "--enable-avresample")))
4270 (synopsis "Cross-platform wrapper around ffmpeg/libav")
4272 "FFMpegSource is a wrapper library around ffmpeg/libav that allows
4273 programmers to access a standard API to open and decompress media files.")
4274 ;; sources are distributed under a different license that the binary.
4275 ;; see https://github.com/FFMS/ffms2/blob/master/COPYING
4276 (license license:gpl2+))); inherits from ffmpeg
4278 (define-public aegisub
4285 "http://ftp.aegisub.org/pub/archives/releases/source/"
4286 name "-" version ".tar.xz"))
4289 "11b83qazc8h0iidyj1rprnnjdivj1lpphvpa08y53n42bfa36pn5"))
4290 (patches (search-patches "aegisub-icu59-include-unistr.patch"
4291 "aegisub-make43.patch"
4292 "aegisub-boost68.patch"))))
4293 (build-system gnu-build-system)
4296 (list "--disable-update-checker"
4297 "--without-portaudio"
4300 "CXXFLAGS=-DU_USING_ICU_NAMESPACE=1")
4301 ;; tests require busted, a lua package we don't have yet
4304 (modify-phases %standard-phases
4305 (add-before 'configure 'fix-ldflags
4307 (setenv "LDFLAGS" "-pthread")
4309 (add-after 'unpack 'fix-boost-headers
4312 '("src/subtitles_provider_libass.cpp"
4313 "src/colour_button.cpp"
4314 "src/video_provider_dummy.cpp"
4315 "./src/video_frame.cpp")
4316 (("#include <boost/gil/gil_all.hpp>")
4317 "#include <boost/gil.hpp>"))
4332 (list intltool desktop-file-utils pkg-config))
4333 (home-page "http://www.aegisub.org/")
4334 (synopsis "Subtitle engine")
4336 "Aegisub is a tool for creating and modifying subtitles. Aegisub makes
4337 it quick and easy to time subtitles to audio, and features many powerful
4338 tools for styling them, including a built-in real-time video preview.")
4339 (license (list license:bsd-3 ; the package is licensed under the bsd-3, except
4340 license:mpl1.1 ; for vendor/universalchardet under the mpl1.1
4341 license:expat)))) ; and src/gl that is under a license similar
4342 ; the the Expat license, with a rewording (Software -> Materials). (called MIT
4343 ; by upstream). See https://github.com/Aegisub/Aegisub/blob/master/LICENCE
4344 ; src/MatroskaParser.(c|h) is under bsd-3 with permission from the author
4346 (define-public pitivi
4347 ;; Pitivi switched to a non-semantic versioning scheme close before 1.0
4348 (let ((latest-semver "0.999.0")
4349 (%version "2021.05.0"))
4352 (version (string-append latest-semver "-" %version))
4357 (url "https://gitlab.gnome.org/GNOME/pitivi.git")
4359 (file-name (git-file-name name version))
4360 (patches (search-patches "pitivi-fix-build-with-meson-0.60.patch"))
4362 (base32 "08x2fs2bak1fbmkvjijgx1dsawispv91bpv5j5gkqbv5dfgf7wah"))))
4363 (build-system meson-build-system)
4366 gst-editing-services
4370 (gst-plugins/selection gst-plugins-bad #:plugins
4371 '("debugutils" "transcode")
4373 '("-Dintrospection=enabled"))
4388 `(("gettext" ,gettext-minimal)
4389 ("glib:bin" ,glib "bin")
4390 ("itstool" ,itstool)
4391 ("pkg-config" ,pkg-config)))
4395 (modify-phases %standard-phases
4396 (add-after 'glib-or-gtk-wrap 'wrap-other-dependencies
4397 (lambda* (#:key outputs #:allow-other-keys)
4398 (let ((prog (string-append (assoc-ref outputs "out")
4401 `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH")))
4402 `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))
4403 ;; We've only added inputs for what Pitivi deems either
4404 ;; necessary or optional. Let the user's packages take
4405 ;; precedence in case they have e.g. the full gst-plugins-bad.
4406 `("GST_PLUGIN_SYSTEM_PATH" suffix
4407 (,(getenv "GST_PLUGIN_SYSTEM_PATH"))))))))))
4408 (home-page "http://www.pitivi.org")
4409 (synopsis "Video editor based on GStreamer Editing Services")
4410 (description "Pitivi is a video editor built upon the GStreamer Editing
4411 Services. It aims to be an intuitive and flexible application that can appeal
4412 to newbies and professionals alike.")
4413 (license license:lgpl2.1+))))
4422 (uri (string-append "mirror://sourceforge/gmerlin/"
4423 name "/" version "/"
4424 name "-" version ".tar.gz"))
4425 (file-name (string-append name "-" version ".tar.gz"))
4428 "1kikkn971a14zzm7svi7190ldc14fjai0xyhpbcmp48s750sraji"))))
4429 (build-system gnu-build-system)
4431 '(#:configure-flags '("LIBS=-lm")))
4433 (list pkg-config doxygen))
4434 (home-page "http://gmerlin.sourceforge.net")
4435 (synopsis "Low level library for multimedia API building")
4437 "Gavl is short for Gmerlin Audio Video Library. It is a low level
4438 library, upon which multimedia APIs can be built. Gavl handles all the
4439 details of audio and video formats like colorspaces, sample rates,
4440 multichannel configurations, etc. It provides standardized definitions for
4441 those formats as well as container structures for carrying audio samples or
4442 video images inside an application.
4444 In addition, it handles the sometimes ugly task of converting between all
4445 these formats and provides some elementary operations (copying, scaling,
4446 alpha blending etc).")
4447 (license license:gpl3)))
4449 (define-public frei0r-plugins
4451 (name "frei0r-plugins")
4456 (uri (string-append "https://files.dyne.org/frei0r/"
4457 "frei0r-plugins-" version ".tar.gz"))
4460 "0fjji3060r4fwr7vn91lwfzl80lg3my9lkp94kbyw8xwz7qgh7qv"))))
4461 (build-system gnu-build-system)
4464 (modify-phases %standard-phases
4465 (add-after 'unpack 'patch-Makefile
4467 ;; XXX: The 1.7.0 Makefile looks for files that have slightly different
4468 ;; names in the tarball. Try removing this for future versions.
4469 (substitute* "Makefile.in"
4470 (("README\\.md ChangeLog TODO AUTHORS")
4471 "README.txt ChangeLog.txt TODO.txt AUTHORS.txt"))
4473 ;; TODO: opencv for additional face detection filters.
4478 (home-page "https://www.dyne.org/software/frei0r/")
4479 (synopsis "Minimalistic plugin API for video effects")
4481 "Frei0r is a minimalistic plugin API for video effects.
4482 The main emphasis is on simplicity for an API that will round up
4483 the most common video effects into simple filters, sources and
4484 mixers that can be controlled by parameters. Frei0r wants to
4485 provide a way to share these simple effects between many
4486 applications, avoiding their reimplementation by different projects.
4487 It counts more than 100 plugins.")
4488 (license (list license:gpl2+
4489 ;; The following files are licensed as LGPL2.1+:
4490 ;; src/generator/ising0r/ising0r.c
4491 ;; src/generator/onecol0r/onecol0r.cpp
4492 ;; src/generator/nois0r/nois0r.cpp
4493 ;; src/generator/lissajous0r/lissajous0r.cpp
4494 ;; src/filter/ndvi/gradientlut.hpp
4495 ;; src/filter/ndvi/ndvi.cpp
4496 ;; src/filter/facedetect/facedetect.cpp
4497 license:lgpl2.1+))))
4499 (define-public motion
4503 (home-page "https://motion-project.github.io/")
4507 (url "https://github.com/Motion-Project/motion")
4508 (commit (string-append "release-" version))))
4511 "09xs815jsivcilpmnrx2jkcxirj4lg5kp99fkr0p2sdxw03myi95"))
4512 (file-name (git-file-name name version))))
4513 (build-system gnu-build-system)
4515 `(("autoconf" ,autoconf)
4516 ("automake" ,automake)
4517 ("gettext" ,gettext-minimal)
4518 ("pkg-config" ,pkg-config)))
4520 `(("libjpeg" ,libjpeg-turbo)
4522 ("libmicrohttpd" ,libmicrohttpd)
4523 ("sqlite" ,sqlite)))
4525 '(#:phases (modify-phases %standard-phases
4528 (patch-shebang "scripts/version.sh")
4529 (invoke "autoreconf" "-vfi"))))
4530 #:configure-flags '("--sysconfdir=/etc")
4531 #:make-flags (list (string-append "sysconfdir="
4532 (assoc-ref %outputs "out")
4535 #:tests? #f)) ; no 'check' target
4536 (synopsis "Detect motion from video signals")
4538 "Motion is a program that monitors the video signal from one or more
4539 cameras and is able to detect if a significant part of the picture has
4540 changed. Or in other words, it can detect motion.")
4542 ;; Some files say "version 2" and others "version 2 or later".
4543 (license license:gpl2)))
4545 (define-public subdl
4546 (let ((commit "4cf5789b11f0ff3f863b704b336190bf968cd471")
4550 (version (git-version "1.0.3" revision commit))
4554 (url "https://github.com/alexanderwink/subdl")
4556 (file-name (git-file-name name version))
4559 "0kmk5ck1j49q4ww0lvas2767kwnzhkq0vdwkmjypdx5zkxz73fn8"))))
4560 (build-system trivial-build-system)
4562 `(#:modules ((guix build utils))
4564 (use-modules (guix build utils))
4565 (let* ((out (assoc-ref %outputs "out"))
4566 (bin (string-append out "/bin"))
4567 (source (assoc-ref %build-inputs "source"))
4568 (python (assoc-ref %build-inputs "python")))
4569 (install-file (string-append source "/subdl") bin)
4570 (patch-shebang (string-append bin "/subdl")
4571 (list (string-append python "/bin")))))))
4572 (inputs (list python))
4573 (synopsis "Command-line tool for downloading subtitles from opensubtitles.org")
4574 (description "Subdl is a command-line tool for downloading subtitles from
4575 opensubtitles.org. By default, it will search for English subtitles, display
4576 the results, download the highest-rated result in the requested language and
4577 save it to the appropriate filename.")
4578 (license license:gpl3+)
4579 (home-page "https://github.com/alexanderwink/subdl"))))
4581 (define-public l-smash
4588 (url "https://github.com/l-smash/l-smash")
4589 (commit (string-append "v" version))))
4590 (file-name (git-file-name name version))
4593 "0rcq9727im6kd8da8b7kzzbzxdldvmh5nsljj9pvr4m3lj484b02"))))
4594 (build-system gnu-build-system)
4596 `(#:tests? #f ;no tests
4598 (list (string-append "LDFLAGS=-Wl,-L.,-rpath="
4599 (assoc-ref %outputs "out") "/lib"))
4601 (modify-phases %standard-phases
4602 ;; configure fails if it is followed by CONFIG_SHELL
4604 (lambda* (#:key outputs #:allow-other-keys)
4605 (let ((out (assoc-ref outputs "out")))
4606 (invoke "./configure" (string-append "--prefix=" out)
4607 "--disable-static")))))))
4610 (home-page "https://l-smash.github.io/l-smash/")
4611 (synopsis "MP4 multiplexer and demultiplexer library")
4613 "L-SMASH is a cross-platform library that handles the ISO base media file
4614 format and some of its derived file formats, including MP4. It operates as a
4615 multiplexer and demultiplexer, and can mux video and audio in several formats
4616 using standalone executable files.")
4617 (license license:isc)))
4619 (define-public qtfaststart
4621 (name "qtfaststart")
4625 (uri (pypi-uri "qtfaststart" version))
4628 "0hcjfik8hhb1syqvyh5c6aillpvzal26nkjflcq1270z64aj6i5h"))))
4629 (build-system python-build-system)
4631 '(#:tests? #f)) ; no test suite
4632 (synopsis "Move QuickTime and MP4 metadata to the beginning of the file")
4633 (description "qtfaststart enables streaming and pseudo-streaming of
4634 QuickTime and MP4 files by moving metadata and offset information to the
4635 beginning of the file. It can also print some useful information about the
4636 structure of the file. This program is based on qt-faststart.c from the FFmpeg
4637 project, which is released into the public domain, as well as ISO 14496-12:2005
4638 (the official spec for MP4), which can be obtained from the ISO or found
4640 (home-page "https://github.com/danielgtaylor/qtfaststart")
4641 (license license:expat)))
4643 (define-public vidstab
4644 (let ((commit "aeabc8daa7904f9edf7441a11f293965a5ef53b8")
4648 (version (git-version "1.1.0" revision commit))
4652 (url "https://github.com/georgmartius/vid.stab")
4654 (file-name (git-file-name name version))
4657 "042iy0f3khwzr68djzvqgn301sy21ljvkf52rnc2c73q7ircnzzn"))))
4658 (build-system cmake-build-system)
4660 '(#:tests? #f)) ; tests are not run as part of standard build process
4661 (home-page "http://public.hronopik.de/vid.stab/")
4662 (synopsis "Video stabilization library")
4663 (description "Vidstab is a video stabilization library which can be used
4664 with FFmpeg. A video acquired using a hand-held camera or a camera mounted on a
4665 vehicle typically suffers from undesirable shakes and jitters. Activities such
4666 as surfing, skiing, riding and walking while shooting videos are especially
4667 prone to erratic camera shakes. Vidstab targets these video contents to help
4668 create smoother and stable videos.")
4669 (license license:gpl2+))))
4671 (define-public libopenshot
4673 (name "libopenshot")
4678 (url "https://github.com/OpenShot/libopenshot")
4679 (commit (string-append "v" version))))
4680 (file-name (git-file-name name version))
4683 "0i9bsn8gklm1mvj60l3d3xrxdgy8svpxjfqcwsr308j5zjn30pv8"))
4684 (modules '((guix build utils)))
4686 ;; Allow overriding of the python installation dir
4687 (substitute* "bindings/python/CMakeLists.txt"
4688 (("(SET\\(PYTHON_MODULE_PATH.*)\\)" _ set)
4689 (string-append set " CACHE PATH "
4690 "\"Python bindings directory\")")))
4691 (delete-file-recursively "thirdparty")
4693 (build-system cmake-build-system)
4695 `(("pkg-config" ,pkg-config)
4698 ("unittest++" ,unittest-cpp)))
4700 (list alsa-lib zlib))
4701 (propagated-inputs ;all referenced in installed headers
4712 (list (string-append "-DPYTHON_MODULE_PATH:PATH=" %output "/lib/python"
4713 ,(version-major+minor (package-version python))
4715 "-DUSE_SYSTEM_JSONCPP:BOOL=ON")
4717 (modify-phases %standard-phases
4718 (add-before 'configure 'set-vars
4719 (lambda* (#:key inputs #:allow-other-keys)
4720 (setenv "LIBOPENSHOT_AUDIO_DIR"
4721 (assoc-ref inputs "libopenshot-audio"))
4723 (assoc-ref inputs "zeromq"))
4724 (setenv "UNITTEST_DIR"
4725 (search-input-directory inputs
4726 "include/UnitTest++")))))))
4727 (home-page "https://openshot.org")
4728 (synopsis "Video-editing, animation, and playback library")
4729 (description "OpenShot Library (libopenshot) is a powerful C++ video
4730 editing library with a multi-threaded and feature rich video editing
4731 API. It includes bindings for Python, Ruby, and other languages.")
4732 (license license:lgpl3+)))
4734 (define-public openshot
4741 (url "https://github.com/OpenShot/openshot-qt")
4742 (commit (string-append "v" version))))
4743 (file-name (git-file-name name version))
4746 "0pa8iwl217503bjlqg2zlrw5lxyq5hvxrf5apxrh3843hj1w1myv"))
4747 (modules '((guix build utils)))
4750 ;; TODO: Unbundle jquery and others from src/timeline/media
4751 (delete-file-recursively "src/images/fonts") #t))))
4752 (build-system python-build-system)
4763 `(#:modules ((guix build python-build-system)
4764 (guix build qt-utils)
4766 #:imported-modules (,@%python-build-system-modules
4767 (guix build qt-utils))
4768 #:phases (modify-phases %standard-phases
4769 (delete 'build) ;install phase does all the work
4771 (lambda* (#:key tests? #:allow-other-keys)
4773 (setenv "QT_QPA_PLATFORM" "offscreen")
4774 (invoke "python" "src/tests/query_tests.py"))))
4775 (add-after 'unpack 'patch-font-location
4776 (lambda* (#:key inputs #:allow-other-keys)
4777 (let ((font (assoc-ref inputs "font-dejavu")))
4778 (substitute* "src/classes/app.py"
4779 (("info.IMAGES_PATH") (string-append "\"" font "\""))
4780 (("fonts") "share/fonts/truetype")
4781 (("[A-Za-z_-]+.ttf") "DejaVuSans.ttf")))
4783 ;; https://github.com/OpenShot/openshot-qt/issues/4502
4784 (add-before 'ensure-no-mtimes-pre-1980 'fix-symbolic-link
4786 (delete-file "images/Humanity/actions/custom/razor_line_with_razor.png")
4787 (symlink "../../../../src/timeline/media/images/razor_line_with_razor.png"
4788 "images/Humanity/actions/custom/razor_line_with_razor.png")))
4789 (add-before 'install 'set-tmp-home
4791 ;; src/classes/info.py "needs" to create several
4792 ;; directories in $HOME when loaded during build
4793 (setenv "HOME" "/tmp")
4795 (add-after 'install 'wrap-program
4796 (lambda* (#:key outputs inputs #:allow-other-keys)
4797 (let ((out (assoc-ref outputs "out")))
4798 (wrap-qt-program "openshot-qt"
4799 #:output out #:inputs inputs))
4801 (home-page "https://www.openshot.org/")
4802 (synopsis "Video editor")
4803 (description "OpenShot takes your videos, photos, and music files and
4804 helps you create the film you have always dreamed of. Easily add sub-titles,
4805 transitions, and effects and then export your film to many common formats.")
4806 (license license:gpl3+)))
4808 (define-public shotcut
4811 (version "21.12.24")
4816 (url "https://github.com/mltframework/shotcut")
4817 (commit (string-append "v" version))))
4818 (file-name (git-file-name name version))
4820 (base32 "1l27dqiyi3af0v155w62ib9xcmqyjj2yzs83aqhcrz5pb3i3j18r"))))
4821 (build-system qt-build-system)
4823 `(#:tests? #f ;there are no tests
4825 (modify-phases %standard-phases
4826 (add-after 'unpack 'patch-executable-paths
4827 (lambda* (#:key inputs #:allow-other-keys)
4828 ;; Shotcut expects ffmpeg and melt executables in the shotcut
4829 ;; directory. Use full store paths.
4830 (let* ((ffmpeg (assoc-ref inputs "ffmpeg"))
4831 (mlt (assoc-ref inputs "mlt")))
4832 (substitute* "src/jobs/ffmpegjob.cpp"
4833 (("\"ffmpeg\"") (string-append "\"" ffmpeg "/bin/ffmpeg\"")))
4834 (substitute* "src/jobs/meltjob.cpp"
4835 (("\"melt\"") (string-append "\"" mlt "/bin/melt\""))
4836 (("\"melt-7\"") (string-append "\"" mlt "/bin/melt-7\""))))))
4838 (lambda* (#:key outputs #:allow-other-keys)
4839 (let* ((out (assoc-ref outputs "out")))
4841 (string-append "PREFIX=" out)
4842 "QMAKE_LRELEASE=lrelease"
4843 "QMAKE_LUPDATE=lupdate"
4845 (add-after 'install 'wrap-executable
4846 (lambda* (#:key inputs outputs #:allow-other-keys)
4847 (let* ((out (assoc-ref outputs "out"))
4848 (frei0r (assoc-ref inputs "frei0r-plugins"))
4849 (jack (assoc-ref inputs "jack"))
4850 (ladspa (assoc-ref inputs "ladspa"))
4851 (mlt (assoc-ref inputs "mlt"))
4852 (sdl2 (assoc-ref inputs "sdl2")))
4853 (wrap-program (string-append out "/bin/shotcut")
4854 `("FREI0R_PATH" ":" =
4855 (,(string-append frei0r "/lib/frei0r-1")))
4856 `("LADSPA_PATH" ":" =
4857 (,(string-append ladspa "/lib/ladspa")))
4858 `("LD_LIBRARY_PATH" ":" prefix
4859 ,(list (string-append jack "/lib" ":" sdl2 "/lib")))
4861 ,(list (string-append mlt "/bin"))))))))))
4863 `(("pkg-config" ,pkg-config)
4864 ("python-wrapper" ,python-wrapper)
4865 ("qttools" ,qttools)))
4888 (home-page "https://www.shotcut.org/")
4889 (synopsis "Video editor built on the MLT framework")
4891 "Shotcut is a video editor built on the MLT framework. Features include
4892 a wide range of formats through @code{ffmpeg}, 4k resolution support, webcam
4893 and audio capture, network stream playback, and many more.")
4894 (license license:gpl3+)))
4896 (define-public dav1d
4904 (url "https://code.videolan.org/videolan/dav1d.git")
4906 (file-name (git-file-name name version))
4908 (base32 "0bkps488h9s15ylvkm4fmfywgrpbw570glawpnv6khpq9n223dzl"))))
4909 (build-system meson-build-system)
4910 (native-inputs (list nasm))
4911 (home-page "https://code.videolan.org/videolan/dav1d")
4912 (synopsis "AV1 decoder")
4913 (description "dav1d is a new AV1 cross-platform decoder, and focused on
4914 speed and correctness.")
4915 (license license:bsd-2)))
4917 (define-public wlstream
4918 (let ((commit "182076a94562b128c3a97ecc53cc68905ea86838")
4922 (version (git-version "0.0" revision commit))
4927 (url "https://github.com/atomnuker/wlstream")
4929 (file-name (git-file-name name version))
4932 "01qbcgfl3g9kfwn1jf1z9pdj3bvf5lmg71d1vwkcllc2az24bjqp"))))
4933 (build-system meson-build-system)
4934 (native-inputs (list libdrm pkg-config))
4935 (inputs (list ffmpeg pulseaudio wayland wayland-protocols))
4936 (home-page "https://github.com/atomnuker/wlstream")
4937 (synopsis "Screen capture tool for Wayland sessions")
4938 (description "Wlstream is a screen capture tool for recording audio and
4939 video from a Wayland session.")
4940 (license license:lgpl2.1+))))
4942 (define-public gaupol
4949 (url "https://github.com/otsaloma/gaupol/")
4951 (file-name (git-file-name name version))
4954 "1mmjg8nwhif2hmmp8i11643izwzdf839brqdai3ksfg0qkh8rnxk"))))
4955 (build-system python-build-system)
4957 `(("gettext" ,gettext-minimal)
4958 ("pkg-config" ,pkg-config)))
4960 (list python-pygobject
4962 python-pycairo ; Required or else clicking on a subtitle line fails.
4963 python-chardet ; Optional: Character encoding detection.
4964 gtkspell3 ; Optional: Inline spell-checking.
4965 iso-codes ; Optional: Translations.
4973 `(#:tests? #f ; Tests seem to require networking.
4975 (modify-phases %standard-phases
4976 (add-after 'unpack 'disable-builtin-byte-compilation
4978 ;; The setup.py script attempts to compile bytecode and fails.
4979 ;; We compile bytecode in a separate phase, so just disable it.
4980 (substitute* "setup.py"
4981 (("distutils\\.util\\.byte_compile\\(.*")
4983 ;; gaupol's setup.py script does not support one of the Python build
4984 ;; system's default flags, "--single-version-externally-managed".
4986 (lambda* (#:key outputs #:allow-other-keys)
4987 (invoke "python" "setup.py" "install"
4988 (string-append "--prefix=" (assoc-ref outputs "out"))
4990 (add-after 'install 'wrap-gaupol
4991 (lambda* (#:key outputs #:allow-other-keys)
4992 (let ((out (assoc-ref outputs "out"))
4993 (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH"))
4994 (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
4995 (wrap-program (string-append out "/bin/gaupol")
4996 `("GST_PLUGIN_SYSTEM_PATH" ":" prefix (,gst-plugin-path))
4997 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))))))
4998 (add-after 'unpack 'patch-data-dir
4999 ;; Fix some path variables that setup.py seems to garble.
5000 (lambda* (#:key outputs #:allow-other-keys)
5001 (let ((out (assoc-ref outputs "out")))
5002 (substitute* "setup.py"
5003 (("DATA_DIR = \\{!r\\}\"\\.format\\(data_dir\\)")
5004 (string-append "DATA_DIR = '" out "/share/gaupol'\""))
5005 (("LOCALE_DIR = \\{!r\\}\"\\.format\\(locale_dir\\)")
5006 (string-append "LOCALE_DIR = '" out "/share/locale'\"")))))))))
5007 (synopsis "Editor for text-based subtitles")
5009 "Gaupol supports multiple subtitle file formats and provides means of
5010 creating subtitles, editing texts and timing subtitles to match video. The
5011 user interface features a builtin video player and is designed with attention
5012 to convenience of translating and batch processing of multiple documents.")
5013 (home-page "https://otsaloma.io/gaupol/")
5014 (license license:gpl3+)))
5016 (define-public theorafile
5017 (let ((commit "404b14d7602b5918d117eaa64e8aa6601ede8593"))
5020 (version (git-version "0.0.0" "1" commit))
5025 (url "https://github.com/FNA-XNA/Theorafile")
5027 (file-name (git-file-name name version))
5029 (base32 "128c3pjzqbgrj020glm5jd6ss18vl19471lj615w2brjwb7c1f0z"))))
5030 (build-system gnu-build-system)
5032 '(#:make-flags '("CC=gcc")
5034 (modify-phases %standard-phases
5039 (invoke "make" "test")))
5041 (lambda* (#:key outputs #:allow-other-keys)
5042 (let ((out (assoc-ref outputs "out")))
5043 (install-file "libtheorafile.so" (string-append out "/lib"))
5044 (install-file "theorafile.h" (string-append out "/include")))
5049 (home-page "https://github.com/FNA-XNA/Theorafile")
5050 (synopsis "Ogg Theora Video Decoder Library")
5051 (description "Theorafile is a library for quickly and easily decoding Ogg
5052 Theora videos. Theorafile was written to be used for FNA's VideoPlayer.")
5053 (license license:zlib))))
5055 (define-public dvdbackup
5062 (uri (string-append "mirror://sourceforge/dvdbackup/dvdbackup/"
5063 "dvdbackup-" version "/"
5064 "dvdbackup-" version ".tar.xz"))
5066 (base32 "1rl3h7waqja8blmbpmwy01q9fgr5r0c32b8dy3pbf59bp3xmd37g"))))
5067 (build-system gnu-build-system)
5069 (list libdvdcss libdvdread))
5070 (home-page "http://dvdbackup.sourceforge.net")
5071 (synopsis "DVD video ripper")
5073 "A simple command line tool to backup video from a DVD. Decrypts the
5074 DVD using @command{libdvdcss}, but does @strong{not} demux, remux,
5075 transcode or reformat the videos in any way, producing perfect backups.")
5076 (license license:gpl3+)))
5078 (define-public svt-av1
5086 (url "https://gitlab.com/AOMediaCodec/SVT-AV1.git")
5087 (commit (string-append "v" version))))
5088 (file-name (git-file-name name version))
5090 (base32 "1mavggl6f7pk7xs22859vm19qp9csjvdcys3b6n2f4pljqkp4qcj"))))
5091 (build-system cmake-build-system)
5092 ;; SVT-AV1 only supports 64-bit Intel-compatible CPUs.
5093 (supported-systems '("x86_64-linux"))
5095 ;; The test suite tries to download test data and git clone a 3rd-party
5096 ;; fork of libaom. Skip it.
5099 (modify-phases %standard-phases
5100 (add-after 'install 'install-documentation
5101 (lambda* (#:key outputs #:allow-other-keys)
5102 (let* ((out (assoc-ref %outputs "out"))
5103 (doc (string-append out "/share/doc/svt-av1-" ,version)))
5104 (copy-recursively "../source/Docs" doc)
5108 (synopsis "AV1 video codec")
5109 (description "SVT-AV1 is an AV1 codec implementation. The encoder is a
5110 work-in-progress, aiming to support video-on-demand and live streaming
5111 applications. It only supports Intel-compatible CPUs (x86).")
5112 (home-page "https://gitlab.com/AOMediaCodec/SVT-AV1")
5113 (license license:bsd-2)))
5115 (define-public svt-vp9
5122 (url "https://github.com/OpenVisualCloud/SVT-VP9")
5123 (commit (string-append "v" version))))
5124 (file-name (git-file-name name version))
5127 "1ypdiw4cq22llvm8jyszxdq6r1aydkj80dsxjarjn5b7c1f2q3ar"))))
5128 ;; SVT-VP9 only supports 64-bit Intel-compatible CPUs.
5129 (supported-systems '("x86_64-linux"))
5130 (build-system cmake-build-system)
5132 `(#:tests? #f ; No test suite
5134 (modify-phases %standard-phases
5135 (add-after 'install 'install-documentation
5136 (lambda* (#:key outputs #:allow-other-keys)
5137 (let* ((out (assoc-ref %outputs "out"))
5138 (doc (string-append out "/share/doc/" ,name "-" ,version)))
5139 (copy-recursively "../source/Docs" doc)
5143 (home-page "https://github.com/OpenVisualCloud/SVT-VP9")
5144 (synopsis "VP9 video encoder")
5145 (description "SVT-VP9 is a VP9 video encoder implementation. It is focused
5146 on supporting video-on-demand and live encoding on Intel Xeon processors.")
5147 (license license:bsd-2)))
5149 (define-public w-scan
5152 (version "20170107")
5156 (uri (string-append "https://www.gen2vdr.de/wirbel/w_scan/w_scan-"
5157 version ".tar.bz2"))
5159 (base32 "1zkgnj2sfvckix360wwk1v5s43g69snm45m0drnzyv7hgf5g7q1q"))))
5160 (build-system gnu-build-system)
5162 `(#:configure-flags '("CFLAGS=-O2 -g -fcommon")))
5163 (synopsis "Scan ATSC/DVB-C/DVB-S/DVB-T channels")
5165 "This is a small command line utility used to perform frequency scans for
5166 DVB and ATSC transmissions without initial tuning data. It can print the
5167 result in several formats:
5169 @item VDR channels.conf,
5170 @item czap/tzap/xine/mplayer channels.conf,
5171 @item Gstreamer dvbsrc plugin,
5172 @item VLC xspf playlist,
5174 @item initial tuning data for scan or dvbv5-scan.
5176 (home-page "https://www.gen2vdr.de/wirbel/w_scan/index2.html")
5177 (license license:gpl2+)))
5179 ;;; XXX: This crate is used only for rav1e and can be removed once the latter
5180 ;;; is updated. See <https://issues.guix.gnu.org/52837>.
5181 (define rust-dav1d-sys-0.3.2
5183 (name "rust-dav1d-sys")
5188 (uri (crate-uri "dav1d-sys" version))
5190 (string-append name "-" version ".tar.gz"))
5192 (base32 "1jdxhnlxcml6jd67lx78ifzkn1xm18zfk4li7vjdh3fa61i073kx"))))
5193 (build-system cargo-build-system)
5196 (("rust-bindgen" ,rust-bindgen-0.54)
5197 ("rust-metadeps" ,rust-metadeps-1))))
5201 (list dav1d clang llvm))
5202 (home-page "https://github.com/rust-av/dav1d-rs")
5203 (synopsis "FFI bindings to dav1d")
5204 (description "This package provides FFI bindings to dav1d.")
5205 (license license:expat)))
5207 (define-public rav1e
5214 (uri (crate-uri "rav1e" version))
5216 (string-append name "-" version ".tar.gz"))
5219 "006bfcmjwg0phg8gc25b1sl2ngjrb2bh1b3fd0s5gbf9nlkr8qsn"))))
5220 (build-system cargo-build-system)
5222 `(;; Strip the '--release' flag to work around the doctest failures with
5223 ;; Rust 1.57 (see: https://github.com/xiph/rav1e/issues/2851).
5224 #:cargo-test-flags '()
5226 (("rust-aom-sys" ,rust-aom-sys-0.3)
5227 ("rust-arbitrary" ,rust-arbitrary-0.4)
5228 ("rust-arg-enum-proc-macro" ,rust-arg-enum-proc-macro-0.3)
5229 ("rust-arrayvec" ,rust-arrayvec-0.7)
5230 ("rust-av-metrics" ,rust-av-metrics-0.7)
5231 ("rust-backtrace" ,rust-backtrace-0.3)
5232 ("rust-bitstream-io" ,rust-bitstream-io-1)
5233 ("rust-byteorder" ,rust-byteorder-1)
5234 ("rust-cfg-if" ,rust-cfg-if-1)
5235 ("rust-clap" ,rust-clap-2)
5236 ("rust-console" ,rust-console-0.14)
5237 ("rust-crossbeam" ,rust-crossbeam-0.8)
5238 ("rust-dav1d-sys" ,rust-dav1d-sys-0.3)
5239 ("rust-fern" ,rust-fern-0.6)
5240 ("rust-image" ,rust-image-0.23)
5241 ("rust-interpolate-name" ,rust-interpolate-name-0.2)
5242 ("rust-itertools" ,rust-itertools-0.10)
5243 ("rust-ivf" ,rust-ivf-0.1)
5244 ("rust-libc" ,rust-libc-0.2)
5245 ("rust-libfuzzer-sys" ,rust-libfuzzer-sys-0.3)
5246 ("rust-log" ,rust-log-0.4)
5247 ("rust-nasm-rs" ,rust-nasm-rs-0.2)
5248 ("rust-noop-proc-macro" ,rust-noop-proc-macro-0.3)
5249 ("rust-num-derive" ,rust-num-derive-0.3)
5250 ("rust-num-traits" ,rust-num-traits-0.2)
5251 ("rust-paste" ,rust-paste-1)
5252 ("rust-rand" ,rust-rand-0.8)
5253 ("rust-rand-chacha" ,rust-rand-chacha-0.3)
5254 ("rust-rayon" ,rust-rayon-1)
5255 ("rust-regex" ,rust-regex-1)
5256 ("rust-rust-hawktracer" ,rust-rust-hawktracer-0.7)
5257 ("rust-rustc-version" ,rust-rustc-version-0.4)
5258 ("rust-scan-fmt" ,rust-scan-fmt-0.2)
5259 ("rust-serde" ,rust-serde-1)
5260 ("rust-signal-hook" ,rust-signal-hook-0.3)
5261 ("rust-simd-helpers" ,rust-simd-helpers-0.1)
5262 ("rust-thiserror" ,rust-thiserror-1)
5263 ("rust-toml" ,rust-toml-0.5)
5264 ("rust-v-frame" ,rust-v-frame-0.2)
5265 ("rust-vergen" ,rust-vergen-3)
5266 ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2)
5267 ("rust-y4m" ,rust-y4m-0.7))
5268 #:cargo-development-inputs
5269 (("rust-assert-cmd" ,rust-assert-cmd-2)
5270 ("rust-cc" ,rust-cc-1)
5271 ("rust-criterion" ,rust-criterion-0.3)
5272 ("rust-interpolate-name" ,rust-interpolate-name-0.2)
5273 ("rust-pretty-assertions" ,rust-pretty-assertions-0.7)
5274 ("rust-rand" ,rust-rand-0.8)
5275 ("rust-rand-chacha" ,rust-rand-chacha-0.3)
5276 ("rust-semver" ,rust-semver-1))
5278 (modify-phases %standard-phases
5279 (add-after 'unpack 'relax-versions
5281 (substitute* "Cargo.toml"
5282 ;; Allow using more recent versions of
5283 (("~3.1.2") "~3"))))
5285 (lambda* (#:key outputs #:allow-other-keys)
5286 (let ((out (assoc-ref outputs "out")))
5287 (invoke "cargo" "cinstall" "--release"
5288 (string-append "--prefix=" out))))))))
5290 `(("cargo-c" ,rust-cargo-c)
5292 (home-page "https://github.com/xiph/rav1e/")
5293 (synopsis "Fast and safe AV1 encoder")
5294 (description "@code{rav1e} is an AV1 video encoder. It is designed to
5295 eventually cover all use cases, though in its current form it is most suitable
5296 for cases where libaom (the reference encoder) is too slow.")
5297 (license license:bsd-2)))
5307 (url "https://github.com/phw/peek")
5309 (file-name (git-file-name name version))
5311 (base32 "1xwlfizga6hvjqq127py8vabaphsny928ar7mwqj9cyqfl6fx41x"))))
5312 (build-system meson-build-system)
5313 (arguments '(#:glib-or-gtk? #t))
5316 ("python" ,python-wrapper)))
5318 `(("desktop-file-utils" ,desktop-file-utils) ; for update-desktop-database
5319 ("gettext" ,gettext-minimal)
5320 ("glib:bin" ,glib "bin") ; for glib-compile-resources
5321 ("gtk+-bin" ,gtk+ "bin") ; For gtk-update-icon-cache
5322 ("pkg-config" ,pkg-config)
5324 (home-page "https://github.com/phw/peek")
5325 (synopsis "Simple animated GIF screen recorder")
5327 "Peek makes it easy to create short screencasts of a screen area. It was
5328 built for the specific use case of recording screen areas, e.g. for easily
5329 showing UI features of your own apps or for showing a bug in bug reports.
5330 With Peek, you simply place the Peek window over the area you want to record
5331 and press \"Record\". Peek is optimized for generating animated GIFs, but you
5332 can also directly record to WebM or MP4 if you prefer.")
5333 (license license:gpl3+)))
5335 (define-public wf-recorder
5337 (name "wf-recorder")
5342 (url "https://github.com/ammen99/wf-recorder")
5343 (commit (string-append "v" version))))
5344 (file-name (git-file-name name version))
5347 "1cw6kpcbl33wh95pvy32xrsrm6kkk1awccr3phyh885xjs3b3iim"))))
5348 (build-system meson-build-system)
5352 (list ffmpeg pulseaudio wayland wayland-protocols libx264))
5353 (home-page "https://github.com/ammen99/wf-recorder")
5354 (synopsis "Screen recorder for wlroots-based compositors")
5356 "@code{wf-recorder} is a utility program for screen recording of
5357 wlroots-based compositors. More specifically, those that support
5358 @code{wlr-screencopy-v1} and @code{xdg-output}.")
5359 (license license:expat)))
5361 (define-public guvcview
5367 (uri (string-append "mirror://sourceforge/guvcview/source/guvcview-"
5368 "src-" version ".tar.gz"))
5371 "11byyfpkcik7wvf2qic77zjamfr2rhji97dpj1gy2fg1bvpiqf4m"))))
5372 (build-system gnu-build-system)
5374 ;; There are no tests and "make check" would fail on an intltool error.
5377 (list pkg-config intltool))
5383 ffmpeg ;libavcodec, libavutil
5388 (home-page "http://guvcview.sourceforge.net/")
5389 (synopsis "Control your webcam and capture videos and images")
5391 "GTK+ UVC Viewer (guvcview) is a graphical application to control a
5392 webcam accessible with Video4Linux (V4L2) and to capture videos and images.
5393 It provides control over precise settings of the webcam such as exposure,
5394 brightness, contrast, and frame rate.")
5396 ;; 'COPYING' is GPLv3 but source headers say GPLv2+.
5397 (license license:gpl2+)))
5399 (define-public get-iplayer
5401 (name "get-iplayer")
5407 (url "https://github.com/get-iplayer/get_iplayer")
5408 (commit (string-append "v" version))))
5409 (file-name (git-file-name name version))
5411 (base32 "077y31gg020wjpx5pcivqgkqawcjxh5kjnvq97x2gd7i3wwc30qi"))))
5412 (build-system perl-build-system)
5414 `(#:tests? #f ; no tests
5416 (modify-phases %standard-phases
5420 (lambda* (#:key outputs #:allow-other-keys)
5421 (let* ((out (assoc-ref outputs "out"))
5422 (bin (string-append out "/bin"))
5423 (man (string-append out "/share/man/man1")))
5424 (install-file "get_iplayer" bin)
5425 (install-file "get_iplayer.cgi" bin)
5426 (install-file "get_iplayer.1" man))
5428 (add-after 'install 'wrap-program
5429 (lambda* (#:key inputs outputs #:allow-other-keys)
5430 (let* ((out (assoc-ref outputs "out"))
5431 (perllib (string-append out "/lib/perl5/site_perl/"
5432 ,(package-version perl))))
5433 (wrap-program (string-append out "/bin/get_iplayer")
5435 prefix (,(string-append perllib ":" (getenv "PERL5LIB")))))
5436 (wrap-program (string-append out "/bin/get_iplayer.cgi")
5438 prefix (,(string-append perllib ":" (getenv "PERL5LIB")))))
5441 (list perl-mojolicious perl-lwp-protocol-https perl-xml-libxml))
5442 (home-page "https://github.com/get-iplayer/get_iplayer")
5443 (synopsis "Download or stream available BBC iPlayer TV and radio programmes")
5444 (description "@code{get_iplayer} lists, searches and records BBC iPlayer
5445 TV/Radio, BBC Podcast programmes. Other third-party plugins may be available.
5446 @code{get_iplayer} has three modes: recording a complete programme for later
5447 playback, streaming a programme directly to a playback application, such as
5448 mplayer; and as a @dfn{Personal Video Recorder} (PVR), subscribing to search
5449 terms and recording programmes automatically. It can also stream or record live
5450 BBC iPlayer output.")
5451 (license license:gpl3+)))
5453 (define-public ogmtools
5459 (uri (string-append "https://www.bunkus.org/videotools/ogmtools/ogmtools-"
5464 "1spx81p5wf59ksl3r3gvf78d77sh7gj8a6lw773iv67bphfivmn8"))))
5465 (build-system gnu-build-system)
5467 (list libvorbis libdvdread))
5468 (synopsis "Information, extraction or creation for OGG media streams")
5470 "These tools allow information about (@code{ogminfo}) or extraction from
5471 \(@code{ogmdemux}) or creation of (@code{ogmmerge}) OGG media streams. It
5472 includes @code{dvdxchap} tool for extracting chapter information from DVD.")
5473 (license license:gpl2)
5474 (home-page "https://www.bunkus.org/videotools/ogmtools/")))
5476 (define-public libcaption
5483 (url "https://github.com/szatmary/libcaption")
5485 (file-name (git-file-name name version))
5488 "16mhw8wpl7wdjj4n7rd1c294p1r8r322plj7z91crla5aah726rq"))))
5489 (build-system cmake-build-system)
5491 `(#:tests? #f ; Cannot figure out how to run the unit tests
5492 #:configure-flags '("-DENABLE_RE2C=ON")))
5495 (synopsis "CEA608 / CEA708 closed-caption codec")
5496 (description "Libcaption creates and parses closed-caption data,
5497 providing an encoder / decoder for the EIA608 and CEA708 closed-caption
5500 608 support is currently limited to encoding and decoding the necessary control
5501 and preamble codes as well as support for the Basic North American, Special
5502 North American and Extended Western European character sets.
5504 708 support is limited to encoding the 608 data in NTSC field 1 user data type
5507 In addition, utility functions to create h.264 SEI (Supplementary enhancement
5508 information) NALUs (Network Abstraction Layer Unit) for inclusion into an h.264
5509 elementary stream are provided.")
5510 (home-page "https://github.com/szatmary/libcaption")
5511 (license license:expat)))
5513 (define-public video-contact-sheet
5515 (name "video-contact-sheet")
5519 (uri (string-append "http://p.outlyer.net/vcs/files/vcs-" version
5523 "0jsl93r0rnybjcipqbww5hwsr9ln6kz1qnf32qfxdvhfw52n27fw"))))
5524 (build-system gnu-build-system)
5528 #~(list (string-append "prefix=" #$output))
5530 #~(modify-phases %standard-phases
5534 (add-after 'install 'wrap-program
5536 (wrap-program (string-append #$output "/bin/vcs")
5539 (string-append dir "/bin"))
5540 (list #$(this-package-input "ffmpeg")
5541 #$(this-package-input "imagemagick"))))))))))
5543 (list bash-minimal ffmpeg imagemagick))
5544 (synopsis "Create contact sheets (preview images) from videos")
5545 (description "@acronym{VCS, Video Contact Sheet} is a Bash script meant to
5546 create video contact sheets (previews) of videos. Any video supported by
5547 MPlayer and FFmpeg can be used. A note of warning: Unlike most similar tools
5548 VCS, by default, makes screenshots the same size as the video, see the manual
5549 for details on how to change this.")
5550 (home-page "http://p.outlyer.net/vcs/")
5551 (license license:lgpl2.1+)))