Gentoo Archives: gentoo-commits

From: Alexis Ballier <aballier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-video/ffmpeg/files/, media-video/ffmpeg/
Date: Mon, 02 Sep 2019 12:00:24
Message-Id: 1567425589.587ca78f0114a1718bd803ebc8a18e322510efdd.aballier@gentoo
1 commit: 587ca78f0114a1718bd803ebc8a18e322510efdd
2 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org>
3 AuthorDate: Mon Sep 2 10:46:00 2019 +0000
4 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org>
5 CommitDate: Mon Sep 2 11:59:49 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=587ca78f
7
8 media-video/ffmpeg: remove old
9
10 Package-Manager: Portage-2.3.73, Repoman-2.3.17
11 Signed-off-by: Alexis Ballier <aballier <AT> gentoo.org>
12
13 media-video/ffmpeg/Manifest | 5 -
14 media-video/ffmpeg/ffmpeg-3.2.6.ebuild | 457 -------------------
15 media-video/ffmpeg/ffmpeg-3.2.7.ebuild | 457 -------------------
16 media-video/ffmpeg/ffmpeg-3.3.4.ebuild | 505 ---------------------
17 media-video/ffmpeg/ffmpeg-3.3.6.ebuild | 505 ---------------------
18 media-video/ffmpeg/ffmpeg-3.3.8.ebuild | 505 ---------------------
19 media-video/ffmpeg/files/ffmpeg32-openjpeg22.patch | 106 -----
20 media-video/ffmpeg/files/openjpeg22.patch | 106 -----
21 media-video/ffmpeg/files/openjpeg23.patch | 109 -----
22 media-video/ffmpeg/metadata.xml | 6 -
23 10 files changed, 2761 deletions(-)
24
25 diff --git a/media-video/ffmpeg/Manifest b/media-video/ffmpeg/Manifest
26 index 125dc130555..e9f02b9e227 100644
27 --- a/media-video/ffmpeg/Manifest
28 +++ b/media-video/ffmpeg/Manifest
29 @@ -1,8 +1,3 @@
30 -DIST ffmpeg-3.2.6.tar.bz2 9623111 BLAKE2B 76ed10d969ec5e85c0ad23fee1118ccfd66689b07062dc51526fca5427507124751d957b57b1a002ba585b9d35afc80cc6f3113c559b160b2751fc526b3d304f SHA512 eca75524374003eac78033bd2a744b459a4dc631c59150b6c9291e06a693bdd14e0b11cae9c800446f0648edccc066480c2b869bcb456a74eeabb91ab41f8285
31 -DIST ffmpeg-3.2.7.tar.bz2 9622391 BLAKE2B 7d6f094ca0bd5e2cab02e051acc8e554873bca2d165fc9326de0b12e145ec939567aed95c01589c47291970a89fb3462c75d32db1c4c2c8cf6d4a14956cd8a79 SHA512 a5b6df77d2d4ede0cc2f398b763d7405f43f43e37c11a596ec1a2a8921714875fd8fa9ffbcff84355854780872ab7313c859a4a19bf419298b4d3bc797ad8ac4
32 -DIST ffmpeg-3.3.4.tar.bz2 9944256 BLAKE2B 72d42a16396882b30641fb057bb597f8e98ecfa482a087ece48189acba8a80a72e931e70ad961db8c01c93a556f619ebdecb39bae9d4559cc504d0f7eabf15a7 SHA512 d2257a71f9ae7856390b807d70bf643d4360fe4f2ad7c76af3ac5332cda353a1a543cdcdea0c510dbb6141f7a3a36ffbf26ae87b0ffc9ce4b3b7641814a40e3a
33 -DIST ffmpeg-3.3.6.tar.bz2 9943322 BLAKE2B 2526fdf9580045131426e554a9bf44fdc6567c12213ea4d5b78aa27f14513f14e07f38b8380183686fa1a62440fe4108eaecddca96f4dec3c74c410b1f90ee03 SHA512 1305760fa981bcb43c8fcb5dd1bf7dd8d3f405a124975f062062b741d49e12386e4d3eec3de6a032fc93cd7f6086d939275a669a9997ffa400f70c20f7eb3d23
34 -DIST ffmpeg-3.3.8.tar.bz2 9953307 BLAKE2B edd3c2ce9730494455a05ec9d81b6c2ceb0ebf526124f95a530214cdb113ffe91aa13b80a66501aefa4f571c5b8f2eedb97f8086370d08e3b4e2a98d517eb92b SHA512 a793f6d0a06ff5244a580d9e54e1252d3ac88e2513dad4d137081103327ae4440ebe9b0d60a13f93536cb6b35097982ea76acc4056bfa31683063eef5c211ede
35 DIST ffmpeg-3.4.5.tar.bz2 10183082 BLAKE2B f72157baefcd6a0ca8f389309bbe947ad21996e0f2eb3c46c6bfc90f1ebbb14bfd007d001e46ea51efef5db5f9fcee24b1a90b6862136aeebecdc95bb61b23a5 SHA512 e12707d47404a9ce02790b77d2852fc1a1573c8108e980c7355fa48ba891d1649464d4fe4d08394ecd6d871f651ac4388486b7654cb54a7aaeedaf05c55513ec
36 DIST ffmpeg-3.4.6.tar.bz2 10190001 BLAKE2B 4c7842900171cf871f8524f08f435797b1a168faa11877100fe74c3ecd4a2c2e004a5110dc23bda818f69b0a484f63d8f34c7904c4827c88894d877cdd70c6fe SHA512 0228751b288096e368f9049854936930b7c1fd89aac31a5382f5de78d3282b4e86a6f562c79833d1635222f0ad56b2e5401a150574714e1b7e0ab4f5d8939812
37 DIST ffmpeg-4.1.1.tar.bz2 10686360 BLAKE2B 47f4716d7e184d7318eb1a99ab1cdc188009464e973162e583f7ca4ae79fa3b103f9d5329c8993b72d20667e42e5a749123709a4640f07762568300b5c3c897f SHA512 0241c44e1dffd0d890a3d30a1b2387ea167d578bb39ba0c804fb417e132d343a9e43da9247b205e18b893d8cf75d8528e9971569be67ac380b88618ef0a75ed4
38
39 diff --git a/media-video/ffmpeg/ffmpeg-3.2.6.ebuild b/media-video/ffmpeg/ffmpeg-3.2.6.ebuild
40 deleted file mode 100644
41 index a6291d34e90..00000000000
42 --- a/media-video/ffmpeg/ffmpeg-3.2.6.ebuild
43 +++ /dev/null
44 @@ -1,457 +0,0 @@
45 -# Copyright 1999-2018 Gentoo Authors
46 -# Distributed under the terms of the GNU General Public License v2
47 -
48 -EAPI=6
49 -
50 -# Subslot: libavutil major.libavcodec major.libavformat major
51 -# Since FFmpeg ships several libraries, subslot is kind of limited here.
52 -# Most consumers will use those three libraries, if a "less used" library
53 -# changes its soname, consumers will have to be rebuilt the old way
54 -# (preserve-libs).
55 -# If, for example, a package does not link to libavformat and only libavformat
56 -# changes its ABI then this package will be rebuilt needlessly. Hence, such a
57 -# package is free _not_ to := depend on FFmpeg but I would strongly encourage
58 -# doing so since such a case is unlikely.
59 -FFMPEG_SUBSLOT=55.57.57
60 -
61 -SCM=""
62 -if [ "${PV#9999}" != "${PV}" ] ; then
63 - SCM="git-r3"
64 - EGIT_REPO_URI="git://source.ffmpeg.org/ffmpeg.git"
65 -fi
66 -
67 -inherit eutils flag-o-matic multilib multilib-minimal toolchain-funcs ${SCM}
68 -
69 -DESCRIPTION="Complete solution to record, convert and stream audio and video. Includes libavcodec"
70 -HOMEPAGE="http://ffmpeg.org/"
71 -if [ "${PV#9999}" != "${PV}" ] ; then
72 - SRC_URI=""
73 -elif [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot
74 - SRC_URI="mirror://gentoo/${P}.tar.bz2"
75 -else # Release
76 - SRC_URI="http://ffmpeg.org/releases/${P/_/-}.tar.bz2"
77 -fi
78 -FFMPEG_REVISION="${PV#*_p}"
79 -
80 -SLOT="0/${FFMPEG_SUBSLOT}"
81 -LICENSE="
82 - !gpl? ( LGPL-2.1 )
83 - gpl? ( GPL-2 )
84 - amr? (
85 - gpl? ( GPL-3 )
86 - !gpl? ( LGPL-3 )
87 - )
88 - gmp? (
89 - gpl? ( GPL-3 )
90 - !gpl? ( LGPL-3 )
91 - )
92 - encode? (
93 - amrenc? (
94 - gpl? ( GPL-3 )
95 - !gpl? ( LGPL-3 )
96 - )
97 - )
98 - samba? ( GPL-3 )
99 -"
100 -if [ "${PV#9999}" = "${PV}" ] ; then
101 - KEYWORDS="alpha amd64 arm ~hppa ia64 ~mips ~ppc ~ppc64 x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
102 -fi
103 -
104 -# Options to use as use_enable in the foo[:bar] form.
105 -# This will feed configure with $(use_enable foo bar)
106 -# or $(use_enable foo foo) if no :bar is set.
107 -# foo is added to IUSE.
108 -FFMPEG_FLAG_MAP=(
109 - +bzip2:bzlib cpudetection:runtime-cpudetect debug gcrypt gnutls gmp
110 - +gpl +hardcoded-tables +iconv lzma +network openssl +postproc
111 - samba:libsmbclient sdl:ffplay sdl:sdl2 vaapi vdpau X:xlib xcb:libxcb
112 - xcb:libxcb-shm xcb:libxcb-xfixes +zlib
113 - # libavdevice options
114 - cdio:libcdio iec61883:libiec61883 ieee1394:libdc1394 libcaca openal
115 - opengl
116 - # indevs
117 - libv4l:libv4l2 pulseaudio:libpulse
118 - # decoders
119 - amr:libopencore-amrwb amr:libopencore-amrnb fdk:libfdk-aac
120 - jpeg2k:libopenjpeg bluray:libbluray gme:libgme gsm:libgsm
121 - mmal modplug:libmodplug opus:libopus libilbc librtmp ssh:libssh
122 - speex:libspeex vorbis:libvorbis vpx:libvpx
123 - zvbi:libzvbi
124 - # libavfilter options
125 - bs2b:libbs2b chromaprint ebur128:libebur128 flite:libflite frei0r
126 - fribidi:libfribidi fontconfig ladspa libass truetype:libfreetype
127 - rubberband:librubberband zimg:libzimg
128 - # libswresample options
129 - libsoxr
130 - # Threads; we only support pthread for now but ffmpeg supports more
131 - +threads:pthreads
132 -)
133 -
134 -# Same as above but for encoders, i.e. they do something only with USE=encode.
135 -FFMPEG_ENCODER_FLAG_MAP=(
136 - amrenc:libvo-amrwbenc mp3:libmp3lame
137 - kvazaar:libkvazaar nvenc:nvenc
138 - openh264:libopenh264 snappy:libsnappy theora:libtheora twolame:libtwolame
139 - wavpack:libwavpack webp:libwebp x264:libx264 x265:libx265 xvid:libxvid
140 -)
141 -
142 -IUSE="
143 - alsa doc +encode jack oss pic static-libs test v4l
144 - ${FFMPEG_FLAG_MAP[@]%:*}
145 - ${FFMPEG_ENCODER_FLAG_MAP[@]%:*}
146 -"
147 -
148 -# Strings for CPU features in the useflag[:configure_option] form
149 -# if :configure_option isn't set, it will use 'useflag' as configure option
150 -ARM_CPU_FEATURES=( armv5te armv6 armv6t2 neon armvfp:vfp )
151 -MIPS_CPU_FEATURES=( mipsdspr1 mipsdspr2 mipsfpu )
152 -PPC_CPU_FEATURES=( altivec )
153 -X86_CPU_FEATURES_RAW=( 3dnow:amd3dnow 3dnowext:amd3dnowext aes:aesni avx:avx avx2:avx2 fma3:fma3 fma4:fma4 mmx:mmx mmxext:mmxext sse:sse sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4 sse4_2:sse42 xop:xop )
154 -X86_CPU_FEATURES=( ${X86_CPU_FEATURES_RAW[@]/#/cpu_flags_x86_} )
155 -X86_CPU_REQUIRED_USE="
156 - cpu_flags_x86_avx2? ( cpu_flags_x86_avx )
157 - cpu_flags_x86_fma4? ( cpu_flags_x86_avx )
158 - cpu_flags_x86_fma3? ( cpu_flags_x86_avx )
159 - cpu_flags_x86_xop? ( cpu_flags_x86_avx )
160 - cpu_flags_x86_avx? ( cpu_flags_x86_sse4_2 )
161 - cpu_flags_x86_aes? ( cpu_flags_x86_sse4_2 )
162 - cpu_flags_x86_sse4_2? ( cpu_flags_x86_sse4_1 )
163 - cpu_flags_x86_sse4_1? ( cpu_flags_x86_ssse3 )
164 - cpu_flags_x86_ssse3? ( cpu_flags_x86_sse3 )
165 - cpu_flags_x86_sse3? ( cpu_flags_x86_sse2 )
166 - cpu_flags_x86_sse2? ( cpu_flags_x86_sse )
167 - cpu_flags_x86_sse? ( cpu_flags_x86_mmxext )
168 - cpu_flags_x86_mmxext? ( cpu_flags_x86_mmx )
169 - cpu_flags_x86_3dnowext? ( cpu_flags_x86_3dnow )
170 - cpu_flags_x86_3dnow? ( cpu_flags_x86_mmx )
171 -"
172 -
173 -IUSE="${IUSE}
174 - ${ARM_CPU_FEATURES[@]%:*}
175 - ${MIPS_CPU_FEATURES[@]%:*}
176 - ${PPC_CPU_FEATURES[@]%:*}
177 - ${X86_CPU_FEATURES[@]%:*}
178 -"
179 -
180 -CPU_REQUIRED_USE="
181 - ${X86_CPU_REQUIRED_USE}
182 -"
183 -
184 -# "$(tc-arch):XXX" form where XXX_CPU_FEATURES are the cpu features that apply to
185 -# $(tc-arch).
186 -CPU_FEATURES_MAP="
187 - arm:ARM
188 - arm64:ARM
189 - mips:MIPS
190 - ppc:PPC
191 - ppc64:PPC
192 - x86:X86
193 - amd64:X86
194 -"
195 -
196 -FFTOOLS=( aviocat cws2fws ffescape ffeval ffhash fourcc2pixfmt graph2dot ismindex pktdumper qt-faststart sidxindex trasher )
197 -IUSE="${IUSE} ${FFTOOLS[@]/#/+fftools_}"
198 -
199 -RDEPEND="
200 - alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] )
201 - amr? ( >=media-libs/opencore-amr-0.1.3-r1[${MULTILIB_USEDEP}] )
202 - bluray? ( >=media-libs/libbluray-0.3.0-r1:=[${MULTILIB_USEDEP}] )
203 - bs2b? ( >=media-libs/libbs2b-3.1.0-r1[${MULTILIB_USEDEP}] )
204 - bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] )
205 - cdio? ( >=dev-libs/libcdio-paranoia-0.90_p1-r1[${MULTILIB_USEDEP}] )
206 - chromaprint? ( >=media-libs/chromaprint-1.2-r1[${MULTILIB_USEDEP}] )
207 - ebur128? ( >=media-libs/libebur128-1.1.0[${MULTILIB_USEDEP}] )
208 - encode? (
209 - amrenc? ( >=media-libs/vo-amrwbenc-0.1.2-r1[${MULTILIB_USEDEP}] )
210 - kvazaar? ( media-libs/kvazaar[${MULTILIB_USEDEP}] )
211 - mp3? ( >=media-sound/lame-3.99.5-r1[${MULTILIB_USEDEP}] )
212 - nvenc? ( media-video/nvidia_video_sdk )
213 - openh264? ( >=media-libs/openh264-1.4.0-r1[${MULTILIB_USEDEP}] )
214 - snappy? ( >=app-arch/snappy-1.1.2-r1[${MULTILIB_USEDEP}] )
215 - theora? (
216 - >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}]
217 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
218 - )
219 - twolame? ( >=media-sound/twolame-0.3.13-r1[${MULTILIB_USEDEP}] )
220 - wavpack? ( >=media-sound/wavpack-4.60.1-r1[${MULTILIB_USEDEP}] )
221 - webp? ( >=media-libs/libwebp-0.3.0[${MULTILIB_USEDEP}] )
222 - x264? ( >=media-libs/x264-0.0.20130506:=[${MULTILIB_USEDEP}] )
223 - x265? ( >=media-libs/x265-1.6:=[${MULTILIB_USEDEP}] )
224 - xvid? ( >=media-libs/xvid-1.3.2-r1[${MULTILIB_USEDEP}] )
225 - )
226 - fdk? ( >=media-libs/fdk-aac-0.1.3:=[${MULTILIB_USEDEP}] )
227 - flite? ( >=app-accessibility/flite-1.4-r4[${MULTILIB_USEDEP}] )
228 - fontconfig? ( >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] )
229 - frei0r? ( media-plugins/frei0r-plugins )
230 - fribidi? ( >=dev-libs/fribidi-0.19.6[${MULTILIB_USEDEP}] )
231 - gcrypt? ( >=dev-libs/libgcrypt-1.6:0=[${MULTILIB_USEDEP}] )
232 - gme? ( >=media-libs/game-music-emu-0.6.0[${MULTILIB_USEDEP}] )
233 - gmp? ( >=dev-libs/gmp-6:0=[${MULTILIB_USEDEP}] )
234 - gnutls? ( >=net-libs/gnutls-2.12.23-r6:=[${MULTILIB_USEDEP}] )
235 - gsm? ( >=media-sound/gsm-1.0.13-r1[${MULTILIB_USEDEP}] )
236 - iconv? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] )
237 - iec61883? (
238 - >=media-libs/libiec61883-1.2.0-r1[${MULTILIB_USEDEP}]
239 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
240 - >=sys-libs/libavc1394-0.5.4-r1[${MULTILIB_USEDEP}]
241 - )
242 - ieee1394? (
243 - >=media-libs/libdc1394-2.2.1[${MULTILIB_USEDEP}]
244 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
245 - )
246 - jack? ( virtual/jack[${MULTILIB_USEDEP}] )
247 - jpeg2k? ( >=media-libs/openjpeg-2:2[${MULTILIB_USEDEP}] )
248 - libass? ( >=media-libs/libass-0.10.2:=[${MULTILIB_USEDEP}] )
249 - libcaca? ( >=media-libs/libcaca-0.99_beta18-r1[${MULTILIB_USEDEP}] )
250 - libilbc? ( >=media-libs/libilbc-2[${MULTILIB_USEDEP}] )
251 - libsoxr? ( >=media-libs/soxr-0.1.0[${MULTILIB_USEDEP}] )
252 - libv4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] )
253 - lzma? ( >=app-arch/xz-utils-5.0.5-r1[${MULTILIB_USEDEP}] )
254 - mmal? ( media-libs/raspberrypi-userland )
255 - modplug? ( >=media-libs/libmodplug-0.8.8.4-r1[${MULTILIB_USEDEP}] )
256 - openal? ( >=media-libs/openal-1.15.1[${MULTILIB_USEDEP}] )
257 - opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
258 - openssl? ( >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] )
259 - opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
260 - pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
261 - librtmp? ( >=media-video/rtmpdump-2.4_p20131018[${MULTILIB_USEDEP}] )
262 - rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
263 - samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
264 - sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
265 - speex? ( >=media-libs/speex-1.2_rc1-r1[${MULTILIB_USEDEP}] )
266 - ssh? ( >=net-libs/libssh-0.5.5[${MULTILIB_USEDEP}] )
267 - truetype? ( >=media-libs/freetype-2.5.0.1:2[${MULTILIB_USEDEP}] )
268 - vaapi? ( >=x11-libs/libva-1.2.1-r1[${MULTILIB_USEDEP}] )
269 - vdpau? ( >=x11-libs/libvdpau-0.7[${MULTILIB_USEDEP}] )
270 - vorbis? (
271 - >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}]
272 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
273 - )
274 - vpx? ( >=media-libs/libvpx-1.4.0:=[${MULTILIB_USEDEP}] )
275 - X? (
276 - >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}]
277 - >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}]
278 - !xcb? ( >=x11-libs/libXfixes-5.0.1[${MULTILIB_USEDEP}] )
279 - >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}]
280 - )
281 - xcb? ( >=x11-libs/libxcb-1.4[${MULTILIB_USEDEP}] )
282 - zimg? ( media-libs/zimg[${MULTILIB_USEDEP}] )
283 - zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
284 - zvbi? ( >=media-libs/zvbi-0.2.35[${MULTILIB_USEDEP}] )
285 - !media-video/qt-faststart
286 - postproc? ( !media-libs/libpostproc )
287 -"
288 -
289 -DEPEND="${RDEPEND}
290 - >=sys-devel/make-3.81
291 - doc? ( sys-apps/texinfo )
292 - >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
293 - ladspa? ( >=media-libs/ladspa-sdk-1.13-r2[${MULTILIB_USEDEP}] )
294 - cpu_flags_x86_mmx? ( >=dev-lang/yasm-1.2 )
295 - test? ( net-misc/wget sys-devel/bc )
296 - v4l? ( sys-kernel/linux-headers )
297 -"
298 -
299 -# Code requiring FFmpeg to be built under gpl license
300 -GPL_REQUIRED_USE="
301 - postproc? ( gpl )
302 - frei0r? ( gpl )
303 - cdio? ( gpl )
304 - samba? ( gpl )
305 - encode? (
306 - x264? ( gpl )
307 - x265? ( gpl )
308 - xvid? ( gpl )
309 - X? ( !xcb? ( gpl ) )
310 - )
311 -"
312 -REQUIRED_USE="
313 - libv4l? ( v4l )
314 - fftools_cws2fws? ( zlib )
315 - test? ( encode )
316 - ${GPL_REQUIRED_USE}
317 - ${CPU_REQUIRED_USE}"
318 -RESTRICT="
319 - gpl? ( openssl? ( bindist ) fdk? ( bindist ) )
320 -"
321 -
322 -S=${WORKDIR}/${P/_/-}
323 -
324 -MULTILIB_WRAPPED_HEADERS=(
325 - /usr/include/libavutil/avconfig.h
326 -)
327 -
328 -PATCHES=( "${FILESDIR}/ffmpeg32-openjpeg22.patch" )
329 -
330 -src_prepare() {
331 - if [[ "${PV%_p*}" != "${PV}" ]] ; then # Snapshot
332 - export revision=git-N-${FFMPEG_REVISION}
333 - fi
334 - default
335 -
336 - # the version script on Solaris causes invalid symbol version problems
337 - # we don't want their hacky workarounds, we're having a GNU ld
338 - sed -i -e 's/sunos)/sunos) network_extralibs="-lsocket -lnsl"; add_cppflags -D__EXTENSIONS__; enable pic; disable symver ;; no-sunos)/' configure || die
339 -}
340 -
341 -multilib_src_configure() {
342 - local myconf=( ${EXTRA_FFMPEG_CONF} )
343 -
344 - local ffuse=( "${FFMPEG_FLAG_MAP[@]}" )
345 - use openssl && use gpl && myconf+=( --enable-nonfree )
346 - use samba && myconf+=( --enable-version3 )
347 -
348 - # Encoders
349 - if use encode ; then
350 - ffuse+=( "${FFMPEG_ENCODER_FLAG_MAP[@]}" )
351 -
352 - # Licensing.
353 - if use amrenc ; then
354 - myconf+=( --enable-version3 )
355 - fi
356 - else
357 - myconf+=( --disable-encoders )
358 - fi
359 -
360 - # Indevs
361 - use v4l || myconf+=( --disable-indev=v4l2 --disable-outdev=v4l2 )
362 - for i in alsa oss jack ; do
363 - use ${i} || myconf+=( --disable-indev=${i} )
364 - done
365 - use xcb || ffuse+=( X:x11grab )
366 -
367 - # Outdevs
368 - for i in alsa oss sdl ; do
369 - use ${i} || myconf+=( --disable-outdev=${i} )
370 - done
371 -
372 - # Decoders
373 - use amr && myconf+=( --enable-version3 )
374 - use gmp && myconf+=( --enable-version3 )
375 - use fdk && use gpl && myconf+=( --enable-nonfree )
376 -
377 - for i in "${ffuse[@]#+}" ; do
378 - myconf+=( $(use_enable ${i%:*} ${i#*:}) )
379 - done
380 -
381 - # (temporarily) disable non-multilib deps
382 - if ! multilib_is_native_abi; then
383 - for i in frei0r ; do
384 - myconf+=( --disable-${i} )
385 - done
386 - fi
387 -
388 - # CPU features
389 - for i in ${CPU_FEATURES_MAP} ; do
390 - if [ "$(tc-arch)" = "${i%:*}" ] ; then
391 - local var="${i#*:}_CPU_FEATURES[@]"
392 - for j in ${!var} ; do
393 - use ${j%:*} || myconf+=( --disable-${j#*:} )
394 - done
395 - fi
396 - done
397 -
398 - if use pic ; then
399 - myconf+=( --enable-pic )
400 - # disable asm code if PIC is required
401 - # as the provided asm decidedly is not PIC for x86.
402 - [[ ${ABI} == x86 ]] && myconf+=( --disable-asm )
403 - fi
404 - [[ ${ABI} == x32 ]] && myconf+=( --disable-asm ) #427004
405 -
406 - # Try to get cpu type based on CFLAGS.
407 - # Bug #172723
408 - # We need to do this so that features of that CPU will be better used
409 - # If they contain an unknown CPU it will not hurt since ffmpeg's configure
410 - # will just ignore it.
411 - for i in $(get-flag mcpu) $(get-flag march) ; do
412 - [[ ${i} = native ]] && i="host" # bug #273421
413 - myconf+=( --cpu=${i} )
414 - break
415 - done
416 -
417 - # LTO support, bug #566282
418 - is-flagq "-flto*" && myconf+=( "--enable-lto" )
419 -
420 - # Mandatory configuration
421 - myconf=(
422 - --enable-avfilter
423 - --enable-avresample
424 - --disable-stripping
425 - --disable-libcelt # bug #664158
426 - "${myconf[@]}"
427 - )
428 -
429 - # cross compile support
430 - if tc-is-cross-compiler ; then
431 - myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}- )
432 - case ${CHOST} in
433 - *freebsd*)
434 - myconf+=( --target-os=freebsd )
435 - ;;
436 - *mingw32*)
437 - myconf+=( --target-os=mingw32 )
438 - ;;
439 - *linux*)
440 - myconf+=( --target-os=linux )
441 - ;;
442 - esac
443 - fi
444 -
445 - # doc
446 - myconf+=(
447 - $(multilib_native_use_enable doc)
448 - $(multilib_native_use_enable doc htmlpages)
449 - $(multilib_native_enable manpages)
450 - )
451 -
452 - set -- "${S}/configure" \
453 - --prefix="${EPREFIX}/usr" \
454 - --libdir="${EPREFIX}/usr/$(get_libdir)" \
455 - --shlibdir="${EPREFIX}/usr/$(get_libdir)" \
456 - --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
457 - --mandir="${EPREFIX}/usr/share/man" \
458 - --enable-shared \
459 - --cc="$(tc-getCC)" \
460 - --cxx="$(tc-getCXX)" \
461 - --ar="$(tc-getAR)" \
462 - --optflags="${CFLAGS}" \
463 - $(use_enable static-libs static) \
464 - "${myconf[@]}"
465 - echo "${@}"
466 - "${@}" || die
467 -}
468 -
469 -multilib_src_compile() {
470 - emake V=1
471 -
472 - if multilib_is_native_abi; then
473 - for i in "${FFTOOLS[@]}" ; do
474 - if use fftools_${i} ; then
475 - emake V=1 tools/${i}$(get_exeext)
476 - fi
477 - done
478 - fi
479 -}
480 -
481 -multilib_src_install() {
482 - emake V=1 DESTDIR="${D}" install install-doc
483 -
484 - if multilib_is_native_abi; then
485 - for i in "${FFTOOLS[@]}" ; do
486 - if use fftools_${i} ; then
487 - dobin tools/${i}$(get_exeext)
488 - fi
489 - done
490 - fi
491 -}
492 -
493 -multilib_src_install_all() {
494 - dodoc Changelog README.md CREDITS doc/*.txt doc/APIchanges
495 - [ -f "RELEASE_NOTES" ] && dodoc "RELEASE_NOTES"
496 -}
497 -
498 -multilib_src_test() {
499 - LD_LIBRARY_PATH="${BUILD_DIR}/libpostproc:${BUILD_DIR}/libswscale:${BUILD_DIR}/libswresample:${BUILD_DIR}/libavcodec:${BUILD_DIR}/libavdevice:${BUILD_DIR}/libavfilter:${BUILD_DIR}/libavformat:${BUILD_DIR}/libavutil:${BUILD_DIR}/libavresample" \
500 - emake V=1 fate
501 -}
502
503 diff --git a/media-video/ffmpeg/ffmpeg-3.2.7.ebuild b/media-video/ffmpeg/ffmpeg-3.2.7.ebuild
504 deleted file mode 100644
505 index ac8492a79df..00000000000
506 --- a/media-video/ffmpeg/ffmpeg-3.2.7.ebuild
507 +++ /dev/null
508 @@ -1,457 +0,0 @@
509 -# Copyright 1999-2018 Gentoo Authors
510 -# Distributed under the terms of the GNU General Public License v2
511 -
512 -EAPI=6
513 -
514 -# Subslot: libavutil major.libavcodec major.libavformat major
515 -# Since FFmpeg ships several libraries, subslot is kind of limited here.
516 -# Most consumers will use those three libraries, if a "less used" library
517 -# changes its soname, consumers will have to be rebuilt the old way
518 -# (preserve-libs).
519 -# If, for example, a package does not link to libavformat and only libavformat
520 -# changes its ABI then this package will be rebuilt needlessly. Hence, such a
521 -# package is free _not_ to := depend on FFmpeg but I would strongly encourage
522 -# doing so since such a case is unlikely.
523 -FFMPEG_SUBSLOT=55.57.57
524 -
525 -SCM=""
526 -if [ "${PV#9999}" != "${PV}" ] ; then
527 - SCM="git-r3"
528 - EGIT_REPO_URI="git://source.ffmpeg.org/ffmpeg.git"
529 -fi
530 -
531 -inherit eutils flag-o-matic multilib multilib-minimal toolchain-funcs ${SCM}
532 -
533 -DESCRIPTION="Complete solution to record, convert and stream audio and video. Includes libavcodec"
534 -HOMEPAGE="http://ffmpeg.org/"
535 -if [ "${PV#9999}" != "${PV}" ] ; then
536 - SRC_URI=""
537 -elif [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot
538 - SRC_URI="mirror://gentoo/${P}.tar.bz2"
539 -else # Release
540 - SRC_URI="http://ffmpeg.org/releases/${P/_/-}.tar.bz2"
541 -fi
542 -FFMPEG_REVISION="${PV#*_p}"
543 -
544 -SLOT="0/${FFMPEG_SUBSLOT}"
545 -LICENSE="
546 - !gpl? ( LGPL-2.1 )
547 - gpl? ( GPL-2 )
548 - amr? (
549 - gpl? ( GPL-3 )
550 - !gpl? ( LGPL-3 )
551 - )
552 - gmp? (
553 - gpl? ( GPL-3 )
554 - !gpl? ( LGPL-3 )
555 - )
556 - encode? (
557 - amrenc? (
558 - gpl? ( GPL-3 )
559 - !gpl? ( LGPL-3 )
560 - )
561 - )
562 - samba? ( GPL-3 )
563 -"
564 -if [ "${PV#9999}" = "${PV}" ] ; then
565 - KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
566 -fi
567 -
568 -# Options to use as use_enable in the foo[:bar] form.
569 -# This will feed configure with $(use_enable foo bar)
570 -# or $(use_enable foo foo) if no :bar is set.
571 -# foo is added to IUSE.
572 -FFMPEG_FLAG_MAP=(
573 - +bzip2:bzlib cpudetection:runtime-cpudetect debug gcrypt gnutls gmp
574 - +gpl +hardcoded-tables +iconv lzma +network openssl +postproc
575 - samba:libsmbclient sdl:ffplay sdl:sdl2 vaapi vdpau X:xlib xcb:libxcb
576 - xcb:libxcb-shm xcb:libxcb-xfixes +zlib
577 - # libavdevice options
578 - cdio:libcdio iec61883:libiec61883 ieee1394:libdc1394 libcaca openal
579 - opengl
580 - # indevs
581 - libv4l:libv4l2 pulseaudio:libpulse
582 - # decoders
583 - amr:libopencore-amrwb amr:libopencore-amrnb fdk:libfdk-aac
584 - jpeg2k:libopenjpeg bluray:libbluray gme:libgme gsm:libgsm
585 - mmal modplug:libmodplug opus:libopus libilbc librtmp ssh:libssh
586 - speex:libspeex vorbis:libvorbis vpx:libvpx
587 - zvbi:libzvbi
588 - # libavfilter options
589 - bs2b:libbs2b chromaprint ebur128:libebur128 flite:libflite frei0r
590 - fribidi:libfribidi fontconfig ladspa libass truetype:libfreetype
591 - rubberband:librubberband zimg:libzimg
592 - # libswresample options
593 - libsoxr
594 - # Threads; we only support pthread for now but ffmpeg supports more
595 - +threads:pthreads
596 -)
597 -
598 -# Same as above but for encoders, i.e. they do something only with USE=encode.
599 -FFMPEG_ENCODER_FLAG_MAP=(
600 - amrenc:libvo-amrwbenc mp3:libmp3lame
601 - kvazaar:libkvazaar nvenc:nvenc
602 - openh264:libopenh264 snappy:libsnappy theora:libtheora twolame:libtwolame
603 - wavpack:libwavpack webp:libwebp x264:libx264 x265:libx265 xvid:libxvid
604 -)
605 -
606 -IUSE="
607 - alsa doc +encode jack oss pic static-libs test v4l
608 - ${FFMPEG_FLAG_MAP[@]%:*}
609 - ${FFMPEG_ENCODER_FLAG_MAP[@]%:*}
610 -"
611 -
612 -# Strings for CPU features in the useflag[:configure_option] form
613 -# if :configure_option isn't set, it will use 'useflag' as configure option
614 -ARM_CPU_FEATURES=( armv5te armv6 armv6t2 neon armvfp:vfp )
615 -MIPS_CPU_FEATURES=( mipsdspr1 mipsdspr2 mipsfpu )
616 -PPC_CPU_FEATURES=( altivec )
617 -X86_CPU_FEATURES_RAW=( 3dnow:amd3dnow 3dnowext:amd3dnowext aes:aesni avx:avx avx2:avx2 fma3:fma3 fma4:fma4 mmx:mmx mmxext:mmxext sse:sse sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4 sse4_2:sse42 xop:xop )
618 -X86_CPU_FEATURES=( ${X86_CPU_FEATURES_RAW[@]/#/cpu_flags_x86_} )
619 -X86_CPU_REQUIRED_USE="
620 - cpu_flags_x86_avx2? ( cpu_flags_x86_avx )
621 - cpu_flags_x86_fma4? ( cpu_flags_x86_avx )
622 - cpu_flags_x86_fma3? ( cpu_flags_x86_avx )
623 - cpu_flags_x86_xop? ( cpu_flags_x86_avx )
624 - cpu_flags_x86_avx? ( cpu_flags_x86_sse4_2 )
625 - cpu_flags_x86_aes? ( cpu_flags_x86_sse4_2 )
626 - cpu_flags_x86_sse4_2? ( cpu_flags_x86_sse4_1 )
627 - cpu_flags_x86_sse4_1? ( cpu_flags_x86_ssse3 )
628 - cpu_flags_x86_ssse3? ( cpu_flags_x86_sse3 )
629 - cpu_flags_x86_sse3? ( cpu_flags_x86_sse2 )
630 - cpu_flags_x86_sse2? ( cpu_flags_x86_sse )
631 - cpu_flags_x86_sse? ( cpu_flags_x86_mmxext )
632 - cpu_flags_x86_mmxext? ( cpu_flags_x86_mmx )
633 - cpu_flags_x86_3dnowext? ( cpu_flags_x86_3dnow )
634 - cpu_flags_x86_3dnow? ( cpu_flags_x86_mmx )
635 -"
636 -
637 -IUSE="${IUSE}
638 - ${ARM_CPU_FEATURES[@]%:*}
639 - ${MIPS_CPU_FEATURES[@]%:*}
640 - ${PPC_CPU_FEATURES[@]%:*}
641 - ${X86_CPU_FEATURES[@]%:*}
642 -"
643 -
644 -CPU_REQUIRED_USE="
645 - ${X86_CPU_REQUIRED_USE}
646 -"
647 -
648 -# "$(tc-arch):XXX" form where XXX_CPU_FEATURES are the cpu features that apply to
649 -# $(tc-arch).
650 -CPU_FEATURES_MAP="
651 - arm:ARM
652 - arm64:ARM
653 - mips:MIPS
654 - ppc:PPC
655 - ppc64:PPC
656 - x86:X86
657 - amd64:X86
658 -"
659 -
660 -FFTOOLS=( aviocat cws2fws ffescape ffeval ffhash fourcc2pixfmt graph2dot ismindex pktdumper qt-faststart sidxindex trasher )
661 -IUSE="${IUSE} ${FFTOOLS[@]/#/+fftools_}"
662 -
663 -RDEPEND="
664 - alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] )
665 - amr? ( >=media-libs/opencore-amr-0.1.3-r1[${MULTILIB_USEDEP}] )
666 - bluray? ( >=media-libs/libbluray-0.3.0-r1:=[${MULTILIB_USEDEP}] )
667 - bs2b? ( >=media-libs/libbs2b-3.1.0-r1[${MULTILIB_USEDEP}] )
668 - bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] )
669 - cdio? ( >=dev-libs/libcdio-paranoia-0.90_p1-r1[${MULTILIB_USEDEP}] )
670 - chromaprint? ( >=media-libs/chromaprint-1.2-r1[${MULTILIB_USEDEP}] )
671 - ebur128? ( >=media-libs/libebur128-1.1.0[${MULTILIB_USEDEP}] )
672 - encode? (
673 - amrenc? ( >=media-libs/vo-amrwbenc-0.1.2-r1[${MULTILIB_USEDEP}] )
674 - kvazaar? ( media-libs/kvazaar[${MULTILIB_USEDEP}] )
675 - mp3? ( >=media-sound/lame-3.99.5-r1[${MULTILIB_USEDEP}] )
676 - nvenc? ( media-video/nvidia_video_sdk )
677 - openh264? ( >=media-libs/openh264-1.4.0-r1[${MULTILIB_USEDEP}] )
678 - snappy? ( >=app-arch/snappy-1.1.2-r1[${MULTILIB_USEDEP}] )
679 - theora? (
680 - >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}]
681 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
682 - )
683 - twolame? ( >=media-sound/twolame-0.3.13-r1[${MULTILIB_USEDEP}] )
684 - wavpack? ( >=media-sound/wavpack-4.60.1-r1[${MULTILIB_USEDEP}] )
685 - webp? ( >=media-libs/libwebp-0.3.0[${MULTILIB_USEDEP}] )
686 - x264? ( >=media-libs/x264-0.0.20130506:=[${MULTILIB_USEDEP}] )
687 - x265? ( >=media-libs/x265-1.6:=[${MULTILIB_USEDEP}] )
688 - xvid? ( >=media-libs/xvid-1.3.2-r1[${MULTILIB_USEDEP}] )
689 - )
690 - fdk? ( >=media-libs/fdk-aac-0.1.3:=[${MULTILIB_USEDEP}] )
691 - flite? ( >=app-accessibility/flite-1.4-r4[${MULTILIB_USEDEP}] )
692 - fontconfig? ( >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] )
693 - frei0r? ( media-plugins/frei0r-plugins )
694 - fribidi? ( >=dev-libs/fribidi-0.19.6[${MULTILIB_USEDEP}] )
695 - gcrypt? ( >=dev-libs/libgcrypt-1.6:0=[${MULTILIB_USEDEP}] )
696 - gme? ( >=media-libs/game-music-emu-0.6.0[${MULTILIB_USEDEP}] )
697 - gmp? ( >=dev-libs/gmp-6:0=[${MULTILIB_USEDEP}] )
698 - gnutls? ( >=net-libs/gnutls-2.12.23-r6:=[${MULTILIB_USEDEP}] )
699 - gsm? ( >=media-sound/gsm-1.0.13-r1[${MULTILIB_USEDEP}] )
700 - iconv? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] )
701 - iec61883? (
702 - >=media-libs/libiec61883-1.2.0-r1[${MULTILIB_USEDEP}]
703 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
704 - >=sys-libs/libavc1394-0.5.4-r1[${MULTILIB_USEDEP}]
705 - )
706 - ieee1394? (
707 - >=media-libs/libdc1394-2.2.1[${MULTILIB_USEDEP}]
708 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
709 - )
710 - jack? ( virtual/jack[${MULTILIB_USEDEP}] )
711 - jpeg2k? ( >=media-libs/openjpeg-2:2[${MULTILIB_USEDEP}] )
712 - libass? ( >=media-libs/libass-0.10.2:=[${MULTILIB_USEDEP}] )
713 - libcaca? ( >=media-libs/libcaca-0.99_beta18-r1[${MULTILIB_USEDEP}] )
714 - libilbc? ( >=media-libs/libilbc-2[${MULTILIB_USEDEP}] )
715 - libsoxr? ( >=media-libs/soxr-0.1.0[${MULTILIB_USEDEP}] )
716 - libv4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] )
717 - lzma? ( >=app-arch/xz-utils-5.0.5-r1[${MULTILIB_USEDEP}] )
718 - mmal? ( media-libs/raspberrypi-userland )
719 - modplug? ( >=media-libs/libmodplug-0.8.8.4-r1[${MULTILIB_USEDEP}] )
720 - openal? ( >=media-libs/openal-1.15.1[${MULTILIB_USEDEP}] )
721 - opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
722 - openssl? ( >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] )
723 - opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
724 - pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
725 - librtmp? ( >=media-video/rtmpdump-2.4_p20131018[${MULTILIB_USEDEP}] )
726 - rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
727 - samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
728 - sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
729 - speex? ( >=media-libs/speex-1.2_rc1-r1[${MULTILIB_USEDEP}] )
730 - ssh? ( >=net-libs/libssh-0.5.5[${MULTILIB_USEDEP}] )
731 - truetype? ( >=media-libs/freetype-2.5.0.1:2[${MULTILIB_USEDEP}] )
732 - vaapi? ( >=x11-libs/libva-1.2.1-r1[${MULTILIB_USEDEP}] )
733 - vdpau? ( >=x11-libs/libvdpau-0.7[${MULTILIB_USEDEP}] )
734 - vorbis? (
735 - >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}]
736 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
737 - )
738 - vpx? ( >=media-libs/libvpx-1.4.0:=[${MULTILIB_USEDEP}] )
739 - X? (
740 - >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}]
741 - >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}]
742 - !xcb? ( >=x11-libs/libXfixes-5.0.1[${MULTILIB_USEDEP}] )
743 - >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}]
744 - )
745 - xcb? ( >=x11-libs/libxcb-1.4[${MULTILIB_USEDEP}] )
746 - zimg? ( media-libs/zimg[${MULTILIB_USEDEP}] )
747 - zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
748 - zvbi? ( >=media-libs/zvbi-0.2.35[${MULTILIB_USEDEP}] )
749 - !media-video/qt-faststart
750 - postproc? ( !media-libs/libpostproc )
751 -"
752 -
753 -DEPEND="${RDEPEND}
754 - >=sys-devel/make-3.81
755 - doc? ( sys-apps/texinfo )
756 - >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
757 - ladspa? ( >=media-libs/ladspa-sdk-1.13-r2[${MULTILIB_USEDEP}] )
758 - cpu_flags_x86_mmx? ( >=dev-lang/yasm-1.2 )
759 - test? ( net-misc/wget sys-devel/bc )
760 - v4l? ( sys-kernel/linux-headers )
761 -"
762 -
763 -# Code requiring FFmpeg to be built under gpl license
764 -GPL_REQUIRED_USE="
765 - postproc? ( gpl )
766 - frei0r? ( gpl )
767 - cdio? ( gpl )
768 - samba? ( gpl )
769 - encode? (
770 - x264? ( gpl )
771 - x265? ( gpl )
772 - xvid? ( gpl )
773 - X? ( !xcb? ( gpl ) )
774 - )
775 -"
776 -REQUIRED_USE="
777 - libv4l? ( v4l )
778 - fftools_cws2fws? ( zlib )
779 - test? ( encode )
780 - ${GPL_REQUIRED_USE}
781 - ${CPU_REQUIRED_USE}"
782 -RESTRICT="
783 - gpl? ( openssl? ( bindist ) fdk? ( bindist ) )
784 -"
785 -
786 -S=${WORKDIR}/${P/_/-}
787 -
788 -MULTILIB_WRAPPED_HEADERS=(
789 - /usr/include/libavutil/avconfig.h
790 -)
791 -
792 -PATCHES=( "${FILESDIR}/ffmpeg32-openjpeg22.patch" )
793 -
794 -src_prepare() {
795 - if [[ "${PV%_p*}" != "${PV}" ]] ; then # Snapshot
796 - export revision=git-N-${FFMPEG_REVISION}
797 - fi
798 - default
799 -
800 - # the version script on Solaris causes invalid symbol version problems
801 - # we don't want their hacky workarounds, we're having a GNU ld
802 - sed -i -e 's/sunos)/sunos) network_extralibs="-lsocket -lnsl"; add_cppflags -D__EXTENSIONS__; enable pic; disable symver ;; no-sunos)/' configure || die
803 -}
804 -
805 -multilib_src_configure() {
806 - local myconf=( ${EXTRA_FFMPEG_CONF} )
807 -
808 - local ffuse=( "${FFMPEG_FLAG_MAP[@]}" )
809 - use openssl && use gpl && myconf+=( --enable-nonfree )
810 - use samba && myconf+=( --enable-version3 )
811 -
812 - # Encoders
813 - if use encode ; then
814 - ffuse+=( "${FFMPEG_ENCODER_FLAG_MAP[@]}" )
815 -
816 - # Licensing.
817 - if use amrenc ; then
818 - myconf+=( --enable-version3 )
819 - fi
820 - else
821 - myconf+=( --disable-encoders )
822 - fi
823 -
824 - # Indevs
825 - use v4l || myconf+=( --disable-indev=v4l2 --disable-outdev=v4l2 )
826 - for i in alsa oss jack ; do
827 - use ${i} || myconf+=( --disable-indev=${i} )
828 - done
829 - use xcb || ffuse+=( X:x11grab )
830 -
831 - # Outdevs
832 - for i in alsa oss sdl ; do
833 - use ${i} || myconf+=( --disable-outdev=${i} )
834 - done
835 -
836 - # Decoders
837 - use amr && myconf+=( --enable-version3 )
838 - use gmp && myconf+=( --enable-version3 )
839 - use fdk && use gpl && myconf+=( --enable-nonfree )
840 -
841 - for i in "${ffuse[@]#+}" ; do
842 - myconf+=( $(use_enable ${i%:*} ${i#*:}) )
843 - done
844 -
845 - # (temporarily) disable non-multilib deps
846 - if ! multilib_is_native_abi; then
847 - for i in frei0r ; do
848 - myconf+=( --disable-${i} )
849 - done
850 - fi
851 -
852 - # CPU features
853 - for i in ${CPU_FEATURES_MAP} ; do
854 - if [ "$(tc-arch)" = "${i%:*}" ] ; then
855 - local var="${i#*:}_CPU_FEATURES[@]"
856 - for j in ${!var} ; do
857 - use ${j%:*} || myconf+=( --disable-${j#*:} )
858 - done
859 - fi
860 - done
861 -
862 - if use pic ; then
863 - myconf+=( --enable-pic )
864 - # disable asm code if PIC is required
865 - # as the provided asm decidedly is not PIC for x86.
866 - [[ ${ABI} == x86 ]] && myconf+=( --disable-asm )
867 - fi
868 - [[ ${ABI} == x32 ]] && myconf+=( --disable-asm ) #427004
869 -
870 - # Try to get cpu type based on CFLAGS.
871 - # Bug #172723
872 - # We need to do this so that features of that CPU will be better used
873 - # If they contain an unknown CPU it will not hurt since ffmpeg's configure
874 - # will just ignore it.
875 - for i in $(get-flag mcpu) $(get-flag march) ; do
876 - [[ ${i} = native ]] && i="host" # bug #273421
877 - myconf+=( --cpu=${i} )
878 - break
879 - done
880 -
881 - # LTO support, bug #566282
882 - is-flagq "-flto*" && myconf+=( "--enable-lto" )
883 -
884 - # Mandatory configuration
885 - myconf=(
886 - --enable-avfilter
887 - --enable-avresample
888 - --disable-stripping
889 - --disable-libcelt # bug #664158
890 - "${myconf[@]}"
891 - )
892 -
893 - # cross compile support
894 - if tc-is-cross-compiler ; then
895 - myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}- )
896 - case ${CHOST} in
897 - *freebsd*)
898 - myconf+=( --target-os=freebsd )
899 - ;;
900 - *mingw32*)
901 - myconf+=( --target-os=mingw32 )
902 - ;;
903 - *linux*)
904 - myconf+=( --target-os=linux )
905 - ;;
906 - esac
907 - fi
908 -
909 - # doc
910 - myconf+=(
911 - $(multilib_native_use_enable doc)
912 - $(multilib_native_use_enable doc htmlpages)
913 - $(multilib_native_enable manpages)
914 - )
915 -
916 - set -- "${S}/configure" \
917 - --prefix="${EPREFIX}/usr" \
918 - --libdir="${EPREFIX}/usr/$(get_libdir)" \
919 - --shlibdir="${EPREFIX}/usr/$(get_libdir)" \
920 - --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
921 - --mandir="${EPREFIX}/usr/share/man" \
922 - --enable-shared \
923 - --cc="$(tc-getCC)" \
924 - --cxx="$(tc-getCXX)" \
925 - --ar="$(tc-getAR)" \
926 - --optflags="${CFLAGS}" \
927 - $(use_enable static-libs static) \
928 - "${myconf[@]}"
929 - echo "${@}"
930 - "${@}" || die
931 -}
932 -
933 -multilib_src_compile() {
934 - emake V=1
935 -
936 - if multilib_is_native_abi; then
937 - for i in "${FFTOOLS[@]}" ; do
938 - if use fftools_${i} ; then
939 - emake V=1 tools/${i}$(get_exeext)
940 - fi
941 - done
942 - fi
943 -}
944 -
945 -multilib_src_install() {
946 - emake V=1 DESTDIR="${D}" install install-doc
947 -
948 - if multilib_is_native_abi; then
949 - for i in "${FFTOOLS[@]}" ; do
950 - if use fftools_${i} ; then
951 - dobin tools/${i}$(get_exeext)
952 - fi
953 - done
954 - fi
955 -}
956 -
957 -multilib_src_install_all() {
958 - dodoc Changelog README.md CREDITS doc/*.txt doc/APIchanges
959 - [ -f "RELEASE_NOTES" ] && dodoc "RELEASE_NOTES"
960 -}
961 -
962 -multilib_src_test() {
963 - LD_LIBRARY_PATH="${BUILD_DIR}/libpostproc:${BUILD_DIR}/libswscale:${BUILD_DIR}/libswresample:${BUILD_DIR}/libavcodec:${BUILD_DIR}/libavdevice:${BUILD_DIR}/libavfilter:${BUILD_DIR}/libavformat:${BUILD_DIR}/libavutil:${BUILD_DIR}/libavresample" \
964 - emake V=1 fate
965 -}
966
967 diff --git a/media-video/ffmpeg/ffmpeg-3.3.4.ebuild b/media-video/ffmpeg/ffmpeg-3.3.4.ebuild
968 deleted file mode 100644
969 index d55a0875bac..00000000000
970 --- a/media-video/ffmpeg/ffmpeg-3.3.4.ebuild
971 +++ /dev/null
972 @@ -1,505 +0,0 @@
973 -# Copyright 1999-2018 Gentoo Authors
974 -# Distributed under the terms of the GNU General Public License v2
975 -
976 -EAPI=6
977 -
978 -# Subslot: libavutil major.libavcodec major.libavformat major
979 -# Since FFmpeg ships several libraries, subslot is kind of limited here.
980 -# Most consumers will use those three libraries, if a "less used" library
981 -# changes its soname, consumers will have to be rebuilt the old way
982 -# (preserve-libs).
983 -# If, for example, a package does not link to libavformat and only libavformat
984 -# changes its ABI then this package will be rebuilt needlessly. Hence, such a
985 -# package is free _not_ to := depend on FFmpeg but I would strongly encourage
986 -# doing so since such a case is unlikely.
987 -FFMPEG_SUBSLOT=55.57.57
988 -
989 -SCM=""
990 -if [ "${PV#9999}" != "${PV}" ] ; then
991 - SCM="git-r3"
992 - EGIT_REPO_URI="git://source.ffmpeg.org/ffmpeg.git"
993 -fi
994 -
995 -inherit eutils flag-o-matic multilib multilib-minimal toolchain-funcs ${SCM}
996 -
997 -DESCRIPTION="Complete solution to record, convert and stream audio and video. Includes libavcodec"
998 -HOMEPAGE="http://ffmpeg.org/"
999 -if [ "${PV#9999}" != "${PV}" ] ; then
1000 - SRC_URI=""
1001 -elif [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot
1002 - SRC_URI="mirror://gentoo/${P}.tar.bz2"
1003 -else # Release
1004 - SRC_URI="http://ffmpeg.org/releases/${P/_/-}.tar.bz2"
1005 -fi
1006 -FFMPEG_REVISION="${PV#*_p}"
1007 -
1008 -SLOT="0/${FFMPEG_SUBSLOT}"
1009 -LICENSE="
1010 - !gpl? ( LGPL-2.1 )
1011 - gpl? ( GPL-2 )
1012 - amr? (
1013 - gpl? ( GPL-3 )
1014 - !gpl? ( LGPL-3 )
1015 - )
1016 - gmp? (
1017 - gpl? ( GPL-3 )
1018 - !gpl? ( LGPL-3 )
1019 - )
1020 - encode? (
1021 - amrenc? (
1022 - gpl? ( GPL-3 )
1023 - !gpl? ( LGPL-3 )
1024 - )
1025 - )
1026 - samba? ( GPL-3 )
1027 -"
1028 -if [ "${PV#9999}" = "${PV}" ] ; then
1029 - KEYWORDS="amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
1030 -fi
1031 -
1032 -# Options to use as use_enable in the foo[:bar] form.
1033 -# This will feed configure with $(use_enable foo bar)
1034 -# or $(use_enable foo foo) if no :bar is set.
1035 -# foo is added to IUSE.
1036 -FFMPEG_FLAG_MAP=(
1037 - +bzip2:bzlib cpudetection:runtime-cpudetect debug gcrypt gnutls gmp
1038 - +gpl +hardcoded-tables +iconv lzma +network openssl +postproc
1039 - samba:libsmbclient sdl:ffplay sdl:sdl2 vaapi vdpau X:xlib xcb:libxcb
1040 - xcb:libxcb-shm xcb:libxcb-xfixes +zlib
1041 - # libavdevice options
1042 - cdio:libcdio iec61883:libiec61883 ieee1394:libdc1394 libcaca openal
1043 - opengl
1044 - # indevs
1045 - libv4l:libv4l2 pulseaudio:libpulse
1046 - # decoders
1047 - amr:libopencore-amrwb amr:libopencore-amrnb fdk:libfdk-aac
1048 - jpeg2k:libopenjpeg bluray:libbluray gme:libgme gsm:libgsm
1049 - mmal modplug:libmodplug opus:libopus libilbc librtmp ssh:libssh
1050 - speex:libspeex vorbis:libvorbis vpx:libvpx
1051 - zvbi:libzvbi
1052 - # libavfilter options
1053 - bs2b:libbs2b chromaprint flite:libflite frei0r
1054 - fribidi:libfribidi fontconfig ladspa libass truetype:libfreetype
1055 - rubberband:librubberband sofalizer:netcdf zeromq:libzmq zimg:libzimg
1056 - # libswresample options
1057 - libsoxr
1058 - # Threads; we only support pthread for now but ffmpeg supports more
1059 - +threads:pthreads
1060 -)
1061 -
1062 -# Same as above but for encoders, i.e. they do something only with USE=encode.
1063 -FFMPEG_ENCODER_FLAG_MAP=(
1064 - amrenc:libvo-amrwbenc mp3:libmp3lame
1065 - kvazaar:libkvazaar nvenc:nvenc
1066 - openh264:libopenh264 snappy:libsnappy theora:libtheora twolame:libtwolame
1067 - wavpack:libwavpack webp:libwebp x264:libx264 x265:libx265 xvid:libxvid
1068 -)
1069 -
1070 -IUSE="
1071 - alsa chromium doc +encode jack oss pic static-libs test v4l
1072 - ${FFMPEG_FLAG_MAP[@]%:*}
1073 - ${FFMPEG_ENCODER_FLAG_MAP[@]%:*}
1074 -"
1075 -
1076 -# Strings for CPU features in the useflag[:configure_option] form
1077 -# if :configure_option isn't set, it will use 'useflag' as configure option
1078 -ARM_CPU_FEATURES=(
1079 - cpu_flags_arm_thumb:armv5te
1080 - cpu_flags_arm_v6:armv6
1081 - cpu_flags_arm_thumb2:armv6t2
1082 - cpu_flags_arm_neon:neon
1083 - cpu_flags_arm_vfp:vfp
1084 - cpu_flags_arm_vfpv3:vfpv3
1085 - cpu_flags_arm_v8:armv8
1086 -)
1087 -ARM_CPU_REQUIRED_USE="
1088 - arm64? ( cpu_flags_arm_v8 )
1089 - cpu_flags_arm_v8? ( cpu_flags_arm_vfpv3 cpu_flags_arm_neon )
1090 - cpu_flags_arm_neon? ( cpu_flags_arm_thumb2 cpu_flags_arm_vfp )
1091 - cpu_flags_arm_vfpv3? ( cpu_flags_arm_vfp )
1092 - cpu_flags_arm_thumb2? ( cpu_flags_arm_v6 )
1093 - cpu_flags_arm_v6? ( cpu_flags_arm_thumb )
1094 -"
1095 -MIPS_CPU_FEATURES=( mipsdspr1:mipsdsp mipsdspr2 mipsfpu )
1096 -PPC_CPU_FEATURES=( altivec )
1097 -X86_CPU_FEATURES_RAW=( 3dnow:amd3dnow 3dnowext:amd3dnowext aes:aesni avx:avx avx2:avx2 fma3:fma3 fma4:fma4 mmx:mmx mmxext:mmxext sse:sse sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4 sse4_2:sse42 xop:xop )
1098 -X86_CPU_FEATURES=( ${X86_CPU_FEATURES_RAW[@]/#/cpu_flags_x86_} )
1099 -X86_CPU_REQUIRED_USE="
1100 - cpu_flags_x86_avx2? ( cpu_flags_x86_avx )
1101 - cpu_flags_x86_fma4? ( cpu_flags_x86_avx )
1102 - cpu_flags_x86_fma3? ( cpu_flags_x86_avx )
1103 - cpu_flags_x86_xop? ( cpu_flags_x86_avx )
1104 - cpu_flags_x86_avx? ( cpu_flags_x86_sse4_2 )
1105 - cpu_flags_x86_aes? ( cpu_flags_x86_sse4_2 )
1106 - cpu_flags_x86_sse4_2? ( cpu_flags_x86_sse4_1 )
1107 - cpu_flags_x86_sse4_1? ( cpu_flags_x86_ssse3 )
1108 - cpu_flags_x86_ssse3? ( cpu_flags_x86_sse3 )
1109 - cpu_flags_x86_sse3? ( cpu_flags_x86_sse2 )
1110 - cpu_flags_x86_sse2? ( cpu_flags_x86_sse )
1111 - cpu_flags_x86_sse? ( cpu_flags_x86_mmxext )
1112 - cpu_flags_x86_mmxext? ( cpu_flags_x86_mmx )
1113 - cpu_flags_x86_3dnowext? ( cpu_flags_x86_3dnow )
1114 - cpu_flags_x86_3dnow? ( cpu_flags_x86_mmx )
1115 -"
1116 -
1117 -IUSE="${IUSE}
1118 - ${ARM_CPU_FEATURES[@]%:*}
1119 - ${MIPS_CPU_FEATURES[@]%:*}
1120 - ${PPC_CPU_FEATURES[@]%:*}
1121 - ${X86_CPU_FEATURES[@]%:*}
1122 -"
1123 -
1124 -CPU_REQUIRED_USE="
1125 - ${ARM_CPU_REQUIRED_USE}
1126 - ${X86_CPU_REQUIRED_USE}
1127 -"
1128 -
1129 -# "$(tc-arch):XXX" form where XXX_CPU_FEATURES are the cpu features that apply to
1130 -# $(tc-arch).
1131 -CPU_FEATURES_MAP="
1132 - arm:ARM
1133 - arm64:ARM
1134 - mips:MIPS
1135 - ppc:PPC
1136 - ppc64:PPC
1137 - x86:X86
1138 - amd64:X86
1139 -"
1140 -
1141 -FFTOOLS=( aviocat cws2fws ffescape ffeval ffhash fourcc2pixfmt graph2dot ismindex pktdumper qt-faststart sidxindex trasher )
1142 -IUSE="${IUSE} ${FFTOOLS[@]/#/+fftools_}"
1143 -
1144 -RDEPEND="
1145 - alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] )
1146 - amr? ( >=media-libs/opencore-amr-0.1.3-r1[${MULTILIB_USEDEP}] )
1147 - bluray? ( >=media-libs/libbluray-0.3.0-r1:=[${MULTILIB_USEDEP}] )
1148 - bs2b? ( >=media-libs/libbs2b-3.1.0-r1[${MULTILIB_USEDEP}] )
1149 - bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] )
1150 - cdio? ( >=dev-libs/libcdio-paranoia-0.90_p1-r1[${MULTILIB_USEDEP}] )
1151 - chromaprint? ( >=media-libs/chromaprint-1.2-r1[${MULTILIB_USEDEP}] )
1152 - encode? (
1153 - amrenc? ( >=media-libs/vo-amrwbenc-0.1.2-r1[${MULTILIB_USEDEP}] )
1154 - kvazaar? ( media-libs/kvazaar[${MULTILIB_USEDEP}] )
1155 - mp3? ( >=media-sound/lame-3.99.5-r1[${MULTILIB_USEDEP}] )
1156 - nvenc? ( media-video/nvidia_video_sdk )
1157 - openh264? ( >=media-libs/openh264-1.4.0-r1[${MULTILIB_USEDEP}] )
1158 - snappy? ( >=app-arch/snappy-1.1.2-r1:=[${MULTILIB_USEDEP}] )
1159 - theora? (
1160 - >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}]
1161 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
1162 - )
1163 - twolame? ( >=media-sound/twolame-0.3.13-r1[${MULTILIB_USEDEP}] )
1164 - wavpack? ( >=media-sound/wavpack-4.60.1-r1[${MULTILIB_USEDEP}] )
1165 - webp? ( >=media-libs/libwebp-0.3.0:=[${MULTILIB_USEDEP}] )
1166 - x264? ( >=media-libs/x264-0.0.20130506:=[${MULTILIB_USEDEP}] )
1167 - x265? ( >=media-libs/x265-1.6:=[${MULTILIB_USEDEP}] )
1168 - xvid? ( >=media-libs/xvid-1.3.2-r1[${MULTILIB_USEDEP}] )
1169 - )
1170 - fdk? ( >=media-libs/fdk-aac-0.1.3:=[${MULTILIB_USEDEP}] )
1171 - flite? ( >=app-accessibility/flite-1.4-r4[${MULTILIB_USEDEP}] )
1172 - fontconfig? ( >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] )
1173 - frei0r? ( media-plugins/frei0r-plugins )
1174 - fribidi? ( >=dev-libs/fribidi-0.19.6[${MULTILIB_USEDEP}] )
1175 - gcrypt? ( >=dev-libs/libgcrypt-1.6:0=[${MULTILIB_USEDEP}] )
1176 - gme? ( >=media-libs/game-music-emu-0.6.0[${MULTILIB_USEDEP}] )
1177 - gmp? ( >=dev-libs/gmp-6:0=[${MULTILIB_USEDEP}] )
1178 - gnutls? ( >=net-libs/gnutls-2.12.23-r6:=[${MULTILIB_USEDEP}] )
1179 - gsm? ( >=media-sound/gsm-1.0.13-r1[${MULTILIB_USEDEP}] )
1180 - iconv? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] )
1181 - iec61883? (
1182 - >=media-libs/libiec61883-1.2.0-r1[${MULTILIB_USEDEP}]
1183 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
1184 - >=sys-libs/libavc1394-0.5.4-r1[${MULTILIB_USEDEP}]
1185 - )
1186 - ieee1394? (
1187 - >=media-libs/libdc1394-2.2.1[${MULTILIB_USEDEP}]
1188 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
1189 - )
1190 - jack? ( virtual/jack[${MULTILIB_USEDEP}] )
1191 - jpeg2k? ( >=media-libs/openjpeg-2:2[${MULTILIB_USEDEP}] )
1192 - libass? ( >=media-libs/libass-0.10.2:=[${MULTILIB_USEDEP}] )
1193 - libcaca? ( >=media-libs/libcaca-0.99_beta18-r1[${MULTILIB_USEDEP}] )
1194 - libilbc? ( >=media-libs/libilbc-2[${MULTILIB_USEDEP}] )
1195 - libsoxr? ( >=media-libs/soxr-0.1.0[${MULTILIB_USEDEP}] )
1196 - libv4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] )
1197 - lzma? ( >=app-arch/xz-utils-5.0.5-r1[${MULTILIB_USEDEP}] )
1198 - mmal? ( media-libs/raspberrypi-userland )
1199 - modplug? ( >=media-libs/libmodplug-0.8.8.4-r1[${MULTILIB_USEDEP}] )
1200 - openal? ( >=media-libs/openal-1.15.1[${MULTILIB_USEDEP}] )
1201 - opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
1202 - openssl? ( >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] )
1203 - opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
1204 - pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
1205 - librtmp? ( >=media-video/rtmpdump-2.4_p20131018[${MULTILIB_USEDEP}] )
1206 - rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
1207 - samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
1208 - sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
1209 - sofalizer? (
1210 - >=sci-libs/netcdf-4.3.2-r1[hdf5]
1211 - >=sci-libs/hdf5-1.8.18[hl]
1212 - )
1213 - speex? ( >=media-libs/speex-1.2_rc1-r1[${MULTILIB_USEDEP}] )
1214 - ssh? ( >=net-libs/libssh-0.5.5[${MULTILIB_USEDEP}] )
1215 - truetype? ( >=media-libs/freetype-2.5.0.1:2[${MULTILIB_USEDEP}] )
1216 - vaapi? ( >=x11-libs/libva-1.2.1-r1[${MULTILIB_USEDEP}] )
1217 - vdpau? ( >=x11-libs/libvdpau-0.7[${MULTILIB_USEDEP}] )
1218 - vorbis? (
1219 - >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}]
1220 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
1221 - )
1222 - vpx? ( >=media-libs/libvpx-1.4.0:=[${MULTILIB_USEDEP}] )
1223 - X? (
1224 - >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}]
1225 - >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}]
1226 - >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}]
1227 - )
1228 - xcb? ( >=x11-libs/libxcb-1.4[${MULTILIB_USEDEP}] )
1229 - zeromq? ( >=net-libs/zeromq-4.1.6 )
1230 - zimg? ( >=media-libs/zimg-2.4:=[${MULTILIB_USEDEP}] )
1231 - zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
1232 - zvbi? ( >=media-libs/zvbi-0.2.35[${MULTILIB_USEDEP}] )
1233 - !media-video/qt-faststart
1234 - postproc? ( !media-libs/libpostproc )
1235 -"
1236 -
1237 -DEPEND="${RDEPEND}
1238 - >=sys-devel/make-3.81
1239 - doc? ( sys-apps/texinfo )
1240 - >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
1241 - ladspa? ( >=media-libs/ladspa-sdk-1.13-r2[${MULTILIB_USEDEP}] )
1242 - cpu_flags_x86_mmx? ( >=dev-lang/yasm-1.2 )
1243 - test? ( net-misc/wget sys-devel/bc )
1244 - v4l? ( sys-kernel/linux-headers )
1245 -"
1246 -
1247 -# Code requiring FFmpeg to be built under gpl license
1248 -GPL_REQUIRED_USE="
1249 - postproc? ( gpl )
1250 - frei0r? ( gpl )
1251 - cdio? ( gpl )
1252 - samba? ( gpl )
1253 - encode? (
1254 - x264? ( gpl )
1255 - x265? ( gpl )
1256 - xvid? ( gpl )
1257 - X? ( !xcb? ( gpl ) )
1258 - )
1259 -"
1260 -REQUIRED_USE="
1261 - libv4l? ( v4l )
1262 - fftools_cws2fws? ( zlib )
1263 - test? ( encode )
1264 - ${GPL_REQUIRED_USE}
1265 - ${CPU_REQUIRED_USE}"
1266 -RESTRICT="
1267 - gpl? ( openssl? ( bindist ) fdk? ( bindist ) )
1268 -"
1269 -
1270 -S=${WORKDIR}/${P/_/-}
1271 -
1272 -MULTILIB_WRAPPED_HEADERS=(
1273 - /usr/include/libavutil/avconfig.h
1274 -)
1275 -
1276 -PATCHES=(
1277 - "${FILESDIR}"/openjpeg22.patch
1278 - "${FILESDIR}"/openjpeg23.patch
1279 - "${FILESDIR}"/chromium.patch
1280 -)
1281 -
1282 -src_prepare() {
1283 - if [[ "${PV%_p*}" != "${PV}" ]] ; then # Snapshot
1284 - export revision=git-N-${FFMPEG_REVISION}
1285 - fi
1286 - default
1287 - echo 'include $(SRC_PATH)/ffbuild/libffmpeg.mak' >> Makefile || die
1288 -}
1289 -
1290 -multilib_src_configure() {
1291 - local myconf=( ${EXTRA_FFMPEG_CONF} )
1292 -
1293 - local ffuse=( "${FFMPEG_FLAG_MAP[@]}" )
1294 - use openssl && use gpl && myconf+=( --enable-nonfree )
1295 - use samba && myconf+=( --enable-version3 )
1296 -
1297 - # Encoders
1298 - if use encode ; then
1299 - ffuse+=( "${FFMPEG_ENCODER_FLAG_MAP[@]}" )
1300 -
1301 - # Licensing.
1302 - if use amrenc ; then
1303 - myconf+=( --enable-version3 )
1304 - fi
1305 - else
1306 - myconf+=( --disable-encoders )
1307 - fi
1308 -
1309 - # Indevs
1310 - use v4l || myconf+=( --disable-indev=v4l2 --disable-outdev=v4l2 )
1311 - for i in alsa oss jack ; do
1312 - use ${i} || myconf+=( --disable-indev=${i} )
1313 - done
1314 -
1315 - # Outdevs
1316 - for i in alsa oss sdl ; do
1317 - use ${i} || myconf+=( --disable-outdev=${i} )
1318 - done
1319 -
1320 - # Decoders
1321 - use amr && myconf+=( --enable-version3 )
1322 - use gmp && myconf+=( --enable-version3 )
1323 - use fdk && use gpl && myconf+=( --enable-nonfree )
1324 -
1325 - for i in "${ffuse[@]#+}" ; do
1326 - myconf+=( $(use_enable ${i%:*} ${i#*:}) )
1327 - done
1328 -
1329 - # (temporarily) disable non-multilib deps
1330 - if ! multilib_is_native_abi; then
1331 - for i in frei0r netcdf libzmq ; do
1332 - myconf+=( --disable-${i} )
1333 - done
1334 - fi
1335 -
1336 - # CPU features
1337 - for i in ${CPU_FEATURES_MAP} ; do
1338 - if [ "$(tc-arch)" = "${i%:*}" ] ; then
1339 - local var="${i#*:}_CPU_FEATURES[@]"
1340 - for j in ${!var} ; do
1341 - use ${j%:*} || myconf+=( --disable-${j#*:} )
1342 - done
1343 - fi
1344 - done
1345 -
1346 - if use pic ; then
1347 - myconf+=( --enable-pic )
1348 - # disable asm code if PIC is required
1349 - # as the provided asm decidedly is not PIC for x86.
1350 - [[ ${ABI} == x86 ]] && myconf+=( --disable-asm )
1351 - fi
1352 - [[ ${ABI} == x32 ]] && myconf+=( --disable-asm ) #427004
1353 -
1354 - # Try to get cpu type based on CFLAGS.
1355 - # Bug #172723
1356 - # We need to do this so that features of that CPU will be better used
1357 - # If they contain an unknown CPU it will not hurt since ffmpeg's configure
1358 - # will just ignore it.
1359 - for i in $(get-flag mcpu) $(get-flag march) ; do
1360 - [[ ${i} = native ]] && i="host" # bug #273421
1361 - myconf+=( --cpu=${i} )
1362 - break
1363 - done
1364 -
1365 - # LTO support, bug #566282
1366 - is-flagq "-flto*" && myconf+=( "--enable-lto" )
1367 -
1368 - # Mandatory configuration
1369 - myconf=(
1370 - --enable-avfilter
1371 - --enable-avresample
1372 - --disable-stripping
1373 - --disable-libcelt # bug #664158
1374 - "${myconf[@]}"
1375 - )
1376 -
1377 - # cross compile support
1378 - if tc-is-cross-compiler ; then
1379 - myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}- --host-cc="$(tc-getBUILD_CC)" )
1380 - case ${CHOST} in
1381 - *freebsd*)
1382 - myconf+=( --target-os=freebsd )
1383 - ;;
1384 - *mingw32*)
1385 - myconf+=( --target-os=mingw32 )
1386 - ;;
1387 - *linux*)
1388 - myconf+=( --target-os=linux )
1389 - ;;
1390 - esac
1391 - fi
1392 -
1393 - # doc
1394 - myconf+=(
1395 - $(multilib_native_use_enable doc)
1396 - $(multilib_native_use_enable doc htmlpages)
1397 - $(multilib_native_enable manpages)
1398 - )
1399 -
1400 - set -- "${S}/configure" \
1401 - --prefix="${EPREFIX}/usr" \
1402 - --libdir="${EPREFIX}/usr/$(get_libdir)" \
1403 - --shlibdir="${EPREFIX}/usr/$(get_libdir)" \
1404 - --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
1405 - --mandir="${EPREFIX}/usr/share/man" \
1406 - --enable-shared \
1407 - --cc="$(tc-getCC)" \
1408 - --cxx="$(tc-getCXX)" \
1409 - --ar="$(tc-getAR)" \
1410 - --optflags="${CFLAGS}" \
1411 - $(use_enable static-libs static) \
1412 - "${myconf[@]}"
1413 - echo "${@}"
1414 - "${@}" || die
1415 -
1416 - if multilib_is_native_abi && use chromium; then
1417 - einfo "Configuring for Chromium"
1418 - mkdir -p ../chromium || die
1419 - pushd ../chromium >/dev/null || die
1420 - set -- "${@}" \
1421 - --disable-shared \
1422 - --enable-static \
1423 - --enable-pic \
1424 - --extra-cflags="-DFF_API_CONVERGENCE_DURATION=0"
1425 - echo "${@}"
1426 - "${@}" || die
1427 - popd >/dev/null || die
1428 - fi
1429 -}
1430 -
1431 -multilib_src_compile() {
1432 - emake V=1
1433 -
1434 - if multilib_is_native_abi; then
1435 - for i in "${FFTOOLS[@]}" ; do
1436 - if use fftools_${i} ; then
1437 - emake V=1 tools/${i}$(get_exeext)
1438 - fi
1439 - done
1440 -
1441 - if use chromium; then
1442 - einfo "Compiling for Chromium"
1443 - pushd ../chromium >/dev/null || die
1444 - emake V=1 libffmpeg
1445 - popd >/dev/null || die
1446 - fi
1447 - fi
1448 -}
1449 -
1450 -multilib_src_install() {
1451 - emake V=1 DESTDIR="${D}" install install-doc
1452 -
1453 - if multilib_is_native_abi; then
1454 - for i in "${FFTOOLS[@]}" ; do
1455 - if use fftools_${i} ; then
1456 - dobin tools/${i}$(get_exeext)
1457 - fi
1458 - done
1459 -
1460 - if use chromium; then
1461 - einfo "Installing for Chromium"
1462 - pushd ../chromium >/dev/null || die
1463 - emake V=1 DESTDIR="${D}" install-libffmpeg
1464 - popd >/dev/null || die
1465 - fi
1466 - fi
1467 -}
1468 -
1469 -multilib_src_install_all() {
1470 - dodoc Changelog README.md CREDITS doc/*.txt doc/APIchanges
1471 - [ -f "RELEASE_NOTES" ] && dodoc "RELEASE_NOTES"
1472 -}
1473 -
1474 -multilib_src_test() {
1475 - LD_LIBRARY_PATH="${BUILD_DIR}/libpostproc:${BUILD_DIR}/libswscale:${BUILD_DIR}/libswresample:${BUILD_DIR}/libavcodec:${BUILD_DIR}/libavdevice:${BUILD_DIR}/libavfilter:${BUILD_DIR}/libavformat:${BUILD_DIR}/libavutil:${BUILD_DIR}/libavresample" \
1476 - emake V=1 fate
1477 -}
1478
1479 diff --git a/media-video/ffmpeg/ffmpeg-3.3.6.ebuild b/media-video/ffmpeg/ffmpeg-3.3.6.ebuild
1480 deleted file mode 100644
1481 index c86f3c9aece..00000000000
1482 --- a/media-video/ffmpeg/ffmpeg-3.3.6.ebuild
1483 +++ /dev/null
1484 @@ -1,505 +0,0 @@
1485 -# Copyright 1999-2018 Gentoo Authors
1486 -# Distributed under the terms of the GNU General Public License v2
1487 -
1488 -EAPI=6
1489 -
1490 -# Subslot: libavutil major.libavcodec major.libavformat major
1491 -# Since FFmpeg ships several libraries, subslot is kind of limited here.
1492 -# Most consumers will use those three libraries, if a "less used" library
1493 -# changes its soname, consumers will have to be rebuilt the old way
1494 -# (preserve-libs).
1495 -# If, for example, a package does not link to libavformat and only libavformat
1496 -# changes its ABI then this package will be rebuilt needlessly. Hence, such a
1497 -# package is free _not_ to := depend on FFmpeg but I would strongly encourage
1498 -# doing so since such a case is unlikely.
1499 -FFMPEG_SUBSLOT=55.57.57
1500 -
1501 -SCM=""
1502 -if [ "${PV#9999}" != "${PV}" ] ; then
1503 - SCM="git-r3"
1504 - EGIT_REPO_URI="git://source.ffmpeg.org/ffmpeg.git"
1505 -fi
1506 -
1507 -inherit eutils flag-o-matic multilib multilib-minimal toolchain-funcs ${SCM}
1508 -
1509 -DESCRIPTION="Complete solution to record, convert and stream audio and video. Includes libavcodec"
1510 -HOMEPAGE="http://ffmpeg.org/"
1511 -if [ "${PV#9999}" != "${PV}" ] ; then
1512 - SRC_URI=""
1513 -elif [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot
1514 - SRC_URI="mirror://gentoo/${P}.tar.bz2"
1515 -else # Release
1516 - SRC_URI="http://ffmpeg.org/releases/${P/_/-}.tar.bz2"
1517 -fi
1518 -FFMPEG_REVISION="${PV#*_p}"
1519 -
1520 -SLOT="0/${FFMPEG_SUBSLOT}"
1521 -LICENSE="
1522 - !gpl? ( LGPL-2.1 )
1523 - gpl? ( GPL-2 )
1524 - amr? (
1525 - gpl? ( GPL-3 )
1526 - !gpl? ( LGPL-3 )
1527 - )
1528 - gmp? (
1529 - gpl? ( GPL-3 )
1530 - !gpl? ( LGPL-3 )
1531 - )
1532 - encode? (
1533 - amrenc? (
1534 - gpl? ( GPL-3 )
1535 - !gpl? ( LGPL-3 )
1536 - )
1537 - )
1538 - samba? ( GPL-3 )
1539 -"
1540 -if [ "${PV#9999}" = "${PV}" ] ; then
1541 - KEYWORDS="amd64 arm ~arm64 ~hppa ia64 ~mips ppc ppc64 x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
1542 -fi
1543 -
1544 -# Options to use as use_enable in the foo[:bar] form.
1545 -# This will feed configure with $(use_enable foo bar)
1546 -# or $(use_enable foo foo) if no :bar is set.
1547 -# foo is added to IUSE.
1548 -FFMPEG_FLAG_MAP=(
1549 - +bzip2:bzlib cpudetection:runtime-cpudetect debug gcrypt gnutls gmp
1550 - +gpl +hardcoded-tables +iconv lzma +network openssl +postproc
1551 - samba:libsmbclient sdl:ffplay sdl:sdl2 vaapi vdpau X:xlib xcb:libxcb
1552 - xcb:libxcb-shm xcb:libxcb-xfixes +zlib
1553 - # libavdevice options
1554 - cdio:libcdio iec61883:libiec61883 ieee1394:libdc1394 libcaca openal
1555 - opengl
1556 - # indevs
1557 - libv4l:libv4l2 pulseaudio:libpulse
1558 - # decoders
1559 - amr:libopencore-amrwb amr:libopencore-amrnb fdk:libfdk-aac
1560 - jpeg2k:libopenjpeg bluray:libbluray gme:libgme gsm:libgsm
1561 - mmal modplug:libmodplug opus:libopus libilbc librtmp ssh:libssh
1562 - speex:libspeex vorbis:libvorbis vpx:libvpx
1563 - zvbi:libzvbi
1564 - # libavfilter options
1565 - bs2b:libbs2b chromaprint flite:libflite frei0r
1566 - fribidi:libfribidi fontconfig ladspa libass truetype:libfreetype
1567 - rubberband:librubberband sofalizer:netcdf zeromq:libzmq zimg:libzimg
1568 - # libswresample options
1569 - libsoxr
1570 - # Threads; we only support pthread for now but ffmpeg supports more
1571 - +threads:pthreads
1572 -)
1573 -
1574 -# Same as above but for encoders, i.e. they do something only with USE=encode.
1575 -FFMPEG_ENCODER_FLAG_MAP=(
1576 - amrenc:libvo-amrwbenc mp3:libmp3lame
1577 - kvazaar:libkvazaar nvenc:nvenc
1578 - openh264:libopenh264 snappy:libsnappy theora:libtheora twolame:libtwolame
1579 - wavpack:libwavpack webp:libwebp x264:libx264 x265:libx265 xvid:libxvid
1580 -)
1581 -
1582 -IUSE="
1583 - alsa chromium doc +encode jack oss pic static-libs test v4l
1584 - ${FFMPEG_FLAG_MAP[@]%:*}
1585 - ${FFMPEG_ENCODER_FLAG_MAP[@]%:*}
1586 -"
1587 -
1588 -# Strings for CPU features in the useflag[:configure_option] form
1589 -# if :configure_option isn't set, it will use 'useflag' as configure option
1590 -ARM_CPU_FEATURES=(
1591 - cpu_flags_arm_thumb:armv5te
1592 - cpu_flags_arm_v6:armv6
1593 - cpu_flags_arm_thumb2:armv6t2
1594 - cpu_flags_arm_neon:neon
1595 - cpu_flags_arm_vfp:vfp
1596 - cpu_flags_arm_vfpv3:vfpv3
1597 - cpu_flags_arm_v8:armv8
1598 -)
1599 -ARM_CPU_REQUIRED_USE="
1600 - arm64? ( cpu_flags_arm_v8 )
1601 - cpu_flags_arm_v8? ( cpu_flags_arm_vfpv3 cpu_flags_arm_neon )
1602 - cpu_flags_arm_neon? ( cpu_flags_arm_thumb2 cpu_flags_arm_vfp )
1603 - cpu_flags_arm_vfpv3? ( cpu_flags_arm_vfp )
1604 - cpu_flags_arm_thumb2? ( cpu_flags_arm_v6 )
1605 - cpu_flags_arm_v6? ( cpu_flags_arm_thumb )
1606 -"
1607 -MIPS_CPU_FEATURES=( mipsdspr1:mipsdsp mipsdspr2 mipsfpu )
1608 -PPC_CPU_FEATURES=( altivec )
1609 -X86_CPU_FEATURES_RAW=( 3dnow:amd3dnow 3dnowext:amd3dnowext aes:aesni avx:avx avx2:avx2 fma3:fma3 fma4:fma4 mmx:mmx mmxext:mmxext sse:sse sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4 sse4_2:sse42 xop:xop )
1610 -X86_CPU_FEATURES=( ${X86_CPU_FEATURES_RAW[@]/#/cpu_flags_x86_} )
1611 -X86_CPU_REQUIRED_USE="
1612 - cpu_flags_x86_avx2? ( cpu_flags_x86_avx )
1613 - cpu_flags_x86_fma4? ( cpu_flags_x86_avx )
1614 - cpu_flags_x86_fma3? ( cpu_flags_x86_avx )
1615 - cpu_flags_x86_xop? ( cpu_flags_x86_avx )
1616 - cpu_flags_x86_avx? ( cpu_flags_x86_sse4_2 )
1617 - cpu_flags_x86_aes? ( cpu_flags_x86_sse4_2 )
1618 - cpu_flags_x86_sse4_2? ( cpu_flags_x86_sse4_1 )
1619 - cpu_flags_x86_sse4_1? ( cpu_flags_x86_ssse3 )
1620 - cpu_flags_x86_ssse3? ( cpu_flags_x86_sse3 )
1621 - cpu_flags_x86_sse3? ( cpu_flags_x86_sse2 )
1622 - cpu_flags_x86_sse2? ( cpu_flags_x86_sse )
1623 - cpu_flags_x86_sse? ( cpu_flags_x86_mmxext )
1624 - cpu_flags_x86_mmxext? ( cpu_flags_x86_mmx )
1625 - cpu_flags_x86_3dnowext? ( cpu_flags_x86_3dnow )
1626 - cpu_flags_x86_3dnow? ( cpu_flags_x86_mmx )
1627 -"
1628 -
1629 -IUSE="${IUSE}
1630 - ${ARM_CPU_FEATURES[@]%:*}
1631 - ${MIPS_CPU_FEATURES[@]%:*}
1632 - ${PPC_CPU_FEATURES[@]%:*}
1633 - ${X86_CPU_FEATURES[@]%:*}
1634 -"
1635 -
1636 -CPU_REQUIRED_USE="
1637 - ${ARM_CPU_REQUIRED_USE}
1638 - ${X86_CPU_REQUIRED_USE}
1639 -"
1640 -
1641 -# "$(tc-arch):XXX" form where XXX_CPU_FEATURES are the cpu features that apply to
1642 -# $(tc-arch).
1643 -CPU_FEATURES_MAP="
1644 - arm:ARM
1645 - arm64:ARM
1646 - mips:MIPS
1647 - ppc:PPC
1648 - ppc64:PPC
1649 - x86:X86
1650 - amd64:X86
1651 -"
1652 -
1653 -FFTOOLS=( aviocat cws2fws ffescape ffeval ffhash fourcc2pixfmt graph2dot ismindex pktdumper qt-faststart sidxindex trasher )
1654 -IUSE="${IUSE} ${FFTOOLS[@]/#/+fftools_}"
1655 -
1656 -RDEPEND="
1657 - alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] )
1658 - amr? ( >=media-libs/opencore-amr-0.1.3-r1[${MULTILIB_USEDEP}] )
1659 - bluray? ( >=media-libs/libbluray-0.3.0-r1:=[${MULTILIB_USEDEP}] )
1660 - bs2b? ( >=media-libs/libbs2b-3.1.0-r1[${MULTILIB_USEDEP}] )
1661 - bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] )
1662 - cdio? ( >=dev-libs/libcdio-paranoia-0.90_p1-r1[${MULTILIB_USEDEP}] )
1663 - chromaprint? ( >=media-libs/chromaprint-1.2-r1[${MULTILIB_USEDEP}] )
1664 - encode? (
1665 - amrenc? ( >=media-libs/vo-amrwbenc-0.1.2-r1[${MULTILIB_USEDEP}] )
1666 - kvazaar? ( media-libs/kvazaar[${MULTILIB_USEDEP}] )
1667 - mp3? ( >=media-sound/lame-3.99.5-r1[${MULTILIB_USEDEP}] )
1668 - nvenc? ( media-video/nvidia_video_sdk )
1669 - openh264? ( >=media-libs/openh264-1.4.0-r1[${MULTILIB_USEDEP}] )
1670 - snappy? ( >=app-arch/snappy-1.1.2-r1:=[${MULTILIB_USEDEP}] )
1671 - theora? (
1672 - >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}]
1673 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
1674 - )
1675 - twolame? ( >=media-sound/twolame-0.3.13-r1[${MULTILIB_USEDEP}] )
1676 - wavpack? ( >=media-sound/wavpack-4.60.1-r1[${MULTILIB_USEDEP}] )
1677 - webp? ( >=media-libs/libwebp-0.3.0:=[${MULTILIB_USEDEP}] )
1678 - x264? ( >=media-libs/x264-0.0.20130506:=[${MULTILIB_USEDEP}] )
1679 - x265? ( >=media-libs/x265-1.6:=[${MULTILIB_USEDEP}] )
1680 - xvid? ( >=media-libs/xvid-1.3.2-r1[${MULTILIB_USEDEP}] )
1681 - )
1682 - fdk? ( >=media-libs/fdk-aac-0.1.3:=[${MULTILIB_USEDEP}] )
1683 - flite? ( >=app-accessibility/flite-1.4-r4[${MULTILIB_USEDEP}] )
1684 - fontconfig? ( >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] )
1685 - frei0r? ( media-plugins/frei0r-plugins )
1686 - fribidi? ( >=dev-libs/fribidi-0.19.6[${MULTILIB_USEDEP}] )
1687 - gcrypt? ( >=dev-libs/libgcrypt-1.6:0=[${MULTILIB_USEDEP}] )
1688 - gme? ( >=media-libs/game-music-emu-0.6.0[${MULTILIB_USEDEP}] )
1689 - gmp? ( >=dev-libs/gmp-6:0=[${MULTILIB_USEDEP}] )
1690 - gnutls? ( >=net-libs/gnutls-2.12.23-r6:=[${MULTILIB_USEDEP}] )
1691 - gsm? ( >=media-sound/gsm-1.0.13-r1[${MULTILIB_USEDEP}] )
1692 - iconv? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] )
1693 - iec61883? (
1694 - >=media-libs/libiec61883-1.2.0-r1[${MULTILIB_USEDEP}]
1695 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
1696 - >=sys-libs/libavc1394-0.5.4-r1[${MULTILIB_USEDEP}]
1697 - )
1698 - ieee1394? (
1699 - >=media-libs/libdc1394-2.2.1[${MULTILIB_USEDEP}]
1700 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
1701 - )
1702 - jack? ( virtual/jack[${MULTILIB_USEDEP}] )
1703 - jpeg2k? ( >=media-libs/openjpeg-2:2[${MULTILIB_USEDEP}] )
1704 - libass? ( >=media-libs/libass-0.10.2:=[${MULTILIB_USEDEP}] )
1705 - libcaca? ( >=media-libs/libcaca-0.99_beta18-r1[${MULTILIB_USEDEP}] )
1706 - libilbc? ( >=media-libs/libilbc-2[${MULTILIB_USEDEP}] )
1707 - libsoxr? ( >=media-libs/soxr-0.1.0[${MULTILIB_USEDEP}] )
1708 - libv4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] )
1709 - lzma? ( >=app-arch/xz-utils-5.0.5-r1[${MULTILIB_USEDEP}] )
1710 - mmal? ( media-libs/raspberrypi-userland )
1711 - modplug? ( >=media-libs/libmodplug-0.8.8.4-r1[${MULTILIB_USEDEP}] )
1712 - openal? ( >=media-libs/openal-1.15.1[${MULTILIB_USEDEP}] )
1713 - opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
1714 - openssl? ( >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] )
1715 - opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
1716 - pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
1717 - librtmp? ( >=media-video/rtmpdump-2.4_p20131018[${MULTILIB_USEDEP}] )
1718 - rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
1719 - samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
1720 - sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
1721 - sofalizer? (
1722 - >=sci-libs/netcdf-4.3.2-r1[hdf5]
1723 - >=sci-libs/hdf5-1.8.18[hl]
1724 - )
1725 - speex? ( >=media-libs/speex-1.2_rc1-r1[${MULTILIB_USEDEP}] )
1726 - ssh? ( >=net-libs/libssh-0.5.5[${MULTILIB_USEDEP}] )
1727 - truetype? ( >=media-libs/freetype-2.5.0.1:2[${MULTILIB_USEDEP}] )
1728 - vaapi? ( >=x11-libs/libva-1.2.1-r1[${MULTILIB_USEDEP}] )
1729 - vdpau? ( >=x11-libs/libvdpau-0.7[${MULTILIB_USEDEP}] )
1730 - vorbis? (
1731 - >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}]
1732 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
1733 - )
1734 - vpx? ( >=media-libs/libvpx-1.4.0:=[${MULTILIB_USEDEP}] )
1735 - X? (
1736 - >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}]
1737 - >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}]
1738 - >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}]
1739 - )
1740 - xcb? ( >=x11-libs/libxcb-1.4[${MULTILIB_USEDEP}] )
1741 - zeromq? ( >=net-libs/zeromq-4.1.6 )
1742 - zimg? ( >=media-libs/zimg-2.4:=[${MULTILIB_USEDEP}] )
1743 - zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
1744 - zvbi? ( >=media-libs/zvbi-0.2.35[${MULTILIB_USEDEP}] )
1745 - !media-video/qt-faststart
1746 - postproc? ( !media-libs/libpostproc )
1747 -"
1748 -
1749 -DEPEND="${RDEPEND}
1750 - >=sys-devel/make-3.81
1751 - doc? ( sys-apps/texinfo )
1752 - >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
1753 - ladspa? ( >=media-libs/ladspa-sdk-1.13-r2[${MULTILIB_USEDEP}] )
1754 - cpu_flags_x86_mmx? ( >=dev-lang/yasm-1.2 )
1755 - test? ( net-misc/wget sys-devel/bc )
1756 - v4l? ( sys-kernel/linux-headers )
1757 -"
1758 -
1759 -# Code requiring FFmpeg to be built under gpl license
1760 -GPL_REQUIRED_USE="
1761 - postproc? ( gpl )
1762 - frei0r? ( gpl )
1763 - cdio? ( gpl )
1764 - samba? ( gpl )
1765 - encode? (
1766 - x264? ( gpl )
1767 - x265? ( gpl )
1768 - xvid? ( gpl )
1769 - X? ( !xcb? ( gpl ) )
1770 - )
1771 -"
1772 -REQUIRED_USE="
1773 - libv4l? ( v4l )
1774 - fftools_cws2fws? ( zlib )
1775 - test? ( encode )
1776 - ${GPL_REQUIRED_USE}
1777 - ${CPU_REQUIRED_USE}"
1778 -RESTRICT="
1779 - gpl? ( openssl? ( bindist ) fdk? ( bindist ) )
1780 -"
1781 -
1782 -S=${WORKDIR}/${P/_/-}
1783 -
1784 -MULTILIB_WRAPPED_HEADERS=(
1785 - /usr/include/libavutil/avconfig.h
1786 -)
1787 -
1788 -PATCHES=(
1789 - "${FILESDIR}"/openjpeg22.patch
1790 - "${FILESDIR}"/openjpeg23.patch
1791 - "${FILESDIR}"/chromium.patch
1792 -)
1793 -
1794 -src_prepare() {
1795 - if [[ "${PV%_p*}" != "${PV}" ]] ; then # Snapshot
1796 - export revision=git-N-${FFMPEG_REVISION}
1797 - fi
1798 - default
1799 - echo 'include $(SRC_PATH)/ffbuild/libffmpeg.mak' >> Makefile || die
1800 -}
1801 -
1802 -multilib_src_configure() {
1803 - local myconf=( ${EXTRA_FFMPEG_CONF} )
1804 -
1805 - local ffuse=( "${FFMPEG_FLAG_MAP[@]}" )
1806 - use openssl && use gpl && myconf+=( --enable-nonfree )
1807 - use samba && myconf+=( --enable-version3 )
1808 -
1809 - # Encoders
1810 - if use encode ; then
1811 - ffuse+=( "${FFMPEG_ENCODER_FLAG_MAP[@]}" )
1812 -
1813 - # Licensing.
1814 - if use amrenc ; then
1815 - myconf+=( --enable-version3 )
1816 - fi
1817 - else
1818 - myconf+=( --disable-encoders )
1819 - fi
1820 -
1821 - # Indevs
1822 - use v4l || myconf+=( --disable-indev=v4l2 --disable-outdev=v4l2 )
1823 - for i in alsa oss jack ; do
1824 - use ${i} || myconf+=( --disable-indev=${i} )
1825 - done
1826 -
1827 - # Outdevs
1828 - for i in alsa oss sdl ; do
1829 - use ${i} || myconf+=( --disable-outdev=${i} )
1830 - done
1831 -
1832 - # Decoders
1833 - use amr && myconf+=( --enable-version3 )
1834 - use gmp && myconf+=( --enable-version3 )
1835 - use fdk && use gpl && myconf+=( --enable-nonfree )
1836 -
1837 - for i in "${ffuse[@]#+}" ; do
1838 - myconf+=( $(use_enable ${i%:*} ${i#*:}) )
1839 - done
1840 -
1841 - # (temporarily) disable non-multilib deps
1842 - if ! multilib_is_native_abi; then
1843 - for i in frei0r netcdf libzmq ; do
1844 - myconf+=( --disable-${i} )
1845 - done
1846 - fi
1847 -
1848 - # CPU features
1849 - for i in ${CPU_FEATURES_MAP} ; do
1850 - if [ "$(tc-arch)" = "${i%:*}" ] ; then
1851 - local var="${i#*:}_CPU_FEATURES[@]"
1852 - for j in ${!var} ; do
1853 - use ${j%:*} || myconf+=( --disable-${j#*:} )
1854 - done
1855 - fi
1856 - done
1857 -
1858 - if use pic ; then
1859 - myconf+=( --enable-pic )
1860 - # disable asm code if PIC is required
1861 - # as the provided asm decidedly is not PIC for x86.
1862 - [[ ${ABI} == x86 ]] && myconf+=( --disable-asm )
1863 - fi
1864 - [[ ${ABI} == x32 ]] && myconf+=( --disable-asm ) #427004
1865 -
1866 - # Try to get cpu type based on CFLAGS.
1867 - # Bug #172723
1868 - # We need to do this so that features of that CPU will be better used
1869 - # If they contain an unknown CPU it will not hurt since ffmpeg's configure
1870 - # will just ignore it.
1871 - for i in $(get-flag mcpu) $(get-flag march) ; do
1872 - [[ ${i} = native ]] && i="host" # bug #273421
1873 - myconf+=( --cpu=${i} )
1874 - break
1875 - done
1876 -
1877 - # LTO support, bug #566282
1878 - is-flagq "-flto*" && myconf+=( "--enable-lto" )
1879 -
1880 - # Mandatory configuration
1881 - myconf=(
1882 - --enable-avfilter
1883 - --enable-avresample
1884 - --disable-stripping
1885 - --disable-libcelt # bug #664158
1886 - "${myconf[@]}"
1887 - )
1888 -
1889 - # cross compile support
1890 - if tc-is-cross-compiler ; then
1891 - myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}- --host-cc="$(tc-getBUILD_CC)" )
1892 - case ${CHOST} in
1893 - *freebsd*)
1894 - myconf+=( --target-os=freebsd )
1895 - ;;
1896 - *mingw32*)
1897 - myconf+=( --target-os=mingw32 )
1898 - ;;
1899 - *linux*)
1900 - myconf+=( --target-os=linux )
1901 - ;;
1902 - esac
1903 - fi
1904 -
1905 - # doc
1906 - myconf+=(
1907 - $(multilib_native_use_enable doc)
1908 - $(multilib_native_use_enable doc htmlpages)
1909 - $(multilib_native_enable manpages)
1910 - )
1911 -
1912 - set -- "${S}/configure" \
1913 - --prefix="${EPREFIX}/usr" \
1914 - --libdir="${EPREFIX}/usr/$(get_libdir)" \
1915 - --shlibdir="${EPREFIX}/usr/$(get_libdir)" \
1916 - --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
1917 - --mandir="${EPREFIX}/usr/share/man" \
1918 - --enable-shared \
1919 - --cc="$(tc-getCC)" \
1920 - --cxx="$(tc-getCXX)" \
1921 - --ar="$(tc-getAR)" \
1922 - --optflags="${CFLAGS}" \
1923 - $(use_enable static-libs static) \
1924 - "${myconf[@]}"
1925 - echo "${@}"
1926 - "${@}" || die
1927 -
1928 - if multilib_is_native_abi && use chromium; then
1929 - einfo "Configuring for Chromium"
1930 - mkdir -p ../chromium || die
1931 - pushd ../chromium >/dev/null || die
1932 - set -- "${@}" \
1933 - --disable-shared \
1934 - --enable-static \
1935 - --enable-pic \
1936 - --extra-cflags="-DFF_API_CONVERGENCE_DURATION=0"
1937 - echo "${@}"
1938 - "${@}" || die
1939 - popd >/dev/null || die
1940 - fi
1941 -}
1942 -
1943 -multilib_src_compile() {
1944 - emake V=1
1945 -
1946 - if multilib_is_native_abi; then
1947 - for i in "${FFTOOLS[@]}" ; do
1948 - if use fftools_${i} ; then
1949 - emake V=1 tools/${i}$(get_exeext)
1950 - fi
1951 - done
1952 -
1953 - if use chromium; then
1954 - einfo "Compiling for Chromium"
1955 - pushd ../chromium >/dev/null || die
1956 - emake V=1 libffmpeg
1957 - popd >/dev/null || die
1958 - fi
1959 - fi
1960 -}
1961 -
1962 -multilib_src_install() {
1963 - emake V=1 DESTDIR="${D}" install install-doc
1964 -
1965 - if multilib_is_native_abi; then
1966 - for i in "${FFTOOLS[@]}" ; do
1967 - if use fftools_${i} ; then
1968 - dobin tools/${i}$(get_exeext)
1969 - fi
1970 - done
1971 -
1972 - if use chromium; then
1973 - einfo "Installing for Chromium"
1974 - pushd ../chromium >/dev/null || die
1975 - emake V=1 DESTDIR="${D}" install-libffmpeg
1976 - popd >/dev/null || die
1977 - fi
1978 - fi
1979 -}
1980 -
1981 -multilib_src_install_all() {
1982 - dodoc Changelog README.md CREDITS doc/*.txt doc/APIchanges
1983 - [ -f "RELEASE_NOTES" ] && dodoc "RELEASE_NOTES"
1984 -}
1985 -
1986 -multilib_src_test() {
1987 - LD_LIBRARY_PATH="${BUILD_DIR}/libpostproc:${BUILD_DIR}/libswscale:${BUILD_DIR}/libswresample:${BUILD_DIR}/libavcodec:${BUILD_DIR}/libavdevice:${BUILD_DIR}/libavfilter:${BUILD_DIR}/libavformat:${BUILD_DIR}/libavutil:${BUILD_DIR}/libavresample" \
1988 - emake V=1 fate
1989 -}
1990
1991 diff --git a/media-video/ffmpeg/ffmpeg-3.3.8.ebuild b/media-video/ffmpeg/ffmpeg-3.3.8.ebuild
1992 deleted file mode 100644
1993 index fe80b8d1262..00000000000
1994 --- a/media-video/ffmpeg/ffmpeg-3.3.8.ebuild
1995 +++ /dev/null
1996 @@ -1,505 +0,0 @@
1997 -# Copyright 1999-2018 Gentoo Authors
1998 -# Distributed under the terms of the GNU General Public License v2
1999 -
2000 -EAPI=6
2001 -
2002 -# Subslot: libavutil major.libavcodec major.libavformat major
2003 -# Since FFmpeg ships several libraries, subslot is kind of limited here.
2004 -# Most consumers will use those three libraries, if a "less used" library
2005 -# changes its soname, consumers will have to be rebuilt the old way
2006 -# (preserve-libs).
2007 -# If, for example, a package does not link to libavformat and only libavformat
2008 -# changes its ABI then this package will be rebuilt needlessly. Hence, such a
2009 -# package is free _not_ to := depend on FFmpeg but I would strongly encourage
2010 -# doing so since such a case is unlikely.
2011 -FFMPEG_SUBSLOT=55.57.57
2012 -
2013 -SCM=""
2014 -if [ "${PV#9999}" != "${PV}" ] ; then
2015 - SCM="git-r3"
2016 - EGIT_REPO_URI="git://source.ffmpeg.org/ffmpeg.git"
2017 -fi
2018 -
2019 -inherit eutils flag-o-matic multilib multilib-minimal toolchain-funcs ${SCM}
2020 -
2021 -DESCRIPTION="Complete solution to record, convert and stream audio and video. Includes libavcodec"
2022 -HOMEPAGE="http://ffmpeg.org/"
2023 -if [ "${PV#9999}" != "${PV}" ] ; then
2024 - SRC_URI=""
2025 -elif [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot
2026 - SRC_URI="mirror://gentoo/${P}.tar.bz2"
2027 -else # Release
2028 - SRC_URI="http://ffmpeg.org/releases/${P/_/-}.tar.bz2"
2029 -fi
2030 -FFMPEG_REVISION="${PV#*_p}"
2031 -
2032 -SLOT="0/${FFMPEG_SUBSLOT}"
2033 -LICENSE="
2034 - !gpl? ( LGPL-2.1 )
2035 - gpl? ( GPL-2 )
2036 - amr? (
2037 - gpl? ( GPL-3 )
2038 - !gpl? ( LGPL-3 )
2039 - )
2040 - gmp? (
2041 - gpl? ( GPL-3 )
2042 - !gpl? ( LGPL-3 )
2043 - )
2044 - encode? (
2045 - amrenc? (
2046 - gpl? ( GPL-3 )
2047 - !gpl? ( LGPL-3 )
2048 - )
2049 - )
2050 - samba? ( GPL-3 )
2051 -"
2052 -if [ "${PV#9999}" = "${PV}" ] ; then
2053 - KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
2054 -fi
2055 -
2056 -# Options to use as use_enable in the foo[:bar] form.
2057 -# This will feed configure with $(use_enable foo bar)
2058 -# or $(use_enable foo foo) if no :bar is set.
2059 -# foo is added to IUSE.
2060 -FFMPEG_FLAG_MAP=(
2061 - +bzip2:bzlib cpudetection:runtime-cpudetect debug gcrypt gnutls gmp
2062 - +gpl +hardcoded-tables +iconv lzma +network openssl +postproc
2063 - samba:libsmbclient sdl:ffplay sdl:sdl2 vaapi vdpau X:xlib xcb:libxcb
2064 - xcb:libxcb-shm xcb:libxcb-xfixes +zlib
2065 - # libavdevice options
2066 - cdio:libcdio iec61883:libiec61883 ieee1394:libdc1394 libcaca openal
2067 - opengl
2068 - # indevs
2069 - libv4l:libv4l2 pulseaudio:libpulse
2070 - # decoders
2071 - amr:libopencore-amrwb amr:libopencore-amrnb fdk:libfdk-aac
2072 - jpeg2k:libopenjpeg bluray:libbluray gme:libgme gsm:libgsm
2073 - mmal modplug:libmodplug opus:libopus libilbc librtmp ssh:libssh
2074 - speex:libspeex vorbis:libvorbis vpx:libvpx
2075 - zvbi:libzvbi
2076 - # libavfilter options
2077 - bs2b:libbs2b chromaprint flite:libflite frei0r
2078 - fribidi:libfribidi fontconfig ladspa libass truetype:libfreetype
2079 - rubberband:librubberband sofalizer:netcdf zeromq:libzmq zimg:libzimg
2080 - # libswresample options
2081 - libsoxr
2082 - # Threads; we only support pthread for now but ffmpeg supports more
2083 - +threads:pthreads
2084 -)
2085 -
2086 -# Same as above but for encoders, i.e. they do something only with USE=encode.
2087 -FFMPEG_ENCODER_FLAG_MAP=(
2088 - amrenc:libvo-amrwbenc mp3:libmp3lame
2089 - kvazaar:libkvazaar nvenc:nvenc
2090 - openh264:libopenh264 snappy:libsnappy theora:libtheora twolame:libtwolame
2091 - wavpack:libwavpack webp:libwebp x264:libx264 x265:libx265 xvid:libxvid
2092 -)
2093 -
2094 -IUSE="
2095 - alsa chromium doc +encode jack oss pic static-libs test v4l
2096 - ${FFMPEG_FLAG_MAP[@]%:*}
2097 - ${FFMPEG_ENCODER_FLAG_MAP[@]%:*}
2098 -"
2099 -
2100 -# Strings for CPU features in the useflag[:configure_option] form
2101 -# if :configure_option isn't set, it will use 'useflag' as configure option
2102 -ARM_CPU_FEATURES=(
2103 - cpu_flags_arm_thumb:armv5te
2104 - cpu_flags_arm_v6:armv6
2105 - cpu_flags_arm_thumb2:armv6t2
2106 - cpu_flags_arm_neon:neon
2107 - cpu_flags_arm_vfp:vfp
2108 - cpu_flags_arm_vfpv3:vfpv3
2109 - cpu_flags_arm_v8:armv8
2110 -)
2111 -ARM_CPU_REQUIRED_USE="
2112 - arm64? ( cpu_flags_arm_v8 )
2113 - cpu_flags_arm_v8? ( cpu_flags_arm_vfpv3 cpu_flags_arm_neon )
2114 - cpu_flags_arm_neon? ( cpu_flags_arm_thumb2 cpu_flags_arm_vfp )
2115 - cpu_flags_arm_vfpv3? ( cpu_flags_arm_vfp )
2116 - cpu_flags_arm_thumb2? ( cpu_flags_arm_v6 )
2117 - cpu_flags_arm_v6? ( cpu_flags_arm_thumb )
2118 -"
2119 -MIPS_CPU_FEATURES=( mipsdspr1:mipsdsp mipsdspr2 mipsfpu )
2120 -PPC_CPU_FEATURES=( altivec )
2121 -X86_CPU_FEATURES_RAW=( 3dnow:amd3dnow 3dnowext:amd3dnowext aes:aesni avx:avx avx2:avx2 fma3:fma3 fma4:fma4 mmx:mmx mmxext:mmxext sse:sse sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4 sse4_2:sse42 xop:xop )
2122 -X86_CPU_FEATURES=( ${X86_CPU_FEATURES_RAW[@]/#/cpu_flags_x86_} )
2123 -X86_CPU_REQUIRED_USE="
2124 - cpu_flags_x86_avx2? ( cpu_flags_x86_avx )
2125 - cpu_flags_x86_fma4? ( cpu_flags_x86_avx )
2126 - cpu_flags_x86_fma3? ( cpu_flags_x86_avx )
2127 - cpu_flags_x86_xop? ( cpu_flags_x86_avx )
2128 - cpu_flags_x86_avx? ( cpu_flags_x86_sse4_2 )
2129 - cpu_flags_x86_aes? ( cpu_flags_x86_sse4_2 )
2130 - cpu_flags_x86_sse4_2? ( cpu_flags_x86_sse4_1 )
2131 - cpu_flags_x86_sse4_1? ( cpu_flags_x86_ssse3 )
2132 - cpu_flags_x86_ssse3? ( cpu_flags_x86_sse3 )
2133 - cpu_flags_x86_sse3? ( cpu_flags_x86_sse2 )
2134 - cpu_flags_x86_sse2? ( cpu_flags_x86_sse )
2135 - cpu_flags_x86_sse? ( cpu_flags_x86_mmxext )
2136 - cpu_flags_x86_mmxext? ( cpu_flags_x86_mmx )
2137 - cpu_flags_x86_3dnowext? ( cpu_flags_x86_3dnow )
2138 - cpu_flags_x86_3dnow? ( cpu_flags_x86_mmx )
2139 -"
2140 -
2141 -IUSE="${IUSE}
2142 - ${ARM_CPU_FEATURES[@]%:*}
2143 - ${MIPS_CPU_FEATURES[@]%:*}
2144 - ${PPC_CPU_FEATURES[@]%:*}
2145 - ${X86_CPU_FEATURES[@]%:*}
2146 -"
2147 -
2148 -CPU_REQUIRED_USE="
2149 - ${ARM_CPU_REQUIRED_USE}
2150 - ${X86_CPU_REQUIRED_USE}
2151 -"
2152 -
2153 -# "$(tc-arch):XXX" form where XXX_CPU_FEATURES are the cpu features that apply to
2154 -# $(tc-arch).
2155 -CPU_FEATURES_MAP="
2156 - arm:ARM
2157 - arm64:ARM
2158 - mips:MIPS
2159 - ppc:PPC
2160 - ppc64:PPC
2161 - x86:X86
2162 - amd64:X86
2163 -"
2164 -
2165 -FFTOOLS=( aviocat cws2fws ffescape ffeval ffhash fourcc2pixfmt graph2dot ismindex pktdumper qt-faststart sidxindex trasher )
2166 -IUSE="${IUSE} ${FFTOOLS[@]/#/+fftools_}"
2167 -
2168 -RDEPEND="
2169 - alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] )
2170 - amr? ( >=media-libs/opencore-amr-0.1.3-r1[${MULTILIB_USEDEP}] )
2171 - bluray? ( >=media-libs/libbluray-0.3.0-r1:=[${MULTILIB_USEDEP}] )
2172 - bs2b? ( >=media-libs/libbs2b-3.1.0-r1[${MULTILIB_USEDEP}] )
2173 - bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] )
2174 - cdio? ( >=dev-libs/libcdio-paranoia-0.90_p1-r1[${MULTILIB_USEDEP}] )
2175 - chromaprint? ( >=media-libs/chromaprint-1.2-r1[${MULTILIB_USEDEP}] )
2176 - encode? (
2177 - amrenc? ( >=media-libs/vo-amrwbenc-0.1.2-r1[${MULTILIB_USEDEP}] )
2178 - kvazaar? ( media-libs/kvazaar[${MULTILIB_USEDEP}] )
2179 - mp3? ( >=media-sound/lame-3.99.5-r1[${MULTILIB_USEDEP}] )
2180 - nvenc? ( media-video/nvidia_video_sdk )
2181 - openh264? ( >=media-libs/openh264-1.4.0-r1[${MULTILIB_USEDEP}] )
2182 - snappy? ( >=app-arch/snappy-1.1.2-r1:=[${MULTILIB_USEDEP}] )
2183 - theora? (
2184 - >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}]
2185 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
2186 - )
2187 - twolame? ( >=media-sound/twolame-0.3.13-r1[${MULTILIB_USEDEP}] )
2188 - wavpack? ( >=media-sound/wavpack-4.60.1-r1[${MULTILIB_USEDEP}] )
2189 - webp? ( >=media-libs/libwebp-0.3.0:=[${MULTILIB_USEDEP}] )
2190 - x264? ( >=media-libs/x264-0.0.20130506:=[${MULTILIB_USEDEP}] )
2191 - x265? ( >=media-libs/x265-1.6:=[${MULTILIB_USEDEP}] )
2192 - xvid? ( >=media-libs/xvid-1.3.2-r1[${MULTILIB_USEDEP}] )
2193 - )
2194 - fdk? ( >=media-libs/fdk-aac-0.1.3:=[${MULTILIB_USEDEP}] )
2195 - flite? ( >=app-accessibility/flite-1.4-r4[${MULTILIB_USEDEP}] )
2196 - fontconfig? ( >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] )
2197 - frei0r? ( media-plugins/frei0r-plugins )
2198 - fribidi? ( >=dev-libs/fribidi-0.19.6[${MULTILIB_USEDEP}] )
2199 - gcrypt? ( >=dev-libs/libgcrypt-1.6:0=[${MULTILIB_USEDEP}] )
2200 - gme? ( >=media-libs/game-music-emu-0.6.0[${MULTILIB_USEDEP}] )
2201 - gmp? ( >=dev-libs/gmp-6:0=[${MULTILIB_USEDEP}] )
2202 - gnutls? ( >=net-libs/gnutls-2.12.23-r6:=[${MULTILIB_USEDEP}] )
2203 - gsm? ( >=media-sound/gsm-1.0.13-r1[${MULTILIB_USEDEP}] )
2204 - iconv? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] )
2205 - iec61883? (
2206 - >=media-libs/libiec61883-1.2.0-r1[${MULTILIB_USEDEP}]
2207 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
2208 - >=sys-libs/libavc1394-0.5.4-r1[${MULTILIB_USEDEP}]
2209 - )
2210 - ieee1394? (
2211 - >=media-libs/libdc1394-2.2.1[${MULTILIB_USEDEP}]
2212 - >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}]
2213 - )
2214 - jack? ( virtual/jack[${MULTILIB_USEDEP}] )
2215 - jpeg2k? ( >=media-libs/openjpeg-2:2[${MULTILIB_USEDEP}] )
2216 - libass? ( >=media-libs/libass-0.10.2:=[${MULTILIB_USEDEP}] )
2217 - libcaca? ( >=media-libs/libcaca-0.99_beta18-r1[${MULTILIB_USEDEP}] )
2218 - libilbc? ( >=media-libs/libilbc-2[${MULTILIB_USEDEP}] )
2219 - libsoxr? ( >=media-libs/soxr-0.1.0[${MULTILIB_USEDEP}] )
2220 - libv4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] )
2221 - lzma? ( >=app-arch/xz-utils-5.0.5-r1[${MULTILIB_USEDEP}] )
2222 - mmal? ( media-libs/raspberrypi-userland )
2223 - modplug? ( >=media-libs/libmodplug-0.8.8.4-r1[${MULTILIB_USEDEP}] )
2224 - openal? ( >=media-libs/openal-1.15.1[${MULTILIB_USEDEP}] )
2225 - opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
2226 - openssl? ( >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] )
2227 - opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
2228 - pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
2229 - librtmp? ( >=media-video/rtmpdump-2.4_p20131018[${MULTILIB_USEDEP}] )
2230 - rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
2231 - samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
2232 - sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
2233 - sofalizer? (
2234 - >=sci-libs/netcdf-4.3.2-r1[hdf5]
2235 - >=sci-libs/hdf5-1.8.18[hl]
2236 - )
2237 - speex? ( >=media-libs/speex-1.2_rc1-r1[${MULTILIB_USEDEP}] )
2238 - ssh? ( >=net-libs/libssh-0.5.5[${MULTILIB_USEDEP}] )
2239 - truetype? ( >=media-libs/freetype-2.5.0.1:2[${MULTILIB_USEDEP}] )
2240 - vaapi? ( >=x11-libs/libva-1.2.1-r1[${MULTILIB_USEDEP}] )
2241 - vdpau? ( >=x11-libs/libvdpau-0.7[${MULTILIB_USEDEP}] )
2242 - vorbis? (
2243 - >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}]
2244 - >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}]
2245 - )
2246 - vpx? ( >=media-libs/libvpx-1.4.0:=[${MULTILIB_USEDEP}] )
2247 - X? (
2248 - >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}]
2249 - >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}]
2250 - >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}]
2251 - )
2252 - xcb? ( >=x11-libs/libxcb-1.4[${MULTILIB_USEDEP}] )
2253 - zeromq? ( >=net-libs/zeromq-4.1.6 )
2254 - zimg? ( >=media-libs/zimg-2.4:=[${MULTILIB_USEDEP}] )
2255 - zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
2256 - zvbi? ( >=media-libs/zvbi-0.2.35[${MULTILIB_USEDEP}] )
2257 - !media-video/qt-faststart
2258 - postproc? ( !media-libs/libpostproc )
2259 -"
2260 -
2261 -DEPEND="${RDEPEND}
2262 - >=sys-devel/make-3.81
2263 - doc? ( sys-apps/texinfo )
2264 - >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
2265 - ladspa? ( >=media-libs/ladspa-sdk-1.13-r2[${MULTILIB_USEDEP}] )
2266 - cpu_flags_x86_mmx? ( >=dev-lang/yasm-1.2 )
2267 - test? ( net-misc/wget sys-devel/bc )
2268 - v4l? ( sys-kernel/linux-headers )
2269 -"
2270 -
2271 -# Code requiring FFmpeg to be built under gpl license
2272 -GPL_REQUIRED_USE="
2273 - postproc? ( gpl )
2274 - frei0r? ( gpl )
2275 - cdio? ( gpl )
2276 - samba? ( gpl )
2277 - encode? (
2278 - x264? ( gpl )
2279 - x265? ( gpl )
2280 - xvid? ( gpl )
2281 - X? ( !xcb? ( gpl ) )
2282 - )
2283 -"
2284 -REQUIRED_USE="
2285 - libv4l? ( v4l )
2286 - fftools_cws2fws? ( zlib )
2287 - test? ( encode )
2288 - ${GPL_REQUIRED_USE}
2289 - ${CPU_REQUIRED_USE}"
2290 -RESTRICT="
2291 - gpl? ( openssl? ( bindist ) fdk? ( bindist ) )
2292 -"
2293 -
2294 -S=${WORKDIR}/${P/_/-}
2295 -
2296 -MULTILIB_WRAPPED_HEADERS=(
2297 - /usr/include/libavutil/avconfig.h
2298 -)
2299 -
2300 -PATCHES=(
2301 - "${FILESDIR}"/openjpeg22.patch
2302 - "${FILESDIR}"/openjpeg23.patch
2303 - "${FILESDIR}"/chromium.patch
2304 -)
2305 -
2306 -src_prepare() {
2307 - if [[ "${PV%_p*}" != "${PV}" ]] ; then # Snapshot
2308 - export revision=git-N-${FFMPEG_REVISION}
2309 - fi
2310 - default
2311 - echo 'include $(SRC_PATH)/ffbuild/libffmpeg.mak' >> Makefile || die
2312 -}
2313 -
2314 -multilib_src_configure() {
2315 - local myconf=( ${EXTRA_FFMPEG_CONF} )
2316 -
2317 - local ffuse=( "${FFMPEG_FLAG_MAP[@]}" )
2318 - use openssl && use gpl && myconf+=( --enable-nonfree )
2319 - use samba && myconf+=( --enable-version3 )
2320 -
2321 - # Encoders
2322 - if use encode ; then
2323 - ffuse+=( "${FFMPEG_ENCODER_FLAG_MAP[@]}" )
2324 -
2325 - # Licensing.
2326 - if use amrenc ; then
2327 - myconf+=( --enable-version3 )
2328 - fi
2329 - else
2330 - myconf+=( --disable-encoders )
2331 - fi
2332 -
2333 - # Indevs
2334 - use v4l || myconf+=( --disable-indev=v4l2 --disable-outdev=v4l2 )
2335 - for i in alsa oss jack ; do
2336 - use ${i} || myconf+=( --disable-indev=${i} )
2337 - done
2338 -
2339 - # Outdevs
2340 - for i in alsa oss sdl ; do
2341 - use ${i} || myconf+=( --disable-outdev=${i} )
2342 - done
2343 -
2344 - # Decoders
2345 - use amr && myconf+=( --enable-version3 )
2346 - use gmp && myconf+=( --enable-version3 )
2347 - use fdk && use gpl && myconf+=( --enable-nonfree )
2348 -
2349 - for i in "${ffuse[@]#+}" ; do
2350 - myconf+=( $(use_enable ${i%:*} ${i#*:}) )
2351 - done
2352 -
2353 - # (temporarily) disable non-multilib deps
2354 - if ! multilib_is_native_abi; then
2355 - for i in frei0r netcdf libzmq ; do
2356 - myconf+=( --disable-${i} )
2357 - done
2358 - fi
2359 -
2360 - # CPU features
2361 - for i in ${CPU_FEATURES_MAP} ; do
2362 - if [ "$(tc-arch)" = "${i%:*}" ] ; then
2363 - local var="${i#*:}_CPU_FEATURES[@]"
2364 - for j in ${!var} ; do
2365 - use ${j%:*} || myconf+=( --disable-${j#*:} )
2366 - done
2367 - fi
2368 - done
2369 -
2370 - if use pic ; then
2371 - myconf+=( --enable-pic )
2372 - # disable asm code if PIC is required
2373 - # as the provided asm decidedly is not PIC for x86.
2374 - [[ ${ABI} == x86 ]] && myconf+=( --disable-asm )
2375 - fi
2376 - [[ ${ABI} == x32 ]] && myconf+=( --disable-asm ) #427004
2377 -
2378 - # Try to get cpu type based on CFLAGS.
2379 - # Bug #172723
2380 - # We need to do this so that features of that CPU will be better used
2381 - # If they contain an unknown CPU it will not hurt since ffmpeg's configure
2382 - # will just ignore it.
2383 - for i in $(get-flag mcpu) $(get-flag march) ; do
2384 - [[ ${i} = native ]] && i="host" # bug #273421
2385 - myconf+=( --cpu=${i} )
2386 - break
2387 - done
2388 -
2389 - # LTO support, bug #566282
2390 - is-flagq "-flto*" && myconf+=( "--enable-lto" )
2391 -
2392 - # Mandatory configuration
2393 - myconf=(
2394 - --enable-avfilter
2395 - --enable-avresample
2396 - --disable-stripping
2397 - --disable-libcelt # bug #664158
2398 - "${myconf[@]}"
2399 - )
2400 -
2401 - # cross compile support
2402 - if tc-is-cross-compiler ; then
2403 - myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}- --host-cc="$(tc-getBUILD_CC)" )
2404 - case ${CHOST} in
2405 - *freebsd*)
2406 - myconf+=( --target-os=freebsd )
2407 - ;;
2408 - *mingw32*)
2409 - myconf+=( --target-os=mingw32 )
2410 - ;;
2411 - *linux*)
2412 - myconf+=( --target-os=linux )
2413 - ;;
2414 - esac
2415 - fi
2416 -
2417 - # doc
2418 - myconf+=(
2419 - $(multilib_native_use_enable doc)
2420 - $(multilib_native_use_enable doc htmlpages)
2421 - $(multilib_native_enable manpages)
2422 - )
2423 -
2424 - set -- "${S}/configure" \
2425 - --prefix="${EPREFIX}/usr" \
2426 - --libdir="${EPREFIX}/usr/$(get_libdir)" \
2427 - --shlibdir="${EPREFIX}/usr/$(get_libdir)" \
2428 - --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
2429 - --mandir="${EPREFIX}/usr/share/man" \
2430 - --enable-shared \
2431 - --cc="$(tc-getCC)" \
2432 - --cxx="$(tc-getCXX)" \
2433 - --ar="$(tc-getAR)" \
2434 - --optflags="${CFLAGS}" \
2435 - $(use_enable static-libs static) \
2436 - "${myconf[@]}"
2437 - echo "${@}"
2438 - "${@}" || die
2439 -
2440 - if multilib_is_native_abi && use chromium; then
2441 - einfo "Configuring for Chromium"
2442 - mkdir -p ../chromium || die
2443 - pushd ../chromium >/dev/null || die
2444 - set -- "${@}" \
2445 - --disable-shared \
2446 - --enable-static \
2447 - --enable-pic \
2448 - --extra-cflags="-DFF_API_CONVERGENCE_DURATION=0"
2449 - echo "${@}"
2450 - "${@}" || die
2451 - popd >/dev/null || die
2452 - fi
2453 -}
2454 -
2455 -multilib_src_compile() {
2456 - emake V=1
2457 -
2458 - if multilib_is_native_abi; then
2459 - for i in "${FFTOOLS[@]}" ; do
2460 - if use fftools_${i} ; then
2461 - emake V=1 tools/${i}$(get_exeext)
2462 - fi
2463 - done
2464 -
2465 - if use chromium; then
2466 - einfo "Compiling for Chromium"
2467 - pushd ../chromium >/dev/null || die
2468 - emake V=1 libffmpeg
2469 - popd >/dev/null || die
2470 - fi
2471 - fi
2472 -}
2473 -
2474 -multilib_src_install() {
2475 - emake V=1 DESTDIR="${D}" install install-doc
2476 -
2477 - if multilib_is_native_abi; then
2478 - for i in "${FFTOOLS[@]}" ; do
2479 - if use fftools_${i} ; then
2480 - dobin tools/${i}$(get_exeext)
2481 - fi
2482 - done
2483 -
2484 - if use chromium; then
2485 - einfo "Installing for Chromium"
2486 - pushd ../chromium >/dev/null || die
2487 - emake V=1 DESTDIR="${D}" install-libffmpeg
2488 - popd >/dev/null || die
2489 - fi
2490 - fi
2491 -}
2492 -
2493 -multilib_src_install_all() {
2494 - dodoc Changelog README.md CREDITS doc/*.txt doc/APIchanges
2495 - [ -f "RELEASE_NOTES" ] && dodoc "RELEASE_NOTES"
2496 -}
2497 -
2498 -multilib_src_test() {
2499 - LD_LIBRARY_PATH="${BUILD_DIR}/libpostproc:${BUILD_DIR}/libswscale:${BUILD_DIR}/libswresample:${BUILD_DIR}/libavcodec:${BUILD_DIR}/libavdevice:${BUILD_DIR}/libavfilter:${BUILD_DIR}/libavformat:${BUILD_DIR}/libavutil:${BUILD_DIR}/libavresample" \
2500 - emake V=1 fate
2501 -}
2502
2503 diff --git a/media-video/ffmpeg/files/ffmpeg32-openjpeg22.patch b/media-video/ffmpeg/files/ffmpeg32-openjpeg22.patch
2504 deleted file mode 100644
2505 index 0ee648641be..00000000000
2506 --- a/media-video/ffmpeg/files/ffmpeg32-openjpeg22.patch
2507 +++ /dev/null
2508 @@ -1,106 +0,0 @@
2509 -commit 078322f33ced4b2db6ac3e5002f98233d6fbf643
2510 -Author: Reino17 <rwijnsma@××××××.nl>
2511 -Date: Fri Jun 23 23:49:31 2017 +0200
2512 -
2513 - Add support for LibOpenJPEG v2.2/git
2514 -
2515 - Signed-off-by: Michael Bradshaw <mjbshaw@××××××.com>
2516 -
2517 -Index: ffmpeg-3.2.7/configure
2518 -===================================================================
2519 ---- ffmpeg-3.2.7.orig/configure
2520 -+++ ffmpeg-3.2.7/configure
2521 -@@ -1831,6 +1831,7 @@ HEADERS_LIST="
2522 - machine_ioctl_meteor_h
2523 - malloc_h
2524 - opencv2_core_core_c_h
2525 -+ openjpeg_2_2_openjpeg_h
2526 - openjpeg_2_1_openjpeg_h
2527 - openjpeg_2_0_openjpeg_h
2528 - openjpeg_1_5_openjpeg_h
2529 -@@ -5721,7 +5722,9 @@ enabled libopencv && { check_hea
2530 - require opencv opencv2/core/core_c.h cvCreateImageHeader -lopencv_core -lopencv_imgproc; } ||
2531 - require_pkg_config opencv opencv/cxcore.h cvCreateImageHeader; }
2532 - enabled libopenh264 && require_pkg_config openh264 wels/codec_api.h WelsGetCodecVersion
2533 --enabled libopenjpeg && { { check_lib2 openjpeg-2.1/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2534 -+enabled libopenjpeg && { { check_lib2 openjpeg-2.2/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2535 -+ check_lib2 openjpeg-2.2/openjpeg.h opj_version -lopenjp2 ||
2536 -+ { check_lib2 openjpeg-2.1/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2537 - check_lib2 openjpeg-2.1/openjpeg.h opj_version -lopenjp2 ||
2538 - { check_lib2 openjpeg-2.0/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2539 - { check_lib2 openjpeg-1.5/openjpeg.h opj_version -lopenjpeg -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2540 -Index: ffmpeg-3.2.7/libavcodec/libopenjpegdec.c
2541 -===================================================================
2542 ---- ffmpeg-3.2.7.orig/libavcodec/libopenjpegdec.c
2543 -+++ ffmpeg-3.2.7/libavcodec/libopenjpegdec.c
2544 -@@ -34,7 +34,9 @@
2545 - #include "internal.h"
2546 - #include "thread.h"
2547 -
2548 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2549 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H
2550 -+# include <openjpeg-2.2/openjpeg.h>
2551 -+#elif HAVE_OPENJPEG_2_1_OPENJPEG_H
2552 - # include <openjpeg-2.1/openjpeg.h>
2553 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2554 - # include <openjpeg-2.0/openjpeg.h>
2555 -@@ -44,7 +46,7 @@
2556 - # include <openjpeg.h>
2557 - #endif
2558 -
2559 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2560 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2561 - # define OPENJPEG_MAJOR_VERSION 2
2562 - # define OPJ(x) OPJ_##x
2563 - #else
2564 -@@ -429,7 +431,7 @@ static int libopenjpeg_decode_frame(AVCo
2565 - opj_stream_set_read_function(stream, stream_read);
2566 - opj_stream_set_skip_function(stream, stream_skip);
2567 - opj_stream_set_seek_function(stream, stream_seek);
2568 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2569 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2570 - opj_stream_set_user_data(stream, &reader, NULL);
2571 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2572 - opj_stream_set_user_data(stream, &reader);
2573 -Index: ffmpeg-3.2.7/libavcodec/libopenjpegenc.c
2574 -===================================================================
2575 ---- ffmpeg-3.2.7.orig/libavcodec/libopenjpegenc.c
2576 -+++ ffmpeg-3.2.7/libavcodec/libopenjpegenc.c
2577 -@@ -32,7 +32,9 @@
2578 - #include "avcodec.h"
2579 - #include "internal.h"
2580 -
2581 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2582 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H
2583 -+# include <openjpeg-2.2/openjpeg.h>
2584 -+#elif HAVE_OPENJPEG_2_1_OPENJPEG_H
2585 - # include <openjpeg-2.1/openjpeg.h>
2586 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2587 - # include <openjpeg-2.0/openjpeg.h>
2588 -@@ -42,7 +44,7 @@
2589 - # include <openjpeg.h>
2590 - #endif
2591 -
2592 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2593 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2594 - # define OPENJPEG_MAJOR_VERSION 2
2595 - # define OPJ(x) OPJ_##x
2596 - #else
2597 -@@ -306,7 +308,7 @@ static av_cold int libopenjpeg_encode_in
2598 -
2599 - opj_set_default_encoder_parameters(&ctx->enc_params);
2600 -
2601 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2602 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2603 - switch (ctx->cinema_mode) {
2604 - case OPJ_CINEMA2K_24:
2605 - ctx->enc_params.rsiz = OPJ_PROFILE_CINEMA_2K;
2606 -@@ -771,7 +773,7 @@ static int libopenjpeg_encode_frame(AVCo
2607 - opj_stream_set_write_function(stream, stream_write);
2608 - opj_stream_set_skip_function(stream, stream_skip);
2609 - opj_stream_set_seek_function(stream, stream_seek);
2610 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2611 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2612 - opj_stream_set_user_data(stream, &writer, NULL);
2613 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2614 - opj_stream_set_user_data(stream, &writer);
2615
2616 diff --git a/media-video/ffmpeg/files/openjpeg22.patch b/media-video/ffmpeg/files/openjpeg22.patch
2617 deleted file mode 100644
2618 index a458c15208a..00000000000
2619 --- a/media-video/ffmpeg/files/openjpeg22.patch
2620 +++ /dev/null
2621 @@ -1,106 +0,0 @@
2622 -commit 078322f33ced4b2db6ac3e5002f98233d6fbf643
2623 -Author: Reino17 <rwijnsma@××××××.nl>
2624 -Date: Fri Jun 23 23:49:31 2017 +0200
2625 -
2626 - Add support for LibOpenJPEG v2.2/git
2627 -
2628 - Signed-off-by: Michael Bradshaw <mjbshaw@××××××.com>
2629 -
2630 -Index: ffmpeg-3.3.3/configure
2631 -===================================================================
2632 ---- ffmpeg-3.3.3.orig/configure
2633 -+++ ffmpeg-3.3.3/configure
2634 -@@ -1875,6 +1875,7 @@ HEADERS_LIST="
2635 - machine_ioctl_meteor_h
2636 - malloc_h
2637 - opencv2_core_core_c_h
2638 -+ openjpeg_2_2_openjpeg_h
2639 - openjpeg_2_1_openjpeg_h
2640 - openjpeg_2_0_openjpeg_h
2641 - openjpeg_1_5_openjpeg_h
2642 -@@ -5805,7 +5806,9 @@ enabled libopencv && { check_hea
2643 - require opencv opencv2/core/core_c.h cvCreateImageHeader -lopencv_core -lopencv_imgproc; } ||
2644 - require_pkg_config opencv opencv/cxcore.h cvCreateImageHeader; }
2645 - enabled libopenh264 && require_pkg_config openh264 wels/codec_api.h WelsGetCodecVersion
2646 --enabled libopenjpeg && { { check_lib openjpeg-2.1/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2647 -+enabled libopenjpeg && { { check_lib openjpeg-2.2/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2648 -+ check_lib openjpeg-2.2/openjpeg.h opj_version -lopenjp2 ||
2649 -+ { check_lib openjpeg-2.1/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2650 - check_lib openjpeg-2.1/openjpeg.h opj_version -lopenjp2 ||
2651 - { check_lib openjpeg-2.0/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2652 - { check_lib openjpeg-1.5/openjpeg.h opj_version -lopenjpeg -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2653 -Index: ffmpeg-3.3.3/libavcodec/libopenjpegdec.c
2654 -===================================================================
2655 ---- ffmpeg-3.3.3.orig/libavcodec/libopenjpegdec.c
2656 -+++ ffmpeg-3.3.3/libavcodec/libopenjpegdec.c
2657 -@@ -34,7 +34,9 @@
2658 - #include "internal.h"
2659 - #include "thread.h"
2660 -
2661 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2662 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H
2663 -+# include <openjpeg-2.2/openjpeg.h>
2664 -+#elif HAVE_OPENJPEG_2_1_OPENJPEG_H
2665 - # include <openjpeg-2.1/openjpeg.h>
2666 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2667 - # include <openjpeg-2.0/openjpeg.h>
2668 -@@ -44,7 +46,7 @@
2669 - # include <openjpeg.h>
2670 - #endif
2671 -
2672 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2673 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2674 - # define OPENJPEG_MAJOR_VERSION 2
2675 - # define OPJ(x) OPJ_##x
2676 - #else
2677 -@@ -429,7 +431,7 @@ static int libopenjpeg_decode_frame(AVCo
2678 - opj_stream_set_read_function(stream, stream_read);
2679 - opj_stream_set_skip_function(stream, stream_skip);
2680 - opj_stream_set_seek_function(stream, stream_seek);
2681 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2682 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2683 - opj_stream_set_user_data(stream, &reader, NULL);
2684 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2685 - opj_stream_set_user_data(stream, &reader);
2686 -Index: ffmpeg-3.3.3/libavcodec/libopenjpegenc.c
2687 -===================================================================
2688 ---- ffmpeg-3.3.3.orig/libavcodec/libopenjpegenc.c
2689 -+++ ffmpeg-3.3.3/libavcodec/libopenjpegenc.c
2690 -@@ -32,7 +32,9 @@
2691 - #include "avcodec.h"
2692 - #include "internal.h"
2693 -
2694 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2695 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H
2696 -+# include <openjpeg-2.2/openjpeg.h>
2697 -+#elif HAVE_OPENJPEG_2_1_OPENJPEG_H
2698 - # include <openjpeg-2.1/openjpeg.h>
2699 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2700 - # include <openjpeg-2.0/openjpeg.h>
2701 -@@ -42,7 +44,7 @@
2702 - # include <openjpeg.h>
2703 - #endif
2704 -
2705 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2706 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2707 - # define OPENJPEG_MAJOR_VERSION 2
2708 - # define OPJ(x) OPJ_##x
2709 - #else
2710 -@@ -305,7 +307,7 @@ static av_cold int libopenjpeg_encode_in
2711 -
2712 - opj_set_default_encoder_parameters(&ctx->enc_params);
2713 -
2714 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2715 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2716 - switch (ctx->cinema_mode) {
2717 - case OPJ_CINEMA2K_24:
2718 - ctx->enc_params.rsiz = OPJ_PROFILE_CINEMA_2K;
2719 -@@ -769,7 +771,7 @@ static int libopenjpeg_encode_frame(AVCo
2720 - opj_stream_set_write_function(stream, stream_write);
2721 - opj_stream_set_skip_function(stream, stream_skip);
2722 - opj_stream_set_seek_function(stream, stream_seek);
2723 --#if HAVE_OPENJPEG_2_1_OPENJPEG_H
2724 -+#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2725 - opj_stream_set_user_data(stream, &writer, NULL);
2726 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2727 - opj_stream_set_user_data(stream, &writer);
2728
2729 diff --git a/media-video/ffmpeg/files/openjpeg23.patch b/media-video/ffmpeg/files/openjpeg23.patch
2730 deleted file mode 100644
2731 index 4398769a22c..00000000000
2732 --- a/media-video/ffmpeg/files/openjpeg23.patch
2733 +++ /dev/null
2734 @@ -1,109 +0,0 @@
2735 -From: Michael Bradshaw <mjbshaw at google.com>
2736 -
2737 -Signed-off-by: Michael Bradshaw <mjbshaw at google.com>
2738 ----
2739 - configure | 5 ++++-
2740 - libavcodec/libopenjpegdec.c | 8 +++++---
2741 - libavcodec/libopenjpegenc.c | 10 ++++++----
2742 - 3 files changed, 15 insertions(+), 8 deletions(-)
2743 -
2744 -diff --git a/configure b/configure
2745 -index 391c141e7a..77c9a18c3c 100755
2746 ---- a/configure
2747 -+++ b/configure
2748 -@@ -1930,6 +1930,7 @@ HEADERS_LIST="
2749 - machine_ioctl_meteor_h
2750 - malloc_h
2751 - opencv2_core_core_c_h
2752 -+ openjpeg_2_3_openjpeg_h
2753 - openjpeg_2_2_openjpeg_h
2754 - openjpeg_2_1_openjpeg_h
2755 - openjpeg_2_0_openjpeg_h
2756 -@@ -5950,7 +5951,9 @@ enabled libopencv && { check_header opencv2/core/core_c.h &&
2757 - require opencv opencv2/core/core_c.h cvCreateImageHeader -lopencv_core -lopencv_imgproc; } ||
2758 - require_pkg_config opencv opencv/cxcore.h cvCreateImageHeader; }
2759 - enabled libopenh264 && require_pkg_config openh264 wels/codec_api.h WelsGetCodecVersion
2760 --enabled libopenjpeg && { { check_lib openjpeg-2.2/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2761 -+enabled libopenjpeg && { { check_lib openjpeg-2.3/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2762 -+ check_lib openjpeg-2.3/openjpeg.h opj_version -lopenjp2 ||
2763 -+ { check_lib openjpeg-2.2/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2764 - check_lib openjpeg-2.2/openjpeg.h opj_version -lopenjp2 ||
2765 - { check_lib openjpeg-2.1/openjpeg.h opj_version -lopenjp2 -DOPJ_STATIC && add_cppflags -DOPJ_STATIC; } ||
2766 - check_lib openjpeg-2.1/openjpeg.h opj_version -lopenjp2 ||
2767 -diff --git a/libavcodec/libopenjpegdec.c b/libavcodec/libopenjpegdec.c
2768 -index 1210123265..67d47bd6a0 100644
2769 ---- a/libavcodec/libopenjpegdec.c
2770 -+++ b/libavcodec/libopenjpegdec.c
2771 -@@ -34,7 +34,9 @@
2772 - #include "internal.h"
2773 - #include "thread.h"
2774 -
2775 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H
2776 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H
2777 -+# include <openjpeg-2.3/openjpeg.h>
2778 -+#elif HAVE_OPENJPEG_2_2_OPENJPEG_H
2779 - # include <openjpeg-2.2/openjpeg.h>
2780 - #elif HAVE_OPENJPEG_2_1_OPENJPEG_H
2781 - # include <openjpeg-2.1/openjpeg.h>
2782 -@@ -46,7 +48,7 @@
2783 - # include <openjpeg.h>
2784 - #endif
2785 -
2786 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2787 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H || HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2788 - # define OPENJPEG_MAJOR_VERSION 2
2789 - # define OPJ(x) OPJ_##x
2790 - #else
2791 -@@ -431,7 +433,7 @@ static int libopenjpeg_decode_frame(AVCodecContext *avctx,
2792 - opj_stream_set_read_function(stream, stream_read);
2793 - opj_stream_set_skip_function(stream, stream_skip);
2794 - opj_stream_set_seek_function(stream, stream_seek);
2795 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2796 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H || HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2797 - opj_stream_set_user_data(stream, &reader, NULL);
2798 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2799 - opj_stream_set_user_data(stream, &reader);
2800 -diff --git a/libavcodec/libopenjpegenc.c b/libavcodec/libopenjpegenc.c
2801 -index b67e533d1d..92b4433b04 100644
2802 ---- a/libavcodec/libopenjpegenc.c
2803 -+++ b/libavcodec/libopenjpegenc.c
2804 -@@ -32,7 +32,9 @@
2805 - #include "avcodec.h"
2806 - #include "internal.h"
2807 -
2808 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H
2809 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H
2810 -+# include <openjpeg-2.3/openjpeg.h>
2811 -+#elif HAVE_OPENJPEG_2_2_OPENJPEG_H
2812 - # include <openjpeg-2.2/openjpeg.h>
2813 - #elif HAVE_OPENJPEG_2_1_OPENJPEG_H
2814 - # include <openjpeg-2.1/openjpeg.h>
2815 -@@ -44,7 +46,7 @@
2816 - # include <openjpeg.h>
2817 - #endif
2818 -
2819 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2820 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H || HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H || HAVE_OPENJPEG_2_0_OPENJPEG_H
2821 - # define OPENJPEG_MAJOR_VERSION 2
2822 - # define OPJ(x) OPJ_##x
2823 - #else
2824 -@@ -307,7 +309,7 @@ static av_cold int libopenjpeg_encode_init(AVCodecContext *avctx)
2825 -
2826 - opj_set_default_encoder_parameters(&ctx->enc_params);
2827 -
2828 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2829 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H || HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2830 - switch (ctx->cinema_mode) {
2831 - case OPJ_CINEMA2K_24:
2832 - ctx->enc_params.rsiz = OPJ_PROFILE_CINEMA_2K;
2833 -@@ -771,7 +773,7 @@ static int libopenjpeg_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
2834 - opj_stream_set_write_function(stream, stream_write);
2835 - opj_stream_set_skip_function(stream, stream_skip);
2836 - opj_stream_set_seek_function(stream, stream_seek);
2837 --#if HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2838 -+#if HAVE_OPENJPEG_2_3_OPENJPEG_H || HAVE_OPENJPEG_2_2_OPENJPEG_H || HAVE_OPENJPEG_2_1_OPENJPEG_H
2839 - opj_stream_set_user_data(stream, &writer, NULL);
2840 - #elif HAVE_OPENJPEG_2_0_OPENJPEG_H
2841 - opj_stream_set_user_data(stream, &writer);
2842 ---
2843 -2.13.5 (Apple Git-94)
2844
2845 diff --git a/media-video/ffmpeg/metadata.xml b/media-video/ffmpeg/metadata.xml
2846 index e5686d5da12..183c78718dc 100644
2847 --- a/media-video/ffmpeg/metadata.xml
2848 +++ b/media-video/ffmpeg/metadata.xml
2849 @@ -8,10 +8,6 @@
2850 <flag name="amr">Enables Adaptive Multi-Rate Audio support</flag>
2851 <flag name="amrenc">Enables Adaptive Multi-Rate Audio encoding support with <pkg>media-libs/vo-amrwbenc</pkg>.</flag>
2852 <flag name="appkit">Enables Apple AppKit framework</flag>
2853 - <flag name="armv5te">Enables optimizations for armv5te processors.</flag>
2854 - <flag name="armv6">Enables optimizations for armv6 processors.</flag>
2855 - <flag name="armv6t2">Enables optimizations for armv6t2 processors.</flag>
2856 - <flag name="armvfp">Enables VFP optimizations for ARM processors.</flag>
2857 <flag name="bluray">Enable playback of Blu-ray filesystems</flag>
2858 <flag name="bs2b">Enables <pkg>media-libs/libbs2b</pkg> based Bauer stereo-to-binaural filter.</flag>
2859 <flag name="cdio">Enables audio CD grabbing with <pkg>dev-libs/libcdio</pkg>.</flag>
2860 @@ -21,7 +17,6 @@
2861 <flag name="cpudetection">Enables runtime CPU detection (useful for bindist, compatibility on other CPUs)</flag>
2862 <flag name="cuda">Enables CUDA-based acceleration. Mostly used for specific filters.</flag>
2863 <flag name="dav1d">Enables AV1 decoding via <pkg>media-libs/dav1d</pkg>.</flag>
2864 - <flag name="ebur128">Enables EBU R128 loudness normalization filter via <pkg>media-libs/libebur128</pkg></flag>
2865 <flag name="fdk">Use external fdk-aac library for AAC encoding</flag>
2866 <flag name="flite">Adds a text-to-speech filter based on <pkg>app-accessibility/flite</pkg>.</flag>
2867 <flag name="frei0r">Enable frei0r wrapping in libavfilter</flag>
2868 @@ -54,7 +49,6 @@
2869 <flag name="postproc">Build and install libpostproc.</flag>
2870 <flag name="rubberband">Adds time-stretching and pitch-shifting audio filter based on <pkg>media-libs/rubberband</pkg>.</flag>
2871 <flag name="snappy">Enable <pkg>app-arch/snappy</pkg> support. Required for e.g. Vidvox Hap encoder.</flag>
2872 - <flag name="sofalizer">Enables Sofalizer filter</flag>
2873 <flag name="srt">Enable support for Secure Reliable Transport (SRT) via <pkg>net-libs/srt</pkg></flag>
2874 <flag name="ssh">Enable SSH/sftp support via <pkg>net-libs/libssh</pkg>.</flag>
2875 <flag name="twolame">Enables MP2 encoding via <pkg>media-sound/twolame</pkg> as an alternative to the internal encoder.</flag>