summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2022-05-18 14:49:55 +0200
committerAndreas Sturmlechner <asturm@gentoo.org>2022-05-18 14:49:55 +0200
commit46b5fab594719d2d438256d257cae5fddd07f538 (patch)
tree874c49cb7087996085707faf8f8f11c3a6f07f49 /media-video/subtitlecomposer
parentsci-mathematics/rkward: 0.7.3 version bump (diff)
downloadgentoo-46b5fab594719d2d438256d257cae5fddd07f538.tar.gz
gentoo-46b5fab594719d2d438256d257cae5fddd07f538.tar.bz2
gentoo-46b5fab594719d2d438256d257cae5fddd07f538.zip
media-video/subtitlecomposer: Fix build with >=ffmpeg-5
Upstream commit 4f4f560e40ba0b760cf688eb024be3cc734ca347 Closes: https://bugs.gentoo.org/834416 Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'media-video/subtitlecomposer')
-rw-r--r--media-video/subtitlecomposer/files/subtitlecomposer-0.7.1-ffmpeg-5.patch65
-rw-r--r--media-video/subtitlecomposer/subtitlecomposer-0.7.1.ebuild1
2 files changed, 66 insertions, 0 deletions
diff --git a/media-video/subtitlecomposer/files/subtitlecomposer-0.7.1-ffmpeg-5.patch b/media-video/subtitlecomposer/files/subtitlecomposer-0.7.1-ffmpeg-5.patch
new file mode 100644
index 000000000000..a0314fb06820
--- /dev/null
+++ b/media-video/subtitlecomposer/files/subtitlecomposer-0.7.1-ffmpeg-5.patch
@@ -0,0 +1,65 @@
+From 4f4f560e40ba0b760cf688eb024be3cc734ca347 Mon Sep 17 00:00:00 2001
+From: Mladen Milinkovic <maxrd2@smoothware.net>
+Date: Tue, 25 Jan 2022 14:01:56 +0100
+Subject: [PATCH] Fix compilation with ffmpeg5 #63
+
+---
+ src/streamprocessor/streamprocessor.cpp | 2 +-
+ src/videoplayer/backend/decoder.h | 1 +
+ src/videoplayer/backend/framequeue.h | 1 +
+ src/videoplayer/backend/streamdemuxer.cpp | 2 +-
+ 4 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/src/streamprocessor/streamprocessor.cpp b/src/streamprocessor/streamprocessor.cpp
+index b86795e..8faf8a2 100644
+--- a/src/streamprocessor/streamprocessor.cpp
++++ b/src/streamprocessor/streamprocessor.cpp
+@@ -195,7 +195,7 @@ StreamProcessor::findStream(int streamType, int streamIndex, bool imageSub)
+ int ret;
+ char errorText[1024];
+
+- AVCodec *dec = avcodec_find_decoder(m_avStream->codecpar->codec_id);
++ const AVCodec *dec = avcodec_find_decoder(m_avStream->codecpar->codec_id);
+ if(!dec) {
+ qWarning() << "Failed to find decoder for stream" << i;
+ return false;
+diff --git a/src/videoplayer/backend/decoder.h b/src/videoplayer/backend/decoder.h
+index 4ab95b2..fb6840d 100644
+--- a/src/videoplayer/backend/decoder.h
++++ b/src/videoplayer/backend/decoder.h
+@@ -11,6 +11,7 @@
+ #include <QThread>
+
+ extern "C" {
++#include "libavcodec/avcodec.h"
+ #include "libavformat/avformat.h"
+ }
+
+diff --git a/src/videoplayer/backend/framequeue.h b/src/videoplayer/backend/framequeue.h
+index dc9b2fa..ece1166 100644
+--- a/src/videoplayer/backend/framequeue.h
++++ b/src/videoplayer/backend/framequeue.h
+@@ -9,6 +9,7 @@
+ #define FRAMEQUEUE_H
+
+ extern "C" {
++#include "libavcodec/avcodec.h"
+ #include "libavformat/avformat.h"
+ }
+
+diff --git a/src/videoplayer/backend/streamdemuxer.cpp b/src/videoplayer/backend/streamdemuxer.cpp
+index 1e339b3..e8320ea 100644
+--- a/src/videoplayer/backend/streamdemuxer.cpp
++++ b/src/videoplayer/backend/streamdemuxer.cpp
+@@ -230,7 +230,7 @@ StreamDemuxer::componentOpen(int streamIndex)
+ {
+ AVFormatContext *ic = m_vs->fmtContext;
+ AVCodecContext *avCtx;
+- AVCodec *codec;
++ const AVCodec *codec;
+ AVDictionary *opts = nullptr;
+ AVDictionaryEntry *t = nullptr;
+ int sampleRate, nbChannels;
+--
+GitLab
+
diff --git a/media-video/subtitlecomposer/subtitlecomposer-0.7.1.ebuild b/media-video/subtitlecomposer/subtitlecomposer-0.7.1.ebuild
index 3ff7e5e962a5..54143eba37a9 100644
--- a/media-video/subtitlecomposer/subtitlecomposer-0.7.1.ebuild
+++ b/media-video/subtitlecomposer/subtitlecomposer-0.7.1.ebuild
@@ -46,6 +46,7 @@ BDEPEND="
PATCHES=(
"${FILESDIR}/${P}-tests-optional.patch"
"${FILESDIR}/${P}-gles-support.patch" # bug 820035
+ "${FILESDIR}/${P}-ffmpeg-5.patch" # bug 834416
)
src_configure() {