Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package QMPlay2 for openSUSE:Factory checked 
in at 2022-01-26 21:27:01
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/QMPlay2 (Old)
 and      /work/SRC/openSUSE:Factory/.QMPlay2.new.1938 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "QMPlay2"

Wed Jan 26 21:27:01 2022 rev:62 rq:949170 version:21.12.24

Changes:
--------
--- /work/SRC/openSUSE:Factory/QMPlay2/QMPlay2.changes  2021-12-24 
20:23:44.458037052 +0100
+++ /work/SRC/openSUSE:Factory/.QMPlay2.new.1938/QMPlay2.changes        
2022-01-26 21:27:43.781684117 +0100
@@ -1,0 +2,6 @@
+Sun Jan 23 11:55:36 UTC 2022 - Simon Vogl <simon.v...@gmx.net>
+
+- Added 0001-fix-ffmpeg-5-compilation.patch to fix a compilation error with 
FFmpeg >= 5.0.0
+- Dropped support for openSUSE Leap 15.2 and SLE15SP2 as they are EOL and 
can't satisfy QMPlay2's future build requirements anymore
+
+-------------------------------------------------------------------

New:
----
  0001-fix-ffmpeg-5-compilation.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ QMPlay2.spec ++++++
--- /var/tmp/diff_new_pack.icFJgG/_old  2022-01-26 21:27:44.317680422 +0100
+++ /var/tmp/diff_new_pack.icFJgG/_new  2022-01-26 21:27:44.321680393 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package QMPlay2
 #
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -30,6 +30,8 @@
 Patch1:         0001-add-opensuse-customizations.patch
 # PATCH-FIX-OPENSUSE
 Patch2:         0001-fix-pipewire-build-error.patch
+# PATCH-FIX-UPSTREAM
+Patch3:         0001-fix-ffmpeg-5-compilation.patch
 BuildRequires:  cmake >= 3.16
 BuildRequires:  gcc-c++
 # Use gcc 10 for openSUSE Leap 15.3+ and SLE15SP3+
@@ -55,10 +57,7 @@
 BuildRequires:  pkgconfig(libcddb)
 BuildRequires:  pkgconfig(libcdio)
 BuildRequires:  pkgconfig(libgme)
-# Enable PipeWire support on openSUSE Leap 15.3+, SLE15SP3+ and openSUSE 
Tumbleweed
-%if 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150300
 BuildRequires:  pkgconfig(libpipewire-0.3)
-%endif
 BuildRequires:  pkgconfig(SPIRV-Tools)
 BuildRequires:  pkgconfig(libpulse)
 BuildRequires:  pkgconfig(libsidplayfp)
@@ -102,6 +101,7 @@
 %if 0%{?sle_version} == 150300
 %patch2 -p1
 %endif
+%patch3 -p1
 
 %build
 # Build options
@@ -119,11 +119,7 @@
   -DCMAKE_INSTALL_LIBDIR=%{_libdir} \
   -DUSE_GLSLC=ON \
   -DUSE_PORTAUDIO=ON \
-%if 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150300
   -DUSE_PIPEWIRE=ON \
-%else
-  -DUSE_PIPEWIRE=OFF \
-%endif
   -DUSE_UPDATES=OFF
 
 %ninja_build

++++++ 0001-fix-ffmpeg-5-compilation.patch ++++++
>From bb48170d01c784d3c0436e9e341e21ad08721ff6 Sun 23  1 11:55:36 2022
From: Simon Vogl <simon.v...@gmx.net>
Date: Sun, 23 Jan 2022 11:55:36 UTC
Subject: [PATCH] Fix FFmpeg 5 compilation

This patch is required to fix a compile error when builing QMPlay2 against 
FFmpeg >= 5.0.0.


diff --git a/src/modules/CUVID/CuvidDec.cpp b/src/modules/CUVID/CuvidDec.cpp
index 64ae9386..f8288764 100644
--- a/src/modules/CUVID/CuvidDec.cpp
+++ b/src/modules/CUVID/CuvidDec.cpp
@@ -431,7 +431,7 @@ bool CuvidDec::open(StreamInfo &streamInfo)
     if (streamInfo.codec_type != AVMEDIA_TYPE_VIDEO)
         return false;
 
-    AVCodec *avCodec = avcodec_find_decoder_by_name(streamInfo.codec_name);
+    auto avCodec = const_cast<AVCodec 
*>(avcodec_find_decoder_by_name(streamInfo.codec_name));
     if (!avCodec)
         return false;
 
diff --git a/src/modules/CUVID/CuvidDec.hpp b/src/modules/CUVID/CuvidDec.hpp
index 0efb5bd9..cce1308d 100644
--- a/src/modules/CUVID/CuvidDec.hpp
+++ b/src/modules/CUVID/CuvidDec.hpp
@@ -26,6 +26,10 @@
 #include <QCoreApplication>
 #include <QQueue>
 
+extern "C" {
+    #include <libavcodec/bsf.h>
+}
+
 class CuvidHWInterop;
 class VideoWriter;
 
diff --git a/src/modules/FFmpeg/FFDec.cpp b/src/modules/FFmpeg/FFDec.cpp
index 592f12b7..9683bcfa 100644
--- a/src/modules/FFmpeg/FFDec.cpp
+++ b/src/modules/FFmpeg/FFDec.cpp
@@ -70,7 +70,7 @@ void FFDec::clearFrames()
 
 AVCodec *FFDec::init(StreamInfo &streamInfo)
 {
-    AVCodec *codec = avcodec_find_decoder_by_name(streamInfo.codec_name);
+    auto codec = const_cast< AVCodec 
*>(avcodec_find_decoder_by_name(streamInfo.codec_name));
     if (codec)
     {
         codec_ctx = avcodec_alloc_context3(codec);
diff --git a/src/modules/FFmpeg/FormatContext.cpp 
b/src/modules/FFmpeg/FormatContext.cpp
index 88f8ccb8..e96758e3 100644
--- a/src/modules/FFmpeg/FormatContext.cpp
+++ b/src/modules/FFmpeg/FormatContext.cpp
@@ -687,7 +687,7 @@ bool FormatContext::open(const QString &_url, const QString 
&param)
         if (scheme != "rtsp")
         {
             // It is needed for QMPlay2 schemes like "alsa://", "v4l2://", etc.
-            inputFmt = av_find_input_format(scheme);
+            inputFmt = const_cast<AVInputFormat 
*>(av_find_input_format(scheme));
             if (inputFmt)
                 url = _url.right(_url.length() - scheme.length() - 3);
         }

Reply via email to