gnu: qemu: Enable Samba support.
[jackhill/guix/guix.git] / gnu / packages / video.scm
CommitLineData
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>
ca3f9952 4;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
cda163cd 5;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
68b3627c 6;;; Copyright © 2015, 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
12f92e38 7;;; Copyright © 2015 Andy Patterson <ajpatter@uwaterloo.ca>
307ad140 8;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
63cd4d53 9;;; Copyright © 2015, 2016, 2017 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>
635f981b 14;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
fe047e13 15;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
590abe01 16;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
72fa6667 17;;; Copyright © 2017 Feng Shu <tumashu@163.com>
b8a31908 18;;; Copyright © 2017 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>
fa379a5b 22;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
2973ebf5 23;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
3440f12a 24;;; Copyright © 2017 Rutger Helling <rhelling@mykolab.com>
39efcc9b
AE
25;;;
26;;; This file is part of GNU Guix.
27;;;
28;;; GNU Guix is free software; you can redistribute it and/or modify it
29;;; under the terms of the GNU General Public License as published by
30;;; the Free Software Foundation; either version 3 of the License, or (at
31;;; your option) any later version.
32;;;
33;;; GNU Guix is distributed in the hope that it will be useful, but
34;;; WITHOUT ANY WARRANTY; without even the implied warranty of
35;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
36;;; GNU General Public License for more details.
37;;;
38;;; You should have received a copy of the GNU General Public License
39;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40
41(define-module (gnu packages video)
fe138965 42 #:use-module (ice-9 match)
08858812 43 #:use-module (srfi srfi-1)
ae0bdd81 44 #:use-module ((guix licenses) #:prefix license:)
e930c2a3 45 #:use-module (guix utils)
39efcc9b
AE
46 #:use-module (guix packages)
47 #:use-module (guix download)
38829eac 48 #:use-module (guix git-download)
d8841cc5 49 #:use-module (guix svn-download)
44726031 50 #:use-module (guix build-system cmake)
39efcc9b 51 #:use-module (guix build-system gnu)
0e74bb5b 52 #:use-module (guix build-system glib-or-gtk)
635f981b 53 #:use-module (guix build-system meson)
615215a5 54 #:use-module (guix build-system python)
1c1178cd 55 #:use-module (guix build-system waf)
3b02429c 56 #:use-module (gnu packages)
39efcc9b 57 #:use-module (gnu packages algebra)
72bfebf5 58 #:use-module (gnu packages audio)
f1044010 59 #:use-module (gnu packages autotools)
d5a748e8 60 #:use-module (gnu packages avahi)
38829eac 61 #:use-module (gnu packages base)
8dd6fc51 62 #:use-module (gnu packages bison)
2973ebf5 63 #:use-module (gnu packages boost)
d5a748e8 64 #:use-module (gnu packages cdrom)
2973ebf5 65 #:use-module (gnu packages check)
fe047e13 66 #:use-module (gnu packages cmake)
39efcc9b 67 #:use-module (gnu packages compression)
e0c40707 68 #:use-module (gnu packages cpp)
f464016d 69 #:use-module (gnu packages curl)
44726031 70 #:use-module (gnu packages databases)
3a44c7bb 71 #:use-module (gnu packages dejagnu)
2973ebf5 72 #:use-module (gnu packages docbook)
e37bdc0f 73 #:use-module (gnu packages documentation)
f22e0e26 74 #:use-module (gnu packages elf)
2973ebf5 75 #:use-module (gnu packages file)
8dd6fc51 76 #:use-module (gnu packages flex)
39efcc9b 77 #:use-module (gnu packages fontutils)
c161c22a 78 #:use-module (gnu packages freedesktop)
44726031
AE
79 #:use-module (gnu packages fribidi)
80 #:use-module (gnu packages gettext)
38829eac 81 #:use-module (gnu packages ghostscript)
d5a748e8
AE
82 #:use-module (gnu packages gl)
83 #:use-module (gnu packages glib)
2cd85cf9 84 #:use-module (gnu packages guile)
fe047e13 85 #:use-module (gnu packages gnome)
d5a748e8 86 #:use-module (gnu packages gnupg)
fe047e13 87 #:use-module (gnu packages gstreamer)
44726031 88 #:use-module (gnu packages gtk)
e55354b8 89 #:use-module (gnu packages image)
b5b20bda 90 #:use-module (gnu packages imagemagick)
c812f460 91 #:use-module (gnu packages libreoffice)
d5a748e8
AE
92 #:use-module (gnu packages linux)
93 #:use-module (gnu packages lua)
fe047e13 94 #:use-module (gnu packages m4)
3a44c7bb 95 #:use-module (gnu packages man)
d5a748e8 96 #:use-module (gnu packages mp3)
4d94b93c 97 #:use-module (gnu packages ncurses)
6f6c8b65 98 #:use-module (gnu packages ocr)
39efcc9b
AE
99 #:use-module (gnu packages perl)
100 #:use-module (gnu packages pkg-config)
a7d94b54 101 #:use-module (gnu packages popt)
d5a748e8 102 #:use-module (gnu packages pulseaudio)
39efcc9b 103 #:use-module (gnu packages python)
589e3f4e 104 #:use-module (gnu packages python-web)
d5a748e8 105 #:use-module (gnu packages qt)
2973ebf5 106 #:use-module (gnu packages ruby)
d5a748e8 107 #:use-module (gnu packages sdl)
2973ebf5
GG
108 #:use-module (gnu packages serialization)
109 #:use-module (gnu packages shells)
d5a748e8 110 #:use-module (gnu packages ssh)
6b2c6be0 111 #:use-module (gnu packages texinfo)
c426e61e 112 #:use-module (gnu packages textutils)
a7fd7b68 113 #:use-module (gnu packages tls)
d5a748e8 114 #:use-module (gnu packages version-control)
bb470bd3 115 #:use-module (gnu packages web)
fe047e13 116 #:use-module (gnu packages webkit)
794223bc 117 #:use-module (gnu packages wxwidgets)
ee3b55ea 118 #:use-module (gnu packages xdisorg)
54ff0b7d 119 #:use-module (gnu packages xiph)
d5a748e8
AE
120 #:use-module (gnu packages xml)
121 #:use-module (gnu packages xorg)
148585c2 122 #:use-module (gnu packages assembly))
39efcc9b 123
6b2c6be0
SB
124(define-public aalib
125 (package
126 (name "aalib")
127 (version "1.4rc5")
128 (source (origin
129 (method url-fetch)
de67e922
LF
130 (uri (string-append "mirror://sourceforge/aa-project/aa-lib/"
131 version "/" name "-" version ".tar.gz"))
6b2c6be0
SB
132 (sha256
133 (base32
134 "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv"))))
135 (build-system gnu-build-system)
136 (native-inputs
137 `(("makeinfo" ,texinfo)))
138 (inputs
139 `(("ncurses" ,ncurses)))
140 (arguments
c437922a 141 `(#:phases
6b2c6be0 142 (modify-phases %standard-phases
3a4de6b2 143 (replace 'configure
014cbde6 144 (lambda* (#:key build inputs outputs #:allow-other-keys)
6b2c6be0
SB
145 ;; This old `configure' script doesn't support
146 ;; variables passed as arguments.
147 (let ((out (assoc-ref outputs "out"))
148 (ncurses (assoc-ref inputs "ncurses")))
149 (setenv "CONFIG_SHELL" (which "bash"))
150 (zero? (system* "./configure"
151 (string-append "--prefix=" out)
014cbde6 152 (string-append "--build=" build)
c437922a
MW
153 ;; The ancient config.guess is unable to
154 ;; guess the host triplet on mips64el.
155 ,@(if (string=? "mips64el-linux"
156 (%current-system))
157 '("--host=mips64el-unknown-linux-gnu")
158 '())
64465558
EF
159 ;; The same is also true with aarch64.
160 ,@(if (string=? "aarch64-linux"
161 (%current-system))
162 '("--host=aarch64-unknown-linux-gnu")
163 '())
6b2c6be0
SB
164 (string-append "--with-ncurses="
165 ncurses)))))))))
166 (home-page "http://aa-project.sourceforge.net/aalib/")
167 (synopsis "ASCII-art library")
168 (description
169 "AA-lib is a low level gfx library which does not require graphics device.
170In fact, there is no graphical output possible. AA-lib replaces those
171old-fashioned output methods with powerful ascii-art renderer.")
172 (license license:lgpl2.0+)))
173
cda163cd
TUBK
174(define-public liba52
175 (package
176 (name "liba52")
177 (version "0.7.4")
178 (source (origin
179 (method url-fetch)
8c056935
TUBK
180 (uri (string-append
181 ;; A mirror://sourceforge URI doesn't work, presumably
182 ;; because the SourceForge project is misconfigured.
183 "http://liba52.sourceforge.net/files/a52dec-" version
184 ".tar.gz"))
cda163cd
TUBK
185 (sha256
186 (base32
23da88f6 187 "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2"))
fc1adab1
AK
188 (patches (search-patches "liba52-enable-pic.patch"
189 "liba52-set-soname.patch"
190 "liba52-use-mtune-not-mcpu.patch"
191 "liba52-link-with-libm.patch"))))
cda163cd 192 (build-system gnu-build-system)
23da88f6
MW
193 ;; XXX We need to run ./bootstrap because of the build system fixes above.
194 (native-inputs
195 `(("autoconf" ,autoconf)
196 ("automake" ,automake)
197 ("libtool" ,libtool)))
412a2422 198 (arguments `(#:configure-flags '("--enable-shared")
23da88f6
MW
199 #:phases
200 (modify-phases %standard-phases
201 ;; XXX We need to run ./bootstrap because of the build
202 ;; system fixes above.
203 (add-after
204 'unpack 'bootstrap
205 (lambda _ (zero? (system* "sh" "bootstrap")))))))
cda163cd
TUBK
206 (home-page "http://liba52.sourceforge.net/")
207 (synopsis "ATSC A/52 stream decoder")
208 (description "liba52 is a library for decoding ATSC A/52 streams. The
209A/52 standard is used in a variety of applications, including digital
210television and DVD. It is also known as AC-3.")
ae0bdd81 211 (license license:gpl2+)))
cda163cd 212
e0884109
MW
213(define-public libmpeg2
214 (package
215 (name "libmpeg2")
216 (version "0.5.1")
217 (source (origin
218 (method url-fetch)
219 ;; A mirror://sourceforge URI doesn't work, presumably
220 ;; because the SourceForge project is misconfigured.
221 (uri (string-append "http://libmpeg2.sourceforge.net/files/"
222 name "-" version ".tar.gz"))
223 (sha256
224 (base32
225 "1m3i322n2fwgrvbs1yck7g5md1dbg22bhq5xdqmjpz5m7j4jxqny"))))
226 (inputs
227 `(("libx11" ,libx11)
228 ("libxext" ,libxext)
229 ("libxv" ,libxv)
230 ("libsm" ,libsm)
231 ("libice" ,libice)
232 ("sdl" ,sdl)))
233 (build-system gnu-build-system)
234 (home-page "http://libmpeg2.sourceforge.net/")
235 (synopsis "MPEG1 and MPEG2 video decoder library")
236 (description
237 "libmpeg2 is a library which can decode MPEG1 and MPEG2 video streams.")
238 (license license:gpl2+)))
239
82712597
MW
240(define-public libx264
241 (package
242 (name "libx264")
715dd13d 243 (version "20170316-2245")
82712597
MW
244 (source (origin
245 (method url-fetch)
4ff71cac 246 (uri (string-append "https://download.videolan.org/pub/x264/snapshots/"
82712597
MW
247 "x264-snapshot-" version ".tar.bz2"))
248 (sha256
249 (base32
715dd13d 250 "1s1nnvl3axz38sv4g09skijl6k9mbbngbb1nsh26w4dr2w2gyzad"))))
82712597
MW
251 (build-system gnu-build-system)
252 (native-inputs
253 `(("pkg-config" ,pkg-config)
254 ("yasm" ,yasm)))
255 ;; TODO: Add gpac input
256 (arguments
257 `(#:tests? #f ;no check target
258 #:configure-flags '("--enable-shared"
259 ;; Don't build the command-line program. If we
260 ;; want it later, we should do so in a different
261 ;; package to avoid a circular dependency (the x264
262 ;; program depends on ffmpeg and ffmpeg depends on
263 ;; libx264).
cb50d0c2
MW
264 "--disable-cli"
265
266 ;; On MIPS, we must pass "--disable-asm" or else
267 ;; configure fails after printing: "You specified a
268 ;; pre-MSA CPU in your CFLAGS. If you really want
269 ;; to run on such a CPU, configure with
270 ;; --disable-asm."
271 ,@(if (string-prefix? "mips"
272 (or (%current-target-system)
273 (%current-system)))
274 '("--disable-asm")
275 '()))))
4ff71cac 276 (home-page "https://www.videolan.org/developers/x264.html")
82712597
MW
277 (synopsis "H.264 video coding library")
278 (description "libx264 is an advanced encoding library for creating
279H.264 (MPEG-4 AVC) video streams.")
280 (license (list license:gpl2+ ;most files
281 license:isc ;common/x86/x86inc.asm
282 license:lgpl2.1+ ;extras/getopt.c
283 license:bsd-3 ;extras/inttypes.h
284 (license:non-copyleft ;extras/cl*.h
285 "file://extras/cl.h"
286 "See extras/cl.h in the distribution.")))))
287
2973ebf5
GG
288(define-public mkvtoolnix
289 (package
290 (name "mkvtoolnix")
291 (version "13.0.0")
292 (source
293 (origin
294 (method url-fetch)
295 (uri (string-append "https://mkvtoolnix.download/sources/"
296 name "-" version ".tar.xz"))
297 (sha256
298 (base32
299 "0hknnnnx9661igm1r73dc7aqxnnrl5a8yvyvr1nhd9ymn2klwpl5"))
300 (modules '((guix build utils)))
301 (snippet
302 '(begin
303 ;; Delete bundled libraries.
304 (for-each delete-file-recursively
305 '("lib/libebml"
306 "lib/libmatroska"
307 "lib/nlohmann-json"
308 "lib/pugixml"
309 "lib/utf8-cpp"))))))
310 (build-system gnu-build-system)
311 (inputs
312 `(("boost" ,boost)
313 ("bzip2" ,bzip2)
314 ("libebml" ,libebml)
315 ("flac" ,flac)
316 ("file" ,file)
317 ("libmatroska" ,libmatroska)
318 ("libogg" ,libogg)
319 ("libvorbis" ,libvorbis)
320 ("lzo" ,lzo)
321 ("pugixml" ,pugixml)
322 ("qt" ,qt)
323 ("utfcpp" ,utfcpp)
324 ("zlib" ,zlib)))
325 (native-inputs
326 `(("docbook-xsl" ,docbook-xsl)
327 ("gettext" ,gettext-minimal)
328 ("googletest" ,googletest)
329 ("libxslt" ,libxslt)
330 ("nlohmann-json-cpp" ,nlohmann-json-cpp)
331 ("perl" ,perl)
332 ("pkg-config" ,pkg-config)
333 ("po4a" ,po4a)
334 ("ruby" ,ruby)))
335 (arguments
336 `(#:configure-flags
337 (list (string-append "--with-boost="
338 (assoc-ref %build-inputs "boost"))
339 (string-append "--with-docbook-xsl-root="
340 (assoc-ref %build-inputs "docbook-xsl")
341 "/xml/xsl/docbook-xsl-"
342 ,(package-version docbook-xsl))
343 (string-append "--with-extra-includes="
344 (assoc-ref %build-inputs "nlohmann-json-cpp")
345 "/include/nlohmann"))
346 #:phases
347 (modify-phases %standard-phases
348 (add-before 'configure 'add-googletest
349 (lambda _
350 (symlink
351 (string-append (assoc-ref %build-inputs "googletest")
352 "/include/gtest") "lib/gtest")
353 #t))
354 (replace 'build
355 (lambda _
356 (let ((-j (list "-j" (number->string (parallel-job-count)))))
357 (zero? (apply system* "rake" -j)))))
358 (replace 'check
359 (lambda _
360 (zero? (system* "rake" "tests/unit"))))
361 (replace 'install
362 (lambda _
363 (zero? (system* "rake" "install")))))))
364 (home-page "https://mkvtoolnix.download")
365 (synopsis "Tools to create, alter and inspect Matroska files")
366 (description
367 "MKVToolNix provides tools for getting information about Matroska files
368(@code{mkvinfo}), extracting tracks/data from Matroska files (@code{mkvextract})
369and creating Matroska files from other media files (@code{mkvmerge}).")
370 (license license:gpl2)))
371
7bc7ffc2
EF
372(define-public x265
373 (package
374 (name "x265")
cfa7473c 375 (version "2.4")
7bc7ffc2
EF
376 (source
377 (origin
378 (method url-fetch)
379 (uri (string-append "https://download.videolan.org/videolan/x265/"
380 "x265_" version ".tar.gz"))
381 (sha256
382 (base32
cfa7473c 383 "0afp0xlk0fb4q6j4sh3hyvjnjccdp61sn21zg3fyqvwgswcafalw"))
7bc7ffc2
EF
384 (modules '((guix build utils)))
385 (snippet
386 '(delete-file-recursively "source/compat/getopt"))))
387 (build-system cmake-build-system)
388 (arguments
389 `(#:tests? #f ; tests are skipped if cpu-optimized code isn't built
a160778c
EF
390 ;; Currently the source code doesn't check for aarch64
391 ,@(if (string-prefix? "aarch64" (or (%current-target-system) (%current-system)))
392 '(#:configure-flags '("-DENABLE_PIC=TRUE"))
393 '())
7bc7ffc2
EF
394 #:phases
395 (modify-phases %standard-phases
396 (add-before 'configure 'prepare-build
397 (lambda _
398 (delete-file-recursively "build")
399 (chdir "source")
400 #t)))))
401 (home-page "http://x265.org/")
402 (synopsis "Library for encoding h.265/HEVC video streams")
403 (description "x265 is a H.265 / HEVC video encoder application library,
404designed to encode video or images into an H.265 / HEVC encoded bitstream.")
405 (license license:gpl2+)))
406
c426e61e
TUBK
407(define-public libass
408 (package
409 (name "libass")
449ad88b 410 (version "0.14.0")
c426e61e
TUBK
411 (source (origin
412 (method url-fetch)
413 (uri (string-append
414 "https://github.com/libass/libass/releases/download/"
415 version "/libass-" version ".tar.xz"))
416 (sha256
417 (base32
449ad88b 418 "18iqznl4mabhj9ywfsz4kwvbsplcv1jjxq50nxssvbj8my1267w8"))))
c426e61e
TUBK
419 (build-system gnu-build-system)
420 (native-inputs
421 `(("pkg-config" ,pkg-config)
449ad88b 422 ("nasm" ,nasm)))
c426e61e
TUBK
423 (propagated-inputs
424 `(("freetype" ,freetype)
425 ("fribidi" ,fribidi)
426 ("fontconfig" ,fontconfig)
427 ("harfbuzz" ,harfbuzz)
428 ("enca" ,enca)))
429 (home-page "https://github.com/libass/libass")
430 (synopsis "Subtitle rendering library for the ASS/SSA format")
431 (description "libass is a subtitle rendering library for the
432ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.")
ae0bdd81 433 (license license:isc)))
c426e61e 434
4d94b93c
TUBK
435(define-public libcaca
436 (package
437 (name "libcaca")
438 (version "0.99.beta19")
439 (source (origin
440 (method url-fetch)
441 (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-"
442 version ".tar.gz"))
443 (sha256
444 (base32
445 "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj"))))
446 (build-system gnu-build-system)
447 (native-inputs `(("pkg-config" ,pkg-config)))
448 (inputs
449 `(("freeglut" ,freeglut)
450 ("ftgl" ,ftgl)
43d51239 451 ("imlib2" ,imlib2)
4d94b93c
TUBK
452 ("libx11" ,libx11)
453 ("mesa" ,mesa)
454 ("ncurses" ,ncurses)
455 ("zlib" ,zlib)))
456 (home-page "http://caca.zoy.org/wiki/libcaca")
457 (synopsis "Colour ASCII-art library")
458 (description "libcaca is a graphics library that outputs text instead of
459pixels, so that it can work on older video cards or text terminals. It
460supports Unicode, 2048 colors, dithering of color images, and advanced text
461canvas operations.")
ae0bdd81 462 (license (license:fsf-free "file://COPYING")))) ;WTFPL version 2
4d94b93c 463
3bfb78dc
TUBK
464(define-public libdca
465 (package
466 (name "libdca")
467 (version "0.0.5")
468 (source (origin
469 (method url-fetch)
470 (uri (string-append
b8a31908 471 "https://download.videolan.org/pub/videolan/libdca/"
3bfb78dc
TUBK
472 version "/libdca-" version ".tar.bz2"))
473 (sha256
474 (base32
475 "0hh6a7l8vvccsd5i1fkv9av2gzv9fy8m0b8jpsn5p6hh4bh2586v"))))
476 (build-system gnu-build-system)
b8a31908 477 (home-page "https://www.videolan.org/developers/libdca.html")
3bfb78dc
TUBK
478 (synopsis "DTS Coherent Acoustics decoder")
479 (description "libdca is a library for decoding DTS Coherent Acoustics
480streams.")
ae0bdd81 481 (license license:gpl2+)))
3bfb78dc 482
99d4c455
TUBK
483(define-public libdv
484 (package
485 (name "libdv")
486 (version "1.0.0")
487 (source (origin
488 (method url-fetch)
489 (uri (string-append
de67e922
LF
490 "mirror://sourceforge/" name "/" name "/"
491 version "/" name "-" version ".tar.gz"))
99d4c455
TUBK
492 (sha256
493 (base32
494 "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3"))))
495 (build-system gnu-build-system)
496 (native-inputs `(("pkg-config" ,pkg-config)))
497 (inputs `(("libxv" ,libxv)))
498 (home-page "http://libdv.sourceforge.net/")
499 (synopsis "DV video (IEC 61834 and SMPTE 314M) codec")
500 (description "The Quasar DV codec (libdv) is a software codec for DV
501video, the encoding format used by most digital camcorders, typically those
502that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was
503developed according to the official standards for DV video: IEC 61834 and
504SMPTE 314M.")
ae0bdd81 505 (license license:lgpl2.1+)))
99d4c455 506
15f1d02a
GG
507(define-public libmatroska
508 (package
509 (name "libmatroska")
510 (version "1.4.7")
511 (source
512 (origin
513 (method url-fetch)
514 (uri (string-append "https://dl.matroska.org/downloads/"
515 name "/" name "-" version ".tar.bz2"))
516 (sha256
517 (base32
518 "1yi5cnv13nhl27xyqayd5l3sf0j3swfj3apzibv71yg9pariwi26"))))
519 (build-system gnu-build-system)
520 (native-inputs
521 `(("pkg-config" ,pkg-config)))
522 (inputs
523 `(("libebml" ,libebml)))
524 (home-page "https://www.matroska.org")
525 (synopsis "C++ libary to parse Matroska files (.mkv and .mka)")
526 (description
527 "Matroska aims to become the standard of multimedia container formats.
528It is based on EBML (Extensible Binary Meta Language), a binary derivative
529of XML. EBML enables the Matroska Development Team to gain significant
530advantages in terms of future format extensibility, without breaking file
531support in old parsers.
532libebml is a C++ library to read and write EBML files.")
533 (license license:lgpl2.1)))
534
ee3b55ea
TUBK
535(define-public libva
536 (package
537 (name "libva")
7035d2dd 538 (version "1.8.3")
ee3b55ea
TUBK
539 (source
540 (origin
541 (method url-fetch)
7035d2dd
MB
542 (uri (list
543 ;; Newer releases are only available on GitHub.
544 (string-append "https://github.com/01org/libva/releases/download/"
545 version "/libva-" version ".tar.bz2")
546 ;; Keep the old URL around for compatibility.
547 (string-append "https://www.freedesktop.org/software/vaapi/releases/"
548 "libva/libva-" version "/libva-" version ".tar.bz2")))
ee3b55ea 549 (sha256
7035d2dd 550 (base32 "16xbk0awl7wp0vy0nyjvxk11spbw25mp8kwd9bmhd6x9xffi5vjn"))))
ee3b55ea
TUBK
551 (build-system gnu-build-system)
552 (native-inputs
553 `(("pkg-config" ,pkg-config)))
554 (inputs
555 `(("libdrm" ,libdrm)
556 ("libx11" ,libx11)
557 ("libxext" ,libxext)
558 ("libxfixes" ,libxfixes)
559 ("mesa" ,mesa)))
372cf039
TUBK
560 (arguments
561 `(#:phases
562 (modify-phases %standard-phases
563 (add-before
564 'build 'fix-dlopen-paths
565 (lambda* (#:key outputs #:allow-other-keys)
566 (let ((out (assoc-ref outputs "out")))
567 (substitute* "va/drm/va_drm_auth_x11.c"
568 (("\"libva-x11\\.so\\.%d\"")
569 (string-append "\"" out "/lib/libva-x11.so.%d\"")))))))
570 ;; Most drivers are in mesa's $prefix/lib/dri, so use that. (Can be
571 ;; overridden at run-time via LIBVA_DRIVERS_PATH.)
572 #:configure-flags
573 (list (string-append "--with-drivers-path="
574 (assoc-ref %build-inputs "mesa") "/lib/dri"))
575 ;; However, we can't write to mesa's store directory, so override the
576 ;; following make variable to install the dummy driver to libva's
577 ;; $prefix/lib/dri directory.
578 #:make-flags
579 (list (string-append "dummy_drv_video_ladir="
580 (assoc-ref %outputs "out") "/lib/dri"))))
5c1c2254 581 (home-page "https://www.freedesktop.org/wiki/Software/vaapi/")
ee3b55ea
TUBK
582 (synopsis "Video acceleration library")
583 (description "The main motivation for VA-API (Video Acceleration API) is
584to enable hardware accelerated video decode/encode at various
585entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
586standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
ae0bdd81 587 (license license:expat)))
ee3b55ea 588
39efcc9b
AE
589(define-public ffmpeg
590 (package
591 (name "ffmpeg")
7f7419b5 592 (version "3.4.1")
39efcc9b
AE
593 (source (origin
594 (method url-fetch)
a1121a7f
EF
595 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
596 version ".tar.xz"))
39efcc9b
AE
597 (sha256
598 (base32
7f7419b5 599 "1h4iz7q10wj04awr2wvmp60n7b09pfwrgwbbw9sgl7klcf52fxss"))))
39efcc9b
AE
600 (build-system gnu-build-system)
601 (inputs
c4c4cc05 602 `(("fontconfig" ,fontconfig)
39efcc9b 603 ("freetype" ,freetype)
8fd43200 604 ("frei0r-plugins" ,frei0r-plugins)
c8dab7f4 605 ("gnutls" ,gnutls)
e816b348 606 ("opus" ,opus)
71241192 607 ("ladspa" ,ladspa)
d4f12db8 608 ("lame" ,lame)
c426e61e 609 ("libass" ,libass)
5d3609e4 610 ("libbluray" ,libbluray)
4d94b93c 611 ("libcaca" ,libcaca)
cc6c0170 612 ("libcdio-paranoia" ,libcdio-paranoia)
39efcc9b 613 ("libtheora" ,libtheora)
bb3df15e 614 ("libva" ,libva)
f88f0d20 615 ("libvdpau" ,libvdpau)
39efcc9b 616 ("libvorbis" ,libvorbis)
dc55b8b2 617 ("libvpx" ,libvpx)
f88f0d20 618 ("libx11" ,libx11)
549381d6 619 ("libx264" ,libx264)
f88f0d20 620 ("mesa" ,mesa)
71241192 621 ("openal" ,openal)
71241192 622 ("pulseaudio" ,pulseaudio)
85bc5434 623 ("sdl" ,sdl2)
72bfebf5 624 ("soxr" ,soxr)
c4c4cc05 625 ("speex" ,speex)
72bfebf5 626 ("twolame" ,twolame)
d505801a 627 ("x265" ,x265)
67932f86 628 ("xvid" ,xvid)
b3546174 629 ("zlib" ,zlib)))
c4c4cc05
JD
630 (native-inputs
631 `(("bc" ,bc)
39efcc9b
AE
632 ("perl" ,perl)
633 ("pkg-config" ,pkg-config)
824d9dc3 634 ("texinfo" ,texinfo)
39efcc9b
AE
635 ("python" ,python-2) ; scripts use interpreter python2
636 ("speex" ,speex)
c4c4cc05 637 ("yasm" ,yasm)))
39efcc9b 638 (arguments
31f9322e 639 `(#:test-target "fate"
12f92e38
AP
640 #:configure-flags
641 ;; possible additional inputs:
642 ;; --enable-avisynth enable reading of AviSynth script
643 ;; files [no]
12f92e38
AP
644 ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no]
645 ;; --enable-libcelt enable CELT decoding via libcelt [no]
646 ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
647 ;; and libraw1394 [no]
648 ;; --enable-libfaac enable AAC encoding via libfaac [no]
649 ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]
650 ;; --enable-libflite enable flite (voice synthesis) support via
651 ;; libflite [no]
652 ;; --enable-libgme enable Game Music Emu via libgme [no]
653 ;; --enable-libgsm enable GSM de/encoding via libgsm [no]
654 ;; --enable-libiec61883 enable iec61883 via libiec61883 [no]
655 ;; --enable-libilbc enable iLBC de/encoding via libilbc [no]
656 ;; --enable-libmodplug enable ModPlug via libmodplug [no]
657 ;; --enable-libnut enable NUT (de)muxing via libnut,
658 ;; native (de)muxer exists [no]
659 ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via
660 ;; libopencore-amrnb [no]
661 ;; --enable-libopencore-amrwb enable AMR-WB decoding via
662 ;; libopencore-amrwb [no]
663 ;; --enable-libopencv enable video filtering via libopencv [no]
664 ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via
665 ;; OpenJPEG [no]
666 ;; --enable-librtmp enable RTMP[E] support via librtmp [no]
667 ;; --enable-libschroedinger enable Dirac de/encoding via
668 ;; libschroedinger [no]
669 ;; --enable-libshine enable fixed-point MP3 encoding via
670 ;; libshine [no]
671 ;; --enable-libssh enable SFTP protocol via libssh [no]
672 ;; (libssh2 does not work)
673 ;; --enable-libstagefright-h264 enable H.264 decoding via
674 ;; libstagefright [no]
675 ;; --enable-libutvideo enable Ut Video encoding and decoding via
676 ;; libutvideo [no]
677 ;; --enable-libv4l2 enable libv4l2/v4l-utils [no]
678 ;; --enable-libvidstab enable video stabilization using
679 ;; vid.stab [no]
680 ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no]
681 ;; --enable-libvo-amrwbenc enable AMR-WB encoding via
682 ;; libvo-amrwbenc [no]
683 ;; --enable-libwavpack enable wavpack encoding via libwavpack [no]
684 ;; --enable-libxavs enable AVS encoding via xavs [no]
685 ;; --enable-libzmq enable message passing via libzmq [no]
686 ;; --enable-libzvbi enable teletext support via libzvbi [no]
687 ;; --enable-opencl enable OpenCL code
12f92e38
AP
688 '("--enable-avresample"
689 "--enable-gpl" ; enable optional gpl licensed parts
690 "--enable-shared"
8fd43200 691 "--enable-frei0r"
12f92e38 692 "--enable-fontconfig"
c8dab7f4 693 "--enable-gnutls"
12f92e38
AP
694 "--enable-ladspa"
695 "--enable-libass"
696 "--enable-libbluray"
697 "--enable-libcaca"
698 "--enable-libcdio"
699 "--enable-libfreetype"
700 "--enable-libmp3lame"
701 "--enable-libopus"
702 "--enable-libpulse"
12f92e38
AP
703 "--enable-libsoxr"
704 "--enable-libspeex"
705 "--enable-libtheora"
706 "--enable-libtwolame"
707 "--enable-libvorbis"
708 "--enable-libvpx"
709 "--enable-libxvid"
710 "--enable-libx264"
d505801a 711 "--enable-libx265"
12f92e38 712 "--enable-openal"
f88f0d20 713 "--enable-opengl"
12f92e38
AP
714
715 "--enable-runtime-cpudetect"
716
1e2a36e1
EF
717 ;; The HTML pages take 7.2 MiB
718 "--disable-htmlpages"
719
720 ;; The static libraries are 23 MiB
721 "--disable-static"
722
12f92e38
AP
723 ;; Runtime cpu detection is not implemented on
724 ;; MIPS, so we disable some features.
725 "--disable-mips32r2"
c5e1fcd0 726 "--disable-mipsdsp"
12f92e38
AP
727 "--disable-mipsdspr2"
728 "--disable-mipsfpu")
31f9322e 729 #:phases
f2feb0ce
LC
730 (modify-phases %standard-phases
731 (replace
39efcc9b
AE
732 'configure
733 ;; configure does not work followed by "SHELL=..." and
734 ;; "CONFIG_SHELL=..."; set environment variables instead
735 (lambda* (#:key outputs configure-flags #:allow-other-keys)
736 (let ((out (assoc-ref outputs "out")))
737 (substitute* "configure"
47734a56 738 (("#! /bin/sh") (string-append "#!" (which "sh"))))
39efcc9b
AE
739 (setenv "SHELL" (which "bash"))
740 (setenv "CONFIG_SHELL" (which "bash"))
12f92e38
AP
741 (zero? (apply system*
742 "./configure"
743 (string-append "--prefix=" out)
744 ;; Add $libdir to the RUNPATH of all the binaries.
745 (string-append "--extra-ldflags=-Wl,-rpath="
746 out "/lib")
747 configure-flags)))))
457e528e
LC
748 (add-before
749 'check 'set-ld-library-path
750 (lambda _
751 ;; Allow $(top_builddir)/ffmpeg to find its dependencies when
752 ;; running tests.
753 (let* ((dso (find-files "." "\\.so$"))
754 (path (string-join (map dirname dso) ":")))
755 (format #t "setting LD_LIBRARY_PATH to ~s~%" path)
756 (setenv "LD_LIBRARY_PATH" path)
27350ef8 757 #t))))))
702bfbf1 758 (home-page "https://www.ffmpeg.org/")
39efcc9b
AE
759 (synopsis "Audio and video framework")
760 (description "FFmpeg is a complete, cross-platform solution to record,
761convert and stream audio and video. It includes the libavcodec
762audio/video codec library.")
ae0bdd81 763 (license license:gpl2+)))
d5a748e8 764
940778c7
LC
765(define-public ffmpeg-2.8
766 (package
767 (inherit ffmpeg)
47111bb3 768 (version "2.8.13")
940778c7
LC
769 (source (origin
770 (method url-fetch)
771 (uri (string-append "https://ffmpeg.org/releases/ffmpeg-"
772 version ".tar.xz"))
773 (sha256
774 (base32
47111bb3 775 "0hyqr391pika4vgynv90bacz11wdpqcqfgj5h7g5jrmgvz6hgj68"))))
940778c7
LC
776 (arguments
777 (substitute-keyword-arguments (package-arguments ffmpeg)
778 ((#:configure-flags flags)
779 `(map (lambda (flag)
780 (if (string=? flag "--disable-mipsdsp")
781 "--disable-mipsdspr1"
782 flag))
783 ,flags))))))
784
d5a748e8
AE
785(define-public vlc
786 (package
787 (name "vlc")
f137f849 788 (version "2.2.8")
d5a748e8
AE
789 (source (origin
790 (method url-fetch)
791 (uri (string-append
a134cc8e 792 "https://download.videolan.org/pub/videolan/vlc/"
d5a748e8
AE
793 version "/vlc-" version ".tar.xz"))
794 (sha256
795 (base32
f137f849 796 "1v32snw46rkgbdqdy3dssl2y13i8p2cr1cw1i18r6vdmiy24dw4v"))))
d5a748e8
AE
797 (build-system gnu-build-system)
798 (native-inputs
2d2e97bd 799 `(("git" ,git) ; needed for a test
d5a748e8
AE
800 ("pkg-config" ,pkg-config)))
801 ;; FIXME: Add optional inputs once available.
802 (inputs
803 `(("alsa-lib" ,alsa-lib)
804 ("avahi" ,avahi)
805 ("dbus" ,dbus)
806 ("flac" ,flac)
b4dff935 807 ("ffmpeg" ,ffmpeg-2.8) ;fails to build against ffmpeg 3.0
d5a748e8
AE
808 ("fontconfig" ,fontconfig)
809 ("freetype" ,freetype)
810 ("gnutls" ,gnutls)
8824da4c 811 ("liba52" ,liba52)
d5a748e8 812 ("libcddb" ,libcddb)
72b6a894 813 ("libdvbpsi" ,libdvbpsi)
d5a748e8
AE
814 ("libgcrypt" ,libgcrypt)
815 ("libkate" ,libkate)
816 ("libmad" ,libmad)
817 ("libogg" ,libogg)
818 ("libpng" ,libpng)
819 ("libsamplerate" ,libsamplerate)
820 ("libssh2" ,libssh2)
821 ("libvorbis" ,libvorbis)
822 ("libtheora" ,libtheora)
823 ("libxext" ,libxext)
c161c22a 824 ("libxi" ,libxi)
d5a748e8
AE
825 ("libxinerama" ,libxinerama)
826 ("libxml2" ,libxml2)
827 ("libxpm" ,libxpm)
2aaa5729 828 ("livemedia-utils" ,livemedia-utils)
d5a748e8
AE
829 ("lua" ,lua-5.1)
830 ("mesa" ,mesa)
831 ("opus" ,opus)
832 ("perl" ,perl)
833 ("pulseaudio" ,pulseaudio)
834 ("python" ,python-wrapper)
552c3e95
MB
835 ("qtbase" ,qtbase)
836 ("qtx11extras" ,qtx11extras)
d5a748e8
AE
837 ("sdl" ,sdl)
838 ("sdl-image" ,sdl-image)
839 ("speex" ,speex)
8f5f6c92 840 ("x265" ,x265)
d5a748e8
AE
841 ("xcb-util-keysyms" ,xcb-util-keysyms)))
842 (arguments
843 `(#:configure-flags
eb1f2420 844 `("CXXFLAGS=-std=gnu++11"
d5a748e8
AE
845 ,(string-append "LDFLAGS=-Wl,-rpath -Wl,"
846 (assoc-ref %build-inputs "ffmpeg")
cd76fbde
LC
847 "/lib")) ;needed for the tests
848
849 #:phases
850 (modify-phases %standard-phases
2d2e97bd 851 (add-after 'unpack 'patch-source
2aaa5729
CL
852 (lambda* (#:key inputs #:allow-other-keys)
853 (let ((livemedia-utils (assoc-ref inputs "livemedia-utils")))
2d2e97bd 854 (substitute* "configure"
2aaa5729
CL
855 (("LIVE555_PREFIX=\\$\\{LIVE555_PREFIX-\"/usr\"\\}")
856 (string-append "LIVE555_PREFIX=" livemedia-utils)))
2d2e97bd
MB
857 ;; Some of the tests require using the display to test out VLC,
858 ;; which fails in our sandboxed build system
859 (substitute* "test/run_vlc.sh"
860 (("./vlc --ignore-config") "echo"))
861 ;; XXX Likely not needed for >2.2.6.
862 (substitute* "modules/gui/qt4/components/interface_widgets.cpp"
863 (("<qx11info_x11.h>") "<QtX11Extras/qx11info_x11.h>"))
2aaa5729 864 #t)))
cd76fbde
LC
865 (add-after 'install 'regenerate-plugin-cache
866 (lambda* (#:key outputs #:allow-other-keys)
867 ;; The 'install-exec-hook' rule in the top-level Makefile.am
868 ;; generates 'lib/vlc/plugins/plugins.dat', a plugin cache, using
869 ;; 'vlc-cache-gen'. This file includes the mtime of the plugins
870 ;; it references. Thus, we first reset the timestamps of all
871 ;; these files, and then regenerate the cache such that the
872 ;; mtimes it includes are always zero instead of being dependent
873 ;; on the build time.
874 (let* ((out (assoc-ref outputs "out"))
875 (pkglibdir (string-append out "/lib/vlc"))
876 (plugindir (string-append pkglibdir "/plugins"))
877 (cachegen (string-append pkglibdir "/vlc-cache-gen")))
878 ;; TODO: Factorize 'reset-timestamps'.
879 (for-each (lambda (file)
880 (let ((s (lstat file)))
881 (unless (eq? (stat:type s) 'symlink)
882 (utime file 0 0 0 0))))
883 (find-files plugindir))
884 (zero? (system* cachegen plugindir))))))))
d5a748e8
AE
885 (home-page "https://www.videolan.org/")
886 (synopsis "Audio and video framework")
887 (description "VLC is a cross-platform multimedia player and framework
888that plays most multimedia files as well as DVD, Audio CD, VCD, and various
889treaming protocols.")
ae0bdd81 890 (license license:gpl2+)))
ace69243
AE
891
892(define-public mplayer
893 (package
894 (name "mplayer")
e71b20e5 895 (version "1.3.0")
ace69243
AE
896 (source (origin
897 (method url-fetch)
898 (uri (string-append
ebde7c7a 899 "https://www.mplayerhq.hu/MPlayer/releases/MPlayer-"
ace69243
AE
900 version ".tar.xz"))
901 (sha256
902 (base32
e71b20e5 903 "0hwqn04bdknb2ic88xd75smffxx63scvz0zvwvjb56nqj9n89l1s"))))
ace69243
AE
904 (build-system gnu-build-system)
905 ;; FIXME: Add additional inputs once available.
906 (native-inputs
907 `(("pkg-config" ,pkg-config)))
908 (inputs
909 `(("alsa-lib" ,alsa-lib)
910 ("cdparanoia" ,cdparanoia)
b3546174 911 ("ffmpeg" ,ffmpeg)
778a6a8b 912 ("fontconfig" ,fontconfig)
ace69243 913 ("freetype" ,freetype)
778a6a8b 914;; ("giflib" ,giflib) ; uses QuantizeBuffer, requires version >= 5
ace69243 915 ("lame" ,lame)
778a6a8b 916 ("libass" ,libass)
b3546174
MW
917 ("libdvdcss" ,libdvdcss)
918 ("libdvdnav" ,libdvdnav)
ace69243 919 ("libjpeg" ,libjpeg)
778a6a8b
EF
920 ("libmpeg2" ,libmpeg2)
921 ("libmpg123" ,mpg123) ; audio codec for MP3
ace69243
AE
922 ("libpng" ,libpng)
923 ("libtheora" ,libtheora)
778a6a8b 924 ("libvdpau" ,libvdpau)
ace69243
AE
925 ("libvorbis" ,libvorbis)
926 ("libx11" ,libx11)
778a6a8b 927 ("libx264" ,libx264)
ace69243
AE
928 ("libxinerama" ,libxinerama)
929 ("libxv" ,libxv)
778a6a8b 930 ("libxxf86dga" ,libxxf86dga)
ace69243 931 ("mesa" ,mesa)
778a6a8b 932 ("opus" ,opus)
ace69243
AE
933 ("perl" ,perl)
934 ("pulseaudio" ,pulseaudio)
935 ("python" ,python-wrapper)
936 ("sdl" ,sdl)
937 ("speex" ,speex)
938 ("yasm" ,yasm)
939 ("zlib" ,zlib)))
940 (arguments
941 `(#:tests? #f ; no test target
942 #:phases
ebde7c7a
EF
943 (modify-phases %standard-phases
944 (replace 'configure
ace69243
AE
945 ;; configure does not work followed by "SHELL=..." and
946 ;; "CONFIG_SHELL=..."; set environment variables instead
947 (lambda* (#:key inputs outputs #:allow-other-keys)
948 (let ((out (assoc-ref outputs "out"))
949 (libx11 (assoc-ref inputs "libx11")))
950 (substitute* "configure"
2564b7c2 951 (("#! /bin/sh") (string-append "#!" (which "sh"))))
ace69243
AE
952 (setenv "SHELL" (which "bash"))
953 (setenv "CONFIG_SHELL" (which "bash"))
954 (zero? (system*
955 "./configure"
956 (string-append "--extra-cflags=-I"
957 libx11 "/include") ; to detect libx11
ebde7c7a 958 "--disable-ffmpeg_a" ; disables bundled ffmpeg
ace69243 959 (string-append "--prefix=" out)
fe138965
MW
960 ;; Enable runtime cpu detection where supported,
961 ;; and choose a suitable target.
962 ,@(match (or (%current-target-system)
963 (%current-system))
964 ("x86_64-linux"
965 '("--enable-runtime-cpudetection"
966 "--target=x86_64-linux"))
967 ("i686-linux"
968 '("--enable-runtime-cpudetection"
969 "--target=i686-linux"))
970 ("mips64el-linux"
f0d6d835
MW
971 '("--target=mips3-linux"))
972 (_ (list (string-append
973 "--target="
974 (or (%current-target-system)
975 (nix-system->gnu-triplet
976 (%current-system)))))))
ebde7c7a
EF
977 "--disable-iwmmxt"))))))))
978 (home-page "https://www.mplayerhq.hu/design7/news.html")
ace69243
AE
979 (synopsis "Audio and video player")
980 (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI,
981Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT,
982NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD,
983SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.")
ae0bdd81 984 (license license:gpl2)))
d0ed39be 985
1c1178cd
TUBK
986(define-public mpv
987 (package
988 (name "mpv")
6fcf8c2d 989 (version "0.27.0")
1c1178cd
TUBK
990 (source (origin
991 (method url-fetch)
992 (uri (string-append
993 "https://github.com/mpv-player/mpv/archive/v" version
994 ".tar.gz"))
995 (sha256
996 (base32
6fcf8c2d 997 "1754371fkva8aqxgbm50jxyvij7mnysq0538bf6zghbmigqqn79l"))
1c1178cd
TUBK
998 (file-name (string-append name "-" version ".tar.gz"))))
999 (build-system waf-build-system)
1000 (native-inputs
832d60dc 1001 `(("perl" ,perl) ; for zsh completion file
1c1178cd
TUBK
1002 ("pkg-config" ,pkg-config)
1003 ("python-docutils" ,python-docutils)))
3440f12a 1004 ;; Missing features: libguess, V4L2
1c1178cd
TUBK
1005 (inputs
1006 `(("alsa-lib" ,alsa-lib)
1007 ("enca" ,enca)
1008 ("ffmpeg" ,ffmpeg)
2d8781a4 1009 ("jack" ,jack-1)
1c1178cd
TUBK
1010 ("ladspa" ,ladspa)
1011 ("lcms" ,lcms)
1012 ("libass" ,libass)
1013 ("libbluray" ,libbluray)
1014 ("libcaca" ,libcaca)
1015 ("libbs2b" ,libbs2b)
1016 ("libcdio-paranoia" ,libcdio-paranoia)
1017 ("libdvdread" ,libdvdread)
1018 ("libdvdnav" ,libdvdnav)
1019 ("libjpeg" ,libjpeg)
1020 ("libva" ,libva)
81c29ccc 1021 ("libvdpau" ,libvdpau)
1c1178cd
TUBK
1022 ("libx11" ,libx11)
1023 ("libxext" ,libxext)
1024 ("libxinerama" ,libxinerama)
1025 ("libxrandr" ,libxrandr)
1026 ("libxscrnsaver" ,libxscrnsaver)
1027 ("libxv" ,libxv)
e66f0dd2
AP
1028 ;; XXX: lua > 5.2 is not currently supported; see
1029 ;; waftools/checks/custom.py
1030 ("lua" ,lua-5.2)
1c1178cd
TUBK
1031 ("mesa" ,mesa)
1032 ("mpg123" ,mpg123)
1033 ("pulseaudio" ,pulseaudio)
1034 ("rsound" ,rsound)
f0b8d83a 1035 ("waf" ,python-waf)
3440f12a
RH
1036 ("wayland" ,wayland)
1037 ("libxkbcommon", libxkbcommon)
1c1178cd
TUBK
1038 ("youtube-dl" ,youtube-dl)
1039 ("zlib" ,zlib)))
1040 (arguments
1041 '(#:phases
1042 (modify-phases %standard-phases
1043 (add-before
f8503e2b 1044 'configure 'setup-waf
1c1178cd
TUBK
1045 (lambda* (#:key inputs #:allow-other-keys)
1046 (copy-file (assoc-ref inputs "waf") "waf")
599fd842 1047 (setenv "CC" "gcc"))))
98c8b963 1048 #:configure-flags (list "--enable-libmpv-shared"
43ba5dd4
EF
1049 "--enable-cdda"
1050 "--enable-dvdread"
1051 "--enable-dvdnav"
98c8b963
EF
1052 "--enable-zsh-comp"
1053 "--disable-build-date")
1c1178cd
TUBK
1054 ;; No check function defined.
1055 #:tests? #f))
581873b5 1056 (home-page "https://mpv.io/")
1c1178cd
TUBK
1057 (synopsis "Audio and video player")
1058 (description "mpv is a general-purpose audio and video player. It is a
1059fork of mplayer2 and MPlayer. It shares some features with the former
1060projects while introducing many more.")
ae0bdd81 1061 (license license:gpl2+)))
1c1178cd 1062
0e74bb5b
AG
1063(define-public gnome-mpv
1064 (package
1065 (name "gnome-mpv")
9b5db24e 1066 (version "0.13")
0e74bb5b
AG
1067 (source
1068 (origin
1069 (method url-fetch)
1070 (uri (string-append "https://github.com/gnome-mpv/gnome-mpv/releases"
1071 "/download/v" version "/gnome-mpv-" version
1072 ".tar.xz"))
1073 (sha256
1074 (base32
9b5db24e 1075 "1w944ymyssgfcjiczrq4saig90crw9b9hhdsnchfbjsw173qi8n5"))))
0e74bb5b
AG
1076 (native-inputs
1077 `(("intltool" ,intltool)
1078 ("pkg-config" ,pkg-config)))
1079 (inputs
1080 `(("gtk+" ,gtk+)
1081 ("libepoxy" ,libepoxy)
1082 ("mpv" ,mpv)))
1083 (build-system glib-or-gtk-build-system)
1084 (home-page "https://github.com/gnome-mpv/gnome-mpv")
1085 (synopsis "GTK+ frontend for the mpv media player")
1086 (description "GNOME MPV is a simple GTK+ frontend for the mpv media player.
1087GNOME MPV interacts with mpv via the client API exported by libmpv, allowing
1088access to mpv's powerful playback capabilities.")
1089 (license license:gpl3+)))
1090
d0ed39be
DT
1091(define-public libvpx
1092 (package
1093 (name "libvpx")
65064909 1094 (version "1.6.1")
d0ed39be
DT
1095 (source (origin
1096 (method url-fetch)
723e8866
MW
1097 (uri (string-append "http://storage.googleapis.com/"
1098 "downloads.webmproject.org/releases/webm/"
1099 name "-" version ".tar.bz2"))
d0ed39be
DT
1100 (sha256
1101 (base32
65064909 1102 "06d8hqjkfs6wl45qf4pwh1kpbvkx6cwywd5y8d4lgagvjwm0qb0w"))
c7c49446 1103 (patches (search-patches "libvpx-CVE-2016-2818.patch"))))
d0ed39be
DT
1104 (build-system gnu-build-system)
1105 (arguments
0e47b4e7
EF
1106 `(#:phases
1107 (modify-phases %standard-phases
1108 (replace 'configure
1109 (lambda* (#:key outputs #:allow-other-keys)
1110 (setenv "CONFIG_SHELL" (which "bash"))
1111 (let ((out (assoc-ref outputs "out")))
1112 (setenv "LDFLAGS"
1113 (string-append "-Wl,-rpath=" out "/lib"))
1114 (zero? (system* "./configure"
1115 "--enable-shared"
1116 "--as=yasm"
1117 ;; Limit size to avoid CVE-2015-1258
1118 "--size-limit=16384x16384"
1119 (string-append "--prefix=" out)))))))
4f8f15cd 1120 #:tests? #f)) ; no check target
d0ed39be
DT
1121 (native-inputs
1122 `(("perl" ,perl)
1123 ("yasm" ,yasm)))
1124 (synopsis "VP8/VP9 video codec")
1125 (description "libvpx is a codec for the VP8/VP9 video compression format.")
ae0bdd81 1126 (license license:bsd-3)
d0ed39be 1127 (home-page "http://www.webmproject.org/")))
615215a5
LC
1128
1129(define-public youtube-dl
1130 (package
1131 (name "youtube-dl")
2a222b7a 1132 (version "2017.12.23")
615215a5
LC
1133 (source (origin
1134 (method url-fetch)
39dc7032 1135 (uri (string-append "https://yt-dl.org/downloads/"
615215a5
LC
1136 version "/youtube-dl-"
1137 version ".tar.gz"))
1138 (sha256
1139 (base32
2a222b7a 1140 "12m1bjdqm9bsc1f5psnzc203avzwr070xpdr6fqr728am536q845"))))
615215a5 1141 (build-system python-build-system)
2ad9515c
AV
1142 (arguments
1143 ;; The problem here is that the directory for the man page and completion
1144 ;; files is relative, and for some reason, setup.py uses the
1145 ;; auto-detected sys.prefix instead of the user-defined "--prefix=FOO".
1146 ;; So, we need pass the prefix directly. In addition, make sure the Bash
1147 ;; completion file is called 'youtube-dl' rather than
1148 ;; 'youtube-dl.bash-completion'.
31c58006
LF
1149 `(#:tests? #f ; Many tests fail. The test suite can be run with pytest.
1150 #:phases (modify-phases %standard-phases
2ad9515c
AV
1151 (add-before 'install 'fix-the-data-directories
1152 (lambda* (#:key outputs #:allow-other-keys)
1153 (let ((prefix (assoc-ref outputs "out")))
1154 (mkdir "bash-completion")
1155 (rename-file "youtube-dl.bash-completion"
1156 "bash-completion/youtube-dl")
1157 (substitute* "setup.py"
1158 (("youtube-dl\\.bash-completion")
1159 "bash-completion/youtube-dl")
1160 (("'etc/")
1161 (string-append "'" prefix "/etc/"))
1162 (("'share/")
1163 (string-append "'" prefix "/share/")))))))))
615215a5
LC
1164 (synopsis "Download videos from YouTube.com and other sites")
1165 (description
b798dfde 1166 "Youtube-dl is a small command-line program to download videos from
615215a5 1167YouTube.com and a few more sites.")
39dc7032 1168 (home-page "https://yt-dl.org")
ae0bdd81 1169 (license license:public-domain)))
e6bdb36a 1170
794223bc
CM
1171(define-public youtube-dl-gui
1172 (package
1173 (name "youtube-dl-gui")
1174 (version "0.3.8")
1175 (source
1176 (origin
1177 (method url-fetch)
1178 (uri (pypi-uri "Youtube-DLG" version))
1179 (sha256
1180 (base32
1181 "0napxwzgls5ik1bxbp99vly32l23xpc4ng5kr24hfhf21ypjyadb"))))
1182 (build-system python-build-system)
1183 (arguments
1184 ;; In Guix, wxpython has not yet been packaged for Python 3.
1185 `(#:python ,python-2
1186 ;; This package has no tests.
1187 #:tests? #f
1188 #:phases
1189 (modify-phases %standard-phases
1190 (add-before 'build 'patch-source
1191 (lambda* (#:key inputs #:allow-other-keys)
1192 ;; The youtube-dl-gui program lets you configure options. Some of
1193 ;; them are problematic, so we change their defaults.
1194 (substitute* "youtube_dl_gui/optionsmanager.py"
1195 ;; When this is true, the builder process will try (and fail) to
1196 ;; write logs to the builder user's home directory.
1197 (("'enable_log': True") "'enable_log': False")
1198 ;; This determines which youtube-dl program youtube-dl-gui will
1199 ;; run. If we don't set this, then youtube-dl-gui might download
1200 ;; an arbitrary copy from the Internet into the user's home
1201 ;; directory and run it, so let's make sure youtube-dl-gui uses
1202 ;; the youtube-dl from the inputs by default.
1203 (("'youtubedl_path': self.config_path")
1204 (string-append "'youtubedl_path': '"
1205 (assoc-ref inputs "youtube-dl")
1206 "/bin'"))
1207 ;; When this is True, when youtube-dl-gui is finished downloading
1208 ;; a file, it will try (and possibly fail) to open the directory
1209 ;; containing the downloaded file. This can fail because it
1210 ;; assumes that xdg-open is in PATH. Unfortunately, simply
1211 ;; adding xdg-utils to the propagated inputs is not enough to
1212 ;; make this work, so for now we set the default to False.
1213 (("'open_dl_dir': True") "'open_dl_dir': False"))
1214 ;; The youtube-dl program from the inputs is actually a wrapper
1215 ;; script written in bash, so attempting to invoke it as a python
1216 ;; script will fail.
1217 (substitute* "youtube_dl_gui/downloaders.py"
1218 (("cmd = \\['python', self\\.youtubedl_path\\]")
1219 "cmd = [self.youtubedl_path]"))
1220 ;; Use relative paths for installing data files so youtube-dl-gui
1221 ;; installs the files relative to its prefix in the store, rather
1222 ;; than relative to /. Also, instead of installing data files into
1223 ;; $prefix/usr/share, install them into $prefix/share for
1224 ;; consistency (see: (standards) Directory Variables).
1225 (substitute* "setup.py"
1226 (("= '/usr/share") "= 'share"))
1227 ;; Update get_locale_file() so it finds the installed localization
1228 ;; files.
1229 (substitute* "youtube_dl_gui/utils.py"
1230 (("os\\.path\\.join\\('/usr', 'share'")
1231 (string-append "os.path.join('"
1232 (assoc-ref %outputs "out")
1233 "', 'share'"))))))))
1234 (inputs
1235 `(("python2-wxpython" ,python2-wxpython)
1236 ("youtube-dl" ,youtube-dl)))
1237 (home-page "https://github.com/MrS0m30n3/youtube-dl-gui")
1238 (synopsis
1239 "GUI (Graphical User Interface) for @command{youtube-dl}")
1240 (description
1241 "Youtube-dlG is a GUI (Graphical User Interface) for
1242@command{youtube-dl}. You can use it to download videos from YouTube and any
1243other site that youtube-dl supports.")
1244 (license license:unlicense)))
1245
72fa6667
FS
1246(define-public you-get
1247 (package
1248 (name "you-get")
86178675 1249 (version "0.4.1011")
72fa6667
FS
1250 (source (origin
1251 (method url-fetch)
1252 (uri (string-append
e2155f58
FS
1253 "https://github.com/soimort/you-get/archive/v"
1254 version ".tar.gz"))
1255 (file-name (string-append name "-" version ".tar.gz"))
72fa6667
FS
1256 (sha256
1257 (base32
86178675 1258 "0cdbh5w0chw3dlrwizm91l6sgkkzy7p6h0072dai4xbw5zgld31k"))))
72fa6667 1259 (build-system python-build-system)
72fa6667 1260 (inputs
5e84eab0
TGR
1261 `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos
1262 (arguments
1263 `(#:phases
1264 (modify-phases %standard-phases
1265 (add-after 'unpack 'qualify-input-references
1266 ;; Explicitly invoke the input ffmpeg, instead of whichever one
1267 ;; happens to be in the user's $PATH at run time.
1268 (lambda* (#:key inputs #:allow-other-keys)
1269 (let ((ffmpeg (string-append (assoc-ref inputs "ffmpeg")
1270 "/bin/ffmpeg")))
1271 (substitute* "src/you_get/processor/ffmpeg.py"
1272 ;; Don't blindly replace all occurrences of ‘'ffmpeg'’: the
1273 ;; same string is also used when sniffing ffmpeg's output.
1274 (("(FFMPEG == |\\()'ffmpeg'" _ prefix)
1275 (string-append prefix "'" ffmpeg "'")))
1276 #t))))
1277 #:tests? #f)) ; XXX some tests need Internet access
817e91bc 1278 (synopsis "Download videos, audio, or images from Web sites")
72fa6667
FS
1279 (description
1280 "You-Get is a command-line utility to download media contents (videos,
1281audio, images) from the Web. It can use either mpv or vlc for playback.")
1282 (home-page "https://you-get.org/")
1283 (license license:expat)))
1284
5d3609e4
TUBK
1285(define-public libbluray
1286 (package
1287 (name "libbluray")
d76e2634 1288 (version "1.0.1")
5d3609e4
TUBK
1289 (source (origin
1290 (method url-fetch)
5e3f68e6 1291 (uri (string-append "https://download.videolan.org/videolan/"
5d3609e4
TUBK
1292 name "/" version "/"
1293 name "-" version ".tar.bz2"))
1294 (sha256
1295 (base32
d76e2634 1296 "0fl5cxfj870rwqmmz3s04wh7wnabb7rnynfj1v3sz37ln8frm7qg"))))
5d3609e4 1297 (build-system gnu-build-system)
6c0cd765 1298 (arguments
d76e2634 1299 `(#:configure-flags '("--disable-bdjava-jar")
6c0cd765
AP
1300 #:phases
1301 (modify-phases %standard-phases
1302 (add-before 'build 'fix-dlopen-paths
1303 (lambda* (#:key inputs #:allow-other-keys)
1304 (let ((libaacs (assoc-ref inputs "libaacs"))
1305 (libbdplus (assoc-ref inputs "libbdplus")))
1306 (substitute* "src/libbluray/disc/aacs.c"
1307 (("\"libaacs\"")
1308 (string-append "\"" libaacs "/lib/libaacs\"")))
1309 (substitute* "src/libbluray/disc/bdplus.c"
1310 (("\"libbdplus\"")
1311 (string-append "\"" libbdplus "/lib/libbdplus\"")))
1312 #t))))))
2da45ebe 1313 (native-inputs `(("pkg-config" ,pkg-config)))
5d3609e4 1314 (inputs
71ee51a0 1315 `(("fontconfig" ,fontconfig)
5d3609e4 1316 ("freetype" ,freetype)
6c0cd765
AP
1317 ("libaacs" ,libaacs)
1318 ("libbdplus" ,libbdplus)
71ee51a0 1319 ("libxml2" ,libxml2)))
5e3f68e6 1320 (home-page "https://www.videolan.org/developers/libbluray.html")
5d3609e4
TUBK
1321 (synopsis "Blu-Ray Disc playback library")
1322 (description
1323 "libbluray is a library designed for Blu-Ray Disc playback for media
1324players, like VLC or MPlayer.")
ae0bdd81 1325 (license license:lgpl2.1+)))
5d3609e4 1326
e6bdb36a
AE
1327(define-public libdvdread
1328 (package
1329 (name "libdvdread")
9aebf330 1330 (version "5.0.3")
e6bdb36a
AE
1331 (source (origin
1332 (method url-fetch)
b8a31908 1333 (uri (string-append "https://download.videolan.org/videolan/"
e6bdb36a
AE
1334 name "/" version "/"
1335 name "-" version ".tar.bz2"))
1336 (sha256
1337 (base32
9aebf330 1338 "0ayqiq0psq18rcp6f5pz82sxsq66v0kwv0y55dbrcg68plnxy71j"))))
e6bdb36a
AE
1339 (build-system gnu-build-system)
1340 (home-page "http://dvdnav.mplayerhq.hu/")
1341 (synopsis "Library for reading video DVDs")
1342 (description
1343 "Libdvdread provides a simple foundation for reading DVD video
1344disks. It provides the functionality that is required to access many
1345DVDs. It parses IFO files, reads NAV-blocks, and performs CSS
1346authentication and descrambling (if an external libdvdcss library is
1347installed).")
ae0bdd81 1348 (license license:gpl2+)))
b027d919 1349
b5b20bda
TD
1350(define-public dvdauthor
1351 (package
1352 (name "dvdauthor")
1353 (version "0.7.2")
1354 (source
1355 (origin
1356 (method url-fetch)
1357 (uri (string-append "mirror://sourceforge/dvdauthor/dvdauthor-"
1358 version ".tar.gz"))
1359 (sha256
1360 (base32
1361 "1drfc47hikfzc9d7hjk34rw10iqw01d2vwmn91pv73ppx4nsj81h"))))
1362 (build-system gnu-build-system)
1363 (inputs
1364 `(("libdvdread" ,libdvdread)
1365 ("libpng" ,libpng)
1366 ("imagemagick" ,imagemagick)
1367 ("libxml2" ,libxml2)
1368 ("freetype" ,freetype)))
1369 (native-inputs
1370 `(("pkg-config" ,pkg-config)))
1371 (synopsis "Generates a DVD-Video movie from a MPEG-2 stream")
1372 (description "@command{dvdauthor} will generate a DVD-Video movie from a
1373MPEG-2 stream containing VOB packets.")
1374 (home-page "http://dvdauthor.sourceforge.net")
1375 (license license:gpl3+)))
1376
b027d919
AE
1377(define-public libdvdnav
1378 (package
1379 (name "libdvdnav")
734976b6 1380 (version "5.0.3")
b027d919
AE
1381 (source (origin
1382 (method url-fetch)
b8a31908 1383 (uri (string-append "https://download.videolan.org/videolan/"
b027d919
AE
1384 name "/" version "/"
1385 name "-" version ".tar.bz2"))
1386 (sha256
1387 (base32
734976b6 1388 "0v8byv5z598k06rqzdmj7739vc86xq3zf79zfr698dib7lz055sh"))))
b027d919
AE
1389 (build-system gnu-build-system)
1390 (native-inputs
1391 `(("pkg-config" ,pkg-config)))
1392 (inputs
1393 `(("libdvdread" ,libdvdread)))
1394 (home-page "http://dvdnav.mplayerhq.hu/")
1395 (synopsis "Library for video DVD navigation features")
1396 (description
1397 "Libdvdnav is a library for developers of multimedia
1398applications. It allows easy use of sophisticated DVD navigation features
1399such as DVD menus, multiangle playback and even interactive DVD games. All
1400this functionality is provided through a simple API which provides the DVD
1401playback as a single logical stream of blocks, intermitted by special
1402dvdnav events to report certain conditions. The main usage of libdvdnav is
1403a loop regularly calling a function to get the next block, surrounded by
1404additional calls to tell the library of user interaction. The whole
1405DVD virtual machine and internal playback states are completely
1406encapsulated.")
ae0bdd81 1407 (license license:gpl2+)))
2cd85cf9 1408
f1044010
TUBK
1409(define-public libdvdnav-4
1410 (package
1411 (inherit libdvdnav)
1412 (version "4.2.1")
1413 (source (origin
1414 (method url-fetch)
1415 (uri
1416 (string-append
b8a31908 1417 "https://download.videolan.org/videolan/libdvdnav/libdvdnav-"
f1044010
TUBK
1418 version ".tar.xz"))
1419 (sha256
1420 (base32
1421 "0wi3gy408c8xj0ism0hckv5jbfh3lg4pmgxv87gbch9jrhp2gjkz"))))
1422 (native-inputs
1423 `(("pkg-config" ,pkg-config)
1424 ("autoconf" ,autoconf)
1425 ("automake" ,automake)
1426 ("libtool" ,libtool)))
1427 (arguments
1428 '(#:phases
dc1d3cde
KK
1429 (modify-phases %standard-phases
1430 (add-after 'unpack 'autoreconf
1431 (lambda _
1432 (zero? (system* "autoreconf" "-vif")))))))))
f1044010 1433
a6f710ec
TUBK
1434(define-public libdvdcss
1435 (package
1436 (name "libdvdcss")
98416109 1437 (version "1.4.0")
a6f710ec
TUBK
1438 (source (origin
1439 (method url-fetch)
b8a31908 1440 (uri (string-append "https://download.videolan.org/pub/"
a6f710ec
TUBK
1441 name "/" version "/"
1442 name "-" version ".tar.bz2"))
1443 (sha256
1444 (base32
98416109 1445 "0nl45ifc4xcb196snv9d6hinfw614cqpzcqp92dg43c0hickg290"))))
a6f710ec 1446 (build-system gnu-build-system)
b8a31908 1447 (home-page "https://www.videolan.org/developers/libdvdcss.html")
a6f710ec
TUBK
1448 (synopsis "Library for accessing DVDs as block devices")
1449 (description
1450 "libdvdcss is a simple library designed for accessing DVDs like a block
1451device without having to bother about the decryption.")
ae0bdd81 1452 (license license:gpl2+)))
a6f710ec 1453
2cd85cf9
DT
1454(define-public srt2vtt
1455 (package
1456 (name "srt2vtt")
1457 (version "0.1")
1458 (source (origin
1459 (method url-fetch)
1460 (uri (string-append
152fc959 1461 "https://files.dthompson.us/srt2vtt/srt2vtt-"
2cd85cf9
DT
1462 version ".tar.gz"))
1463 (sha256
1464 (base32
1465 "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif"))))
1466 (build-system gnu-build-system)
1467 (inputs
1468 `(("guile" ,guile-2.0)))
1469 (synopsis "SubRip to WebVTT subtitle converter")
1470 (description "srt2vtt converts SubRip formatted subtitles to WebVTT format
1471for use with HTML5 video.")
1472 (home-page "http://dthompson.us/pages/software/srt2vtt")
ae0bdd81 1473 (license license:gpl3+)))
44726031
AE
1474
1475(define-public avidemux
1476 (package
1477 (name "avidemux")
9e786e8b 1478 (version "2.6.12")
44726031
AE
1479 (source (origin
1480 (method url-fetch)
1481 (uri (string-append
de67e922
LF
1482 "mirror://sourceforge/" name "/" name "/" version "/"
1483 name "_" version ".tar.gz"))
44726031
AE
1484 (sha256
1485 (base32
9e786e8b 1486 "0nz52yih8sff53inndkh2dba759xjzsh4b8xjww419lcpk0qp6kn"))
fc1adab1 1487 (patches (search-patches "avidemux-install-to-lib.patch"))))
44726031
AE
1488 (build-system cmake-build-system)
1489 (native-inputs
1490 `(("pkg-config" ,pkg-config)))
1491 ;; FIXME: Once packaged, add libraries not found during the build.
1492 (inputs
1493 `(("alsa-lib" ,alsa-lib)
1494 ("fontconfig" ,fontconfig)
1495 ("freetype" ,freetype)
1496 ("fribidi" ,fribidi)
1497 ("glu" ,glu)
44726031
AE
1498 ("jack" ,jack-1)
1499 ("lame" ,lame)
4cafe8ad
EF
1500 ("libva" ,libva)
1501 ("libvdpau" ,libvdpau)
44726031
AE
1502 ("libvorbis" ,libvorbis)
1503 ("libvpx" ,libvpx)
1504 ("libxv" ,libxv)
1505 ("perl" ,perl)
1506 ("pulseaudio" ,pulseaudio)
1507 ("python" ,python-wrapper)
a2c24bf5
DC
1508 ("qt" ,qt) ; FIXME: reenable modular qt after update - requires building
1509 ;("qtbase" ,qtbase) with -std=gnu++11.
1510 ;("qttools" ,qttools)
44726031
AE
1511 ("sdl" ,sdl)
1512 ("sqlite" ,sqlite)
1513 ("yasm" ,yasm)
1514 ("zlib" ,zlib)))
1515 (arguments
1516 `(#:tests? #f ; no check target
1517 #:phases
1518 ;; Make sure files inside the included ffmpeg tarball are
1519 ;; patch-shebanged.
1898900f
EF
1520 (modify-phases %standard-phases
1521 (add-before 'patch-source-shebangs 'unpack-ffmpeg
44726031
AE
1522 (lambda _
1523 (with-directory-excursion "avidemux_core/ffmpeg_package"
1898900f
EF
1524 (system* "tar" "xf" "ffmpeg-2.7.6.tar.bz2")
1525 (delete-file "ffmpeg-2.7.6.tar.bz2"))))
1526 (add-after 'patch-source-shebangs 'repack-ffmpeg
44726031
AE
1527 (lambda _
1528 (with-directory-excursion "avidemux_core/ffmpeg_package"
9e786e8b 1529 (substitute* "ffmpeg-2.7.6/configure"
2fed4042 1530 (("#! /bin/sh") (string-append "#!" (which "sh"))))
9e786e8b 1531 (system* "tar" "cjf" "ffmpeg-2.7.6.tar.bz2" "ffmpeg-2.7.6"
c09e6a5f 1532 ;; avoid non-determinism in the archive
92226a47
MW
1533 "--sort=name" "--mtime=@0"
1534 "--owner=root:0" "--group=root:0")
1898900f
EF
1535 (delete-file-recursively "ffmpeg-2.7.6"))))
1536 (replace 'configure
1537 (lambda _
1538 ;; Copy-paste settings from the cmake build system.
1539 (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH"))
1540 (setenv "CMAKE_INCLUDE_PATH" (getenv "C_INCLUDE_PATH"))))
1541 (replace 'build
1542 (lambda* (#:key inputs outputs #:allow-other-keys)
1543 (let*
1544 ((out (assoc-ref outputs "out"))
1545 (lib (string-append out "/lib"))
1546 (top (getcwd))
1547 (sdl (assoc-ref inputs "sdl"))
1548 (build_component
1549 (lambda* (component srcdir #:optional (args '()))
1550 (let ((builddir (string-append "build_" component)))
1551 (mkdir builddir)
1552 (with-directory-excursion builddir
1553 (zero?
1554 (and
44726031
AE
1555 (apply system* "cmake"
1556 "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE"
1557 (string-append "-DCMAKE_INSTALL_PREFIX=" out)
1558 (string-append "-DCMAKE_INSTALL_RPATH=" lib)
c687f731
AE
1559 (string-append "-DCMAKE_SHARED_LINKER_FLAGS="
1560 "\"-Wl,-rpath=" lib "\"")
44726031
AE
1561 (string-append "-DAVIDEMUX_SOURCE_DIR=" top)
1562 (string-append "-DSDL_INCLUDE_DIR="
1563 sdl "/include/SDL")
1564 (string-append "../" srcdir)
aab56ab7 1565 "-DENABLE_QT5=True"
44726031 1566 args)
1898900f
EF
1567 (system* "make" "-j"
1568 (number->string (parallel-job-count)))
1569 (system* "make" "install"))))))))
1570 (mkdir out)
1571 (and (build_component "core" "avidemux_core")
1572 (build_component "cli" "avidemux/cli")
1573 (build_component "qt4" "avidemux/qt4")
1574 (build_component "plugins_common" "avidemux_plugins"
1575 '("-DPLUGIN_UI=COMMON"))
1576 (build_component "plugins_cli" "avidemux_plugins"
1577 '("-DPLUGIN_UI=CLI"))
1578 (build_component "plugins_qt4" "avidemux_plugins"
1579 '("-DPLUGIN_UI=QT4"))
1580 (build_component "plugins_settings" "avidemux_plugins"
1581 '("-DPLUGIN_UI=SETTINGS")))
1582 ;; Remove .exe and .dll file.
1583 (delete-file-recursively
1584 (string-append out "/share/ADM6_addons")))))
1585 (delete 'install))))
44726031
AE
1586 (home-page "http://fixounet.free.fr/avidemux/")
1587 (synopsis "Video editor")
1588 (description "Avidemux is a video editor designed for simple cutting,
1589filtering and encoding tasks. It supports many file types, including AVI,
1590DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks
1591can be automated using projects, job queue and powerful scripting
1592capabilities.")
afd9ed5c 1593 (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"))
44726031 1594 ;; Software with various licenses is included, see License.txt.
ae0bdd81 1595 (license license:gpl2+)))
44726031 1596
6f6c8b65
TUBK
1597(define-public vapoursynth
1598 (package
1599 (name "vapoursynth")
4f7a9e0b 1600 (version "37")
6f6c8b65
TUBK
1601 (source (origin
1602 (method url-fetch)
1603 (uri (string-append
1604 "https://github.com/vapoursynth/vapoursynth/archive/R"
1605 version ".tar.gz"))
0b37c4cd 1606 (file-name (string-append name "-" version ".tar.gz"))
6f6c8b65
TUBK
1607 (sha256
1608 (base32
4f7a9e0b 1609 "1g3hc079jw4mz1cmkv2y28pdb556wqc8ql7iravgh1rg8j3f1zi5"))))
6f6c8b65
TUBK
1610 (build-system gnu-build-system)
1611 (native-inputs
1612 `(("autoconf" ,autoconf)
1613 ("automake" ,automake)
1614 ("cython" ,python-cython)
1615 ("libtool" ,libtool)
1616 ("pkg-config" ,pkg-config)
1617 ("python" ,python)
1618 ("yasm" ,yasm)))
1619 (inputs
1620 `(("ffmpeg" ,ffmpeg)
1621 ("libass" ,libass)
f80d5fe0
EF
1622 ("tesseract-ocr" ,tesseract-ocr)
1623 ("zimg" ,zimg)))
6f6c8b65
TUBK
1624 (arguments
1625 '(#:phases
1626 (modify-phases %standard-phases
1627 (add-after
f8503e2b 1628 'unpack 'autogen
6f6c8b65
TUBK
1629 (lambda _
1630 (zero? (system* "sh" "autogen.sh")))))))
1631 (home-page "http://www.vapoursynth.com/")
1632 (synopsis "Video processing framework")
1633 (description "VapourSynth is a C++ library and Python module for video
1634manipulation. It aims to be a modern rewrite of Avisynth, supporting
1635multithreading, generalized colorspaces, per frame properties, and videos with
1636format changes.")
9a078f48 1637 ;; src/core/cpufeatures only allows x86, ARM or PPC
cda20ee8
EF
1638 (supported-systems (fold delete %supported-systems
1639 '("mips64el-linux" "aarch64-linux")))
6f6c8b65 1640 ;; As seen from the source files.
ae0bdd81 1641 (license license:lgpl2.1+)))
6f6c8b65 1642
67932f86
TUBK
1643(define-public xvid
1644 (package
1645 (name "xvid")
e05035c7 1646 (version "1.3.4")
67932f86
TUBK
1647 (source (origin
1648 (method url-fetch)
1649 (uri (string-append
1650 "http://downloads.xvid.org/downloads/xvidcore-"
1651 version ".tar.bz2"))
1652 (sha256
1653 (base32
e05035c7 1654 "1xwbmp9wqshc0ckm970zdpi0yvgqxlqg0s8bkz98mnr8p2067bsz"))))
67932f86
TUBK
1655 (build-system gnu-build-system)
1656 (native-inputs `(("yasm" ,yasm)))
1657 (arguments
1658 '(#:phases
62fe2d47
EF
1659 (modify-phases %standard-phases
1660 (add-before
1661 'configure 'pre-configure
1662 (lambda _
1663 (chdir "build/generic")
1664 (substitute* "configure"
1665 (("#! /bin/sh") (string-append "#!" (which "sh")))))))
67932f86
TUBK
1666 ;; No 'check' target.
1667 #:tests? #f))
1668 (home-page "https://www.xvid.com/")
1669 (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec")
1670 (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video
1671codec library. It uses ASP features such as b-frames, global and quarter
1672pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG
1673and custom quantization matrices.")
ae0bdd81 1674 (license license:gpl2+)))
e16fde14
DT
1675
1676(define-public livestreamer
1677 (package
1678 (name "livestreamer")
68e88a09 1679 (version "1.12.2")
e16fde14
DT
1680 (source (origin
1681 (method url-fetch)
1682 (uri (string-append
1683 "https://github.com/chrippa/livestreamer/archive/v"
1684 version ".tar.gz"))
1685 (file-name (string-append "livestreamer-" version ".tar.gz"))
1686 (sha256
1687 (base32
68e88a09 1688 "1fp3d3z2grb1ls97smjkraazpxnvajda2d1g1378s6gzmda2jvjd"))))
e16fde14
DT
1689 (build-system python-build-system)
1690 (arguments
1691 '(#:tests? #f)) ; tests rely on external web servers
e16fde14 1692 (propagated-inputs
5b9fe59f 1693 `(("python-requests" ,python-requests)))
e16fde14
DT
1694 (synopsis "Internet video stream viewer")
1695 (description "Livestreamer is a command-line utility that extracts streams
1696from various services and pipes them into a video playing application.")
1697 (home-page "http://livestreamer.io/")
1698 (license license:bsd-2)))
307ad140
RW
1699
1700(define-public mlt
1701 (package
1702 (name "mlt")
f05f5b30 1703 (version "6.4.1")
307ad140
RW
1704 (source (origin
1705 (method url-fetch)
4c7729dc
EF
1706 (uri (string-append "https://github.com/mltframework/mlt/"
1707 "archive/v" version ".tar.gz"))
1708 (file-name (string-append name "-" version ".tar.gz"))
307ad140
RW
1709 (sha256
1710 (base32
f05f5b30 1711 "10m3ry0b2pvqx3bk34qh5dq337nn8pkc2gzfyhsj4nv9abskln47"))))
307ad140
RW
1712 (build-system gnu-build-system)
1713 (arguments
1714 `(#:tests? #f ; no tests
1715 #:make-flags '("CC=gcc")
1716 #:configure-flags
1717 (list "--enable-gpl3"
1718 "--enable-gpl")
1719 #:phases
1720 (modify-phases %standard-phases
1721 (add-after
1722 'configure 'override-LDFLAGS
1723 (lambda* (#:key outputs #:allow-other-keys)
1724 (substitute* "config.mak"
1725 (("LDFLAGS\\+=")
1726 (string-append "LDFLAGS+=-Wl,-rpath="
1727 (assoc-ref outputs "out")
1728 "/lib ")))
1729 #t)))))
1730 (inputs
1731 `(("alsa-lib" ,alsa-lib)
1732 ("fftw" ,fftw)
1733 ("libxml2" ,libxml2)
1734 ("jack" ,jack-1)
1735 ("ladspa" ,ladspa)
1736 ("libsamplerate" ,libsamplerate)
4c7729dc 1737 ("pulseaudio" ,pulseaudio)
307ad140
RW
1738 ("sdl" ,sdl)
1739 ("sox" ,sox)))
1740 (native-inputs
1741 `(("pkg-config" ,pkg-config)))
4c7729dc 1742 (home-page "https://www.mltframework.org/")
307ad140
RW
1743 (synopsis "Author, manage, and run multitrack audio/video compositions")
1744 (description
1745 "MLT is a multimedia framework, designed and developed for television
1746broadcasting. It provides a toolkit for broadcasters, video editors, media
1747players, transcoders, web streamers and many more types of applications. The
1748functionality of the system is provided via an assortment of ready to use
1749tools, XML authoring components, and an extensible plug-in based API.")
1750 (license license:lgpl2.1+)))
f464016d 1751
945d985a
DT
1752(define-public v4l-utils
1753 (package
1754 (name "v4l-utils")
f1d1ef71 1755 (version "1.12.5")
945d985a
DT
1756 (source (origin
1757 (method url-fetch)
1d4ac724 1758 (uri (string-append "https://linuxtv.org/downloads/v4l-utils"
945d985a
DT
1759 "/v4l-utils-" version ".tar.bz2"))
1760 (sha256
1761 (base32
f1d1ef71 1762 "03g2b4rivrilimcp57mwrlsa3qvrxmk4sza08mygwmqbvcnic606"))))
945d985a
DT
1763 (build-system gnu-build-system)
1764 (arguments
1765 '(#:configure-flags
1766 (list (string-append "--with-udevdir="
1767 (assoc-ref %outputs "out")
2cef0f7c
DC
1768 "/lib/udev")
1769 "CXXFLAGS=-std=gnu++11")))
945d985a 1770 (native-inputs
4ca077d5
TGR
1771 `(("perl" ,perl)
1772 ("pkg-config" ,pkg-config)))
945d985a
DT
1773 (inputs
1774 `(("alsa-lib" ,alsa-lib)
1775 ("glu" ,glu)
1776 ("libjpeg" ,libjpeg)
1777 ("libx11" ,libx11)
b37662e2 1778 ("qtbase" ,qtbase)
945d985a
DT
1779 ("eudev" ,eudev)))
1780 (synopsis "Realtime video capture utilities for Linux")
1781 (description "The v4l-utils provide a series of libraries and utilities to
1782be used for realtime video capture via Linux-specific APIs.")
1783 (home-page "https://linuxtv.org/wiki/index.php/V4l-utils")
1784 ;; libv4l2 is LGPL2.1+, while utilities are GPL2 only.
1785 (license (list license:lgpl2.1+ license:gpl2))))
1786
f464016d
DT
1787(define-public obs
1788 (package
1789 (name "obs")
341ccb0f 1790 (version "18.0.2")
f464016d
DT
1791 (source (origin
1792 (method url-fetch)
1793 (uri (string-append "https://github.com/jp9000/obs-studio"
1794 "/archive/" version ".tar.gz"))
1795 (file-name (string-append name "-" version ".tar.gz"))
1796 (sha256
1797 (base32
341ccb0f 1798 "02pbiyvf5x0zh448h5rpmyn33qnsqk694xxlyns83mdi74savyqw"))))
f464016d 1799 (build-system cmake-build-system)
08858812 1800 (arguments
f3bd1728 1801 `(#:tests? #f)) ; no tests
f464016d
DT
1802 (native-inputs
1803 `(("pkg-config" ,pkg-config)))
1804 (inputs
4f98c3c5
EF
1805 `(("alsa-lib" ,alsa-lib)
1806 ("curl" ,curl)
f464016d
DT
1807 ("eudev" ,eudev)
1808 ("ffmpeg" ,ffmpeg)
4f98c3c5 1809 ("fontconfig" ,fontconfig)
f464016d
DT
1810 ("freetype" ,freetype)
1811 ("jack" ,jack-1)
1812 ("jansson" ,jansson)
1813 ("libx264" ,libx264)
1814 ("libxcomposite" ,libxcomposite)
1815 ("mesa" ,mesa)
1816 ("pulseaudio" ,pulseaudio)
90a2309b
EF
1817 ("qtbase" ,qtbase)
1818 ("qtx11extras" ,qtx11extras)
4f98c3c5 1819 ("speex" ,speex)
d4df2032 1820 ("v4l-utils" ,v4l-utils)
f464016d
DT
1821 ("zlib" ,zlib)))
1822 (synopsis "Live streaming software")
1823 (description "Open Broadcaster Software provides a graphical interface for
1824video recording and live streaming. OBS supports capturing audio and video
1825from many input sources such as webcams, X11 (for screencasting), PulseAudio,
1826and JACK.")
1827 (home-page "https://obsproject.com")
f3bd1728 1828 (supported-systems '("x86_64-linux" "i686-linux"))
f464016d 1829 (license license:gpl2+)))
d5650f86
EF
1830
1831(define-public libvdpau
1832 (package
1833 (name "libvdpau")
1834 (version "1.1.1")
1835 (source
1836 (origin
1837 (method url-fetch)
1838 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
1839 name "-" version ".tar.bz2"))
1840 (sha256
1841 (base32
1842 "0dnpb0yh7v6rvckx82kxg045rd9rbsw25wjv7ad5n8h94s9h2yl5"))))
1843 (build-system gnu-build-system)
1844 (native-inputs
1845 `(("pkg-config" ,pkg-config)))
1846 (inputs
1847 `(("dri2proto" ,dri2proto)
1848 ("libx11" ,libx11 "out")
1849 ("libxext" ,libxext)))
1850 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
1851 (synopsis "Video Decode and Presentation API")
1852 (description "VDPAU is the Video Decode and Presentation API for UNIX. It
1853provides an interface to video decode acceleration and presentation hardware
1854present in modern GPUs.")
1855 (license (license:x11-style "file://COPYING"))))
3161d32d
EF
1856
1857(define-public vdpauinfo
1858 (package
1859 (name "vdpauinfo")
1860 (version "1.0")
1861 (source
1862 (origin
1863 (method url-fetch)
1864 (uri (string-append "https://secure.freedesktop.org/~aplattner/vdpau/"
1865 name "-" version ".tar.gz"))
1866 (sha256
1867 (base32
1868 "1i2b0k9h8r0lnxlrkgqzmrjakgaw3f1ygqqwzx8w6676g85rcm20"))))
1869 (build-system gnu-build-system)
1870 (native-inputs
1871 `(("pkg-config" ,pkg-config)
1872 ("libx11" ,libx11)))
1873 (propagated-inputs
1874 `(("libvdpau" ,libvdpau)))
1875 (home-page "https://wiki.freedesktop.org/www/Software/VDPAU/")
1876 (synopsis "Tool to query the capabilities of a VDPAU implementation")
1877 (description "Vdpauinfo is a tool to query the capabilities of a VDPAU
1878implementation.")
1879 (license (license:x11-style "file://COPYING"))))
a7d94b54 1880
67df7164
EF
1881(define-public libvdpau-va-gl
1882 (package
1883 (name "libvdpau-va-gl")
1884 (version "0.4.2")
1885 (source
1886 (origin
1887 (method url-fetch)
1888 (uri (string-append "https://github.com/i-rinat/libvdpau-va-gl/"
1889 "releases/download/v" version "/libvdpau-va-gl-"
1890 version ".tar.gz"))
1891 (sha256
1892 (base32
1893 "1x2ag1f2fwa4yh1g5spv99w9x1m33hbxlqwyhm205ssq0ra234bx"))
1894 (patches (search-patches "libvdpau-va-gl-unbundle.patch"))
1895 (modules '((guix build utils)))
1896 (snippet '(delete-file-recursively "3rdparty"))))
1897 (build-system cmake-build-system)
1898 (arguments
1899 '(#:tests? #f)) ; Tests require a running X11 server, with VA-API support.
1900 (native-inputs
1901 `(("libvdpau" ,libvdpau)
1902 ("pkg-config" ,pkg-config)))
1903 (inputs
1904 `(("libva" ,libva)
1905 ("mesa" ,mesa)))
1906 (home-page "https://github.com/i-rinat/libvdpau-va-gl")
1907 (synopsis "VDPAU driver with VA-API/OpenGL backend")
1908 (description
1909 "Many applications can use VDPAU to accelerate portions of the video
1910decoding process and video post-processing to the GPU video hardware. Since
1911there is no VDPAU available on Intel chips, they fall back to different drawing
1912techniques. This driver uses OpenGL under the hood to accelerate drawing and
1913scaling and VA-API (if available) to accelerate video decoding.")
1914 (license license:expat)))
1915
a7d94b54
LC
1916(define-public recordmydesktop
1917 (package
1918 (name "recordmydesktop")
1919 (version "0.3.8.1")
1920 (source (origin
1921 (method url-fetch)
1922 (uri (string-append "mirror://sourceforge/" name "/" name "/"
1923 version "/recordmydesktop-" version ".tar.gz"))
1924 (sha256
1925 (base32
1926 "133kkl5j0r877d41bzj7kj0vf3xm8x80yyx2n8nqxrva304f58ik"))))
1927 (build-system gnu-build-system)
1928 (inputs `(("popt" ,popt)
1929 ("zlib" ,zlib)
1930 ("libx11" ,libx11)
1931 ("libice" ,libice)
1932 ("libsm" ,libsm)
1933 ("libxfixes" ,libxfixes)
1934 ("libxdamage" ,libxdamage)
1935 ("libxext" ,libxext)
ed6ba9cc 1936 ("alsa-lib" ,alsa-lib)
a7d94b54
LC
1937 ("libvorbis" ,libvorbis)
1938 ("libtheora" ,libtheora)))
1939 (home-page "http://recordmydesktop.sourceforge.net/")
1940 (synopsis "Desktop session video recorder")
1941 (description
1942 "recordMyDesktop is a command-line tool that captures the activity in
1943your graphical desktop and encodes it as a video. This is a useful tool for
1944making @dfn{screencasts}.")
1945 (license license:gpl2+)))
d8841cc5 1946
63cd4d53
AV
1947(define-public simplescreenrecorder
1948 (package
1949 (name "simplescreenrecorder")
1950 (version "0.3.8")
1951 (source
1952 (origin
1953 (method url-fetch)
1954 (uri (string-append "https://github.com/MaartenBaert/ssr/archive/"
1955 version ".tar.gz"))
1956 (file-name (string-append name "-" version ".tar.gz"))
1957 (sha256
1958 (base32
1959 "0v8w35n8w772s08w7k0icynqdsdakbrcanbgx6j847bfqfsg21gg"))))
1960 (build-system gnu-build-system)
1961 ;; Although libx11, libxfixes, libxext are listed as build dependencies in
1962 ;; README.md, the program builds and functions properly without them.
1963 ;; As a result, they are omitted. Please add them back if problems appear.
1964 (inputs
1965 `(("alsa-lib" ,alsa-lib)
1966 ("ffmpeg" ,ffmpeg)
1967 ("glu" ,glu)
1968 ("jack" ,jack-1)
1969 ("libxi" ,libxi)
1970 ("pulseaudio" ,pulseaudio)
1971 ("qt" ,qt-4))) ; README.md: using Qt 5 causes some stability issues
1972 (native-inputs `(("pkg-config" ,pkg-config)))
1973 ;; Using HTTPS causes part of the page to be displayed improperly.
1974 (home-page "http://www.maartenbaert.be/simplescreenrecorder/")
1975 (synopsis "Screen recorder")
1976 (description "SimpleScreenRecorder is an easy to use screen recorder with
1977a graphical user interface. It supports recording the entire screen, or a
1978part of it, and allows encoding in many different codecs and file formats.
1979Other features include a live preview and live streaming.")
1980 (license (list license:gpl3+ ; most files
1981 license:zlib ; glinject/elfhacks.*
1982 license:isc ; glinject/*
1983 license:x11)))) ; build-aux/install-sh
1984
d8841cc5
KK
1985(define-public libsmpeg
1986 (package
1987 (name "libsmpeg")
1988 (version "0.4.5")
1989 (source (origin
1990 (method svn-fetch)
1991 (uri (svn-reference
1992 (url "svn://svn.icculus.org/smpeg/trunk/")
1993 (revision 401))) ; last revision before smpeg2 (for SDL 2.0)
b9af0564 1994 (file-name (string-append name "-" version "-checkout"))
d8841cc5
KK
1995 (sha256
1996 (base32
1997 "18yfkr70lr1x1hc8snn2ldnbzdcc7b64xmkqrfk8w59gpg7sl1xn"))))
1998 (build-system gnu-build-system)
1999 (arguments
2000 `(#:phases (modify-phases %standard-phases
2001 (add-after 'unpack 'autogen.sh
2002 (lambda _
2003 (zero? (system* "sh" "autogen.sh")))))))
2004 (native-inputs
2005 `(("autoconf" ,autoconf)
2006 ("automake" ,automake)))
2007 (inputs
2008 `(("sdl" ,sdl2)))
2009 (home-page "http://icculus.org/smpeg/")
2010 (synopsis "SDL MPEG decoding library")
2011 (description
2012 "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player library
2013with sound support. Video playback is based on the ubiquitous Berkeley MPEG
2014player, mpeg_play v2.2. Audio is played through a slightly modified mpegsound
2015library, part of splay v0.8.2. SMPEG supports MPEG audio (MP3), MPEG-1 video,
2016and MPEG system streams.")
2017 (license (list license:expat
2018 license:lgpl2.1
2019 license:lgpl2.1+
2020 license:gpl2))))
4df07622
AP
2021
2022(define-public libbdplus
2023 (package
2024 (name "libbdplus")
2025 (version "0.1.2")
2026 (source
2027 (origin
2028 (method url-fetch)
6f13c4fd 2029 (uri (string-append "https://ftp.videolan.org/pub/videolan/libbdplus/"
4df07622
AP
2030 version "/" name "-" version ".tar.bz2"))
2031 (sha256
2032 (base32 "02n87lysqn4kg2qk7d1ffrp96c44zkdlxdj0n16hbgrlrpiwlcd6"))))
2033 (inputs
2034 `(("libgcrypt" ,libgcrypt)))
2035 (build-system gnu-build-system)
b8a31908 2036 (home-page "https://www.videolan.org/developers/libbdplus.html")
4df07622
AP
2037 (synopsis "Library for decrypting certain Blu-Ray discs")
2038 (description "libbdplus is a library which implements the BD+ System
2039specifications.")
2040 (license license:lgpl2.1+)))
8dd6fc51
AP
2041
2042(define-public libaacs
2043 (package
2044 (name "libaacs")
ba58886a 2045 (version "0.9.0")
8dd6fc51
AP
2046 (source
2047 (origin
2048 (method url-fetch)
6c2481ef 2049 (uri (string-append "https://ftp.videolan.org/pub/videolan/libaacs/"
8dd6fc51
AP
2050 version "/" name "-" version ".tar.bz2"))
2051 (sha256
ba58886a 2052 (base32 "1kms92i0c7i1yl659kqjf19lm8172pnpik5lsxp19xphr74vvq27"))))
8dd6fc51
AP
2053 (inputs
2054 `(("libgcrypt" ,libgcrypt)))
2055 (native-inputs
2056 `(("bison" ,bison)
2057 ("flex" ,flex)))
2058 (build-system gnu-build-system)
b8a31908 2059 (home-page "https://www.videolan.org/developers/libaacs.html")
8dd6fc51
AP
2060 (synopsis "Library for decrypting certain Blu-Ray discs")
2061 (description "libaacs is a library which implements the Advanced Access
2062Content System specification.")
2063 (license license:lgpl2.1+)))
05234973 2064
2065(define-public mps-youtube
2066 (package
2067 (name "mps-youtube")
2068 (version "0.2.7.1")
2069 (source
2070 (origin
2071 (method url-fetch)
2072 (uri (string-append "https://github.com/mps-youtube/mps-youtube/"
2073 "archive/v" version ".tar.gz"))
2074 (file-name (string-append name "-" version ".tar.gz"))
2075 (sha256
2076 (base32
2077 "1s7h35yx6f0szf8mm8612ic913w3v05m2kwphjfcxnpq0ammhyci"))))
2078 (build-system python-build-system)
175d6264 2079 (arguments
2080 ;; Tests need to be disabled until #556 upstream is fixed. It reads as if the
2081 ;; test suite results differ depending on the country and also introduce
2082 ;; non-determinism in the tests.
2083 ;; https://github.com/mps-youtube/mps-youtube/issues/556
2084 `(#:tests? #f))
05234973 2085 (propagated-inputs
2086 `(("python-pafy" ,python-pafy)
2087 ("python-pygobject" ,python-pygobject))) ; For mpris2 support
2088 (home-page "https://github.com/mps-youtube/mps-youtube")
2089 (synopsis "Terminal based YouTube player and downloader")
2090 (description
2091 "@code{mps-youtube} is based on mps, a terminal based program to
2092search, stream and download music. This implementation uses YouTube as
2093a source of content and can play and download video as well as audio.
2094It can use either mpv or mplayer for playback, and for conversion of
2095formats ffmpeg or libav is used. Users should install one of the
2096supported players in addition to this package.")
2097 (license license:gpl3+)))
fe047e13
EB
2098
2099(define-public handbrake
2100 (package
2101 (name "handbrake")
2102 (version "0.10.5")
2103 (source (origin
2104 (method url-fetch)
2105 (uri (string-append "https://handbrake.fr/rotation.php?file="
2106 "HandBrake-" version ".tar.bz2"))
2107 (file-name (string-append "handbrake-" version ".tar.bz2"))
2108 (sha256
2109 (base32
2110 "1w720y3bplkz187wgvy4a4xm0vpppg45mlni55l6yi8v2bfk14pv"))
2111 (patches (search-patches "handbrake-pkg-config-path.patch"))
2112 (modules '((guix build utils)))
2113 (snippet
2114 ;; Remove bundled libraries and source not necessary for
2115 ;; running under a GNU environment.
2116 '(begin
2117 (for-each delete-file-recursively '("contrib" "macosx" "win"))
2118 #t))))
2119 (build-system glib-or-gtk-build-system)
2120 (native-inputs
2121 `(("automake" ,automake) ;gui subpackage must be bootstrapped
2122 ("autoconf" ,autoconf)
2123 ("curl" ,curl) ;not actually used, but tested for
2124 ("intltool" ,intltool)
2125 ("libtool" ,libtool)
2126 ("pkg-config" ,pkg-config)
2127 ("python" ,python-2))) ;for configuration
2128 (inputs
2129 `(("bzip2" ,bzip2)
2130 ("dbus-glib" ,dbus-glib)
2131 ("ffmpeg" ,ffmpeg)
2132 ("fontconfig" ,fontconfig)
2133 ("freetype" ,freetype)
2134 ("glib" ,glib)
2135 ("gstreamer" ,gstreamer)
2136 ("gst-plugins-base" ,gst-plugins-base)
2137 ("gtk+" ,gtk+)
2138 ("lame" ,lame)
2139 ("libass" ,libass)
2140 ("libbluray" ,libbluray)
2141 ("libdvdnav" ,libdvdnav)
2142 ("libdvdread" ,libdvdread)
2143 ("libgudev" ,libgudev)
2144 ("libmpeg2" ,libmpeg2)
2145 ("libnotify" ,libnotify)
2146 ("libogg" ,libogg)
2147 ("libsamplerate" ,libsamplerate)
2148 ("libtheora" ,libtheora)
2149 ("libvorbis" ,libvorbis)
2150 ("libvpx" ,libvpx)
2151 ("libxml2" ,libxml2)
2152 ("libx264" ,libx264)
2153 ("x265" ,x265)
2154 ("zlib" ,zlib)))
2155 (arguments
2156 `(#:tests? #f ;tests require Ruby and claim to be unsupported
2157 #:phases
2158 (modify-phases %standard-phases
2159 (add-before 'patch-source-shebangs 'bootstrap-gtk
2160 ;; Run bootstrap ahead of time so that shebangs get patched.
2161 (lambda _
2162 (setenv "CONFIG_SHELL" (which "sh"))
2163 (setenv "NOCONFIGURE" "1")
2164 ;; Patch the Makefile so that it doesn't bootstrap again.
2165 (substitute* "gtk/module.rules"
2166 ((".*autogen\\.sh.*") ""))
2167 (zero? (system* "sh" "./gtk/autogen.sh"))))
2168 (add-before 'configure 'disable-contrib
2169 (lambda _
2170 (substitute* "make/include/main.defs"
2171 ;; Disable unconditional inclusion of some "contrib"
2172 ;; libraries (ffmpeg, libvpx, libdvdread, libdvdnav,
2173 ;; and libbluray), which would lead to fetching and
2174 ;; building of these libraries. Use our own instead.
2175 (("MODULES \\+= contrib") "# MODULES += contrib"))
2176 #t))
2177 (add-before 'configure 'fix-x265-linking
2178 (lambda _
2179 (substitute* "test/module.defs"
2180 ;; Fix missing library during linking error
2181 (("TEST.GCC.l =") "TEST.GCC.l = x265"))
2182 #t))
2183 (replace 'configure
2184 (lambda* (#:key outputs configure-flags #:allow-other-keys)
2185 ;; 'configure' is not an autoconf-generated script, and
2186 ;; errors on unrecognized arguments,
2187 ;; e.g. --enable-fast-install
2188 (let ((out (assoc-ref outputs "out")))
2189 (zero? (apply system* "./configure"
2190 (string-append "--prefix=" out)
2191 (or configure-flags '()))))))
2192 (add-after 'configure 'chdir-build
2193 (lambda _ (chdir "./build") #t)))))
2194 (home-page "https://handbrake.fr")
2195 (synopsis "Video transcoder")
2196 (description
2197 "HandBrake is a tool for converting video from any format to a selection
2198of modern, widely supported codecs.")
2199 ;; Most under GPL version 2 or later, and portions under BSD 3 Clause
2200 (license (list license:gpl2+ license:bsd-3))))
590abe01
JN
2201
2202(define-public openh264
2203 (package
2204 (name "openh264")
1a34ca0e 2205 (version "1.7.0")
590abe01
JN
2206 (source (origin
2207 (method url-fetch)
2208 (uri (string-append "https://github.com/cisco/"
2209 name "/archive/v" version ".tar.gz"))
2210 (file-name (string-append name "-" version ".tar.gz"))
2211 (sha256
2212 (base32
1a34ca0e 2213 "0gv571bqkxk7ic64dmavs1q8nr7p59mcf4ibqp4lc070gn6w61ww"))))
590abe01
JN
2214 (build-system gnu-build-system)
2215 (native-inputs
2216 `(("nasm" ,nasm)
2217 ("python" ,python)))
2218 (arguments
8363a835
EF
2219 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
2220 "CC=gcc")
590abe01
JN
2221 #:test-target "test"
2222 #:phases (modify-phases %standard-phases
2223 ;; no configure script
2224 (delete 'configure))))
2225 (home-page "http://www.openh264.org/")
2226 (synopsis "H264 decoder library")
2227 (description
2228 "Openh264 is a library which can decode H264 video streams.")
2229 (license license:bsd-2)))
3a44c7bb 2230
2231(define-public libmp4v2
2232 (package
2233 (name "libmp4v2")
2234 (version "2.0.0")
2235 (source
2236 (origin
2237 (method url-fetch)
2238 ;; XXX: The new location of upstream is uncertain and will become relevant the
2239 ;; moment when the googlecode archive shuts down. It is past the date it
2240 ;; should've been turned off. I tried to communicate with upstream, but this
2241 ;; wasn't very responsive and not very helpful. The short summary is, it is
2242 ;; chaos when it comes to the amount of forks and only time will tell where
2243 ;; the new upstream location is.
2244 (uri (string-append "https://storage.googleapis.com/google-"
2245 "code-archive-downloads/v2/"
2246 "code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
2247 (file-name (string-append name "-" version ".tar.bz2"))
2248 (sha256
2249 (base32
2250 "0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
2251 (build-system gnu-build-system)
2252 (outputs '("out"
2253 "static")) ; 3.7MiB .a file
2254 (arguments
2255 `(#:phases
2256 (modify-phases %standard-phases
2257 (add-after 'unpack 'remove-dates
2258 (lambda _
2259 ;; Make the build reproducible.
2260 (substitute* "configure"
2261 (("PROJECT_build=\"`date`\"") "PROJECT_build=\"\"")
2262 (("ac_abs_top_builddir=$ac_pwd") "ac_abs_top_builddir=\"\""))
2263 #t))
2264 (add-after 'install 'move-static-libraries
2265 (lambda* (#:key outputs #:allow-other-keys)
2266 ;; Move static libraries to the "static" output.
2267 (let* ((out (assoc-ref outputs "out"))
2268 (lib (string-append out "/lib"))
2269 (static (assoc-ref outputs "static"))
2270 (slib (string-append static "/lib")))
2271 (mkdir-p slib)
2272 (for-each (lambda (file)
2273 (install-file file slib)
2274 (delete-file file))
2275 (find-files lib "\\.a$"))
2276 #t))))))
2277 (native-inputs
2278 `(("help2man" ,help2man)
2279 ("dejagnu" ,dejagnu)))
2280 (home-page "https://code.google.com/archive/p/mp4v2/")
2281 (synopsis "API to create and modify mp4 files")
2282 (description
2283 "The MP4v2 library provides an API to create and modify mp4 files as defined by
2284ISO-IEC:14496-1:2001 MPEG-4 Systems. This file format is derived from Apple's QuickTime
2285file format that has been used as a multimedia file format in a variety of platforms and
2286applications. It is a very powerful and extensible format that can accommodate
2287practically any type of media.")
2288 (license license:mpl1.1)))
e0c40707
EJ
2289
2290(define-public libmediainfo
2291 (package
2292 (name "libmediainfo")
2293 (version "0.7.95")
2294 (source (origin
2295 (method url-fetch)
2296 (uri (string-append "https://mediaarea.net/download/source/"
2297 name "/" version"/"
2298 name "_" version ".tar.bz2"))
2299 (sha256
2300 (base32
2301 "1kchh6285b07z5nixv619hc9gml2ysdayicdiv30frrlqiyxqw4b"))))
2302 ;; TODO add a Big Buck Bunny webm for tests.
2303 (native-inputs
2304 `(("autoconf" ,autoconf)
2305 ("automake" ,automake)
2306 ("libtool" ,libtool)
2307 ("pkg-config" ,pkg-config)
2308 ("zlib" ,zlib)
2309 ("tinyxml2" ,tinyxml2)
2310 ("curl" ,curl)
2311 ("libzen" ,libzen)))
2312 (build-system gnu-build-system)
2313 (arguments
2314 '(#:tests? #f ; see above TODO
2315 #:phases
2316 ;; build scripts not in root of archive
2317 (modify-phases %standard-phases
0cae36b5 2318 (add-after 'unpack 'change-to-build-dir
e0c40707 2319 (lambda _
0cae36b5
EF
2320 (chdir "Project/GNU/Library")
2321 #t))
2322 (add-after 'change-to-build-dir 'autogen
e0c40707 2323 (lambda _
d10092b8 2324 (zero? (system* "sh" "autogen.sh")))))))
e0c40707
EJ
2325 (home-page "https://mediaarea.net/en/MediaInfo")
2326 (synopsis "Library for retrieving media metadata")
2327 (description "MediaInfo is a library used for retrieving technical
2328information and other metadata about audio or video files. A non-exhaustive
2329list of the information MediaInfo can retrieve from media files include:
2330
2331@itemize
2332@item General: title, author, director, album, track number, date, duration...
2333@item Video: codec, aspect, fps, bitrate...
2334@item Audio: codec, sample rate, channels, language, bitrate...
2335@item Text: language of subtitle
2336@item Chapters: number of chapters, list of chapters
2337@end itemize
2338
2339MediaInfo supports the following formats:
2340
2341@itemize
2342@item Video: MKV, OGM, AVI, DivX, WMV, QuickTime, Real, MPEG-1,
2343MPEG-2, MPEG-4, DVD (VOB)...
2344@item Video Codecs: DivX, XviD, MSMPEG4, ASP, H.264, AVC...)
2345@item Audio: OGG, MP3, WAV, RA, AC3, DTS, AAC, M4A, AU, AIFF...
2346@item Subtitles: SRT, SSA, ASS, SAMI...
2347@end itemize\n")
2348 (license license:bsd-2)))
2349
d5fa2777
EJ
2350;; TODO also have a GUI version available
2351(define-public mediainfo
2352 (package
2353 (name "mediainfo")
2354 (version "0.7.95")
2355 (source (origin
2356 (method url-fetch)
2357 (uri (string-append "https://mediaarea.net/download/source/"
2358 name "/" version "/"
2359 name "_" version ".tar.bz2"))
2360 (sha256
2361 (base32
2362 "0dy51a3i79jppmg1gi4f6h7jx4hcgnkmfim4d7d3gmnlbkjh8anv"))))
2363 (native-inputs
2364 `(("autoconf" ,autoconf)
2365 ("automake" ,automake)
2366 ("libtool" ,libtool)
2367 ("pkg-config" ,pkg-config)
2368 ("zlib" ,zlib)
2369 ("libmediainfo", libmediainfo)
2370 ("libzen" ,libzen)))
2371 (build-system gnu-build-system)
2372 (arguments
2373 '(#:tests? #f ; lacks tests
2374 #:phases
2375 ;; build scripts not in root of archive
2376 (modify-phases %standard-phases
2f17187f 2377 (add-after 'unpack 'change-to-build-dir
d5fa2777 2378 (lambda _
2f17187f
EF
2379 (chdir "Project/GNU/CLI")
2380 #t))
2381 (add-after 'change-to-build-dir 'autogen
d5fa2777 2382 (lambda _
d10092b8 2383 (zero? (system* "sh" "autogen.sh")))))))
d5fa2777
EJ
2384 (home-page "https://mediaarea.net/en/MediaInfo")
2385 (synopsis "Utility for reading media metadata")
2386 (description "MediaInfo is a utility used for retrieving technical
2387information and other metadata about audio or video files. It supports the
2388many codecs and formats supported by libmediainfo.")
2389 (license license:bsd-2)))
fa379a5b
CL
2390
2391(define-public livemedia-utils
2392 (package
2393 (name "livemedia-utils")
e7178996 2394 (version "2017.06.04")
fa379a5b
CL
2395 (source (origin
2396 (method url-fetch)
2397 (uri (string-append
517c66c0 2398 "https://download.videolan.org/contrib/live555/live."
fa379a5b
CL
2399 version ".tar.gz"))
2400 (sha256
2401 (base32
e7178996 2402 "0xf3vynxqpxpd762zni0jkblnjlgbqxjx99m83m7gqx6zriph271"))))
fa379a5b
CL
2403 (build-system gnu-build-system)
2404 (arguments
2405 '(#:tests? #f ; no tests
2406 #:make-flags (list "CC=gcc"
2407 (string-append "LDFLAGS=-Wl,-rpath="
2408 (assoc-ref %outputs "out") "/lib")
2409 (string-append "PREFIX="
2410 (assoc-ref %outputs "out")))
2411 #:phases (modify-phases %standard-phases
2412 (add-before 'configure 'fix-makefiles-generation
2413 (lambda _
2414 (substitute* "genMakefiles"
2415 (("/bin/rm") "rm"))
2416 #t))
2417 (replace 'configure
2418 (lambda _
2419 (zero? (system* "./genMakefiles"
2420 "linux-with-shared-libraries")))))))
2421 (home-page "http://www.live555.com/liveMedia/")
2422 (synopsis "Set of C++ libraries for multimedia streaming")
2423 (description "This code forms a set of C++ libraries for multimedia
2424streaming, using open standard protocols (RTP/RTCP, RTSP, SIP). The libraries
2425can be used to stream, receive, and process MPEG, H.265, H.264, H.263+, DV or
2426JPEG video, and several audio codecs. They can easily be extended to support
2427additional (audio and/or video) codecs, and can also be used to build basic
2428RTSP or SIP clients and servers.")
2429 (license license:lgpl3+)))
0dff4dd9
CL
2430
2431(define-public libdvbpsi
2432 (package
2433 (name "libdvbpsi")
2434 (version "1.3.1")
2435 (source (origin
2436 (method url-fetch)
2437 (uri (string-append
2438 "https://download.videolan.org/pub/libdvbpsi/"
2439 version "/libdvbpsi-" version ".tar.bz2"))
2440 (sha256
2441 (base32
2442 "0824r08kaspbrrg2dd5d46s475zb7j59brqkm2y6x3mdsnpng0yn"))))
2443 (build-system gnu-build-system)
2444 (home-page "https://www.videolan.org/developers/libdvbpsi.html")
2445 (synopsis "Library for decoding and generation of MPEG TS and DVB PSI
2446tables")
2447 (description "libdvbpsi is a simple library designed for decoding and
2448generation of MPEG TS and DVB PSI tables according to standards ISO/IEC 13818s
2449and ITU-T H.222.0.")
2450 (license license:lgpl2.1)))
6779ae27
JL
2451
2452(define-public ffms2
2453 (package
2454 (name "ffms2")
2455 (version "2.23")
2456 (home-page "https://github.com/FFMS/ffms2/")
2457 (source (origin
2458 (method url-fetch)
2459 (uri (string-append home-page "archive/" version ".tar.gz"))
2460 (file-name (string-append name "-" version ".tar.gz"))
2461 (sha256
2462 (base32
2463 "1vbkab8vrplxz5xgag8ggzkwp4f7nf285pd0l2a7zy66n6i2m6xh"))))
2464 (build-system gnu-build-system)
2465 (arguments
2466 '(#:configure-flags
2467 (list "--enable-avresample")))
2468 (inputs
2469 `(("zlib" ,zlib)))
2470 (propagated-inputs
2471 `(("ffmpeg" ,ffmpeg)))
2472 (native-inputs
2473 `(("pkg-config" ,pkg-config)))
2474 (synopsis "Cross-platform wrapper around ffmpeg/libav")
2475 (description
2476 "FFMpegSource is a wrapper library around ffmpeg/libav that allows
2477programmers to access a standard API to open and decompress media files.")
2478 ;; sources are distributed under a different license that the binary.
2479 ;; see https://github.com/FFMS/ffms2/blob/master/COPYING
2480 (license license:gpl2+))); inherits from ffmpeg
c812f460
JL
2481
2482(define-public aegisub
2483 (package
2484 (name "aegisub")
2485 (version "3.2.2")
2486 (source (origin
2487 (method url-fetch)
2488 (uri (string-append
2489 "http://ftp.aegisub.org/pub/archives/releases/source/"
2490 name "-" version ".tar.xz"))
2491 (sha256
2492 (base32
2493 "11b83qazc8h0iidyj1rprnnjdivj1lpphvpa08y53n42bfa36pn5"))))
2494 (build-system gnu-build-system)
2495 (arguments
2496 `(#:configure-flags
2497 (list "--disable-update-checker"
2498 "--without-portaudio"
2499 "--without-openal"
2500 "--without-oss")
2501 ;; tests require busted, a lua package we don't have yet
2502 #:tests? #f
2503 #:phases
2504 (modify-phases %standard-phases
2505 (add-before 'configure 'fix-ldflags
2506 (lambda _
2507 (setenv "LDFLAGS" "-pthread"))))))
2508 (inputs
2509 `(("boost" ,boost)
2510 ("desktop-file-utils" ,desktop-file-utils)
2511 ("ffms2" ,ffms2)
2512 ("fftw" ,fftw)
2513 ("hunspell" ,hunspell)
2514 ("mesa" ,mesa)
2515 ("libass" ,libass)
2516 ("alsa-lib" ,alsa-lib)
2517 ("pulseaudio" ,pulseaudio)
2518 ("libx11" ,libx11)
2519 ("freetype" ,freetype)
2520 ("wxwidgets-gtk2" ,wxwidgets-gtk2)))
2521 (native-inputs
2522 `(("intltool" ,intltool)
2523 ("pkg-config" ,pkg-config)))
2524 (home-page "http://www.aegisub.org/")
2525 (synopsis "Subtitle engine")
2526 (description
2527 "Aegisub is a tool for creating and modifying subtitles. Aegisub makes
2528it quick and easy to time subtitles to audio, and features many powerful
2529tools for styling them, including a built-in real-time video preview.")
2530 (license (list license:bsd-3 ; the package is licensed under the bsd-3, except
2531 license:mpl1.1 ; for vendor/universalchardet under the mpl1.1
2532 license:expat)))) ; and src/gl that is under a license similar
2533 ; the the Expat license, with a rewording (Software -> Materials). (called MIT
2534 ; by upstream). See https://github.com/Aegisub/Aegisub/blob/master/LICENCE
2535 ; src/MatroskaParser.(c|h) is under bsd-3 with permission from the author
2536
635f981b 2537(define-public gst-transcoder
2538 (package
2539 (name "gst-transcoder")
2540 (version "1.12.2")
2541 (source
2542 (origin
2543 (method url-fetch)
2544 (uri (string-append "https://github.com/pitivi/gst-transcoder/"
2545 "archive/" version ".tar.gz"))
2546 (file-name (string-append name "-" version ".tar.gz"))
2547 (sha256
2548 (base32
2549 "0cnwmrsd321s02ff91m3j27ydj7f8wks0jvmp5admlhka6z7zxm9"))))
2550 (build-system meson-build-system)
2551 (inputs
2552 `(("gobject-introspection" ,gobject-introspection)
2553 ("glib" ,glib)
2554 ("gstreamer" ,gstreamer)
2555 ("gst-plugins-base" ,gst-plugins-base)))
2556 (native-inputs
2557 `(("python" ,python)
2558 ("pkg-config" ,pkg-config)))
2559 (home-page "https://github.com/pitivi/gst-transcoder/")
2560 (synopsis "GStreamer Transcoding API")
2561 (description "GStreamer Transcoding API")
2562 (license license:lgpl2.1)))
e37bdc0f 2563
2564(define-public gavl
2565 (package
2566 (name "gavl")
2567 (version "1.4.0")
2568 (source
2569 (origin
2570 (method url-fetch)
2571 (uri (string-append "mirror://sourceforge/gmerlin/"
2572 name "/" version "/"
2573 name "-" version ".tar.gz"))
2574 (file-name (string-append name "-" version ".tar.gz"))
2575 (sha256
2576 (base32
2577 "1kikkn971a14zzm7svi7190ldc14fjai0xyhpbcmp48s750sraji"))))
2578 (build-system gnu-build-system)
c178aa34
EF
2579 (arguments
2580 '(#:configure-flags '("LIBS=-lm")))
e37bdc0f 2581 (native-inputs
2582 `(("pkg-config" ,pkg-config)
2583 ("doxygen" ,doxygen)))
2584 (home-page "http://gmerlin.sourceforge.net")
2585 (synopsis "Low level library for multimedia API building")
2586 (description
2587 "Gavl is short for Gmerlin Audio Video Library. It is a low level
2588library, upon which multimedia APIs can be built. Gavl handles all the
2589details of audio and video formats like colorspaces, sample rates,
2590multichannel configurations, etc. It provides standardized definitions for
2591those formats as well as container structures for carrying audio samples or
2592video images inside an application.
2593
2594In addition, it handles the sometimes ugly task of converting between all
2595these formats and provides some elementary operations (copying, scaling,
2596alpha blending etc).")
2597 (license license:gpl3)))
49e1d76d 2598
2599(define-public frei0r-plugins
2600 (package
2601 (name "frei0r-plugins")
2602 (version "1.6.1")
2603 (source
2604 (origin
2605 (method url-fetch)
2606 (uri (string-append "https://files.dyne.org/frei0r/"
2607 "frei0r-plugins-" version ".tar.gz"))
2608 (sha256
2609 (base32
2610 "0pji26fpd0dqrx1akyhqi6729s394irl73dacnyxk58ijqq4dhp0"))))
2611 (build-system gnu-build-system)
2612 (arguments
2613 `(#:phases
2614 (modify-phases %standard-phases
2615 (add-after 'unpack 'autotools
2616 (lambda _
2617 (zero? (system* "sh" "autogen.sh")))))))
2618 ;; TODO: opencv for additional face detection filters
2619 (inputs
2620 `(("gavl" ,gavl)
2621 ("cairo" ,cairo)))
2622 (native-inputs
2623 `(("pkg-config" ,pkg-config)
2624 ("libtool" ,libtool)
2625 ("automake" ,automake)
2626 ("autoconf" ,autoconf)))
2627 (home-page "https://www.dyne.org/software/frei0r/")
2628 (synopsis "Minimalistic plugin API for video effects")
2629 (description
2630 "Frei0r is a minimalistic plugin API for video effects.
2631The main emphasis is on simplicity for an API that will round up
2632the most common video effects into simple filters, sources and
2633mixers that can be controlled by parameters. Frei0r wants to
2634provide a way to share these simple effects between many
2635applications, avoiding their reimplementation by different projects.
2636It counts more than 100 plugins.")
2637 (license (list license:gpl2+
2638 ;; The following files are licensed as LGPL2.1+:
2639 ;; src/generator/ising0r/ising0r.c
2640 ;; src/generator/onecol0r/onecol0r.cpp
2641 ;; src/generator/nois0r/nois0r.cpp
2642 ;; src/generator/lissajous0r/lissajous0r.cpp
2643 ;; src/filter/ndvi/gradientlut.hpp
2644 ;; src/filter/ndvi/ndvi.cpp
2645 ;; src/filter/facedetect/facedetect.cpp
2646 license:lgpl2.1+))))