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