summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2013-01-17 21:15:03 +0000
committerAlexis Ballier <aballier@gentoo.org>2013-01-17 21:15:03 +0000
commit01359c321c8b6c2ac2de2df3cd3319c962eb2af6 (patch)
tree30ba9fdd8efbc69a6557dba64b2b14cafa9fef4d /sci-libs/vtk
parentVersion bump (diff)
downloadgentoo-2-01359c321c8b6c2ac2de2df3cd3319c962eb2af6.tar.gz
gentoo-2-01359c321c8b6c2ac2de2df3cd3319c962eb2af6.tar.bz2
gentoo-2-01359c321c8b6c2ac2de2df3cd3319c962eb2af6.zip
Fix build with latest ffmpeg. Part of bug #450464.
(Portage version: 2.2.0_alpha154/cvs/Linux x86_64, signed Manifest commit with key 160F534A)
Diffstat (limited to 'sci-libs/vtk')
-rw-r--r--sci-libs/vtk/ChangeLog6
-rw-r--r--sci-libs/vtk/files/vtk-5.10.1-ffmpeg-1.patch49
-rw-r--r--sci-libs/vtk/vtk-5.10.1.ebuild3
3 files changed, 56 insertions, 2 deletions
diff --git a/sci-libs/vtk/ChangeLog b/sci-libs/vtk/ChangeLog
index bcb146e1da6b..0dd7f15f8744 100644
--- a/sci-libs/vtk/ChangeLog
+++ b/sci-libs/vtk/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for sci-libs/vtk
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/vtk/ChangeLog,v 1.104 2013/01/15 13:57:49 jlec Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/vtk/ChangeLog,v 1.105 2013/01/17 21:15:03 aballier Exp $
+
+ 17 Jan 2013; Alexis Ballier <aballier@gentoo.org> vtk-5.10.1.ebuild,
+ +files/vtk-5.10.1-ffmpeg-1.patch:
+ Fix build with latest ffmpeg. Part of bug #450464.
15 Jan 2013; Justin Lecher <jlec@gentoo.org> vtk-5.10.1.ebuild,
+files/vtk-5.10.1-tcl8.6.patch:
diff --git a/sci-libs/vtk/files/vtk-5.10.1-ffmpeg-1.patch b/sci-libs/vtk/files/vtk-5.10.1-ffmpeg-1.patch
new file mode 100644
index 000000000000..2cefb12591a5
--- /dev/null
+++ b/sci-libs/vtk/files/vtk-5.10.1-ffmpeg-1.patch
@@ -0,0 +1,49 @@
+https://bugs.gentoo.org/show_bug.cgi?id=450464
+
+Index: VTK5.10.1/IO/vtkFFMPEGWriter.cxx
+===================================================================
+--- VTK5.10.1.orig/IO/vtkFFMPEGWriter.cxx
++++ VTK5.10.1/IO/vtkFFMPEGWriter.cxx
+@@ -192,13 +192,6 @@ int vtkFFMPEGWriterInternal::Start()
+ c->bit_rate_tolerance = this->Writer->GetBitRateTolerance();
+ }
+
+- //apply the chosen parameters
+- if (av_set_parameters(this->avFormatContext, NULL) < 0)
+- {
+- vtkGenericWarningMacro (<< "Invalid output format parameters." );
+- return 0;
+- }
+-
+ //manufacture a codec with the chosen parameters
+ AVCodec *codec = avcodec_find_encoder(c->codec_id);
+ if (!codec)
+@@ -259,14 +252,17 @@ int vtkFFMPEGWriterInternal::Start()
+
+
+ //Finally, open the file and start it off.
+- if (url_fopen(&this->avFormatContext->pb, this->avFormatContext->filename, URL_WRONLY) < 0)
++ if (avio_open(&this->avFormatContext->pb, this->avFormatContext->filename, AVIO_FLAG_WRITE) < 0)
+ {
+ vtkGenericWarningMacro (<< "Could not open " << this->Writer->GetFileName() << "." );
+ return 0;
+ }
+ this->openedFile = 1;
+
+- av_write_header(this->avFormatContext);
++ if(avformat_write_header(this->avFormatContext, NULL) < 0) {
++ vtkGenericWarningMacro (<< "Failed to write header." );
++ return 0;
++ }
+ return 1;
+ }
+
+@@ -391,7 +387,7 @@ void vtkFFMPEGWriterInternal::End()
+ #ifdef VTK_FFMPEG_OLD_URL_FCLOSE
+ url_fclose(&this->avFormatContext->pb);
+ #else
+- url_fclose(this->avFormatContext->pb);
++ avio_close(this->avFormatContext->pb);
+ #endif
+ this->openedFile = 0;
+ }
diff --git a/sci-libs/vtk/vtk-5.10.1.ebuild b/sci-libs/vtk/vtk-5.10.1.ebuild
index 2f20984444b8..af88a06312de 100644
--- a/sci-libs/vtk/vtk-5.10.1.ebuild
+++ b/sci-libs/vtk/vtk-5.10.1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/vtk/vtk-5.10.1.ebuild,v 1.4 2013/01/15 13:57:49 jlec Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/vtk/vtk-5.10.1.ebuild,v 1.5 2013/01/17 21:15:03 aballier Exp $
EAPI=3
@@ -77,6 +77,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-5.6.1-ffmpeg.patch
"${FILESDIR}"/${PN}-5.6.1-libav-0.8.patch
"${FILESDIR}"/${P}-tcl8.6.patch
+ "${FILESDIR}"/${P}-ffmpeg-1.patch
)
pkg_setup() {