diff options
Diffstat (limited to 'media-video')
-rw-r--r-- | media-video/ffmpeg/ChangeLog | 7 | ||||
-rw-r--r-- | media-video/ffmpeg/Manifest | 10 | ||||
-rw-r--r-- | media-video/ffmpeg/ffmpeg-2.5.ebuild | 379 |
3 files changed, 391 insertions, 5 deletions
diff --git a/media-video/ffmpeg/ChangeLog b/media-video/ffmpeg/ChangeLog index 891f9d3a2008..37015a3c8c05 100644 --- a/media-video/ffmpeg/ChangeLog +++ b/media-video/ffmpeg/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for media-video/ffmpeg # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/ffmpeg/ChangeLog,v 1.810 2014/12/02 09:01:14 aballier Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-video/ffmpeg/ChangeLog,v 1.811 2014/12/04 09:03:51 aballier Exp $ + +*ffmpeg-2.5 (04 Dec 2014) + + 04 Dec 2014; Alexis Ballier <aballier@gentoo.org> +ffmpeg-2.5.ebuild: + version bump *ffmpeg-2.4.4 (02 Dec 2014) diff --git a/media-video/ffmpeg/Manifest b/media-video/ffmpeg/Manifest index bc0359c1524c..8f8305a08945 100644 --- a/media-video/ffmpeg/Manifest +++ b/media-video/ffmpeg/Manifest @@ -14,6 +14,7 @@ DIST ffmpeg-1.2.9.tar.bz2 5973148 SHA256 5cdd912e13c8fe302937db811f63616193a0465 DIST ffmpeg-2.2.10.tar.bz2 7033420 SHA256 157b405f5c1077175326e6e5ae2e10e04a940a6110e744adc9add372651ca891 SHA512 6118b055c2fb9ce24ccfc3c76e62d16e309c35379d31965cd427de204bd31769d34beb2cd1dec7d704c8b25c7a3850ae253f1ed9bb34fb58a58505747b1e8feb WHIRLPOOL ba89e55d17704246225b0f276926e265889912ad80b309e499148dc041d623e63f8d26e347a798946b2e5cb36e54d9196916363c84e28df8ad590af6e1330c7b DIST ffmpeg-2.4.3.tar.bz2 7369986 SHA256 ca5c3e3c0e4f9e43b9dceafceb866acb1ea575cb9f2d94e0d959303e4fc4e602 SHA512 4e954bfdd683a4aec9773cc8404114ce7989ea311bce5b244a8478a7cbc59dafac622962ed80203ba5b4dff3721fb459d7cedb7c74c6c6093cf9d998e32e4540 WHIRLPOOL 41233ccfa22d09cbdfc53bfeba54acf4c2363e2e6de9ff0b034698f8e1ace1ffeabc6f8d579e00ec39fdd4fd2f68aec2f1f1f6773f2f91efb74ee39f8d22f59a DIST ffmpeg-2.4.4.tar.bz2 7369780 SHA256 9ad041c0201fb8b2605c5c5c0259c373c793c32cfc96f7315fca67e900494afc SHA512 18e4f020339e6c01388e663c5e66537de02df5fc935677481b14f9017810fa3734a3c5e0b0bf324ac4282212f391cb82b4c7d14dbfe9c9bb93ceb7d337fa7f11 WHIRLPOOL 69ededdb43e4adc65587c7a0c958d5d4a03e5599c4d16c1ff864b130962c1a94112f37d31e2fccd64db81213cc7a456d8484473c565f54249704f4acdb7ad9e6 +DIST ffmpeg-2.5.tar.bz2 7673841 SHA256 148cfd694b60245f9116f5932f3f60bb6dba47bcfef395cdda7a7d8ed48d57ac SHA512 4b1a1896b5b56fb675d774ac86f118d7b0c3eabe46baee9e45913af0330553feb3241bec98d6be55a6b667961a2ad84f3c3b1c8547b7365e8450454a48cc4e88 WHIRLPOOL 2403f73308f28e48c6318f09d2afe7dcc0c7ff2d7f93ac73701c5078234ab96d3a98907bf645d445d4454ad8ed308ea713d961c4fc351b63a9855cb5ba1f7d3e EBUILD ffmpeg-0.10.15.ebuild 9938 SHA256 d4c3b812f56c3c610c42709836c2263912b4118c86b1953289ba44493c5b511b SHA512 b04f03badab825c227af90d7986bb6b46b7b8b4ed20ef6de04d8429cf630ba96d36981b951c13443b48c6ff49a4e21f1d8c17108ce7862d2a41ce80386d42dc5 WHIRLPOOL 7188c3419031aa6a74cec9549a2dde10a88bc7c224160fc68121dc8b82e4b8fee14dfd065676274f9ec194251a092545dab2fd7d9c16a22e0dde9f8ecece8d2d EBUILD ffmpeg-1.0.10.ebuild 9661 SHA256 8e268c28be34d501171171af761494f37a26a8fe84293e9b8a05cf8bfd56ac76 SHA512 79781c15c09bff885f6f193e361bf8f929eca66903575fdfdb1188afc5d69c3bb6d0bd232d5eced7f4ac4a9c2f3aaff59a4164024e38bbd7f4c0a2c4a074c008 WHIRLPOOL 84e24bfc65736aa714a5506c9e8b1fa9e6ddc91e0c06e991e4598cdf1b85c1da68317fded1374fbfa6076f7a81c0da0cded87d7e3e9f2a1427d5218a59482fcf EBUILD ffmpeg-1.2.10.ebuild 10930 SHA256 282edf36621931548f7e9354f09ed9976a56a9715cb65120d1b99294d6e777fc SHA512 9b1aedcfc720c26e6677625996b2dfcb70b5a7c01b7b675ddc9ec82b615e3f7934710f194824c871d3b7626368e5320c3a8961c383bc97daa01722d92759a1e1 WHIRLPOOL 8152357f7f953b3036d1c1c3cb376198b7c7bab1ac9c78016c43666f54141c4b51f22d4b3a85e28c5c88f94b32a02c15775f12d67adf43de32a2cf9babd92e9e @@ -22,13 +23,14 @@ EBUILD ffmpeg-1.2.9.ebuild 10929 SHA256 7f8efcf95b404dc68d6e1ca867d2a751d159c6eb EBUILD ffmpeg-2.2.10.ebuild 12608 SHA256 85c51534b63cf37f4515b341f4008d5966207ba2d0300828b08958e6ddd92fe2 SHA512 0833b848dcbab24e57a439c5177baa30c997eb91fd7f88d5ae16d3aef9785d1407a5360aa0e2ff70130812434071154ab1916e672a903bd75558f88e25a8550e WHIRLPOOL 3fb135cb5f92a7158bf969e63d8dbc8f7fdb685317a6920e11100adc370979a10d7e9c4cdafe4bae8862719c514edce53f1fcd0ce71cfc90137916f91730faba EBUILD ffmpeg-2.4.3.ebuild 12981 SHA256 52cda2b043ae1f91dea6807219e31618d1bb273b7efc7e6a7039b166926dca5f SHA512 ad6332923a6bf4aa5da93f9a2105febcbba44fe5f299d84dc486369e42291e6ec13808d58e42a1c1f94afa49060e5999b2d84a8098e7cd6aec9595811767edc9 WHIRLPOOL 16168726ff1ee37e084ef899bd360d3903081eaad9a8e6bfad837defd846cd93ef99d152e3d7aaa5b0b01ebac838edc3d5e01ae89273ad1b4782a15a991f623b EBUILD ffmpeg-2.4.4.ebuild 12981 SHA256 35c9f6a0ca3d367a611e561d94e3a4b9f755ea1a19e1812433c6f5615d6858e6 SHA512 da97aa8e9c5d510f12d48693030b983756573a5bc62ae15b8aeecf7893bd4c9f9b34998424361ecb1464ca9b4380fd25dfac14c9b31d6aeb0890703d8f9efac2 WHIRLPOOL ab1b76150e2fc7df48238ab90e88832c160a2af079dfa9050769c4fc0a6738be7f3b49d22546d9a8fc3306f886f9e27bbce5c38311e170f84eea7d3fd8856edf +EBUILD ffmpeg-2.5.ebuild 13073 SHA256 d37f21c1b07df3addfc457689c61f79d3412a80dfb2d9f0c5b0fcac1e2bc8dba SHA512 c200db458b490801db1063e53cfc42a133bdac3977b2af807a6806fa0033a7b2db01878c3b8c0395b8aaafdef3614a0f2d5266c8bc87e2370be7cdaa1812323c WHIRLPOOL 785e184cad5a7ff910a6772462df3a21ba09d0e80b6c0727940aa3ef276260ac41b2f3d0de967fe8a3931a0c60acab09b4c84bf3bd7019060cc3ee0da0b5e5ca EBUILD ffmpeg-9999.ebuild 13076 SHA256 bac15fc30d7fc2f4a2a4db916c61466aaa26da128fd88bd99155040928551899 SHA512 f0b9b7b8d6d3bc0990a0a85e0219f98af176b5dd87e1f98981f6a337e821aa0d9657e836b296bdd51b4febfd7d3dc04bb2f7cf32a3c1024eb21fba71e9927048 WHIRLPOOL b51c96f1ebb6fd2b87e9494d5e6023decb3c875024ef836974b83a6cf76fc65a2601b596f5a67ed3aa098836dd862d548db02a48e928fae7c9ed6f66ccef7f99 -MISC ChangeLog 112155 SHA256 3ce04a87ae130eb004c26f30e8333273e081fd173d943ecb3ea71004035496fb SHA512 ab2c40387155639f3abae8f8d7eafa4e962a5882906df39372ac8df996b9b45840fe3b0d422419666a9c401ccf90cb378e77110d1b9590df2214fe3d8e09c4eb WHIRLPOOL f034725d94061c2b34710da8becb5dea069afeef2222dd3370041e2ddccab40c88bab287e14eb349e02132d81f22d2889b6198a3f999cdff7707b977e61e12d0 +MISC ChangeLog 112270 SHA256 8a0cc83847cc696bd7b7c707627694b30b7dcfa528ea52c9d642f8a3d6fd8714 SHA512 6f97864da4536165fbedd408263eb94f0537600c007d0880abb0acb4f143e7a666f24453a57824f3d7c1032984d7496cbf63bab662070449b20980ed229ef648 WHIRLPOOL 068e4ea19f3ac4bad86540df2be041eb917073204e6512c7ac7bd9ebae5327a2ee0c31454ff393e3ceff75369b5ddd381fbb9aba4f7aae71062b4b562eba2f30 MISC metadata.xml 5647 SHA256 359e839a7d9c3c36825bfae0e9217688785d279cebbfc440bd4074f5bc58fb9c SHA512 3efe9374ca61952911a6593417494092d9fd5465745a63e427dc74cbd6aa4af46277ec4865603daf5b27163c8db97823ff2b4eb857e88d73f3278e63a949e372 WHIRLPOOL fc5873ea67edea764b6ffff08862ad850a4bef83daed4a1ac03fc2cd9cfb8cb587561ce8fdee39a79fd6686b4605bebaaa0c00dac6a858e5d6f5ac563751ea20 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 -iEYEAREIAAYFAlR9f9wACgkQvFcC4BYPU0pRigCgx9e4Nvm/e0lUuPjcY4Z+l3bP -IQ0AoIcEvuRPdit00Zqoy2oInyExFtJc -=qs8g +iEYEAREIAAYFAlSAI3kACgkQvFcC4BYPU0oQiwCgjdeHXYNe7/UTHPATN5Z++O/p +qogAoMGivPutJrlSeEH2zwf38qHepQTR +=EDKz -----END PGP SIGNATURE----- diff --git a/media-video/ffmpeg/ffmpeg-2.5.ebuild b/media-video/ffmpeg/ffmpeg-2.5.ebuild new file mode 100644 index 000000000000..9dcd41254d64 --- /dev/null +++ b/media-video/ffmpeg/ffmpeg-2.5.ebuild @@ -0,0 +1,379 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-video/ffmpeg/ffmpeg-2.5.ebuild,v 1.1 2014/12/04 09:03:51 aballier Exp $ + +EAPI="5" + +# Subslot: libavutil major.libavcodec major.libavformat major +# Since FFmpeg ships several libraries, subslot is kind of limited here. +# Most consumers will use those three libraries, if a "less used" library +# changes its soname, consumers will have to be rebuilt the old way +# (preserve-libs). +# If, for example, a package does not link to libavformat and only libavformat +# changes its ABI then this package will be rebuilt needlessly. Hence, such a +# package is free _not_ to := depend on FFmpeg but I would strongly encourage +# doing so since such a case is unlikely. +FFMPEG_SUBSLOT=54.56.56 + +SCM="" +if [ "${PV#9999}" != "${PV}" ] ; then + SCM="git-2" + EGIT_REPO_URI="git://source.ffmpeg.org/ffmpeg.git" +fi + +inherit eutils flag-o-matic multilib multilib-minimal toolchain-funcs ${SCM} + +DESCRIPTION="Complete solution to record, convert and stream audio and video. Includes libavcodec" +HOMEPAGE="http://ffmpeg.org/" +if [ "${PV#9999}" != "${PV}" ] ; then + SRC_URI="" +elif [ "${PV%_p*}" != "${PV}" ] ; then # Snapshot + SRC_URI="mirror://gentoo/${P}.tar.bz2" +else # Release + SRC_URI="http://ffmpeg.org/releases/${P/_/-}.tar.bz2" +fi +FFMPEG_REVISION="${PV#*_p}" + +LICENSE="GPL-2 amr? ( GPL-3 ) encode? ( aac? ( GPL-3 ) ) samba? ( GPL-3 )" +SLOT="0/${FFMPEG_SUBSLOT}" +if [ "${PV#9999}" = "${PV}" ] ; then + KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux" +fi +IUSE=" + aac aacplus alsa amr amrenc bindist bluray bs2b +bzip2 cdio celt + cpudetection debug doc +encode examples faac fdk flite fontconfig frei0r + fribidi gme gnutls gsm +hardcoded-tables +iconv iec61883 ieee1394 jack + jpeg2k ladspa libass libcaca libsoxr libv4l lzma modplug mp3 +network + openal opengl openssl opus oss pic pulseaudio quvi rtmp samba schroedinger + sdl speex ssh static-libs test theora threads truetype twolame v4l vaapi + vdpau vorbis vpx wavpack webp X x264 x265 xcb xvid +zlib zvbi + " + +ARM_CPU_FEATURES="armv5te armv6 armv6t2 neon armvfp:vfp" +MIPS_CPU_FEATURES="mips32r2 mipsdspr1 mipsdspr2 mipsfpu" +PPC_CPU_FEATURES="altivec" +X86_CPU_FEATURES="3dnow:amd3dnow 3dnowext:amd3dnowext avx avx2 fma3 fma4 mmx mmxext sse sse2 sse3 ssse3 sse4 sse4_2:sse42 xop" + +# String for CPU features in the useflag[:configure_option] form +# if :configure_option isn't set, it will use 'useflag' as configure option +CPU_FEATURES=" + ${ARM_CPU_FEATURES} + ${MIPS_CPU_FEATURES} + ${PPC_CPU_FEATURES} + ${X86_CPU_FEATURES} +" + +for i in ${CPU_FEATURES}; do + IUSE="${IUSE} ${i%:*}" +done + +FFTOOLS="aviocat cws2fws ffescape ffeval ffhash fourcc2pixfmt graph2dot ismindex pktdumper qt-faststart trasher" + +for i in ${FFTOOLS}; do + IUSE="${IUSE} +fftools_$i" +done + +RDEPEND=" + alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] ) + amr? ( >=media-libs/opencore-amr-0.1.3-r1[${MULTILIB_USEDEP}] ) + bluray? ( >=media-libs/libbluray-0.3.0-r1[${MULTILIB_USEDEP}] ) + bs2b? ( >=media-libs/libbs2b-3.1.0-r1[${MULTILIB_USEDEP}] ) + bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] ) + cdio? ( >=dev-libs/libcdio-paranoia-0.90_p1-r1[${MULTILIB_USEDEP}] ) + celt? ( >=media-libs/celt-0.11.1-r1[${MULTILIB_USEDEP}] ) + encode? ( + aac? ( >=media-libs/vo-aacenc-0.1.3[${MULTILIB_USEDEP}] ) + aacplus? ( >=media-libs/libaacplus-2.0.2-r1[${MULTILIB_USEDEP}] ) + amrenc? ( >=media-libs/vo-amrwbenc-0.1.2-r1[${MULTILIB_USEDEP}] ) + faac? ( >=media-libs/faac-1.28-r3[${MULTILIB_USEDEP}] ) + mp3? ( >=media-sound/lame-3.99.5-r1[${MULTILIB_USEDEP}] ) + theora? ( + >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}] + >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}] + ) + twolame? ( >=media-sound/twolame-0.3.13-r1[${MULTILIB_USEDEP}] ) + wavpack? ( >=media-sound/wavpack-4.60.1-r1[${MULTILIB_USEDEP}] ) + webp? ( >=media-libs/libwebp-0.3.0[${MULTILIB_USEDEP}] ) + x264? ( >=media-libs/x264-0.0.20130506:=[${MULTILIB_USEDEP}] ) + x265? ( >=media-libs/x265-1.2:=[${MULTILIB_USEDEP}] ) + xvid? ( >=media-libs/xvid-1.3.2-r1[${MULTILIB_USEDEP}] ) + ) + fdk? ( >=media-libs/fdk-aac-0.1.3[${MULTILIB_USEDEP}] ) + flite? ( >=app-accessibility/flite-1.4-r4[${MULTILIB_USEDEP}] ) + fontconfig? ( >=media-libs/fontconfig-2.10.92[${MULTILIB_USEDEP}] ) + frei0r? ( media-plugins/frei0r-plugins ) + fribidi? ( >=dev-libs/fribidi-0.19.6[${MULTILIB_USEDEP}] ) + gme? ( >=media-libs/game-music-emu-0.6.0[${MULTILIB_USEDEP}] ) + gnutls? ( >=net-libs/gnutls-2.12.23-r6[${MULTILIB_USEDEP}] ) + gsm? ( >=media-sound/gsm-1.0.13-r1[${MULTILIB_USEDEP}] ) + iconv? ( >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] ) + iec61883? ( + >=media-libs/libiec61883-1.2.0-r1[${MULTILIB_USEDEP}] + >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}] + >=sys-libs/libavc1394-0.5.4-r1[${MULTILIB_USEDEP}] + ) + ieee1394? ( + >=media-libs/libdc1394-2.2.1[${MULTILIB_USEDEP}] + >=sys-libs/libraw1394-2.1.0-r1[${MULTILIB_USEDEP}] + ) + jack? ( >=media-sound/jack-audio-connection-kit-0.121.3-r1[${MULTILIB_USEDEP}] ) + jpeg2k? ( >=media-libs/openjpeg-1.5.0:0[${MULTILIB_USEDEP}] ) + libass? ( >=media-libs/libass-0.10.2[${MULTILIB_USEDEP}] ) + libcaca? ( >=media-libs/libcaca-0.99_beta18-r1[${MULTILIB_USEDEP}] ) + libsoxr? ( >=media-libs/soxr-0.1.0[${MULTILIB_USEDEP}] ) + libv4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] ) + lzma? ( >=app-arch/xz-utils-5.0.5-r1[${MULTILIB_USEDEP}] ) + modplug? ( >=media-libs/libmodplug-0.8.8.4-r1[${MULTILIB_USEDEP}] ) + openal? ( >=media-libs/openal-1.15.1[${MULTILIB_USEDEP}] ) + opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] ) + openssl? ( >=dev-libs/openssl-1.0.1h-r2[${MULTILIB_USEDEP}] ) + opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] ) + pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] ) + quvi? ( media-libs/libquvi:0.4[${MULTILIB_USEDEP}] ) + rtmp? ( >=media-video/rtmpdump-2.4_p20131018[${MULTILIB_USEDEP}] ) + samba? ( >=net-fs/samba-3.6.23-r1[${MULTILIB_USEDEP}] ) + schroedinger? ( >=media-libs/schroedinger-1.0.11-r1[${MULTILIB_USEDEP}] ) + sdl? ( >=media-libs/libsdl-1.2.15-r4[sound,video,${MULTILIB_USEDEP}] ) + speex? ( >=media-libs/speex-1.2_rc1-r1[${MULTILIB_USEDEP}] ) + ssh? ( >=net-libs/libssh-0.5.5[${MULTILIB_USEDEP}] ) + truetype? ( >=media-libs/freetype-2.5.0.1:2[${MULTILIB_USEDEP}] ) + vaapi? ( >=x11-libs/libva-1.2.1-r1[${MULTILIB_USEDEP}] ) + vdpau? ( >=x11-libs/libvdpau-0.7[${MULTILIB_USEDEP}] ) + vorbis? ( + >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}] + >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}] + ) + vpx? ( >=media-libs/libvpx-1.2.0_pre20130625[${MULTILIB_USEDEP}] ) + X? ( + >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}] + >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}] + >=x11-libs/libXfixes-5.0.1[${MULTILIB_USEDEP}] + >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}] + ) + xcb? ( x11-libs/libxcb[${MULTILIB_USEDEP}] ) + zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] ) + zvbi? ( >=media-libs/zvbi-0.2.35[${MULTILIB_USEDEP}] ) + !media-video/qt-faststart + !media-libs/libpostproc +" + +DEPEND="${RDEPEND} + >=sys-devel/make-3.81 + doc? ( app-text/texi2html ) + fontconfig? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + gnutls? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + ieee1394? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + ladspa? ( >=media-libs/ladspa-sdk-1.13-r2[${MULTILIB_USEDEP}] ) + libv4l? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + mmx? ( >=dev-lang/yasm-1.2 ) + rtmp? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + schroedinger? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + test? ( net-misc/wget sys-devel/bc ) + truetype? ( >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}] ) + v4l? ( sys-kernel/linux-headers ) +" + +RDEPEND="${RDEPEND} + abi_x86_32? ( !<=app-emulation/emul-linux-x86-medialibs-20140508-r3 + !app-emulation/emul-linux-x86-medialibs[-abi_x86_32(-)] )" + +# faac is license-incompatible with ffmpeg +REQUIRED_USE="bindist? ( encode? ( !faac !aacplus ) !openssl ) + libv4l? ( v4l ) + fftools_cws2fws? ( zlib ) + test? ( encode )" + +S=${WORKDIR}/${P/_/-} + +MULTILIB_WRAPPED_HEADERS=( + /usr/include/libavutil/avconfig.h +) + +src_prepare() { + if [[ "${PV%_p*}" != "${PV}" ]] ; then # Snapshot + export revision=git-N-${FFMPEG_REVISION} + fi + epatch_user +} + +multilib_src_configure() { + local myconf=( ${EXTRA_FFMPEG_CONF} ) + + # options to use as use_enable in the foo[:bar] form. + # This will feed configure with $(use_enable foo bar) + # or $(use_enable foo foo) if no :bar is set. + local ffuse=( + bzip2:bzlib cpudetection:runtime-cpudetect debug doc + gnutls hardcoded-tables iconv lzma network openssl samba:libsmbclient + sdl:ffplay vaapi vdpau X:xlib xcb:libxcb xcb:libxcb-shm xcb:libxcb-xfixes zlib + ) + use openssl && myconf+=( --enable-nonfree ) + use samba && myconf+=( --enable-version3 ) + + # Encoders + if use encode + then + ffuse+=( aac:libvo-aacenc amrenc:libvo-amrwbenc mp3:libmp3lame ) + for i in aacplus faac theora twolame wavpack webp x264 x265 xvid; do + ffuse+=( ${i}:lib${i} ) + done + + # Licensing. + if use aac || use amrenc ; then + myconf+=( --enable-version3 ) + fi + if use aacplus || use faac ; then + myconf+=( --enable-nonfree ) + fi + else + myconf+=( --disable-encoders ) + fi + + # libavdevice options + ffuse+=( cdio:libcdio iec61883:libiec61883 ieee1394:libdc1394 libcaca openal opengl ) + + # Indevs + use v4l || myconf+=( --disable-indev=v4l2 --disable-outdev=v4l2 ) + for i in alsa oss jack ; do + use ${i} || myconf+=( --disable-indev=${i} ) + done + ffuse+=( libv4l:libv4l2 pulseaudio:libpulse X:x11grab ) + + # Outdevs + for i in alsa oss sdl ; do + use ${i} || myconf+=( --disable-outdev=${i} ) + done + + # libavfilter options + ffuse+=( bs2b:libbs2b flite:libflite frei0r fribidi:libfribidi fontconfig ladspa libass truetype:libfreetype ) + + # libswresample options + ffuse+=( libsoxr ) + + # Threads; we only support pthread for now but ffmpeg supports more + ffuse+=( threads:pthreads ) + + # Decoders + ffuse+=( amr:libopencore-amrwb amr:libopencore-amrnb fdk:libfdk-aac jpeg2k:libopenjpeg ) + use amr && myconf+=( --enable-version3 ) + for i in bluray celt gme gsm modplug opus quvi rtmp ssh schroedinger speex vorbis vpx zvbi; do + ffuse+=( ${i}:lib${i} ) + done + use fdk && myconf+=( --enable-nonfree ) + + for i in "${ffuse[@]}" ; do + myconf+=( $(use_enable ${i%:*} ${i#*:}) ) + done + + # (temporarily) disable non-multilib deps + if ! multilib_is_native_abi; then + for i in frei0r ; do + myconf+=( --disable-${i} ) + done + fi + + # CPU features + for i in ${CPU_FEATURES}; do + use ${i%:*} || myconf+=( --disable-${i#*:} ) + done + if use pic ; then + myconf+=( --enable-pic ) + # disable asm code if PIC is required + # as the provided asm decidedly is not PIC for x86. + [[ ${ABI} == x86 ]] && myconf+=( --disable-asm ) + fi + [[ ${ABI} == x32 ]] && myconf+=( --disable-asm ) #427004 + + # Try to get cpu type based on CFLAGS. + # Bug #172723 + # We need to do this so that features of that CPU will be better used + # If they contain an unknown CPU it will not hurt since ffmpeg's configure + # will just ignore it. + for i in $(get-flag mcpu) $(get-flag mtune) $(get-flag march) ; do + [[ ${i} = native ]] && i="host" # bug #273421 + myconf+=( --cpu=${i} ) + break + done + + # Mandatory configuration + myconf=( + --enable-gpl + --enable-postproc + --enable-avfilter + --enable-avresample + --disable-stripping + "${myconf[@]}" + ) + + # cross compile support + if tc-is-cross-compiler ; then + myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}- ) + case ${CHOST} in + *freebsd*) + myconf+=( --target-os=freebsd ) + ;; + mingw32*) + myconf+=( --target-os=mingw32 ) + ;; + *linux*) + myconf+=( --target-os=linux ) + ;; + esac + fi + + set -- "${S}/configure" \ + --prefix="${EPREFIX}/usr" \ + --libdir="${EPREFIX}/usr/$(get_libdir)" \ + --shlibdir="${EPREFIX}/usr/$(get_libdir)" \ + --mandir="${EPREFIX}/usr/share/man" \ + --enable-shared \ + --cc="$(tc-getCC)" \ + --cxx="$(tc-getCXX)" \ + --ar="$(tc-getAR)" \ + --optflags="${CFLAGS}" \ + --extra-cflags="${CFLAGS}" \ + --extra-cxxflags="${CXXFLAGS}" \ + $(use_enable static-libs static) \ + "${myconf[@]}" + echo "${@}" + "${@}" || die +} + +multilib_src_compile() { + emake V=1 + + if multilib_is_native_abi; then + for i in ${FFTOOLS} ; do + if use fftools_${i} ; then + emake V=1 tools/${i} + fi + done + fi +} + +multilib_src_install() { + emake V=1 DESTDIR="${D}" install install-man + + if multilib_is_native_abi; then + for i in ${FFTOOLS} ; do + if use fftools_${i} ; then + dobin tools/${i} + fi + done + fi +} + +multilib_src_install_all() { + dodoc Changelog README.md CREDITS doc/*.txt doc/APIchanges + [ -f "RELEASE_NOTES" ] && dodoc "RELEASE_NOTES" + use doc && dohtml -r doc/* + if use examples ; then + dodoc -r doc/examples + docompress -x /usr/share/doc/${PF}/examples + fi +} + +multilib_src_test() { + 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" \ + emake V=1 fate +} |