From: "Miroslav Šulc" <fordfrog@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: media-sound/musescore/files/, media-sound/musescore/
Date: Sat, 4 Jan 2020 14:58:41 +0000 (UTC) [thread overview]
Message-ID: <1578149911.cbcd81d0463012d030b33ed6adc50ec87e5f0c03.fordfrog@gentoo> (raw)
commit: cbcd81d0463012d030b33ed6adc50ec87e5f0c03
Author: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 4 14:58:14 2020 +0000
Commit: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org>
CommitDate: Sat Jan 4 14:58:31 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cbcd81d0
media-sound/musescore: fixed compilation against qt 5.14
Closes: https://bugs.gentoo.org/703706
Package-Manager: Portage-2.3.84, Repoman-2.3.20
Signed-off-by: Miroslav Šulc <fordfrog <AT> gentoo.org>
media-sound/musescore/files/5583.patch | 212 +++++++++++++++++++++++++++
media-sound/musescore/musescore-3.3.3.ebuild | 3 +-
media-sound/musescore/musescore-3.3.4.ebuild | 3 +-
media-sound/musescore/musescore-9999.ebuild | 3 +-
4 files changed, 218 insertions(+), 3 deletions(-)
diff --git a/media-sound/musescore/files/5583.patch b/media-sound/musescore/files/5583.patch
new file mode 100644
index 00000000000..da4d0c52d04
--- /dev/null
+++ b/media-sound/musescore/files/5583.patch
@@ -0,0 +1,212 @@
+From 09d138946aad53962ce23298093747f0ce52304f Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= <jerome.duval@gmail.com>
+Date: Tue, 31 Dec 2019 17:39:34 +0100
+Subject: [PATCH 1/2] Specializes template routines.
+
+Qt 5.14 introduces serialisation/deserialisation for enum classes,
+this results in ambiguous templates between qdatastream.h and preferences.h.
+we specialize everything to workaround this.
+---
+ mscore/preferences.h | 41 ++++++++++++++++++++++++++++++++++++-----
+ 1 file changed, 36 insertions(+), 5 deletions(-)
+
+diff --git a/mscore/preferences.h b/mscore/preferences.h
+index bef3df8536..8c3ac9b0ed 100644
+--- a/mscore/preferences.h
++++ b/mscore/preferences.h
+@@ -233,21 +233,52 @@ extern Preferences preferences;
+
+ // Stream operators for enum classes
+ // enum classes don't play well with QSettings without custom serialization
+-template<typename T, typename std::enable_if<std::is_enum<T>::value>::type* = nullptr>
+-inline QDataStream &operator<<(QDataStream &out, const T &val)
++inline QDataStream&
++operator<<(QDataStream &out, const Ms::MuseScoreStyleType &val)
+ {
+ return out << static_cast<int>(val);
+ }
+
+-template<typename T, typename std::enable_if<std::is_enum<T>::value>::type* = nullptr>
+-inline QDataStream &operator>>(QDataStream &in, T &val)
++inline QDataStream&
++operator>>(QDataStream &in, Ms::MuseScoreStyleType &val)
+ {
+ int tmp;
+ in >> tmp;
+- val = static_cast<T>(tmp);
++ val = static_cast<Ms::MuseScoreStyleType>(tmp);
+ return in;
+ }
+
++inline QDataStream&
++operator<<(QDataStream &out, const Ms::SessionStart &val)
++{
++ return out << static_cast<int>(val);
++}
++
++inline QDataStream&
++operator>>(QDataStream &in, Ms::SessionStart &val)
++{
++ int tmp;
++ in >> tmp;
++ val = static_cast<Ms::SessionStart>(tmp);
++ return in;
++}
++
++inline QDataStream&
++operator<<(QDataStream &out, const Ms::MusicxmlExportBreaks &val)
++{
++ return out << static_cast<int>(val);
++}
++
++inline QDataStream&
++operator>>(QDataStream &in, Ms::MusicxmlExportBreaks &val)
++{
++ int tmp;
++ in >> tmp;
++ val = static_cast<Ms::MusicxmlExportBreaks>(tmp);
++ return in;
++}
++
++
+ class PreferenceVisitor {
+ public:
+ virtual void visit(QString key, IntPreference*) = 0;
+
+From 6b759bb5ee7b83fd8a82429e4cdb74279c5d33b6 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= <jerome.duval@gmail.com>
+Date: Tue, 31 Dec 2019 17:42:04 +0100
+Subject: [PATCH 2/2] fix warnings: replace QString::null, with QString()
+
+---
+ mscore/capella.cpp | 2 +-
+ mscore/importmidi/importmidi.cpp | 2 +-
+ mscore/instrdialog.cpp | 2 +-
+ mscore/musescore.cpp | 12 ++++++------
+ mscore/musescore.h | 2 +-
+ mscore/network/loginmanager.cpp | 2 +-
+ 6 files changed, 11 insertions(+), 11 deletions(-)
+
+diff --git a/mscore/capella.cpp b/mscore/capella.cpp
+index 7144414e32..6243c8cca6 100644
+--- a/mscore/capella.cpp
++++ b/mscore/capella.cpp
+@@ -2708,7 +2708,7 @@ Score::FileError importCapella(MasterScore* score, const QString& name)
+ QMessageBox::warning(0,
+ QWidget::tr("Import Capella"),
+ QWidget::tr("Load failed: %1").arg(cf.error(errNo)),
+- QString::null, QWidget::tr("Quit"), QString::null, 0, 1);
++ QString(), QWidget::tr("Quit"), QString(), 0, 1);
+ }
+ fp.close();
+ // avoid another error message box
+diff --git a/mscore/importmidi/importmidi.cpp b/mscore/importmidi/importmidi.cpp
+index a5d8894686..8091a83369 100644
+--- a/mscore/importmidi/importmidi.cpp
++++ b/mscore/importmidi/importmidi.cpp
+@@ -1200,7 +1200,7 @@ Score::FileError importMidi(MasterScore *score, const QString &name)
+ QMessageBox::warning(0,
+ QWidget::tr("Load MIDI"),
+ QWidget::tr("Load failed: %1").arg(errorText),
+- QString::null, QWidget::tr("Quit"), QString::null, 0, 1);
++ QString(), QWidget::tr("Quit"), QString(), 0, 1);
+ }
+ fp.close();
+ qDebug("importMidi: bad file format");
+diff --git a/mscore/instrdialog.cpp b/mscore/instrdialog.cpp
+index fa7bacd622..8d81fe9e20 100644
+--- a/mscore/instrdialog.cpp
++++ b/mscore/instrdialog.cpp
+@@ -138,7 +138,7 @@ void InstrumentsDialog::on_loadButton_clicked()
+ QMessageBox::warning(0,
+ QWidget::tr("Load Style Failed"),
+ QString(strerror(errno)),
+- QString::null, QWidget::tr("Quit"), QString::null, 0, 1);
++ QString(), QWidget::tr("Quit"), QString(), 0, 1);
+ return;
+ }
+ instrumentsWidget->buildTemplateList();
+diff --git a/mscore/musescore.cpp b/mscore/musescore.cpp
+index dd4a4b95ca..07cb596abe 100644
+--- a/mscore/musescore.cpp
++++ b/mscore/musescore.cpp
+@@ -4013,7 +4013,7 @@ bool MuseScore::readLanguages(const QString& path)
+ QMessageBox::warning(0,
+ QWidget::tr("Load Languages Failed:"),
+ error,
+- QString::null, QWidget::tr("Quit"), QString::null, 0, 1);
++ QString(), QWidget::tr("Quit"), QString(), 0, 1);
+ return false;
+ }
+
+@@ -6753,7 +6753,7 @@ bool MuseScore::saveMp3(Score* score, const QString& name)
+ QMessageBox::warning(0,
+ tr("Encoding Error"),
+ tr("Unable to open target file for writing"),
+- QString::null, QString::null);
++ QString(), QString());
+ }
+ return false;
+ }
+@@ -6792,7 +6792,7 @@ bool MuseScore::saveMp3(Score* score, QIODevice* device, bool& wasCanceled)
+ QMessageBox::warning(0,
+ tr("Error Opening LAME library"),
+ tr("Could not open MP3 encoding library!"),
+- QString::null, QString::null);
++ QString(), QString());
+ qDebug("Could not open MP3 encoding library!");
+ return false;
+ }
+@@ -6804,7 +6804,7 @@ bool MuseScore::saveMp3(Score* score, QIODevice* device, bool& wasCanceled)
+ QMessageBox::warning(0,
+ tr("Error Opening LAME library"),
+ tr("Not a valid or supported MP3 encoding library!"),
+- QString::null, QString::null);
++ QString(), QString());
+ qDebug("Not a valid or supported MP3 encoding library!");
+ return false;
+ }
+@@ -6829,7 +6829,7 @@ bool MuseScore::saveMp3(Score* score, QIODevice* device, bool& wasCanceled)
+ if (!MScore::noGui) {
+ QMessageBox::warning(0, tr("Encoding Error"),
+ tr("Unable to initialize MP3 stream"),
+- QString::null, QString::null);
++ QString(), QString());
+ }
+ qDebug("Unable to initialize MP3 stream");
+ MScore::sampleRate = oldSampleRate;
+@@ -6996,7 +6996,7 @@ bool MuseScore::saveMp3(Score* score, QIODevice* device, bool& wasCanceled)
+ QMessageBox::warning(0,
+ tr("Encoding Error"),
+ tr("Error %1 returned from MP3 encoder").arg(bytes),
+- QString::null, QString::null);
++ QString(), QString());
+ break;
+ }
+ else
+diff --git a/mscore/musescore.h b/mscore/musescore.h
+index 434072a12f..d8089a345c 100644
+--- a/mscore/musescore.h
++++ b/mscore/musescore.h
+@@ -142,7 +142,7 @@ struct LanguageItem {
+ LanguageItem(const QString k, const QString n) {
+ key = k;
+ name = n;
+- handbook = QString::null;
++ handbook = QString();
+ }
+ LanguageItem(const QString k, const QString n, const QString h) {
+ key = k;
+diff --git a/mscore/network/loginmanager.cpp b/mscore/network/loginmanager.cpp
+index 7bcfd892e0..4abf7e3e4e 100644
+--- a/mscore/network/loginmanager.cpp
++++ b/mscore/network/loginmanager.cpp
+@@ -680,7 +680,7 @@ void LoginManager::mediaUploadFinished()
+ QMessageBox::warning(0,
+ tr("Upload Error"),
+ tr("Sorry, MuseScore couldn't upload the audio file. Error %1").arg(e),
+- QString::null, QString::null);
++ QString(), QString());
+ }
+ }
+
diff --git a/media-sound/musescore/musescore-3.3.3.ebuild b/media-sound/musescore/musescore-3.3.3.ebuild
index cd4bca0639e..e0e03cdcb56 100644
--- a/media-sound/musescore/musescore-3.3.3.ebuild
+++ b/media-sound/musescore/musescore-3.3.3.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -54,6 +54,7 @@ RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}/${PN}-3.0.1-man-pages.patch"
+ "${FILESDIR}/5583.patch"
)
S="${WORKDIR}/MuseScore-${PV}"
diff --git a/media-sound/musescore/musescore-3.3.4.ebuild b/media-sound/musescore/musescore-3.3.4.ebuild
index cd4bca0639e..e0e03cdcb56 100644
--- a/media-sound/musescore/musescore-3.3.4.ebuild
+++ b/media-sound/musescore/musescore-3.3.4.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -54,6 +54,7 @@ RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}/${PN}-3.0.1-man-pages.patch"
+ "${FILESDIR}/5583.patch"
)
S="${WORKDIR}/MuseScore-${PV}"
diff --git a/media-sound/musescore/musescore-9999.ebuild b/media-sound/musescore/musescore-9999.ebuild
index 6b06e3b852c..cbaf17ea641 100644
--- a/media-sound/musescore/musescore-9999.ebuild
+++ b/media-sound/musescore/musescore-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -54,6 +54,7 @@ RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}/${PN}-3.0.1-man-pages.patch"
+ "${FILESDIR}/5583.patch"
)
src_unpack() {
next reply other threads:[~2020-01-04 14:58 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-04 14:58 Miroslav Šulc [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-08-27 9:12 [gentoo-commits] repo/gentoo:master commit in: media-sound/musescore/files/, media-sound/musescore/ Miroslav Šulc
2024-08-04 11:24 Miroslav Šulc
2024-08-04 11:16 Miroslav Šulc
2024-08-04 10:14 Miroslav Šulc
2023-01-09 15:07 Sam James
2023-01-09 12:03 Sam James
2021-02-28 11:47 Miroslav Šulc
2020-10-17 9:07 Miroslav Šulc
2020-08-06 13:28 Miroslav Šulc
2020-04-02 12:59 Miroslav Šulc
2020-03-04 16:19 Miroslav Šulc
2019-04-28 23:45 Andreas Sturmlechner
2019-02-01 19:50 Miroslav Šulc
2018-12-24 0:51 Andreas Sturmlechner
2018-08-21 21:23 Andreas Sturmlechner
2018-08-21 21:23 Andreas Sturmlechner
2018-08-17 22:04 Andreas Sturmlechner
2017-12-09 23:13 Michał Górny
2017-07-30 15:45 David Seifert
2017-01-30 13:20 Johannes Huber
2017-01-04 10:15 David Seifert
2016-11-29 8:29 David Seifert
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1578149911.cbcd81d0463012d030b33ed6adc50ec87e5f0c03.fordfrog@gentoo \
--to=fordfrog@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox