public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/olive] f45: fix build with FFmpeg 9
@ 2026-09-18 17:09 Dominik 'Rathann' Mierzejewski
0 siblings, 0 replies; only message in thread
From: Dominik 'Rathann' Mierzejewski @ 2026-09-18 17:09 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/olive
Branch : f45
Commit : 2f6720ef0a6d62e95d2c9b0f0be827a403fa7e0b
Author : Dominik 'Rathann' Mierzejewski <dominik@greysector.net>
Date : 2026-08-21T18:08:55+02:00
Stats : +64/-1 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/olive/c/2f6720ef0a6d62e95d2c9b0f0be827a403fa7e0b?branch=f45
Log:
fix build with FFmpeg 9
---
diff --git a/olive-ffmpeg-9.patch b/olive-ffmpeg-9.patch
new file mode 100644
index 0000000..2040a7c
--- /dev/null
+++ b/olive-ffmpeg-9.patch
@@ -0,0 +1,58 @@
+diff -up olive-8ac191ceb64476b50cd8e16dce7c971fb791af95/app/codec/ffmpeg/ffmpegencoder.cpp.orig olive-8ac191ceb64476b50cd8e16dce7c971fb791af95/app/codec/ffmpeg/ffmpegencoder.cpp
+--- olive-8ac191ceb64476b50cd8e16dce7c971fb791af95/app/codec/ffmpeg/ffmpegencoder.cpp.orig 2026-08-21 18:02:55.476472990 +0200
++++ olive-8ac191ceb64476b50cd8e16dce7c971fb791af95/app/codec/ffmpeg/ffmpegencoder.cpp 2026-08-21 18:07:47.116833479 +0200
+@@ -55,14 +55,22 @@ QStringList FFmpegEncoder::GetPixelForma
+ const AVCodec* codec_info = GetEncoder(c, SampleFormat::INVALID);
+
+ if (codec_info) {
+- for (int i=0; codec_info->pix_fmts[i]!=-1; i++) {
+- if (FFmpegUtils::ConvertJPEGSpaceToRegularSpace(codec_info->pix_fmts[i]) != codec_info->pix_fmts[i]) {
+- // This is a deprecated "JPEG" space, skip it
+- continue;
+- }
++ const AVPixelFormat *supported_pix_fmts = nullptr;
++ if (avcodec_get_supported_config(nullptr, codec_info, AV_CODEC_CONFIG_PIX_FORMAT, 0,
++ reinterpret_cast<const void **>(&supported_pix_fmts), nullptr) < 0) {
++ supported_pix_fmts = nullptr;
++ }
++
++ if (supported_pix_fmts) {
++ for (int i=0; supported_pix_fmts[i]!=AV_PIX_FMT_NONE; i++) {
++ if (FFmpegUtils::ConvertJPEGSpaceToRegularSpace(supported_pix_fmts[i]) != supported_pix_fmts[i]) {
++ // This is a deprecated "JPEG" space, skip it
++ continue;
++ }
+
+- const char* pix_fmt_name = av_get_pix_fmt_name(codec_info->pix_fmts[i]);
+- pix_fmts.append(pix_fmt_name);
++ const char* pix_fmt_name = av_get_pix_fmt_name(supported_pix_fmts[i]);
++ pix_fmts.append(pix_fmt_name);
++ }
+ }
+ }
+
+@@ -88,11 +96,19 @@ std::vector<SampleFormat> FFmpegEncoder:
+ } else {
+ const AVCodec* codec_info = GetEncoder(c, SampleFormat::INVALID);
+
+- if (codec_info && codec_info->sample_fmts) {
+- for (int i=0; codec_info->sample_fmts[i]!=-1; i++) {
+- SampleFormat this_format = FFmpegUtils::GetNativeSampleFormat(static_cast<AVSampleFormat>(codec_info->sample_fmts[i]));
+- if (this_format != SampleFormat::INVALID) {
+- f.push_back(this_format);
++ if (codec_info) {
++ const AVSampleFormat *sample_fmts = nullptr;
++ if (avcodec_get_supported_config(nullptr, codec_info, AV_CODEC_CONFIG_SAMPLE_FORMAT, 0,
++ reinterpret_cast<const void **>(&sample_fmts), nullptr) < 0) {
++ sample_fmts = nullptr;
++ }
++
++ if (sample_fmts) {
++ for (int i=0; sample_fmts[i]!=AV_SAMPLE_FMT_NONE; i++) {
++ SampleFormat this_format = FFmpegUtils::GetNativeSampleFormat(static_cast<AVSampleFormat>(sample_fmts[i]));
++ if (this_format != SampleFormat::INVALID) {
++ f.push_back(this_format);
++ }
+ }
+ }
+ }
diff --git a/olive.spec b/olive.spec
index b417b07..cceabc3 100644
--- a/olive.spec
+++ b/olive.spec
@@ -18,7 +18,7 @@ Version: 0.2.0^%{gitdate}git%{shortcommit}
%else
Version: 0.2.0
%endif
-Release: 8%{?dist}
+Release: 9%{?dist}
Summary: A free non-linear video editor
# app/widget/flowlayout/flowlayout.*: BSD-3-Clause
# ext/KDDockWidgets/LICENSE.txt: GPL-2.0-only OR GPL-3.0-only
@@ -42,6 +42,8 @@ Patch3: %{name}-oiio-3.0.patch
Patch4: %{name}-ffmpeg-8.patch
Patch5: 0001-fix-qt6-arg-format.patch
Patch6: 0002-fix-qt6-arg-sampleformat.patch
+# fix build with FFmpeg 9
+Patch7: %{name}-ffmpeg-9.patch
%else
Source0: https://github.com/olive-editor/%{name}/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz
%endif
@@ -149,6 +151,9 @@ appstream-util validate-relax --nonet %{buildroot}/%{_metainfodir}/%{unique_name
%{_datadir}/mime/packages/%{unique_name}.xml
%changelog
+* Fri Aug 21 2026 Dominik Mierzejewski <dominik@greysector.net> - 0.2.0^20241204git8ac191c-9
+- fix build with FFmpeg 9
+
* Thu Jul 16 2026 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.0^20241204git8ac191c-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-09-18 17:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-18 17:09 [rpms/olive] f45: fix build with FFmpeg 9 Dominik 'Rathann' Mierzejewski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox