Commit | Line | Data |
---|---|---|
39efcc9b | 1 | ;;; GNU Guix --- Functional package management for GNU |
44726031 | 2 | ;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr> |
2cd85cf9 | 3 | ;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org> |
3b02429c | 4 | ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> |
cda163cd | 5 | ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com> |
39efcc9b AE |
6 | ;;; |
7 | ;;; This file is part of GNU Guix. | |
8 | ;;; | |
9 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
10 | ;;; under the terms of the GNU General Public License as published by | |
11 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
12 | ;;; your option) any later version. | |
13 | ;;; | |
14 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
15 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 | ;;; GNU General Public License for more details. | |
18 | ;;; | |
19 | ;;; You should have received a copy of the GNU General Public License | |
20 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
21 | ||
22 | (define-module (gnu packages video) | |
fe138965 | 23 | #:use-module (ice-9 match) |
615215a5 | 24 | #:use-module ((guix licenses) |
4d94b93c | 25 | #:select (gpl2 gpl2+ gpl3+ lgpl2.1+ bsd-3 public-domain |
c426e61e | 26 | fsf-free isc)) |
39efcc9b AE |
27 | #:use-module (guix packages) |
28 | #:use-module (guix download) | |
38829eac | 29 | #:use-module (guix git-download) |
44726031 | 30 | #:use-module (guix build-system cmake) |
39efcc9b | 31 | #:use-module (guix build-system gnu) |
615215a5 | 32 | #:use-module (guix build-system python) |
3b02429c | 33 | #:use-module (gnu packages) |
39efcc9b | 34 | #:use-module (gnu packages algebra) |
72bfebf5 | 35 | #:use-module (gnu packages audio) |
f1044010 | 36 | #:use-module (gnu packages autotools) |
d5a748e8 | 37 | #:use-module (gnu packages avahi) |
38829eac | 38 | #:use-module (gnu packages base) |
d5a748e8 | 39 | #:use-module (gnu packages cdrom) |
39efcc9b | 40 | #:use-module (gnu packages compression) |
44726031 | 41 | #:use-module (gnu packages databases) |
5d3609e4 | 42 | #:use-module (gnu packages doxygen) |
f22e0e26 | 43 | #:use-module (gnu packages elf) |
39efcc9b | 44 | #:use-module (gnu packages fontutils) |
44726031 AE |
45 | #:use-module (gnu packages fribidi) |
46 | #:use-module (gnu packages gettext) | |
38829eac | 47 | #:use-module (gnu packages ghostscript) |
d5a748e8 AE |
48 | #:use-module (gnu packages gl) |
49 | #:use-module (gnu packages glib) | |
2cd85cf9 | 50 | #:use-module (gnu packages guile) |
d5a748e8 AE |
51 | #:use-module (gnu packages gnupg) |
52 | #:use-module (gnu packages gnutls) | |
44726031 | 53 | #:use-module (gnu packages gtk) |
e55354b8 | 54 | #:use-module (gnu packages image) |
d5a748e8 AE |
55 | #:use-module (gnu packages linux) |
56 | #:use-module (gnu packages lua) | |
57 | #:use-module (gnu packages mp3) | |
4d94b93c | 58 | #:use-module (gnu packages ncurses) |
39efcc9b AE |
59 | #:use-module (gnu packages openssl) |
60 | #:use-module (gnu packages perl) | |
61 | #:use-module (gnu packages pkg-config) | |
d5a748e8 | 62 | #:use-module (gnu packages pulseaudio) |
39efcc9b | 63 | #:use-module (gnu packages python) |
d5a748e8 | 64 | #:use-module (gnu packages qt) |
38829eac | 65 | #:use-module (gnu packages samba) |
d5a748e8 AE |
66 | #:use-module (gnu packages sdl) |
67 | #:use-module (gnu packages ssh) | |
5d3609e4 | 68 | #:use-module (gnu packages texlive) |
c426e61e | 69 | #:use-module (gnu packages textutils) |
d5a748e8 | 70 | #:use-module (gnu packages version-control) |
bb470bd3 | 71 | #:use-module (gnu packages web) |
ee3b55ea | 72 | #:use-module (gnu packages xdisorg) |
54ff0b7d | 73 | #:use-module (gnu packages xiph) |
d5a748e8 AE |
74 | #:use-module (gnu packages xml) |
75 | #:use-module (gnu packages xorg) | |
44726031 AE |
76 | #:use-module (gnu packages yasm) |
77 | #:use-module (gnu packages zip)) | |
39efcc9b | 78 | |
cda163cd TUBK |
79 | (define-public liba52 |
80 | (package | |
81 | (name "liba52") | |
82 | (version "0.7.4") | |
83 | (source (origin | |
84 | (method url-fetch) | |
8c056935 TUBK |
85 | (uri (string-append |
86 | ;; A mirror://sourceforge URI doesn't work, presumably | |
87 | ;; because the SourceForge project is misconfigured. | |
88 | "http://liba52.sourceforge.net/files/a52dec-" version | |
89 | ".tar.gz")) | |
cda163cd TUBK |
90 | (sha256 |
91 | (base32 | |
92 | "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2")))) | |
93 | (build-system gnu-build-system) | |
94 | (home-page "http://liba52.sourceforge.net/") | |
95 | (synopsis "ATSC A/52 stream decoder") | |
96 | (description "liba52 is a library for decoding ATSC A/52 streams. The | |
97 | A/52 standard is used in a variety of applications, including digital | |
98 | television and DVD. It is also known as AC-3.") | |
99 | (license gpl2+))) | |
100 | ||
c426e61e TUBK |
101 | (define-public libass |
102 | (package | |
103 | (name "libass") | |
104 | (version "0.12.1") | |
105 | (source (origin | |
106 | (method url-fetch) | |
107 | (uri (string-append | |
108 | "https://github.com/libass/libass/releases/download/" | |
109 | version "/libass-" version ".tar.xz")) | |
110 | (sha256 | |
111 | (base32 | |
112 | "1mwj2nk9g6cq6f8m1hf0ijg1299rghhy9naahqq43sc2whblb1l7")))) | |
113 | (build-system gnu-build-system) | |
114 | (native-inputs | |
115 | `(("pkg-config" ,pkg-config) | |
116 | ("yasm" ,yasm))) | |
117 | (propagated-inputs | |
118 | `(("freetype" ,freetype) | |
119 | ("fribidi" ,fribidi) | |
120 | ("fontconfig" ,fontconfig) | |
121 | ("harfbuzz" ,harfbuzz) | |
122 | ("enca" ,enca))) | |
123 | (home-page "https://github.com/libass/libass") | |
124 | (synopsis "Subtitle rendering library for the ASS/SSA format") | |
125 | (description "libass is a subtitle rendering library for the | |
126 | ASS/SSA (Advanced Substation Alpha/SubStation Alpha) subtitle format.") | |
127 | (license isc))) | |
128 | ||
4d94b93c TUBK |
129 | (define-public libcaca |
130 | (package | |
131 | (name "libcaca") | |
132 | (version "0.99.beta19") | |
133 | (source (origin | |
134 | (method url-fetch) | |
135 | (uri (string-append "http://caca.zoy.org/files/libcaca/libcaca-" | |
136 | version ".tar.gz")) | |
137 | (sha256 | |
138 | (base32 | |
139 | "1x3j6yfyxl52adgnabycr0n38j9hx2j74la0hz0n8cnh9ry4d2qj")))) | |
140 | (build-system gnu-build-system) | |
141 | (native-inputs `(("pkg-config" ,pkg-config))) | |
142 | (inputs | |
143 | `(("freeglut" ,freeglut) | |
144 | ("ftgl" ,ftgl) | |
145 | ("libx11" ,libx11) | |
146 | ("mesa" ,mesa) | |
147 | ("ncurses" ,ncurses) | |
148 | ("zlib" ,zlib))) | |
149 | (home-page "http://caca.zoy.org/wiki/libcaca") | |
150 | (synopsis "Colour ASCII-art library") | |
151 | (description "libcaca is a graphics library that outputs text instead of | |
152 | pixels, so that it can work on older video cards or text terminals. It | |
153 | supports Unicode, 2048 colors, dithering of color images, and advanced text | |
154 | canvas operations.") | |
155 | (license (fsf-free "file://COPYING")))) ;WTFPL version 2 | |
156 | ||
3bfb78dc TUBK |
157 | (define-public libdca |
158 | (package | |
159 | (name "libdca") | |
160 | (version "0.0.5") | |
161 | (source (origin | |
162 | (method url-fetch) | |
163 | (uri (string-append | |
164 | "http://download.videolan.org/pub/videolan/libdca/" | |
165 | version "/libdca-" version ".tar.bz2")) | |
166 | (sha256 | |
167 | (base32 | |
168 | "0hh6a7l8vvccsd5i1fkv9av2gzv9fy8m0b8jpsn5p6hh4bh2586v")))) | |
169 | (build-system gnu-build-system) | |
170 | (home-page "http://www.videolan.org/developers/libdca.html") | |
171 | (synopsis "DTS Coherent Acoustics decoder") | |
172 | (description "libdca is a library for decoding DTS Coherent Acoustics | |
173 | streams.") | |
174 | (license gpl2+))) | |
175 | ||
99d4c455 TUBK |
176 | (define-public libdv |
177 | (package | |
178 | (name "libdv") | |
179 | (version "1.0.0") | |
180 | (source (origin | |
181 | (method url-fetch) | |
182 | (uri (string-append | |
183 | "mirror://sourceforge/libdv/libdv-" version ".tar.gz")) | |
184 | (sha256 | |
185 | (base32 | |
186 | "1fl96f2xh2slkv1i1ix7kqk576a0ak1d33cylm0mbhm96d0761d3")))) | |
187 | (build-system gnu-build-system) | |
188 | (native-inputs `(("pkg-config" ,pkg-config))) | |
189 | (inputs `(("libxv" ,libxv))) | |
190 | (home-page "http://libdv.sourceforge.net/") | |
191 | (synopsis "DV video (IEC 61834 and SMPTE 314M) codec") | |
192 | (description "The Quasar DV codec (libdv) is a software codec for DV | |
193 | video, the encoding format used by most digital camcorders, typically those | |
194 | that support the IEEE 1394 (a.k.a. FireWire or i.Link) interface. Libdv was | |
195 | developed according to the official standards for DV video: IEC 61834 and | |
196 | SMPTE 314M.") | |
197 | (license lgpl2.1+))) | |
198 | ||
ee3b55ea TUBK |
199 | (define-public libva |
200 | (package | |
201 | (name "libva") | |
202 | (version "1.5.1") | |
203 | (source | |
204 | (origin | |
205 | (method url-fetch) | |
206 | (uri (string-append | |
207 | "http://www.freedesktop.org/software/vaapi/releases/libva/libva-" | |
208 | version".tar.bz2")) | |
209 | (sha256 | |
210 | (base32 "01d01mm9fgpwzqycmjjcj3in3vvzcibi3f64icsw2sksmmgb4495")))) | |
211 | (build-system gnu-build-system) | |
212 | (native-inputs | |
213 | `(("pkg-config" ,pkg-config))) | |
214 | (inputs | |
215 | `(("libdrm" ,libdrm) | |
216 | ("libx11" ,libx11) | |
217 | ("libxext" ,libxext) | |
218 | ("libxfixes" ,libxfixes) | |
219 | ("mesa" ,mesa))) | |
220 | (home-page "http://www.freedesktop.org/wiki/Software/vaapi/") | |
221 | (synopsis "Video acceleration library") | |
222 | (description "The main motivation for VA-API (Video Acceleration API) is | |
223 | to enable hardware accelerated video decode/encode at various | |
224 | entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding | |
225 | standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).") | |
226 | (license expat))) | |
227 | ||
39efcc9b AE |
228 | (define-public ffmpeg |
229 | (package | |
230 | (name "ffmpeg") | |
6abdad69 | 231 | (version "2.6") |
39efcc9b AE |
232 | (source (origin |
233 | (method url-fetch) | |
234 | (uri (string-append "http://www.ffmpeg.org/releases/ffmpeg-" | |
235 | version ".tar.bz2")) | |
236 | (sha256 | |
237 | (base32 | |
6abdad69 | 238 | "14a7zp8pa1rvw6nr9l2rf57xr004n5kwkhn5lglybjnn1p68xhr3")))) |
39efcc9b AE |
239 | (build-system gnu-build-system) |
240 | (inputs | |
c4c4cc05 | 241 | `(("fontconfig" ,fontconfig) |
39efcc9b | 242 | ("freetype" ,freetype) |
e816b348 | 243 | ("opus" ,opus) |
71241192 | 244 | ("ladspa" ,ladspa) |
d4f12db8 | 245 | ("lame" ,lame) |
c426e61e | 246 | ("libass" ,libass) |
5d3609e4 | 247 | ("libbluray" ,libbluray) |
4d94b93c | 248 | ("libcaca" ,libcaca) |
cc6c0170 | 249 | ("libcdio-paranoia" ,libcdio-paranoia) |
bb470bd3 | 250 | ("libquvi" ,libquvi) |
39efcc9b AE |
251 | ("libtheora" ,libtheora) |
252 | ("libvorbis" ,libvorbis) | |
dc55b8b2 | 253 | ("libvpx" ,libvpx) |
71241192 | 254 | ("openal" ,openal) |
f22e0e26 | 255 | ("patchelf" ,patchelf) |
71241192 | 256 | ("pulseaudio" ,pulseaudio) |
72bfebf5 | 257 | ("soxr" ,soxr) |
c4c4cc05 | 258 | ("speex" ,speex) |
72bfebf5 | 259 | ("twolame" ,twolame) |
67932f86 | 260 | ("xvid" ,xvid) |
c4c4cc05 JD |
261 | ("zlib", zlib))) |
262 | (native-inputs | |
263 | `(("bc" ,bc) | |
264 | ("bzip2" ,bzip2) | |
39efcc9b AE |
265 | ("perl" ,perl) |
266 | ("pkg-config" ,pkg-config) | |
267 | ("python" ,python-2) ; scripts use interpreter python2 | |
268 | ("speex" ,speex) | |
c4c4cc05 | 269 | ("yasm" ,yasm))) |
39efcc9b | 270 | (arguments |
31f9322e | 271 | `(#:test-target "fate" |
f22e0e26 AE |
272 | #:modules ((guix build gnu-build-system) |
273 | (guix build utils) | |
274 | (guix build rpath) | |
275 | (srfi srfi-26)) | |
276 | #:imported-modules ((guix build gnu-build-system) | |
277 | (guix build utils) | |
278 | (guix build rpath)) | |
31f9322e | 279 | #:phases |
39efcc9b AE |
280 | (alist-replace |
281 | 'configure | |
282 | ;; configure does not work followed by "SHELL=..." and | |
283 | ;; "CONFIG_SHELL=..."; set environment variables instead | |
284 | (lambda* (#:key outputs configure-flags #:allow-other-keys) | |
285 | (let ((out (assoc-ref outputs "out"))) | |
286 | (substitute* "configure" | |
287 | (("#! /bin/sh") (string-append "#!" (which "bash")))) | |
288 | (setenv "SHELL" (which "bash")) | |
289 | (setenv "CONFIG_SHELL" (which "bash")) | |
97ffa451 AE |
290 | ;; FIXME: only needed for ffmpeg-2.2.13, but easier to add |
291 | ;; globally; drop as soon as ffmpeg-2.2.13 is dropped | |
292 | (setenv "LDFLAGS" "-ldl") | |
39efcc9b AE |
293 | ;; possible additional inputs: |
294 | ;; --enable-avisynth enable reading of AviSynth script files [no] | |
295 | ;; --enable-frei0r enable frei0r video filtering | |
39efcc9b | 296 | ;; --enable-libaacplus enable AAC+ encoding via libaacplus [no] |
39efcc9b | 297 | ;; --enable-libcelt enable CELT decoding via libcelt [no] |
39efcc9b AE |
298 | ;; --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394 |
299 | ;; and libraw1394 [no] | |
300 | ;; --enable-libfaac enable AAC encoding via libfaac [no] | |
301 | ;; --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no] | |
302 | ;; --enable-libflite enable flite (voice synthesis) support via libflite [no] | |
303 | ;; --enable-libgme enable Game Music Emu via libgme [no] | |
304 | ;; --enable-libgsm enable GSM de/encoding via libgsm [no] | |
305 | ;; --enable-libiec61883 enable iec61883 via libiec61883 [no] | |
306 | ;; --enable-libilbc enable iLBC de/encoding via libilbc [no] | |
307 | ;; --enable-libmodplug enable ModPlug via libmodplug [no] | |
39efcc9b AE |
308 | ;; --enable-libnut enable NUT (de)muxing via libnut, |
309 | ;; native (de)muxer exists [no] | |
310 | ;; --enable-libopencore-amrnb enable AMR-NB de/encoding via libopencore-amrnb [no] | |
311 | ;; --enable-libopencore-amrwb enable AMR-WB decoding via libopencore-amrwb [no] | |
312 | ;; --enable-libopencv enable video filtering via libopencv [no] | |
313 | ;; --enable-libopenjpeg enable JPEG 2000 de/encoding via OpenJPEG [no] | |
39efcc9b AE |
314 | ;; --enable-librtmp enable RTMP[E] support via librtmp [no] |
315 | ;; --enable-libschroedinger enable Dirac de/encoding via libschroedinger [no] | |
316 | ;; --enable-libshine enable fixed-point MP3 encoding via libshine [no] | |
39efcc9b AE |
317 | ;; --enable-libssh enable SFTP protocol via libssh [no] |
318 | ;; (libssh2 does not work) | |
319 | ;; --enable-libstagefright-h264 enable H.264 decoding via libstagefright [no] | |
39efcc9b AE |
320 | ;; --enable-libutvideo enable Ut Video encoding and decoding via libutvideo [no] |
321 | ;; --enable-libv4l2 enable libv4l2/v4l-utils [no] | |
322 | ;; --enable-libvidstab enable video stabilization using vid.stab [no] | |
323 | ;; --enable-libvo-aacenc enable AAC encoding via libvo-aacenc [no] | |
324 | ;; --enable-libvo-amrwbenc enable AMR-WB encoding via libvo-amrwbenc [no] | |
39efcc9b AE |
325 | ;; --enable-libwavpack enable wavpack encoding via libwavpack [no] |
326 | ;; --enable-libx264 enable H.264 encoding via x264 [no] | |
327 | ;; --enable-libxavs enable AVS encoding via xavs [no] | |
39efcc9b AE |
328 | ;; --enable-libzmq enable message passing via libzmq [no] |
329 | ;; --enable-libzvbi enable teletext support via libzvbi [no] | |
39efcc9b AE |
330 | ;; --enable-opencl enable OpenCL code |
331 | ;; --enable-x11grab enable X11 grabbing [no] | |
332 | (zero? (system* | |
333 | "./configure" | |
334 | (string-append "--prefix=" out) | |
c85a866d | 335 | "--enable-avresample" |
39efcc9b AE |
336 | "--enable-gpl" ; enable optional gpl licensed parts |
337 | "--enable-shared" | |
338 | "--enable-fontconfig" | |
339 | ;; "--enable-gnutls" ; causes test failures | |
71241192 | 340 | "--enable-ladspa" |
c426e61e | 341 | "--enable-libass" |
5d3609e4 | 342 | "--enable-libbluray" |
4d94b93c | 343 | "--enable-libcaca" |
cc6c0170 | 344 | "--enable-libcdio" |
39efcc9b | 345 | "--enable-libfreetype" |
d4f12db8 | 346 | "--enable-libmp3lame" |
e816b348 | 347 | "--enable-libopus" |
71241192 | 348 | "--enable-libpulse" |
bb470bd3 | 349 | "--enable-libquvi" |
72bfebf5 | 350 | "--enable-libsoxr" |
39efcc9b AE |
351 | "--enable-libspeex" |
352 | "--enable-libtheora" | |
72bfebf5 | 353 | "--enable-libtwolame" |
39efcc9b | 354 | "--enable-libvorbis" |
dc55b8b2 | 355 | "--enable-libvpx" |
67932f86 | 356 | "--enable-libxvid" |
71241192 | 357 | "--enable-openal" |
82fce926 MW |
358 | |
359 | "--enable-runtime-cpudetect" | |
360 | ||
361 | ;; Runtime cpu detection is not implemented on | |
362 | ;; MIPS, so we disable some features. | |
39efcc9b AE |
363 | "--disable-mips32r2" |
364 | "--disable-mipsdspr1" | |
365 | "--disable-mipsdspr2" | |
366 | "--disable-mipsfpu")))) | |
f22e0e26 AE |
367 | (alist-cons-after |
368 | 'strip 'add-lib-to-runpath | |
369 | (lambda* (#:key outputs #:allow-other-keys) | |
370 | (let* ((out (assoc-ref outputs "out")) | |
371 | (lib (string-append out "/lib"))) | |
622c8f0a | 372 | ;; Add LIB to the RUNPATH of all the executables and libraries. |
f22e0e26 AE |
373 | (with-directory-excursion out |
374 | (for-each (cut augment-rpath <> lib) | |
622c8f0a SB |
375 | (append (find-files "bin" ".*") |
376 | (find-files "lib" "\\.so\\..*\\.")))))) | |
f22e0e26 | 377 | %standard-phases)))) |
39efcc9b AE |
378 | (home-page "http://www.ffmpeg.org/") |
379 | (synopsis "Audio and video framework") | |
380 | (description "FFmpeg is a complete, cross-platform solution to record, | |
381 | convert and stream audio and video. It includes the libavcodec | |
382 | audio/video codec library.") | |
383 | (license gpl2+))) | |
d5a748e8 | 384 | |
f9e687b5 MW |
385 | ;; We need this older ffmpeg because vlc-2.1.5 doesn't work with ffmpeg-2.4. |
386 | (define-public ffmpeg-2.2 | |
387 | (package (inherit ffmpeg) | |
49685cae | 388 | (version "2.2.13") |
f9e687b5 MW |
389 | (source (origin |
390 | (method url-fetch) | |
391 | (uri (string-append "http://www.ffmpeg.org/releases/ffmpeg-" | |
392 | version ".tar.bz2")) | |
393 | (sha256 | |
394 | (base32 | |
49685cae | 395 | "1vva8ffwxi3rg44byy09qlbiqrrd1h4rmsl5b1mbmvzvwl1lq1l0")))))) |
f9e687b5 | 396 | |
d5a748e8 AE |
397 | (define-public vlc |
398 | (package | |
399 | (name "vlc") | |
b9156ccc | 400 | (version "2.1.5") |
d5a748e8 AE |
401 | (source (origin |
402 | (method url-fetch) | |
403 | (uri (string-append | |
404 | "http://download.videolan.org/pub/videolan/vlc/" | |
405 | version "/vlc-" version ".tar.xz")) | |
406 | (sha256 | |
407 | (base32 | |
b9156ccc | 408 | "0whzbn7ahn5maarcwl1yhk9lq10b0q0y9w5pjl9kh3frdjmncrbg")))) |
d5a748e8 AE |
409 | (build-system gnu-build-system) |
410 | (native-inputs | |
411 | `(("git" ,git) ; needed for a test | |
412 | ("pkg-config" ,pkg-config))) | |
413 | ;; FIXME: Add optional inputs once available. | |
414 | (inputs | |
415 | `(("alsa-lib" ,alsa-lib) | |
416 | ("avahi" ,avahi) | |
417 | ("dbus" ,dbus) | |
418 | ("flac" ,flac) | |
f9e687b5 | 419 | ("ffmpeg" ,ffmpeg-2.2) ; FIXME: vlc-2.1.5 won't work with ffmpeg-2.4 |
d5a748e8 AE |
420 | ("fontconfig" ,fontconfig) |
421 | ("freetype" ,freetype) | |
422 | ("gnutls" ,gnutls) | |
423 | ("libcddb" ,libcddb) | |
424 | ("libgcrypt" ,libgcrypt) | |
425 | ("libkate" ,libkate) | |
426 | ("libmad" ,libmad) | |
427 | ("libogg" ,libogg) | |
428 | ("libpng" ,libpng) | |
429 | ("libsamplerate" ,libsamplerate) | |
430 | ("libssh2" ,libssh2) | |
431 | ("libvorbis" ,libvorbis) | |
432 | ("libtheora" ,libtheora) | |
433 | ("libxext" ,libxext) | |
434 | ("libxinerama" ,libxinerama) | |
435 | ("libxml2" ,libxml2) | |
436 | ("libxpm" ,libxpm) | |
437 | ("lua" ,lua-5.1) | |
438 | ("mesa" ,mesa) | |
439 | ("opus" ,opus) | |
440 | ("perl" ,perl) | |
441 | ("pulseaudio" ,pulseaudio) | |
442 | ("python" ,python-wrapper) | |
443 | ("qt" ,qt-4) | |
444 | ("sdl" ,sdl) | |
445 | ("sdl-image" ,sdl-image) | |
446 | ("speex" ,speex) | |
447 | ("xcb-util-keysyms" ,xcb-util-keysyms))) | |
448 | (arguments | |
449 | `(#:configure-flags | |
450 | `("--disable-a52" ; FIXME: reenable once available | |
d5a748e8 AE |
451 | ,(string-append "LDFLAGS=-Wl,-rpath -Wl," |
452 | (assoc-ref %build-inputs "ffmpeg") | |
453 | "/lib")))) ; needed for the tests | |
454 | (home-page "https://www.videolan.org/") | |
455 | (synopsis "Audio and video framework") | |
456 | (description "VLC is a cross-platform multimedia player and framework | |
457 | that plays most multimedia files as well as DVD, Audio CD, VCD, and various | |
458 | treaming protocols.") | |
459 | (license gpl2+))) | |
ace69243 AE |
460 | |
461 | (define-public mplayer | |
462 | (package | |
463 | (name "mplayer") | |
464 | (version "1.1.1") | |
465 | (source (origin | |
466 | (method url-fetch) | |
467 | (uri (string-append | |
468 | "http://www.mplayerhq.hu/MPlayer/releases/MPlayer-" | |
469 | version ".tar.xz")) | |
470 | (sha256 | |
471 | (base32 | |
472 | "0xlcg7rszrwmw29wqr0plsw5d1rq0hb7vjsq7bmmfsly2z1wg3yf")))) | |
473 | (build-system gnu-build-system) | |
474 | ;; FIXME: Add additional inputs once available. | |
475 | (native-inputs | |
476 | `(("pkg-config" ,pkg-config))) | |
477 | (inputs | |
478 | `(("alsa-lib" ,alsa-lib) | |
479 | ("cdparanoia" ,cdparanoia) | |
480 | ("fontconfig" ,fontconfig) | |
481 | ("freetype" ,freetype) | |
482 | ("lame" ,lame) | |
60bbd4f1 | 483 | ("libmpg123" ,mpg123) ; audio codec for MP3 |
ace69243 AE |
484 | ;; ("giflib" ,giflib) ; uses QuantizeBuffer, requires version >= 5 |
485 | ("libjpeg" ,libjpeg) | |
486 | ("libpng" ,libpng) | |
487 | ("libtheora" ,libtheora) | |
488 | ("libvorbis" ,libvorbis) | |
489 | ("libx11" ,libx11) | |
490 | ("libxxf86dga" ,libxxf86dga) | |
491 | ("libxinerama" ,libxinerama) | |
492 | ("libxv" ,libxv) | |
493 | ("mesa" ,mesa) | |
494 | ("perl" ,perl) | |
495 | ("pulseaudio" ,pulseaudio) | |
496 | ("python" ,python-wrapper) | |
497 | ("sdl" ,sdl) | |
498 | ("speex" ,speex) | |
499 | ("yasm" ,yasm) | |
500 | ("zlib" ,zlib))) | |
501 | (arguments | |
502 | `(#:tests? #f ; no test target | |
503 | #:phases | |
504 | (alist-replace | |
505 | 'configure | |
506 | ;; configure does not work followed by "SHELL=..." and | |
507 | ;; "CONFIG_SHELL=..."; set environment variables instead | |
508 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
509 | (let ((out (assoc-ref outputs "out")) | |
510 | (libx11 (assoc-ref inputs "libx11"))) | |
511 | (substitute* "configure" | |
512 | (("#! /bin/sh") (string-append "#!" (which "bash")))) | |
513 | (setenv "SHELL" (which "bash")) | |
514 | (setenv "CONFIG_SHELL" (which "bash")) | |
515 | (zero? (system* | |
516 | "./configure" | |
517 | (string-append "--extra-cflags=-I" | |
518 | libx11 "/include") ; to detect libx11 | |
519 | "--disable-tremor-internal" ; forces external libvorbis | |
520 | (string-append "--prefix=" out) | |
fe138965 MW |
521 | ;; Enable runtime cpu detection where supported, |
522 | ;; and choose a suitable target. | |
523 | ,@(match (or (%current-target-system) | |
524 | (%current-system)) | |
525 | ("x86_64-linux" | |
526 | '("--enable-runtime-cpudetection" | |
527 | "--target=x86_64-linux")) | |
528 | ("i686-linux" | |
529 | '("--enable-runtime-cpudetection" | |
530 | "--target=i686-linux")) | |
531 | ("mips64el-linux" | |
532 | '("--target=mips3-linux"))) | |
ace69243 AE |
533 | "--disable-armv5te" |
534 | "--disable-armv6" | |
535 | "--disable-armv6t2" | |
536 | "--disable-armvfp" | |
537 | "--disable-neon" | |
538 | "--disable-thumb" | |
539 | "--disable-iwmmxt")))) | |
540 | %standard-phases))) | |
541 | (home-page "http://www.mplayerhq.hu/design7/news.html") | |
542 | (synopsis "Audio and video player") | |
543 | (description "MPlayer is a movie player. It plays most MPEG/VOB, AVI, | |
544 | Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT, | |
545 | NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files. One can watch VideoCD, | |
546 | SVCD, DVD, 3ivx, DivX 3/4/5, WMV and H.264 movies.") | |
547 | (license gpl2))) | |
d0ed39be | 548 | |
38829eac TUBK |
549 | ;;; This is not version 2; it's a fork literally named "mplayer2". |
550 | (define-public mplayer2 | |
551 | (package | |
552 | (name "mplayer2") | |
553 | ;; There are no tarballs. The 2.0 git tag, which is actually the first | |
554 | ;; release is from 2011. The latest commit is from 2013 October, so we | |
555 | ;; use that commit. | |
556 | (version "201310") | |
557 | (source (origin | |
558 | (method git-fetch) | |
559 | (uri (git-reference | |
560 | ;; XXX Change this if mplayer2.org goes up again. | |
561 | (url "http://repo.or.cz/mplayer2.git") | |
562 | (commit "2c378c71a4d9b1df382db9aa787b646628b4e3f9"))) | |
563 | (sha256 | |
564 | (base32 | |
565 | "0s8554sanj6cvnf0h148nsmjgy5v0568nmcza7grpv6fnmddpfam")) | |
566 | (file-name (string-append name "-" version "-checkout")) | |
567 | ;; Warning: after using this patch, one must pass the -ltheora | |
568 | ;; linker flag manually to configure; see below. | |
569 | (patches (list (search-patch "mplayer2-theora-fix.patch"))))) | |
570 | (build-system gnu-build-system) | |
571 | (native-inputs | |
572 | `(("pkg-config" ,pkg-config) | |
573 | ("perl" ,perl) | |
574 | ("python" ,python) | |
575 | ("python-2" ,python-2) | |
576 | ("python-docutils" ,python-docutils) | |
577 | ;; ./configure uses which(1) to find rst2man.py. | |
578 | ("which" ,which))) | |
579 | ;; Missing features: DirectFB, Xss screensaver extensions, VDPAU, MNG, | |
580 | ;; libnut, DirectShow TV interface, Radio interfaces of all kinds, vstream | |
581 | ;; client, XMSS inputplugin support, joystick, lirc/lircc, and openal. | |
582 | ;; OpenAL support is experimental and causes compilation to fail with | |
583 | ;; linker errors. | |
584 | (inputs | |
585 | `(("alsa-lib" ,alsa-lib) | |
586 | ("faad2" ,faad2) | |
587 | ("ffmpeg" ,ffmpeg) | |
588 | ("gettext" ,gnu-gettext) | |
589 | ("jack" ,jack-2) | |
590 | ("ladspa" ,ladspa) | |
591 | ("lcms" ,lcms) | |
592 | ("liba52" ,liba52) | |
593 | ("libass" ,libass) | |
594 | ("libbluray" ,libbluray) | |
595 | ("libbs2b" ,libbs2b) | |
596 | ("libcaca" ,libcaca) | |
597 | ("libcdio-paranoia" ,libcdio-paranoia) | |
598 | ("libdca" ,libdca) | |
599 | ("libdv" ,libdv) | |
600 | ("libdvdread" ,libdvdread) | |
601 | ("libdvdnav" ,libdvdnav-4) | |
602 | ("libjpeg" ,libjpeg) | |
603 | ("libmad" ,libmad) | |
604 | ("libpng" ,libpng) | |
605 | ("libquvi" ,libquvi) | |
606 | ("libtheora" ,libtheora) | |
607 | ("libungif" ,libungif) | |
608 | ("libvorbis" ,libvorbis) | |
609 | ("libx11" ,libx11) | |
610 | ("libxinerama" ,libxinerama) | |
611 | ("libxv" ,libxv) | |
612 | ("mesa" ,mesa) | |
613 | ("mpg123" ,mpg123) | |
614 | ("ncurses" ,ncurses) | |
615 | ("portaudio" ,portaudio) | |
616 | ("pulseaudio" ,pulseaudio) | |
617 | ("rsound" ,rsound) | |
618 | ("samba" ,samba) | |
619 | ("sdl" ,sdl) | |
620 | ("speex" ,speex) | |
621 | ("xvid" ,xvid))) | |
622 | (arguments | |
623 | '(#:phases | |
624 | (alist-replace | |
625 | 'configure | |
626 | ;; ./configure does not work followed by "SHELL=..." and | |
627 | ;; "CONFIG_SHELL=..."; set environment variables instead. | |
628 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
629 | (setenv "SHELL" (which "bash")) | |
630 | (setenv "CONFIG_SHELL" (which "bash")) | |
631 | (substitute* "configure" | |
632 | (("/usr/X11") (assoc-ref inputs "libx11"))) | |
633 | (zero? | |
634 | (system* "./configure" | |
635 | (string-append "--prefix=" (assoc-ref outputs "out")) | |
636 | "--enable-translation" | |
637 | "--enable-runtime-cpudetection" | |
638 | ;; This is needed in accordance with the theora patch. | |
639 | "--extra-libs=-ltheoradec"))) | |
640 | (alist-cons-before | |
641 | 'build 'fix-TOOLS-shebangs | |
642 | (lambda _ | |
643 | (substitute* (find-files "TOOLS" "\\.(sh|pl|py)$") | |
644 | (("/usr/bin/env") (which "env")) | |
645 | (("/usr/bin/perl") (which "perl")) | |
646 | (("/usr/bin/python3") (which "python3")) | |
647 | (("/usr/bin/python") (which "python")))) | |
648 | (alist-cons-before | |
649 | 'build 'fix-input-buffer-padding-size | |
650 | (lambda _ | |
651 | (substitute* "libmpdemux/demuxer.h" | |
652 | ;; This has to match with FFmpeg's FF_INPUT_BUFFER_PADDING_SIZE, | |
653 | ;; which has changed at some point. | |
654 | (("(#define MP_INPUT_BUFFER_PADDING_SIZE )[0-9]*" all) | |
655 | (string-append all "32")))) | |
656 | %standard-phases))) | |
657 | ;; No 'check' target. | |
658 | #:tests? #f)) | |
659 | ;; XXX Change this if mplayer2.org goes up again. | |
660 | (home-page "http://repo.or.cz/w/mplayer2.git") | |
661 | (synopsis "Audio and video player") | |
662 | (description "mplayer2 is a general-purpose audio and video player. It's | |
663 | a fork of the original MPlayer project, and contains further development in | |
664 | several areas.") | |
665 | ;; See file Copyright. Most files are gpl2+ or compatible, but talloc.c | |
666 | ;; is under lgpl3+, thus the whole project becomes gpl3+. | |
667 | (license gpl3+))) | |
668 | ||
d0ed39be DT |
669 | (define-public libvpx |
670 | (package | |
671 | (name "libvpx") | |
672 | (version "1.3.0") | |
673 | (source (origin | |
674 | (method url-fetch) | |
675 | (uri (string-append "http://webm.googlecode.com/files/libvpx-v" | |
676 | version ".tar.bz2")) | |
677 | (sha256 | |
678 | (base32 | |
3b02429c MW |
679 | "1aai0h0z1bhp89pxmg4fkrwpmqq24k39fhr15cw6q77m9bccip6k")) |
680 | (patches | |
681 | (list (search-patch "libvpx-vp9-out-of-bounds-access.patch") | |
682 | (search-patch "libvpx-fix-ssse3-quantize.patch") | |
683 | (search-patch "libvpx-fix-armhf-link.patch"))))) | |
d0ed39be DT |
684 | (build-system gnu-build-system) |
685 | (arguments | |
3b02429c | 686 | `(#:phases (alist-replace |
d0ed39be DT |
687 | 'configure |
688 | (lambda* (#:key outputs #:allow-other-keys) | |
689 | (setenv "CONFIG_SHELL" (which "bash")) | |
690 | (let ((out (assoc-ref outputs "out"))) | |
691 | (zero? (system* "./configure" | |
692 | "--enable-shared" | |
693 | "--as=yasm" | |
3b02429c MW |
694 | ,@(if (and (not (%current-target-system)) |
695 | (string-prefix? | |
696 | "armhf-" | |
697 | (%current-system))) | |
698 | ;; When building on ARMv7, libvpx | |
699 | ;; assumes that NEON will be | |
700 | ;; available. On Guix, armhf | |
701 | ;; does not require NEON, so we | |
702 | ;; build for ARMv6 and -marm (since | |
703 | ;; no thumb2 on ARMv6) to ensure | |
704 | ;; compatibility with all ARMv7 | |
705 | ;; cores we support. Based on | |
706 | ;; the Debian libvpx package. | |
707 | '("--target=armv6-linux-gcc" | |
708 | "--extra-cflags=-marm" | |
709 | "--enable-small") | |
710 | '()) | |
d0ed39be DT |
711 | (string-append "--prefix=" out))))) |
712 | %standard-phases) | |
713 | #:tests? #f)) ; no check target | |
714 | (native-inputs | |
715 | `(("perl" ,perl) | |
716 | ("yasm" ,yasm))) | |
717 | (synopsis "VP8/VP9 video codec") | |
718 | (description "libvpx is a codec for the VP8/VP9 video compression format.") | |
719 | (license bsd-3) | |
720 | (home-page "http://www.webmproject.org/"))) | |
615215a5 LC |
721 | |
722 | (define-public youtube-dl | |
723 | (package | |
724 | (name "youtube-dl") | |
2f7fade9 | 725 | (version "2015.01.23.4") |
615215a5 LC |
726 | (source (origin |
727 | (method url-fetch) | |
728 | (uri (string-append "http://youtube-dl.org/downloads/" | |
729 | version "/youtube-dl-" | |
730 | version ".tar.gz")) | |
731 | (sha256 | |
732 | (base32 | |
2f7fade9 | 733 | "0pvvab9dk1righ3fa79000iz8fzdlcxakscx5sd31730c37j3kj2")))) |
615215a5 LC |
734 | (build-system python-build-system) |
735 | (inputs `(("setuptools" ,python-setuptools))) | |
736 | (home-page "http://youtube-dl.org") | |
737 | (synopsis "Download videos from YouTube.com and other sites") | |
738 | (description | |
739 | "youtube-dl is a small command-line program to download videos from | |
740 | YouTube.com and a few more sites.") | |
741 | (license public-domain))) | |
e6bdb36a | 742 | |
5d3609e4 TUBK |
743 | (define-public libbluray |
744 | (package | |
745 | (name "libbluray") | |
746 | (version "0.7.0") | |
747 | (source (origin | |
748 | (method url-fetch) | |
749 | (uri (string-append "http://download.videolan.org/videolan/" | |
750 | name "/" version "/" | |
751 | name "-" version ".tar.bz2")) | |
752 | (sha256 | |
753 | (base32 | |
754 | "13dngs4b4cv29f6b825dq14n77mfhvk1kjb42axpq494pfgyp6zp")))) | |
755 | (build-system gnu-build-system) | |
756 | (native-inputs `(("pkg-config" ,pkg-config))) | |
757 | (inputs | |
758 | `(("doxygen" ,doxygen) | |
759 | ("fontconfig" ,fontconfig) | |
760 | ("freetype" ,freetype) | |
761 | ("libxml2" ,libxml2) | |
762 | ("perl" ,perl) ;for doxygen | |
763 | ("texlive" ,texlive))) | |
764 | (home-page "http://www.videolan.org/developers/libbluray.html") | |
765 | (synopsis "Blu-Ray Disc playback library") | |
766 | (description | |
767 | "libbluray is a library designed for Blu-Ray Disc playback for media | |
768 | players, like VLC or MPlayer.") | |
769 | (license lgpl2.1+))) | |
770 | ||
e6bdb36a AE |
771 | (define-public libdvdread |
772 | (package | |
773 | (name "libdvdread") | |
774 | (version "5.0.0") | |
775 | (source (origin | |
776 | (method url-fetch) | |
777 | (uri (string-append "http://download.videolan.org/videolan/" | |
778 | name "/" version "/" | |
779 | name "-" version ".tar.bz2")) | |
780 | (sha256 | |
781 | (base32 | |
782 | "052z62l3x8ka5jpf5bi1mzp5p323n1z9rxj74nq5c35a88x1myv6")))) | |
783 | (build-system gnu-build-system) | |
784 | (home-page "http://dvdnav.mplayerhq.hu/") | |
785 | (synopsis "Library for reading video DVDs") | |
786 | (description | |
787 | "Libdvdread provides a simple foundation for reading DVD video | |
788 | disks. It provides the functionality that is required to access many | |
789 | DVDs. It parses IFO files, reads NAV-blocks, and performs CSS | |
790 | authentication and descrambling (if an external libdvdcss library is | |
791 | installed).") | |
792 | (license gpl2+))) | |
b027d919 AE |
793 | |
794 | (define-public libdvdnav | |
795 | (package | |
796 | (name "libdvdnav") | |
797 | (version "5.0.1") | |
798 | (source (origin | |
799 | (method url-fetch) | |
800 | (uri (string-append "http://download.videolan.org/videolan/" | |
801 | name "/" version "/" | |
802 | name "-" version ".tar.bz2")) | |
803 | (sha256 | |
804 | (base32 | |
805 | "1ad2lkkiydgwiyqfysra9lkwjv9yqnvcg4hv92hx8qzics1cpcbj")))) | |
806 | (build-system gnu-build-system) | |
807 | (native-inputs | |
808 | `(("pkg-config" ,pkg-config))) | |
809 | (inputs | |
810 | `(("libdvdread" ,libdvdread))) | |
811 | (home-page "http://dvdnav.mplayerhq.hu/") | |
812 | (synopsis "Library for video DVD navigation features") | |
813 | (description | |
814 | "Libdvdnav is a library for developers of multimedia | |
815 | applications. It allows easy use of sophisticated DVD navigation features | |
816 | such as DVD menus, multiangle playback and even interactive DVD games. All | |
817 | this functionality is provided through a simple API which provides the DVD | |
818 | playback as a single logical stream of blocks, intermitted by special | |
819 | dvdnav events to report certain conditions. The main usage of libdvdnav is | |
820 | a loop regularly calling a function to get the next block, surrounded by | |
821 | additional calls to tell the library of user interaction. The whole | |
822 | DVD virtual machine and internal playback states are completely | |
823 | encapsulated.") | |
824 | (license gpl2+))) | |
2cd85cf9 | 825 | |
f1044010 TUBK |
826 | (define-public libdvdnav-4 |
827 | (package | |
828 | (inherit libdvdnav) | |
829 | (version "4.2.1") | |
830 | (source (origin | |
831 | (method url-fetch) | |
832 | (uri | |
833 | (string-append | |
834 | "http://download.videolan.org/videolan/libdvdnav/libdvdnav-" | |
835 | version ".tar.xz")) | |
836 | (sha256 | |
837 | (base32 | |
838 | "0wi3gy408c8xj0ism0hckv5jbfh3lg4pmgxv87gbch9jrhp2gjkz")))) | |
839 | (native-inputs | |
840 | `(("pkg-config" ,pkg-config) | |
841 | ("autoconf" ,autoconf) | |
842 | ("automake" ,automake) | |
843 | ("libtool" ,libtool))) | |
844 | (arguments | |
845 | '(#:phases | |
846 | (alist-cons-after | |
847 | 'unpack 'autoreconf | |
848 | (lambda _ | |
849 | (zero? (system* "autoreconf" "-vif"))) | |
850 | %standard-phases))))) | |
851 | ||
a6f710ec TUBK |
852 | (define-public libdvdcss |
853 | (package | |
854 | (name "libdvdcss") | |
855 | (version "1.3.0") | |
856 | (source (origin | |
857 | (method url-fetch) | |
858 | (uri (string-append "http://download.videolan.org/videolan/" | |
859 | name "/" version "/" | |
860 | name "-" version ".tar.bz2")) | |
861 | (sha256 | |
862 | (base32 | |
863 | "158k9zagmbk5bkbz96l6lwhh7xcgfcnzflkr4vblskhcab6llhbw")))) | |
864 | (build-system gnu-build-system) | |
865 | (home-page "http://www.videolan.org/developers/libdvdcss.html") | |
866 | (synopsis "Library for accessing DVDs as block devices") | |
867 | (description | |
868 | "libdvdcss is a simple library designed for accessing DVDs like a block | |
869 | device without having to bother about the decryption.") | |
870 | (license gpl2+))) | |
871 | ||
2cd85cf9 DT |
872 | (define-public srt2vtt |
873 | (package | |
874 | (name "srt2vtt") | |
875 | (version "0.1") | |
876 | (source (origin | |
877 | (method url-fetch) | |
878 | (uri (string-append | |
879 | "http://dthompson.us/releases/srt2vtt/srt2vtt-" | |
880 | version ".tar.gz")) | |
881 | (sha256 | |
882 | (base32 | |
883 | "16b377znjm6qlga5yb8aj7b7bcisa1ghcnj2lrb1d30lvxp4liif")))) | |
884 | (build-system gnu-build-system) | |
885 | (inputs | |
886 | `(("guile" ,guile-2.0))) | |
887 | (synopsis "SubRip to WebVTT subtitle converter") | |
888 | (description "srt2vtt converts SubRip formatted subtitles to WebVTT format | |
889 | for use with HTML5 video.") | |
890 | (home-page "http://dthompson.us/pages/software/srt2vtt") | |
891 | (license gpl3+))) | |
44726031 AE |
892 | |
893 | (define-public avidemux | |
894 | (package | |
895 | (name "avidemux") | |
896 | (version "2.6.8") | |
897 | (source (origin | |
898 | (method url-fetch) | |
899 | (uri (string-append | |
900 | "mirror://sourceforge/avidemux/avidemux_" | |
901 | version ".tar.gz")) | |
902 | (sha256 | |
903 | (base32 | |
904 | "10p60wjkzf1bxqcb6i7bx4hbqy3vqg598p3l9lc4v2c9b8iqr682")))) | |
905 | (build-system cmake-build-system) | |
906 | (native-inputs | |
907 | `(("pkg-config" ,pkg-config))) | |
908 | ;; FIXME: Once packaged, add libraries not found during the build. | |
909 | (inputs | |
910 | `(("alsa-lib" ,alsa-lib) | |
911 | ("fontconfig" ,fontconfig) | |
912 | ("freetype" ,freetype) | |
913 | ("fribidi" ,fribidi) | |
914 | ("glu" ,glu) | |
915 | ("gtk+" ,gtk+) | |
916 | ("jack" ,jack-1) | |
917 | ("lame" ,lame) | |
918 | ("libvorbis" ,libvorbis) | |
919 | ("libvpx" ,libvpx) | |
920 | ("libxv" ,libxv) | |
921 | ("perl" ,perl) | |
922 | ("pulseaudio" ,pulseaudio) | |
923 | ("python" ,python-wrapper) | |
924 | ("qt" ,qt-4) | |
925 | ("sdl" ,sdl) | |
926 | ("sqlite" ,sqlite) | |
927 | ("yasm" ,yasm) | |
928 | ("zlib" ,zlib))) | |
929 | (arguments | |
930 | `(#:tests? #f ; no check target | |
931 | #:phases | |
932 | ;; Make sure files inside the included ffmpeg tarball are | |
933 | ;; patch-shebanged. | |
934 | (alist-cons-before | |
935 | 'patch-source-shebangs 'unpack-ffmpeg | |
936 | (lambda _ | |
937 | (with-directory-excursion "avidemux_core/ffmpeg_package" | |
938 | (system* "tar" "xf" "ffmpeg-1.2.1.tar.bz2") | |
939 | (delete-file "ffmpeg-1.2.1.tar.bz2"))) | |
940 | (alist-cons-after | |
941 | 'patch-source-shebangs 'repack-ffmpeg | |
942 | (lambda _ | |
943 | (with-directory-excursion "avidemux_core/ffmpeg_package" | |
944 | (substitute* "ffmpeg-1.2.1/configure" | |
945 | (("#! /bin/sh") (string-append "#!" (which "bash")))) | |
946 | (system* "tar" "cjf" "ffmpeg-1.2.1.tar.bz2" "ffmpeg-1.2.1") | |
947 | (delete-file-recursively "ffmpeg-1.2.1"))) | |
948 | (alist-replace 'configure | |
949 | (lambda _ | |
950 | ;; Copy-paste settings from the cmake build system. | |
951 | (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH")) | |
952 | (setenv "CMAKE_INCLUDE_PATH" (getenv "CPATH"))) | |
953 | (alist-replace 'build | |
954 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
955 | (let* | |
956 | ((out (assoc-ref outputs "out")) | |
957 | (lib (string-append out "/lib64")) | |
958 | (top (getcwd)) | |
959 | (sdl (assoc-ref inputs "sdl")) | |
960 | (build_component | |
961 | (lambda* (component srcdir #:optional (args '())) | |
962 | (let ((builddir (string-append "build_" component))) | |
963 | (mkdir builddir) | |
964 | (with-directory-excursion builddir | |
965 | (zero? (and | |
966 | (apply system* "cmake" | |
967 | "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE" | |
968 | (string-append "-DCMAKE_INSTALL_PREFIX=" out) | |
969 | (string-append "-DCMAKE_INSTALL_RPATH=" lib) | |
970 | (string-append "-DAVIDEMUX_SOURCE_DIR=" top) | |
971 | (string-append "-DSDL_INCLUDE_DIR=" | |
972 | sdl "/include/SDL") | |
973 | (string-append "../" srcdir) | |
974 | args) | |
975 | (system* "make" "-j" | |
976 | (number->string (parallel-job-count))) | |
977 | (system* "make" "install")))))))) | |
978 | (mkdir out) | |
979 | (and (build_component "core" "avidemux_core") | |
980 | (build_component "cli" "avidemux/cli") | |
981 | (build_component "qt4" "avidemux/qt4") | |
982 | (build_component "gtk" "avidemux/gtk") | |
983 | (build_component "plugins_common" "avidemux_plugins" | |
984 | '("-DPLUGIN_UI=COMMON")) | |
985 | (build_component "plugins_cli" "avidemux_plugins" | |
986 | '("-DPLUGIN_UI=CLI")) | |
987 | (build_component "plugins_qt4" "avidemux_plugins" | |
988 | '("-DPLUGIN_UI=QT4")) | |
989 | (build_component "plugins_gtk" "avidemux_plugins" | |
990 | '("-DPLUGIN_UI=GTK")) | |
991 | (build_component "plugins_settings" "avidemux_plugins" | |
992 | '("-DPLUGIN_UI=SETTINGS"))) | |
993 | ;; Remove .exe and .dll file. | |
994 | (delete-file-recursively | |
995 | (string-append out "/share/ADM6_addons")))) | |
996 | (alist-delete 'install | |
997 | %standard-phases))))))) | |
998 | (home-page "http://fixounet.free.fr/avidemux/") | |
999 | (synopsis "Video editor") | |
1000 | (description "Avidemux is a video editor designed for simple cutting, | |
1001 | filtering and encoding tasks. It supports many file types, including AVI, | |
1002 | DVD compatible MPEG files, MP4 and ASF, using a variety of codecs. Tasks | |
1003 | can be automated using projects, job queue and powerful scripting | |
1004 | capabilities.") | |
1005 | ;; Software with various licenses is included, see License.txt. | |
1006 | (license gpl2+))) | |
1007 | ||
1008 | (define-public avidemux-2.5 | |
1009 | (package (inherit avidemux) | |
1010 | (version "2.5.6") | |
1011 | (source (origin | |
1012 | (method url-fetch) | |
1013 | (uri (string-append | |
1014 | "mirror://sourceforge/avidemux/avidemux_" | |
1015 | version ".tar.gz")) | |
1016 | (sha256 | |
1017 | (base32 | |
1018 | "12wvxz0n2g85f079d8mdkkp2zm279d34m9v7qgcqndh48cn7znnn")))) | |
1019 | (native-inputs | |
1020 | `(("pkg-config" ,pkg-config))) | |
1021 | (inputs | |
1022 | `(("alsa-lib" ,alsa-lib) | |
1023 | ("gettext" ,gnu-gettext) | |
1024 | ("gtk+" ,gtk+-2) | |
1025 | ("jack" ,jack-1) | |
1026 | ("lame" ,lame) | |
1027 | ("libvorbis" ,libvorbis) | |
1028 | ("libvpx" ,libvpx) | |
1029 | ("libxml2" ,libxml2) | |
1030 | ("libxslt" ,libxslt) | |
1031 | ("libxv" ,libxv) | |
1032 | ("perl" ,perl) | |
1033 | ("pulseaudio" ,pulseaudio) | |
1034 | ("qt" ,qt-4) | |
1035 | ("sdl" ,sdl) | |
1036 | ("yasm" ,yasm) | |
1037 | ("zlib" ,zlib))) | |
1038 | (arguments | |
1039 | `(#:tests? #f | |
1040 | #:phases | |
1041 | (alist-cons-before | |
1042 | 'patch-source-shebangs 'unpack-ffmpeg | |
1043 | (lambda _ | |
1044 | (with-directory-excursion "avidemux/ADM_libraries" | |
1045 | (system* "tar" "xf" "ffmpeg-0.9.tar.bz2") | |
1046 | (delete-file "ffmpeg-0.9.tar.bz2"))) | |
1047 | (alist-cons-after | |
1048 | 'patch-source-shebangs 'repack-ffmpeg | |
1049 | (lambda _ | |
1050 | (with-directory-excursion "avidemux/ADM_libraries" | |
1051 | (substitute* "ffmpeg-0.9/configure" | |
1052 | (("#! /bin/sh") (string-append "#!" (which "bash")))) | |
1053 | (system* "tar" "cjf" "ffmpeg-0.9.tar.bz2" "ffmpeg-0.9") | |
1054 | (delete-file-recursively "ffmpeg-0.9"))) | |
1055 | (alist-replace 'configure | |
1056 | (lambda _ | |
1057 | (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH")) | |
1058 | (setenv "CMAKE_INCLUDE_PATH" (getenv "CPATH"))) | |
1059 | (alist-replace 'build | |
1060 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
1061 | (let* | |
1062 | ((out (assoc-ref outputs "out")) | |
1063 | (lib (string-append out "/lib")) | |
1064 | (top (getcwd)) | |
1065 | (sdl (assoc-ref inputs "sdl")) | |
1066 | (build_component | |
1067 | (lambda* (component srcdir) | |
1068 | (let ((builddir (string-append "build_" component))) | |
1069 | (mkdir builddir) | |
1070 | (with-directory-excursion builddir | |
1071 | (zero? (and | |
1072 | (system* "cmake" | |
1073 | "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE" | |
1074 | (string-append "-DCMAKE_INSTALL_PREFIX=" | |
1075 | out) | |
1076 | (string-append "-DCMAKE_INSTALL_RPATH=" | |
1077 | lib) | |
1078 | (string-append "-DAVIDEMUX_SOURCE_DIR=" | |
1079 | top) | |
1080 | (string-append "-DAVIDEMUX_CORECONFIG_DIR=" | |
1081 | top "/build_main/config") | |
1082 | (string-append "-DAVIDEMUX_INSTALL_PREFIX=" | |
1083 | out) | |
1084 | (string-append "-DSDL_INCLUDE_DIR=" | |
1085 | sdl "/include/SDL") | |
1086 | (string-append "../" srcdir)) | |
1087 | (system* "make" "-j" | |
1088 | (number->string (parallel-job-count))) | |
1089 | (system* "make" "install")))))))) | |
1090 | (mkdir out) | |
1091 | (and (build_component "main" ".") | |
1092 | (build_component "plugins" "plugins")) | |
1093 | (delete-file-recursively | |
1094 | (string-append out "/share/ADM_addons")))) | |
1095 | (alist-delete 'install | |
1096 | %standard-phases))))))))) | |
67932f86 TUBK |
1097 | |
1098 | (define-public xvid | |
1099 | (package | |
1100 | (name "xvid") | |
1101 | (version "1.3.3") | |
1102 | (source (origin | |
1103 | (method url-fetch) | |
1104 | (uri (string-append | |
1105 | "http://downloads.xvid.org/downloads/xvidcore-" | |
1106 | version ".tar.bz2")) | |
1107 | (sha256 | |
1108 | (base32 | |
1109 | "0m5g75qvapr7xpywg6a83v5x19kw1nm9l2q48lg7jvvpba0bmqdh")))) | |
1110 | (build-system gnu-build-system) | |
1111 | (native-inputs `(("yasm" ,yasm))) | |
1112 | (arguments | |
1113 | '(#:phases | |
1114 | (alist-cons-before | |
1115 | 'configure 'pre-configure | |
1116 | (lambda _ | |
1117 | (chdir "build/generic") | |
1118 | (substitute* "configure" | |
1119 | (("#! /bin/sh") (string-append "#!" (which "sh"))))) | |
1120 | %standard-phases) | |
1121 | ;; No 'check' target. | |
1122 | #:tests? #f)) | |
1123 | (home-page "https://www.xvid.com/") | |
1124 | (synopsis "MPEG-4 Part 2 Advanced Simple Profile video codec") | |
1125 | (description "Xvid is an MPEG-4 Part 2 Advanced Simple Profile (ASP) video | |
1126 | codec library. It uses ASP features such as b-frames, global and quarter | |
1127 | pixel motion compensation, lumi masking, trellis quantization, and H.263, MPEG | |
1128 | and custom quantization matrices.") | |
1129 | (license gpl2+))) |