Gentoo Archives: gentoo-commits

From: Alexis Ballier <aballier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-electronics/gazebo/, sci-electronics/gazebo/files/
Date: Wed, 02 Mar 2022 17:45:26
Message-Id: 1646243101.218f0e9d77cc20c2c6f37cbe2d25e608ba80ea09.aballier@gentoo
1 commit: 218f0e9d77cc20c2c6f37cbe2d25e608ba80ea09
2 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org>
3 AuthorDate: Wed Mar 2 17:27:32 2022 +0000
4 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org>
5 CommitDate: Wed Mar 2 17:45:01 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=218f0e9d
7
8 sci-electronics/gazebo: fix build with ffmpeg4
9
10 Closes: https://bugs.gentoo.org/833868
11 Package-Manager: Portage-3.0.30, Repoman-3.0.3
12 Signed-off-by: Alexis Ballier <aballier <AT> gentoo.org>
13
14 sci-electronics/gazebo/files/ffmpeg4.patch | 16 ++++++++++++++++
15 sci-electronics/gazebo/gazebo-11.10.1.ebuild | 1 +
16 2 files changed, 17 insertions(+)
17
18 diff --git a/sci-electronics/gazebo/files/ffmpeg4.patch b/sci-electronics/gazebo/files/ffmpeg4.patch
19 new file mode 100644
20 index 000000000000..7b7c8d7270fd
21 --- /dev/null
22 +++ b/sci-electronics/gazebo/files/ffmpeg4.patch
23 @@ -0,0 +1,16 @@
24 +Index: gazebo-11.10.1/gazebo/common/VideoEncoder.cc
25 +===================================================================
26 +--- gazebo-11.10.1.orig/gazebo/common/VideoEncoder.cc
27 ++++ gazebo-11.10.1/gazebo/common/VideoEncoder.cc
28 +@@ -224,7 +224,10 @@ bool VideoEncoder::Start(const std::stri
29 +
30 + // The remainder of this function handles FFMPEG initialization of a video
31 + // stream
32 +- const AVOutputFormat *outputFormat = nullptr;
33 ++#if LIBAVFORMAT_VERSION_MAJOR >= 59
34 ++ const
35 ++#endif
36 ++ AVOutputFormat *outputFormat = nullptr;
37 +
38 + // This 'if' and 'free' are just for safety. We chech the value of formatCtx
39 + // below.
40
41 diff --git a/sci-electronics/gazebo/gazebo-11.10.1.ebuild b/sci-electronics/gazebo/gazebo-11.10.1.ebuild
42 index 4641556896a7..3291c74fa777 100644
43 --- a/sci-electronics/gazebo/gazebo-11.10.1.ebuild
44 +++ b/sci-electronics/gazebo/gazebo-11.10.1.ebuild
45 @@ -66,6 +66,7 @@ PATCHES=(
46 "${FILESDIR}/qwt.patch"
47 "${FILESDIR}/cmake.patch"
48 "${FILESDIR}/ffmpeg5.patch"
49 + "${FILESDIR}/ffmpeg4.patch"
50 )
51
52 src_configure() {