Compare commits

..

6 Commits
master ... f28

Author SHA1 Message Date
Rex Dieter 10ce0838ab Merge branch 'f29' into f28 2018-12-30 09:41:09 -06:00
Rex Dieter eb523086ad Merge branch 'f29' into f28 2018-08-21 17:27:32 -05:00
Rex Dieter 7aa1752593 Revert "Add patches to backport fixes of QTBUG-65789 and QTBUG-67019 needed by GCompris-qt"
This reverts commit e03bd20de9.
2018-08-21 17:27:29 -05:00
Rex Dieter d1bf1ade81 Revert "note branch-only commit"
This reverts commit 75247d2d19.
2018-08-21 17:27:27 -05:00
Rex Dieter 75247d2d19 note branch-only commit 2018-06-30 16:29:08 -05:00
Robert-André Mauchin e03bd20de9 Add patches to backport fixes of QTBUG-65789 and QTBUG-67019 needed by GCompris-qt 2018-06-30 17:55:22 +02:00
5 changed files with 165 additions and 45 deletions

3
.gitignore vendored
View File

@ -1,4 +1 @@
/qtdeclarative-everywhere-src-5.11.3.tar.xz
/qtdeclarative-everywhere-src-5.12.1.tar.xz
/qtdeclarative-everywhere-src-5.12.3.tar.xz
/qtdeclarative-everywhere-src-5.12.4.tar.xz

View File

@ -0,0 +1,75 @@
From 4950c366b12265f1ea390a6feb8dbbd0d850d206 Mon Sep 17 00:00:00 2001
From: Guillem Jover <guillem@hadrons.org>
Date: Mon, 12 Oct 2015 01:45:37 +0200
Subject: [PATCH v2] Do not make lack of SSE2 support on x86-32 fatal
When an x86-32 CPU does not have SSE2 support (which is the case for
all AMD CPUs, and older Intel CPUs), fallback to use the interpreter,
otherwise use the JIT engine.
Even then, make the lack of SSE2 support on x86-32 fatal when trying
to instantiate a JIT engine, which does require it.
Refactor the required CPU support check into a new pair of privately
exported functions to avoid duplicating the logic, and do so in
functions instead of class members to avoid changing the class
signatures.
Version: 5.7.x
Bug-Debian: https://bugs.debian.org/792594
---
src/qml/jsruntime/qv4engine.cpp | 1 +
src/qml/qml/v8/qv8engine.cpp | 7 -------
tools/qmljs/qmljs.cpp | 7 +++----
5 files changed, 24 insertions(+), 11 deletions(-)
--- a/src/qml/jsruntime/qv4engine.cpp
+++ b/src/qml/jsruntime/qv4engine.cpp
@@ -160,6 +160,7 @@
#ifdef V4_ENABLE_JIT
static const bool forceMoth = !qEnvironmentVariableIsEmpty("QV4_FORCE_INTERPRETER") ||
+ !JIT::hasRequiredCpuSupport() ||
!OSAllocator::canAllocateExecutableMemory();
if (forceMoth) {
factory = new Moth::ISelFactory;
--- a/src/qml/qml/v8/qv8engine.cpp
+++ b/src/qml/qml/v8/qv8engine.cpp
@@ -64,7 +64,6 @@
#include <QtCore/qjsonvalue.h>
#include <QtCore/qdatetime.h>
#include <QtCore/qdatastream.h>
-#include <private/qsimd_p.h>
#include <private/qv4value_p.h>
#include <private/qv4dateobject_p.h>
@@ -129,12 +128,6 @@
, m_xmlHttpRequestData(0)
, m_listModelData(0)
{
-#ifdef Q_PROCESSOR_X86_32
- if (!qCpuHasFeature(SSE2)) {
- qFatal("This program requires an X86 processor that supports SSE2 extension, at least a Pentium 4 or newer");
- }
-#endif
-
QML_MEMORY_SCOPE_STRING("QV8Engine::QV8Engine");
qMetaTypeId<QJSValue>();
qMetaTypeId<QList<int> >();
--- a/tools/qmljs/qmljs.cpp
+++ b/tools/qmljs/qmljs.cpp
@@ -90,11 +90,10 @@
enum {
use_masm,
use_moth
- } mode;
+ } mode = use_moth;
#ifdef V4_ENABLE_JIT
- mode = use_masm;
-#else
- mode = use_moth;
+ if (QV4::JIT::hasRequiredCpuSupport())
+ mode = use_masm;
#endif
bool runAsQml = false;

View File

@ -1,14 +1,21 @@
%global qt_module qtdeclarative
%if 0%{?fedora} < 29
%ifarch %{ix86}
%global nosse2_hack 1
## TODO:
# * consider debian's approach of runtime detection instead,
# w hen/if their patch is rebased for 5.11.x
%endif
%endif
# definition borrowed from qtbase
%global multilib_archs x86_64 %{ix86} %{?mips} ppc64 ppc s390x s390 sparc64 sparcv9
#global bootstrap 1
Summary: Qt5 - QtDeclarative component
Name: qt5-%{qt_module}
Version: 5.12.4
Release: 3%{?dist}
Version: 5.11.3
Release: 1%{?dist}
# See LICENSE.GPL LICENSE.LGPL LGPL_EXCEPTION.txt, for details
License: LGPLv2 with exceptions or GPLv3 with exceptions
@ -20,10 +27,19 @@ Source0: https://download.qt.io/official_releases/qt/%{majmin}/%{version}/submod
# https://bugzilla.redhat.com/show_bug.cgi?id=1441343
Source5: qv4global_p-multilib.h
# support no_sse2 CONFIG (fedora i686 builds cannot assume -march=pentium4 -msse2 -mfpmath=sse flags, or the JIT that needs them)
# https://codereview.qt-project.org/#change,73710
# inspired by https://build.opensuse.org/package/view_file/KDE:Unstable:Qt/libqt5-qtdeclarative/sse2_nojit.patch
Patch1: qtdeclarative-opensource-src-5.11.0-no_sse2.patch
## upstream patches
## upstreamable patches
# https://codereview.qt-project.org/#/c/127354/
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=792594
#Patch202: https://sources.debian.org/data/main/q/qtdeclarative-opensource-src/5.10.1-4/debian/patches/Do-not-make-lack-of-SSE2-support-on-x86-32-fatal.patch
# filter qml provides
%global __provides_exclude_from ^%{_qt5_archdatadir}/qml/.*\\.so$
@ -35,12 +51,10 @@ BuildRequires: qt5-rpm-macros >= %{version}
BuildRequires: qt5-qtbase-devel >= %{version}
BuildRequires: qt5-qtbase-private-devel
%{?_qt5:Requires: %{_qt5}%{?_isa} = %{_qt5_version}}
BuildRequires: python%{python3_pkgversion}
%if 0%{?bootstrap}
Obsoletes: %{name}-examples < %{version}-%{release}
%global no_examples CONFIG-=compile_examples
%endif
BuildRequires: qt5-qtxmlpatterns-devel >= %{version}
# recommended workaround from:
# https://fedoraproject.org/wiki/Changes/Move_usr_bin_python_into_separate_package
BuildRequires: /usr/bin/python
%if 0%{?tests}
BuildRequires: dbus-x11
@ -76,15 +90,27 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
%prep
%autosetup -n %{qt_module}-everywhere-src-%{version}
%setup -q -n %{qt_module}-everywhere-src-%{version}
%if 0%{?nosse2_hack}
%patch1 -p1 -b .no_sse2
%endif
## FIXME/REBASE
#patch202 -p1 -b .no_sse2_non_fatal
%build
%if 0%{?nosse2_hack}
# build libQt5Qml with no_sse2
mkdir -p %{_target_platform}-no_sse2
pushd %{_target_platform}-no_sse2
%{qmake_qt5} -config no_sse2 ..
make sub-src-clean
%make_build -C src/qml
popd
%endif
# HACK so calls to "python" get what we want
ln -s %{__python3} python
export PATH=`pwd`:$PATH
# no shadow builds until fixed: https://bugreports.qt.io/browse/QTBUG-37417
%qmake_qt5
%make_build
@ -93,6 +119,12 @@ export PATH=`pwd`:$PATH
%install
%make_install INSTALL_ROOT=%{buildroot}
%if 0%{?nosse2_hack}
mkdir -p %{buildroot}%{_qt5_libdir}/sse2
mv %{buildroot}%{_qt5_libdir}/libQt5Qml.so.5* %{buildroot}%{_qt5_libdir}/sse2/
make install INSTALL_ROOT=%{buildroot} -C %{_target_platform}-no_sse2/src/qml
%endif
%ifarch %{multilib_archs}
# multilib: qv4global_p.h
mv %{buildroot}%{_qt5_headerdir}/QtQml/%{version}/QtQml/private/qv4global_p.h \
@ -152,10 +184,12 @@ make check -k -C tests ||:
%files
%license LICENSE.LGPL*
%{_qt5_libdir}/libQt5Qml.so.5*
%if 0%{?nosse2_hack}
%{_qt5_libdir}/sse2/libQt5Qml.so.5*
%endif
%{_qt5_libdir}/libQt5Quick.so.5*
%{_qt5_libdir}/libQt5QuickWidgets.so.5*
%{_qt5_libdir}/libQt5QuickParticles.so.5*
%{_qt5_libdir}/libQt5QuickShapes.so.5*
%{_qt5_libdir}/libQt5QuickTest.so.5*
%{_qt5_plugindir}/qmltooling/
%{_qt5_archdatadir}/qml/
@ -184,36 +218,11 @@ make check -k -C tests ||:
%{_qt5_libdir}/libQt5QmlDebug.a
%{_qt5_libdir}/libQt5QmlDebug.prl
%if ! 0%{?no_examples:1}
%files examples
%{_qt5_examplesdir}/
%endif
%changelog
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 5.12.4-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Tue Jul 16 2019 Rex Dieter <rdieter@fedoraproject.org> - 5.12.4-2
- build with python3
* Fri Jun 14 2019 Jan Grulich <jgrulich@redhat.com> - 5.12.4-1
- 5.12.4
* Tue Jun 04 2019 Jan Grulich <jgrulich@redhat.com> - 5.12.3-1
- 5.12.3
* Fri Mar 15 2019 Rex Dieter <rdieter@fedoraproject.org> - 5.12.1-2
- de-bootstrap
* Mon Feb 04 2019 Rex Dieter <rdieter@fedoraproject.org> - 5.12.1-1
- 5.12.1
- drop remants of sse2 hack support
- add bootstrap support (examples)
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 5.11.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Fri Dec 07 2018 Rex Dieter <rdieter@fedoraproject.org> - 5.11.3-1
- 5.11.3

View File

@ -0,0 +1,39 @@
diff -up qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/jsruntime.pri.no_sse2 qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/jsruntime.pri
--- qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/jsruntime.pri.no_sse2 2018-04-30 06:54:03.000000000 -0500
+++ qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/jsruntime.pri 2018-05-24 16:15:51.151738531 -0500
@@ -115,6 +115,11 @@ SOURCES += \
$$PWD/qv4value.cpp \
$$PWD/qv4executableallocator.cpp
+linux-g++*:isEqual(QT_ARCH,i386):!no_sse2 {
+ QMAKE_CFLAGS += -msse2 -mfpmath=sse
+ QMAKE_CXXFLAGS += -msse2 -mfpmath=sse
+}
+
valgrind {
DEFINES += V4_USE_VALGRIND
}
diff -up qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/qv4global_p.h.no_sse2 qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/qv4global_p.h
--- qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/qv4global_p.h.no_sse2 2018-04-30 06:54:03.000000000 -0500
+++ qtdeclarative-everywhere-src-5.11.0/src/qml/jsruntime/qv4global_p.h 2018-05-24 20:23:38.642642420 -0500
@@ -88,7 +88,7 @@ inline double trunc(double d) { return d
//
// NOTE: This should match the logic in qv4targetplatform_p.h!
-#if defined(Q_PROCESSOR_X86) && (QT_POINTER_SIZE == 4) \
+#if defined(Q_PROCESSOR_X86) && (QT_POINTER_SIZE == 4) && defined(__SSE2__) \
&& (defined(Q_OS_WIN) || defined(Q_OS_LINUX) || defined(Q_OS_QNX) || defined(Q_OS_FREEBSD))
# define V4_ENABLE_JIT
#elif defined(Q_PROCESSOR_X86_64) && (QT_POINTER_SIZE == 8) \
diff -up qtdeclarative-everywhere-src-5.11.0/src/qml/qml/v8/qv8engine.cpp.no_sse2 qtdeclarative-everywhere-src-5.11.0/src/qml/qml/v8/qv8engine.cpp
--- qtdeclarative-everywhere-src-5.11.0/src/qml/qml/v8/qv8engine.cpp.no_sse2 2018-05-24 16:15:51.152738550 -0500
+++ qtdeclarative-everywhere-src-5.11.0/src/qml/qml/v8/qv8engine.cpp 2018-05-24 20:21:01.273574503 -0500
@@ -131,7 +131,7 @@ QV8Engine::QV8Engine(QJSEngine *qq, QV4:
{
#ifdef Q_PROCESSOR_X86_32
if (!qCpuHasFeature(SSE2)) {
- qFatal("This program requires an X86 processor that supports SSE2 extension, at least a Pentium 4 or newer");
+ qDebug("This program requires an X86 processor that supports SSE2 extension, at least a Pentium 4 or newer, processors missing the extension are NOT supported to run QML2 code!");
}
#endif

View File

@ -1 +1 @@
SHA512 (qtdeclarative-everywhere-src-5.12.4.tar.xz) = 953b0dac76b73a7a21b393ab88718da12d77dfc688dc07c55c96ea1658bc14acd9097bef60df4a95d2923d3fb1e02b46499c032aa53844d4fd344b0037514671
SHA512 (qtdeclarative-everywhere-src-5.11.3.tar.xz) = 07d440b10ba2fbd700a191791cb6991fb9ce72c78787340e7f564bdb2bef24b035e15fe2aecd36d58f8794e56bd0aa35d28b350a73707e27748e54d46609e1a0