Skip to content

Commit

Permalink
kde-apps/kdenlive: backport patch from upstream solving crash
Browse files Browse the repository at this point in the history
Gentoo-bug: 605610

Package-Manager: Portage-2.3.3, Repoman-2.3.1
  • Loading branch information
Michael Palimaka committed Jan 18, 2017
1 parent b3fe1e3 commit 38ebbd3
Show file tree
Hide file tree
Showing 2 changed files with 131 additions and 0 deletions.
60 changes: 60 additions & 0 deletions kde-apps/kdenlive/files/kdenlive-16.12.1-crash.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
From 8a20fca86e9e2ce3d04b3e024b0752e19f9d8c8e Mon Sep 17 00:00:00 2001
From: Jean-Baptiste Mardelle <[email protected]>
Date: Mon, 16 Jan 2017 20:06:00 +0100
Subject: [PATCH] Revert "Fix warning about QOffscreenSurface thread" Caused
startup crash on NVidia cards CCBUG: 375094

This reverts commit 6675c4a509046aa3b57c60cbc3f31435e09c2df7.
---
src/monitor/glwidget.cpp | 10 +++-------
src/monitor/glwidget.h | 1 -
2 files changed, 3 insertions(+), 8 deletions(-)

diff --git a/src/monitor/glwidget.cpp b/src/monitor/glwidget.cpp
index e4089e6..cd4f56a 100644
--- a/src/monitor/glwidget.cpp
+++ b/src/monitor/glwidget.cpp
@@ -109,7 +109,6 @@ GLWidget::GLWidget(int id, QObject *parent)
mlt_properties_set_data(mlt_global_properties(), "glslManager", NULL, 0, NULL, NULL);
emit gpuNotSupported();
}
- connect(this, SIGNAL(sceneGraphInitialized()), SLOT(createOffscreen()));
connect(this, SIGNAL(sceneGraphInitialized()), SLOT(initializeGL()), Qt::DirectConnection);
connect(this, SIGNAL(beforeRendering()), SLOT(paintGL()), Qt::DirectConnection);
}
@@ -143,17 +142,14 @@ void GLWidget::updateAudioForAnalysis()
m_frameRenderer->sendAudioForAnalysis = KdenliveSettings::monitor_audio();
}

-void GLWidget::createOffscreen()
+void GLWidget::initializeGL()
{
+ if (m_isInitialized || !isVisible() || !openglContext()) return;
if (!m_offscreenSurface.isValid()) {
m_offscreenSurface.setFormat(openglContext()->format());
m_offscreenSurface.create();
+ openglContext()->makeCurrent(this);
}
-}
-
-void GLWidget::initializeGL()
-{
- if (m_isInitialized || !isVisible() || !openglContext()) return;
initializeOpenGLFunctions();
qDebug() << "OpenGL vendor: " << QString::fromUtf8((const char*) glGetString(GL_VENDOR));
qDebug() << "OpenGL renderer: " << QString::fromUtf8((const char*) glGetString(GL_RENDERER));
diff --git a/src/monitor/glwidget.h b/src/monitor/glwidget.h
index dc1e0e2..d12500a 100644
--- a/src/monitor/glwidget.h
+++ b/src/monitor/glwidget.h
@@ -182,7 +182,6 @@ private slots:
void updateTexture(GLuint yName, GLuint uName, GLuint vName);
void paintGL();
void onFrameDisplayed(const SharedFrame &frame);
- void createOffscreen();

protected:
void resizeEvent(QResizeEvent* event);
--
2.10.2

71 changes: 71 additions & 0 deletions kde-apps/kdenlive/kdenlive-16.12.1-r1.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=6

KDE_HANDBOOK="optional"
inherit kde5

DESCRIPTION="Non-linear video editing suite by KDE"
HOMEPAGE="https://www.kdenlive.org/"

LICENSE="GPL-2"
KEYWORDS="~amd64 ~x86"
IUSE="freesound gles2 jogshuttle semantic-desktop v4l"

RDEPEND="
$(add_frameworks_dep karchive)
$(add_frameworks_dep kbookmarks)
$(add_frameworks_dep kcompletion)
$(add_frameworks_dep kconfig)
$(add_frameworks_dep kconfigwidgets)
$(add_frameworks_dep kcoreaddons)
$(add_frameworks_dep kcrash)
$(add_frameworks_dep kdbusaddons)
$(add_frameworks_dep kguiaddons)
$(add_frameworks_dep ki18n)
$(add_frameworks_dep kiconthemes)
$(add_frameworks_dep kio)
$(add_frameworks_dep kitemviews)
$(add_frameworks_dep kjobwidgets)
$(add_frameworks_dep knewstuff)
$(add_frameworks_dep knotifications)
$(add_frameworks_dep knotifyconfig)
$(add_frameworks_dep kservice)
$(add_frameworks_dep ktextwidgets)
$(add_frameworks_dep kwidgetsaddons)
$(add_frameworks_dep kxmlgui)
$(add_frameworks_dep solid)
$(add_qt_dep qtdbus)
$(add_qt_dep qtdeclarative)
$(add_qt_dep qtgui 'gles2=')
$(add_qt_dep qtnetwork)
$(add_qt_dep qtquickcontrols)
$(add_qt_dep qtscript)
$(add_qt_dep qtsvg)
$(add_qt_dep qtwidgets)
$(add_qt_dep qtxml)
>=media-libs/mlt-6.0.0[ffmpeg,kdenlive,melt,qt5,sdl,xml]
virtual/ffmpeg[encode,sdl,X]
virtual/opengl
freesound? ( $(add_qt_dep qtwebkit) )
semantic-desktop? ( $(add_frameworks_dep kfilemetadata) )
v4l? ( media-libs/libv4l )
"
DEPEND="${RDEPEND}
sys-devel/gettext
"

PATCHES=( "${FILESDIR}/${P}-crash.patch" )

src_configure() {
local mycmakeargs=(
$(cmake-utils_use_find_package freesound Qt5WebKitWidgets)
-DWITH_JogShuttle=$(usex jogshuttle)
$(cmake-utils_use_find_package semantic-desktop KF5FileMetaData)
$(cmake-utils_use_find_package v4l LibV4L2)
)

kde5_src_configure
}

0 comments on commit 38ebbd3

Please sign in to comment.