qt6-base: update to 6.4.2.

This commit is contained in:
Đoàn Trần Công Danh 2023-02-17 11:43:09 +07:00
parent 169d2f3450
commit 61ca21f8ee
10 changed files with 102 additions and 77 deletions

View File

@ -1,6 +1,6 @@
--- a/tests/auto/corelib/text/qlocale/tst_qlocale.cpp
+++ b/tests/auto/corelib/text/qlocale/tst_qlocale.cpp
@@ -1453,8 +1453,10 @@ void tst_QLocale::fpExceptions()
--- qt6-base-6.4.2.orig/tests/auto/corelib/text/qlocale/tst_qlocale.cpp
+++ qt6-base-6.4.2/tests/auto/corelib/text/qlocale/tst_qlocale.cpp
@@ -1502,8 +1502,10 @@ void tst_QLocale::fpExceptions()
fenv_t envp;
fegetenv(&envp);
feclearexcept(FE_ALL_EXCEPT);

View File

@ -1,10 +1,10 @@
--- a/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp
+++ b/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp
@@ -229,9 +229,11 @@ void tst_QTextMarkdownImporter::lists_da
--- qt6-base-6.4.2.orig/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp
+++ qt6-base-6.4.2/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp
@@ -204,9 +204,11 @@ void tst_QTextMarkdownImporter::lists_da
QTest::newRow("numeric lists nested in empty lists")
<< "- \n 1. a\n 2. b\n- c\n 1.\n + d\n" << 4 << false
<< "- \n 1. a\n 2. b\n- c 1. + d\n";
+#if 0
+#ifdef __GLIC__
QTest::newRow("styled spans in list items")
<< "1. normal text\n2. **bold** text\n3. `code` in the item\n4. *italic* text\n5. _underlined_ text\n" << 5 << false
<< "1. normal text\n2. **bold** text\n3. `code` in the item\n4. *italic* text\n5. _underlined_ text\n";
@ -12,20 +12,3 @@
}
void tst_QTextMarkdownImporter::lists()
--- a/tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp
@@ -1776,11 +1776,14 @@ void tst_QGraphicsWidget::updateFocusCha
const QPoint center(view.viewport()->width() / 2, view.viewport()->height() / 2);
QTest::mouseMove(view.viewport(), center);
QTest::mouseClick(view.viewport(), Qt::LeftButton, {}, center);
+#if 0
+ // Same sympton with QTBUG-23699
#ifdef Q_OS_MAC
QEXPECT_FAIL("", "QTBUG-23699", Continue);
#endif
QTRY_COMPARE(qApp->activeWindow(), static_cast<QWidget *>(&view));
QTRY_COMPARE(scene.focusItem(), static_cast<QGraphicsItem *>(w));
+#endif
}
void tst_QGraphicsWidget::sizeHint_data()

View File

@ -1,6 +1,6 @@
--- a/qmake/library/ioutils.cpp 2020-09-24 17:55:53.000000000 +0200
+++ b/qmake/library/ioutils.cpp 2020-09-24 17:55:53.000000000 +0200
@@ -40,6 +40,7 @@
--- qt6-base-6.4.2.orig/qmake/library/ioutils.cpp
+++ qt6-base-6.4.2/qmake/library/ioutils.cpp
@@ -15,6 +15,7 @@
# include <unistd.h>
# include <utime.h>
# include <fcntl.h>
@ -8,9 +8,9 @@
# include <errno.h>
#endif
--- a/src/corelib/io/qstorageinfo_unix.cpp 2020-09-24 17:55:53.000000000 +0200
+++ b/src/corelib/io/qstorageinfo_unix.cpp 2020-09-24 17:55:53.000000000 +0200
@@ -58,6 +58,7 @@
--- qt6-base-6.4.2.orig/src/corelib/io/qstorageinfo_unix.cpp
+++ qt6-base-6.4.2/src/corelib/io/qstorageinfo_unix.cpp
@@ -23,6 +23,7 @@
# include <sys/vfs.h>
# include <mntent.h>
#elif defined(Q_OS_LINUX) || defined(Q_OS_HURD)

View File

@ -0,0 +1,19 @@
--- qt6-base-6.4.2.orig/tests/auto/gui/image/qimage/tst_qimage.cpp
+++ qt6-base-6.4.2/tests/auto/gui/image/qimage/tst_qimage.cpp
@@ -1806,6 +1806,8 @@ void tst_QImage::smoothScale2()
QRgb expected = opaque ? qRgb(63, 127, 255) : qRgba(31, 63, 127, 127);
img.fill(expected);
+#ifdef __GLIBC__
+ // broken on musl, unknown reason
// scale x down, y down
QImage scaled = img.scaled(QSize(1, 1), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
QRgb pixel = scaled.pixel(0, 0);
@@ -1869,6 +1871,7 @@ void tst_QImage::smoothScale2()
QCOMPARE(qBlue(pixel), qBlue(expected));
}
}
+#endif
}
static inline int rand8()

View File

