mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 17:09:10 -07:00
dev-qt/qtdeclarative: tentatively backport fix for musescore
~testing only for now, bit worried because:
1. upstream fix is recent and hasn't been reviewed/merged yet
2. it does not apply to 6.10.3 at all, and I needed to adapt it
myself despite not really knowing C++
I can confirm that musescore works, but unsure if it could have
other negative effects.
Will wait a few days, and if nothing comes up will forward the
keywords to stable.
musescore users in stable may want to add to package.accept_keywords:
=dev-qt/qtdeclarative-6.10.3-r1
Patching may be needed for 6.11.1 later as well, fix may not make it.
Closes: https://bugs.gentoo.org/973374
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
Note that this is a non-official backport which required a bit
|
||||
of adaptation to work with 6.10.3, seems to work but possible
|
||||
overlooked something.
|
||||
|
||||
https://bugs.gentoo.org/973374
|
||||
https://codereview.qt-project.org/c/qt%2Fqtdeclarative/+/733089
|
||||
--- a/src/qml/qml/qqmltypecompiler.cpp
|
||||
+++ b/src/qml/qml/qqmltypecompiler.cpp
|
||||
@@ -5,4 +5,5 @@
|
||||
#include "qqmltypecompiler_p.h"
|
||||
|
||||
+#include <iterator>
|
||||
#include <private/qqmlobjectcreator_p.h>
|
||||
#include <private/qqmlcustomparser_p.h>
|
||||
@@ -919,13 +920,12 @@
|
||||
// Apply the ordering in the IR
|
||||
obj->setFirstAlias(ordered[0]);
|
||||
- if (ordered[0] == defaultPropertyAlias)
|
||||
- obj->indexOfDefaultPropertyOrAlias = 0;
|
||||
- for (qsizetype i = 0, end = ordered.size() - 1; i < end; ++i) {
|
||||
+ for (qsizetype i = 0, end = ordered.size() - 1; i < end; ++i)
|
||||
ordered[i]->next = ordered[i + 1];
|
||||
- if (ordered[i] == defaultPropertyAlias)
|
||||
- obj->indexOfDefaultPropertyOrAlias = i;
|
||||
- }
|
||||
ordered.last()->next = nullptr;
|
||||
|
||||
+ if (defaultPropertyAlias) {
|
||||
+ auto it = std::find(ordered.constBegin(), ordered.constEnd(), defaultPropertyAlias);
|
||||
+ obj->indexOfDefaultPropertyOrAlias = std::distance(ordered.constBegin(), it);
|
||||
+ }
|
||||
return true;
|
||||
}
|
||||
65
dev-qt/qtdeclarative/qtdeclarative-6.10.3-r1.ebuild
Normal file
65
dev-qt/qtdeclarative/qtdeclarative-6.10.3-r1.ebuild
Normal file
@@ -0,0 +1,65 @@
|
||||
# Copyright 2021-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
PYTHON_COMPAT=( python3_{11..14} )
|
||||
QT6_HAS_STATIC_LIBS=1
|
||||
# behaves very badly when qtdeclarative is not already installed, also
|
||||
# other more minor issues (installs junk, sandbox/offscreen issues)
|
||||
QT6_RESTRICT_TESTS=1
|
||||
inherit python-any-r1 qt6-build
|
||||
|
||||
DESCRIPTION="Qt Declarative (Quick 2)"
|
||||
|
||||
if [[ ${QT6_BUILD_TYPE} == release ]]; then
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~x86"
|
||||
fi
|
||||
|
||||
IUSE="accessibility +jit +network opengl qmlls +sql +ssl svg vulkan +widgets"
|
||||
|
||||
RDEPEND="
|
||||
~dev-qt/qtbase-${PV}:6[accessibility=,gui,network=,opengl=,sql?,ssl?,vulkan=,widgets=]
|
||||
qmlls? ( ~dev-qt/qtlanguageserver-${PV}:6 )
|
||||
svg? ( ~dev-qt/qtsvg-${PV}:6 )
|
||||
"
|
||||
DEPEND="
|
||||
${RDEPEND}
|
||||
vulkan? ( dev-util/vulkan-headers )
|
||||
"
|
||||
BDEPEND="
|
||||
${PYTHON_DEPS}
|
||||
~dev-qt/qtshadertools-${PV}:6
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-6.10.3-unity-build.patch
|
||||
"${FILESDIR}"/${PN}-6.10.3-QTBUG-144701.patch
|
||||
)
|
||||
|
||||
src_configure() {
|
||||
local mycmakeargs=(
|
||||
$(cmake_use_find_package qmlls Qt6LanguageServerPrivate)
|
||||
$(cmake_use_find_package sql Qt6Sql)
|
||||
$(cmake_use_find_package svg Qt6Svg)
|
||||
$(qt_feature jit qml_jit)
|
||||
$(qt_feature network qml_network)
|
||||
$(qt_feature ssl qml_ssl)
|
||||
)
|
||||
|
||||
qt6-build_src_configure
|
||||
}
|
||||
|
||||
src_install() {
|
||||
qt6-build_src_install
|
||||
|
||||
if [[ ! -e ${D}${QT6_LIBDIR}/libQt6QuickControls2.so.6 ]]; then #940675
|
||||
eerror "${CATEGORY}/${PF} seems to have been improperly built and"
|
||||
eerror "install was aborted to protect the system. Possibly(?) due"
|
||||
eerror "to a rare portage ordering bug. If using portage, try:"
|
||||
eerror " emerge -1 qtshadertools:6 qtdeclarative:6"
|
||||
eerror "If that did not resolve the issue, please provide build.log"
|
||||
eerror "on https://bugs.gentoo.org/940675"
|
||||
die "aborting due to incomplete/broken build (see above)"
|
||||
fi
|
||||
}
|
||||
Reference in New Issue
Block a user