summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2018-11-29 21:02:59 +0100
committerAndreas Sturmlechner <asturm@gentoo.org>2018-11-29 21:18:46 +0100
commit22c33947b0ef4c26437b62ebdd76e2ad19fdb8b1 (patch)
tree8ff81d1246878892766f80de316fcd81787957bd /sci-libs/opencascade/files
parentmedia-sound/cantata: Drop 2.2.0 (diff)
downloadgentoo-22c33947b0ef4c26437b62ebdd76e2ad19fdb8b1.tar.gz
gentoo-22c33947b0ef4c26437b62ebdd76e2ad19fdb8b1.tar.bz2
gentoo-22c33947b0ef4c26437b62ebdd76e2ad19fdb8b1.zip
sci-libs/opencascade: Fix build with ffmpeg-4
Reported-by: Boris Vingradov <no111u3@gmail.com> Closes: https://bugs.gentoo.org/672248 Package-Manager: Portage-2.3.52, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'sci-libs/opencascade/files')
-rw-r--r--sci-libs/opencascade/files/opencascade-7.3.0-ffmpeg4.patch38
1 files changed, 38 insertions, 0 deletions
diff --git a/sci-libs/opencascade/files/opencascade-7.3.0-ffmpeg4.patch b/sci-libs/opencascade/files/opencascade-7.3.0-ffmpeg4.patch
new file mode 100644
index 000000000000..fc572a4f5bca
--- /dev/null
+++ b/sci-libs/opencascade/files/opencascade-7.3.0-ffmpeg4.patch
@@ -0,0 +1,38 @@
+Author: jbeich
+Date: Wed May 2 13:25:55 UTC 2018
+New revision: 468831
+
+src/Image/Image_VideoRecorder.cxx:279:25: error: use of undeclared identifier 'CODEC_FLAG_GLOBAL_HEADER'
+ aCodecCtx->flags |= CODEC_FLAG_GLOBAL_HEADER;
+ ^
+src/Image/Image_VideoRecorder.cxx:452:38: error: use of undeclared identifier 'AVFMT_RAWPICTURE'
+ if ((myAVContext->oformat->flags & AVFMT_RAWPICTURE) != 0
+ ^
+
+--- a/src/Image/Image_VideoRecorder.cxx 2017-08-30 13:28:21 UTC
++++ b/src/Image/Image_VideoRecorder.cxx
+@@ -276,7 +276,7 @@ Standard_Boolean Image_VideoRecorder::addVideoStream (
+ // some formats want stream headers to be separate
+ if (myAVContext->oformat->flags & AVFMT_GLOBALHEADER)
+ {
+- aCodecCtx->flags |= CODEC_FLAG_GLOBAL_HEADER;
++ aCodecCtx->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
+ }
+ return Standard_True;
+ #else
+@@ -449,6 +449,7 @@ Standard_Boolean Image_VideoRecorder::writeVideoFrame
+ AVPacket aPacket;
+ memset (&aPacket, 0, sizeof(aPacket));
+ av_init_packet (&aPacket);
++#ifdef AVFMT_RAWPICTURE
+ if ((myAVContext->oformat->flags & AVFMT_RAWPICTURE) != 0
+ && !theToFlush)
+ {
+@@ -461,6 +462,7 @@ Standard_Boolean Image_VideoRecorder::writeVideoFrame
+ aResAv = av_interleaved_write_frame (myAVContext, &aPacket);
+ }
+ else
++#endif
+ {
+ // encode the image
+ myFrame->pts = myFrameCount;