@ -6,11 +6,9 @@ This breaks qt6-webengine's search path for translations.
Using realpath instead would probably be a more correct solution.
---
diff --git qtbasesrc/corelib/global/qlibraryinfo.cpp qtbasesrc/corelib/global/qlibraryinfo.cpp
index 8bcf67e73d..28d7355310 100644
--- a/src/corelib/global/qlibraryinfo.cpp
+++ b/src/corelib/global/qlibraryinfo.cpp
@@ -558,6 +558,12 @@ static QString getRelocatablePrefix()
--- qt6-base-6.4.2.orig/src/corelib/global/qlibraryinfo.cpp
+++ qt6-base-6.4.2/src/corelib/global/qlibraryinfo.cpp
@@ -358,6 +358,12 @@ static QString getRelocatablePrefix(QLib
int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
if (result > 0 && info.dli_fname)
prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
@ -21,5 +19,5 @@ index 8bcf67e73d..28d7355310 100644
+ }
+#endif
#elif defined(Q_OS_WIN)
Q_UNUSED(usageMode);
HMODULE hModule = getWindowsModuleHandle();
const int kBufferSize = 4096;

View File

@ -1,6 +1,6 @@
--- a/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
+++ b/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
@@ -607,7 +607,10 @@ void tst_QResourceEngine::lastModified()
--- qt6-base-6.4.2.orig/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
+++ qt6-base-6.4.2/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
@@ -592,7 +592,10 @@ void tst_QResourceEngine::lastModified()
{
QFileInfo fi(":/");
QVERIFY(fi.exists());

View File

@ -1,6 +1,6 @@
--- a/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
+++ b/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
@@ -624,18 +624,14 @@ void tst_QGlobal::qRoundFloats() {
--- qt6-base-6.4.2.orig/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
+++ qt6-base-6.4.2/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
@@ -599,18 +599,14 @@ void tst_QGlobal::qRoundFloats() {
QFETCH(float, expected);
#if !(defined(Q_PROCESSOR_ARM_64) && (__has_builtin(__builtin_round) || defined(Q_CC_GNU)) && !defined(Q_CC_CLANG))
@ -23,7 +23,7 @@
}
void tst_QGlobal::qRoundDoubles_data() {
@@ -653,18 +649,14 @@ void tst_QGlobal::qRoundDoubles() {
@@ -628,18 +624,14 @@ void tst_QGlobal::qRoundDoubles() {
QFETCH(double, expected);
#if !(defined(Q_PROCESSOR_ARM_64) && (__has_builtin(__builtin_round) || defined(Q_CC_GNU)) && !defined(Q_CC_CLANG))

View File

@ -1,6 +1,6 @@
--- a/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp 2022-11-03 00:05:49.281737775 +0100
+++ - 2022-11-03 00:07:52.538145369 +0100
@@ -165,6 +165,8 @@
--- qt6-base-6.4.2.orig/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp
+++ qt6-base-6.4.2/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp
@@ -165,6 +165,8 @@ void tst_QStorageInfo::tempFile()
#ifdef Q_OS_LINUX
if (storage1.fileSystemType() == "btrfs")
QSKIP("This test doesn't work on btrfs, probably due to a btrfs bug");

View File

@ -1,6 +1,6 @@
# Template file for 'qt6-base'
pkgname=qt6-base
version=6.4.0
version=6.4.2
revision=1
build_style=cmake
configure_args="-DINSTALL_DATADIR=share/qt6
@ -13,6 +13,8 @@ configure_args="-DINSTALL_DATADIR=share/qt6
-DINSTALL_SYSCONFDIR=/etc/xdg
-DQT_FEATURE_openssl_linked=ON
-DQT_FEATURE_system_sqlite=ON
-DQT_FEATURE_libproxy=ON
-DQT_FEATURE_qmake=ON
-DBUILD_WITH_PCH=OFF"
hostmakedepends="perl pkg-config xmlstarlet"
makedepends="zlib-devel libzstd-devel dbus-devel
@ -30,13 +32,13 @@ maintainer="John <me@johnnynator.dev>"
license="GPL-3.0-only WITH Qt-GPL-exception-1.0, LGPL-3.0-only, GPL-2.0-or-later"
homepage="https://www.qt.io"
distfiles="https://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtbase-everywhere-src-${version}.tar.xz"
checksum=cb6475a0bd8567c49f7ffbb072a05516ee6671171bed55db75b22b94ead9b37d
checksum=a88bc6cedbb34878a49a622baa79cace78cfbad4f95fdbd3656ddb21c705525d
python_version=3
if [ "$CROSS_BUILD" ]; then
hostmakedepends+=" qt6-base-devel"
hostmakedepends+=" qt6-base"
# QtSetup fails native builds if this is set
configure_args+="-DQT_FORCE_BUILD_TOOLS=true"
configure_args+=" -DQT_FORCE_BUILD_TOOLS=true"
fi
# It is currently expected that quite a few patches do fail
@ -47,47 +49,66 @@ fi
do_check() {
cd build
export QT_QPA_PLATFORM=offscreen
export QMAKESPEC=$wrksrc/mkspecs/linux-g++
local failing_tests="tst_selftests tst_qmake tst_moc
tst_rcc tst_qfile tst_qstandardpaths
tst_qtemporarydir tst_qtemporaryfile tst_qdir
tst_qpluginloader tst_qlibrary tst_qtextstream
tst_qdate tst_qdatetime tst_qtimezone
test_umbrella_config test_wrap_cpp_and_resources
test_dependent_modules test_needsquoting_dirname
test_add_resource_options test_wrap_cpp_options
test_platform_defs_include test_qtmainwin_library
test_dbus_module test_multiple_find_package
test_add_resources_delayed_file test_QTBUG-63422
test_add_binary_resources_delayed_file
test_private_includes test_private_targets
test_testlib_definitions test_json_plugin_includes
test_testlib_no_link_gui test_testlib_no_link_widgets
module_includes test_concurrent_module test_opengl_lib
test_build_simple_widget_app_qmake
test_interface test_interface_link_libraries
test_moc_macro_target test_add_big_resource
test_versionless_targets test_add_resources_binary_generated
test_plugin_flavor_static test_plugin_flavor_shared
test_plugin_flavor_derived_from_qt_type
tst_qaddpreroutine tst_qfont tst_qfontdatabase
tst_qfont tst_qfontdatabase
tst_qfontmetrics tst_qglyphrun tst_qrawfont
tst_qtextdocumentlayout tst_qopenglconfig
tst_qopengl tst_qdnslookup tst_qfiledialog
tst_qopengl tst_qfiledialog
tst_qgraphicsview tst_qapplication tst_qfontcombobox
tst_qlineedit tst_qmenubar tst_qopenglwidget
tst_qx11info tst_qcomplextext
test_QFINDTESTDATA run_test_QFINDTESTDATA"
tst_qaddpreroutine tst_qtextcursor"
# Unknown platform linux-g++ :/
failing_tests+=" mockplugins test_import_plugins
test_static_resources test_generating_cpp_exports"
test_static_resources test_generating_cpp_exports"
failing_tests+=" tst_qstorageinfo"
# broken with -O, passed with -O0, probably broken floating point code.
failing_tests+=" tst_qvectornd"
if [ "$XBPS_TARGET_LIBC" = musl ]; then
# Some glibc specific DNS Lookup
failing_tests+=" tst_qdnslookup"
fi
if [ "$XBPS_TARGET_WORDSIZE" = 32 ]; then
# failing on i686, not checked on arm
failing_tests+=" tst_qvectorrnd"
fi
local ctest_exclude="("
for failure in $failing_tests; do
ctest_exclude+="$failure|"
done
ctest_exclude="${ctest_exclude%|})"
if [ ! -e "$wrksrc/build/include/qt6" ]; then
ln -s .. "$wrksrc/build/include/qt6"
fi
ctest -E "$ctest_exclude"
rm "$wrksrc/build/include/qt6"
}
post_install() {
rm -rf ${DESTDIR}/usr/tests
cat <<-EOF >${DESTDIR}/usr/lib/qt6/bin/target_qt.conf
[Paths]
Prefix=../../../
HostPrefix=/usr
Binaries=lib/qt6/bin
HostBinaries=lib/qt6/bin
Libraries=lib
HostLibraries=lib
LibraryExecutables=lib/qt6/libexec
HostLibraryExecutables=lib/qt6/libexec
ArchData=lib/qt6
HostArchData=lib/qt6
Data=share/qt6
HostData=share/qt6
Sysroot=
SysrootifyPrefix=false
TargetSpec=linux-g++
HostSpec=linux-g++
EOF
}
qt6-gui_package() {
@ -231,11 +252,9 @@ qt6-plugin-tls-qcertonly_package() {
}
qt6-plugin-networkinformation_package() {
short_desc+=" - Networkinformation plugin"
short_desc+=" - NetworkInformation plugin"
pkg_install() {
vmove usr/lib/qt6/plugins/networkinformation/libqnetworkmanager.so
vmove usr/lib/qt6/plugins/networkinformation/libqglib.so
vmove usr/lib/qt6/plugins/networkinformation
}
}
@ -261,8 +280,8 @@ qt6-base-devel_package() {
qt6-plugin-networkinformation>=${version}_${revision}
${makedepends}"
pkg_install() {
local _f
vmove usr/include
vmove usr/lib/cmake
vmove usr/lib/metatypes
vmove usr/lib/pkgconfig
vmove usr/lib/qt6/mkspecs
@ -270,5 +289,11 @@ qt6-base-devel_package() {
vmove "usr/lib/*.so"
vmove "usr/lib/*.prl"
vmove usr/share/qt6/modules
for _f in ${DESTDIR}/usr/lib/cmake/*; do
case "$_f" in
*Tools|*HostInfo) ;;
*) vmove "usr/lib/cmake/${_f##*/}" ;;
esac
done
}
}