1 |
commit: a922a262381b0f28746512408c5def10a6df67a4 |
2 |
Author: Ilya Tumaykin <itumaykin <AT> gmail <DOT> com> |
3 |
AuthorDate: Tue May 31 04:49:34 2016 +0000 |
4 |
Commit: Sam Jorna <wraeth <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue May 31 08:49:12 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a922a262 |
7 |
|
8 |
media-video/mpv: remove old |
9 |
|
10 |
Closes: https://github.com/gentoo/gentoo/pull/1569 |
11 |
Package-Manager: portage-2.3.0_rc1 |
12 |
|
13 |
media-video/mpv/Manifest | 1 - |
14 |
.../mpv-0.17.0-add-missing-math-include.patch | 21 -- |
15 |
...7.0-fix-seeking-without-first-index-entry.patch | 42 --- |
16 |
media-video/mpv/mpv-0.17.0-r4.ebuild | 300 --------------------- |
17 |
media-video/mpv/mpv-0.17.0.ebuild | 288 -------------------- |
18 |
5 files changed, 652 deletions(-) |
19 |
|
20 |
diff --git a/media-video/mpv/Manifest b/media-video/mpv/Manifest |
21 |
index 171e223..39ac01f 100644 |
22 |
--- a/media-video/mpv/Manifest |
23 |
+++ b/media-video/mpv/Manifest |
24 |
@@ -1,4 +1,3 @@ |
25 |
-DIST mpv-0.17.0-patches-04.tar.gz 7862 SHA256 a6b259cfe3ed605ca5530981670051e38c712c906bbdd0ea7958932660cc6556 SHA512 74dc84ab5baadb950658d55ba5d89300fc169c67cf854ca33ea812e246a1fbbbe9f84d0f07ca6cc3ca5fb97710209974105785a8a3e593166a4aaa696266b1ea WHIRLPOOL 743c9c7443213499d2ec692955c447f29ec10c3305fa13c2e06ae52b10408473b35037772b4b3c4a2f69ff9318fe1a6dd8a7d5c4307928424b0a081447b9018e |
26 |
DIST mpv-0.17.0-patches-05.tar.gz 12830 SHA256 cc63d7fe5754ceb62bc8c33d50a02376ee0d5d4c3ff0763fc85787624e32b1e1 SHA512 680b5f50e5a4749ffd63712bf6160b64b37bd14bfc9f9b3912afb1a576a1ab754cdaeb20ee206e3484e037126bec395431002590ff3417ea247d2be340b4fd09 WHIRLPOOL 01e76442ed360ca0f29404038d5b082fb87d40dcf7a868377735ac63cd2df51385dd5987fe57ed6c5928ca1aca3fa8938d7fe878360025d6ea8706b7948c8531 |
27 |
DIST mpv-0.17.0.tar.gz 2882629 SHA256 602cd2b0f5fc7e43473234fbb96e3f7bbb6418f15eb8fa720d9433cce31eba6e SHA512 fb79738a16dbc12b60199a68836aca121a800958af4eaf6c2bdf1114bde36c156bafc232e814045a16fd738d2de1e2d8392bc98507961e5a73fa692e270dc7a2 WHIRLPOOL 704133b4033a5a2be8db92a4f1e52397d5b261a99a035d38e33b91d2c478e0e9bfcb2ba0e24ee03d37fffe693b275f50f7f1e453263a5afe61e8944f51eefa61 |
28 |
DIST mpv-0.9.2.tar.gz 2701306 SHA256 c0148f55dbd17705f49bb496d0ce374419de62e1b17195d91409d7727cbd4751 SHA512 4f652a8e78d65b0ef44a06287b05250dfdfbce4cf5a6e21d3b446eedec268d83cf98afcc687272e2da2cfac9e9f69a303847dffdfd45cecdd4273b943ce50967 WHIRLPOOL 1512bacc2ce50e875770c76106a1bb2bc1d0cc5f6e2bdce91ff8c5cfc8bf13ffb48519858a5fa2a7d57880820dc12e5eb20f34ab71eca5d76ec303618da8f3fe |
29 |
|
30 |
diff --git a/media-video/mpv/files/0.17.0/mpv-0.17.0-add-missing-math-include.patch b/media-video/mpv/files/0.17.0/mpv-0.17.0-add-missing-math-include.patch |
31 |
deleted file mode 100644 |
32 |
index 9f04fbe..0000000 |
33 |
--- a/media-video/mpv/files/0.17.0/mpv-0.17.0-add-missing-math-include.patch |
34 |
+++ /dev/null |
35 |
@@ -1,21 +0,0 @@ |
36 |
-commit b735c0e2077cb37df6764350472cbc68a9142d91 |
37 |
-Author: wm4 <wm4@nowhere> |
38 |
-Date: Fri Apr 15 13:58:41 2016 +0200 |
39 |
- |
40 |
-lcms: include math.h |
41 |
- |
42 |
-Fixes #3053. |
43 |
---- |
44 |
- |
45 |
-diff --git a/video/out/opengl/lcms.c b/video/out/opengl/lcms.c |
46 |
-index 7db8da6..a2030d3 100644 |
47 |
---- a/video/out/opengl/lcms.c |
48 |
-+++ b/video/out/opengl/lcms.c |
49 |
-@@ -16,6 +16,7 @@ |
50 |
- */ |
51 |
- |
52 |
- #include <string.h> |
53 |
-+#include <math.h> |
54 |
- |
55 |
- #include "mpv_talloc.h" |
56 |
- |
57 |
|
58 |
diff --git a/media-video/mpv/files/0.17.0/mpv-0.17.0-fix-seeking-without-first-index-entry.patch b/media-video/mpv/files/0.17.0/mpv-0.17.0-fix-seeking-without-first-index-entry.patch |
59 |
deleted file mode 100644 |
60 |
index 82c6d37..0000000 |
61 |
--- a/media-video/mpv/files/0.17.0/mpv-0.17.0-fix-seeking-without-first-index-entry.patch |
62 |
+++ /dev/null |
63 |
@@ -1,42 +0,0 @@ |
64 |
-commit f4142ab9ad1d929b60ff134754f482754b63043a |
65 |
-Author: wm4 <wm4@nowhere> |
66 |
-Date: Tue Apr 12 15:41:44 2016 +0200 |
67 |
- |
68 |
-demux_mkv: fix seeking with files that miss the first index entry |
69 |
- |
70 |
-Now it will always be able to seek back to the start, even if the index |
71 |
-is sparse or misses the first entry. |
72 |
- |
73 |
-This can be achieved by reusing the logic for incremental index |
74 |
-generation (for files with no index), and start time probing (for making |
75 |
-sure the first block is always indexed). |
76 |
---- |
77 |
- |
78 |
-diff --git a/demux/demux_mkv.c b/demux/demux_mkv.c |
79 |
-index b0a910b..210f4d6 100644 |
80 |
---- a/demux/demux_mkv.c |
81 |
-+++ b/demux/demux_mkv.c |
82 |
-@@ -773,8 +773,9 @@ static int demux_mkv_read_cues(demuxer_t *demuxer) |
83 |
- if (cues.n_cue_point <= 3) // probably too sparse and will just break seeking |
84 |
- goto done; |
85 |
- |
86 |
-- // Discard incremental index. |
87 |
-- mkv_d->num_indexes = 0; |
88 |
-+ // Discard incremental index. (Keep the first entry, which must be the |
89 |
-+ // start of the file - helps with files that miss the first index entry.) |
90 |
-+ mkv_d->num_indexes = MPMIN(1, mkv_d->num_indexes); |
91 |
- mkv_d->index_has_durations = false; |
92 |
- |
93 |
- for (int i = 0; i < cues.n_cue_point; i++) { |
94 |
-@@ -2963,8 +2964,10 @@ static void probe_first_timestamp(struct demuxer *demuxer) |
95 |
- return; |
96 |
- |
97 |
- struct block_info block; |
98 |
-- if (read_next_block(demuxer, &block) > 0) |
99 |
-+ if (read_next_block(demuxer, &block) > 0) { |
100 |
-+ index_block(demuxer, &block); |
101 |
- mkv_d->tmp_block = block; |
102 |
-+ } |
103 |
- |
104 |
- demuxer->start_time = mkv_d->cluster_tc / 1e9; |
105 |
- |
106 |
|
107 |
diff --git a/media-video/mpv/mpv-0.17.0-r4.ebuild b/media-video/mpv/mpv-0.17.0-r4.ebuild |
108 |
deleted file mode 100644 |
109 |
index 93907e6..0000000 |
110 |
--- a/media-video/mpv/mpv-0.17.0-r4.ebuild |
111 |
+++ /dev/null |
112 |
@@ -1,300 +0,0 @@ |
113 |
-# Copyright 1999-2016 Gentoo Foundation |
114 |
-# Distributed under the terms of the GNU General Public License v2 |
115 |
-# $Id$ |
116 |
- |
117 |
-EAPI=6 |
118 |
- |
119 |
-PYTHON_COMPAT=( python{2_7,3_3,3_4,3_5} ) |
120 |
-PYTHON_REQ_USE='threads(+)' |
121 |
- |
122 |
-WAF_PV=1.8.12 |
123 |
- |
124 |
-inherit fdo-mime gnome2-utils pax-utils python-any-r1 toolchain-funcs waf-utils |
125 |
- |
126 |
-DESCRIPTION="Media player based on MPlayer and mplayer2" |
127 |
-HOMEPAGE="https://mpv.io/" |
128 |
- |
129 |
-if [[ ${PV} != *9999* ]]; then |
130 |
- SRC_URI=" |
131 |
- https://github.com/mpv-player/mpv/archive/v${PV}.tar.gz -> ${P}.tar.gz |
132 |
- https://dev.gentoo.org/~wraeth/distfiles/${P}-patches-04.tar.gz |
133 |
- " |
134 |
- KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux" |
135 |
- DOCS=( RELEASE_NOTES ) |
136 |
-else |
137 |
- EGIT_REPO_URI="git://github.com/mpv-player/mpv.git" |
138 |
- inherit git-r3 |
139 |
-fi |
140 |
-SRC_URI+=" https://waf.io/waf-${WAF_PV}" |
141 |
-DOCS+=( CONTRIBUTING.md README.md ) |
142 |
- |
143 |
-# See Copyright in sources and Gentoo bug 506946. Waf is BSD, libmpv is ISC. |
144 |
-LICENSE="GPL-2+ BSD ISC" |
145 |
-SLOT="0" |
146 |
-IUSE="aqua +alsa archive bluray cdda +cli coreaudio doc drm dvb dvd +egl +enca |
147 |
- encode gbm +iconv jack jpeg lcms +libass libav libcaca libguess libmpv lua |
148 |
- luajit openal +opengl oss pulseaudio raspberry-pi rubberband samba -sdl |
149 |
- selinux test uchardet v4l vaapi vdpau vf-dlopen wayland +X xinerama |
150 |
- +xscreensaver +xv zsh-completion" |
151 |
- |
152 |
-REQUIRED_USE=" |
153 |
- || ( cli libmpv ) |
154 |
- aqua? ( opengl ) |
155 |
- egl? ( || ( gbm X wayland ) ) |
156 |
- enca? ( iconv ) |
157 |
- gbm? ( drm egl ) |
158 |
- lcms? ( || ( opengl egl ) ) |
159 |
- libguess? ( iconv ) |
160 |
- luajit? ( lua ) |
161 |
- uchardet? ( iconv ) |
162 |
- v4l? ( || ( alsa oss ) ) |
163 |
- vaapi? ( || ( gbm X wayland ) ) |
164 |
- vdpau? ( X ) |
165 |
- wayland? ( egl ) |
166 |
- xinerama? ( X ) |
167 |
- xscreensaver? ( X ) |
168 |
- xv? ( X ) |
169 |
- zsh-completion? ( cli ) |
170 |
-" |
171 |
- |
172 |
-COMMON_DEPEND=" |
173 |
- !libav? ( >=media-video/ffmpeg-2.4:0=[encode?,threads,vaapi?,vdpau?] ) |
174 |
- libav? ( >=media-video/libav-11:0=[encode?,threads,vaapi?,vdpau?] ) |
175 |
- sys-libs/zlib |
176 |
- alsa? ( >=media-libs/alsa-lib-1.0.18 ) |
177 |
- archive? ( >=app-arch/libarchive-3.0.0:= ) |
178 |
- bluray? ( >=media-libs/libbluray-0.3.0 ) |
179 |
- cdda? ( dev-libs/libcdio-paranoia ) |
180 |
- drm? ( x11-libs/libdrm ) |
181 |
- dvb? ( virtual/linuxtv-dvb-headers ) |
182 |
- dvd? ( |
183 |
- >=media-libs/libdvdnav-4.2.0 |
184 |
- >=media-libs/libdvdread-4.1.0 |
185 |
- ) |
186 |
- egl? ( media-libs/mesa[egl,gbm(-)?,wayland(-)?] ) |
187 |
- iconv? ( |
188 |
- virtual/libiconv |
189 |
- enca? ( app-i18n/enca ) |
190 |
- libguess? ( >=app-i18n/libguess-1.0 ) |
191 |
- uchardet? ( dev-libs/uchardet ) |
192 |
- ) |
193 |
- jack? ( virtual/jack ) |
194 |
- jpeg? ( virtual/jpeg:0 ) |
195 |
- lcms? ( >=media-libs/lcms-2.6:2 ) |
196 |
- libass? ( |
197 |
- >=media-libs/libass-0.12.1:=[fontconfig,harfbuzz] |
198 |
- virtual/ttf-fonts |
199 |
- ) |
200 |
- libcaca? ( >=media-libs/libcaca-0.99_beta18 ) |
201 |
- lua? ( |
202 |
- !luajit? ( || ( =dev-lang/lua-5.1*:= =dev-lang/lua-5.2*:= ) ) |
203 |
- luajit? ( dev-lang/luajit:2 ) |
204 |
- ) |
205 |
- openal? ( >=media-libs/openal-1.13 ) |
206 |
- opengl? ( !aqua? ( virtual/opengl ) ) |
207 |
- pulseaudio? ( media-sound/pulseaudio ) |
208 |
- raspberry-pi? ( |
209 |
- >=media-libs/raspberrypi-userland-0_pre20160305-r1 |
210 |
- media-libs/mesa[egl,gles2] |
211 |
- ) |
212 |
- rubberband? ( >=media-libs/rubberband-1.8.0 ) |
213 |
- samba? ( net-fs/samba ) |
214 |
- sdl? ( media-libs/libsdl2[sound,threads,video,X?,wayland?] ) |
215 |
- v4l? ( media-libs/libv4l ) |
216 |
- vaapi? ( >=x11-libs/libva-1.4.0[drm?,X?,wayland?] ) |
217 |
- wayland? ( |
218 |
- >=dev-libs/wayland-1.6.0 |
219 |
- >=x11-libs/libxkbcommon-0.3.0 |
220 |
- ) |
221 |
- X? ( |
222 |
- x11-libs/libX11 |
223 |
- x11-libs/libXext |
224 |
- >=x11-libs/libXrandr-1.2.0 |
225 |
- opengl? ( x11-libs/libXdamage ) |
226 |
- vdpau? ( >=x11-libs/libvdpau-0.2 ) |
227 |
- xinerama? ( x11-libs/libXinerama ) |
228 |
- xscreensaver? ( x11-libs/libXScrnSaver ) |
229 |
- xv? ( x11-libs/libXv ) |
230 |
- ) |
231 |
-" |
232 |
-DEPEND="${COMMON_DEPEND} |
233 |
- ${PYTHON_DEPS} |
234 |
- >=dev-lang/perl-5.8 |
235 |
- dev-python/docutils |
236 |
- virtual/pkgconfig |
237 |
- doc? ( dev-python/rst2pdf ) |
238 |
- test? ( >=dev-util/cmocka-1.0.0 ) |
239 |
-" |
240 |
-RDEPEND="${COMMON_DEPEND} |
241 |
- selinux? ( sec-policy/selinux-mplayer ) |
242 |
-" |
243 |
- |
244 |
-pkg_pretend() { |
245 |
- if [[ ${MERGE_TYPE} != "binary" ]] && ! tc-has-tls && use vaapi && use egl; then |
246 |
- die "Your compiler lacks C++11 TLS support. Use GCC>=4.8.0 or Clang>=3.3." |
247 |
- fi |
248 |
-} |
249 |
- |
250 |
-src_prepare() { |
251 |
- cp "${DISTDIR}/waf-${WAF_PV}" "${S}"/waf || die |
252 |
- chmod +x "${S}"/waf || die |
253 |
- default_src_prepare |
254 |
- EPATCH_SUFFIX=patch EPATCH_FORCE=yes epatch "${WORKDIR}/${PV}" |
255 |
-} |
256 |
- |
257 |
-src_configure() { |
258 |
- local mywafargs=( |
259 |
- --confdir="${EPREFIX}/etc/${PN}" |
260 |
- --docdir="${EPREFIX}/usr/share/doc/${PF}" |
261 |
- |
262 |
- --disable-gpl3 # Unclear license info. See Gentoo bug 571728. |
263 |
- |
264 |
- $(usex cli '' '--disable-cplayer') |
265 |
- $(use_enable libmpv libmpv-shared) |
266 |
- |
267 |
- # See deep down below for build-date. |
268 |
- --disable-libmpv-static |
269 |
- --disable-static-build |
270 |
- --disable-optimize # Don't add '-O2' to CFLAGS. |
271 |
- --disable-debug-build # Don't add '-g' to CFLAGS. |
272 |
- |
273 |
- $(use_enable doc html-build) |
274 |
- $(use_enable doc pdf-build) |
275 |
- $(use_enable vf-dlopen vf-dlopen-filters) |
276 |
- $(use_enable zsh-completion zsh-comp) |
277 |
- $(use_enable test) |
278 |
- |
279 |
- $(use_enable iconv) |
280 |
- $(use_enable samba libsmbclient) |
281 |
- $(use_enable lua) |
282 |
- $(usex luajit '--lua=luajit' '') |
283 |
- $(use_enable libass) |
284 |
- $(use_enable libass libass-osd) |
285 |
- $(use_enable encode encoding) |
286 |
- $(use_enable bluray libbluray) |
287 |
- $(use_enable dvd dvdread) |
288 |
- $(use_enable dvd dvdnav) |
289 |
- $(use_enable cdda) |
290 |
- $(use_enable enca) |
291 |
- $(use_enable libguess) |
292 |
- $(use_enable uchardet) |
293 |
- $(use_enable rubberband) |
294 |
- $(use_enable lcms lcms2) |
295 |
- --disable-vapoursynth # Only available in overlays. |
296 |
- --disable-vapoursynth-lazy |
297 |
- $(use_enable archive libarchive) |
298 |
- |
299 |
- --enable-libavdevice |
300 |
- |
301 |
- # Audio outputs: |
302 |
- $(use_enable sdl sdl2) # Listed under audio, but also includes video. |
303 |
- --disable-sdl1 |
304 |
- $(use_enable oss oss-audio) |
305 |
- --disable-rsound # Only available in overlays. |
306 |
- $(use_enable pulseaudio pulse) |
307 |
- $(use_enable jack) |
308 |
- $(use_enable openal) |
309 |
- --disable-opensles |
310 |
- $(use_enable alsa) |
311 |
- $(use_enable coreaudio) |
312 |
- |
313 |
- # Video outputs: |
314 |
- $(use_enable aqua cocoa) |
315 |
- $(use_enable drm) |
316 |
- $(use_enable gbm) |
317 |
- $(use_enable wayland) |
318 |
- $(use_enable X x11) |
319 |
- $(use_enable xscreensaver xss) |
320 |
- $(use_enable X xext) |
321 |
- $(use_enable xv) |
322 |
- $(use_enable xinerama) |
323 |
- $(use_enable X xrandr) |
324 |
- $(usex opengl "$(use_enable aqua gl-cocoa)" '--disable-gl-cocoa') |
325 |
- $(usex opengl "$(use_enable X gl-x11)" '--disable-gl-x11') |
326 |
- $(usex egl "$(use_enable X egl-x11)" '--disable-egl-x11') |
327 |
- $(usex egl "$(use_enable gbm egl-drm)" '--disable-egl-drm') |
328 |
- $(use_enable wayland gl-wayland) |
329 |
- $(use_enable vdpau) |
330 |
- $(usex vdpau "$(use_enable opengl vdpau-gl-x11)" '--disable-vdpau-gl-x11') |
331 |
- $(use_enable vaapi) # See below for vaapi-glx, vaapi-x-egl. |
332 |
- $(usex vaapi "$(use_enable X vaapi-x11)" '--disable-vaapi-x11') |
333 |
- $(usex vaapi "$(use_enable wayland vaapi-wayland)" '--disable-vaapi-wayland') |
334 |
- $(usex vaapi "$(use_enable gbm vaapi-drm)" '--disable-vaapi-drm') |
335 |
- $(use_enable libcaca caca) |
336 |
- $(use_enable jpeg) |
337 |
- --disable-android |
338 |
- $(use_enable raspberry-pi rpi) |
339 |
- $(usex libmpv "$(use_enable opengl plain-gl)" '--disable-plain-gl') |
340 |
- |
341 |
- # HWaccels: |
342 |
- # Automagic Video Toolbox HW acceleration. See Gentoo bug 577332. |
343 |
- $(use_enable vaapi vaapi-hwaccel) |
344 |
- # Automagic VDPAU HW acceleration. See Gentoo bug 558870. |
345 |
- |
346 |
- # TV features: |
347 |
- $(use_enable v4l tv) |
348 |
- $(use_enable v4l tv-v4l2) |
349 |
- $(use_enable v4l libv4l2) |
350 |
- $(use_enable v4l audio-input) |
351 |
- $(use_enable dvb dvbin) |
352 |
- |
353 |
- # Miscellaneous features: |
354 |
- --disable-apple-remote # Needs testing first. See Gentoo bug 577332. |
355 |
- ) |
356 |
- |
357 |
- if use vaapi && use X; then |
358 |
- mywafargs+=( |
359 |
- $(use_enable opengl vaapi-glx) |
360 |
- $(use_enable egl vaapi-x-egl) |
361 |
- ) |
362 |
- fi |
363 |
- |
364 |
- # Create reproducible non-live builds. |
365 |
- [[ ${PV} != *9999* ]] && mywafargs+=(--disable-build-date) |
366 |
- |
367 |
- waf-utils_src_configure "${mywafargs[@]}" |
368 |
-} |
369 |
- |
370 |
-src_install() { |
371 |
- waf-utils_src_install |
372 |
- |
373 |
- if use cli && use luajit; then |
374 |
- pax-mark -m "${ED}"usr/bin/${PN} |
375 |
- fi |
376 |
-} |
377 |
- |
378 |
-pkg_preinst() { |
379 |
- gnome2_icon_savelist |
380 |
-} |
381 |
- |
382 |
-pkg_postinst() { |
383 |
- fdo-mime_desktop_database_update |
384 |
- gnome2_icon_cache_update |
385 |
- |
386 |
- # bash-completion < 2.3-r1 already installs (mostly broken) mpv completion. |
387 |
- if use cli && ! has_version '<app-shells/bash-completion-2.3-r1' && \ |
388 |
- ! has_version 'app-shells/mpv-bash-completion'; then |
389 |
- elog "If you want to have command-line completion via bash-completion," |
390 |
- elog "please install app-shells/mpv-bash-completion." |
391 |
- fi |
392 |
- |
393 |
- if use cli && [[ -n ${REPLACING_VERSIONS} ]] && \ |
394 |
- has_version 'app-shells/mpv-bash-completion'; then |
395 |
- elog "If command-line completion doesn't work after mpv update," |
396 |
- elog "please rebuild app-shells/mpv-bash-completion." |
397 |
- fi |
398 |
-} |
399 |
- |
400 |
-pkg_postrm() { |
401 |
- fdo-mime_desktop_database_update |
402 |
- gnome2_icon_cache_update |
403 |
-} |
404 |
- |
405 |
-src_test() { |
406 |
- cd "${S}"/build/test || die |
407 |
- for test in *; do |
408 |
- if [[ -x ${test} ]]; then |
409 |
- ./"${test}" || die "Test suite failed" |
410 |
- fi |
411 |
- done |
412 |
-} |
413 |
|
414 |
diff --git a/media-video/mpv/mpv-0.17.0.ebuild b/media-video/mpv/mpv-0.17.0.ebuild |
415 |
deleted file mode 100644 |
416 |
index aa01e11..0000000 |
417 |
--- a/media-video/mpv/mpv-0.17.0.ebuild |
418 |
+++ /dev/null |
419 |
@@ -1,288 +0,0 @@ |
420 |
-# Copyright 1999-2016 Gentoo Foundation |
421 |
-# Distributed under the terms of the GNU General Public License v2 |
422 |
-# $Id$ |
423 |
- |
424 |
-EAPI=6 |
425 |
- |
426 |
-PYTHON_COMPAT=( python{2_7,3_3,3_4,3_5} ) |
427 |
-PYTHON_REQ_USE='threads(+)' |
428 |
- |
429 |
-WAF_PV='1.8.12' |
430 |
- |
431 |
-inherit fdo-mime gnome2-utils pax-utils python-any-r1 toolchain-funcs waf-utils |
432 |
- |
433 |
-DESCRIPTION="Media player based on MPlayer and mplayer2" |
434 |
-HOMEPAGE="https://mpv.io/" |
435 |
- |
436 |
-if [[ ${PV} != *9999* ]]; then |
437 |
- SRC_URI="https://github.com/mpv-player/mpv/archive/v${PV}.tar.gz -> ${P}.tar.gz" |
438 |
- KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux" |
439 |
- DOCS=( RELEASE_NOTES ) |
440 |
-else |
441 |
- EGIT_REPO_URI="https://github.com/mpv-player/mpv.git" |
442 |
- inherit git-r3 |
443 |
-fi |
444 |
-SRC_URI+=" https://waf.io/waf-${WAF_PV}" |
445 |
-DOCS+=( README.md ) |
446 |
- |
447 |
-# See Copyright in source tarball and bug #506946. Waf is BSD, libmpv is ISC. |
448 |
-LICENSE="GPL-2+ BSD ISC" |
449 |
-SLOT="0" |
450 |
-IUSE="aqua +alsa archive bluray cdda +cli coreaudio doc drm dvb +dvd +egl +enca |
451 |
- encode gbm +iconv jack jpeg lcms +libass libav libcaca libguess libmpv lua |
452 |
- luajit openal +opengl oss pulseaudio raspberry-pi rubberband samba -sdl |
453 |
- selinux test uchardet v4l vaapi vdpau vf-dlopen wayland +X xinerama |
454 |
- +xscreensaver +xv zsh-completion" |
455 |
- |
456 |
-REQUIRED_USE=" |
457 |
- || ( cli libmpv ) |
458 |
- aqua? ( opengl ) |
459 |
- egl? ( || ( gbm X wayland ) ) |
460 |
- enca? ( iconv ) |
461 |
- gbm? ( drm egl ) |
462 |
- lcms? ( || ( opengl egl ) ) |
463 |
- libguess? ( iconv ) |
464 |
- luajit? ( lua ) |
465 |
- uchardet? ( iconv ) |
466 |
- v4l? ( || ( alsa oss ) ) |
467 |
- vaapi? ( || ( gbm X wayland ) ) |
468 |
- vdpau? ( X ) |
469 |
- wayland? ( egl ) |
470 |
- xinerama? ( X ) |
471 |
- xscreensaver? ( X ) |
472 |
- xv? ( X ) |
473 |
- zsh-completion? ( cli ) |
474 |
-" |
475 |
- |
476 |
-COMMON_DEPEND=" |
477 |
- !libav? ( >=media-video/ffmpeg-2.4:0=[encode?,threads,vaapi?,vdpau?] ) |
478 |
- libav? ( >=media-video/libav-11:0=[encode?,threads,vaapi?,vdpau?] ) |
479 |
- sys-libs/zlib |
480 |
- alsa? ( >=media-libs/alsa-lib-1.0.18 ) |
481 |
- archive? ( >=app-arch/libarchive-3.0.0:= ) |
482 |
- bluray? ( >=media-libs/libbluray-0.3.0 ) |
483 |
- cdda? ( dev-libs/libcdio-paranoia ) |
484 |
- drm? ( x11-libs/libdrm ) |
485 |
- dvb? ( virtual/linuxtv-dvb-headers ) |
486 |
- dvd? ( |
487 |
- >=media-libs/libdvdnav-4.2.0 |
488 |
- >=media-libs/libdvdread-4.1.0 |
489 |
- ) |
490 |
- egl? ( media-libs/mesa[egl,gbm(-)?,wayland(-)?] ) |
491 |
- iconv? ( |
492 |
- virtual/libiconv |
493 |
- enca? ( app-i18n/enca ) |
494 |
- libguess? ( >=app-i18n/libguess-1.0 ) |
495 |
- uchardet? ( dev-libs/uchardet ) |
496 |
- ) |
497 |
- jack? ( virtual/jack ) |
498 |
- jpeg? ( virtual/jpeg:0 ) |
499 |
- lcms? ( >=media-libs/lcms-2.6:2 ) |
500 |
- libass? ( |
501 |
- >=media-libs/libass-0.12.1:=[fontconfig,harfbuzz] |
502 |
- virtual/ttf-fonts |
503 |
- ) |
504 |
- libcaca? ( >=media-libs/libcaca-0.99_beta18 ) |
505 |
- lua? ( |
506 |
- !luajit? ( || ( =dev-lang/lua-5.1*:= =dev-lang/lua-5.2*:= ) ) |
507 |
- luajit? ( dev-lang/luajit:2 ) |
508 |
- ) |
509 |
- openal? ( >=media-libs/openal-1.13 ) |
510 |
- opengl? ( !aqua? ( virtual/opengl ) ) |
511 |
- pulseaudio? ( media-sound/pulseaudio ) |
512 |
- raspberry-pi? ( |
513 |
- >=media-libs/raspberrypi-userland-0_pre20160305-r1 |
514 |
- media-libs/mesa[egl,gles2] |
515 |
- ) |
516 |
- rubberband? ( >=media-libs/rubberband-1.8.0 ) |
517 |
- samba? ( net-fs/samba ) |
518 |
- sdl? ( media-libs/libsdl2[sound,threads,video,X?,wayland?] ) |
519 |
- v4l? ( media-libs/libv4l ) |
520 |
- vaapi? ( >=x11-libs/libva-1.4.0[drm?,X?,wayland?] ) |
521 |
- wayland? ( |
522 |
- >=dev-libs/wayland-1.6.0 |
523 |
- >=x11-libs/libxkbcommon-0.3.0 |
524 |
- ) |
525 |
- X? ( |
526 |
- x11-libs/libX11 |
527 |
- x11-libs/libXext |
528 |
- >=x11-libs/libXrandr-1.2.0 |
529 |
- opengl? ( x11-libs/libXdamage ) |
530 |
- vdpau? ( >=x11-libs/libvdpau-0.2 ) |
531 |
- xinerama? ( x11-libs/libXinerama ) |
532 |
- xscreensaver? ( x11-libs/libXScrnSaver ) |
533 |
- xv? ( x11-libs/libXv ) |
534 |
- ) |
535 |
-" |
536 |
-DEPEND="${COMMON_DEPEND} |
537 |
- ${PYTHON_DEPS} |
538 |
- >=dev-lang/perl-5.8 |
539 |
- dev-python/docutils |
540 |
- virtual/pkgconfig |
541 |
- doc? ( dev-python/rst2pdf ) |
542 |
- test? ( >=dev-util/cmocka-1.0.0 ) |
543 |
-" |
544 |
-RDEPEND="${COMMON_DEPEND} |
545 |
- selinux? ( sec-policy/selinux-mplayer ) |
546 |
-" |
547 |
- |
548 |
-PATCHES=( |
549 |
- "${FILESDIR}/${PV}/${P}-fix-seeking-without-first-index-entry.patch" |
550 |
- "${FILESDIR}/${PV}/${P}-add-missing-math-include.patch" |
551 |
-) |
552 |
- |
553 |
-pkg_pretend() { |
554 |
- if [[ ${MERGE_TYPE} != "binary" ]] && ! tc-has-tls && use vaapi && use egl; then |
555 |
- die "Your compiler lacks C++11 TLS support. Use GCC>=4.8.0 or Clang>=3.3." |
556 |
- fi |
557 |
-} |
558 |
- |
559 |
-src_prepare() { |
560 |
- cp "${DISTDIR}/waf-${WAF_PV}" "${S}"/waf || die |
561 |
- chmod +x "${S}"/waf || die |
562 |
- default |
563 |
-} |
564 |
- |
565 |
-src_configure() { |
566 |
- local mywafargs=( |
567 |
- --confdir="${EPREFIX}"/etc/${PN} |
568 |
- --docdir="${EPREFIX}"/usr/share/doc/${PF} |
569 |
- |
570 |
- --disable-gpl3 # Unclear license info. See Gentoo bug 571728. |
571 |
- |
572 |
- $(usex cli '' '--disable-cplayer') |
573 |
- $(use_enable libmpv libmpv-shared) |
574 |
- |
575 |
- # See deep down below for build-date |
576 |
- --disable-libmpv-static |
577 |
- --disable-static-build |
578 |
- --disable-optimize # Do not add '-O2' to CFLAGS |
579 |
- --disable-debug-build # Do not add '-g' to CFLAGS |
580 |
- |
581 |
- $(use_enable doc html-build) |
582 |
- $(use_enable doc pdf-build) |
583 |
- $(use_enable vf-dlopen vf-dlopen-filters) |
584 |
- $(use_enable zsh-completion zsh-comp) |
585 |
- $(use_enable test) |
586 |
- |
587 |
- $(use_enable iconv) |
588 |
- $(use_enable samba libsmbclient) |
589 |
- $(use_enable lua) |
590 |
- $(usex luajit '--lua=luajit' '') |
591 |
- $(use_enable libass) |
592 |
- $(use_enable libass libass-osd) |
593 |
- $(use_enable encode encoding) |
594 |
- $(use_enable bluray libbluray) |
595 |
- $(use_enable dvd dvdread) |
596 |
- $(use_enable dvd dvdnav) |
597 |
- $(use_enable cdda) |
598 |
- $(use_enable enca) |
599 |
- $(use_enable libguess) |
600 |
- $(use_enable uchardet) |
601 |
- $(use_enable rubberband) |
602 |
- $(use_enable lcms lcms2) |
603 |
- --disable-vapoursynth # Only available in overlays |
604 |
- --disable-vapoursynth-lazy |
605 |
- $(use_enable archive libarchive) |
606 |
- |
607 |
- --enable-libavdevice |
608 |
- |
609 |
- # Audio outputs |
610 |
- $(use_enable sdl sdl2) # Listed under audio, but also includes video |
611 |
- --disable-sdl1 |
612 |
- $(use_enable oss oss-audio) |
613 |
- --disable-rsound # Only available in overlays |
614 |
- $(use_enable pulseaudio pulse) |
615 |
- $(use_enable jack) |
616 |
- $(use_enable openal) |
617 |
- --disable-opensles |
618 |
- $(use_enable alsa) |
619 |
- $(use_enable coreaudio) |
620 |
- |
621 |
- # Video outputs |
622 |
- $(use_enable aqua cocoa) |
623 |
- $(use_enable drm) |
624 |
- $(use_enable gbm) |
625 |
- $(use_enable wayland) |
626 |
- $(use_enable X x11) |
627 |
- $(use_enable xscreensaver xss) |
628 |
- $(use_enable X xext) |
629 |
- $(use_enable xv) |
630 |
- $(use_enable xinerama) |
631 |
- $(use_enable X xrandr) |
632 |
- $(usex opengl "$(use_enable aqua gl-cocoa)" '--disable-gl-cocoa') |
633 |
- $(usex opengl "$(use_enable X gl-x11)" '--disable-gl-x11') |
634 |
- $(usex egl "$(use_enable X egl-x11)" '--disable-egl-x11') |
635 |
- $(usex egl "$(use_enable gbm egl-drm)" '--disable-egl-drm') |
636 |
- $(use_enable wayland gl-wayland) |
637 |
- $(use_enable vdpau) |
638 |
- $(usex vdpau "$(use_enable opengl vdpau-gl-x11)" '--disable-vdpau-gl-x11') |
639 |
- $(use_enable vaapi) # See below for vaapi-glx, vaapi-x-egl |
640 |
- $(usex vaapi "$(use_enable X vaapi-x11)" '--disable-vaapi-x11') |
641 |
- $(usex vaapi "$(use_enable wayland vaapi-wayland)" '--disable-vaapi-wayland') |
642 |
- $(usex vaapi "$(use_enable gbm vaapi-drm)" '--disable-vaapi-drm') |
643 |
- $(use_enable libcaca caca) |
644 |
- $(use_enable jpeg) |
645 |
- --disable-android |
646 |
- $(use_enable raspberry-pi rpi) |
647 |
- $(usex libmpv "$(use_enable opengl plain-gl)" '--disable-plain-gl') |
648 |
- |
649 |
- # HWaccels |
650 |
- # Automagic Video Toolbox HW acceleration. See Gentoo bug 577332. |
651 |
- $(use_enable vaapi vaapi-hwaccel) |
652 |
- # Automagic VDPAU HW acceleration. See Gentoo bug 558870. |
653 |
- |
654 |
- # TV features |
655 |
- $(use_enable v4l tv) |
656 |
- $(use_enable v4l tv-v4l2) |
657 |
- $(use_enable v4l libv4l2) |
658 |
- $(use_enable v4l audio-input) |
659 |
- $(use_enable dvb dvbin) |
660 |
- |
661 |
- # Miscellaneous features |
662 |
- --disable-apple-remote # Needs testing first. See Gentoo bug 577332. |
663 |
- ) |
664 |
- |
665 |
- if use vaapi && use X; then |
666 |
- mywafargs+=( |
667 |
- $(use_enable opengl vaapi-glx) |
668 |
- $(use_enable egl vaapi-x-egl) |
669 |
- ) |
670 |
- fi |
671 |
- |
672 |
- # Create reproducible non-live builds |
673 |
- [[ ${PV} != *9999* ]] && mywafargs+=(--disable-build-date) |
674 |
- |
675 |
- waf-utils_src_configure "${mywafargs[@]}" |
676 |
-} |
677 |
- |
678 |
-src_install() { |
679 |
- waf-utils_src_install |
680 |
- |
681 |
- if use cli && use luajit; then |
682 |
- pax-mark -m "${ED}usr/bin/${PN}" |
683 |
- fi |
684 |
-} |
685 |
- |
686 |
-pkg_preinst() { |
687 |
- gnome2_icon_savelist |
688 |
-} |
689 |
- |
690 |
-pkg_postinst() { |
691 |
- fdo-mime_desktop_database_update |
692 |
- gnome2_icon_cache_update |
693 |
-} |
694 |
- |
695 |
-pkg_postrm() { |
696 |
- fdo-mime_desktop_database_update |
697 |
- gnome2_icon_cache_update |
698 |
-} |
699 |
- |
700 |
-src_test() { |
701 |
- cd "${S}"/build/test || die |
702 |
- for test in *; do |
703 |
- if [[ -x ${test} ]]; then |
704 |
- ./"${test}" || die "Test suite failed" |
705 |
- fi |
706 |
- done |
707 |
-} |