summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2012-10-25 12:46:30 +0000
committerAlexis Ballier <aballier@gentoo.org>2012-10-25 12:46:30 +0000
commita19ad84e8c8fbc9717483f93ad9c71969c09bf67 (patch)
tree0061914752d162b56669c2554e7c27bcdd3a7332 /media-libs
parentEnable maximum log levels for tests (diff)
downloadgentoo-2-a19ad84e8c8fbc9717483f93ad9c71969c09bf67.tar.gz
gentoo-2-a19ad84e8c8fbc9717483f93ad9c71969c09bf67.tar.bz2
gentoo-2-a19ad84e8c8fbc9717483f93ad9c71969c09bf67.zip
fix build with recent ffmpeg versions
(Portage version: 2.2.0_alpha141/cvs/Linux x86_64, signed Manifest commit with key 160F534A)
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/mlt/ChangeLog6
-rw-r--r--media-libs/mlt/files/mlt-0.8.2-av_codec_is_encoder.patch32
-rw-r--r--media-libs/mlt/mlt-0.8.2.ebuild3
3 files changed, 39 insertions, 2 deletions
diff --git a/media-libs/mlt/ChangeLog b/media-libs/mlt/ChangeLog
index 81670b4b2802..ced5d3ef32f1 100644
--- a/media-libs/mlt/ChangeLog
+++ b/media-libs/mlt/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for media-libs/mlt
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/mlt/ChangeLog,v 1.94 2012/09/22 04:12:32 yngwin Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/mlt/ChangeLog,v 1.95 2012/10/25 12:46:30 aballier Exp $
+
+ 25 Oct 2012; Alexis Ballier <aballier@gentoo.org> mlt-0.8.2.ebuild,
+ +files/mlt-0.8.2-av_codec_is_encoder.patch:
+ fix build with recent ffmpeg versions
22 Sep 2012; Ben de Groot <yngwin@gentoo.org> -mlt-0.8.0.ebuild:
Remove mlt-0.8.0 as requested in bug #435748
diff --git a/media-libs/mlt/files/mlt-0.8.2-av_codec_is_encoder.patch b/media-libs/mlt/files/mlt-0.8.2-av_codec_is_encoder.patch
new file mode 100644
index 000000000000..3d0ba1ceb2aa
--- /dev/null
+++ b/media-libs/mlt/files/mlt-0.8.2-av_codec_is_encoder.patch
@@ -0,0 +1,32 @@
+AVCodec.encode has been renamed recently is ffmpeg, causing mlt to fail to build.
+Starting from libavcodec 54.7 we have av_codec_is_encoder available publicly so
+use this instead.
+
+Index: mlt-0.8.2/src/modules/avformat/consumer_avformat.c
+===================================================================
+--- mlt-0.8.2.orig/src/modules/avformat/consumer_avformat.c
++++ mlt-0.8.2/src/modules/avformat/consumer_avformat.c
+@@ -238,7 +238,11 @@ static int consumer_start( mlt_consumer
+ mlt_properties_set_data( doc, "audio_codecs", codecs, 0, NULL, NULL );
+ while ( ( codec = av_codec_next( codec ) ) )
+ #if LIBAVCODEC_VERSION_INT >= ((54<<16)+(0<<8)+0)
++#if LIBAVCODEC_VERSION_INT >= ((54<<16)+(7<<8)+0)
++ if ( av_codec_is_encoder(codec) && codec->type == CODEC_TYPE_AUDIO )
++#else
+ if ( ( codec->encode || codec->encode2 ) && codec->type == CODEC_TYPE_AUDIO )
++#endif
+ #else
+ if ( codec->encode && codec->type == CODEC_TYPE_AUDIO )
+ #endif
+@@ -262,7 +266,11 @@ static int consumer_start( mlt_consumer
+ mlt_properties_set_data( doc, "video_codecs", codecs, 0, NULL, NULL );
+ while ( ( codec = av_codec_next( codec ) ) )
+ #if LIBAVCODEC_VERSION_INT >= ((54<<16)+(0<<8)+0)
++#if LIBAVCODEC_VERSION_INT >= ((54<<16)+(7<<8)+0)
++ if ( av_codec_is_encoder(codec) && codec->type == CODEC_TYPE_VIDEO )
++#else
+ if ( (codec->encode || codec->encode2) && codec->type == CODEC_TYPE_VIDEO )
++#endif
+ #else
+ if ( codec->encode && codec->type == CODEC_TYPE_VIDEO )
+ #endif
diff --git a/media-libs/mlt/mlt-0.8.2.ebuild b/media-libs/mlt/mlt-0.8.2.ebuild
index 55e3c0271f0c..5b3753ba093e 100644
--- a/media-libs/mlt/mlt-0.8.2.ebuild
+++ b/media-libs/mlt/mlt-0.8.2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/mlt/mlt-0.8.2.ebuild,v 1.1 2012/08/31 03:39:11 yngwin Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/mlt/mlt-0.8.2.ebuild,v 1.2 2012/10/25 12:46:30 aballier Exp $
EAPI=4
PYTHON_DEPEND="python? 2:2.6"
@@ -66,6 +66,7 @@ pkg_setup() {
src_prepare() {
epatch "${FILESDIR}"/${PN}-0.7.2-ruby-link.patch
+ epatch "${FILESDIR}"/${PN}-0.8.2-av_codec_is_encoder.patch
# respect CFLAGS LDFLAGS when building shared libraries. Bug #308873
for x in python lua; do