Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
Please login to access the resource
openSUSE:Factory:Rebuild
QMPlay2
0001-add-opensuse-customizations.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0001-add-opensuse-customizations.patch of Package QMPlay2
From: Simon Vogl <simon.vogl@gmx.net> Date: Tue, 7 Dec 2021 21:41:49 UTC Subject: [PATCH] Fix broken python detection of QMPlay2 when it tries to launch youtube-dl This patch is required to prevent QMPlay2 from always preferring python2 over python3 which can lead to crashes in certain cases. It also adds openSUSE branding to the about screen. --- a/src/qmplay2/YouTubeDL.cpp +++ b/src/qmplay2/YouTubeDL.cpp @@ -467,29 +467,9 @@ QString program = m_ytDlPath; #ifndef Q_OS_WIN - QFile ytDlFile(program); - if (ytDlFile.open(QFile::ReadOnly)) - { - const auto shebang = ytDlFile.readLine(99).trimmed(); - const int idx = shebang.lastIndexOf("python"); - if (shebang.startsWith("#!") && idx > -1) - { - const auto pythonCmd = shebang.mid(idx); - if (QStandardPaths::findExecutable(pythonCmd).endsWith(pythonCmd)) - { - args.prepend(program); - program = pythonCmd; - } -#ifdef Q_OS_MACOS - else if (QFileInfo(QString("/usr/local/bin/" + pythonCmd)).isExecutable()) - { - args.prepend(program); - program = "/usr/local/bin/" + pythonCmd; - } -#endif - } - ytDlFile.close(); - } + //Enforce execution command as "python3", disable automatic detection + args.prepend(program); + program = "python3"; #endif m_process.start(program, args); --- a/src/gui/AboutWidget.cpp +++ b/src/gui/AboutWidget.cpp @@ -49,6 +49,7 @@ labelText += ", " + QGuiApplication::platformName(); #endif labelText += ")"; + labelText += "<br/><b>This release was supplied by SUSE/openSUSE.</b>"; QLabel *label = new QLabel(labelText); QLabel *iconL = new QLabel;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor