]> git.sur5r.net Git - minitube/commitdiff
Fix compilation with mpv 0.35 (Closes: #1024029)
authorJakob Haufe <sur5r@debian.org>
Sat, 3 Dec 2022 22:57:03 +0000 (23:57 +0100)
committerJakob Haufe <sur5r@debian.org>
Sat, 3 Dec 2022 22:57:03 +0000 (23:57 +0100)
debian/patches/mpv-0.35-fix [new file with mode: 0644]
debian/patches/series

diff --git a/debian/patches/mpv-0.35-fix b/debian/patches/mpv-0.35-fix
new file mode 100644 (file)
index 0000000..d22d848
--- /dev/null
@@ -0,0 +1,24 @@
+Description: Fix compilation with mpv 0.35
+Author: Kotori Itsuka <cmdrkotori2@gmail.com>
+
+Origin: other, https://github.com/mpc-qt/mpc-qt/commit/a880cb84511d18af26dcd136fac62932e775f475
+Bug: https://github.com/flaviotordini/minitube/issues/217
+Bug-Debian: https://bugs.debian.org/1024029
+Forwarded: not-needed
+Last-Update: 2022-12-03
+
+--- minitube-3.9.3.orig/lib/media/src/mpv/mpvwidget.cpp
++++ minitube-3.9.3/lib/media/src/mpv/mpvwidget.cpp
+@@ -30,7 +30,11 @@ void MpvWidget::initializeGL() {
+     qDebug() << "initializeGL" << nativeParent;
+     if (nativeParent == nullptr) qFatal("No native parent");
+-    mpv_opengl_init_params gl_init_params{get_proc_address, this, nullptr};
++    #if MPV_CLIENT_API_VERSION < MPV_MAKE_VERSION(2,0)
++      mpv_opengl_init_params gl_init_params{get_proc_address, this, nullptr};
++    #else
++      mpv_opengl_init_params gl_init_params{get_proc_address, this};
++    #endif
+     mpv_render_param params[]{{MPV_RENDER_PARAM_API_TYPE, (void *)MPV_RENDER_API_TYPE_OPENGL},
+                               {MPV_RENDER_PARAM_OPENGL_INIT_PARAMS, &gl_init_params},
+                               {MPV_RENDER_PARAM_INVALID, nullptr},
index 5e67db8d00524501f73e38eac391b7421cceda29..1e7586c3f5429da57a788681b16f29b2e11d4726 100644 (file)
@@ -1,2 +1,3 @@
 proper-tempfiles
 disable-update-check
+mpv-0.35-fix