Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] [wip] qt6: update to 6.2 (alpha)
@ 2021-06-27 19:18 Johnnynator
  2021-06-27 19:20 ` [PR PATCH] [Updated] " Johnnynator
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: Johnnynator @ 2021-06-27 19:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2512 bytes --]

There is a new pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 120611 bytes --]

From a169ab9c53d284c7389a64c1369661fca5661838 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Daniel=20N=C3=A9ri?= <dne+github@mayonnaise.net>
Date: Sun, 27 Jun 2021 00:05:14 +0000
Subject: [PATCH 01/25] tailscale: update to 1.10.0.

---
 srcpkgs/tailscale/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/tailscale/template b/srcpkgs/tailscale/template
index 27fb51011812..598429ea085e 100644
--- a/srcpkgs/tailscale/template
+++ b/srcpkgs/tailscale/template
@@ -1,6 +1,6 @@
 # Template file for 'tailscale'
 pkgname=tailscale
-version=1.8.5
+version=1.10.0
 revision=1
 build_style=go
 go_import_path="tailscale.com"
@@ -14,7 +14,7 @@ maintainer="Noel Cower <ncower@nil.dev>"
 license="BSD-3-Clause"
 homepage="https://tailscale.com"
 distfiles="https://github.com/tailscale/tailscale/archive/v${version}.tar.gz"
-checksum=f3a558f3006f0182dc12bd3f346a2f66e6f8389fcfa3e42f2b78e496bfc331ad
+checksum=8345fc01fd07d3fa325817104b373bbdd54568ef807135e9d5eafa5321fa7f87
 
 post_install() {
 	vlicense LICENSE

From 945a006369c7c4f2b431f5347aa78249e9e2591c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 02/25] qt6-3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..9a45c8c011ef 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt3d-everywhere-src-${version}"
+wrksrc="qt3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - 3d"
 maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=8fff7ac79b3f508df00bfc4e14e401b1dde0a5bc1d67d3cb88c05b04ac12aa1b
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 782625d45ea9ff1cff4a696c216329ec91ca8540 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 03/25] qt6-base: update to 6.2.0alpha.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 +++++++++++++++++++
 srcpkgs/qt6-base/template                     | 16 ++++++------
 2 files changed, 33 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index bb043213a360..fad36fe8bc70 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtbase-everywhere-src-${version}"
+wrksrc="qtbase-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
  -DINSTALL_ARCHDATADIR=lib/qt6
@@ -27,8 +27,8 @@ short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtbase-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=eb18d8fc5b5136ab0d177d89c54ec197363904fedb2aecb0d87033ce78ddffcc
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -84,10 +84,10 @@ qt6-gui_package() {
 	short_desc+=" - Gui"
 	pkg_install() {
 		vmove "usr/lib/libQt6Gui.so.*"
-		vmove "usr/lib/libQt6XcbQpa.so.*"
-		vmove "usr/lib/libQt6EglFSDeviceIntegration.so.*"
-		vmove "usr/lib/libQt6EglFsKmsGbmSupport.so.*"
-		vmove "usr/lib/libQt6EglFsKmsSupport.so.*"
+		vmove "usr/lib/libQt6XcbQpaPrivate.so.*"
+		vmove "usr/lib/libQt6EglFSDeviceIntegrationPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsGbmSupportPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsSupportPrivate.so.*"
 		vmove "usr/lib/libQt6OpenGL.so.*"
 		vmove usr/lib/qt6/plugins/generic
 		vmove usr/lib/qt6/plugins/platforms

From fcfa7c78e478144ad8008e5c83b1cceae844477b Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 04/25] qt6-charts: update to 6.2.0alpha.

---
 srcpkgs/qt6-charts/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..1beaf0dbecfd 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtcharts-everywhere-src-${version}"
+wrksrc="qtcharts-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - charts"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtcharts-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=294205bc1e855bb44a0e17c707b981c617fc08d55d071e1d02441ff5a4e7e676
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 0028f19ff4ea75b0c68e505bed2ac3a3119d04c1 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 05/25] qt6-declarative: update to 6.2.0alpha.

---
 srcpkgs/qt6-declarative/template | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..bef006df96f0 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,23 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtdeclarative-everywhere-src-${version}"
+wrksrc="qtdeclarative-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel qt6-declarative-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtdeclarative-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=4fd2d9448620586862e56149c43ef93b6dddcb60d6f211ab933bed984d1f1d8a
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +37,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}

From 7b311a0017ce60f4bfd8914e51049e9befc776b5 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 06/25] qt6-imageformats: update to 6.2.0alpha.

---
 srcpkgs/qt6-imageformats/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..8207913c89f9 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtimageformats-everywhere-src-${version}"
+wrksrc="qtimageformats-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - imageformats"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtimageformats-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=6e4a3690b5de83733f9a4ad492784b33748684cd99e98aa7cd3c30c97faa2bae

From 34d09a16564ded75f1bb51e7cc3869b54afe7cbb Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 07/25] qt6-lottie: update to 6.2.0alpha.

---
 srcpkgs/qt6-lottie/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..0a55513d0cb8 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtlottie-everywhere-src-${version}"
+wrksrc="qtlottie-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - lottie"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlottie-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=07e01a8993866abcb372cc8569d299f79cc6a91ebf66a5a85a5abe722527eadc
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 6073498f41816f1a870e018f8f51b94949bf7460 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 08/25] qt6-networkauth: update to 6.2.0alpha.

---
 srcpkgs/qt6-networkauth/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..654a2bb0fd69 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtnetworkauth-everywhere-src-${version}"
+wrksrc="qtnetworkauth-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - networkauth"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtnetworkauth-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=75784d38da1d476b209c3151dbd9afda0708fdcfbfd48d09a520754a442ccda6
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 08e90f20b9c6a9144bdfd0838370851ede390838 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 09/25] qt6-qt5compat: update to 6.2.0alpha.

---
 srcpkgs/qt6-qt5compat/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index d64b37bff575..0567c1b374e5 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt5compat-everywhere-src-${version}"
+wrksrc="qt5compat-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Compo
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt5compat-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=210dbe079b51ba47841219fde59ad11a8e77a4a851a73b77121153ed03afb473
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 6f67688b5c75a273ccec942a7fb45a82e7824d9c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 10/25] qt6-quick3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-quick3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..673ec342450f 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquick3d-everywhere-src-${version}"
+wrksrc="qtquick3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel qt6-shadertools-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - Quick3d"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquick3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=b60012e2d3d4b9d62cbddd84b56dcae985bc7b111b551d0eadd06551772db806
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From d7ebf34d78a5eb5bbdf0ef7671e609382468cb55 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:16 +0200
Subject: [PATCH 11/25] qt6-quickcontrols2: update to 6.2.0alpha.

---
 srcpkgs/qt6-quickcontrols2/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
index ab57102a19cf..efd4972c669c 100644
--- a/srcpkgs/qt6-quickcontrols2/template
+++ b/srcpkgs/qt6-quickcontrols2/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quickcontrols2'
 pkgname=qt6-quickcontrols2
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
+wrksrc="qtquickcontrols2-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quickcontrols2"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-2.0-or-later, LGPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquickcontrols2-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=40c8af99adb342c45809bfe06c73ac7d923433518cb7bc7997f6fc40e169c4c5
 
 qt6-quickcontrols2-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"

From bd636b7a59adad7671b098a74b46a96fc643ef5d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 12/25] qt6-quicktimeline: update to 6.2.0alpha.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..bc0225e767bc 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquicktimeline-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e5b024adf9ae291004b5273465757583796c989f317e3bc62366953f02c7a89a
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 98e438415f6e17803a530d079d67f1f7551dff1c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 13/25] qt6-scxml: update to 6.2.0alpha.

---
 srcpkgs/qt6-scxml/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..f8324f91a3d7 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtscxml-everywhere-src-${version}"
+wrksrc="qtscxml-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - scxml"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtscxml-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e29a333477e84d407421096fd2d90bccfb95ae4b8d0ed0d0785586e56cfa9d0c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 583e2350be1253b38877afb8a1254284e5ec2359 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 14/25] qt6-shadertools: update to 6.2.0alpha.

---
 srcpkgs/qt6-shadertools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..42fa436708a6 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtshadertools-everywhere-src-${version}"
+wrksrc="qtshadertools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - shadertools"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtshadertools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=08144fa6d96c4382e47b3203d27f999b86d4ed1f1b828e09a48614f32b12ee59
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From 41fa91fdc3a1bca9120cf848e6afdfd0e2f803a5 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 15/25] qt6-svg: update to 6.2.0alpha.

---
 srcpkgs/qt6-svg/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..c37793e0613b 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtsvg-everywhere-src-${version}"
+wrksrc="qtsvg-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-svg componen
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtsvg-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=dd7c5312b8430130103d91908bd5f19fa2c6bf01c76acb757e5974603b3769c8
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 95b0f9af9ad7f5c8dc9f9495e014fa7c1f4e0607 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 16/25] qt6-tools: update to 6.2.0alpha.

---
 srcpkgs/qt6-tools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..0e7a9126bcf7 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttools-everywhere-src-${version}"
+wrksrc="qttools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-tools compon
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=32596431f71f7b4bbcd05e86c0490f97bf68b66e560337e5418a7faee5d86e84
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From c8784540312c4ab6c946b9e623571f4db7dc0c77 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 17/25] qt6-translations: update to 6.2.0alpha.

---
 srcpkgs/qt6-translations/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..c8be8fe68426 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttranslations-everywhere-src-${version}"
+wrksrc="qttranslations-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel qt6-tools-devel perl"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - translations"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttranslations-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=0fecd5d3e8f8823d1c77e95fbbac80c084b08df5a02f06fe71b2af6ceceb87ad

From f61a7493a0ed503ddeee391a47353376cb3854dc Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 18/25] qt6-virtualkeyboard: update to 6.2.0alpha.

---
 srcpkgs/qt6-virtualkeyboard/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..c5034fa3e95d 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
+wrksrc="qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
@@ -13,8 +13,8 @@ short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=1675dad7cd41fddb593d1fcf0a6d2a7c0f27ae9962232cba8a0a94dd38044320
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From e2f270803e509a6f4ad715dbd44d72d4080358c8 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 19/25] qt6-wayland: update to 6.2.0alpha.

---
 srcpkgs/qt6-wayland/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..77c5eecd2551 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtwayland-everywhere-src-${version}"
+wrksrc="qtwayland-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel qt6-wayland-devel"
@@ -14,8 +14,8 @@ short_desc="Cross-platform application and UI framework - Wayland"
 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwayland-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=71209da169478c6ea3555f8e55edd9fe9d758ac9826c404af2a5e912a8fcfa5d
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From b322227f06e9774a872f2d98040d705cf1365b41 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:16:54 +0200
Subject: [PATCH 20/25] New package: qt6-serialport-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-serialport-devel    |  1 +
 srcpkgs/qt6-serialport/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-serialport-devel
 create mode 100644 srcpkgs/qt6-serialport/template

diff --git a/common/shlibs b/common/shlibs
index 8a7eef8df8c3..eb023b6275aa 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2060,6 +2060,7 @@ libQt6Help.so.6 qt6-tools-6.1.0_1
 libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
+libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-serialport-devel b/srcpkgs/qt6-serialport-devel
new file mode 120000
index 000000000000..f6a498cf2653
--- /dev/null
+++ b/srcpkgs/qt6-serialport-devel
@@ -0,0 +1 @@
+qt6-serialport
\ No newline at end of file
diff --git a/srcpkgs/qt6-serialport/template b/srcpkgs/qt6-serialport/template
new file mode 100644
index 000000000000..45e5915979cc
--- /dev/null
+++ b/srcpkgs/qt6-serialport/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-serialport'
+pkgname=qt6-serialport
+version=6.2.0alpha
+revision=1
+wrksrc="qtserialport-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel pkg-config"
+makedepends="qt6-base-devel"
+short_desc="Cross-platform application and UI framework - serialport"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtserialport-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=51129c6964c42668e2ea205f1fcb0e0ea099aaeae74607112957343afb531863
+
+qt6-serialport-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From cd74e1273d5b658e7e46bfc6654c55e55a0d213f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:23:48 +0200
Subject: [PATCH 21/25] New package: qt6-websockets-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-websockets-devel    |  1 +
 srcpkgs/qt6-websockets/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-websockets-devel
 create mode 100644 srcpkgs/qt6-websockets/template

diff --git a/common/shlibs b/common/shlibs
index eb023b6275aa..69227af2267f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2061,6 +2061,7 @@ libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
+libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-websockets-devel b/srcpkgs/qt6-websockets-devel
new file mode 120000
index 000000000000..a3c674e42954
--- /dev/null
+++ b/srcpkgs/qt6-websockets-devel
@@ -0,0 +1 @@
+qt6-websockets
\ No newline at end of file
diff --git a/srcpkgs/qt6-websockets/template b/srcpkgs/qt6-websockets/template
new file mode 100644
index 000000000000..6177426904ae
--- /dev/null
+++ b/srcpkgs/qt6-websockets/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-websockets'
+pkgname=qt6-websockets
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebsockets-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel"
+short_desc="Cross-platform application and UI framework - websockets"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebsockets-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=f8277d05192ee5f823356a6c6b72ea816a0187f6a0915b783605bee9549a8761
+
+qt6-websockets-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 157a42de6ef78b662b4ae568e2b9440a7bc194c1 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:25:04 +0200
Subject: [PATCH 22/25] New package: qt6-webchannel-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-webchannel-devel    |  1 +
 srcpkgs/qt6-webchannel/template | 28 ++++++++++++++++++++++++++++
 3 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-webchannel-devel
 create mode 100644 srcpkgs/qt6-webchannel/template

diff --git a/common/shlibs b/common/shlibs
index 69227af2267f..e6d1ef7157b4 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2062,6 +2062,7 @@ libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
+libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-webchannel-devel b/srcpkgs/qt6-webchannel-devel
new file mode 120000
index 000000000000..03e8b23d785d
--- /dev/null
+++ b/srcpkgs/qt6-webchannel-devel
@@ -0,0 +1 @@
+qt6-webchannel
\ No newline at end of file
diff --git a/srcpkgs/qt6-webchannel/template b/srcpkgs/qt6-webchannel/template
new file mode 100644
index 000000000000..a1d217810c90
--- /dev/null
+++ b/srcpkgs/qt6-webchannel/template
@@ -0,0 +1,28 @@
+# Template file for 'qt6-webchannel'
+pkgname=qt6-webchannel
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebchannel-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel qt6-websockets-devel"
+short_desc="Cross-platform application and UI framework - webchannel"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebchannel-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=68fd3f0508b6df69b5736d7e142509131f3728630abdcd432a06430e5ca8920c
+
+qt6-webchannel-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1
+	 qt6-websockets-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 0dd36f8635e032ca87f03eab1cc64831b791fb01 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 21:08:25 +0200
Subject: [PATCH 23/25] New package: qt6-multimedia-6.2.0alpha

---
 srcpkgs/qt6-multimedia-devel    |  1 +
 srcpkgs/qt6-multimedia/template | 29 +++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-multimedia-devel
 create mode 100644 srcpkgs/qt6-multimedia/template

diff --git a/srcpkgs/qt6-multimedia-devel b/srcpkgs/qt6-multimedia-devel
new file mode 120000
index 000000000000..9343446502d0
--- /dev/null
+++ b/srcpkgs/qt6-multimedia-devel
@@ -0,0 +1 @@
+qt6-multimedia
\ No newline at end of file
diff --git a/srcpkgs/qt6-multimedia/template b/srcpkgs/qt6-multimedia/template
new file mode 100644
index 000000000000..41a25959361e
--- /dev/null
+++ b/srcpkgs/qt6-multimedia/template
@@ -0,0 +1,29 @@
+# Template file for 'qt6-multimedia'
+pkgname=qt6-multimedia
+version=6.2.0alpha
+revision=1
+wrksrc="qtmultimedia-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_FEATURE_gstreamer=ON"
+hostmakedepends="perl qt6-declarative-devel pkg-config
+ qt6-shadertools-devel"
+makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
+ qt6-shadertools-devel libglib-devel gst-plugins-base1-devel"
+short_desc="Cross-platform application and UI framework - multimedia"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtmultimedia-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=9241fe9456c04ba1feaffd74883d37155c0218baf8aa9fc3dd54642791f378cd
+
+qt6-multimedia-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From c58ed734db40dc0aa08b551c0b53be44c517f2ce Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 00:35:33 +0200
Subject: [PATCH 24/25] New package: qt6-webengine-6.2.0alpha

---
 srcpkgs/qt6-webengine-devel                   |   1 +
 srcpkgs/qt6-webengine/files/resolv_compat.h   |  29 ++
 ...-compilation-support-to-cmake-builds.patch | 474 ++++++++++++++++++
 .../patches/0001-mus-cstring.patch            |  10 +
 ...use-target-C-XX-FLAGS-for-host-cmake.patch |  26 +
 .../patches/0002-None-no-debug.patch          |  11 +
 ...reg.h-to-get-__WORDSIZE-on-musl-libc.patch |  26 +
 .../patches/0003-musl-dispatch-to-musl.patch  | 103 ++++
 .../patches/0004-musl-no-mallinfo.patch       |  39 ++
 .../patches/0005-musl-off_t.patch             |  10 +
 .../patches/0006-musl-pread-pwrite.patch      |  18 +
 .../patches/0008-musl-resolve.patch           |  26 +
 .../patches/0009-musl-siginfo_t.patch         |  18 +
 .../patches/0010-musl-stackstart.patch        |  20 +
 .../patches/0011-musl-sandbox.patch           |  71 +++
 ...0012-musl-chromium-default-stacksize.patch |  15 +
 .../0014-musl-cross-no-asm_ptrace_h.patch     |  30 ++
 .../patches/0015-no-glibc-cmake-check.patch   |  14 +
 .../patches/0016-qt-musl-execinfo.patch       | 106 ++++
 .../0017-qt-musl-thread-stacksize.patch       |  26 +
 .../patches/0018-sandbox-membarrier.patch     |  60 +++
 .../patches/0020-msgvec-push_back.patch       |  14 +
 .../patches/0021-sandbox-sched_getparam.patch |  26 +
 .../0022-canonicalize-file-name-musl.patch    |  11 +
 .../patches/0089-enable-ppc64.patch           |  37 ++
 .../qt6-webengine/patches/0110-size_t.patch   |  16 +
 .../patches/0111-armv7l-neon.patch            |  10 +
 .../patches/0112-arm-user_vfp.patch           |  20 +
 .../patches/0113-arm-elf_auxv_t.patch         |  18 +
 .../qt6-webengine/patches/0114-time64.patch   |  89 ++++
 .../patches/0121-glibc-2.33.patch             | 144 ++++++
 srcpkgs/qt6-webengine/template                |  93 ++++
 32 files changed, 1611 insertions(+)
 create mode 120000 srcpkgs/qt6-webengine-devel
 create mode 100644 srcpkgs/qt6-webengine/files/resolv_compat.h
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0110-size_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0114-time64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
 create mode 100644 srcpkgs/qt6-webengine/template

diff --git a/srcpkgs/qt6-webengine-devel b/srcpkgs/qt6-webengine-devel
new file mode 120000
index 000000000000..8e4d1b99c587
--- /dev/null
+++ b/srcpkgs/qt6-webengine-devel
@@ -0,0 +1 @@
+qt6-webengine
\ No newline at end of file
diff --git a/srcpkgs/qt6-webengine/files/resolv_compat.h b/srcpkgs/qt6-webengine/files/resolv_compat.h
new file mode 100644
index 000000000000..4f0e852a19d0
--- /dev/null
+++ b/srcpkgs/qt6-webengine/files/resolv_compat.h
@@ -0,0 +1,29 @@
+#if !defined(__GLIBC__)
+/***************************************************************************
+ * resolv_compat.h
+ *
+ * Mimick GLIBC's res_ninit() and res_nclose() for musl libc
+ * Note: res_init() is actually deprecated according to
+ * http://docs.oracle.com/cd/E36784_01/html/E36875/res-nclose-3resolv.html
+ **************************************************************************/
+#include <string.h>
+
+static inline int res_ninit(res_state statp)
+{
+	int rc = res_init();
+	if (statp != &_res) {
+		memcpy(statp, &_res, sizeof(*statp));
+	}
+	return rc;
+}
+
+static inline int res_nclose(res_state statp)
+{
+	if (!statp)
+		return -1;
+	if (statp != &_res) {
+		memset(statp, 0, sizeof(*statp));
+	}
+	return 0;
+}
+#endif
diff --git a/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
new file mode 100644
index 000000000000..c70f219e5f4d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
@@ -0,0 +1,474 @@
+From 7a22a424ff2997f644d930050635db214c068d10 Mon Sep 17 00:00:00 2001
+From: Michal Klocek <michal.klocek@qt.io>
+Date: Sun, 23 May 2021 17:39:28 +0200
+Subject: [PATCH 1/2] Add cross compilation support to cmake builds
+
+Add arm cross-compile basic support. CMake does not
+support host builds. However we do host build with gn and
+changing that would require an extra effort to keep all necessary
+changes with Chromium upstream. Therefore let gn to perform
+the host build for required tools and just feed gn with all the
+build data.
+
+Add new build steps:
+
+* install gn into QT_HOST_PATH/libexec.
+* run hostBuild project to get native architecture and compiler
+* call PkgConfigHost to pass pkg-config paths to gn
+* create wrapper script for host pkg-config to escape
+  yocto shell pkg config exports
+
+This change also splits gn toolchain into 3 toolchains host,target,v8
+Now hostBuild provides host and v8 toolchain in case of cross compile.
+
+The build optimizations will follow in another patch.
+
+Note this is tested only with yocto based images.
+
+Pick-to: dev
+Task-number: QTBUG-91760
+Change-Id: Ic2bea12229acc71fbd36a848e9ed4fed7e14b485
+---
+ CMakeLists.txt                           | 37 ++++++++++++++++--
+ cmake/FindGn.cmake                       |  9 +++--
+ cmake/FindNinja.cmake                    |  4 +-
+ cmake/FindPkgConfigHost.cmake            | 40 ++++++++++++++++++++
+ cmake/Functions.cmake                    | 45 ++++++++++++++++++++++
+ configure.cmake                          | 10 ++++-
+ src/core/CMakeLists.txt                  | 48 ++++++++++++++++++------
+ src/core/api/configure.cmake             | 10 ++---
+ src/core/configure/BUILD.toolchain.gn.in | 32 ++--------------
+ src/core/configure/CMakeLists.txt        | 35 +++++++++++++++++
+ 10 files changed, 215 insertions(+), 55 deletions(-)
+ create mode 100644 cmake/FindPkgConfigHost.cmake
+ create mode 100644 src/core/configure/CMakeLists.txt
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 8a3ff75c..2a93dca5 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -63,6 +63,7 @@ add_subdirectory(src/process)
+ add_subdirectory(src/webenginewidgets)
+ add_subdirectory(src/webenginequick)
+ qt_build_repo_end()
++get_install_config(installConfig)
+ 
+ ### NINJA
+ 
+@@ -94,9 +95,10 @@ if(NOT Gn_FOUND)
+                    -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
+                    -DCMAKE_PREFIX_PATH:PATH=<INSTALL_DIR>
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+-)
++    )
+ endif()
+ 
++
+ ### LIBS
+ 
+ # on windows source path can be specified without hard drive letter,
+@@ -115,12 +117,14 @@ endif()
+ list(TRANSFORM featureList PREPEND "-D")
+ list(APPEND libsCmakeArgs
+         "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}"
+-        "-DWEBENGINE_ROOT_BUILD_PATH=${CMAKE_CURRENT_BINARY_DIR}"
++        "-DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}"
+         "-DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}"
+         "-DWEBENGINE_REPO_BUILD=TRUE"
+         "${featureList}"
+ )
+-
++if(QT_HOST_PATH)
++    list(APPEND libsCmakeArgs "-DQT_HOST_PATH=${QT_HOST_PATH}")
++endif()
+ if(LINUX)
+     set(cmd "${CMAKE_COMMAND} --build ${CMAKE_CURRENT_BINARY_DIR}/src")
+     file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/src/build.sh CONTENT "ulimit -n 4096 && ${cmd}\n")
+@@ -210,3 +214,30 @@ if(NOT QT_FEATURE_framework)
+         DESTINATION ${CMAKE_INSTALL_PREFIX}
+     )
+ endif()
++
++### CROSS BUILD SETUP
++
++# install gn for cross build
++# TODO: is this really needed, should we skip it and just build gn as host build ?
++if(LINUX AND NOT Gn_FOUND OR INSTALL_GN)
++    set(INSTALL_GN 1 CACHE INTERNAL "")
++    install(
++        PROGRAMS ${installDir}/bin/gn
++        CONFIGURATIONS ${installConfig}
++        RUNTIME DESTINATION "${INSTALL_LIBEXECDIR}"
++    )
++endif()
++
++if(CMAKE_CROSSCOMPILING)
++    externalproject_add(hostBuild
++        SOURCE_DIR  ${CMAKE_CURRENT_LIST_DIR}/src/core/configure
++        BINARY_DIR  ${CMAKE_CURRENT_BINARY_DIR}/configure
++        PREFIX      cross
++        USES_TERMINAL_BUILD ON
++        CMAKE_ARGS -DCMAKE_TOOLCHAIN_FILE=${QT_HOST_PATH}/lib/cmake/Qt6/qt.toolchain.cmake
++                   -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
++                   -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
++                   -DGN_TARGET_CPU=${TEST_architecture_arch}
++    )
++    externalproject_add_stepdependencies(libs install hostBuild)
++endif()
+diff --git a/cmake/FindGn.cmake b/cmake/FindGn.cmake
+index 12a90778..abfa0fe2 100644
+--- a/cmake/FindGn.cmake
++++ b/cmake/FindGn.cmake
+@@ -1,9 +1,10 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/../..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
++endif()
++find_program(Gn_EXECUTABLE NAMES gn PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
++if(NOT QT_HOST_PATH STREQUAL "")
++   find_program(Gn_EXECUTABLE NAMES gn PATHS ${QT_HOST_PATH}/${INSTALL_LIBEXECDIR} NO_DEFAULT_PATH)
+ endif()
+-
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
+-
+ find_program(Gn_EXECUTABLE NAMES gn)
+ 
+ if(Gn_EXECUTABLE)
+diff --git a/cmake/FindNinja.cmake b/cmake/FindNinja.cmake
+index 3615d58b..720e7326 100644
+--- a/cmake/FindNinja.cmake
++++ b/cmake/FindNinja.cmake
+@@ -1,8 +1,8 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
+ endif()
+ 
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
++find_program(Ninja_EXECUTABLE NAMES ninja ninja-build PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
+ find_program(Ninja_EXECUTABLE NAMES ninja ninja-build)
+ 
+ if(Ninja_EXECUTABLE)
+diff --git a/cmake/FindPkgConfigHost.cmake b/cmake/FindPkgConfigHost.cmake
+new file mode 100644
+index 00000000..de021638
+--- /dev/null
++++ b/cmake/FindPkgConfigHost.cmake
+@@ -0,0 +1,40 @@
++# this is just simply pkg config wrapper to pass executable path to gn
++
++if(CMAKE_CROSSCOMPILING)
++   # find pkg-config, use PKG_CONFIG_HOST if set
++   if((NOT PKG_CONFIG_HOST_EXECUTABLE) AND (NOT "$ENV{PKG_CONFIG_HOST}" STREQUAL ""))
++       set(PKG_CONFIG_HOST_EXECUTABLE "$ENV{PKG_CONFIG_HOST}" CACHE FILEPATH "pkg-config host executable")
++   endif()
++
++   find_program(PKG_CONFIG_HOST_EXECUTABLE NAMES "pkg-config" DOC "pkg-config executable"
++       NO_SYSTEM_ENVIRONMENT_PATH
++       NO_CMAKE_FIND_ROOT_PATH
++   )
++
++   if(PKG_CONFIG_HOST_EXECUTABLE)
++       mark_as_advanced(PKG_CONFIG_HOST_EXECUTABLE)
++       execute_process(COMMAND ${PKG_CONFIG_HOST_EXECUTABLE} --version
++           OUTPUT_VARIABLE PKG_CONFIG_HOST_VERSION_STRING
++           OUTPUT_STRIP_TRAILING_WHITESPACE
++           ERROR_QUIET)
++   endif ()
++
++   include(FindPackageHandleStandardArgs)
++   find_package_handle_standard_args(PkgConfigHost
++       FOUND_VAR PkgConfigHost_FOUND
++       VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++       REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++   )
++else() # if not corss build simply wrap FindPkgConfig
++   find_package(PkgConfig)
++   if(PKG_CONFIG_FOUND)
++       include(FindPackageHandleStandardArgs)
++       set(PKG_CONFIG_HOST_VERSION ${PKG_CONFIG_VERSION})
++       set(PKG_CONFIG_HOST_EXECUTABLE ${PKG_CONFIG_EXECUTABLE})
++       find_package_handle_standard_args(PkgConfigHost
++           FOUND_VAR PkgConfigHost_FOUND
++           VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++           REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++       )
++  endif()
++endif()
+diff --git a/cmake/Functions.cmake b/cmake/Functions.cmake
+index d29ed7a4..3cdfdee9 100644
+--- a/cmake/Functions.cmake
++++ b/cmake/Functions.cmake
+@@ -348,3 +348,48 @@ function(qt_internal_add_external_project_dependency_to_root_project name)
+ 
+     cmake_policy(POP)
+ endfunction()
++
++function(get_gn_arch result arch)
++   if("${arch}" STREQUAL "i386")
++      set(${result} "x86" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "x86_64")
++      set(${result} "x64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm")
++      set(${result} "arm" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm64")
++      set(${result} "arm64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel")
++      set(${result} "mipsel" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel64")
++      set(${result} "mips64el" PARENT_SCOPE)
++   else()
++      message(DEBUG "Unsupported achitecture: ${arch}")
++   endif()
++endfunction()
++
++function(get_v8_arch result targetArch)
++   set(list32 i386 arm mipsel)
++   if("${targetArch}" IN_LIST list32)
++       set(${result} "i386" PARENT_SCOPE)
++   else()
++       set(${result} "x86_64" PARENT_SCOPE)
++   endif()
++endfunction()
++
++function(configure_gn_toolchain name cpuType v8CpuType toolchainIn toolchainOut)
++    set(GN_TOOLCHAIN ${name})
++    get_gn_arch(GN_CPU ${cpuType})
++    get_gn_arch(GN_V8_CPU ${v8CpuType})
++    configure_file(${toolchainIn} ${toolchainOut}/BUILD.gn @ONLY)
++endfunction()
++
++function(create_pkg_config_host_wrapper wrapperName wrapperCmd)
++    file(WRITE ${wrapperName}
++        "#!/bin/sh\n"
++        "unset PKG_CONFIG_LIBDIR\n"
++        "unset PKG_CONFIG_PATH\n"
++        "unset PKG_CONFIG_SYSROOT_DIR\n"
++        "exec ${wrapperCmd} \"$@\""
++    )
++    file(CHMOD ${wrapperName} PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE)
++endfunction()
+diff --git a/configure.cmake b/configure.cmake
+index 53392313..2a8552d7 100644
+--- a/configure.cmake
++++ b/configure.cmake
+@@ -333,9 +333,17 @@ endif()
+ assertTargets(webEngineError webEngineSupport Gui Widgets OpenGL OpenGLWidgets Quick Qml)
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION (LINUX AND NOT CMAKE_CROSSCOMPILING) OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
++   CONDITION LINUX OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
+    MESSAGE "Build can be done only on Linux, Windows or macOS."
+ )
++if(LINUX AND CMAKE_CROSSCOMPILING)
++   get_gn_arch(testArch ${TEST_architecture_arch})
++   add_check_for_support(webEngineError webEngineSupport
++       MODULE QtWebEngine
++       CONDITION testArch
++       MESSAGE "Cross compiling is not supported for ${TEST_architecture_arch}."
++   )
++endif()
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+    CONDITION NOT QT_FEATURE_static
+diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
+index fd935fe1..40d7fd8e 100644
+--- a/src/core/CMakeLists.txt
++++ b/src/core/CMakeLists.txt
+@@ -24,6 +24,11 @@ find_package(Nodejs 12.0)
+ find_package(PkgConfig)
+ if(PkgConfig_FOUND)
+     pkg_check_modules(XSCRNSAVER xscrnsaver)
++    find_package(PkgConfigHost)
++    if(CMAKE_CROSSCOMPILING)
++        create_pkg_config_host_wrapper("${buildDir}/pkg-config-host_wrapper.sh" "${PKG_CONFIG_HOST_EXECUTABLE}")
++        set(PKG_CONFIG_HOST_EXECUTABLE "${buildDir}/pkg-config-host_wrapper.sh")
++    endif()
+ endif()
+ 
+ get_target_property(qtWebEngineProcessName WebEngineCore QTWEBENGINEPROCESS_NAME)
+@@ -36,6 +41,24 @@ else()
+     set(configs ${CMAKE_BUILD_TYPE})
+ endif()
+ 
++##
++#   TOOLCHAIN SETUP
++##
++
++if(LINUX)
++    if(NOT CMAKE_CROSSCOMPILING) # delivered by hostBuild project
++        configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/host_toolchain)
++        configure_gn_toolchain(v8 ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/v8_toolchain)
++    endif()
++    configure_gn_toolchain(target ${TEST_architecture_arch} ${TEST_architecture_arch}
++        ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++        ${buildDir}/target_toolchain)
++endif()
++
+ foreach(config ${configs})
+ 
+ ##
+@@ -250,12 +273,6 @@ foreach(config ${configs})
+     configure_gn_target(${buildGn} ${config}
+         ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.root.gn.in ${buildDir}/${config}/BUILD.gn)
+ 
+-##
+-#   TOOLCHAIN SETUP
+-##
+-
+-    configure_file(${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
+-        ${buildDir}/${config}/toolchain/BUILD.gn @ONLY)
+ 
+ ##
+ #   GN CALL PARAMETERS SETUP
+@@ -419,6 +436,15 @@ foreach(config ${configs})
+         )
+     endif()
+     if(LINUX)
++        get_gn_arch(cpu ${TEST_architecture_arch})
++        if(CMAKE_CROSSCOMPILING)
++            list(APPEND gnArgArg target_cpu="${cpu}")
++        else()
++            list(APPEND gnArgArg host_cpu="${cpu}")
++        endif()
++        if(CMAKE_SYSROOT)
++            list(APPEND gnArgArg target_sysroot="${CMAKE_SYSROOT}")
++        endif()
+         list(APPEND gnArgArg
+             use_cups=false
+             use_gio=false
+@@ -435,11 +461,11 @@ foreach(config ${configs})
+             ozone_platform_external=true
+             ozone_platform="qt"
+             ozone_extra_path="${CMAKE_CURRENT_LIST_DIR}/ozone/ozone_extra.gni"
+-            custom_toolchain="${buildDir}/${config}/toolchain:target"
+-            host_toolchain="${buildDir}/${config}/toolchain:host"
+-            host_cpu="x64"
+-            pkg_config="pkg-config"
+-            host_pkg_config="/usr/bin/pkg-config"
++            custom_toolchain="${buildDir}/target_toolchain:target"
++            host_toolchain="${buildDir}/host_toolchain:host"
++            v8_snapshot_toolchain="${buildDir}/v8_toolchain:v8"
++            pkg_config="${PKG_CONFIG_EXECUTABLE}"
++            host_pkg_config="${PKG_CONFIG_HOST_EXECUTABLE}"
+             use_glib=false
+         )
+         set(systemLibs libjpeg libpng freetype harfbuzz libevent libwebp libxml
+diff --git a/src/core/api/configure.cmake b/src/core/api/configure.cmake
+index 35d28e87..0cf46bf0 100644
+--- a/src/core/api/configure.cmake
++++ b/src/core/api/configure.cmake
+@@ -143,11 +143,11 @@ qt_configure_add_summary_entry(
+     CONDITION UNIX
+ )
+ qt_configure_end_summary_section() # end of "Qt WebEngineCore" section
+-qt_configure_add_report_entry(
+-    TYPE WARNING
+-    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
+-    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
+-)
++#qt_configure_add_report_entry(
++#    TYPE WARNING
++#    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
++#    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
++#)
+ qt_configure_add_report_entry(
+     TYPE WARNING
+     MESSAGE "V8 snapshot cannot be built. Most likely, the 32-bit host compiler does not work. Please make sure you have 32-bit devel environment installed."
+diff --git a/src/core/configure/BUILD.toolchain.gn.in b/src/core/configure/BUILD.toolchain.gn.in
+index e44fa42d..c1bf3845 100644
+--- a/src/core/configure/BUILD.toolchain.gn.in
++++ b/src/core/configure/BUILD.toolchain.gn.in
+@@ -1,6 +1,6 @@
+ import("//build/config/sysroot.gni")
+ import("//build/toolchain/gcc_toolchain.gni")
+-gcc_toolchain("host") {
++gcc_toolchain("@GN_TOOLCHAIN@") {
+   cc = "@CMAKE_C_COMPILER@"
+   cxx = "@CMAKE_CXX_COMPILER@"
+   ld = "@CMAKE_CXX_COMPILER@"
+@@ -9,34 +9,8 @@ gcc_toolchain("host") {
+   extra_cppflags = ""
+   toolchain_args = {
+     current_os = "linux"
+-    current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+-}
+-gcc_toolchain("v8_snapshot") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
+-    v8_current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+- }
+-gcc_toolchain("target") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
++    current_cpu = "@GN_CPU@"
++    v8_current_cpu = "@GN_V8_CPU@"
+     is_clang = false
+     use_gold = false
+   }
+diff --git a/src/core/configure/CMakeLists.txt b/src/core/configure/CMakeLists.txt
+new file mode 100644
+index 00000000..0ae4b4b4
+--- /dev/null
++++ b/src/core/configure/CMakeLists.txt
+@@ -0,0 +1,35 @@
++cmake_minimum_required(VERSION 3.19)
++
++if(NOT DEFINED WEBENGINE_ROOT_SOURCE_DIR)
++    get_filename_component(WEBENGINE_ROOT_SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/../../.." REALPATH)
++endif()
++if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
++    get_filename_component(WEBENGINE_ROOT_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}/../../.." REALPATH)
++endif()
++
++include(${WEBENGINE_ROOT_SOURCE_DIR}/.cmake.conf)
++include(${WEBENGINE_ROOT_SOURCE_DIR}/cmake/Functions.cmake)
++
++set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${WEBENGINE_ROOT_SOURCE_DIR}/cmake")
++
++project(QtWebEngineConfigure
++    VERSION "${QT_REPO_MODULE_VERSION}"
++    LANGUAGES CXX C)
++
++find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals Core)
++
++set(buildDir ${CMAKE_CURRENT_BINARY_DIR})
++configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/host_toolchain
++)
++install(FILES ${buildDir}/host_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/host_toolchain
++    )
++get_v8_arch(GN_V8_HOST_CPU ${GN_TARGET_CPU})
++configure_gn_toolchain(v8 ${GN_V8_HOST_CPU} ${GN_TARGET_CPU}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/v8_toolchain)
++install(FILES ${buildDir}/v8_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/v8_toolchain
++)
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
new file mode 100644
index 000000000000..d4b22c77ce96
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/mojo/public/cpp/platform/named_platform_channel_posix.cc	2021-03-08 10:30:42.504006604 +0100
++++ -	2021-03-08 10:31:27.415366585 +0100
+@@ -8,6 +8,7 @@
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <unistd.h>
++#include <cstring>
+ 
+ #include "base/files/file_util.h"
+ #include "base/files/scoped_file.h"
diff --git a/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
new file mode 100644
index 000000000000..de6d5abb4461
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
@@ -0,0 +1,26 @@
+From 8eece1b0c72bef7319069703031543ddd0ca87ee Mon Sep 17 00:00:00 2001
+From: John Zimmermann <me@johnnynator.dev>
+Date: Sun, 27 Jun 2021 20:35:15 +0200
+Subject: [PATCH 2/2] Do not use target C{XX}FLAGS for host cmake
+
+Change-Id: Ia66d153fa9f1aff63491f6a1ec7380b8bda1e3c7
+---
+ CMakeLists.txt | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 2a93dca5..2a8e6cfb 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -238,6 +238,8 @@ if(CMAKE_CROSSCOMPILING)
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+                    -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
+                    -DGN_TARGET_CPU=${TEST_architecture_arch}
++                   -DCMAKE_CXX_FLAGS=$ENV{CXXFLAGS_FOR_BUILD}
++                   -DCMAKE_C_FLAGS=$ENV{CFLAGS_FOR_BUILD}
+     )
+     externalproject_add_stepdependencies(libs install hostBuild)
+ endif()
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
new file mode 100644
index 000000000000..4a428fe03b37
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
@@ -0,0 +1,11 @@
+--- a/src/core/CMakeLists.txt	2021-06-27 14:24:18.812840134 +0200
++++ b/src/core/CMakeLists.txt	2021-06-27 14:51:46.825108637 +0200
+@@ -299,6 +299,8 @@
+         endif()
+     elseif(${config} STREQUAL "MinSizeRel")
+         list(APPEND gnArgArg is_debug=false symbol_level=0 optimize_for_size=true)
++    elseif(${config} STREQUAL "None")
++        list(APPEND gnArgArg is_debug=false symbol_level=0)
+     endif()
+ 
+     list(APPEND gnArgArg
diff --git a/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
new file mode 100644
index 000000000000..da4160b21bd3
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
@@ -0,0 +1,26 @@
+From 9001c54d6b974449174a8cee8f3f5d78a9bd6c9e Mon Sep 17 00:00:00 2001
+From: Felix Janda <felix.janda@posteo.de>
+Date: Sun, 1 Feb 2015 14:26:52 +0100
+Subject: [PATCH 3/6] include <sys/reg.h> to get __WORDSIZE on musl libc
+
+---
+ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/common/linux/elf_core_dump.h b/src/common/linux/elf_core_dump.h
+index d03c7a8..02eb391 100644
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
+@@ -36,6 +36,9 @@
+ #include <elf.h>
+ #include <link.h>
+ #include <stddef.h>
++#ifndef __GLIBC__
++#include <sys/reg.h>
++#endif
+ 
+ #include "common/memory_range.h"
+ 
+-- 
+2.0.5
+
diff --git a/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
new file mode 100644
index 000000000000..de32a3dab95c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
@@ -0,0 +1,103 @@
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+@@ -6,6 +6,7 @@
+ 
+ #include <malloc.h>
+ 
++#if defined(__GLIBC__)
+ // This translation unit defines a default dispatch for the allocator shim which
+ // routes allocations to libc functions.
+ // The code here is strongly inspired from tcmalloc's libc_override_glibc.h.
+@@ -73,3 +74,92 @@ const AllocatorDispatch AllocatorDispatch::default_dispatch = {
+     nullptr,               /* free_definite_size_function */
+     nullptr,               /* next */
+ };
++
++#else // defined(__GLIBC__)
++
++#include <dlfcn.h>
++
++extern "C" {
++// Declare function pointers to the memory functions
++typedef void* (*t_libc_malloc)(size_t size);
++typedef void* (*t_libc_calloc)(size_t n, size_t size);
++typedef void* (*t_libc_realloc)(void* address, size_t size);
++typedef void* (*t_libc_memalign)(size_t alignment, size_t size);
++typedef void (*t_libc_free)(void* ptr);
++typedef size_t (*t_libc_malloc_usable_size)(void* ptr);
++
++// Static instances of pointers to libc.so dl symbols
++static t_libc_malloc libc_malloc = NULL;
++static t_libc_calloc libc_calloc = NULL;
++static t_libc_realloc libc_realloc = NULL;
++static t_libc_memalign libc_memalign = NULL;
++static t_libc_free libc_free = NULL;
++static t_libc_malloc_usable_size libc_malloc_usable_size = NULL;
++
++// resolve the symbols in libc.so
++void musl_libc_memory_init(void)
++{
++  libc_malloc = (t_libc_malloc) dlsym(RTLD_NEXT, "malloc");
++  libc_calloc = (t_libc_calloc) dlsym(RTLD_NEXT, "calloc");
++  libc_realloc = (t_libc_realloc) dlsym(RTLD_NEXT, "realloc");
++  libc_memalign = (t_libc_memalign) dlsym(RTLD_NEXT, "memalign");
++  libc_free = (t_libc_free) dlsym(RTLD_NEXT, "free");
++  libc_malloc_usable_size = (t_libc_malloc_usable_size) dlsym(RTLD_NEXT, "malloc_usable_size");
++}
++}  // extern "C"
++
++namespace {
++
++using base::allocator::AllocatorDispatch;
++
++void* MuslMalloc(const AllocatorDispatch*, size_t size, void* context) {
++  if (!libc_malloc)
++    musl_libc_memory_init();
++  return (*libc_malloc)(size);
++}
++
++void* MuslCalloc(const AllocatorDispatch*, size_t n, size_t size, void* context) {
++  if (!libc_calloc)
++    musl_libc_memory_init();
++  return (*libc_calloc)(n, size);
++}
++
++void* MuslRealloc(const AllocatorDispatch*, void* address, size_t size, void* context) {
++  if (!libc_realloc)
++    musl_libc_memory_init();
++  return (*libc_realloc)(address, size);
++}
++
++void* MuslMemalign(const AllocatorDispatch*, size_t alignment, size_t size, void* context) {
++  if (!libc_memalign)
++    musl_libc_memory_init();
++  return (*libc_memalign)(alignment, size);
++}
++
++void MuslFree(const AllocatorDispatch*, void* address, void* context) {
++  if (!libc_free)
++    musl_libc_memory_init();
++  (*libc_free)(address);
++}
++
++size_t MuslGetSizeEstimate(const AllocatorDispatch*, void* address, void* context) {
++  // TODO(siggi, primiano): malloc_usable_size may need redirection in the
++  //     presence of interposing shims that divert allocations.
++  if (!libc_malloc_usable_size)
++    musl_libc_memory_init();
++  return (*libc_malloc_usable_size)(address);
++}
++
++}  // namespace
++
++const AllocatorDispatch AllocatorDispatch::default_dispatch = {
++    &MuslMalloc,           /* alloc_function */
++    &MuslCalloc,           /* alloc_zero_initialized_function */
++    &MuslMemalign,         /* alloc_aligned_function */
++    &MuslRealloc,          /* realloc_function */
++    &MuslFree,             /* free_function */
++    &MuslGetSizeEstimate,  /* get_size_estimate_function */
++    nullptr,               /* next */
++};
++
++#endif
diff --git a/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
new file mode 100644
index 000000000000..36900f907833
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
@@ -0,0 +1,39 @@
+--- qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2017-11-28 14:06:53.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2018-01-27 20:13:26.960932805 +0100
+@@ -243,7 +243,7 @@
+   allocated_objects_count = main_heap_info.block_count;
+ #elif defined(OS_FUCHSIA)
+ // TODO(fuchsia): Port, see https://crbug.com/706592.
+-#else
++#elif defined(__GLIBC__)
+   struct mallinfo info = mallinfo();
+   DCHECK_GE(info.arena + info.hblkhd, info.uordblks);
+ 
+@@ -255,6 +255,8 @@
+ 
+   // Total allocated space is given by |uordblks|.
+   allocated_objects_size = info.uordblks;
++#else
++// musl libc does not support mallinfo()
+ #endif
+ 
+   MemoryAllocatorDump* outer_dump = pmd->CreateAllocatorDump("malloc");
+--- qtwebengine/src/3rdparty/chromium/base/process/process_metrics_posix.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:03:38.579424720 +0100
+@@ -119,14 +119,14 @@
+   malloc_statistics_t stats = {0};
+   malloc_zone_statistics(nullptr, &stats);
+   return stats.size_in_use;
+-#elif defined(OS_LINUX) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
++#elif (defined(OS_LINUX) && defined(__GLIBC__)) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
+   struct mallinfo minfo = mallinfo();
+ #if BUILDFLAG(USE_TCMALLOC)
+   return minfo.uordblks;
+ #else
+   return minfo.hblkhd + minfo.arena;
+ #endif
+-#elif defined(OS_FUCHSIA)
++#else //if defined(OS_FUCHSIA) // also musl doesn't do this.
+   // TODO(fuchsia): Not currently exposed. https://crbug.com/735087.
+   return 0;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
new file mode 100644
index 000000000000..52db3b9ebf46
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
@@ -0,0 +1,10 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-05-26 14:58:54.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-10-01 14:31:30.885000000 +0200
+@@ -21,6 +21,7 @@
+ #define htons(x) _byteswap_ushort (x)
+ #else
+ #include <arpa/inet.h>
++#include <sys/types.h>
+ #include <stdint.h>
+ #endif
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
new file mode 100644
index 000000000000..00017bba0172
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
@@ -0,0 +1,18 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:26.639964100 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:11.611964995 +0200
+@@ -1794,6 +1794,15 @@
+ /* End of s390/s390x definitions                                             */
+ #endif
+ 
++#ifndef __GLIBC__
++  /* For Musl libc pread/pread is the same as pread64/pwrite64 */
++#ifndef __NR_pread
++#define __NR_pread              __NR_pread64
++#endif
++#ifndef __NR_pwrite
++#define __NR_pwrite             __NR_pwrite64
++#endif
++#endif /* ifndef __GLIBC__ */
+ 
+ /* After forking, we must make sure to only call system calls.               */
+ #if defined(__BOUNDED_POINTERS__)
diff --git a/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
new file mode 100644
index 000000000000..edfceb79f30a
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
@@ -0,0 +1,26 @@
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-12-20 03:33:11.749059656 +0100
+@@ -9,6 +9,10 @@
+ 
+ #include <resolv.h>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/lazy_instance.h"
+ #include "base/logging.h"
+ #include "base/macros.h"
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-12-20 03:40:07.671953098 +0100
+@@ -6,6 +6,10 @@
+ 
+ #include <string>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/bind.h"
+ #include "base/files/file.h"
+ #include "base/files/file_path.h"
diff --git a/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
new file mode 100644
index 000000000000..fe760be16664
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
@@ -0,0 +1,18 @@
+There's a subtle difference in the internal name of siginfo_t fields
+between glibc and musl. The structure itself is equivalent, so it
+should suffice to add a macro to rename the field.
+
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-02-17 05:57:43.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-06-03 08:20:25.032716427 +0200
+@@ -22,6 +22,11 @@
+ #include "sandbox/linux/services/android_ucontext.h"
+ #endif
+
++// musl libc defines siginfo_t __si_fields instead of _sifields
++#if !defined(__GLIBC__)
++#define _sifields __si_fields
++#endif
++
+ namespace {
+
+ const int kCapacityIncrement = 20;
diff --git a/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
new file mode 100644
index 000000000000..a9f8ab6c252c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
@@ -0,0 +1,20 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:08:43.586475349 +0100
++++ qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:18:22.274505203 +0100
+@@ -28,7 +28,7 @@
+ // FIXME: On Mac OSX and Linux, this method cannot estimate stack size
+ // correctly for the main thread.
+ 
+-#elif defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#elif defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   // pthread_getattr_np() can fail if the thread is not invoked by
+   // pthread_create() (e.g., the main thread of blink_unittests).
+@@ -96,7 +96,7 @@
+ }
+ 
+ void* GetStackStart() {
+-#if defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#if defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   pthread_attr_t attr;
+   int error;
diff --git a/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
new file mode 100644
index 000000000000..d3de1e41183d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
@@ -0,0 +1,71 @@
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-09-13 19:53:53.453780253 +0200
+@@ -129,7 +129,7 @@
+ // CLONE_VM, nor CLONE_THREAD, which includes all fork() implementations.
+ ResultExpr RestrictCloneToThreadsAndEPERMFork() {
+   const Arg<unsigned long> flags(0);
+-
++#if defined(__GLIBC__)
+   // TODO(mdempsky): Extend DSL to support (flags & ~mask1) == mask2.
+   const uint64_t kAndroidCloneMask = CLONE_VM | CLONE_FS | CLONE_FILES |
+                                      CLONE_SIGHAND | CLONE_THREAD |
+@@ -148,6 +148,17 @@
+   return If(IsAndroid() ? android_test : glibc_test, Allow())
+       .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
+       .Else(CrashSIGSYSClone());
++#else
++  const int required = CLONE_VM | CLONE_FS | CLONE_FILES | CLONE_SIGHAND |
++                       CLONE_THREAD | CLONE_SYSVSEM;
++  const int safe = CLONE_SETTLS | CLONE_PARENT_SETTID | CLONE_CHILD_CLEARTID |
++                   CLONE_DETACHED;
++  const BoolExpr thread_clone_ok = (flags&~safe)==required;
++
++  return If(thread_clone_ok, Allow())
++      .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
++      .Else(CrashSIGSYSClone());
++#endif
+ }
+ 
+ ResultExpr RestrictPrctl() {
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-09-13 19:56:31.779773940 +0200
+@@ -375,6 +375,9 @@
+ #if defined(__i386__)
+     case __NR_waitpid:
+ #endif
++#if !defined(__GLIBC__)
++    case __NR_set_tid_address:
++#endif
+       return true;
+     case __NR_clone:  // Should be parameter-restricted.
+     case __NR_setns:  // Privileged.
+@@ -387,7 +390,9 @@
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
+     case __NR_set_thread_area:
+ #endif
++#if defined(__GLIBC__)
+     case __NR_set_tid_address:
++#endif
+     case __NR_unshare:
+ #if !defined(__mips__) && !defined(__aarch64__)
+     case __NR_vfork:
+@@ -496,6 +501,9 @@
+     case __NR_mlock:
+     case __NR_munlock:
+     case __NR_munmap:
++#if !defined(__GLIBC__)
++    case __NR_mremap:
++#endif
+       return true;
+     case __NR_madvise:
+     case __NR_mincore:
+@@ -511,7 +519,9 @@
+     case __NR_modify_ldt:
+ #endif
+     case __NR_mprotect:
++#if defined(__GLIBC__)
+     case __NR_mremap:
++#endif
+     case __NR_msync:
+     case __NR_munlockall:
+     case __NR_readahead:
diff --git a/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
new file mode 100644
index 000000000000..7bf5a22fba71
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
@@ -0,0 +1,15 @@
+--- qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc.orig	2018-09-19 18:05:15.523923703 +0200
++++ qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc	2018-09-19 18:08:05.150932454 +0200
+@@ -173,7 +173,12 @@
+ 
+ size_t GetDefaultThreadStackSize(const pthread_attr_t& attributes) {
+ #if !defined(THREAD_SANITIZER)
++#if defined(__GLIBC__)
+   return 0;
++#else // defined(__GLIBC__)
++  // For Musl libc try with a default stack size of 2 MiB
++  return 2 * 1024 * 1024;
++#endif // !defined(__GLIBC__)
+ #else
+   // ThreadSanitizer bloats the stack heavily. Evidence has been that the
+   // default stack size isn't enough for some browser tests.
diff --git a/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
new file mode 100644
index 000000000000..140742f72c25
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
@@ -0,0 +1,30 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-11-22 00:41:58.522477559 +0100
+@@ -38,7 +38,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_ptrace_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <errno.h>
+ #include <fcntl.h>
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-11-22 00:49:39.533492245 +0100
+@@ -32,7 +32,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_core_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <elf.h>
+ #include <stdio.h>
diff --git a/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
new file mode 100644
index 000000000000..f6c3aadb8421
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
@@ -0,0 +1,14 @@
+--- a/configure.cmake	2021-06-21 23:31:04.000000000 +0200
++++ -	2021-06-27 16:16:32.873528917 +0200
+@@ -373,11 +373,6 @@
+ )
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION NOT LINUX OR TEST_glibc
+-   MESSAGE "A suitable version >= 2.17 of glibc is required."
+-)
+-add_check_for_support(webEngineError webEngineSupport
+-   MODULE QtWebEngine
+    CONDITION NOT LINUX OR TEST_khr
+    MESSAGE "Build requires Khronos development headers for build - see mesa/libegl1-mesa-dev"
+ )
diff --git a/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
new file mode 100644
index 000000000000..608dd0b4e078
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
@@ -0,0 +1,106 @@
+--- qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc.orig	2019-04-09 09:31:16.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc	2019-05-06 23:16:13.245502467 +0200
+@@ -27,7 +27,7 @@
+ #if !defined(USE_SYMBOLIZE)
+ #include <cxxabi.h>
+ #endif
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ #include <execinfo.h>
+ #endif
+ 
+@@ -86,7 +86,7 @@
+   // Note: code in this function is NOT async-signal safe (std::string uses
+   // malloc internally).
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   std::string::size_type search_from = 0;
+   while (search_from < text->size()) {
+     // Look for the start of a mangled symbol, from search_from.
+@@ -121,7 +121,7 @@
+       search_from = mangled_start + 2;
+     }
+   }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ }
+ #endif  // !defined(USE_SYMBOLIZE)
+ 
+@@ -133,7 +133,7 @@
+   virtual ~BacktraceOutputHandler() = default;
+ };
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void OutputPointer(void* pointer, BacktraceOutputHandler* handler) {
+   // This should be more than enough to store a 64-bit number in hex:
+   // 16 hex digits + 1 for null-terminator.
+@@ -216,7 +216,7 @@
+   }
+ #endif  // defined(USE_SYMBOLIZE)
+ }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ 
+ void PrintToStderr(const char* output) {
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+@@ -812,7 +812,7 @@
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+   // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   // Though the backtrace API man page does not list any possible negative
+   // return values, we take no chance.
+   return base::saturated_cast<size_t>(backtrace(trace, count));
+@@ -825,13 +825,13 @@
+ // NOTE: This code MUST be async-signal safe (it's used by in-process
+ // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   PrintBacktraceOutputHandler handler;
+   ProcessBacktrace(trace_, count_, prefix_string, &handler);
+ #endif
+ }
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void StackTrace::OutputToStreamWithPrefix(std::ostream* os,
+                                           const char* prefix_string) const {
+   StreamBacktraceOutputHandler handler(os);
+--- qtwebengine/src/3rdparty/chromium/base/debug/stack_trace.cc	2019-04-09 09:31:16.000000000 +0200
++++ -	2019-05-06 23:18:14.923566992 +0200
+@@ -233,7 +233,7 @@
+ }
+ std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
+   std::stringstream stream;
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(&stream, prefix_string);
+ #endif
+   return stream.str();
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2017-11-28 14:06:53.000000000 +0100
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2018-01-27 22:46:34.970406807 +0100
+@@ -546,7 +546,7 @@
+ 
+ LogMessage::~LogMessage() {
+   size_t stack_start = stream_.tellp();
+-#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && !defined(__UCLIBC__) && \
++#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && defined(__GLIBC__) && \
+     !defined(OS_AIX)
+   if (severity_ == LOG_FATAL && !base::debug::BeingDebugged()) {
+     // Include a stack trace on a fatal, unless a debugger is attached.
+--- a/src/3rdparty/chromium/base/debug/stack_trace.cc	2021-06-27 18:17:06.834705848 +0200
++++ -	2021-06-27 18:27:53.014102803 +0200
+@@ -217,7 +217,9 @@
+ }
+ 
+ void StackTrace::OutputToStream(std::ostream* os) const {
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(os, nullptr);
++#endif
+ }
+ 
+ std::string StackTrace::ToString() const {
diff --git a/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
new file mode 100644
index 000000000000..496753bef30f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
@@ -0,0 +1,26 @@
+diff --git a/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc b/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+index 02bf49b..05ee182 100644
+--- qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
++++ qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+@@ -13,7 +13,7 @@ namespace pp {
+ namespace {
+ 
+ // Use 2MB default stack size for Native Client, otherwise use system default.
+-#if defined(__native_client__)
++#if defined(__native_client__) || !defined(__GLIBC__)
+ const size_t kDefaultStackSize = 2 * 1024 * 1024;
+ #else
+ const size_t kDefaultStackSize = 0;
+diff --git a/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc b/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+index cf7f3ec..e06a5ce 100644
+--- qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
++++ qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+@@ -761,7 +761,7 @@ void Thread::Start() {
+ #if V8_OS_MACOSX
+     // Default on Mac OS X is 512kB -- bump up to 1MB
+     stack_size = 1 * 1024 * 1024;
+-#elif V8_OS_AIX
++#elif V8_OS_AIX || !defined(__GLIBC__)
+     // Default on AIX is 96kB -- bump up to 2MB
+     stack_size = 2 * 1024 * 1024;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
new file mode 100644
index 000000000000..b73971f24324
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
@@ -0,0 +1,60 @@
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
+@@ -1063,4 +1063,8 @@
+ #define __NR_memfd_create 279
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 283
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_ARM64_LINUX_SYSCALLS_H_
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,10 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier (__NR_SYSCALL_BASE+389)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
+@@ -1422,5 +1422,9 @@
+ #define __NR_memfd_create 356
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 375
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_32_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
+@@ -1290,5 +1290,9 @@
+ #define __NR_memfd_create 319
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 324
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -370,6 +370,7 @@
+   switch (sysno) {
+     case __NR_exit:
+     case __NR_exit_group:
++    case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+ #if defined(__i386__)
diff --git a/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
new file mode 100644
index 000000000000..75481a2889f4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
@@ -0,0 +1,14 @@
+--- qtwebengine-everywhere-src-5.14.0-beta2/src/3rdparty/chromium/net/socket/udp_socket_posix.cc	2019-10-08 08:27:43.000000000 +0200
++++ -	2019-11-11 22:41:46.699068889 +0100
+@@ -1191,7 +1191,11 @@
+     msg_iov->push_back({const_cast<char*>(buffer->data()), buffer->length()});
+   msgvec->reserve(buffers.size());
+   for (size_t j = 0; j < buffers.size(); j++)
++#if defined(__GLIBC__)
+     msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, nullptr, 0, 0}, 0});
++#else
++    msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, 0, 0, 0}, 0});
++#endif
+   int result = HANDLE_EINTR(Sendmmsg(fd, &msgvec[0], buffers.size(), 0));
+   SendResult send_result(0, 0, std::move(buffers));
+   if (result < 0) {
diff --git a/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
new file mode 100644
index 000000000000..d8c6aa15cf66
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
@@ -0,0 +1,26 @@
+Allow SYS_sched_getparam and SYS_sched_getscheduler
+musl uses them for pthread_getschedparam()
+
+source: https://git.alpinelinux.org/aports/commit/community/chromium?id=54af9f8ac24f52d382c5758e2445bf0206eff40e
+
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:13:44.992079145 +0100
+@@ -93,11 +93,18 @@
+     case __NR_sysinfo:
+     case __NR_times:
+     case __NR_uname:
++#if !defined(__GLIBC__)
++    case __NR_sched_getparam:
++    case __NR_sched_getscheduler:
++    case __NR_sched_setscheduler:
++#endif
+       return Allow();
+     case __NR_sched_getaffinity:
++#if defined(__GLIBC__)
+     case __NR_sched_getparam:
+     case __NR_sched_getscheduler:
+     case __NR_sched_setscheduler:
++#endif
+       return RestrictSchedTarget(GetPolicyPid(), sysno);
+     case __NR_prlimit64:
+       // See crbug.com/662450 and setrlimit comment above.
diff --git a/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
new file mode 100644
index 000000000000..893ed2d41bb4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
@@ -0,0 +1,11 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/nasm/nasmlib/realpath.c	2019-09-23 14:24:20.000000000 +0200
++++ -	2019-10-11 06:27:28.450329986 +0200
+@@ -57,7 +57,7 @@
+  */
+ char *nasm_realpath(const char *rel_path)
+ {
+-    char *rp = canonicalize_file_name(rel_path);
++    char *rp = realpath(rel_path, NULL);
+     return rp ? rp : nasm_strdup(rel_path);
+ }
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
new file mode 100644
index 000000000000..4fb19ccdd2e5
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
@@ -0,0 +1,37 @@
+From 463f1234c57a36e78ff666bd55094a9d4e68f296 Mon Sep 17 00:00:00 2001
+From: q66 <daniel@octaforge.org>
+Date: Sat, 18 Jan 2020 23:52:55 +0100
+Subject: [PATCH 1/3] Enable ppc64 builds
+
+---
+ configure.pri                  | 1 +
+ mkspecs/features/functions.prf | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/configure.pri b/configure.pri
+index 3a144e3f8..cabe8b24a 100644
+--- a/configure.pri	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:18:43.124754796 +0100
+@@ -144,6 +144,7 @@
+     contains(QT_ARCH, "arm")|contains(QT_ARCH, "arm64"): return(true)
+     contains(QT_ARCH, "mips"): return(true)
+     contains(QT_ARCH, "mips64"): return(true)
++    contains(QT_ARCH, "power64"): return(true)
+     qtLog("Architecture not supported.")
+     return(false)
+ }
+diff --git a/mkspecs/features/functions.prf b/mkspecs/features/functions.prf
+index 512e2523b..e31123654 100644
+--- a/mkspecs/features/functions.prf	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:19:21.345036293 +0100
+@@ -107,6 +107,7 @@
+     contains(qtArch, "mips"): return(mipsel)
+     contains(qtArch, "mips64"): return(mips64el)
+     contains(qtArch, "mips64el"): return(mips64el)
++    contains(qtArch, "power64"): return(ppc64)
+     return(unknown)
+ }
+ 
+-- 
+2.26.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0110-size_t.patch b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
new file mode 100644
index 000000000000..462e3202279f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
@@ -0,0 +1,16 @@
+--- a/src/3rdparty/chromium/third_party/angle/include/platform/PlatformMethods.h	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:44:25.477989726 +0100
+@@ -239,11 +239,11 @@
+ using ProgramKeyType   = std::array<uint8_t, 20>;
+ using CacheProgramFunc = void (*)(PlatformMethods *platform,
+                                   const ProgramKeyType &key,
+-                                  size_t programSize,
++                                  std::size_t programSize,
+                                   const uint8_t *programBytes);
+ inline void DefaultCacheProgram(PlatformMethods *platform,
+                                 const ProgramKeyType &key,
+-                                size_t programSize,
++                                std::size_t programSize,
+                                 const uint8_t *programBytes)
+ {}
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
new file mode 100644
index 000000000000..368099b981cc
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/skia/BUILD.gn	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/skia/BUILD.gn	2020-10-06 20:51:48.834970455 +0200
+@@ -772,7 +772,6 @@
+         # Root build config sets -mfpu=$arm_fpu, which we expect to be neon
+         # when running this.
+         if (!arm_use_neon) {
+-          configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
+           cflags += [ "-mfpu=neon" ]
+         }
+       }
diff --git a/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
new file mode 100644
index 000000000000..6e2d62f35ee6
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
@@ -0,0 +1,20 @@
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -17,6 +17,17 @@
+ 
+ #include <stdint.h>
+ #include <sys/user.h>
++#if !defined(__GLIBC__)
++struct user_vfp {
++	unsigned long long fpregs[32];
++	unsigned long fpscr;
++};
++struct user_vfp_exc {
++	unsigned long fpexc;
++	unsigned long fpinst;
++	unsigned long fpinst2;
++};
++#endif /* !defined(__GLIBC__) */
+ 
+ #include <type_traits>
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
new file mode 100644
index 000000000000..5c7cbfc46f65
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
@@ -0,0 +1,18 @@
+--- a/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-10-06 21:28:45.124882085 +0200
+@@ -109,6 +109,15 @@
+ #define HWCAP_IDIV  (HWCAP_IDIVA | HWCAP_IDIVT)
+ #define HWCAP_LPAE  (1 << 20)
+ 
++#ifndef __GLIBC__
++#include <elf.h>
++#ifdef __LP64__
++typedef Elf64_auxv_t elf_auxv_t;
++#else
++typedef Elf32_auxv_t elf_auxv_t;
++#endif
++#endif
++
+ static uint32_t ReadELFHWCaps() {
+ #if V8_GLIBC_PREREQ(2, 16)
+   return static_cast<uint32_t>(getauxval(AT_HWCAP));
diff --git a/srcpkgs/qt6-webengine/patches/0114-time64.patch b/srcpkgs/qt6-webengine/patches/0114-time64.patch
new file mode 100644
index 000000000000..6a98dd4e480e
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0114-time64.patch
@@ -0,0 +1,89 @@
+Description: fix seccomp-bpf failures in syscalls 0403, 0407
+ glibc ≥ 2.31 uses these syscalls on 32-bit platforms:
+ .
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=2e44b10b42d68d98
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=ec138c67cbda8b58
+Author: Andreas Müller <schnitzeltony@gmail.com>
+Forwarded: no
+Last-Update: 2020-09-02
+
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -148,7 +148,14 @@ ResultExpr EvaluateSyscallImpl(int fs_de
+     return Allow();
+ #endif
+ 
+-  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep) {
++  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep
++#if defined(__NR_clock_gettime64)
++                                  || sysno == __NR_clock_gettime64
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++                                  || sysno == __NR_clock_nanosleep_time64
++#endif
++  ) {
+     return RestrictClockID();
+   }
+ 
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
+@@ -60,6 +60,12 @@ class RestrictClockIdPolicy : public bpf
+       case __NR_clock_gettime:
+       case __NR_clock_getres:
+       case __NR_clock_nanosleep:
++#if defined(__NR_clock_nanosleep_time64)
++      case __NR_clock_nanosleep_time64:
++#endif
++#if defined(__NR_clock_gettime64)
++      case __NR_clock_gettime64:
++#endif
+         return RestrictClockID();
+       default:
+         return Allow();
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -39,6 +39,12 @@ bool SyscallSets::IsAllowedGettime(int s
+                                 // filtered by RestrictClokID().
+     case __NR_clock_gettime:    // Parameters filtered by RestrictClockID().
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
++#if defined(__NR_clock_gettime64)
++    case __NR_clock_gettime64:  // Parameters filtered by RestrictClockID().
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++    case __NR_clock_nanosleep_time64:  // Parameters filtered by RestrictClockID().
++#endif
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,14 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_SYSCALL_BASE+403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_SYSCALL_BASE+407)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
+@@ -1433,4 +1433,12 @@
+ #define __NR_memfd_create (__NR_Linux + 354)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_Linux + 403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_Linux + 407)
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_MIPS_LINUX_SYSCALLS_H_
diff --git a/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
new file mode 100644
index 000000000000..3a0ba3b2d854
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
@@ -0,0 +1,144 @@
+# Patch made by Kevin Kofler <Kevin@tigcc.ticalc.org>
+# https://bugzilla.redhat.com/show_bug.cgi?id=1904652
+
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2021-01-20 02:14:53.066223906 +0100
+@@ -257,6 +257,18 @@
+     return RestrictKillTarget(current_pid, sysno);
+   }
+ 
++#if defined(__NR_newfstatat)
++  if (sysno == __NR_newfstatat) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
++#if defined(__NR_fstatat64)
++  if (sysno == __NR_fstatat64) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
+   if (SyscallSets::IsFileSystem(sysno) ||
+       SyscallSets::IsCurrentDirectory(sysno)) {
+     return Error(fs_denied_errno);
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2021-01-22 19:02:55.651668257 +0100
+@@ -6,6 +6,8 @@
+ 
+ #include "sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h"
+ 
++#include <errno.h>
++#include <fcntl.h>
+ #include <stddef.h>
+ #include <stdint.h>
+ #include <string.h>
+@@ -355,6 +357,35 @@
+   return -ENOSYS;
+ }
+ 
++intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args,
++                            void* aux) {
++  switch (args.nr) {
++#if defined(__NR_newfstatat)
++    case __NR_newfstatat:
++#endif
++#if defined(__NR_fstatat64)
++    case __NR_fstatat64:
++#endif
++#if defined(__NR_newfstatat) || defined(__NR_fstatat64)
++      if (*reinterpret_cast<const char *>(args.args[1]) == '\0'
++          && args.args[3] == static_cast<uint64_t>(AT_EMPTY_PATH)) {
++        return sandbox::sys_fstat64(static_cast<int>(args.args[0]),
++                                    reinterpret_cast<struct stat64 *>(args.args[2]));
++      } else {
++        errno = EACCES;
++        return -1;
++      }
++      break;
++#endif
++  }
++
++  CrashSIGSYS_Handler(args, aux);
++
++  // Should never be reached.
++  RAW_CHECK(false);
++  return -ENOSYS;
++}
++
+ bpf_dsl::ResultExpr CrashSIGSYS() {
+   return bpf_dsl::Trap(CrashSIGSYS_Handler, NULL);
+ }
+@@ -387,6 +418,10 @@
+   return bpf_dsl::Trap(SIGSYSSchedHandler, NULL);
+ }
+ 
++bpf_dsl::ResultExpr RewriteFstatatSIGSYS() {
++  return bpf_dsl::Trap(SIGSYSFstatatHandler, NULL);
++}
++
+ void AllocateCrashKeys() {
+ #if !defined(OS_NACL_NONSFI)
+   if (seccomp_crash_key)
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2021-01-20 02:11:04.583714199 +0100
+@@ -62,6 +62,10 @@
+ // sched_setparam(), sched_setscheduler()
+ SANDBOX_EXPORT intptr_t SIGSYSSchedHandler(const arch_seccomp_data& args,
+                                            void* aux);
++// If the fstatat syscall is actually a disguised fstat, calls the regular fstat
++// syscall, otherwise, crashes in the same way as CrashSIGSYS_Handler.
++SANDBOX_EXPORT intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args, 
++                                             void* aux);
+ 
+ // Variants of the above functions for use with bpf_dsl.
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYS();
+@@ -72,6 +76,7 @@
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSFutex();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSPtrace();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteSchedSIGSYS();
++SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteFstatatSIGSYS();
+ 
+ // Allocates a crash key so that Seccomp information can be recorded.
+ void AllocateCrashKeys();
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2021-01-20 02:41:12.033133269 +0100
+@@ -261,4 +261,13 @@
+ 
+ #endif  // defined(MEMORY_SANITIZER)
+ 
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf)
++{
++#if defined(__NR_fstat64)
++    return syscall(__NR_fstat64, fd, buf);
++#else
++    return syscall(__NR_fstat, fd, buf);
++#endif
++}
++
+ }  // namespace sandbox
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2021-01-20 02:40:26.499827829 +0100
+@@ -17,6 +17,7 @@
+ struct rlimit64;
+ struct cap_hdr;
+ struct cap_data;
++struct stat64;
+ 
+ namespace sandbox {
+ 
+@@ -84,6 +85,9 @@
+                                  const struct sigaction* act,
+                                  struct sigaction* oldact);
+ 
++// Recent glibc rewrites fstat to fstatat.
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf);
++
+ }  // namespace sandbox
+ 
+ #endif  // SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_
diff --git a/srcpkgs/qt6-webengine/template b/srcpkgs/qt6-webengine/template
new file mode 100644
index 000000000000..45aeb56b42b1
--- /dev/null
+++ b/srcpkgs/qt6-webengine/template
@@ -0,0 +1,93 @@
+# Template file for 'qt6-webengine'
+pkgname=qt6-webengine
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebengine-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true
+ -DQT_FEATURE_webengine_system_ffmpeg=ON
+ -DQT_FEATURE_webengine_system_libevent=ON
+ -DQT_FEATURE_webengine_system_gn=ON
+ -DPKG_CONFIG_HOST_EXECUTABLE=${PKG_CONFIG_FOR_BUILD}"
+hostmakedepends="qt6-base-devel perl pkg-config nodejs python
+ protobuf gperf flex nss-devel libwebp-devel"
+makedepends="qt6-base-devel qt6-declarative-devel pulseaudio-devel
+ alsa-lib-devel libvpx-devel pciutils-devel opus-devel libxslt-devel
+ libxml2-devel freetype-devel lcms2-devel libwebp-devel icu-devel
+ re2-devel zlib-devel libpng-devel minizip-devel harfbuzz-devel
+ nss-devel libXcursor-devel libXcomposite-devel libXScrnSaver-devel
+ protobuf-devel ffmpeg-devel snappy-devel libevent-devel pipewire-devel
+ qt6-quickcontrols2-devel qt6-location-devel qt6-webchannel-devel"
+short_desc="Cross-platform application and UI framework - Webengine"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-3.0-only, GPL-2.0-only, LGPL-3.0-only BSD-3-Clause"
+homepage="https://www.qt.io"
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebengine-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e509436aa22b952e6195c146cf06a839b85aaa0724feb85f0b78516dc42105a4
+
+if [ -z "$CROSS_BUILD" ];then
+	configure_args+=" -DCMAKE_TOOLCHAIN_FILE=/usr/lib/cmake/Qt6/qt.toolchain.cmake"
+fi
+
+if [ "$XBPS_LIBC" = "musl" ]; then
+	hostmakedepends+=" musl-legacy-compat"
+fi
+
+if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
+	makedepends+=" musl-legacy-compat"
+fi
+
+if [ ! "$XBPS_WORDSIZE" = "$XBPS_TARGET_WORDSIZE" ]; then
+	broken="webengine can be built only if word size matches"
+fi
+
+if [ "$XBPS_WORDSIZE" -eq 32 ]; then
+	nodebug=yes
+	LDFLAGS="-Wl,--no-keep-memory"
+fi
+
+if [ "$XBPS_TARGET_ENDIAN" != "le" ]; then
+	broken="webengine only supports little endian"
+fi
+
+_bootstrap_gn() {
+	# Bootstrap gn (generate ninja)
+	echo "Bootstrapping 'gn'"
+	cd ${wrksrc}/src/3rdparty/gn
+	CFLAGS="$CFLAGS_host" CXXFLAGS="$CXXFLAGS_host" LDFLAGS="$LDFLAGS_host" \
+	PKGCONFIG=/usr/bin/pkgconfig PKG_CONFIG_PATH="/usr/lib/pkgconfig:/usr/share/pkgconfig" \
+		python2 build/gen.py --no-last-commit-position --out-path \
+			${wrksrc}/src/3rdparty/gn/out/Release --cc "${CC_host:-$CC}" \
+			--cxx "${CXX_host:-$CXX}" --ld "${CXX_host:-$CXX}" --ar "${AR_host:-$AR}" \
+			--qt-version "${version}.qtwebengine.qt.io"
+	ninja -C out/Release gn
+	cd ${wrksrc}
+}
+
+pre_configure() {
+	cp ${FILESDIR}/resolv_compat.h ${wrksrc}/src/3rdparty/chromium/net/dns
+	_bootstrap_gn
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+pre_build() {
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+post_install() {
+	rm -r ${DESTDIR}/builddir
+	mv ${DESTDIR}/usr/resources ${DESTDIR}/usr/share/qt6
+	mv ${DESTDIR}/usr/translations ${DESTDIR}/usr/share/qt6
+}
+
+qt6-webengine-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-webchannel-devel>=${version}_1
+	 qt6-declarative-devel>=${version}_1 qt6-location-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+	}
+}

From d173e9e63fd5ea4ca38412f4b00b97ac0fd4639b Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 16:00:28 +0200
Subject: [PATCH 25/25] New package: qt6-location-6.2.0alpha

---
 common/shlibs                 |  1 +
 srcpkgs/qt6-location-devel    |  1 +
 srcpkgs/qt6-location/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-location-devel
 create mode 100644 srcpkgs/qt6-location/template

diff --git a/common/shlibs b/common/shlibs
index e6d1ef7157b4..e3b64dfad96b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2063,6 +2063,7 @@ libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
+libQt6Positioning.so.6 qt6-location-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-location-devel b/srcpkgs/qt6-location-devel
new file mode 120000
index 000000000000..7924c82dd3f4
--- /dev/null
+++ b/srcpkgs/qt6-location-devel
@@ -0,0 +1 @@
+qt6-location
\ No newline at end of file
diff --git a/srcpkgs/qt6-location/template b/srcpkgs/qt6-location/template
new file mode 100644
index 000000000000..3bad3ab8aade
--- /dev/null
+++ b/srcpkgs/qt6-location/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-location'
+pkgname=qt6-location
+version=6.2.0alpha
+revision=1
+wrksrc="qtlocation-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-serialport-devel qt6-declarative-devel GConf-devel"
+short_desc="Cross-platform application and UI framework - location"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlocation-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=514a84d73ccb7af5f7921b99a5742314c8875bd4cb1a982a09b28a8080c117c8
+
+qt6-location-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
@ 2021-06-27 19:20 ` Johnnynator
  2021-06-27 19:37 ` Johnnynator
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-06-27 19:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

There is an updated pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 119573 bytes --]

From b5cde7b93c73f447a644dc06904a4e37de8deceb Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 01/24] qt6-3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..9a45c8c011ef 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt3d-everywhere-src-${version}"
+wrksrc="qt3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - 3d"
 maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=8fff7ac79b3f508df00bfc4e14e401b1dde0a5bc1d67d3cb88c05b04ac12aa1b
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 3bbfbb063956864a2f04fe692e986af042b31bd6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 02/24] qt6-base: update to 6.2.0alpha.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 +++++++++++++++++++
 srcpkgs/qt6-base/template                     | 16 ++++++------
 2 files changed, 33 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index bb043213a360..fad36fe8bc70 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtbase-everywhere-src-${version}"
+wrksrc="qtbase-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
  -DINSTALL_ARCHDATADIR=lib/qt6
@@ -27,8 +27,8 @@ short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtbase-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=eb18d8fc5b5136ab0d177d89c54ec197363904fedb2aecb0d87033ce78ddffcc
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -84,10 +84,10 @@ qt6-gui_package() {
 	short_desc+=" - Gui"
 	pkg_install() {
 		vmove "usr/lib/libQt6Gui.so.*"
-		vmove "usr/lib/libQt6XcbQpa.so.*"
-		vmove "usr/lib/libQt6EglFSDeviceIntegration.so.*"
-		vmove "usr/lib/libQt6EglFsKmsGbmSupport.so.*"
-		vmove "usr/lib/libQt6EglFsKmsSupport.so.*"
+		vmove "usr/lib/libQt6XcbQpaPrivate.so.*"
+		vmove "usr/lib/libQt6EglFSDeviceIntegrationPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsGbmSupportPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsSupportPrivate.so.*"
 		vmove "usr/lib/libQt6OpenGL.so.*"
 		vmove usr/lib/qt6/plugins/generic
 		vmove usr/lib/qt6/plugins/platforms

From 887ee80e9686b8e588deacefd50f56dd74d5d773 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 03/24] qt6-charts: update to 6.2.0alpha.

---
 srcpkgs/qt6-charts/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..1beaf0dbecfd 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtcharts-everywhere-src-${version}"
+wrksrc="qtcharts-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - charts"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtcharts-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=294205bc1e855bb44a0e17c707b981c617fc08d55d071e1d02441ff5a4e7e676
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 69958b3a121927781ae2119dbe7881510d436bb9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 04/24] qt6-declarative: update to 6.2.0alpha.

---
 srcpkgs/qt6-declarative/template | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..bef006df96f0 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,23 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtdeclarative-everywhere-src-${version}"
+wrksrc="qtdeclarative-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel qt6-declarative-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtdeclarative-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=4fd2d9448620586862e56149c43ef93b6dddcb60d6f211ab933bed984d1f1d8a
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +37,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}

From aada910c567270d02619c3dbf850c5bd7020a143 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 05/24] qt6-imageformats: update to 6.2.0alpha.

---
 srcpkgs/qt6-imageformats/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..8207913c89f9 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtimageformats-everywhere-src-${version}"
+wrksrc="qtimageformats-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - imageformats"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtimageformats-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=6e4a3690b5de83733f9a4ad492784b33748684cd99e98aa7cd3c30c97faa2bae

From 15ab172bb800f7d3f236f65bdd36a7c369389c67 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 06/24] qt6-lottie: update to 6.2.0alpha.

---
 srcpkgs/qt6-lottie/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..0a55513d0cb8 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtlottie-everywhere-src-${version}"
+wrksrc="qtlottie-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - lottie"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlottie-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=07e01a8993866abcb372cc8569d299f79cc6a91ebf66a5a85a5abe722527eadc
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From eb078c67d662ab8343f5978c753e39886d639d92 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 07/24] qt6-networkauth: update to 6.2.0alpha.

---
 srcpkgs/qt6-networkauth/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..654a2bb0fd69 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtnetworkauth-everywhere-src-${version}"
+wrksrc="qtnetworkauth-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - networkauth"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtnetworkauth-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=75784d38da1d476b209c3151dbd9afda0708fdcfbfd48d09a520754a442ccda6
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 7c2a671fa4d46b18e000208854b4109a7d2df9ba Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 08/24] qt6-qt5compat: update to 6.2.0alpha.

---
 srcpkgs/qt6-qt5compat/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index d64b37bff575..0567c1b374e5 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt5compat-everywhere-src-${version}"
+wrksrc="qt5compat-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Compo
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt5compat-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=210dbe079b51ba47841219fde59ad11a8e77a4a851a73b77121153ed03afb473
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From be6ba0726c80f36232967cce5dfcfb5b9ee65fb8 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 09/24] qt6-quick3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-quick3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..673ec342450f 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquick3d-everywhere-src-${version}"
+wrksrc="qtquick3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel qt6-shadertools-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - Quick3d"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquick3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=b60012e2d3d4b9d62cbddd84b56dcae985bc7b111b551d0eadd06551772db806
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From b27e77ae879c847b2ac68560fab513afe37b2eea Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:16 +0200
Subject: [PATCH 10/24] qt6-quickcontrols2: update to 6.2.0alpha.

---
 srcpkgs/qt6-quickcontrols2/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
index ab57102a19cf..efd4972c669c 100644
--- a/srcpkgs/qt6-quickcontrols2/template
+++ b/srcpkgs/qt6-quickcontrols2/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quickcontrols2'
 pkgname=qt6-quickcontrols2
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
+wrksrc="qtquickcontrols2-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quickcontrols2"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-2.0-or-later, LGPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquickcontrols2-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=40c8af99adb342c45809bfe06c73ac7d923433518cb7bc7997f6fc40e169c4c5
 
 qt6-quickcontrols2-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"

From 1a17155662858e9d84a7b6cd9ce3653d9361f6e6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 11/24] qt6-quicktimeline: update to 6.2.0alpha.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..bc0225e767bc 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquicktimeline-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e5b024adf9ae291004b5273465757583796c989f317e3bc62366953f02c7a89a
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 1f5209e2a8751a0772f0bcf681991984aba6afd4 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 12/24] qt6-scxml: update to 6.2.0alpha.

---
 srcpkgs/qt6-scxml/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..f8324f91a3d7 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtscxml-everywhere-src-${version}"
+wrksrc="qtscxml-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - scxml"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtscxml-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e29a333477e84d407421096fd2d90bccfb95ae4b8d0ed0d0785586e56cfa9d0c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From b606a67dc061c1f45b239157b773083b7e4bd395 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 13/24] qt6-shadertools: update to 6.2.0alpha.

---
 srcpkgs/qt6-shadertools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..42fa436708a6 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtshadertools-everywhere-src-${version}"
+wrksrc="qtshadertools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - shadertools"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtshadertools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=08144fa6d96c4382e47b3203d27f999b86d4ed1f1b828e09a48614f32b12ee59
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From 7c296b0c79ade72bae881ca17db1f85a83cf6eb2 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 14/24] qt6-svg: update to 6.2.0alpha.

---
 srcpkgs/qt6-svg/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..c37793e0613b 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtsvg-everywhere-src-${version}"
+wrksrc="qtsvg-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-svg componen
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtsvg-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=dd7c5312b8430130103d91908bd5f19fa2c6bf01c76acb757e5974603b3769c8
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 44c54233dece4657c855e854dec92e411b82041c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 15/24] qt6-tools: update to 6.2.0alpha.

---
 srcpkgs/qt6-tools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..0e7a9126bcf7 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttools-everywhere-src-${version}"
+wrksrc="qttools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-tools compon
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=32596431f71f7b4bbcd05e86c0490f97bf68b66e560337e5418a7faee5d86e84
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 7d8b1526b9c0448307dd4aa4a9d4de5377053d3c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 16/24] qt6-translations: update to 6.2.0alpha.

---
 srcpkgs/qt6-translations/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..c8be8fe68426 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttranslations-everywhere-src-${version}"
+wrksrc="qttranslations-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel qt6-tools-devel perl"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - translations"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttranslations-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=0fecd5d3e8f8823d1c77e95fbbac80c084b08df5a02f06fe71b2af6ceceb87ad

From 0c0055a85111cada71a12c5c36ba2a21b6e97b2e Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 17/24] qt6-virtualkeyboard: update to 6.2.0alpha.

---
 srcpkgs/qt6-virtualkeyboard/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..c5034fa3e95d 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
+wrksrc="qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
@@ -13,8 +13,8 @@ short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=1675dad7cd41fddb593d1fcf0a6d2a7c0f27ae9962232cba8a0a94dd38044320
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From e5dd139978eaceb3156704b74231c109e41cb7e5 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 18/24] qt6-wayland: update to 6.2.0alpha.

---
 srcpkgs/qt6-wayland/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..77c5eecd2551 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtwayland-everywhere-src-${version}"
+wrksrc="qtwayland-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel qt6-wayland-devel"
@@ -14,8 +14,8 @@ short_desc="Cross-platform application and UI framework - Wayland"
 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwayland-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=71209da169478c6ea3555f8e55edd9fe9d758ac9826c404af2a5e912a8fcfa5d
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From 43d52a9d09171ba008c6b8ea1621f3dc7d902242 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:16:54 +0200
Subject: [PATCH 19/24] New package: qt6-serialport-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-serialport-devel    |  1 +
 srcpkgs/qt6-serialport/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-serialport-devel
 create mode 100644 srcpkgs/qt6-serialport/template

diff --git a/common/shlibs b/common/shlibs
index 8a7eef8df8c3..eb023b6275aa 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2060,6 +2060,7 @@ libQt6Help.so.6 qt6-tools-6.1.0_1
 libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
+libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-serialport-devel b/srcpkgs/qt6-serialport-devel
new file mode 120000
index 000000000000..f6a498cf2653
--- /dev/null
+++ b/srcpkgs/qt6-serialport-devel
@@ -0,0 +1 @@
+qt6-serialport
\ No newline at end of file
diff --git a/srcpkgs/qt6-serialport/template b/srcpkgs/qt6-serialport/template
new file mode 100644
index 000000000000..45e5915979cc
--- /dev/null
+++ b/srcpkgs/qt6-serialport/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-serialport'
+pkgname=qt6-serialport
+version=6.2.0alpha
+revision=1
+wrksrc="qtserialport-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel pkg-config"
+makedepends="qt6-base-devel"
+short_desc="Cross-platform application and UI framework - serialport"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtserialport-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=51129c6964c42668e2ea205f1fcb0e0ea099aaeae74607112957343afb531863
+
+qt6-serialport-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 7edd1755472ba68864fb02b77aca9b61aa5ff69a Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:23:48 +0200
Subject: [PATCH 20/24] New package: qt6-websockets-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-websockets-devel    |  1 +
 srcpkgs/qt6-websockets/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-websockets-devel
 create mode 100644 srcpkgs/qt6-websockets/template

diff --git a/common/shlibs b/common/shlibs
index eb023b6275aa..69227af2267f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2061,6 +2061,7 @@ libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
+libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-websockets-devel b/srcpkgs/qt6-websockets-devel
new file mode 120000
index 000000000000..a3c674e42954
--- /dev/null
+++ b/srcpkgs/qt6-websockets-devel
@@ -0,0 +1 @@
+qt6-websockets
\ No newline at end of file
diff --git a/srcpkgs/qt6-websockets/template b/srcpkgs/qt6-websockets/template
new file mode 100644
index 000000000000..6177426904ae
--- /dev/null
+++ b/srcpkgs/qt6-websockets/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-websockets'
+pkgname=qt6-websockets
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebsockets-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel"
+short_desc="Cross-platform application and UI framework - websockets"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebsockets-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=f8277d05192ee5f823356a6c6b72ea816a0187f6a0915b783605bee9549a8761
+
+qt6-websockets-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 13ee41a031d02c96b1d1e015ff33cf3d775a351f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:25:04 +0200
Subject: [PATCH 21/24] New package: qt6-webchannel-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-webchannel-devel    |  1 +
 srcpkgs/qt6-webchannel/template | 28 ++++++++++++++++++++++++++++
 3 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-webchannel-devel
 create mode 100644 srcpkgs/qt6-webchannel/template

diff --git a/common/shlibs b/common/shlibs
index 69227af2267f..e6d1ef7157b4 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2062,6 +2062,7 @@ libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
+libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-webchannel-devel b/srcpkgs/qt6-webchannel-devel
new file mode 120000
index 000000000000..03e8b23d785d
--- /dev/null
+++ b/srcpkgs/qt6-webchannel-devel
@@ -0,0 +1 @@
+qt6-webchannel
\ No newline at end of file
diff --git a/srcpkgs/qt6-webchannel/template b/srcpkgs/qt6-webchannel/template
new file mode 100644
index 000000000000..a1d217810c90
--- /dev/null
+++ b/srcpkgs/qt6-webchannel/template
@@ -0,0 +1,28 @@
+# Template file for 'qt6-webchannel'
+pkgname=qt6-webchannel
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebchannel-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel qt6-websockets-devel"
+short_desc="Cross-platform application and UI framework - webchannel"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebchannel-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=68fd3f0508b6df69b5736d7e142509131f3728630abdcd432a06430e5ca8920c
+
+qt6-webchannel-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1
+	 qt6-websockets-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 5ec2dcc9776c43e878b647e9c87332c3e38511a9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 21:08:25 +0200
Subject: [PATCH 22/24] New package: qt6-multimedia-6.2.0alpha

---
 srcpkgs/qt6-multimedia-devel    |  1 +
 srcpkgs/qt6-multimedia/template | 29 +++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-multimedia-devel
 create mode 100644 srcpkgs/qt6-multimedia/template

diff --git a/srcpkgs/qt6-multimedia-devel b/srcpkgs/qt6-multimedia-devel
new file mode 120000
index 000000000000..9343446502d0
--- /dev/null
+++ b/srcpkgs/qt6-multimedia-devel
@@ -0,0 +1 @@
+qt6-multimedia
\ No newline at end of file
diff --git a/srcpkgs/qt6-multimedia/template b/srcpkgs/qt6-multimedia/template
new file mode 100644
index 000000000000..41a25959361e
--- /dev/null
+++ b/srcpkgs/qt6-multimedia/template
@@ -0,0 +1,29 @@
+# Template file for 'qt6-multimedia'
+pkgname=qt6-multimedia
+version=6.2.0alpha
+revision=1
+wrksrc="qtmultimedia-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_FEATURE_gstreamer=ON"
+hostmakedepends="perl qt6-declarative-devel pkg-config
+ qt6-shadertools-devel"
+makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
+ qt6-shadertools-devel libglib-devel gst-plugins-base1-devel"
+short_desc="Cross-platform application and UI framework - multimedia"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtmultimedia-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=9241fe9456c04ba1feaffd74883d37155c0218baf8aa9fc3dd54642791f378cd
+
+qt6-multimedia-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From ddcd2dc86383ec43b0d7e35b1c6e2e1f9086caf4 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 00:35:33 +0200
Subject: [PATCH 23/24] New package: qt6-webengine-6.2.0alpha

---
 srcpkgs/qt6-webengine-devel                   |   1 +
 srcpkgs/qt6-webengine/files/resolv_compat.h   |  29 ++
 ...-compilation-support-to-cmake-builds.patch | 474 ++++++++++++++++++
 .../patches/0001-mus-cstring.patch            |  10 +
 ...use-target-C-XX-FLAGS-for-host-cmake.patch |  26 +
 .../patches/0002-None-no-debug.patch          |  11 +
 ...reg.h-to-get-__WORDSIZE-on-musl-libc.patch |  26 +
 .../patches/0003-musl-dispatch-to-musl.patch  | 103 ++++
 .../patches/0004-musl-no-mallinfo.patch       |  39 ++
 .../patches/0005-musl-off_t.patch             |  10 +
 .../patches/0006-musl-pread-pwrite.patch      |  18 +
 .../patches/0008-musl-resolve.patch           |  26 +
 .../patches/0009-musl-siginfo_t.patch         |  18 +
 .../patches/0010-musl-stackstart.patch        |  20 +
 .../patches/0011-musl-sandbox.patch           |  71 +++
 ...0012-musl-chromium-default-stacksize.patch |  15 +
 .../0014-musl-cross-no-asm_ptrace_h.patch     |  30 ++
 .../patches/0015-no-glibc-cmake-check.patch   |  14 +
 .../patches/0016-qt-musl-execinfo.patch       | 106 ++++
 .../0017-qt-musl-thread-stacksize.patch       |  26 +
 .../patches/0018-sandbox-membarrier.patch     |  60 +++
 .../patches/0020-msgvec-push_back.patch       |  14 +
 .../patches/0021-sandbox-sched_getparam.patch |  26 +
 .../0022-canonicalize-file-name-musl.patch    |  11 +
 .../patches/0089-enable-ppc64.patch           |  37 ++
 .../qt6-webengine/patches/0110-size_t.patch   |  16 +
 .../patches/0111-armv7l-neon.patch            |  10 +
 .../patches/0112-arm-user_vfp.patch           |  20 +
 .../patches/0113-arm-elf_auxv_t.patch         |  18 +
 .../qt6-webengine/patches/0114-time64.patch   |  89 ++++
 .../patches/0121-glibc-2.33.patch             | 144 ++++++
 srcpkgs/qt6-webengine/template                |  93 ++++
 32 files changed, 1611 insertions(+)
 create mode 120000 srcpkgs/qt6-webengine-devel
 create mode 100644 srcpkgs/qt6-webengine/files/resolv_compat.h
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0110-size_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0114-time64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
 create mode 100644 srcpkgs/qt6-webengine/template

diff --git a/srcpkgs/qt6-webengine-devel b/srcpkgs/qt6-webengine-devel
new file mode 120000
index 000000000000..8e4d1b99c587
--- /dev/null
+++ b/srcpkgs/qt6-webengine-devel
@@ -0,0 +1 @@
+qt6-webengine
\ No newline at end of file
diff --git a/srcpkgs/qt6-webengine/files/resolv_compat.h b/srcpkgs/qt6-webengine/files/resolv_compat.h
new file mode 100644
index 000000000000..4f0e852a19d0
--- /dev/null
+++ b/srcpkgs/qt6-webengine/files/resolv_compat.h
@@ -0,0 +1,29 @@
+#if !defined(__GLIBC__)
+/***************************************************************************
+ * resolv_compat.h
+ *
+ * Mimick GLIBC's res_ninit() and res_nclose() for musl libc
+ * Note: res_init() is actually deprecated according to
+ * http://docs.oracle.com/cd/E36784_01/html/E36875/res-nclose-3resolv.html
+ **************************************************************************/
+#include <string.h>
+
+static inline int res_ninit(res_state statp)
+{
+	int rc = res_init();
+	if (statp != &_res) {
+		memcpy(statp, &_res, sizeof(*statp));
+	}
+	return rc;
+}
+
+static inline int res_nclose(res_state statp)
+{
+	if (!statp)
+		return -1;
+	if (statp != &_res) {
+		memset(statp, 0, sizeof(*statp));
+	}
+	return 0;
+}
+#endif
diff --git a/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
new file mode 100644
index 000000000000..c70f219e5f4d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
@@ -0,0 +1,474 @@
+From 7a22a424ff2997f644d930050635db214c068d10 Mon Sep 17 00:00:00 2001
+From: Michal Klocek <michal.klocek@qt.io>
+Date: Sun, 23 May 2021 17:39:28 +0200
+Subject: [PATCH 1/2] Add cross compilation support to cmake builds
+
+Add arm cross-compile basic support. CMake does not
+support host builds. However we do host build with gn and
+changing that would require an extra effort to keep all necessary
+changes with Chromium upstream. Therefore let gn to perform
+the host build for required tools and just feed gn with all the
+build data.
+
+Add new build steps:
+
+* install gn into QT_HOST_PATH/libexec.
+* run hostBuild project to get native architecture and compiler
+* call PkgConfigHost to pass pkg-config paths to gn
+* create wrapper script for host pkg-config to escape
+  yocto shell pkg config exports
+
+This change also splits gn toolchain into 3 toolchains host,target,v8
+Now hostBuild provides host and v8 toolchain in case of cross compile.
+
+The build optimizations will follow in another patch.
+
+Note this is tested only with yocto based images.
+
+Pick-to: dev
+Task-number: QTBUG-91760
+Change-Id: Ic2bea12229acc71fbd36a848e9ed4fed7e14b485
+---
+ CMakeLists.txt                           | 37 ++++++++++++++++--
+ cmake/FindGn.cmake                       |  9 +++--
+ cmake/FindNinja.cmake                    |  4 +-
+ cmake/FindPkgConfigHost.cmake            | 40 ++++++++++++++++++++
+ cmake/Functions.cmake                    | 45 ++++++++++++++++++++++
+ configure.cmake                          | 10 ++++-
+ src/core/CMakeLists.txt                  | 48 ++++++++++++++++++------
+ src/core/api/configure.cmake             | 10 ++---
+ src/core/configure/BUILD.toolchain.gn.in | 32 ++--------------
+ src/core/configure/CMakeLists.txt        | 35 +++++++++++++++++
+ 10 files changed, 215 insertions(+), 55 deletions(-)
+ create mode 100644 cmake/FindPkgConfigHost.cmake
+ create mode 100644 src/core/configure/CMakeLists.txt
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 8a3ff75c..2a93dca5 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -63,6 +63,7 @@ add_subdirectory(src/process)
+ add_subdirectory(src/webenginewidgets)
+ add_subdirectory(src/webenginequick)
+ qt_build_repo_end()
++get_install_config(installConfig)
+ 
+ ### NINJA
+ 
+@@ -94,9 +95,10 @@ if(NOT Gn_FOUND)
+                    -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
+                    -DCMAKE_PREFIX_PATH:PATH=<INSTALL_DIR>
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+-)
++    )
+ endif()
+ 
++
+ ### LIBS
+ 
+ # on windows source path can be specified without hard drive letter,
+@@ -115,12 +117,14 @@ endif()
+ list(TRANSFORM featureList PREPEND "-D")
+ list(APPEND libsCmakeArgs
+         "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}"
+-        "-DWEBENGINE_ROOT_BUILD_PATH=${CMAKE_CURRENT_BINARY_DIR}"
++        "-DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}"
+         "-DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}"
+         "-DWEBENGINE_REPO_BUILD=TRUE"
+         "${featureList}"
+ )
+-
++if(QT_HOST_PATH)
++    list(APPEND libsCmakeArgs "-DQT_HOST_PATH=${QT_HOST_PATH}")
++endif()
+ if(LINUX)
+     set(cmd "${CMAKE_COMMAND} --build ${CMAKE_CURRENT_BINARY_DIR}/src")
+     file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/src/build.sh CONTENT "ulimit -n 4096 && ${cmd}\n")
+@@ -210,3 +214,30 @@ if(NOT QT_FEATURE_framework)
+         DESTINATION ${CMAKE_INSTALL_PREFIX}
+     )
+ endif()
++
++### CROSS BUILD SETUP
++
++# install gn for cross build
++# TODO: is this really needed, should we skip it and just build gn as host build ?
++if(LINUX AND NOT Gn_FOUND OR INSTALL_GN)
++    set(INSTALL_GN 1 CACHE INTERNAL "")
++    install(
++        PROGRAMS ${installDir}/bin/gn
++        CONFIGURATIONS ${installConfig}
++        RUNTIME DESTINATION "${INSTALL_LIBEXECDIR}"
++    )
++endif()
++
++if(CMAKE_CROSSCOMPILING)
++    externalproject_add(hostBuild
++        SOURCE_DIR  ${CMAKE_CURRENT_LIST_DIR}/src/core/configure
++        BINARY_DIR  ${CMAKE_CURRENT_BINARY_DIR}/configure
++        PREFIX      cross
++        USES_TERMINAL_BUILD ON
++        CMAKE_ARGS -DCMAKE_TOOLCHAIN_FILE=${QT_HOST_PATH}/lib/cmake/Qt6/qt.toolchain.cmake
++                   -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
++                   -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
++                   -DGN_TARGET_CPU=${TEST_architecture_arch}
++    )
++    externalproject_add_stepdependencies(libs install hostBuild)
++endif()
+diff --git a/cmake/FindGn.cmake b/cmake/FindGn.cmake
+index 12a90778..abfa0fe2 100644
+--- a/cmake/FindGn.cmake
++++ b/cmake/FindGn.cmake
+@@ -1,9 +1,10 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/../..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
++endif()
++find_program(Gn_EXECUTABLE NAMES gn PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
++if(NOT QT_HOST_PATH STREQUAL "")
++   find_program(Gn_EXECUTABLE NAMES gn PATHS ${QT_HOST_PATH}/${INSTALL_LIBEXECDIR} NO_DEFAULT_PATH)
+ endif()
+-
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
+-
+ find_program(Gn_EXECUTABLE NAMES gn)
+ 
+ if(Gn_EXECUTABLE)
+diff --git a/cmake/FindNinja.cmake b/cmake/FindNinja.cmake
+index 3615d58b..720e7326 100644
+--- a/cmake/FindNinja.cmake
++++ b/cmake/FindNinja.cmake
+@@ -1,8 +1,8 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
+ endif()
+ 
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
++find_program(Ninja_EXECUTABLE NAMES ninja ninja-build PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
+ find_program(Ninja_EXECUTABLE NAMES ninja ninja-build)
+ 
+ if(Ninja_EXECUTABLE)
+diff --git a/cmake/FindPkgConfigHost.cmake b/cmake/FindPkgConfigHost.cmake
+new file mode 100644
+index 00000000..de021638
+--- /dev/null
++++ b/cmake/FindPkgConfigHost.cmake
+@@ -0,0 +1,40 @@
++# this is just simply pkg config wrapper to pass executable path to gn
++
++if(CMAKE_CROSSCOMPILING)
++   # find pkg-config, use PKG_CONFIG_HOST if set
++   if((NOT PKG_CONFIG_HOST_EXECUTABLE) AND (NOT "$ENV{PKG_CONFIG_HOST}" STREQUAL ""))
++       set(PKG_CONFIG_HOST_EXECUTABLE "$ENV{PKG_CONFIG_HOST}" CACHE FILEPATH "pkg-config host executable")
++   endif()
++
++   find_program(PKG_CONFIG_HOST_EXECUTABLE NAMES "pkg-config" DOC "pkg-config executable"
++       NO_SYSTEM_ENVIRONMENT_PATH
++       NO_CMAKE_FIND_ROOT_PATH
++   )
++
++   if(PKG_CONFIG_HOST_EXECUTABLE)
++       mark_as_advanced(PKG_CONFIG_HOST_EXECUTABLE)
++       execute_process(COMMAND ${PKG_CONFIG_HOST_EXECUTABLE} --version
++           OUTPUT_VARIABLE PKG_CONFIG_HOST_VERSION_STRING
++           OUTPUT_STRIP_TRAILING_WHITESPACE
++           ERROR_QUIET)
++   endif ()
++
++   include(FindPackageHandleStandardArgs)
++   find_package_handle_standard_args(PkgConfigHost
++       FOUND_VAR PkgConfigHost_FOUND
++       VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++       REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++   )
++else() # if not corss build simply wrap FindPkgConfig
++   find_package(PkgConfig)
++   if(PKG_CONFIG_FOUND)
++       include(FindPackageHandleStandardArgs)
++       set(PKG_CONFIG_HOST_VERSION ${PKG_CONFIG_VERSION})
++       set(PKG_CONFIG_HOST_EXECUTABLE ${PKG_CONFIG_EXECUTABLE})
++       find_package_handle_standard_args(PkgConfigHost
++           FOUND_VAR PkgConfigHost_FOUND
++           VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++           REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++       )
++  endif()
++endif()
+diff --git a/cmake/Functions.cmake b/cmake/Functions.cmake
+index d29ed7a4..3cdfdee9 100644
+--- a/cmake/Functions.cmake
++++ b/cmake/Functions.cmake
+@@ -348,3 +348,48 @@ function(qt_internal_add_external_project_dependency_to_root_project name)
+ 
+     cmake_policy(POP)
+ endfunction()
++
++function(get_gn_arch result arch)
++   if("${arch}" STREQUAL "i386")
++      set(${result} "x86" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "x86_64")
++      set(${result} "x64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm")
++      set(${result} "arm" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm64")
++      set(${result} "arm64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel")
++      set(${result} "mipsel" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel64")
++      set(${result} "mips64el" PARENT_SCOPE)
++   else()
++      message(DEBUG "Unsupported achitecture: ${arch}")
++   endif()
++endfunction()
++
++function(get_v8_arch result targetArch)
++   set(list32 i386 arm mipsel)
++   if("${targetArch}" IN_LIST list32)
++       set(${result} "i386" PARENT_SCOPE)
++   else()
++       set(${result} "x86_64" PARENT_SCOPE)
++   endif()
++endfunction()
++
++function(configure_gn_toolchain name cpuType v8CpuType toolchainIn toolchainOut)
++    set(GN_TOOLCHAIN ${name})
++    get_gn_arch(GN_CPU ${cpuType})
++    get_gn_arch(GN_V8_CPU ${v8CpuType})
++    configure_file(${toolchainIn} ${toolchainOut}/BUILD.gn @ONLY)
++endfunction()
++
++function(create_pkg_config_host_wrapper wrapperName wrapperCmd)
++    file(WRITE ${wrapperName}
++        "#!/bin/sh\n"
++        "unset PKG_CONFIG_LIBDIR\n"
++        "unset PKG_CONFIG_PATH\n"
++        "unset PKG_CONFIG_SYSROOT_DIR\n"
++        "exec ${wrapperCmd} \"$@\""
++    )
++    file(CHMOD ${wrapperName} PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE)
++endfunction()
+diff --git a/configure.cmake b/configure.cmake
+index 53392313..2a8552d7 100644
+--- a/configure.cmake
++++ b/configure.cmake
+@@ -333,9 +333,17 @@ endif()
+ assertTargets(webEngineError webEngineSupport Gui Widgets OpenGL OpenGLWidgets Quick Qml)
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION (LINUX AND NOT CMAKE_CROSSCOMPILING) OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
++   CONDITION LINUX OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
+    MESSAGE "Build can be done only on Linux, Windows or macOS."
+ )
++if(LINUX AND CMAKE_CROSSCOMPILING)
++   get_gn_arch(testArch ${TEST_architecture_arch})
++   add_check_for_support(webEngineError webEngineSupport
++       MODULE QtWebEngine
++       CONDITION testArch
++       MESSAGE "Cross compiling is not supported for ${TEST_architecture_arch}."
++   )
++endif()
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+    CONDITION NOT QT_FEATURE_static
+diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
+index fd935fe1..40d7fd8e 100644
+--- a/src/core/CMakeLists.txt
++++ b/src/core/CMakeLists.txt
+@@ -24,6 +24,11 @@ find_package(Nodejs 12.0)
+ find_package(PkgConfig)
+ if(PkgConfig_FOUND)
+     pkg_check_modules(XSCRNSAVER xscrnsaver)
++    find_package(PkgConfigHost)
++    if(CMAKE_CROSSCOMPILING)
++        create_pkg_config_host_wrapper("${buildDir}/pkg-config-host_wrapper.sh" "${PKG_CONFIG_HOST_EXECUTABLE}")
++        set(PKG_CONFIG_HOST_EXECUTABLE "${buildDir}/pkg-config-host_wrapper.sh")
++    endif()
+ endif()
+ 
+ get_target_property(qtWebEngineProcessName WebEngineCore QTWEBENGINEPROCESS_NAME)
+@@ -36,6 +41,24 @@ else()
+     set(configs ${CMAKE_BUILD_TYPE})
+ endif()
+ 
++##
++#   TOOLCHAIN SETUP
++##
++
++if(LINUX)
++    if(NOT CMAKE_CROSSCOMPILING) # delivered by hostBuild project
++        configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/host_toolchain)
++        configure_gn_toolchain(v8 ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/v8_toolchain)
++    endif()
++    configure_gn_toolchain(target ${TEST_architecture_arch} ${TEST_architecture_arch}
++        ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++        ${buildDir}/target_toolchain)
++endif()
++
+ foreach(config ${configs})
+ 
+ ##
+@@ -250,12 +273,6 @@ foreach(config ${configs})
+     configure_gn_target(${buildGn} ${config}
+         ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.root.gn.in ${buildDir}/${config}/BUILD.gn)
+ 
+-##
+-#   TOOLCHAIN SETUP
+-##
+-
+-    configure_file(${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
+-        ${buildDir}/${config}/toolchain/BUILD.gn @ONLY)
+ 
+ ##
+ #   GN CALL PARAMETERS SETUP
+@@ -419,6 +436,15 @@ foreach(config ${configs})
+         )
+     endif()
+     if(LINUX)
++        get_gn_arch(cpu ${TEST_architecture_arch})
++        if(CMAKE_CROSSCOMPILING)
++            list(APPEND gnArgArg target_cpu="${cpu}")
++        else()
++            list(APPEND gnArgArg host_cpu="${cpu}")
++        endif()
++        if(CMAKE_SYSROOT)
++            list(APPEND gnArgArg target_sysroot="${CMAKE_SYSROOT}")
++        endif()
+         list(APPEND gnArgArg
+             use_cups=false
+             use_gio=false
+@@ -435,11 +461,11 @@ foreach(config ${configs})
+             ozone_platform_external=true
+             ozone_platform="qt"
+             ozone_extra_path="${CMAKE_CURRENT_LIST_DIR}/ozone/ozone_extra.gni"
+-            custom_toolchain="${buildDir}/${config}/toolchain:target"
+-            host_toolchain="${buildDir}/${config}/toolchain:host"
+-            host_cpu="x64"
+-            pkg_config="pkg-config"
+-            host_pkg_config="/usr/bin/pkg-config"
++            custom_toolchain="${buildDir}/target_toolchain:target"
++            host_toolchain="${buildDir}/host_toolchain:host"
++            v8_snapshot_toolchain="${buildDir}/v8_toolchain:v8"
++            pkg_config="${PKG_CONFIG_EXECUTABLE}"
++            host_pkg_config="${PKG_CONFIG_HOST_EXECUTABLE}"
+             use_glib=false
+         )
+         set(systemLibs libjpeg libpng freetype harfbuzz libevent libwebp libxml
+diff --git a/src/core/api/configure.cmake b/src/core/api/configure.cmake
+index 35d28e87..0cf46bf0 100644
+--- a/src/core/api/configure.cmake
++++ b/src/core/api/configure.cmake
+@@ -143,11 +143,11 @@ qt_configure_add_summary_entry(
+     CONDITION UNIX
+ )
+ qt_configure_end_summary_section() # end of "Qt WebEngineCore" section
+-qt_configure_add_report_entry(
+-    TYPE WARNING
+-    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
+-    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
+-)
++#qt_configure_add_report_entry(
++#    TYPE WARNING
++#    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
++#    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
++#)
+ qt_configure_add_report_entry(
+     TYPE WARNING
+     MESSAGE "V8 snapshot cannot be built. Most likely, the 32-bit host compiler does not work. Please make sure you have 32-bit devel environment installed."
+diff --git a/src/core/configure/BUILD.toolchain.gn.in b/src/core/configure/BUILD.toolchain.gn.in
+index e44fa42d..c1bf3845 100644
+--- a/src/core/configure/BUILD.toolchain.gn.in
++++ b/src/core/configure/BUILD.toolchain.gn.in
+@@ -1,6 +1,6 @@
+ import("//build/config/sysroot.gni")
+ import("//build/toolchain/gcc_toolchain.gni")
+-gcc_toolchain("host") {
++gcc_toolchain("@GN_TOOLCHAIN@") {
+   cc = "@CMAKE_C_COMPILER@"
+   cxx = "@CMAKE_CXX_COMPILER@"
+   ld = "@CMAKE_CXX_COMPILER@"
+@@ -9,34 +9,8 @@ gcc_toolchain("host") {
+   extra_cppflags = ""
+   toolchain_args = {
+     current_os = "linux"
+-    current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+-}
+-gcc_toolchain("v8_snapshot") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
+-    v8_current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+- }
+-gcc_toolchain("target") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
++    current_cpu = "@GN_CPU@"
++    v8_current_cpu = "@GN_V8_CPU@"
+     is_clang = false
+     use_gold = false
+   }
+diff --git a/src/core/configure/CMakeLists.txt b/src/core/configure/CMakeLists.txt
+new file mode 100644
+index 00000000..0ae4b4b4
+--- /dev/null
++++ b/src/core/configure/CMakeLists.txt
+@@ -0,0 +1,35 @@
++cmake_minimum_required(VERSION 3.19)
++
++if(NOT DEFINED WEBENGINE_ROOT_SOURCE_DIR)
++    get_filename_component(WEBENGINE_ROOT_SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/../../.." REALPATH)
++endif()
++if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
++    get_filename_component(WEBENGINE_ROOT_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}/../../.." REALPATH)
++endif()
++
++include(${WEBENGINE_ROOT_SOURCE_DIR}/.cmake.conf)
++include(${WEBENGINE_ROOT_SOURCE_DIR}/cmake/Functions.cmake)
++
++set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${WEBENGINE_ROOT_SOURCE_DIR}/cmake")
++
++project(QtWebEngineConfigure
++    VERSION "${QT_REPO_MODULE_VERSION}"
++    LANGUAGES CXX C)
++
++find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals Core)
++
++set(buildDir ${CMAKE_CURRENT_BINARY_DIR})
++configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/host_toolchain
++)
++install(FILES ${buildDir}/host_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/host_toolchain
++    )
++get_v8_arch(GN_V8_HOST_CPU ${GN_TARGET_CPU})
++configure_gn_toolchain(v8 ${GN_V8_HOST_CPU} ${GN_TARGET_CPU}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/v8_toolchain)
++install(FILES ${buildDir}/v8_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/v8_toolchain
++)
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
new file mode 100644
index 000000000000..d4b22c77ce96
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/mojo/public/cpp/platform/named_platform_channel_posix.cc	2021-03-08 10:30:42.504006604 +0100
++++ -	2021-03-08 10:31:27.415366585 +0100
+@@ -8,6 +8,7 @@
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <unistd.h>
++#include <cstring>
+ 
+ #include "base/files/file_util.h"
+ #include "base/files/scoped_file.h"
diff --git a/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
new file mode 100644
index 000000000000..de6d5abb4461
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
@@ -0,0 +1,26 @@
+From 8eece1b0c72bef7319069703031543ddd0ca87ee Mon Sep 17 00:00:00 2001
+From: John Zimmermann <me@johnnynator.dev>
+Date: Sun, 27 Jun 2021 20:35:15 +0200
+Subject: [PATCH 2/2] Do not use target C{XX}FLAGS for host cmake
+
+Change-Id: Ia66d153fa9f1aff63491f6a1ec7380b8bda1e3c7
+---
+ CMakeLists.txt | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 2a93dca5..2a8e6cfb 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -238,6 +238,8 @@ if(CMAKE_CROSSCOMPILING)
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+                    -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
+                    -DGN_TARGET_CPU=${TEST_architecture_arch}
++                   -DCMAKE_CXX_FLAGS=$ENV{CXXFLAGS_FOR_BUILD}
++                   -DCMAKE_C_FLAGS=$ENV{CFLAGS_FOR_BUILD}
+     )
+     externalproject_add_stepdependencies(libs install hostBuild)
+ endif()
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
new file mode 100644
index 000000000000..4a428fe03b37
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
@@ -0,0 +1,11 @@
+--- a/src/core/CMakeLists.txt	2021-06-27 14:24:18.812840134 +0200
++++ b/src/core/CMakeLists.txt	2021-06-27 14:51:46.825108637 +0200
+@@ -299,6 +299,8 @@
+         endif()
+     elseif(${config} STREQUAL "MinSizeRel")
+         list(APPEND gnArgArg is_debug=false symbol_level=0 optimize_for_size=true)
++    elseif(${config} STREQUAL "None")
++        list(APPEND gnArgArg is_debug=false symbol_level=0)
+     endif()
+ 
+     list(APPEND gnArgArg
diff --git a/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
new file mode 100644
index 000000000000..da4160b21bd3
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
@@ -0,0 +1,26 @@
+From 9001c54d6b974449174a8cee8f3f5d78a9bd6c9e Mon Sep 17 00:00:00 2001
+From: Felix Janda <felix.janda@posteo.de>
+Date: Sun, 1 Feb 2015 14:26:52 +0100
+Subject: [PATCH 3/6] include <sys/reg.h> to get __WORDSIZE on musl libc
+
+---
+ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/common/linux/elf_core_dump.h b/src/common/linux/elf_core_dump.h
+index d03c7a8..02eb391 100644
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
+@@ -36,6 +36,9 @@
+ #include <elf.h>
+ #include <link.h>
+ #include <stddef.h>
++#ifndef __GLIBC__
++#include <sys/reg.h>
++#endif
+ 
+ #include "common/memory_range.h"
+ 
+-- 
+2.0.5
+
diff --git a/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
new file mode 100644
index 000000000000..de32a3dab95c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
@@ -0,0 +1,103 @@
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+@@ -6,6 +6,7 @@
+ 
+ #include <malloc.h>
+ 
++#if defined(__GLIBC__)
+ // This translation unit defines a default dispatch for the allocator shim which
+ // routes allocations to libc functions.
+ // The code here is strongly inspired from tcmalloc's libc_override_glibc.h.
+@@ -73,3 +74,92 @@ const AllocatorDispatch AllocatorDispatch::default_dispatch = {
+     nullptr,               /* free_definite_size_function */
+     nullptr,               /* next */
+ };
++
++#else // defined(__GLIBC__)
++
++#include <dlfcn.h>
++
++extern "C" {
++// Declare function pointers to the memory functions
++typedef void* (*t_libc_malloc)(size_t size);
++typedef void* (*t_libc_calloc)(size_t n, size_t size);
++typedef void* (*t_libc_realloc)(void* address, size_t size);
++typedef void* (*t_libc_memalign)(size_t alignment, size_t size);
++typedef void (*t_libc_free)(void* ptr);
++typedef size_t (*t_libc_malloc_usable_size)(void* ptr);
++
++// Static instances of pointers to libc.so dl symbols
++static t_libc_malloc libc_malloc = NULL;
++static t_libc_calloc libc_calloc = NULL;
++static t_libc_realloc libc_realloc = NULL;
++static t_libc_memalign libc_memalign = NULL;
++static t_libc_free libc_free = NULL;
++static t_libc_malloc_usable_size libc_malloc_usable_size = NULL;
++
++// resolve the symbols in libc.so
++void musl_libc_memory_init(void)
++{
++  libc_malloc = (t_libc_malloc) dlsym(RTLD_NEXT, "malloc");
++  libc_calloc = (t_libc_calloc) dlsym(RTLD_NEXT, "calloc");
++  libc_realloc = (t_libc_realloc) dlsym(RTLD_NEXT, "realloc");
++  libc_memalign = (t_libc_memalign) dlsym(RTLD_NEXT, "memalign");
++  libc_free = (t_libc_free) dlsym(RTLD_NEXT, "free");
++  libc_malloc_usable_size = (t_libc_malloc_usable_size) dlsym(RTLD_NEXT, "malloc_usable_size");
++}
++}  // extern "C"
++
++namespace {
++
++using base::allocator::AllocatorDispatch;
++
++void* MuslMalloc(const AllocatorDispatch*, size_t size, void* context) {
++  if (!libc_malloc)
++    musl_libc_memory_init();
++  return (*libc_malloc)(size);
++}
++
++void* MuslCalloc(const AllocatorDispatch*, size_t n, size_t size, void* context) {
++  if (!libc_calloc)
++    musl_libc_memory_init();
++  return (*libc_calloc)(n, size);
++}
++
++void* MuslRealloc(const AllocatorDispatch*, void* address, size_t size, void* context) {
++  if (!libc_realloc)
++    musl_libc_memory_init();
++  return (*libc_realloc)(address, size);
++}
++
++void* MuslMemalign(const AllocatorDispatch*, size_t alignment, size_t size, void* context) {
++  if (!libc_memalign)
++    musl_libc_memory_init();
++  return (*libc_memalign)(alignment, size);
++}
++
++void MuslFree(const AllocatorDispatch*, void* address, void* context) {
++  if (!libc_free)
++    musl_libc_memory_init();
++  (*libc_free)(address);
++}
++
++size_t MuslGetSizeEstimate(const AllocatorDispatch*, void* address, void* context) {
++  // TODO(siggi, primiano): malloc_usable_size may need redirection in the
++  //     presence of interposing shims that divert allocations.
++  if (!libc_malloc_usable_size)
++    musl_libc_memory_init();
++  return (*libc_malloc_usable_size)(address);
++}
++
++}  // namespace
++
++const AllocatorDispatch AllocatorDispatch::default_dispatch = {
++    &MuslMalloc,           /* alloc_function */
++    &MuslCalloc,           /* alloc_zero_initialized_function */
++    &MuslMemalign,         /* alloc_aligned_function */
++    &MuslRealloc,          /* realloc_function */
++    &MuslFree,             /* free_function */
++    &MuslGetSizeEstimate,  /* get_size_estimate_function */
++    nullptr,               /* next */
++};
++
++#endif
diff --git a/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
new file mode 100644
index 000000000000..36900f907833
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
@@ -0,0 +1,39 @@
+--- qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2017-11-28 14:06:53.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2018-01-27 20:13:26.960932805 +0100
+@@ -243,7 +243,7 @@
+   allocated_objects_count = main_heap_info.block_count;
+ #elif defined(OS_FUCHSIA)
+ // TODO(fuchsia): Port, see https://crbug.com/706592.
+-#else
++#elif defined(__GLIBC__)
+   struct mallinfo info = mallinfo();
+   DCHECK_GE(info.arena + info.hblkhd, info.uordblks);
+ 
+@@ -255,6 +255,8 @@
+ 
+   // Total allocated space is given by |uordblks|.
+   allocated_objects_size = info.uordblks;
++#else
++// musl libc does not support mallinfo()
+ #endif
+ 
+   MemoryAllocatorDump* outer_dump = pmd->CreateAllocatorDump("malloc");
+--- qtwebengine/src/3rdparty/chromium/base/process/process_metrics_posix.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:03:38.579424720 +0100
+@@ -119,14 +119,14 @@
+   malloc_statistics_t stats = {0};
+   malloc_zone_statistics(nullptr, &stats);
+   return stats.size_in_use;
+-#elif defined(OS_LINUX) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
++#elif (defined(OS_LINUX) && defined(__GLIBC__)) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
+   struct mallinfo minfo = mallinfo();
+ #if BUILDFLAG(USE_TCMALLOC)
+   return minfo.uordblks;
+ #else
+   return minfo.hblkhd + minfo.arena;
+ #endif
+-#elif defined(OS_FUCHSIA)
++#else //if defined(OS_FUCHSIA) // also musl doesn't do this.
+   // TODO(fuchsia): Not currently exposed. https://crbug.com/735087.
+   return 0;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
new file mode 100644
index 000000000000..52db3b9ebf46
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
@@ -0,0 +1,10 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-05-26 14:58:54.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-10-01 14:31:30.885000000 +0200
+@@ -21,6 +21,7 @@
+ #define htons(x) _byteswap_ushort (x)
+ #else
+ #include <arpa/inet.h>
++#include <sys/types.h>
+ #include <stdint.h>
+ #endif
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
new file mode 100644
index 000000000000..00017bba0172
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
@@ -0,0 +1,18 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:26.639964100 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:11.611964995 +0200
+@@ -1794,6 +1794,15 @@
+ /* End of s390/s390x definitions                                             */
+ #endif
+ 
++#ifndef __GLIBC__
++  /* For Musl libc pread/pread is the same as pread64/pwrite64 */
++#ifndef __NR_pread
++#define __NR_pread              __NR_pread64
++#endif
++#ifndef __NR_pwrite
++#define __NR_pwrite             __NR_pwrite64
++#endif
++#endif /* ifndef __GLIBC__ */
+ 
+ /* After forking, we must make sure to only call system calls.               */
+ #if defined(__BOUNDED_POINTERS__)
diff --git a/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
new file mode 100644
index 000000000000..edfceb79f30a
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
@@ -0,0 +1,26 @@
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-12-20 03:33:11.749059656 +0100
+@@ -9,6 +9,10 @@
+ 
+ #include <resolv.h>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/lazy_instance.h"
+ #include "base/logging.h"
+ #include "base/macros.h"
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-12-20 03:40:07.671953098 +0100
+@@ -6,6 +6,10 @@
+ 
+ #include <string>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/bind.h"
+ #include "base/files/file.h"
+ #include "base/files/file_path.h"
diff --git a/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
new file mode 100644
index 000000000000..fe760be16664
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
@@ -0,0 +1,18 @@
+There's a subtle difference in the internal name of siginfo_t fields
+between glibc and musl. The structure itself is equivalent, so it
+should suffice to add a macro to rename the field.
+
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-02-17 05:57:43.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-06-03 08:20:25.032716427 +0200
+@@ -22,6 +22,11 @@
+ #include "sandbox/linux/services/android_ucontext.h"
+ #endif
+
++// musl libc defines siginfo_t __si_fields instead of _sifields
++#if !defined(__GLIBC__)
++#define _sifields __si_fields
++#endif
++
+ namespace {
+
+ const int kCapacityIncrement = 20;
diff --git a/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
new file mode 100644
index 000000000000..a9f8ab6c252c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
@@ -0,0 +1,20 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:08:43.586475349 +0100
++++ qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:18:22.274505203 +0100
+@@ -28,7 +28,7 @@
+ // FIXME: On Mac OSX and Linux, this method cannot estimate stack size
+ // correctly for the main thread.
+ 
+-#elif defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#elif defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   // pthread_getattr_np() can fail if the thread is not invoked by
+   // pthread_create() (e.g., the main thread of blink_unittests).
+@@ -96,7 +96,7 @@
+ }
+ 
+ void* GetStackStart() {
+-#if defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#if defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   pthread_attr_t attr;
+   int error;
diff --git a/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
new file mode 100644
index 000000000000..d3de1e41183d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
@@ -0,0 +1,71 @@
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-09-13 19:53:53.453780253 +0200
+@@ -129,7 +129,7 @@
+ // CLONE_VM, nor CLONE_THREAD, which includes all fork() implementations.
+ ResultExpr RestrictCloneToThreadsAndEPERMFork() {
+   const Arg<unsigned long> flags(0);
+-
++#if defined(__GLIBC__)
+   // TODO(mdempsky): Extend DSL to support (flags & ~mask1) == mask2.
+   const uint64_t kAndroidCloneMask = CLONE_VM | CLONE_FS | CLONE_FILES |
+                                      CLONE_SIGHAND | CLONE_THREAD |
+@@ -148,6 +148,17 @@
+   return If(IsAndroid() ? android_test : glibc_test, Allow())
+       .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
+       .Else(CrashSIGSYSClone());
++#else
++  const int required = CLONE_VM | CLONE_FS | CLONE_FILES | CLONE_SIGHAND |
++                       CLONE_THREAD | CLONE_SYSVSEM;
++  const int safe = CLONE_SETTLS | CLONE_PARENT_SETTID | CLONE_CHILD_CLEARTID |
++                   CLONE_DETACHED;
++  const BoolExpr thread_clone_ok = (flags&~safe)==required;
++
++  return If(thread_clone_ok, Allow())
++      .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
++      .Else(CrashSIGSYSClone());
++#endif
+ }
+ 
+ ResultExpr RestrictPrctl() {
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-09-13 19:56:31.779773940 +0200
+@@ -375,6 +375,9 @@
+ #if defined(__i386__)
+     case __NR_waitpid:
+ #endif
++#if !defined(__GLIBC__)
++    case __NR_set_tid_address:
++#endif
+       return true;
+     case __NR_clone:  // Should be parameter-restricted.
+     case __NR_setns:  // Privileged.
+@@ -387,7 +390,9 @@
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
+     case __NR_set_thread_area:
+ #endif
++#if defined(__GLIBC__)
+     case __NR_set_tid_address:
++#endif
+     case __NR_unshare:
+ #if !defined(__mips__) && !defined(__aarch64__)
+     case __NR_vfork:
+@@ -496,6 +501,9 @@
+     case __NR_mlock:
+     case __NR_munlock:
+     case __NR_munmap:
++#if !defined(__GLIBC__)
++    case __NR_mremap:
++#endif
+       return true;
+     case __NR_madvise:
+     case __NR_mincore:
+@@ -511,7 +519,9 @@
+     case __NR_modify_ldt:
+ #endif
+     case __NR_mprotect:
++#if defined(__GLIBC__)
+     case __NR_mremap:
++#endif
+     case __NR_msync:
+     case __NR_munlockall:
+     case __NR_readahead:
diff --git a/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
new file mode 100644
index 000000000000..7bf5a22fba71
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
@@ -0,0 +1,15 @@
+--- qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc.orig	2018-09-19 18:05:15.523923703 +0200
++++ qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc	2018-09-19 18:08:05.150932454 +0200
+@@ -173,7 +173,12 @@
+ 
+ size_t GetDefaultThreadStackSize(const pthread_attr_t& attributes) {
+ #if !defined(THREAD_SANITIZER)
++#if defined(__GLIBC__)
+   return 0;
++#else // defined(__GLIBC__)
++  // For Musl libc try with a default stack size of 2 MiB
++  return 2 * 1024 * 1024;
++#endif // !defined(__GLIBC__)
+ #else
+   // ThreadSanitizer bloats the stack heavily. Evidence has been that the
+   // default stack size isn't enough for some browser tests.
diff --git a/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
new file mode 100644
index 000000000000..140742f72c25
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
@@ -0,0 +1,30 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-11-22 00:41:58.522477559 +0100
+@@ -38,7 +38,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_ptrace_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <errno.h>
+ #include <fcntl.h>
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-11-22 00:49:39.533492245 +0100
+@@ -32,7 +32,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_core_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <elf.h>
+ #include <stdio.h>
diff --git a/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
new file mode 100644
index 000000000000..f6c3aadb8421
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
@@ -0,0 +1,14 @@
+--- a/configure.cmake	2021-06-21 23:31:04.000000000 +0200
++++ -	2021-06-27 16:16:32.873528917 +0200
+@@ -373,11 +373,6 @@
+ )
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION NOT LINUX OR TEST_glibc
+-   MESSAGE "A suitable version >= 2.17 of glibc is required."
+-)
+-add_check_for_support(webEngineError webEngineSupport
+-   MODULE QtWebEngine
+    CONDITION NOT LINUX OR TEST_khr
+    MESSAGE "Build requires Khronos development headers for build - see mesa/libegl1-mesa-dev"
+ )
diff --git a/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
new file mode 100644
index 000000000000..608dd0b4e078
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
@@ -0,0 +1,106 @@
+--- qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc.orig	2019-04-09 09:31:16.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc	2019-05-06 23:16:13.245502467 +0200
+@@ -27,7 +27,7 @@
+ #if !defined(USE_SYMBOLIZE)
+ #include <cxxabi.h>
+ #endif
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ #include <execinfo.h>
+ #endif
+ 
+@@ -86,7 +86,7 @@
+   // Note: code in this function is NOT async-signal safe (std::string uses
+   // malloc internally).
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   std::string::size_type search_from = 0;
+   while (search_from < text->size()) {
+     // Look for the start of a mangled symbol, from search_from.
+@@ -121,7 +121,7 @@
+       search_from = mangled_start + 2;
+     }
+   }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ }
+ #endif  // !defined(USE_SYMBOLIZE)
+ 
+@@ -133,7 +133,7 @@
+   virtual ~BacktraceOutputHandler() = default;
+ };
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void OutputPointer(void* pointer, BacktraceOutputHandler* handler) {
+   // This should be more than enough to store a 64-bit number in hex:
+   // 16 hex digits + 1 for null-terminator.
+@@ -216,7 +216,7 @@
+   }
+ #endif  // defined(USE_SYMBOLIZE)
+ }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ 
+ void PrintToStderr(const char* output) {
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+@@ -812,7 +812,7 @@
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+   // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   // Though the backtrace API man page does not list any possible negative
+   // return values, we take no chance.
+   return base::saturated_cast<size_t>(backtrace(trace, count));
+@@ -825,13 +825,13 @@
+ // NOTE: This code MUST be async-signal safe (it's used by in-process
+ // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   PrintBacktraceOutputHandler handler;
+   ProcessBacktrace(trace_, count_, prefix_string, &handler);
+ #endif
+ }
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void StackTrace::OutputToStreamWithPrefix(std::ostream* os,
+                                           const char* prefix_string) const {
+   StreamBacktraceOutputHandler handler(os);
+--- qtwebengine/src/3rdparty/chromium/base/debug/stack_trace.cc	2019-04-09 09:31:16.000000000 +0200
++++ -	2019-05-06 23:18:14.923566992 +0200
+@@ -233,7 +233,7 @@
+ }
+ std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
+   std::stringstream stream;
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(&stream, prefix_string);
+ #endif
+   return stream.str();
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2017-11-28 14:06:53.000000000 +0100
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2018-01-27 22:46:34.970406807 +0100
+@@ -546,7 +546,7 @@
+ 
+ LogMessage::~LogMessage() {
+   size_t stack_start = stream_.tellp();
+-#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && !defined(__UCLIBC__) && \
++#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && defined(__GLIBC__) && \
+     !defined(OS_AIX)
+   if (severity_ == LOG_FATAL && !base::debug::BeingDebugged()) {
+     // Include a stack trace on a fatal, unless a debugger is attached.
+--- a/src/3rdparty/chromium/base/debug/stack_trace.cc	2021-06-27 18:17:06.834705848 +0200
++++ -	2021-06-27 18:27:53.014102803 +0200
+@@ -217,7 +217,9 @@
+ }
+ 
+ void StackTrace::OutputToStream(std::ostream* os) const {
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(os, nullptr);
++#endif
+ }
+ 
+ std::string StackTrace::ToString() const {
diff --git a/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
new file mode 100644
index 000000000000..496753bef30f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
@@ -0,0 +1,26 @@
+diff --git a/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc b/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+index 02bf49b..05ee182 100644
+--- qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
++++ qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+@@ -13,7 +13,7 @@ namespace pp {
+ namespace {
+ 
+ // Use 2MB default stack size for Native Client, otherwise use system default.
+-#if defined(__native_client__)
++#if defined(__native_client__) || !defined(__GLIBC__)
+ const size_t kDefaultStackSize = 2 * 1024 * 1024;
+ #else
+ const size_t kDefaultStackSize = 0;
+diff --git a/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc b/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+index cf7f3ec..e06a5ce 100644
+--- qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
++++ qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+@@ -761,7 +761,7 @@ void Thread::Start() {
+ #if V8_OS_MACOSX
+     // Default on Mac OS X is 512kB -- bump up to 1MB
+     stack_size = 1 * 1024 * 1024;
+-#elif V8_OS_AIX
++#elif V8_OS_AIX || !defined(__GLIBC__)
+     // Default on AIX is 96kB -- bump up to 2MB
+     stack_size = 2 * 1024 * 1024;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
new file mode 100644
index 000000000000..b73971f24324
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
@@ -0,0 +1,60 @@
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
+@@ -1063,4 +1063,8 @@
+ #define __NR_memfd_create 279
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 283
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_ARM64_LINUX_SYSCALLS_H_
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,10 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier (__NR_SYSCALL_BASE+389)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
+@@ -1422,5 +1422,9 @@
+ #define __NR_memfd_create 356
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 375
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_32_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
+@@ -1290,5 +1290,9 @@
+ #define __NR_memfd_create 319
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 324
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -370,6 +370,7 @@
+   switch (sysno) {
+     case __NR_exit:
+     case __NR_exit_group:
++    case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+ #if defined(__i386__)
diff --git a/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
new file mode 100644
index 000000000000..75481a2889f4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
@@ -0,0 +1,14 @@
+--- qtwebengine-everywhere-src-5.14.0-beta2/src/3rdparty/chromium/net/socket/udp_socket_posix.cc	2019-10-08 08:27:43.000000000 +0200
++++ -	2019-11-11 22:41:46.699068889 +0100
+@@ -1191,7 +1191,11 @@
+     msg_iov->push_back({const_cast<char*>(buffer->data()), buffer->length()});
+   msgvec->reserve(buffers.size());
+   for (size_t j = 0; j < buffers.size(); j++)
++#if defined(__GLIBC__)
+     msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, nullptr, 0, 0}, 0});
++#else
++    msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, 0, 0, 0}, 0});
++#endif
+   int result = HANDLE_EINTR(Sendmmsg(fd, &msgvec[0], buffers.size(), 0));
+   SendResult send_result(0, 0, std::move(buffers));
+   if (result < 0) {
diff --git a/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
new file mode 100644
index 000000000000..d8c6aa15cf66
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
@@ -0,0 +1,26 @@
+Allow SYS_sched_getparam and SYS_sched_getscheduler
+musl uses them for pthread_getschedparam()
+
+source: https://git.alpinelinux.org/aports/commit/community/chromium?id=54af9f8ac24f52d382c5758e2445bf0206eff40e
+
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:13:44.992079145 +0100
+@@ -93,11 +93,18 @@
+     case __NR_sysinfo:
+     case __NR_times:
+     case __NR_uname:
++#if !defined(__GLIBC__)
++    case __NR_sched_getparam:
++    case __NR_sched_getscheduler:
++    case __NR_sched_setscheduler:
++#endif
+       return Allow();
+     case __NR_sched_getaffinity:
++#if defined(__GLIBC__)
+     case __NR_sched_getparam:
+     case __NR_sched_getscheduler:
+     case __NR_sched_setscheduler:
++#endif
+       return RestrictSchedTarget(GetPolicyPid(), sysno);
+     case __NR_prlimit64:
+       // See crbug.com/662450 and setrlimit comment above.
diff --git a/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
new file mode 100644
index 000000000000..893ed2d41bb4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
@@ -0,0 +1,11 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/nasm/nasmlib/realpath.c	2019-09-23 14:24:20.000000000 +0200
++++ -	2019-10-11 06:27:28.450329986 +0200
+@@ -57,7 +57,7 @@
+  */
+ char *nasm_realpath(const char *rel_path)
+ {
+-    char *rp = canonicalize_file_name(rel_path);
++    char *rp = realpath(rel_path, NULL);
+     return rp ? rp : nasm_strdup(rel_path);
+ }
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
new file mode 100644
index 000000000000..4fb19ccdd2e5
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
@@ -0,0 +1,37 @@
+From 463f1234c57a36e78ff666bd55094a9d4e68f296 Mon Sep 17 00:00:00 2001
+From: q66 <daniel@octaforge.org>
+Date: Sat, 18 Jan 2020 23:52:55 +0100
+Subject: [PATCH 1/3] Enable ppc64 builds
+
+---
+ configure.pri                  | 1 +
+ mkspecs/features/functions.prf | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/configure.pri b/configure.pri
+index 3a144e3f8..cabe8b24a 100644
+--- a/configure.pri	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:18:43.124754796 +0100
+@@ -144,6 +144,7 @@
+     contains(QT_ARCH, "arm")|contains(QT_ARCH, "arm64"): return(true)
+     contains(QT_ARCH, "mips"): return(true)
+     contains(QT_ARCH, "mips64"): return(true)
++    contains(QT_ARCH, "power64"): return(true)
+     qtLog("Architecture not supported.")
+     return(false)
+ }
+diff --git a/mkspecs/features/functions.prf b/mkspecs/features/functions.prf
+index 512e2523b..e31123654 100644
+--- a/mkspecs/features/functions.prf	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:19:21.345036293 +0100
+@@ -107,6 +107,7 @@
+     contains(qtArch, "mips"): return(mipsel)
+     contains(qtArch, "mips64"): return(mips64el)
+     contains(qtArch, "mips64el"): return(mips64el)
++    contains(qtArch, "power64"): return(ppc64)
+     return(unknown)
+ }
+ 
+-- 
+2.26.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0110-size_t.patch b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
new file mode 100644
index 000000000000..462e3202279f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
@@ -0,0 +1,16 @@
+--- a/src/3rdparty/chromium/third_party/angle/include/platform/PlatformMethods.h	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:44:25.477989726 +0100
+@@ -239,11 +239,11 @@
+ using ProgramKeyType   = std::array<uint8_t, 20>;
+ using CacheProgramFunc = void (*)(PlatformMethods *platform,
+                                   const ProgramKeyType &key,
+-                                  size_t programSize,
++                                  std::size_t programSize,
+                                   const uint8_t *programBytes);
+ inline void DefaultCacheProgram(PlatformMethods *platform,
+                                 const ProgramKeyType &key,
+-                                size_t programSize,
++                                std::size_t programSize,
+                                 const uint8_t *programBytes)
+ {}
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
new file mode 100644
index 000000000000..368099b981cc
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/skia/BUILD.gn	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/skia/BUILD.gn	2020-10-06 20:51:48.834970455 +0200
+@@ -772,7 +772,6 @@
+         # Root build config sets -mfpu=$arm_fpu, which we expect to be neon
+         # when running this.
+         if (!arm_use_neon) {
+-          configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
+           cflags += [ "-mfpu=neon" ]
+         }
+       }
diff --git a/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
new file mode 100644
index 000000000000..6e2d62f35ee6
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
@@ -0,0 +1,20 @@
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -17,6 +17,17 @@
+ 
+ #include <stdint.h>
+ #include <sys/user.h>
++#if !defined(__GLIBC__)
++struct user_vfp {
++	unsigned long long fpregs[32];
++	unsigned long fpscr;
++};
++struct user_vfp_exc {
++	unsigned long fpexc;
++	unsigned long fpinst;
++	unsigned long fpinst2;
++};
++#endif /* !defined(__GLIBC__) */
+ 
+ #include <type_traits>
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
new file mode 100644
index 000000000000..5c7cbfc46f65
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
@@ -0,0 +1,18 @@
+--- a/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-10-06 21:28:45.124882085 +0200
+@@ -109,6 +109,15 @@
+ #define HWCAP_IDIV  (HWCAP_IDIVA | HWCAP_IDIVT)
+ #define HWCAP_LPAE  (1 << 20)
+ 
++#ifndef __GLIBC__
++#include <elf.h>
++#ifdef __LP64__
++typedef Elf64_auxv_t elf_auxv_t;
++#else
++typedef Elf32_auxv_t elf_auxv_t;
++#endif
++#endif
++
+ static uint32_t ReadELFHWCaps() {
+ #if V8_GLIBC_PREREQ(2, 16)
+   return static_cast<uint32_t>(getauxval(AT_HWCAP));
diff --git a/srcpkgs/qt6-webengine/patches/0114-time64.patch b/srcpkgs/qt6-webengine/patches/0114-time64.patch
new file mode 100644
index 000000000000..6a98dd4e480e
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0114-time64.patch
@@ -0,0 +1,89 @@
+Description: fix seccomp-bpf failures in syscalls 0403, 0407
+ glibc ≥ 2.31 uses these syscalls on 32-bit platforms:
+ .
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=2e44b10b42d68d98
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=ec138c67cbda8b58
+Author: Andreas Müller <schnitzeltony@gmail.com>
+Forwarded: no
+Last-Update: 2020-09-02
+
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -148,7 +148,14 @@ ResultExpr EvaluateSyscallImpl(int fs_de
+     return Allow();
+ #endif
+ 
+-  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep) {
++  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep
++#if defined(__NR_clock_gettime64)
++                                  || sysno == __NR_clock_gettime64
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++                                  || sysno == __NR_clock_nanosleep_time64
++#endif
++  ) {
+     return RestrictClockID();
+   }
+ 
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
+@@ -60,6 +60,12 @@ class RestrictClockIdPolicy : public bpf
+       case __NR_clock_gettime:
+       case __NR_clock_getres:
+       case __NR_clock_nanosleep:
++#if defined(__NR_clock_nanosleep_time64)
++      case __NR_clock_nanosleep_time64:
++#endif
++#if defined(__NR_clock_gettime64)
++      case __NR_clock_gettime64:
++#endif
+         return RestrictClockID();
+       default:
+         return Allow();
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -39,6 +39,12 @@ bool SyscallSets::IsAllowedGettime(int s
+                                 // filtered by RestrictClokID().
+     case __NR_clock_gettime:    // Parameters filtered by RestrictClockID().
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
++#if defined(__NR_clock_gettime64)
++    case __NR_clock_gettime64:  // Parameters filtered by RestrictClockID().
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++    case __NR_clock_nanosleep_time64:  // Parameters filtered by RestrictClockID().
++#endif
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,14 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_SYSCALL_BASE+403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_SYSCALL_BASE+407)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
+@@ -1433,4 +1433,12 @@
+ #define __NR_memfd_create (__NR_Linux + 354)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_Linux + 403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_Linux + 407)
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_MIPS_LINUX_SYSCALLS_H_
diff --git a/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
new file mode 100644
index 000000000000..3a0ba3b2d854
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
@@ -0,0 +1,144 @@
+# Patch made by Kevin Kofler <Kevin@tigcc.ticalc.org>
+# https://bugzilla.redhat.com/show_bug.cgi?id=1904652
+
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2021-01-20 02:14:53.066223906 +0100
+@@ -257,6 +257,18 @@
+     return RestrictKillTarget(current_pid, sysno);
+   }
+ 
++#if defined(__NR_newfstatat)
++  if (sysno == __NR_newfstatat) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
++#if defined(__NR_fstatat64)
++  if (sysno == __NR_fstatat64) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
+   if (SyscallSets::IsFileSystem(sysno) ||
+       SyscallSets::IsCurrentDirectory(sysno)) {
+     return Error(fs_denied_errno);
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2021-01-22 19:02:55.651668257 +0100
+@@ -6,6 +6,8 @@
+ 
+ #include "sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h"
+ 
++#include <errno.h>
++#include <fcntl.h>
+ #include <stddef.h>
+ #include <stdint.h>
+ #include <string.h>
+@@ -355,6 +357,35 @@
+   return -ENOSYS;
+ }
+ 
++intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args,
++                            void* aux) {
++  switch (args.nr) {
++#if defined(__NR_newfstatat)
++    case __NR_newfstatat:
++#endif
++#if defined(__NR_fstatat64)
++    case __NR_fstatat64:
++#endif
++#if defined(__NR_newfstatat) || defined(__NR_fstatat64)
++      if (*reinterpret_cast<const char *>(args.args[1]) == '\0'
++          && args.args[3] == static_cast<uint64_t>(AT_EMPTY_PATH)) {
++        return sandbox::sys_fstat64(static_cast<int>(args.args[0]),
++                                    reinterpret_cast<struct stat64 *>(args.args[2]));
++      } else {
++        errno = EACCES;
++        return -1;
++      }
++      break;
++#endif
++  }
++
++  CrashSIGSYS_Handler(args, aux);
++
++  // Should never be reached.
++  RAW_CHECK(false);
++  return -ENOSYS;
++}
++
+ bpf_dsl::ResultExpr CrashSIGSYS() {
+   return bpf_dsl::Trap(CrashSIGSYS_Handler, NULL);
+ }
+@@ -387,6 +418,10 @@
+   return bpf_dsl::Trap(SIGSYSSchedHandler, NULL);
+ }
+ 
++bpf_dsl::ResultExpr RewriteFstatatSIGSYS() {
++  return bpf_dsl::Trap(SIGSYSFstatatHandler, NULL);
++}
++
+ void AllocateCrashKeys() {
+ #if !defined(OS_NACL_NONSFI)
+   if (seccomp_crash_key)
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2021-01-20 02:11:04.583714199 +0100
+@@ -62,6 +62,10 @@
+ // sched_setparam(), sched_setscheduler()
+ SANDBOX_EXPORT intptr_t SIGSYSSchedHandler(const arch_seccomp_data& args,
+                                            void* aux);
++// If the fstatat syscall is actually a disguised fstat, calls the regular fstat
++// syscall, otherwise, crashes in the same way as CrashSIGSYS_Handler.
++SANDBOX_EXPORT intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args, 
++                                             void* aux);
+ 
+ // Variants of the above functions for use with bpf_dsl.
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYS();
+@@ -72,6 +76,7 @@
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSFutex();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSPtrace();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteSchedSIGSYS();
++SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteFstatatSIGSYS();
+ 
+ // Allocates a crash key so that Seccomp information can be recorded.
+ void AllocateCrashKeys();
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2021-01-20 02:41:12.033133269 +0100
+@@ -261,4 +261,13 @@
+ 
+ #endif  // defined(MEMORY_SANITIZER)
+ 
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf)
++{
++#if defined(__NR_fstat64)
++    return syscall(__NR_fstat64, fd, buf);
++#else
++    return syscall(__NR_fstat, fd, buf);
++#endif
++}
++
+ }  // namespace sandbox
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2021-01-20 02:40:26.499827829 +0100
+@@ -17,6 +17,7 @@
+ struct rlimit64;
+ struct cap_hdr;
+ struct cap_data;
++struct stat64;
+ 
+ namespace sandbox {
+ 
+@@ -84,6 +85,9 @@
+                                  const struct sigaction* act,
+                                  struct sigaction* oldact);
+ 
++// Recent glibc rewrites fstat to fstatat.
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf);
++
+ }  // namespace sandbox
+ 
+ #endif  // SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_
diff --git a/srcpkgs/qt6-webengine/template b/srcpkgs/qt6-webengine/template
new file mode 100644
index 000000000000..45aeb56b42b1
--- /dev/null
+++ b/srcpkgs/qt6-webengine/template
@@ -0,0 +1,93 @@
+# Template file for 'qt6-webengine'
+pkgname=qt6-webengine
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebengine-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true
+ -DQT_FEATURE_webengine_system_ffmpeg=ON
+ -DQT_FEATURE_webengine_system_libevent=ON
+ -DQT_FEATURE_webengine_system_gn=ON
+ -DPKG_CONFIG_HOST_EXECUTABLE=${PKG_CONFIG_FOR_BUILD}"
+hostmakedepends="qt6-base-devel perl pkg-config nodejs python
+ protobuf gperf flex nss-devel libwebp-devel"
+makedepends="qt6-base-devel qt6-declarative-devel pulseaudio-devel
+ alsa-lib-devel libvpx-devel pciutils-devel opus-devel libxslt-devel
+ libxml2-devel freetype-devel lcms2-devel libwebp-devel icu-devel
+ re2-devel zlib-devel libpng-devel minizip-devel harfbuzz-devel
+ nss-devel libXcursor-devel libXcomposite-devel libXScrnSaver-devel
+ protobuf-devel ffmpeg-devel snappy-devel libevent-devel pipewire-devel
+ qt6-quickcontrols2-devel qt6-location-devel qt6-webchannel-devel"
+short_desc="Cross-platform application and UI framework - Webengine"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-3.0-only, GPL-2.0-only, LGPL-3.0-only BSD-3-Clause"
+homepage="https://www.qt.io"
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebengine-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e509436aa22b952e6195c146cf06a839b85aaa0724feb85f0b78516dc42105a4
+
+if [ -z "$CROSS_BUILD" ];then
+	configure_args+=" -DCMAKE_TOOLCHAIN_FILE=/usr/lib/cmake/Qt6/qt.toolchain.cmake"
+fi
+
+if [ "$XBPS_LIBC" = "musl" ]; then
+	hostmakedepends+=" musl-legacy-compat"
+fi
+
+if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
+	makedepends+=" musl-legacy-compat"
+fi
+
+if [ ! "$XBPS_WORDSIZE" = "$XBPS_TARGET_WORDSIZE" ]; then
+	broken="webengine can be built only if word size matches"
+fi
+
+if [ "$XBPS_WORDSIZE" -eq 32 ]; then
+	nodebug=yes
+	LDFLAGS="-Wl,--no-keep-memory"
+fi
+
+if [ "$XBPS_TARGET_ENDIAN" != "le" ]; then
+	broken="webengine only supports little endian"
+fi
+
+_bootstrap_gn() {
+	# Bootstrap gn (generate ninja)
+	echo "Bootstrapping 'gn'"
+	cd ${wrksrc}/src/3rdparty/gn
+	CFLAGS="$CFLAGS_host" CXXFLAGS="$CXXFLAGS_host" LDFLAGS="$LDFLAGS_host" \
+	PKGCONFIG=/usr/bin/pkgconfig PKG_CONFIG_PATH="/usr/lib/pkgconfig:/usr/share/pkgconfig" \
+		python2 build/gen.py --no-last-commit-position --out-path \
+			${wrksrc}/src/3rdparty/gn/out/Release --cc "${CC_host:-$CC}" \
+			--cxx "${CXX_host:-$CXX}" --ld "${CXX_host:-$CXX}" --ar "${AR_host:-$AR}" \
+			--qt-version "${version}.qtwebengine.qt.io"
+	ninja -C out/Release gn
+	cd ${wrksrc}
+}
+
+pre_configure() {
+	cp ${FILESDIR}/resolv_compat.h ${wrksrc}/src/3rdparty/chromium/net/dns
+	_bootstrap_gn
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+pre_build() {
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+post_install() {
+	rm -r ${DESTDIR}/builddir
+	mv ${DESTDIR}/usr/resources ${DESTDIR}/usr/share/qt6
+	mv ${DESTDIR}/usr/translations ${DESTDIR}/usr/share/qt6
+}
+
+qt6-webengine-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-webchannel-devel>=${version}_1
+	 qt6-declarative-devel>=${version}_1 qt6-location-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+	}
+}

From 50842cd59d644d01fe6620e7ece6a30ff4a0794b Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 16:00:28 +0200
Subject: [PATCH 24/24] New package: qt6-location-6.2.0alpha

---
 common/shlibs                 |  1 +
 srcpkgs/qt6-location-devel    |  1 +
 srcpkgs/qt6-location/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-location-devel
 create mode 100644 srcpkgs/qt6-location/template

diff --git a/common/shlibs b/common/shlibs
index e6d1ef7157b4..e3b64dfad96b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2063,6 +2063,7 @@ libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
+libQt6Positioning.so.6 qt6-location-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-location-devel b/srcpkgs/qt6-location-devel
new file mode 120000
index 000000000000..7924c82dd3f4
--- /dev/null
+++ b/srcpkgs/qt6-location-devel
@@ -0,0 +1 @@
+qt6-location
\ No newline at end of file
diff --git a/srcpkgs/qt6-location/template b/srcpkgs/qt6-location/template
new file mode 100644
index 000000000000..3bad3ab8aade
--- /dev/null
+++ b/srcpkgs/qt6-location/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-location'
+pkgname=qt6-location
+version=6.2.0alpha
+revision=1
+wrksrc="qtlocation-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-serialport-devel qt6-declarative-devel GConf-devel"
+short_desc="Cross-platform application and UI framework - location"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlocation-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=514a84d73ccb7af5f7921b99a5742314c8875bd4cb1a982a09b28a8080c117c8
+
+qt6-location-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
  2021-06-27 19:20 ` [PR PATCH] [Updated] " Johnnynator
@ 2021-06-27 19:37 ` Johnnynator
  2021-06-27 19:38 ` Johnnynator
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-06-27 19:37 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

There is an updated pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 286377 bytes --]

From b5cde7b93c73f447a644dc06904a4e37de8deceb Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 01/24] qt6-3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..9a45c8c011ef 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt3d-everywhere-src-${version}"
+wrksrc="qt3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - 3d"
 maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=8fff7ac79b3f508df00bfc4e14e401b1dde0a5bc1d67d3cb88c05b04ac12aa1b
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 3bbfbb063956864a2f04fe692e986af042b31bd6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 02/24] qt6-base: update to 6.2.0alpha.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 +++++++++++++++++++
 srcpkgs/qt6-base/template                     | 16 ++++++------
 2 files changed, 33 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index bb043213a360..fad36fe8bc70 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtbase-everywhere-src-${version}"
+wrksrc="qtbase-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
  -DINSTALL_ARCHDATADIR=lib/qt6
@@ -27,8 +27,8 @@ short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtbase-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=eb18d8fc5b5136ab0d177d89c54ec197363904fedb2aecb0d87033ce78ddffcc
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -84,10 +84,10 @@ qt6-gui_package() {
 	short_desc+=" - Gui"
 	pkg_install() {
 		vmove "usr/lib/libQt6Gui.so.*"
-		vmove "usr/lib/libQt6XcbQpa.so.*"
-		vmove "usr/lib/libQt6EglFSDeviceIntegration.so.*"
-		vmove "usr/lib/libQt6EglFsKmsGbmSupport.so.*"
-		vmove "usr/lib/libQt6EglFsKmsSupport.so.*"
+		vmove "usr/lib/libQt6XcbQpaPrivate.so.*"
+		vmove "usr/lib/libQt6EglFSDeviceIntegrationPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsGbmSupportPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsSupportPrivate.so.*"
 		vmove "usr/lib/libQt6OpenGL.so.*"
 		vmove usr/lib/qt6/plugins/generic
 		vmove usr/lib/qt6/plugins/platforms

From 887ee80e9686b8e588deacefd50f56dd74d5d773 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 03/24] qt6-charts: update to 6.2.0alpha.

---
 srcpkgs/qt6-charts/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..1beaf0dbecfd 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtcharts-everywhere-src-${version}"
+wrksrc="qtcharts-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - charts"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtcharts-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=294205bc1e855bb44a0e17c707b981c617fc08d55d071e1d02441ff5a4e7e676
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 69958b3a121927781ae2119dbe7881510d436bb9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 04/24] qt6-declarative: update to 6.2.0alpha.

---
 srcpkgs/qt6-declarative/template | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..bef006df96f0 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,23 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtdeclarative-everywhere-src-${version}"
+wrksrc="qtdeclarative-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel qt6-declarative-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtdeclarative-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=4fd2d9448620586862e56149c43ef93b6dddcb60d6f211ab933bed984d1f1d8a
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +37,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}

From aada910c567270d02619c3dbf850c5bd7020a143 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 05/24] qt6-imageformats: update to 6.2.0alpha.

---
 srcpkgs/qt6-imageformats/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..8207913c89f9 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtimageformats-everywhere-src-${version}"
+wrksrc="qtimageformats-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - imageformats"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtimageformats-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=6e4a3690b5de83733f9a4ad492784b33748684cd99e98aa7cd3c30c97faa2bae

From 15ab172bb800f7d3f236f65bdd36a7c369389c67 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 06/24] qt6-lottie: update to 6.2.0alpha.

---
 srcpkgs/qt6-lottie/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..0a55513d0cb8 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtlottie-everywhere-src-${version}"
+wrksrc="qtlottie-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - lottie"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlottie-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=07e01a8993866abcb372cc8569d299f79cc6a91ebf66a5a85a5abe722527eadc
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From eb078c67d662ab8343f5978c753e39886d639d92 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 07/24] qt6-networkauth: update to 6.2.0alpha.

---
 srcpkgs/qt6-networkauth/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..654a2bb0fd69 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtnetworkauth-everywhere-src-${version}"
+wrksrc="qtnetworkauth-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - networkauth"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtnetworkauth-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=75784d38da1d476b209c3151dbd9afda0708fdcfbfd48d09a520754a442ccda6
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 7c2a671fa4d46b18e000208854b4109a7d2df9ba Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 08/24] qt6-qt5compat: update to 6.2.0alpha.

---
 srcpkgs/qt6-qt5compat/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index d64b37bff575..0567c1b374e5 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt5compat-everywhere-src-${version}"
+wrksrc="qt5compat-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Compo
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt5compat-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=210dbe079b51ba47841219fde59ad11a8e77a4a851a73b77121153ed03afb473
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From be6ba0726c80f36232967cce5dfcfb5b9ee65fb8 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 09/24] qt6-quick3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-quick3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..673ec342450f 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquick3d-everywhere-src-${version}"
+wrksrc="qtquick3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel qt6-shadertools-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - Quick3d"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquick3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=b60012e2d3d4b9d62cbddd84b56dcae985bc7b111b551d0eadd06551772db806
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From b27e77ae879c847b2ac68560fab513afe37b2eea Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:16 +0200
Subject: [PATCH 10/24] qt6-quickcontrols2: update to 6.2.0alpha.

---
 srcpkgs/qt6-quickcontrols2/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
index ab57102a19cf..efd4972c669c 100644
--- a/srcpkgs/qt6-quickcontrols2/template
+++ b/srcpkgs/qt6-quickcontrols2/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quickcontrols2'
 pkgname=qt6-quickcontrols2
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
+wrksrc="qtquickcontrols2-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quickcontrols2"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-2.0-or-later, LGPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquickcontrols2-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=40c8af99adb342c45809bfe06c73ac7d923433518cb7bc7997f6fc40e169c4c5
 
 qt6-quickcontrols2-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"

From 1a17155662858e9d84a7b6cd9ce3653d9361f6e6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 11/24] qt6-quicktimeline: update to 6.2.0alpha.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..bc0225e767bc 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquicktimeline-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e5b024adf9ae291004b5273465757583796c989f317e3bc62366953f02c7a89a
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 1f5209e2a8751a0772f0bcf681991984aba6afd4 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 12/24] qt6-scxml: update to 6.2.0alpha.

---
 srcpkgs/qt6-scxml/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..f8324f91a3d7 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtscxml-everywhere-src-${version}"
+wrksrc="qtscxml-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - scxml"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtscxml-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e29a333477e84d407421096fd2d90bccfb95ae4b8d0ed0d0785586e56cfa9d0c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From b606a67dc061c1f45b239157b773083b7e4bd395 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 13/24] qt6-shadertools: update to 6.2.0alpha.

---
 srcpkgs/qt6-shadertools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..42fa436708a6 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtshadertools-everywhere-src-${version}"
+wrksrc="qtshadertools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - shadertools"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtshadertools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=08144fa6d96c4382e47b3203d27f999b86d4ed1f1b828e09a48614f32b12ee59
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From 7c296b0c79ade72bae881ca17db1f85a83cf6eb2 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 14/24] qt6-svg: update to 6.2.0alpha.

---
 srcpkgs/qt6-svg/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..c37793e0613b 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtsvg-everywhere-src-${version}"
+wrksrc="qtsvg-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-svg componen
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtsvg-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=dd7c5312b8430130103d91908bd5f19fa2c6bf01c76acb757e5974603b3769c8
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 44c54233dece4657c855e854dec92e411b82041c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 15/24] qt6-tools: update to 6.2.0alpha.

---
 srcpkgs/qt6-tools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..0e7a9126bcf7 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttools-everywhere-src-${version}"
+wrksrc="qttools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-tools compon
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=32596431f71f7b4bbcd05e86c0490f97bf68b66e560337e5418a7faee5d86e84
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 7d8b1526b9c0448307dd4aa4a9d4de5377053d3c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 16/24] qt6-translations: update to 6.2.0alpha.

---
 srcpkgs/qt6-translations/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..c8be8fe68426 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttranslations-everywhere-src-${version}"
+wrksrc="qttranslations-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel qt6-tools-devel perl"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - translations"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttranslations-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=0fecd5d3e8f8823d1c77e95fbbac80c084b08df5a02f06fe71b2af6ceceb87ad

From 0c0055a85111cada71a12c5c36ba2a21b6e97b2e Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 17/24] qt6-virtualkeyboard: update to 6.2.0alpha.

---
 srcpkgs/qt6-virtualkeyboard/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..c5034fa3e95d 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
+wrksrc="qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
@@ -13,8 +13,8 @@ short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=1675dad7cd41fddb593d1fcf0a6d2a7c0f27ae9962232cba8a0a94dd38044320
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From e5dd139978eaceb3156704b74231c109e41cb7e5 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 18/24] qt6-wayland: update to 6.2.0alpha.

---
 srcpkgs/qt6-wayland/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..77c5eecd2551 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtwayland-everywhere-src-${version}"
+wrksrc="qtwayland-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel qt6-wayland-devel"
@@ -14,8 +14,8 @@ short_desc="Cross-platform application and UI framework - Wayland"
 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwayland-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=71209da169478c6ea3555f8e55edd9fe9d758ac9826c404af2a5e912a8fcfa5d
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From 43d52a9d09171ba008c6b8ea1621f3dc7d902242 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:16:54 +0200
Subject: [PATCH 19/24] New package: qt6-serialport-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-serialport-devel    |  1 +
 srcpkgs/qt6-serialport/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-serialport-devel
 create mode 100644 srcpkgs/qt6-serialport/template

diff --git a/common/shlibs b/common/shlibs
index 8a7eef8df8c3..eb023b6275aa 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2060,6 +2060,7 @@ libQt6Help.so.6 qt6-tools-6.1.0_1
 libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
+libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-serialport-devel b/srcpkgs/qt6-serialport-devel
new file mode 120000
index 000000000000..f6a498cf2653
--- /dev/null
+++ b/srcpkgs/qt6-serialport-devel
@@ -0,0 +1 @@
+qt6-serialport
\ No newline at end of file
diff --git a/srcpkgs/qt6-serialport/template b/srcpkgs/qt6-serialport/template
new file mode 100644
index 000000000000..45e5915979cc
--- /dev/null
+++ b/srcpkgs/qt6-serialport/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-serialport'
+pkgname=qt6-serialport
+version=6.2.0alpha
+revision=1
+wrksrc="qtserialport-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel pkg-config"
+makedepends="qt6-base-devel"
+short_desc="Cross-platform application and UI framework - serialport"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtserialport-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=51129c6964c42668e2ea205f1fcb0e0ea099aaeae74607112957343afb531863
+
+qt6-serialport-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 7edd1755472ba68864fb02b77aca9b61aa5ff69a Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:23:48 +0200
Subject: [PATCH 20/24] New package: qt6-websockets-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-websockets-devel    |  1 +
 srcpkgs/qt6-websockets/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-websockets-devel
 create mode 100644 srcpkgs/qt6-websockets/template

diff --git a/common/shlibs b/common/shlibs
index eb023b6275aa..69227af2267f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2061,6 +2061,7 @@ libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
+libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-websockets-devel b/srcpkgs/qt6-websockets-devel
new file mode 120000
index 000000000000..a3c674e42954
--- /dev/null
+++ b/srcpkgs/qt6-websockets-devel
@@ -0,0 +1 @@
+qt6-websockets
\ No newline at end of file
diff --git a/srcpkgs/qt6-websockets/template b/srcpkgs/qt6-websockets/template
new file mode 100644
index 000000000000..6177426904ae
--- /dev/null
+++ b/srcpkgs/qt6-websockets/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-websockets'
+pkgname=qt6-websockets
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebsockets-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel"
+short_desc="Cross-platform application and UI framework - websockets"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebsockets-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=f8277d05192ee5f823356a6c6b72ea816a0187f6a0915b783605bee9549a8761
+
+qt6-websockets-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 13ee41a031d02c96b1d1e015ff33cf3d775a351f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:25:04 +0200
Subject: [PATCH 21/24] New package: qt6-webchannel-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-webchannel-devel    |  1 +
 srcpkgs/qt6-webchannel/template | 28 ++++++++++++++++++++++++++++
 3 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-webchannel-devel
 create mode 100644 srcpkgs/qt6-webchannel/template

diff --git a/common/shlibs b/common/shlibs
index 69227af2267f..e6d1ef7157b4 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2062,6 +2062,7 @@ libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
+libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-webchannel-devel b/srcpkgs/qt6-webchannel-devel
new file mode 120000
index 000000000000..03e8b23d785d
--- /dev/null
+++ b/srcpkgs/qt6-webchannel-devel
@@ -0,0 +1 @@
+qt6-webchannel
\ No newline at end of file
diff --git a/srcpkgs/qt6-webchannel/template b/srcpkgs/qt6-webchannel/template
new file mode 100644
index 000000000000..a1d217810c90
--- /dev/null
+++ b/srcpkgs/qt6-webchannel/template
@@ -0,0 +1,28 @@
+# Template file for 'qt6-webchannel'
+pkgname=qt6-webchannel
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebchannel-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel qt6-websockets-devel"
+short_desc="Cross-platform application and UI framework - webchannel"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebchannel-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=68fd3f0508b6df69b5736d7e142509131f3728630abdcd432a06430e5ca8920c
+
+qt6-webchannel-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1
+	 qt6-websockets-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 5ec2dcc9776c43e878b647e9c87332c3e38511a9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 21:08:25 +0200
Subject: [PATCH 22/24] New package: qt6-multimedia-6.2.0alpha

---
 srcpkgs/qt6-multimedia-devel    |  1 +
 srcpkgs/qt6-multimedia/template | 29 +++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-multimedia-devel
 create mode 100644 srcpkgs/qt6-multimedia/template

diff --git a/srcpkgs/qt6-multimedia-devel b/srcpkgs/qt6-multimedia-devel
new file mode 120000
index 000000000000..9343446502d0
--- /dev/null
+++ b/srcpkgs/qt6-multimedia-devel
@@ -0,0 +1 @@
+qt6-multimedia
\ No newline at end of file
diff --git a/srcpkgs/qt6-multimedia/template b/srcpkgs/qt6-multimedia/template
new file mode 100644
index 000000000000..41a25959361e
--- /dev/null
+++ b/srcpkgs/qt6-multimedia/template
@@ -0,0 +1,29 @@
+# Template file for 'qt6-multimedia'
+pkgname=qt6-multimedia
+version=6.2.0alpha
+revision=1
+wrksrc="qtmultimedia-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_FEATURE_gstreamer=ON"
+hostmakedepends="perl qt6-declarative-devel pkg-config
+ qt6-shadertools-devel"
+makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
+ qt6-shadertools-devel libglib-devel gst-plugins-base1-devel"
+short_desc="Cross-platform application and UI framework - multimedia"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtmultimedia-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=9241fe9456c04ba1feaffd74883d37155c0218baf8aa9fc3dd54642791f378cd
+
+qt6-multimedia-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From bcad9fe863f5812be6d0e720474708a52727161b Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 00:35:33 +0200
Subject: [PATCH 23/24] New package: qt6-webengine-6.2.0alpha

---
 srcpkgs/qt6-webengine-devel                   |    1 +
 srcpkgs/qt6-webengine/files/resolv_compat.h   |   29 +
 ...-compilation-support-to-cmake-builds.patch |  474 +++
 .../patches/0001-mus-cstring.patch            |   10 +
 ...use-target-C-XX-FLAGS-for-host-cmake.patch |   26 +
 .../patches/0002-None-no-debug.patch          |   11 +
 ...reg.h-to-get-__WORDSIZE-on-musl-libc.patch |   26 +
 .../patches/0003-musl-dispatch-to-musl.patch  |  103 +
 .../patches/0004-musl-no-mallinfo.patch       |   39 +
 .../patches/0005-musl-off_t.patch             |   10 +
 .../patches/0006-musl-pread-pwrite.patch      |   18 +
 .../patches/0008-musl-resolve.patch           |   26 +
 .../patches/0009-musl-siginfo_t.patch         |   18 +
 .../patches/0010-musl-stackstart.patch        |   20 +
 .../patches/0011-musl-sandbox.patch           |   71 +
 ...0012-musl-chromium-default-stacksize.patch |   15 +
 .../0014-musl-cross-no-asm_ptrace_h.patch     |   30 +
 .../patches/0015-no-glibc-cmake-check.patch   |   14 +
 .../patches/0016-qt-musl-execinfo.patch       |  106 +
 .../0017-qt-musl-thread-stacksize.patch       |   26 +
 .../patches/0018-sandbox-membarrier.patch     |   60 +
 .../patches/0020-msgvec-push_back.patch       |   14 +
 .../patches/0021-sandbox-sched_getparam.patch |   26 +
 .../0022-canonicalize-file-name-musl.patch    |   11 +
 .../patches/0089-enable-ppc64.patch           |   49 +
 .../patches/0090-qtwebengine-ppc64.patch      | 3604 +++++++++++++++++
 .../patches/0091-chromium-ppc64le-musl.patch  |  185 +
 .../qt6-webengine/patches/0110-size_t.patch   |   16 +
 .../patches/0111-armv7l-neon.patch            |   10 +
 .../patches/0112-arm-user_vfp.patch           |   20 +
 .../patches/0113-arm-elf_auxv_t.patch         |   18 +
 .../qt6-webengine/patches/0114-time64.patch   |   89 +
 .../patches/0121-glibc-2.33.patch             |  144 +
 srcpkgs/qt6-webengine/template                |   93 +
 34 files changed, 5412 insertions(+)
 create mode 120000 srcpkgs/qt6-webengine-devel
 create mode 100644 srcpkgs/qt6-webengine/files/resolv_compat.h
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0110-size_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0114-time64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
 create mode 100644 srcpkgs/qt6-webengine/template

diff --git a/srcpkgs/qt6-webengine-devel b/srcpkgs/qt6-webengine-devel
new file mode 120000
index 000000000000..8e4d1b99c587
--- /dev/null
+++ b/srcpkgs/qt6-webengine-devel
@@ -0,0 +1 @@
+qt6-webengine
\ No newline at end of file
diff --git a/srcpkgs/qt6-webengine/files/resolv_compat.h b/srcpkgs/qt6-webengine/files/resolv_compat.h
new file mode 100644
index 000000000000..4f0e852a19d0
--- /dev/null
+++ b/srcpkgs/qt6-webengine/files/resolv_compat.h
@@ -0,0 +1,29 @@
+#if !defined(__GLIBC__)
+/***************************************************************************
+ * resolv_compat.h
+ *
+ * Mimick GLIBC's res_ninit() and res_nclose() for musl libc
+ * Note: res_init() is actually deprecated according to
+ * http://docs.oracle.com/cd/E36784_01/html/E36875/res-nclose-3resolv.html
+ **************************************************************************/
+#include <string.h>
+
+static inline int res_ninit(res_state statp)
+{
+	int rc = res_init();
+	if (statp != &_res) {
+		memcpy(statp, &_res, sizeof(*statp));
+	}
+	return rc;
+}
+
+static inline int res_nclose(res_state statp)
+{
+	if (!statp)
+		return -1;
+	if (statp != &_res) {
+		memset(statp, 0, sizeof(*statp));
+	}
+	return 0;
+}
+#endif
diff --git a/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
new file mode 100644
index 000000000000..c70f219e5f4d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
@@ -0,0 +1,474 @@
+From 7a22a424ff2997f644d930050635db214c068d10 Mon Sep 17 00:00:00 2001
+From: Michal Klocek <michal.klocek@qt.io>
+Date: Sun, 23 May 2021 17:39:28 +0200
+Subject: [PATCH 1/2] Add cross compilation support to cmake builds
+
+Add arm cross-compile basic support. CMake does not
+support host builds. However we do host build with gn and
+changing that would require an extra effort to keep all necessary
+changes with Chromium upstream. Therefore let gn to perform
+the host build for required tools and just feed gn with all the
+build data.
+
+Add new build steps:
+
+* install gn into QT_HOST_PATH/libexec.
+* run hostBuild project to get native architecture and compiler
+* call PkgConfigHost to pass pkg-config paths to gn
+* create wrapper script for host pkg-config to escape
+  yocto shell pkg config exports
+
+This change also splits gn toolchain into 3 toolchains host,target,v8
+Now hostBuild provides host and v8 toolchain in case of cross compile.
+
+The build optimizations will follow in another patch.
+
+Note this is tested only with yocto based images.
+
+Pick-to: dev
+Task-number: QTBUG-91760
+Change-Id: Ic2bea12229acc71fbd36a848e9ed4fed7e14b485
+---
+ CMakeLists.txt                           | 37 ++++++++++++++++--
+ cmake/FindGn.cmake                       |  9 +++--
+ cmake/FindNinja.cmake                    |  4 +-
+ cmake/FindPkgConfigHost.cmake            | 40 ++++++++++++++++++++
+ cmake/Functions.cmake                    | 45 ++++++++++++++++++++++
+ configure.cmake                          | 10 ++++-
+ src/core/CMakeLists.txt                  | 48 ++++++++++++++++++------
+ src/core/api/configure.cmake             | 10 ++---
+ src/core/configure/BUILD.toolchain.gn.in | 32 ++--------------
+ src/core/configure/CMakeLists.txt        | 35 +++++++++++++++++
+ 10 files changed, 215 insertions(+), 55 deletions(-)
+ create mode 100644 cmake/FindPkgConfigHost.cmake
+ create mode 100644 src/core/configure/CMakeLists.txt
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 8a3ff75c..2a93dca5 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -63,6 +63,7 @@ add_subdirectory(src/process)
+ add_subdirectory(src/webenginewidgets)
+ add_subdirectory(src/webenginequick)
+ qt_build_repo_end()
++get_install_config(installConfig)
+ 
+ ### NINJA
+ 
+@@ -94,9 +95,10 @@ if(NOT Gn_FOUND)
+                    -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
+                    -DCMAKE_PREFIX_PATH:PATH=<INSTALL_DIR>
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+-)
++    )
+ endif()
+ 
++
+ ### LIBS
+ 
+ # on windows source path can be specified without hard drive letter,
+@@ -115,12 +117,14 @@ endif()
+ list(TRANSFORM featureList PREPEND "-D")
+ list(APPEND libsCmakeArgs
+         "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}"
+-        "-DWEBENGINE_ROOT_BUILD_PATH=${CMAKE_CURRENT_BINARY_DIR}"
++        "-DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}"
+         "-DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}"
+         "-DWEBENGINE_REPO_BUILD=TRUE"
+         "${featureList}"
+ )
+-
++if(QT_HOST_PATH)
++    list(APPEND libsCmakeArgs "-DQT_HOST_PATH=${QT_HOST_PATH}")
++endif()
+ if(LINUX)
+     set(cmd "${CMAKE_COMMAND} --build ${CMAKE_CURRENT_BINARY_DIR}/src")
+     file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/src/build.sh CONTENT "ulimit -n 4096 && ${cmd}\n")
+@@ -210,3 +214,30 @@ if(NOT QT_FEATURE_framework)
+         DESTINATION ${CMAKE_INSTALL_PREFIX}
+     )
+ endif()
++
++### CROSS BUILD SETUP
++
++# install gn for cross build
++# TODO: is this really needed, should we skip it and just build gn as host build ?
++if(LINUX AND NOT Gn_FOUND OR INSTALL_GN)
++    set(INSTALL_GN 1 CACHE INTERNAL "")
++    install(
++        PROGRAMS ${installDir}/bin/gn
++        CONFIGURATIONS ${installConfig}
++        RUNTIME DESTINATION "${INSTALL_LIBEXECDIR}"
++    )
++endif()
++
++if(CMAKE_CROSSCOMPILING)
++    externalproject_add(hostBuild
++        SOURCE_DIR  ${CMAKE_CURRENT_LIST_DIR}/src/core/configure
++        BINARY_DIR  ${CMAKE_CURRENT_BINARY_DIR}/configure
++        PREFIX      cross
++        USES_TERMINAL_BUILD ON
++        CMAKE_ARGS -DCMAKE_TOOLCHAIN_FILE=${QT_HOST_PATH}/lib/cmake/Qt6/qt.toolchain.cmake
++                   -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
++                   -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
++                   -DGN_TARGET_CPU=${TEST_architecture_arch}
++    )
++    externalproject_add_stepdependencies(libs install hostBuild)
++endif()
+diff --git a/cmake/FindGn.cmake b/cmake/FindGn.cmake
+index 12a90778..abfa0fe2 100644
+--- a/cmake/FindGn.cmake
++++ b/cmake/FindGn.cmake
+@@ -1,9 +1,10 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/../..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
++endif()
++find_program(Gn_EXECUTABLE NAMES gn PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
++if(NOT QT_HOST_PATH STREQUAL "")
++   find_program(Gn_EXECUTABLE NAMES gn PATHS ${QT_HOST_PATH}/${INSTALL_LIBEXECDIR} NO_DEFAULT_PATH)
+ endif()
+-
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
+-
+ find_program(Gn_EXECUTABLE NAMES gn)
+ 
+ if(Gn_EXECUTABLE)
+diff --git a/cmake/FindNinja.cmake b/cmake/FindNinja.cmake
+index 3615d58b..720e7326 100644
+--- a/cmake/FindNinja.cmake
++++ b/cmake/FindNinja.cmake
+@@ -1,8 +1,8 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
+ endif()
+ 
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
++find_program(Ninja_EXECUTABLE NAMES ninja ninja-build PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
+ find_program(Ninja_EXECUTABLE NAMES ninja ninja-build)
+ 
+ if(Ninja_EXECUTABLE)
+diff --git a/cmake/FindPkgConfigHost.cmake b/cmake/FindPkgConfigHost.cmake
+new file mode 100644
+index 00000000..de021638
+--- /dev/null
++++ b/cmake/FindPkgConfigHost.cmake
+@@ -0,0 +1,40 @@
++# this is just simply pkg config wrapper to pass executable path to gn
++
++if(CMAKE_CROSSCOMPILING)
++   # find pkg-config, use PKG_CONFIG_HOST if set
++   if((NOT PKG_CONFIG_HOST_EXECUTABLE) AND (NOT "$ENV{PKG_CONFIG_HOST}" STREQUAL ""))
++       set(PKG_CONFIG_HOST_EXECUTABLE "$ENV{PKG_CONFIG_HOST}" CACHE FILEPATH "pkg-config host executable")
++   endif()
++
++   find_program(PKG_CONFIG_HOST_EXECUTABLE NAMES "pkg-config" DOC "pkg-config executable"
++       NO_SYSTEM_ENVIRONMENT_PATH
++       NO_CMAKE_FIND_ROOT_PATH
++   )
++
++   if(PKG_CONFIG_HOST_EXECUTABLE)
++       mark_as_advanced(PKG_CONFIG_HOST_EXECUTABLE)
++       execute_process(COMMAND ${PKG_CONFIG_HOST_EXECUTABLE} --version
++           OUTPUT_VARIABLE PKG_CONFIG_HOST_VERSION_STRING
++           OUTPUT_STRIP_TRAILING_WHITESPACE
++           ERROR_QUIET)
++   endif ()
++
++   include(FindPackageHandleStandardArgs)
++   find_package_handle_standard_args(PkgConfigHost
++       FOUND_VAR PkgConfigHost_FOUND
++       VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++       REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++   )
++else() # if not corss build simply wrap FindPkgConfig
++   find_package(PkgConfig)
++   if(PKG_CONFIG_FOUND)
++       include(FindPackageHandleStandardArgs)
++       set(PKG_CONFIG_HOST_VERSION ${PKG_CONFIG_VERSION})
++       set(PKG_CONFIG_HOST_EXECUTABLE ${PKG_CONFIG_EXECUTABLE})
++       find_package_handle_standard_args(PkgConfigHost
++           FOUND_VAR PkgConfigHost_FOUND
++           VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++           REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++       )
++  endif()
++endif()
+diff --git a/cmake/Functions.cmake b/cmake/Functions.cmake
+index d29ed7a4..3cdfdee9 100644
+--- a/cmake/Functions.cmake
++++ b/cmake/Functions.cmake
+@@ -348,3 +348,48 @@ function(qt_internal_add_external_project_dependency_to_root_project name)
+ 
+     cmake_policy(POP)
+ endfunction()
++
++function(get_gn_arch result arch)
++   if("${arch}" STREQUAL "i386")
++      set(${result} "x86" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "x86_64")
++      set(${result} "x64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm")
++      set(${result} "arm" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm64")
++      set(${result} "arm64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel")
++      set(${result} "mipsel" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel64")
++      set(${result} "mips64el" PARENT_SCOPE)
++   else()
++      message(DEBUG "Unsupported achitecture: ${arch}")
++   endif()
++endfunction()
++
++function(get_v8_arch result targetArch)
++   set(list32 i386 arm mipsel)
++   if("${targetArch}" IN_LIST list32)
++       set(${result} "i386" PARENT_SCOPE)
++   else()
++       set(${result} "x86_64" PARENT_SCOPE)
++   endif()
++endfunction()
++
++function(configure_gn_toolchain name cpuType v8CpuType toolchainIn toolchainOut)
++    set(GN_TOOLCHAIN ${name})
++    get_gn_arch(GN_CPU ${cpuType})
++    get_gn_arch(GN_V8_CPU ${v8CpuType})
++    configure_file(${toolchainIn} ${toolchainOut}/BUILD.gn @ONLY)
++endfunction()
++
++function(create_pkg_config_host_wrapper wrapperName wrapperCmd)
++    file(WRITE ${wrapperName}
++        "#!/bin/sh\n"
++        "unset PKG_CONFIG_LIBDIR\n"
++        "unset PKG_CONFIG_PATH\n"
++        "unset PKG_CONFIG_SYSROOT_DIR\n"
++        "exec ${wrapperCmd} \"$@\""
++    )
++    file(CHMOD ${wrapperName} PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE)
++endfunction()
+diff --git a/configure.cmake b/configure.cmake
+index 53392313..2a8552d7 100644
+--- a/configure.cmake
++++ b/configure.cmake
+@@ -333,9 +333,17 @@ endif()
+ assertTargets(webEngineError webEngineSupport Gui Widgets OpenGL OpenGLWidgets Quick Qml)
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION (LINUX AND NOT CMAKE_CROSSCOMPILING) OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
++   CONDITION LINUX OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
+    MESSAGE "Build can be done only on Linux, Windows or macOS."
+ )
++if(LINUX AND CMAKE_CROSSCOMPILING)
++   get_gn_arch(testArch ${TEST_architecture_arch})
++   add_check_for_support(webEngineError webEngineSupport
++       MODULE QtWebEngine
++       CONDITION testArch
++       MESSAGE "Cross compiling is not supported for ${TEST_architecture_arch}."
++   )
++endif()
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+    CONDITION NOT QT_FEATURE_static
+diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
+index fd935fe1..40d7fd8e 100644
+--- a/src/core/CMakeLists.txt
++++ b/src/core/CMakeLists.txt
+@@ -24,6 +24,11 @@ find_package(Nodejs 12.0)
+ find_package(PkgConfig)
+ if(PkgConfig_FOUND)
+     pkg_check_modules(XSCRNSAVER xscrnsaver)
++    find_package(PkgConfigHost)
++    if(CMAKE_CROSSCOMPILING)
++        create_pkg_config_host_wrapper("${buildDir}/pkg-config-host_wrapper.sh" "${PKG_CONFIG_HOST_EXECUTABLE}")
++        set(PKG_CONFIG_HOST_EXECUTABLE "${buildDir}/pkg-config-host_wrapper.sh")
++    endif()
+ endif()
+ 
+ get_target_property(qtWebEngineProcessName WebEngineCore QTWEBENGINEPROCESS_NAME)
+@@ -36,6 +41,24 @@ else()
+     set(configs ${CMAKE_BUILD_TYPE})
+ endif()
+ 
++##
++#   TOOLCHAIN SETUP
++##
++
++if(LINUX)
++    if(NOT CMAKE_CROSSCOMPILING) # delivered by hostBuild project
++        configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/host_toolchain)
++        configure_gn_toolchain(v8 ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/v8_toolchain)
++    endif()
++    configure_gn_toolchain(target ${TEST_architecture_arch} ${TEST_architecture_arch}
++        ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++        ${buildDir}/target_toolchain)
++endif()
++
+ foreach(config ${configs})
+ 
+ ##
+@@ -250,12 +273,6 @@ foreach(config ${configs})
+     configure_gn_target(${buildGn} ${config}
+         ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.root.gn.in ${buildDir}/${config}/BUILD.gn)
+ 
+-##
+-#   TOOLCHAIN SETUP
+-##
+-
+-    configure_file(${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
+-        ${buildDir}/${config}/toolchain/BUILD.gn @ONLY)
+ 
+ ##
+ #   GN CALL PARAMETERS SETUP
+@@ -419,6 +436,15 @@ foreach(config ${configs})
+         )
+     endif()
+     if(LINUX)
++        get_gn_arch(cpu ${TEST_architecture_arch})
++        if(CMAKE_CROSSCOMPILING)
++            list(APPEND gnArgArg target_cpu="${cpu}")
++        else()
++            list(APPEND gnArgArg host_cpu="${cpu}")
++        endif()
++        if(CMAKE_SYSROOT)
++            list(APPEND gnArgArg target_sysroot="${CMAKE_SYSROOT}")
++        endif()
+         list(APPEND gnArgArg
+             use_cups=false
+             use_gio=false
+@@ -435,11 +461,11 @@ foreach(config ${configs})
+             ozone_platform_external=true
+             ozone_platform="qt"
+             ozone_extra_path="${CMAKE_CURRENT_LIST_DIR}/ozone/ozone_extra.gni"
+-            custom_toolchain="${buildDir}/${config}/toolchain:target"
+-            host_toolchain="${buildDir}/${config}/toolchain:host"
+-            host_cpu="x64"
+-            pkg_config="pkg-config"
+-            host_pkg_config="/usr/bin/pkg-config"
++            custom_toolchain="${buildDir}/target_toolchain:target"
++            host_toolchain="${buildDir}/host_toolchain:host"
++            v8_snapshot_toolchain="${buildDir}/v8_toolchain:v8"
++            pkg_config="${PKG_CONFIG_EXECUTABLE}"
++            host_pkg_config="${PKG_CONFIG_HOST_EXECUTABLE}"
+             use_glib=false
+         )
+         set(systemLibs libjpeg libpng freetype harfbuzz libevent libwebp libxml
+diff --git a/src/core/api/configure.cmake b/src/core/api/configure.cmake
+index 35d28e87..0cf46bf0 100644
+--- a/src/core/api/configure.cmake
++++ b/src/core/api/configure.cmake
+@@ -143,11 +143,11 @@ qt_configure_add_summary_entry(
+     CONDITION UNIX
+ )
+ qt_configure_end_summary_section() # end of "Qt WebEngineCore" section
+-qt_configure_add_report_entry(
+-    TYPE WARNING
+-    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
+-    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
+-)
++#qt_configure_add_report_entry(
++#    TYPE WARNING
++#    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
++#    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
++#)
+ qt_configure_add_report_entry(
+     TYPE WARNING
+     MESSAGE "V8 snapshot cannot be built. Most likely, the 32-bit host compiler does not work. Please make sure you have 32-bit devel environment installed."
+diff --git a/src/core/configure/BUILD.toolchain.gn.in b/src/core/configure/BUILD.toolchain.gn.in
+index e44fa42d..c1bf3845 100644
+--- a/src/core/configure/BUILD.toolchain.gn.in
++++ b/src/core/configure/BUILD.toolchain.gn.in
+@@ -1,6 +1,6 @@
+ import("//build/config/sysroot.gni")
+ import("//build/toolchain/gcc_toolchain.gni")
+-gcc_toolchain("host") {
++gcc_toolchain("@GN_TOOLCHAIN@") {
+   cc = "@CMAKE_C_COMPILER@"
+   cxx = "@CMAKE_CXX_COMPILER@"
+   ld = "@CMAKE_CXX_COMPILER@"
+@@ -9,34 +9,8 @@ gcc_toolchain("host") {
+   extra_cppflags = ""
+   toolchain_args = {
+     current_os = "linux"
+-    current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+-}
+-gcc_toolchain("v8_snapshot") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
+-    v8_current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+- }
+-gcc_toolchain("target") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
++    current_cpu = "@GN_CPU@"
++    v8_current_cpu = "@GN_V8_CPU@"
+     is_clang = false
+     use_gold = false
+   }
+diff --git a/src/core/configure/CMakeLists.txt b/src/core/configure/CMakeLists.txt
+new file mode 100644
+index 00000000..0ae4b4b4
+--- /dev/null
++++ b/src/core/configure/CMakeLists.txt
+@@ -0,0 +1,35 @@
++cmake_minimum_required(VERSION 3.19)
++
++if(NOT DEFINED WEBENGINE_ROOT_SOURCE_DIR)
++    get_filename_component(WEBENGINE_ROOT_SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/../../.." REALPATH)
++endif()
++if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
++    get_filename_component(WEBENGINE_ROOT_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}/../../.." REALPATH)
++endif()
++
++include(${WEBENGINE_ROOT_SOURCE_DIR}/.cmake.conf)
++include(${WEBENGINE_ROOT_SOURCE_DIR}/cmake/Functions.cmake)
++
++set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${WEBENGINE_ROOT_SOURCE_DIR}/cmake")
++
++project(QtWebEngineConfigure
++    VERSION "${QT_REPO_MODULE_VERSION}"
++    LANGUAGES CXX C)
++
++find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals Core)
++
++set(buildDir ${CMAKE_CURRENT_BINARY_DIR})
++configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/host_toolchain
++)
++install(FILES ${buildDir}/host_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/host_toolchain
++    )
++get_v8_arch(GN_V8_HOST_CPU ${GN_TARGET_CPU})
++configure_gn_toolchain(v8 ${GN_V8_HOST_CPU} ${GN_TARGET_CPU}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/v8_toolchain)
++install(FILES ${buildDir}/v8_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/v8_toolchain
++)
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
new file mode 100644
index 000000000000..d4b22c77ce96
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/mojo/public/cpp/platform/named_platform_channel_posix.cc	2021-03-08 10:30:42.504006604 +0100
++++ -	2021-03-08 10:31:27.415366585 +0100
+@@ -8,6 +8,7 @@
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <unistd.h>
++#include <cstring>
+ 
+ #include "base/files/file_util.h"
+ #include "base/files/scoped_file.h"
diff --git a/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
new file mode 100644
index 000000000000..de6d5abb4461
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
@@ -0,0 +1,26 @@
+From 8eece1b0c72bef7319069703031543ddd0ca87ee Mon Sep 17 00:00:00 2001
+From: John Zimmermann <me@johnnynator.dev>
+Date: Sun, 27 Jun 2021 20:35:15 +0200
+Subject: [PATCH 2/2] Do not use target C{XX}FLAGS for host cmake
+
+Change-Id: Ia66d153fa9f1aff63491f6a1ec7380b8bda1e3c7
+---
+ CMakeLists.txt | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 2a93dca5..2a8e6cfb 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -238,6 +238,8 @@ if(CMAKE_CROSSCOMPILING)
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+                    -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
+                    -DGN_TARGET_CPU=${TEST_architecture_arch}
++                   -DCMAKE_CXX_FLAGS=$ENV{CXXFLAGS_FOR_BUILD}
++                   -DCMAKE_C_FLAGS=$ENV{CFLAGS_FOR_BUILD}
+     )
+     externalproject_add_stepdependencies(libs install hostBuild)
+ endif()
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
new file mode 100644
index 000000000000..4a428fe03b37
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
@@ -0,0 +1,11 @@
+--- a/src/core/CMakeLists.txt	2021-06-27 14:24:18.812840134 +0200
++++ b/src/core/CMakeLists.txt	2021-06-27 14:51:46.825108637 +0200
+@@ -299,6 +299,8 @@
+         endif()
+     elseif(${config} STREQUAL "MinSizeRel")
+         list(APPEND gnArgArg is_debug=false symbol_level=0 optimize_for_size=true)
++    elseif(${config} STREQUAL "None")
++        list(APPEND gnArgArg is_debug=false symbol_level=0)
+     endif()
+ 
+     list(APPEND gnArgArg
diff --git a/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
new file mode 100644
index 000000000000..da4160b21bd3
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
@@ -0,0 +1,26 @@
+From 9001c54d6b974449174a8cee8f3f5d78a9bd6c9e Mon Sep 17 00:00:00 2001
+From: Felix Janda <felix.janda@posteo.de>
+Date: Sun, 1 Feb 2015 14:26:52 +0100
+Subject: [PATCH 3/6] include <sys/reg.h> to get __WORDSIZE on musl libc
+
+---
+ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/common/linux/elf_core_dump.h b/src/common/linux/elf_core_dump.h
+index d03c7a8..02eb391 100644
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
+@@ -36,6 +36,9 @@
+ #include <elf.h>
+ #include <link.h>
+ #include <stddef.h>
++#ifndef __GLIBC__
++#include <sys/reg.h>
++#endif
+ 
+ #include "common/memory_range.h"
+ 
+-- 
+2.0.5
+
diff --git a/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
new file mode 100644
index 000000000000..de32a3dab95c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
@@ -0,0 +1,103 @@
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+@@ -6,6 +6,7 @@
+ 
+ #include <malloc.h>
+ 
++#if defined(__GLIBC__)
+ // This translation unit defines a default dispatch for the allocator shim which
+ // routes allocations to libc functions.
+ // The code here is strongly inspired from tcmalloc's libc_override_glibc.h.
+@@ -73,3 +74,92 @@ const AllocatorDispatch AllocatorDispatch::default_dispatch = {
+     nullptr,               /* free_definite_size_function */
+     nullptr,               /* next */
+ };
++
++#else // defined(__GLIBC__)
++
++#include <dlfcn.h>
++
++extern "C" {
++// Declare function pointers to the memory functions
++typedef void* (*t_libc_malloc)(size_t size);
++typedef void* (*t_libc_calloc)(size_t n, size_t size);
++typedef void* (*t_libc_realloc)(void* address, size_t size);
++typedef void* (*t_libc_memalign)(size_t alignment, size_t size);
++typedef void (*t_libc_free)(void* ptr);
++typedef size_t (*t_libc_malloc_usable_size)(void* ptr);
++
++// Static instances of pointers to libc.so dl symbols
++static t_libc_malloc libc_malloc = NULL;
++static t_libc_calloc libc_calloc = NULL;
++static t_libc_realloc libc_realloc = NULL;
++static t_libc_memalign libc_memalign = NULL;
++static t_libc_free libc_free = NULL;
++static t_libc_malloc_usable_size libc_malloc_usable_size = NULL;
++
++// resolve the symbols in libc.so
++void musl_libc_memory_init(void)
++{
++  libc_malloc = (t_libc_malloc) dlsym(RTLD_NEXT, "malloc");
++  libc_calloc = (t_libc_calloc) dlsym(RTLD_NEXT, "calloc");
++  libc_realloc = (t_libc_realloc) dlsym(RTLD_NEXT, "realloc");
++  libc_memalign = (t_libc_memalign) dlsym(RTLD_NEXT, "memalign");
++  libc_free = (t_libc_free) dlsym(RTLD_NEXT, "free");
++  libc_malloc_usable_size = (t_libc_malloc_usable_size) dlsym(RTLD_NEXT, "malloc_usable_size");
++}
++}  // extern "C"
++
++namespace {
++
++using base::allocator::AllocatorDispatch;
++
++void* MuslMalloc(const AllocatorDispatch*, size_t size, void* context) {
++  if (!libc_malloc)
++    musl_libc_memory_init();
++  return (*libc_malloc)(size);
++}
++
++void* MuslCalloc(const AllocatorDispatch*, size_t n, size_t size, void* context) {
++  if (!libc_calloc)
++    musl_libc_memory_init();
++  return (*libc_calloc)(n, size);
++}
++
++void* MuslRealloc(const AllocatorDispatch*, void* address, size_t size, void* context) {
++  if (!libc_realloc)
++    musl_libc_memory_init();
++  return (*libc_realloc)(address, size);
++}
++
++void* MuslMemalign(const AllocatorDispatch*, size_t alignment, size_t size, void* context) {
++  if (!libc_memalign)
++    musl_libc_memory_init();
++  return (*libc_memalign)(alignment, size);
++}
++
++void MuslFree(const AllocatorDispatch*, void* address, void* context) {
++  if (!libc_free)
++    musl_libc_memory_init();
++  (*libc_free)(address);
++}
++
++size_t MuslGetSizeEstimate(const AllocatorDispatch*, void* address, void* context) {
++  // TODO(siggi, primiano): malloc_usable_size may need redirection in the
++  //     presence of interposing shims that divert allocations.
++  if (!libc_malloc_usable_size)
++    musl_libc_memory_init();
++  return (*libc_malloc_usable_size)(address);
++}
++
++}  // namespace
++
++const AllocatorDispatch AllocatorDispatch::default_dispatch = {
++    &MuslMalloc,           /* alloc_function */
++    &MuslCalloc,           /* alloc_zero_initialized_function */
++    &MuslMemalign,         /* alloc_aligned_function */
++    &MuslRealloc,          /* realloc_function */
++    &MuslFree,             /* free_function */
++    &MuslGetSizeEstimate,  /* get_size_estimate_function */
++    nullptr,               /* next */
++};
++
++#endif
diff --git a/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
new file mode 100644
index 000000000000..36900f907833
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
@@ -0,0 +1,39 @@
+--- qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2017-11-28 14:06:53.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2018-01-27 20:13:26.960932805 +0100
+@@ -243,7 +243,7 @@
+   allocated_objects_count = main_heap_info.block_count;
+ #elif defined(OS_FUCHSIA)
+ // TODO(fuchsia): Port, see https://crbug.com/706592.
+-#else
++#elif defined(__GLIBC__)
+   struct mallinfo info = mallinfo();
+   DCHECK_GE(info.arena + info.hblkhd, info.uordblks);
+ 
+@@ -255,6 +255,8 @@
+ 
+   // Total allocated space is given by |uordblks|.
+   allocated_objects_size = info.uordblks;
++#else
++// musl libc does not support mallinfo()
+ #endif
+ 
+   MemoryAllocatorDump* outer_dump = pmd->CreateAllocatorDump("malloc");
+--- qtwebengine/src/3rdparty/chromium/base/process/process_metrics_posix.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:03:38.579424720 +0100
+@@ -119,14 +119,14 @@
+   malloc_statistics_t stats = {0};
+   malloc_zone_statistics(nullptr, &stats);
+   return stats.size_in_use;
+-#elif defined(OS_LINUX) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
++#elif (defined(OS_LINUX) && defined(__GLIBC__)) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
+   struct mallinfo minfo = mallinfo();
+ #if BUILDFLAG(USE_TCMALLOC)
+   return minfo.uordblks;
+ #else
+   return minfo.hblkhd + minfo.arena;
+ #endif
+-#elif defined(OS_FUCHSIA)
++#else //if defined(OS_FUCHSIA) // also musl doesn't do this.
+   // TODO(fuchsia): Not currently exposed. https://crbug.com/735087.
+   return 0;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
new file mode 100644
index 000000000000..52db3b9ebf46
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
@@ -0,0 +1,10 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-05-26 14:58:54.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-10-01 14:31:30.885000000 +0200
+@@ -21,6 +21,7 @@
+ #define htons(x) _byteswap_ushort (x)
+ #else
+ #include <arpa/inet.h>
++#include <sys/types.h>
+ #include <stdint.h>
+ #endif
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
new file mode 100644
index 000000000000..00017bba0172
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
@@ -0,0 +1,18 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:26.639964100 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:11.611964995 +0200
+@@ -1794,6 +1794,15 @@
+ /* End of s390/s390x definitions                                             */
+ #endif
+ 
++#ifndef __GLIBC__
++  /* For Musl libc pread/pread is the same as pread64/pwrite64 */
++#ifndef __NR_pread
++#define __NR_pread              __NR_pread64
++#endif
++#ifndef __NR_pwrite
++#define __NR_pwrite             __NR_pwrite64
++#endif
++#endif /* ifndef __GLIBC__ */
+ 
+ /* After forking, we must make sure to only call system calls.               */
+ #if defined(__BOUNDED_POINTERS__)
diff --git a/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
new file mode 100644
index 000000000000..edfceb79f30a
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
@@ -0,0 +1,26 @@
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-12-20 03:33:11.749059656 +0100
+@@ -9,6 +9,10 @@
+ 
+ #include <resolv.h>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/lazy_instance.h"
+ #include "base/logging.h"
+ #include "base/macros.h"
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-12-20 03:40:07.671953098 +0100
+@@ -6,6 +6,10 @@
+ 
+ #include <string>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/bind.h"
+ #include "base/files/file.h"
+ #include "base/files/file_path.h"
diff --git a/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
new file mode 100644
index 000000000000..fe760be16664
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
@@ -0,0 +1,18 @@
+There's a subtle difference in the internal name of siginfo_t fields
+between glibc and musl. The structure itself is equivalent, so it
+should suffice to add a macro to rename the field.
+
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-02-17 05:57:43.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-06-03 08:20:25.032716427 +0200
+@@ -22,6 +22,11 @@
+ #include "sandbox/linux/services/android_ucontext.h"
+ #endif
+
++// musl libc defines siginfo_t __si_fields instead of _sifields
++#if !defined(__GLIBC__)
++#define _sifields __si_fields
++#endif
++
+ namespace {
+
+ const int kCapacityIncrement = 20;
diff --git a/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
new file mode 100644
index 000000000000..a9f8ab6c252c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
@@ -0,0 +1,20 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:08:43.586475349 +0100
++++ qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:18:22.274505203 +0100
+@@ -28,7 +28,7 @@
+ // FIXME: On Mac OSX and Linux, this method cannot estimate stack size
+ // correctly for the main thread.
+ 
+-#elif defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#elif defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   // pthread_getattr_np() can fail if the thread is not invoked by
+   // pthread_create() (e.g., the main thread of blink_unittests).
+@@ -96,7 +96,7 @@
+ }
+ 
+ void* GetStackStart() {
+-#if defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#if defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   pthread_attr_t attr;
+   int error;
diff --git a/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
new file mode 100644
index 000000000000..d3de1e41183d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
@@ -0,0 +1,71 @@
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-09-13 19:53:53.453780253 +0200
+@@ -129,7 +129,7 @@
+ // CLONE_VM, nor CLONE_THREAD, which includes all fork() implementations.
+ ResultExpr RestrictCloneToThreadsAndEPERMFork() {
+   const Arg<unsigned long> flags(0);
+-
++#if defined(__GLIBC__)
+   // TODO(mdempsky): Extend DSL to support (flags & ~mask1) == mask2.
+   const uint64_t kAndroidCloneMask = CLONE_VM | CLONE_FS | CLONE_FILES |
+                                      CLONE_SIGHAND | CLONE_THREAD |
+@@ -148,6 +148,17 @@
+   return If(IsAndroid() ? android_test : glibc_test, Allow())
+       .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
+       .Else(CrashSIGSYSClone());
++#else
++  const int required = CLONE_VM | CLONE_FS | CLONE_FILES | CLONE_SIGHAND |
++                       CLONE_THREAD | CLONE_SYSVSEM;
++  const int safe = CLONE_SETTLS | CLONE_PARENT_SETTID | CLONE_CHILD_CLEARTID |
++                   CLONE_DETACHED;
++  const BoolExpr thread_clone_ok = (flags&~safe)==required;
++
++  return If(thread_clone_ok, Allow())
++      .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
++      .Else(CrashSIGSYSClone());
++#endif
+ }
+ 
+ ResultExpr RestrictPrctl() {
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-09-13 19:56:31.779773940 +0200
+@@ -375,6 +375,9 @@
+ #if defined(__i386__)
+     case __NR_waitpid:
+ #endif
++#if !defined(__GLIBC__)
++    case __NR_set_tid_address:
++#endif
+       return true;
+     case __NR_clone:  // Should be parameter-restricted.
+     case __NR_setns:  // Privileged.
+@@ -387,7 +390,9 @@
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
+     case __NR_set_thread_area:
+ #endif
++#if defined(__GLIBC__)
+     case __NR_set_tid_address:
++#endif
+     case __NR_unshare:
+ #if !defined(__mips__) && !defined(__aarch64__)
+     case __NR_vfork:
+@@ -496,6 +501,9 @@
+     case __NR_mlock:
+     case __NR_munlock:
+     case __NR_munmap:
++#if !defined(__GLIBC__)
++    case __NR_mremap:
++#endif
+       return true;
+     case __NR_madvise:
+     case __NR_mincore:
+@@ -511,7 +519,9 @@
+     case __NR_modify_ldt:
+ #endif
+     case __NR_mprotect:
++#if defined(__GLIBC__)
+     case __NR_mremap:
++#endif
+     case __NR_msync:
+     case __NR_munlockall:
+     case __NR_readahead:
diff --git a/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
new file mode 100644
index 000000000000..7bf5a22fba71
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
@@ -0,0 +1,15 @@
+--- qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc.orig	2018-09-19 18:05:15.523923703 +0200
++++ qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc	2018-09-19 18:08:05.150932454 +0200
+@@ -173,7 +173,12 @@
+ 
+ size_t GetDefaultThreadStackSize(const pthread_attr_t& attributes) {
+ #if !defined(THREAD_SANITIZER)
++#if defined(__GLIBC__)
+   return 0;
++#else // defined(__GLIBC__)
++  // For Musl libc try with a default stack size of 2 MiB
++  return 2 * 1024 * 1024;
++#endif // !defined(__GLIBC__)
+ #else
+   // ThreadSanitizer bloats the stack heavily. Evidence has been that the
+   // default stack size isn't enough for some browser tests.
diff --git a/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
new file mode 100644
index 000000000000..140742f72c25
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
@@ -0,0 +1,30 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-11-22 00:41:58.522477559 +0100
+@@ -38,7 +38,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_ptrace_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <errno.h>
+ #include <fcntl.h>
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-11-22 00:49:39.533492245 +0100
+@@ -32,7 +32,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_core_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <elf.h>
+ #include <stdio.h>
diff --git a/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
new file mode 100644
index 000000000000..f6c3aadb8421
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
@@ -0,0 +1,14 @@
+--- a/configure.cmake	2021-06-21 23:31:04.000000000 +0200
++++ -	2021-06-27 16:16:32.873528917 +0200
+@@ -373,11 +373,6 @@
+ )
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION NOT LINUX OR TEST_glibc
+-   MESSAGE "A suitable version >= 2.17 of glibc is required."
+-)
+-add_check_for_support(webEngineError webEngineSupport
+-   MODULE QtWebEngine
+    CONDITION NOT LINUX OR TEST_khr
+    MESSAGE "Build requires Khronos development headers for build - see mesa/libegl1-mesa-dev"
+ )
diff --git a/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
new file mode 100644
index 000000000000..608dd0b4e078
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
@@ -0,0 +1,106 @@
+--- qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc.orig	2019-04-09 09:31:16.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc	2019-05-06 23:16:13.245502467 +0200
+@@ -27,7 +27,7 @@
+ #if !defined(USE_SYMBOLIZE)
+ #include <cxxabi.h>
+ #endif
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ #include <execinfo.h>
+ #endif
+ 
+@@ -86,7 +86,7 @@
+   // Note: code in this function is NOT async-signal safe (std::string uses
+   // malloc internally).
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   std::string::size_type search_from = 0;
+   while (search_from < text->size()) {
+     // Look for the start of a mangled symbol, from search_from.
+@@ -121,7 +121,7 @@
+       search_from = mangled_start + 2;
+     }
+   }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ }
+ #endif  // !defined(USE_SYMBOLIZE)
+ 
+@@ -133,7 +133,7 @@
+   virtual ~BacktraceOutputHandler() = default;
+ };
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void OutputPointer(void* pointer, BacktraceOutputHandler* handler) {
+   // This should be more than enough to store a 64-bit number in hex:
+   // 16 hex digits + 1 for null-terminator.
+@@ -216,7 +216,7 @@
+   }
+ #endif  // defined(USE_SYMBOLIZE)
+ }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ 
+ void PrintToStderr(const char* output) {
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+@@ -812,7 +812,7 @@
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+   // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   // Though the backtrace API man page does not list any possible negative
+   // return values, we take no chance.
+   return base::saturated_cast<size_t>(backtrace(trace, count));
+@@ -825,13 +825,13 @@
+ // NOTE: This code MUST be async-signal safe (it's used by in-process
+ // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   PrintBacktraceOutputHandler handler;
+   ProcessBacktrace(trace_, count_, prefix_string, &handler);
+ #endif
+ }
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void StackTrace::OutputToStreamWithPrefix(std::ostream* os,
+                                           const char* prefix_string) const {
+   StreamBacktraceOutputHandler handler(os);
+--- qtwebengine/src/3rdparty/chromium/base/debug/stack_trace.cc	2019-04-09 09:31:16.000000000 +0200
++++ -	2019-05-06 23:18:14.923566992 +0200
+@@ -233,7 +233,7 @@
+ }
+ std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
+   std::stringstream stream;
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(&stream, prefix_string);
+ #endif
+   return stream.str();
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2017-11-28 14:06:53.000000000 +0100
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2018-01-27 22:46:34.970406807 +0100
+@@ -546,7 +546,7 @@
+ 
+ LogMessage::~LogMessage() {
+   size_t stack_start = stream_.tellp();
+-#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && !defined(__UCLIBC__) && \
++#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && defined(__GLIBC__) && \
+     !defined(OS_AIX)
+   if (severity_ == LOG_FATAL && !base::debug::BeingDebugged()) {
+     // Include a stack trace on a fatal, unless a debugger is attached.
+--- a/src/3rdparty/chromium/base/debug/stack_trace.cc	2021-06-27 18:17:06.834705848 +0200
++++ -	2021-06-27 18:27:53.014102803 +0200
+@@ -217,7 +217,9 @@
+ }
+ 
+ void StackTrace::OutputToStream(std::ostream* os) const {
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(os, nullptr);
++#endif
+ }
+ 
+ std::string StackTrace::ToString() const {
diff --git a/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
new file mode 100644
index 000000000000..496753bef30f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
@@ -0,0 +1,26 @@
+diff --git a/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc b/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+index 02bf49b..05ee182 100644
+--- qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
++++ qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+@@ -13,7 +13,7 @@ namespace pp {
+ namespace {
+ 
+ // Use 2MB default stack size for Native Client, otherwise use system default.
+-#if defined(__native_client__)
++#if defined(__native_client__) || !defined(__GLIBC__)
+ const size_t kDefaultStackSize = 2 * 1024 * 1024;
+ #else
+ const size_t kDefaultStackSize = 0;
+diff --git a/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc b/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+index cf7f3ec..e06a5ce 100644
+--- qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
++++ qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+@@ -761,7 +761,7 @@ void Thread::Start() {
+ #if V8_OS_MACOSX
+     // Default on Mac OS X is 512kB -- bump up to 1MB
+     stack_size = 1 * 1024 * 1024;
+-#elif V8_OS_AIX
++#elif V8_OS_AIX || !defined(__GLIBC__)
+     // Default on AIX is 96kB -- bump up to 2MB
+     stack_size = 2 * 1024 * 1024;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
new file mode 100644
index 000000000000..b73971f24324
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
@@ -0,0 +1,60 @@
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
+@@ -1063,4 +1063,8 @@
+ #define __NR_memfd_create 279
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 283
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_ARM64_LINUX_SYSCALLS_H_
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,10 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier (__NR_SYSCALL_BASE+389)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
+@@ -1422,5 +1422,9 @@
+ #define __NR_memfd_create 356
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 375
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_32_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
+@@ -1290,5 +1290,9 @@
+ #define __NR_memfd_create 319
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 324
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -370,6 +370,7 @@
+   switch (sysno) {
+     case __NR_exit:
+     case __NR_exit_group:
++    case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+ #if defined(__i386__)
diff --git a/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
new file mode 100644
index 000000000000..75481a2889f4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
@@ -0,0 +1,14 @@
+--- qtwebengine-everywhere-src-5.14.0-beta2/src/3rdparty/chromium/net/socket/udp_socket_posix.cc	2019-10-08 08:27:43.000000000 +0200
++++ -	2019-11-11 22:41:46.699068889 +0100
+@@ -1191,7 +1191,11 @@
+     msg_iov->push_back({const_cast<char*>(buffer->data()), buffer->length()});
+   msgvec->reserve(buffers.size());
+   for (size_t j = 0; j < buffers.size(); j++)
++#if defined(__GLIBC__)
+     msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, nullptr, 0, 0}, 0});
++#else
++    msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, 0, 0, 0}, 0});
++#endif
+   int result = HANDLE_EINTR(Sendmmsg(fd, &msgvec[0], buffers.size(), 0));
+   SendResult send_result(0, 0, std::move(buffers));
+   if (result < 0) {
diff --git a/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
new file mode 100644
index 000000000000..d8c6aa15cf66
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
@@ -0,0 +1,26 @@
+Allow SYS_sched_getparam and SYS_sched_getscheduler
+musl uses them for pthread_getschedparam()
+
+source: https://git.alpinelinux.org/aports/commit/community/chromium?id=54af9f8ac24f52d382c5758e2445bf0206eff40e
+
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:13:44.992079145 +0100
+@@ -93,11 +93,18 @@
+     case __NR_sysinfo:
+     case __NR_times:
+     case __NR_uname:
++#if !defined(__GLIBC__)
++    case __NR_sched_getparam:
++    case __NR_sched_getscheduler:
++    case __NR_sched_setscheduler:
++#endif
+       return Allow();
+     case __NR_sched_getaffinity:
++#if defined(__GLIBC__)
+     case __NR_sched_getparam:
+     case __NR_sched_getscheduler:
+     case __NR_sched_setscheduler:
++#endif
+       return RestrictSchedTarget(GetPolicyPid(), sysno);
+     case __NR_prlimit64:
+       // See crbug.com/662450 and setrlimit comment above.
diff --git a/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
new file mode 100644
index 000000000000..893ed2d41bb4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
@@ -0,0 +1,11 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/nasm/nasmlib/realpath.c	2019-09-23 14:24:20.000000000 +0200
++++ -	2019-10-11 06:27:28.450329986 +0200
+@@ -57,7 +57,7 @@
+  */
+ char *nasm_realpath(const char *rel_path)
+ {
+-    char *rp = canonicalize_file_name(rel_path);
++    char *rp = realpath(rel_path, NULL);
+     return rp ? rp : nasm_strdup(rel_path);
+ }
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
new file mode 100644
index 000000000000..b87766825063
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
@@ -0,0 +1,49 @@
+From 463f1234c57a36e78ff666bd55094a9d4e68f296 Mon Sep 17 00:00:00 2001
+From: q66 <daniel@octaforge.org>
+Date: Sat, 18 Jan 2020 23:52:55 +0100
+Subject: [PATCH 1/3] Enable ppc64 builds
+
+---
+ configure.pri                  | 1 +
+ mkspecs/features/functions.prf | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/configure.pri b/configure.pri
+index 3a144e3f8..cabe8b24a 100644
+--- a/configure.pri	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:18:43.124754796 +0100
+@@ -144,6 +144,7 @@
+     contains(QT_ARCH, "arm")|contains(QT_ARCH, "arm64"): return(true)
+     contains(QT_ARCH, "mips"): return(true)
+     contains(QT_ARCH, "mips64"): return(true)
++    contains(QT_ARCH, "power64"): return(true)
+     qtLog("Architecture not supported.")
+     return(false)
+ }
+diff --git a/mkspecs/features/functions.prf b/mkspecs/features/functions.prf
+index 512e2523b..e31123654 100644
+--- a/mkspecs/features/functions.prf	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:19:21.345036293 +0100
+@@ -107,6 +107,7 @@
+     contains(qtArch, "mips"): return(mipsel)
+     contains(qtArch, "mips64"): return(mips64el)
+     contains(qtArch, "mips64el"): return(mips64el)
++    contains(qtArch, "power64"): return(ppc64)
+     return(unknown)
+ }
+ 
+--- a/cmake/Functions.cmake	2021-06-27 21:30:47.236998844 +0200
++++ -	2021-06-27 21:33:50.091794753 +0200
+@@ -362,6 +362,8 @@
+       set(${result} "mipsel" PARENT_SCOPE)
+    elseif("${arch}" STREQUAL "mipsel64")
+       set(${result} "mips64el" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "power64")
++      set(${result} "ppc64" PARENT_SCOPE)
+    else()
+       message(DEBUG "Unsupported achitecture: ${arch}")
+    endif()
+
+-- 
+2.26.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch b/srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch
new file mode 100644
index 000000000000..40f2185bd4c5
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch
@@ -0,0 +1,3604 @@
+diff --git a/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn b/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn
+index 9c92012ce..a4a5cd86d 100644
+--- a/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn
++++ b/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn
+@@ -65,8 +65,6 @@ packaging_files = packaging_files_binaries + [
+                     "$root_out_dir/xdg-mime",
+                     "$root_out_dir/xdg-settings",
+                     "$root_out_dir/locales/en-US.pak",
+-                    "$root_out_dir/MEIPreload/manifest.json",
+-                    "$root_out_dir/MEIPreload/preloaded_data.pb",
+                   ]
+ 
+ action_foreach("calculate_deb_dependencies") {
+@@ -331,7 +329,6 @@ group("installer_deps") {
+     ":theme_files",
+     "//chrome",
+     "//chrome:packed_resources",
+-    "//chrome/browser/resources/media/mei_preload:component",
+     "//sandbox/linux:chrome_sandbox",
+     "//third_party/crashpad/crashpad/handler:crashpad_handler",
+   ]
+diff --git a/src/3rdparty/chromium/sandbox/features.gni b/src/3rdparty/chromium/sandbox/features.gni
+index 09280d35f..42514157f 100644
+--- a/src/3rdparty/chromium/sandbox/features.gni
++++ b/src/3rdparty/chromium/sandbox/features.gni
+@@ -11,6 +11,7 @@ import("//build/config/nacl/config.gni")
+ use_seccomp_bpf = (is_linux || is_android) &&
+                   (current_cpu == "x86" || current_cpu == "x64" ||
+                    current_cpu == "arm" || current_cpu == "arm64" ||
+-                   current_cpu == "mipsel" || current_cpu == "mips64el")
++                   current_cpu == "mipsel" || current_cpu == "mips64el" ||
++                   current_cpu == "ppc64")
+ 
+ use_seccomp_bpf = use_seccomp_bpf || is_nacl_nonsfi
+diff --git a/src/3rdparty/chromium/sandbox/linux/BUILD.gn b/src/3rdparty/chromium/sandbox/linux/BUILD.gn
+index c27351f9a..9141e1239 100644
+--- a/src/3rdparty/chromium/sandbox/linux/BUILD.gn
++++ b/src/3rdparty/chromium/sandbox/linux/BUILD.gn
+@@ -407,6 +407,8 @@ component("sandbox_services") {
+ 
+ source_set("sandbox_services_headers") {
+   sources = [
++    "system_headers/ppc64_linux_syscalls.h",
++    "system_headers/ppc64_linux_ucontext.h",
+     "system_headers/arm64_linux_syscalls.h",
+     "system_headers/arm_linux_syscalls.h",
+     "system_headers/arm_linux_ucontext.h",
+diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
+index 313511f22..0ca3a326f 100644
+--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
++++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
+@@ -56,6 +56,13 @@
+ #define MAX_PUBLIC_SYSCALL __NR_syscalls
+ #define MAX_SYSCALL MAX_PUBLIC_SYSCALL
+ 
++#elif defined(__powerpc64__)
++
++#include <asm/unistd.h>
++#define MIN_SYSCALL 0u
++#define MAX_PUBLIC_SYSCALL 386u
++#define MAX_SYSCALL MAX_PUBLIC_SYSCALL
++
+ #else
+ #error "Unsupported architecture"
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+index 1a407b952..a6aec544e 100644
+--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
++++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+@@ -16,6 +16,9 @@
+ #if defined(__mips__)
+ // sys/user.h in eglibc misses size_t definition
+ #include <stddef.h>
++#elif defined(__powerpc64__)
++// Manually define greg_t on ppc64
++typedef unsigned long long greg_t;
+ #endif
+ #endif
+ 
+@@ -346,6 +349,51 @@ struct regs_struct {
+ #define SECCOMP_PT_PARM4(_regs) (_regs).regs[3]
+ #define SECCOMP_PT_PARM5(_regs) (_regs).regs[4]
+ #define SECCOMP_PT_PARM6(_regs) (_regs).regs[5]
++
++#elif defined(__powerpc64__)
++#include <asm/ptrace.h>
++
++typedef struct pt_regs regs_struct;
++
++#ifdef ARCH_CPU_LITTLE_ENDIAN
++#define SECCOMP_ARCH AUDIT_ARCH_PPC64LE
++#else
++#define SECCOMP_ARCH AUDIT_ARCH_PPC64
++#endif
++
++#define SECCOMP_REG(_ctx, _reg) ((_ctx)->uc_mcontext.regs->gpr[_reg])
++
++#define SECCOMP_RESULT(_ctx) SECCOMP_REG(_ctx, 3)
++#define SECCOMP_SYSCALL(_ctx) SECCOMP_REG(_ctx, 0)
++#define SECCOMP_IP(_ctx) (_ctx)->uc_mcontext.regs->nip
++#define SECCOMP_PARM1(_ctx) SECCOMP_REG(_ctx, 3)
++#define SECCOMP_PARM2(_ctx) SECCOMP_REG(_ctx, 4)
++#define SECCOMP_PARM3(_ctx) SECCOMP_REG(_ctx, 5)
++#define SECCOMP_PARM4(_ctx) SECCOMP_REG(_ctx, 6)
++#define SECCOMP_PARM5(_ctx) SECCOMP_REG(_ctx, 7)
++#define SECCOMP_PARM6(_ctx) SECCOMP_REG(_ctx, 8)
++
++#define SECCOMP_NR_IDX (offsetof(struct arch_seccomp_data, nr))
++#define SECCOMP_ARCH_IDX (offsetof(struct arch_seccomp_data, arch))
++#define SECCOMP_IP_MSB_IDX \
++  (offsetof(struct arch_seccomp_data, instruction_pointer) + 4)
++#define SECCOMP_IP_LSB_IDX \
++  (offsetof(struct arch_seccomp_data, instruction_pointer) + 0)
++#define SECCOMP_ARG_MSB_IDX(nr) \
++  (offsetof(struct arch_seccomp_data, args) + 8 * (nr) + 4)
++#define SECCOMP_ARG_LSB_IDX(nr) \
++  (offsetof(struct arch_seccomp_data, args) + 8 * (nr) + 0)
++
++#define SECCOMP_PT_RESULT(_regs) (_regs).gpr[3]
++#define SECCOMP_PT_SYSCALL(_regs) (_regs).gpr[0]
++#define SECCOMP_PT_IP(_regs) (_regs).nip
++#define SECCOMP_PT_PARM1(_regs) (_regs).gpr[3]
++#define SECCOMP_PT_PARM2(_regs) (_regs).gpr[4]
++#define SECCOMP_PT_PARM3(_regs) (_regs).gpr[5]
++#define SECCOMP_PT_PARM4(_regs) (_regs).gpr[6]
++#define SECCOMP_PT_PARM5(_regs) (_regs).gpr[7]
++#define SECCOMP_PT_PARM6(_regs) (_regs).gpr[8]
++
+ #else
+ #error Unsupported target platform
+ 
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+index 712f9699a..55f062817 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -88,7 +88,8 @@ bool IsBaselinePolicyWatched(int sysno) {
+          SyscallSets::IsPrctl(sysno) ||
+          SyscallSets::IsProcessGroupOrSession(sysno) ||
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+          SyscallSets::IsSocketCall(sysno) ||
+ #endif
+ #if defined(__arm__)
+@@ -210,7 +211,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno,
+   }
+ 
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+   if (sysno == __NR_mmap)
+     return RestrictMmapFlags();
+ #endif
+@@ -228,7 +229,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno,
+     return RestrictPrctl();
+ 
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+   if (sysno == __NR_socketpair) {
+     // Only allow AF_UNIX, PF_UNIX. Crash if anything else is seen.
+     static_assert(AF_UNIX == PF_UNIX,
+@@ -268,7 +269,8 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno,
+   }
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   if (SyscallSets::IsSocketCall(sysno))
+     return RestrictSocketcallCommand();
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc
+index fc36187c9..1affc9189 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc
+@@ -291,8 +291,10 @@ TEST_BASELINE_SIGSYS(__NR_timer_create)
+ #if !defined(__aarch64__)
+ TEST_BASELINE_SIGSYS(__NR_eventfd)
+ TEST_BASELINE_SIGSYS(__NR_inotify_init)
++#if !defined(__powerpc64__)
+ TEST_BASELINE_SIGSYS(__NR_vserver)
+ #endif
++#endif
+ 
+ #if defined(LIBC_GLIBC) && !defined(OS_CHROMEOS)
+ BPF_TEST_C(BaselinePolicy, FutexEINVAL, BaselinePolicy) {
+diff --git sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc
+index f51915edc..ca2f4f106 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc
++++ a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc
+@@ -40,7 +40,8 @@
+ #include <sys/ptrace.h>
+ #if (defined(OS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \
+     !defined(__arm__) && !defined(__aarch64__) &&           \
+-    !defined(PTRACE_GET_THREAD_AREA)
++    !defined(PTRACE_GET_THREAD_AREA) &&			    \
++    !defined(__powerpc64__)
+ // Also include asm/ptrace-abi.h since ptrace.h in older libc (for instance
+ // the one in Ubuntu 16.04 LTS) is missing PTRACE_GET_THREAD_AREA.
+ // asm/ptrace-abi.h doesn't exist on arm32 and PTRACE_GET_THREAD_AREA isn't
+@@ -49,6 +50,11 @@
+ #endif
+ #endif  // !OS_NACL_NONSFI
+ 
++// On PPC64, TCGETS is defined in terms of struct termios, so we must include termios.h
++#ifdef __powerpc64__
++#include <termios.h>
++#endif
++
+ #if defined(OS_ANDROID)
+ 
+ #if !defined(F_DUPFD_CLOEXEC)
+@@ -98,6 +104,15 @@
+ #endif
+ }
+ 
++inline bool IsArchitecturePPC64() {
++#if defined(__powerpc64__)
++  return true;
++#else
++  return false;
++#endif
++}
++
++
+ // Ubuntu's version of glibc has a race condition in sem_post that can cause
+ // it to call futex(2) with bogus op arguments. To workaround this, we need
+ // to allow those futex(2) calls to fail with EINVAL, instead of crashing the
+@@ -239,6 +254,8 @@
+   uint64_t kOLargeFileFlag = O_LARGEFILE;
+   if (IsArchitectureX86_64() || IsArchitectureI386() || IsArchitectureMips())
+     kOLargeFileFlag = 0100000;
++  else if (IsArchitecturePPC64())
++    kOLargeFileFlag = 0200000;
+ 
+   const Arg<int> cmd(1);
+   const Arg<long> long_arg(2);
+@@ -253,14 +270,23 @@
+               F_SETLKW,
+               F_GETLK,
+               F_DUPFD,
+-              F_DUPFD_CLOEXEC),
+-             Allow())
++              F_DUPFD_CLOEXEC
++#if defined(__powerpc64__)
++// On PPC64, F_SETLK, F_GETLK, F_SETLKW are defined as the 64-bit variants
++// but glibc will sometimes still use the 32-bit versions. Allow both.
++              ,
++              5, /* F_GETLK (32) */
++              6, /* F_SETLK (32) */
++              7  /* F_SETLKW (32) */
++#endif
++              ),
++            Allow())
+       .Case(F_SETFL,
+             If((long_arg & ~kAllowedMask) == 0, Allow()).Else(CrashSIGSYS()))
+       .Default(CrashSIGSYS());
+ }
+ 
+-#if defined(__i386__) || defined(__mips__)
++#if defined(__i386__) || defined(__mips__) || defined(__powerpc64__)
+ ResultExpr RestrictSocketcallCommand() {
+   // Unfortunately, we are unable to restrict the first parameter to
+   // socketpair(2). Whilst initially sounding bad, it's noteworthy that very
+@@ -450,7 +450,7 @@
+ #endif
+   return Switch(request)
+       .CASES((
+-#if !defined(__aarch64__)
++#if !defined(__aarch64__) && !defined(__powerpc64__)
+                  PTRACE_GETREGS, PTRACE_GETFPREGS,
+ #if defined(TRACE_GET_THREAD_AREA)
+                  PTRACE_GET_THREAD_AREA,
+
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h
+index ba4289f05..9a4d5ab2d 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h
+@@ -48,7 +48,7 @@ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictMprotectFlags();
+ // O_NONBLOCK | O_SYNC | O_LARGEFILE | O_CLOEXEC | O_NOATIME.
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictFcntlCommands();
+ 
+-#if defined(__i386__) || defined(__mips__)
++#if defined(__i386__) || defined(__mips__) || defined(__powerpc64__)
+ // Restrict socketcall(2) to only allow socketpair(2), send(2), recv(2),
+ // sendto(2), recvfrom(2), shutdown(2), sendmsg(2) and recvmsg(2).
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictSocketcallCommand();
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+index e16223a5e..8f37dd7dc 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -29,7 +29,8 @@ bool SyscallSets::IsAllowedGettime(int sysno) {
+   switch (sysno) {
+     case __NR_gettimeofday:
+ #if defined(__i386__) || defined(__x86_64__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_time:
+ #endif
+       return true;
+@@ -41,12 +42,14 @@ bool SyscallSets::IsAllowedGettime(int sysno) {
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_ftime:  // Obsolete.
+ #endif
+     case __NR_settimeofday:  // Privileged.
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_stime:
+ #endif
+     default:
+@@ -112,7 +115,7 @@ bool SyscallSets::IsFileSystem(int sysno) {
+     case __NR_faccessat:  // EPERM not a valid errno.
+     case __NR_fchmodat:
+     case __NR_fchownat:  // Should be called chownat ?
+-#if defined(__x86_64__) || defined(__aarch64__)
++#if defined(__x86_64__) || defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_newfstatat:  // fstatat(). EPERM not a valid errno.
+ #elif defined(__i386__) || defined(__arm__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+@@ -131,7 +134,7 @@ bool SyscallSets::IsFileSystem(int sysno) {
+     case __NR_memfd_create:
+     case __NR_mkdirat:
+     case __NR_mknodat:
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_oldlstat:
+     case __NR_oldstat:
+ #endif
+@@ -145,7 +148,8 @@ bool SyscallSets::IsFileSystem(int sysno) {
+ #endif
+     case __NR_statfs:  // EPERM not a valid errno.
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_statfs64:
+ #endif
+     case __NR_symlinkat:
+@@ -155,7 +159,8 @@ bool SyscallSets::IsFileSystem(int sysno) {
+     case __NR_truncate64:
+ #endif
+     case __NR_unlinkat:
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_utime:
+ #endif
+     case __NR_utimensat:  // New.
+@@ -174,7 +179,8 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) {
+ #endif
+       return true;
+ // TODO(jln): these should be denied gracefully as well (moved below).
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_fadvise64:  // EPERM not a valid errno.
+ #endif
+ #if defined(__i386__)
+@@ -187,11 +193,12 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) {
+     case __NR_flock:      // EPERM not a valid errno.
+     case __NR_fstatfs:    // Give information about the whole filesystem.
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_fstatfs64:
+ #endif
+     case __NR_fsync:  // EPERM not a valid errno.
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_oldfstat:
+ #endif
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+@@ -199,6 +206,8 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) {
+     case __NR_sync_file_range:  // EPERM not a valid errno.
+ #elif defined(__arm__)
+     case __NR_arm_sync_file_range:  // EPERM not a valid errno.
++#elif defined(__powerpc64__)
++    case __NR_sync_file_range2: // EPERM not a valid errno.
+ #endif
+     default:
+       return false;
+@@ -224,7 +233,8 @@ bool SyscallSets::IsDeniedFileSystemAccessViaFd(int sysno) {
+ #endif
+     case __NR_getdents64:  // EPERM not a valid errno.
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_readdir:
+ #endif
+       return true;
+@@ -265,7 +275,7 @@ bool SyscallSets::IsGetSimpleId(int sysno) {
+ bool SyscallSets::IsProcessPrivilegeChange(int sysno) {
+   switch (sysno) {
+     case __NR_capset:
+-#if defined(__i386__) || defined(__x86_64__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__)
+     case __NR_ioperm:  // Intel privilege.
+     case __NR_iopl:    // Intel privilege.
+ #endif
+@@ -316,7 +326,8 @@ bool SyscallSets::IsAllowedSignalHandling(int sysno) {
+     case __NR_rt_sigreturn:
+     case __NR_rt_sigtimedwait:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_sigaction:
+     case __NR_sigprocmask:
+     case __NR_sigreturn:
+@@ -332,7 +343,8 @@ bool SyscallSets::IsAllowedSignalHandling(int sysno) {
+ #endif
+     case __NR_signalfd4:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_sigpending:
+     case __NR_sigsuspend:
+ #endif
+@@ -356,7 +368,7 @@ bool SyscallSets::IsAllowedOperationOnFd(int sysno) {
+ #endif
+     case __NR_dup3:
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_shutdown:
+ #endif
+       return true;
+@@ -390,7 +402,7 @@ bool SyscallSets::IsAllowedProcessStartOrDeath(int sysno) {
+     case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_waitpid:
+ #endif
+ #if !defined(__GLIBC__)
+@@ -412,7 +424,7 @@ bool SyscallSets::IsAllowedProcessStartOrDeath(int sysno) {
+     case __NR_set_tid_address:
+ #endif
+     case __NR_unshare:
+-#if !defined(__mips__) && !defined(__aarch64__)
++#if !defined(__mips__) && !defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_vfork:
+ #endif
+     default:
+@@ -461,7 +473,7 @@ bool SyscallSets::IsAllowedGetOrModifySocket(int sysno) {
+       return true;
+     default:
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_socketpair:  // We will want to inspect its argument.
+ #endif
+       return false;
+@@ -471,7 +483,7 @@ bool SyscallSets::IsAllowedGetOrModifySocket(int sysno) {
+ bool SyscallSets::IsDeniedGetOrModifySocket(int sysno) {
+   switch (sysno) {
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_accept:
+     case __NR_accept4:
+     case __NR_bind:
+@@ -486,7 +498,8 @@ bool SyscallSets::IsDeniedGetOrModifySocket(int sysno) {
+ }
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+ // Big multiplexing system call for sockets.
+ bool SyscallSets::IsSocketCall(int sysno) {
+   switch (sysno) {
+@@ -500,7 +513,8 @@ bool SyscallSets::IsSocketCall(int sysno) {
+ }
+ #endif
+ 
+-#if defined(__x86_64__) || defined(__arm__) || defined(__mips__)
++#if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
++    defined(__powerpc64__)
+ bool SyscallSets::IsNetworkSocketInformation(int sysno) {
+   switch (sysno) {
+     case __NR_getpeername:
+@@ -528,7 +542,7 @@ bool SyscallSets::IsAllowedAddressSpaceAccess(int sysno) {
+     case __NR_mincore:
+     case __NR_mlockall:
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_mmap:
+ #endif
+ #if defined(__i386__) || defined(__arm__) || \
+@@ -560,7 +574,8 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) {
+   switch (sysno) {
+     case __NR_lseek:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR__llseek:
+ #endif
+ #if !defined(__aarch64__)
+@@ -572,26 +587,28 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) {
+     case __NR_readv:
+     case __NR_pread64:
+ #if defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_recv:
+ #endif
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_recvfrom:  // Could specify source.
+     case __NR_recvmsg:   // Could specify source.
+ #endif
+-#if defined(__i386__) || defined(__x86_64__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__)
+     case __NR_select:
+ #endif
+-#if defined(__i386__) || defined(__arm__) || defined(__mips__)
++#if defined(__i386__) || defined(__arm__) || defined(__mips__) || defined(__powerpc64__)
+     case __NR__newselect:
+ #endif
+ #if defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_send:
+ #endif
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_sendmsg:  // Could specify destination.
+     case __NR_sendto:   // Could specify destination.
+ #endif
+@@ -648,7 +665,8 @@ bool SyscallSets::IsAllowedBasicScheduler(int sysno) {
+       return true;
+     case __NR_getpriority:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_nice:
+ #endif
+     case __NR_setpriority:
+@@ -660,7 +678,8 @@ bool SyscallSets::IsAllowedBasicScheduler(int sysno) {
+ bool SyscallSets::IsAdminOperation(int sysno) {
+   switch (sysno) {
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_bdflush:
+ #endif
+     case __NR_kexec_load:
+@@ -676,7 +695,8 @@ bool SyscallSets::IsAdminOperation(int sysno) {
+ 
+ bool SyscallSets::IsKernelModule(int sysno) {
+   switch (sysno) {
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_create_module:
+     case __NR_get_kernel_syms:  // Should ENOSYS.
+     case __NR_query_module:
+@@ -709,7 +729,8 @@ bool SyscallSets::IsFsControl(int sysno) {
+     case __NR_swapoff:
+     case __NR_swapon:
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_umount:
+ #endif
+     case __NR_umount2:
+@@ -725,7 +746,7 @@ bool SyscallSets::IsNuma(int sysno) {
+     case __NR_getcpu:
+     case __NR_mbind:
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_migrate_pages:
+ #endif
+     case __NR_move_pages:
+@@ -754,14 +775,15 @@ bool SyscallSets::IsGlobalProcessEnvironment(int sysno) {
+   switch (sysno) {
+     case __NR_acct:  // Privileged.
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_getrlimit:
+ #endif
+-#if defined(__i386__) || defined(__arm__)
++#if defined(__i386__) || defined(__arm__) || defined(__powerpc64__)
+     case __NR_ugetrlimit:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_ulimit:
+ #endif
+     case __NR_getrusage:
+@@ -795,7 +817,7 @@ bool SyscallSets::IsGlobalSystemStatus(int sysno) {
+ #endif
+     case __NR_sysinfo:
+     case __NR_uname:
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_olduname:
+     case __NR_oldolduname:
+ #endif
+@@ -890,7 +912,8 @@ bool SyscallSets::IsSystemVMessageQueue(int sysno) {
+ #endif
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+ // Big system V multiplexing system call.
+ bool SyscallSets::IsSystemVIpc(int sysno) {
+   switch (sysno) {
+@@ -910,7 +933,8 @@ bool SyscallSets::IsAnySystemV(int sysno) {
+   return IsSystemVMessageQueue(sysno) || IsSystemVSemaphores(sysno) ||
+          IsSystemVSharedMemory(sysno);
+ #elif defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   return IsSystemVIpc(sysno);
+ #endif
+ }
+@@ -963,7 +987,8 @@ bool SyscallSets::IsFaNotify(int sysno) {
+ bool SyscallSets::IsTimer(int sysno) {
+   switch (sysno) {
+     case __NR_getitimer:
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_alarm:
+ #endif
+     case __NR_setitimer:
+@@ -1022,18 +1047,22 @@ bool SyscallSets::IsMisc(int sysno) {
+     case __NR_syncfs:
+     case __NR_vhangup:
+ // The system calls below are not implemented.
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_afs_syscall:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_break:
+ #endif
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_getpmsg:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_gtty:
+     case __NR_idle:
+     case __NR_lock:
+@@ -1041,20 +1070,22 @@ bool SyscallSets::IsMisc(int sysno) {
+     case __NR_prof:
+     case __NR_profil:
+ #endif
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_putpmsg:
+ #endif
+ #if defined(__x86_64__)
+     case __NR_security:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_stty:
+ #endif
+-#if defined(__x86_64__)
++#if defined(__x86_64__) || defined(__powerpc64__)
+     case __NR_tuxcall:
+ #endif
+-#if !defined(__aarch64__)
++#if !defined(__aarch64__) && !defined(__powerpc64__)
+     case __NR_vserver:
+ #endif
+       return true;
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h
+index 923533ec9..e2bb1db98 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h
+@@ -43,13 +43,14 @@ class SANDBOX_EXPORT SyscallSets {
+   static bool IsDeniedGetOrModifySocket(int sysno);
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   // Big multiplexing system call for sockets.
+   static bool IsSocketCall(int sysno);
+ #endif
+ 
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+   static bool IsNetworkSocketInformation(int sysno);
+ #endif
+ 
+@@ -88,7 +89,8 @@ class SANDBOX_EXPORT SyscallSets {
+ #endif
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   // Big system V multiplexing system call.
+   static bool IsSystemVIpc(int sysno);
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+index 34edabd2b..10fa5fd07 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+@@ -16,7 +16,7 @@ namespace sandbox {
+ namespace {
+ 
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \
+-    defined(ARCH_CPU_MIPS_FAMILY)
++    defined(ARCH_CPU_MIPS_FAMILY) || defined (ARCH_CPU_PPC64_FAMILY)
+ // Number that's not currently used by any Linux kernel ABIs.
+ const int kInvalidSyscallNumber = 0x351d3;
+ #else
+@@ -308,12 +308,56 @@ asm(// We need to be able to tell the kernel exactly where we made a
+     // Enter the kernel
+     "svc 0\n"
+     "2:ret\n"
++    ".cfi_endproc\n"
++    ".size SyscallAsm, .-SyscallAsm\n"
++#elif defined(__powerpc64__)
++    ".text\n"
++    ".align 4\n"
++    ".type SyscallAsm @function\n"
++    "SyscallAsm:\n"
++    ".cfi_startproc\n"
++
++    // Check if r3 is negative
++    "cmpdi 3, 0\n"
++    "bgt 2f\n"
++
++    // Load address of 3f into r3 and return
++    "mflr 10\n"
++    "bl 1f\n"
++    "1: mflr 3\n"
++    "mtlr 10\n"
++    "addi 3, 3, 4*13\n"
++    "blr\n"
++
++    // Load arguments from array into r3-8
++    // save param 3 in r10
++    "2:\n"
++    "mr 0, 3\n"
++    "ld 3, 0(4)\n"
++    "ld 5, 16(4)\n"
++    "ld 6, 24(4)\n"
++    "ld 7, 32(4)\n"
++    "ld 8, 40(4)\n"
++    "ld 4, 8(4)\n"
++    "li 9, 0\n"
++
++    // Enter kernel
++    "sc\n"
++
++    // Magic return address
++    "3:\n"
++    // Like MIPS, ppc64 return values are always positive.
++    // Check for error in cr0.SO and negate upon error
++    "bc 4, 3, 4f\n"
++    "neg 3, 3\n"
++    "4: blr\n"
++
+     ".cfi_endproc\n"
+     ".size SyscallAsm, .-SyscallAsm\n"
+ #endif
+     );  // asm
+ 
+-#if defined(__x86_64__)
++#if defined(__x86_64__) || defined(__powerpc64__)
+ extern "C" {
+ intptr_t SyscallAsm(intptr_t nr, const intptr_t args[6]);
+ }
+@@ -427,6 +471,8 @@ intptr_t Syscall::Call(int nr,
+     ret = inout;
+   }
+ 
++#elif defined(__powerpc64__)
++  intptr_t ret = SyscallAsm(nr, args);
+ #else
+ #error "Unimplemented architecture"
+ #endif
+@@ -443,8 +489,18 @@ void Syscall::PutValueInUcontext(intptr_t ret_val, ucontext_t* ctx) {
+     // needs to be changed back.
+     ret_val = -ret_val;
+     SECCOMP_PARM4(ctx) = 1;
+-  } else
++  } else {
+     SECCOMP_PARM4(ctx) = 0;
++  }
++#endif
++#if defined(__powerpc64__)
++  // Same as MIPS, need to invert ret and set error register (cr0.SO)
++  if (ret_val <= -1 && ret_val >= -4095) {
++    ret_val = -ret_val;
++    ctx->uc_mcontext.regs->ccr |= (1 << 28);
++  } else {
++    ctx->uc_mcontext.regs->ccr &= ~(1 << 28);
++  }
+ #endif
+   SECCOMP_RESULT(ctx) = static_cast<greg_t>(ret_val);
+ }
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc
+index 663d9e896..f55e03ed5 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc
+@@ -237,6 +237,20 @@ void Trap::SigSys(int nr, LinuxSigInfo* info, ucontext_t* ctx) {
+       SetIsInSigHandler();
+     }
+ 
++#if defined(__powerpc64__)
++    // On ppc64+glibc, some syscalls seem to accidentally negate the first
++    // parameter which causes checks against it to fail. For now, manually
++    // negate them back.
++    // TODO(shawn@anastas.io): investigate this issue further
++    auto nr = SECCOMP_SYSCALL(ctx);
++    if (nr == __NR_openat || nr == __NR_mkdirat || nr == __NR_faccessat || nr == __NR_readlinkat ||
++        nr == __NR_renameat || nr == __NR_renameat2 || nr == __NR_newfstatat || nr == __NR_unlinkat) {
++        if (static_cast<int>(SECCOMP_PARM1(ctx)) > 0) {
++            SECCOMP_PARM1(ctx) = -SECCOMP_PARM1(ctx);
++        }
++    }
++#endif
++
+     // Copy the seccomp-specific data into a arch_seccomp_data structure. This
+     // is what we are showing to TrapFnc callbacks that the system call
+     // evaluator registered with the sandbox.
+diff --git a/src/3rdparty/chromium/sandbox/linux/services/credentials.cc b/src/3rdparty/chromium/sandbox/linux/services/credentials.cc
+index d7b5d8c44..4adc6d0d4 100644
+--- a/src/3rdparty/chromium/sandbox/linux/services/credentials.cc
++++ b/src/3rdparty/chromium/sandbox/linux/services/credentials.cc
+@@ -81,7 +81,7 @@ bool ChrootToSafeEmptyDir() {
+   pid_t pid = -1;
+   alignas(16) char stack_buf[PTHREAD_STACK_MIN];
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \
+-    defined(ARCH_CPU_MIPS_FAMILY)
++    defined(ARCH_CPU_MIPS_FAMILY) || defined(ARCH_CPU_PPC64_FAMILY)
+   // The stack grows downward.
+   void* stack = stack_buf + sizeof(stack_buf);
+ #else
+diff --git a/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc b/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+index fcfd2aa12..f6eb32fb7 100644
+--- a/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
++++ b/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+@@ -58,7 +58,7 @@ long sys_clone(unsigned long flags,
+ #if defined(ARCH_CPU_X86_64)
+   return syscall(__NR_clone, flags, child_stack, ptid, ctid, tls);
+ #elif defined(ARCH_CPU_X86) || defined(ARCH_CPU_ARM_FAMILY) || \
+-    defined(ARCH_CPU_MIPS_FAMILY)
++    defined(ARCH_CPU_MIPS_FAMILY) || defined(ARCH_CPU_PPC64_FAMILY)
+   // CONFIG_CLONE_BACKWARDS defined.
+   return syscall(__NR_clone, flags, child_stack, ptid, tls, ctid);
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc b/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc
+index 8321d2379..7e5ad1de3 100644
+--- a/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc
++++ b/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc
+@@ -157,7 +157,7 @@ bool BrokerProcess::IsSyscallAllowed(int sysno) const {
+ #if defined(__NR_fstatat)
+     case __NR_fstatat:
+ #endif
+-#if defined(__x86_64__) || defined(__aarch64__)
++#if defined(__x86_64__) || defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_newfstatat:
+ #endif
+       return !fast_check_in_client_ || allowed_command_set_.test(COMMAND_STAT);
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h
+index a60fe2ad3..9dccdb51d 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h
+@@ -29,6 +29,9 @@
+ #ifndef EM_AARCH64
+ #define EM_AARCH64 183
+ #endif
++#ifndef EM_PPC64
++#define EM_PPC64 21
++#endif
+ 
+ #ifndef __AUDIT_ARCH_64BIT
+ #define __AUDIT_ARCH_64BIT 0x80000000
+@@ -54,6 +57,12 @@
+ #ifndef AUDIT_ARCH_AARCH64
+ #define AUDIT_ARCH_AARCH64 (EM_AARCH64 | __AUDIT_ARCH_64BIT | __AUDIT_ARCH_LE)
+ #endif
++#ifndef AUDIT_ARCH_PPC64
++#define AUDIT_ARCH_PPC64 (EM_PPC64 | __AUDIT_ARCH_64BIT)
++#endif
++#ifndef AUDIT_ARCH_PPC64LE
++#define AUDIT_ARCH_PPC64LE (EM_PPC64 | __AUDIT_ARCH_64BIT | __AUDIT_ARCH_LE)
++#endif
+ 
+ // For prctl.h
+ #ifndef PR_SET_SECCOMP
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h
+index f5a736761..515b21a5f 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h
+@@ -13,7 +13,7 @@
+ // (not undefined, but defined different values and in different memory
+ // layouts). So, fill the gap here.
+ #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+ 
+ #define LINUX_SIGHUP 1
+ #define LINUX_SIGINT 2
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h
+index 2b78a0cc3..0a70f5ea5 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h
+@@ -35,5 +35,9 @@
+ #include "sandbox/linux/system_headers/arm64_linux_syscalls.h"
+ #endif
+ 
++#if defined(__powerpc64__)
++#include "sandbox/linux/system_headers/ppc64_linux_syscalls.h"
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_LINUX_SYSCALLS_H_
+ 
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h
+index 22ce78027..a69b024c2 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h
+@@ -11,6 +11,8 @@
+ #include "sandbox/linux/system_headers/arm_linux_ucontext.h"
+ #elif defined(__i386__)
+ #include "sandbox/linux/system_headers/i386_linux_ucontext.h"
++#elif defined(__powerpc64__)
++#include "sandbox/linux/system_headers/ppc64_linux_ucontext.h"
+ #else
+ #error "No support for your architecture in PNaCl header"
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_syscalls.h b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_syscalls.h
+new file mode 100644
+index 000000000..ccacffe22
+--- /dev/null
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_syscalls.h
+@@ -0,0 +1,12 @@
++// Copyright 2014 The Chromium Authors. All rights reserved.
++// Use of this source code is governed by a BSD-style license that can be
++// found in the LICENSE file.
++
++#ifndef SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_
++#define SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_
++
++#include <asm/unistd.h>
++
++//TODO: is it necessary to redefine syscall numbers for PPC64?
++
++#endif  // SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_ucontext.h b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_ucontext.h
+new file mode 100644
+index 000000000..07728e087
+--- /dev/null
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_ucontext.h
+@@ -0,0 +1,12 @@
++// Copyright 2014 The Chromium Authors. All rights reserved.
++// Use of this source code is governed by a BSD-style license that can be
++// found in the LICENSE file.
++
++#ifndef SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_UCONTEXT_H_
++#define SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_UCONTEXT_H_
++
++#include <sys/ucontext.h>
++
++//TODO: is it necessary to redefine ucontext on PPC64?
++
++#endif  // SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_UCONTEXT_H_
+diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc
+index 443e9114b..6df5678d6 100644
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc
++++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc
+@@ -15,6 +15,11 @@
+ #include "sandbox/linux/system_headers/linux_syscalls.h"
+ #include "services/service_manager/sandbox/linux/sandbox_linux.h"
+ 
++// On PPC64, TCGETS is defined in terms of struct termios, so we must include termios.h
++#ifdef __powerpc64__
++#include <termios.h>
++#endif
++
+ // TODO(vignatti): replace the local definitions below with #include
+ // <linux/dma-buf.h> once kernel version 4.6 becomes widely used.
+ #include <linux/types.h>
+diff --git a/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h b/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h
+index 3a807e1e3..5258617a7 100644
+--- a/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h
++++ b/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h
+@@ -92,7 +92,16 @@ class TInfoSinkBase
+             stream.precision(8);
+             stream << f;
+         }
+-        sink.append(stream.str());
++
++        // Hack to work around a bug where negative floating point values
++        // are rendered like '.0.5' instead of '-0.5'
++        std::string res(stream.str());
++
++        if (signbit(f)) { // test if f is negative
++            res[0] = '-';
++        }
++
++        sink.append(res);
+         return *this;
+     }
+     // Write boolean values as their names instead of integral value.
+diff --git a/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h b/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h
+index 746789913..9132b3fc0 100644
+--- a/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h
++++ b/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h
+@@ -9,6 +9,7 @@
+ #ifndef LIBANGLE_CONSTANTS_H_
+ #define LIBANGLE_CONSTANTS_H_
+ 
++#include <cstddef>
+ #include "common/platform.h"
+ 
+ #include <stdint.h>
+diff --git a/src/3rdparty/chromium/third_party/boringssl/BUILD.gn b/src/3rdparty/chromium/third_party/boringssl/BUILD.gn
+index b435499f4..ac8a84b6d 100644
+--- a/src/3rdparty/chromium/third_party/boringssl/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/boringssl/BUILD.gn
+@@ -101,6 +101,13 @@ if (is_win && !is_msan && current_cpu != "arm64") {
+       } else {
+         public_configs = [ ":no_asm_config" ]
+       }
++    } else if (current_cpu == "ppc64") {
++      if (is_linux) {
++        # TODO: ppc64 (be) check
++        sources += crypto_sources_linux_ppc64le
++      } else {
++        public_configs = [ ":no_asm_config" ]
++      }
+     } else {
+       public_configs = [ ":no_asm_config" ]
+     }
+diff --git a/src/3rdparty/chromium/third_party/breakpad/BUILD.gn b/src/3rdparty/chromium/third_party/breakpad/BUILD.gn
+index 5617de88..dc8bc176 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/breakpad/BUILD.gn
+@@ -598,7 +598,6 @@ if (is_linux || is_android) {
+       "breakpad/src/client/minidump_file_writer.h",
+       "breakpad/src/common/convert_UTF.cc",
+       "breakpad/src/common/convert_UTF.h",
+-      "breakpad/src/common/linux/breakpad_getcontext.S",
+       "breakpad/src/common/linux/elf_core_dump.cc",
+       "breakpad/src/common/linux/elf_core_dump.h",
+       "breakpad/src/common/linux/elfutils.cc",
+@@ -636,6 +635,15 @@ if (is_linux || is_android) {
+ 
+     libs = [ "dl" ]
+ 
++    if (current_cpu == "ppc64") {
++        defines = [ "HAVE_GETCONTEXT" ]
++        #libs += [ "ucontext" ]
++    } else {
++        sources += [
++            "breakpad/src/common/linux/breakpad_getcontext.S"
++        ]
++    }
++
+     include_dirs = [
+       ".",
+       "breakpad/src",
+@@ -686,7 +693,6 @@ if (is_linux || is_android) {
+       "breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc",
+       "breakpad/src/client/linux/minidump_writer/minidump_writer_unittest_utils.cc",
+       "breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader_unittest.cc",
+-      "breakpad/src/common/linux/breakpad_getcontext_unittest.cc",
+       "breakpad/src/common/linux/elf_core_dump_unittest.cc",
+       "breakpad/src/common/linux/file_id_unittest.cc",
+       "breakpad/src/common/linux/linux_libc_support_unittest.cc",
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h
+index 07d9171a0..9aed4cb36 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h
+@@ -44,6 +44,8 @@ typedef MDRawContextARM RawContextCPU;
+ typedef MDRawContextARM64_Old RawContextCPU;
+ #elif defined(__mips__)
+ typedef MDRawContextMIPS RawContextCPU;
++#elif defined(__powerpc64__)
++typedef MDRawContextPPC64 RawContextCPU;
+ #else
+ #error "This code has not been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+index aae1dc13b..03afec7a5 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+@@ -270,7 +270,42 @@ void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
+   out->float_save.fir = mcontext.fpc_eir;
+ #endif
+ }
+-#endif  // __mips__
++
++#elif defined(__powerpc64__)
++
++uintptr_t ThreadInfo::GetInstructionPointer() const {
++    return mcontext.gp_regs[PT_NIP];
++}
++
++void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
++    out->context_flags = MD_CONTEXT_PPC64_FULL;
++    for (int i = 0; i < MD_CONTEXT_PPC64_GPR_COUNT; i++)
++        out->gpr[i] = mcontext.gp_regs[i];
++
++    out->lr = mcontext.gp_regs[PT_LNK];
++    out->srr0 = mcontext.gp_regs[PT_NIP];
++    out->srr1 = mcontext.gp_regs[PT_MSR];
++    out->cr = mcontext.gp_regs[PT_CCR];
++    out->xer = mcontext.gp_regs[PT_XER];
++    out->ctr = mcontext.gp_regs[PT_CTR];
++    
++    for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
++        out->float_save.fpregs[i] = mcontext.fp_regs[i];
++
++    out->float_save.fpscr = mcontext.fp_regs[NFPREG-1];
++
++    for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
++        out->vector_save.save_vr[i] = \
++            {(((uint64_t)vregs.vrregs[i][0]) << 32) 
++                          | vregs.vrregs[i][1], 
++            (((uint64_t)vregs.vrregs[i][2]) << 32)
++                         | vregs.vrregs[i][3]};
++
++    out->vrsave = vregs.vrsave;
++    out->vector_save.save_vscr = {0, vregs.vscr.vscr_word};
++    out->vector_save.save_vrvalid = 0xFFFFFFFF; 
++}
++#endif  // __powerpc64__
+ 
+ void ThreadInfo::GetGeneralPurposeRegisters(void** gp_regs, size_t* size) {
+   assert(gp_regs || size);
+@@ -279,6 +314,11 @@ void ThreadInfo::GetGeneralPurposeRegisters(void** gp_regs, size_t* size) {
+     *gp_regs = mcontext.gregs;
+   if (size)
+     *size = sizeof(mcontext.gregs);
++#elif defined(__powerpc64__)
++  if (gp_regs)
++    *gp_regs = mcontext.gp_regs;
++  if (size)
++    *size = sizeof(mcontext.gp_regs);
+ #else
+   if (gp_regs)
+     *gp_regs = &regs;
+@@ -294,6 +334,11 @@ void ThreadInfo::GetFloatingPointRegisters(void** fp_regs, size_t* size) {
+     *fp_regs = &mcontext.fpregs;
+   if (size)
+     *size = sizeof(mcontext.fpregs);
++#elif defined(__powerpc64__)
++  if (fp_regs)
++    *fp_regs = &mcontext.fp_regs;
++  if (size)
++    *size = sizeof(mcontext.fp_regs);
+ #else
+   if (fp_regs)
+     *fp_regs = &fpregs;
+@@ -302,4 +347,13 @@ void ThreadInfo::GetFloatingPointRegisters(void** fp_regs, size_t* size) {
+ #endif
+ }
+ 
++#if defined(__powerpc64__)
++void ThreadInfo::GetVectorRegisters(void** v_regs, size_t* size) {
++    if (v_regs)
++        *v_regs = &vregs;
++    if (size)
++        *size = sizeof(vregs);
++}
++#endif
++
+ }  // namespace google_breakpad
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h
+index fb216fa6d..593aac822 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h
+@@ -68,6 +68,10 @@ struct ThreadInfo {
+   // Use the structures defined in <sys/user.h>
+   struct user_regs_struct regs;
+   struct user_fpsimd_struct fpregs;
++#elif defined(__powerpc64__)
++  // Use the structures defined in <sys/ucontext.h>.
++  mcontext_t mcontext;
++  vrregset_t vregs;
+ #elif defined(__mips__)
+   // Use the structure defined in <sys/ucontext.h>.
+   mcontext_t mcontext;
+@@ -84,6 +88,11 @@ struct ThreadInfo {
+ 
+   // Returns the pointer and size of float point register area.
+   void GetFloatingPointRegisters(void** fp_regs, size_t* size);
++
++#if defined(__powerpc64__)
++  // Returns the pointer and size of the vector register area. (PPC64 only)
++  void GetVectorRegisters(void** v_regs, size_t* size);
++#endif
+ };
+ 
+ }  // namespace google_breakpad
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+index a8f9ccc72..7620cf6f7 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+@@ -254,6 +254,48 @@ void UContextReader::FillCPUContext(RawContextCPU *out, const ucontext_t *uc) {
+   out->float_save.fir = uc->uc_mcontext.fpc_eir;  // Unused.
+ #endif
+ }
++
++#elif defined(__powerpc64__)
++
++uintptr_t UContextReader::GetStackPointer(const ucontext_t* uc) {
++    return uc->uc_mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP];
++}
++
++uintptr_t UContextReader::GetInstructionPointer(const ucontext_t* uc) {
++    return uc->uc_mcontext.gp_regs[PT_NIP];
++}
++
++void UContextReader::FillCPUContext(RawContextCPU* out, const ucontext_t* uc,
++                                    const vrregset_t* vregs) {
++    out->context_flags = MD_CONTEXT_PPC64_FULL;
++
++    for (int i = 0; i < MD_CONTEXT_PPC64_GPR_COUNT; i++)
++        out->gpr[i] = uc->uc_mcontext.gp_regs[i];
++
++    out->lr = uc->uc_mcontext.gp_regs[PT_LNK];    
++    out->srr0 = uc->uc_mcontext.gp_regs[PT_NIP];
++    out->srr1 = uc->uc_mcontext.gp_regs[PT_MSR];
++    out->cr = uc->uc_mcontext.gp_regs[PT_CCR];
++    out->xer = uc->uc_mcontext.gp_regs[PT_XER];
++    out->ctr = uc->uc_mcontext.gp_regs[PT_CTR];
++    
++    for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
++        out->float_save.fpregs[i] = uc->uc_mcontext.fp_regs[i];
++
++    out->float_save.fpscr = uc->uc_mcontext.fp_regs[NFPREG-1];
++
++    for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
++        out->vector_save.save_vr[i] =
++            {(((uint64_t)vregs->vrregs[i][0]) << 32) 
++                         | vregs->vrregs[i][1], 
++             (((uint64_t)vregs->vrregs[i][2]) << 32)
++                         | vregs->vrregs[i][3]};
++
++    out->vrsave = vregs->vrsave;
++    out->vector_save.save_vscr = {0, vregs->vscr.vscr_word};
++    out->vector_save.save_vrvalid = 0xFFFFFFFF; 
++}
++
+ #endif
+ 
+ }  // namespace google_breakpad
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h
+index f3dde1f4d..96079169d 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h
+@@ -54,6 +54,9 @@ struct UContextReader {
+ #elif defined(__aarch64__)
+   static void FillCPUContext(RawContextCPU *out, const ucontext_t *uc,
+                              const struct fpsimd_context* fpregs);
++#elif defined(__powerpc64__)
++  static void FillCPUContext(RawContextCPU *out, const ucontext_t *uc,
++                             const vrregset_t* vregs);
+ #else
+   static void FillCPUContext(RawContextCPU *out, const ucontext_t *uc);
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+index b895f6d7a..901cd68fb 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+@@ -461,9 +461,16 @@ bool ExceptionHandler::HandleSignal(int /*sig*/, siginfo_t* info, void* uc) {
+     memcpy(&g_crash_context_.float_state, fp_ptr,
+            sizeof(g_crash_context_.float_state));
+   }
++#elif defined(__powerpc64__)
++  // On PPC64, we must copy VR state
++  ucontext_t* uc_ptr = (ucontext_t*)uc;
++  if (uc_ptr->uc_mcontext.v_regs) {
++    memcpy(&g_crash_context_.vector_state, uc_ptr->uc_mcontext.v_regs,
++           sizeof(g_crash_context_.vector_state));
++  }
+ #elif !defined(__ARM_EABI__) && !defined(__mips__)
+   // FP state is not part of user ABI on ARM Linux.
+-  // In case of MIPS Linux FP state is already part of ucontext_t
++  // In case of MIPS, Linux FP state is already part of ucontext_t
+   // and 'float_state' is not a member of CrashContext.
+   ucontext_t* uc_ptr = (ucontext_t*)uc;
+   if (uc_ptr->uc_mcontext.fpregs) {
+@@ -701,11 +708,19 @@ bool ExceptionHandler::WriteMinidump() {
+   }
+ #endif
+ 
+-#if !defined(__ARM_EABI__) && !defined(__aarch64__) && !defined(__mips__)
++#if !defined(__ARM_EABI__) && !defined(__aarch64__) && !defined(__mips__) \
++    && !defined(__powerpc64__)
+   // FPU state is not part of ARM EABI ucontext_t.
+   memcpy(&context.float_state, context.context.uc_mcontext.fpregs,
+          sizeof(context.float_state));
+ #endif
++
++#if defined(__powerpc64__)
++  // Vector registers must be copied on PPC64
++  memcpy(&context.vector_state, context.context.uc_mcontext.v_regs,
++         sizeof(context.vector_state));
++#endif
++
+   context.tid = sys_gettid();
+ 
+   // Add an exception stream to the minidump for better reporting.
+@@ -726,6 +741,9 @@ bool ExceptionHandler::WriteMinidump() {
+ #elif defined(__mips__)
+   context.siginfo.si_addr =
+       reinterpret_cast<void*>(context.context.uc_mcontext.pc);
++#elif defined(__powerpc64__)
++  context.siginfo.si_addr =
++      reinterpret_cast<void*>(context.context.uc_mcontext.gp_regs[PT_NIP]);
+ #else
+ #error "This code has not been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h
+index f44483ff0..36ce6d6ce 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h
+@@ -192,7 +192,11 @@ class ExceptionHandler {
+     siginfo_t siginfo;
+     pid_t tid;  // the crashing thread.
+     ucontext_t context;
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++    // PPC64's FP state is a part of ucontext_t like MIPS but the vector
++    // state is not, so a struct is needed.
++    vstate_t vector_state;
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+     // #ifdef this out because FP state is not part of user ABI for Linux ARM.
+     // In case of MIPS Linux FP state is already part of ucontext_t so
+     // 'float_state' is not required.
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc
+index bcbf9c26f..2c36ed41f 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc
+@@ -307,7 +307,7 @@ TEST(ExceptionHandlerTest, ParallelChildCrashesDontHang) {
+   }
+ 
+   // Wait a while until the child should have crashed.
+-  usleep(1000000);
++  usleep(2000000);
+   // Kill the child if it is still running.
+   kill(child, SIGKILL);
+ 
+@@ -559,6 +559,8 @@ const unsigned char kIllegalInstruction[] = {
+ #if defined(__mips__)
+   // mfc2 zero,Impl - usually illegal in userspace.
+   0x48, 0x00, 0x00, 0x48
++#elif defined(__powerpc64__)
++  0x01, 0x01, 0x01, 0x01 // Crashes on a tested POWER9 cpu
+ #else
+   // This crashes with SIGILL on x86/x86-64/arm.
+   0xff, 0xff, 0xff, 0xff
+@@ -754,10 +756,10 @@ TEST(ExceptionHandlerTest, InstructionPointerMemoryMaxBound) {
+ 
+   // These are defined here so the parent can use them to check the
+   // data from the minidump afterwards.
+-  // Use 4k here because the OS will hand out a single page even
++  // Use the page size here because the OS will hand out a single page even
+   // if a smaller size is requested, and this test wants to
+   // test the upper bound of the memory range.
+-  const uint32_t kMemorySize = 4096;  // bytes
++  const uint32_t kMemorySize = getpagesize();  // bytes
+   const int kOffset = kMemorySize - sizeof(kIllegalInstruction);
+ 
+   const pid_t child = fork();
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc
+index fa3c1713a..6ce709e2f 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc
+@@ -138,7 +138,9 @@ class MicrodumpWriter {
+                   const MicrodumpExtraInfo& microdump_extra_info,
+                   LinuxDumper* dumper)
+       : ucontext_(context ? &context->context : NULL),
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++        vector_state_(context ? &context->vector_state : NULL),
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+         float_state_(context ? &context->float_state : NULL),
+ #endif
+         dumper_(dumper),
+@@ -337,6 +339,8 @@ class MicrodumpWriter {
+ # else
+ #  error "This mips ABI is currently not supported (n32)"
+ #endif
++#elif defined(__powerpc64__)
++    const char kArch[] = "ppc64";
+ #else
+ #error "This code has not been ported to your platform yet"
+ #endif
+@@ -409,7 +413,9 @@ class MicrodumpWriter {
+   void DumpCPUState() {
+     RawContextCPU cpu;
+     my_memset(&cpu, 0, sizeof(RawContextCPU));
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++    UContextReader::FillCPUContext(&cpu, ucontext_, vector_state_);
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+     UContextReader::FillCPUContext(&cpu, ucontext_, float_state_);
+ #else
+     UContextReader::FillCPUContext(&cpu, ucontext_);
+@@ -605,7 +611,9 @@ class MicrodumpWriter {
+   void* Alloc(unsigned bytes) { return dumper_->allocator()->Alloc(bytes); }
+ 
+   const ucontext_t* const ucontext_;
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++  const google_breakpad::vstate_t* const vector_state_;
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+   const google_breakpad::fpstate_t* const float_state_;
+ #endif
+   LinuxDumper* dumper_;
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc
+index c2fea0225..8c62c524a 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc
+@@ -278,10 +278,19 @@ TEST(MicrodumpWriterTest, BasicWithMappings) {
+   CrashAndGetMicrodump(mappings, MicrodumpExtraInfo(), &buf);
+   ASSERT_TRUE(ContainsMicrodump(buf));
+ 
++  int page_size = getpagesize();
+ #ifdef __LP64__
+-  ASSERT_NE(std::string::npos,
+-            buf.find("M 0000000000001000 000000000000002A 0000000000001000 "
+-                     "33221100554477668899AABBCCDDEEFF0 libfoo.so"));
++  // This test is only available for the following page sizes
++  ASSERT_TRUE((page_size == 4096) || (page_size == 65536));
++  if (page_size == 4096) { 
++    ASSERT_NE(std::string::npos,
++              buf.find("M 0000000000001000 000000000000002A 0000000000001000 "
++                       "33221100554477668899AABBCCDDEEFF0 libfoo.so"));
++  } else {
++    ASSERT_NE(std::string::npos,
++              buf.find("M 0000000000010000 000000000000002A 0000000000010000 "
++                       "33221100554477668899AABBCCDDEEFF0 libfoo.so"));
++  }
+ #else
+   ASSERT_NE(std::string::npos,
+             buf.find("M 00001000 0000002A 00001000 "
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc
+index 4756a5416..4805fb694 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc
+@@ -117,6 +117,9 @@ bool LinuxCoreDumper::GetThreadInfoByIndex(size_t index, ThreadInfo* info) {
+ #elif defined(__mips__)
+   stack_pointer =
+       reinterpret_cast<uint8_t*>(info->mcontext.gregs[MD_CONTEXT_MIPS_REG_SP]);
++#elif defined(__powerpc64__)
++  stack_pointer =
++      reinterpret_cast<uint8_t*>(info->mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP]);
+ #else
+ #error "This code hasn't been ported to your platform yet."
+ #endif
+@@ -202,7 +205,10 @@ bool LinuxCoreDumper::EnumerateThreads() {
+         memset(&info, 0, sizeof(ThreadInfo));
+         info.tgid = status->pr_pgrp;
+         info.ppid = status->pr_ppid;
+-#if defined(__mips__)
++#if defined(__powerpc64__)
++        for (int i = 0; i < 31; i++)
++            info.mcontext.gp_regs[i] = status->pr_reg[i];
++#elif defined(__mips__)
+ #if defined(__ANDROID__)
+         for (int i = EF_R0; i <= EF_R31; i++)
+           info.mcontext.gregs[i - EF_R0] = status->pr_reg[i];
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc
+index 1112035bc..8523dad63 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc
+@@ -765,7 +765,9 @@ bool LinuxDumper::GetStackInfo(const void** stack, size_t* stack_len,
+       reinterpret_cast<uint8_t*>(int_stack_pointer & ~(page_size - 1));
+ 
+   // The number of bytes of stack which we try to capture.
+-  static const ptrdiff_t kStackToCapture = 32 * 1024;
++  // This now depends on page_size to avoid missing data
++  // on systems with larger page sizes.
++  static const ptrdiff_t kStackToCapture = 8 * page_size;
+ 
+   const MappingInfo* mapping = FindMapping(stack_pointer);
+   if (!mapping)
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h
+index f4a75d906..020981f57 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h
+@@ -63,7 +63,8 @@ namespace google_breakpad {
+  (defined(__mips__) && _MIPS_SIM == _ABIO32)
+ typedef Elf32_auxv_t elf_aux_entry;
+ #elif defined(__x86_64) || defined(__aarch64__) || \
+-     (defined(__mips__) && _MIPS_SIM != _ABIO32)
++     (defined(__mips__) && _MIPS_SIM != _ABIO32) || \
++     defined(__powerpc64__)
+ typedef Elf64_auxv_t elf_aux_entry;
+ #endif
+ 
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc
+index 3ad48e501..1688c365e 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc
+@@ -51,6 +51,8 @@
+ #define TID_PTR_REGISTER "rcx"
+ #elif defined(__mips__)
+ #define TID_PTR_REGISTER "$1"
++#elif defined(__powerpc64__)
++#define TID_PTR_REGISTER "r8"
+ #else
+ #error This test has not been ported to this platform.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc
+index 8a3f04e29..e607b28d5 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc
+@@ -154,19 +154,27 @@ bool LinuxPtraceDumper::CopyFromProcess(void* dest, pid_t child,
+   return true;
+ }
+ 
+-bool LinuxPtraceDumper::ReadRegisterSet(ThreadInfo* info, pid_t tid)
+-{
++bool LinuxPtraceDumper::ReadRegisterSet(ThreadInfo* info, pid_t tid) {
+ #ifdef PTRACE_GETREGSET
+   struct iovec io;
+   info->GetGeneralPurposeRegisters(&io.iov_base, &io.iov_len);
+-  if (sys_ptrace(PTRACE_GETREGSET, tid, (void*)NT_PRSTATUS, (void*)&io) == -1) {
++  if (ptrace(PTRACE_GETREGSET, tid, (void*)NT_PRSTATUS, (void*)&io) == -1) {
+     return false;
+   }
+ 
+   info->GetFloatingPointRegisters(&io.iov_base, &io.iov_len);
+-  if (sys_ptrace(PTRACE_GETREGSET, tid, (void*)NT_FPREGSET, (void*)&io) == -1) {
++  if (ptrace(PTRACE_GETREGSET, tid, (void*)NT_FPREGSET, (void*)&io) == -1) {
+     return false;
+   }
++
++#if defined(__powerpc64__)
++  // Grab the vector registers on PPC64 too
++  info->GetVectorRegisters(&io.iov_base, &io.iov_len);
++  if (ptrace(PTRACE_GETREGSET, tid, (void*)NT_PPC_VMX, (void*)&io) == -1) {
++    return false;
++  }
++#endif // defined(__powerpc64__)
++
+   return true;
+ #else
+   return false;
+@@ -303,6 +311,9 @@ bool LinuxPtraceDumper::GetThreadInfoByIndex(size_t index, ThreadInfo* info) {
+ #elif defined(__mips__)
+   stack_pointer =
+       reinterpret_cast<uint8_t*>(info->mcontext.gregs[MD_CONTEXT_MIPS_REG_SP]);
++#elif defined(__powerpc64__)
++  stack_pointer =
++      reinterpret_cast<uint8_t*>(info->mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP]);
+ #else
+ #error "This code hasn't been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc
+index a41dafce0..31743940d 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc
+@@ -462,6 +462,9 @@ TEST(LinuxPtraceDumperTest, VerifyStackReadWithMultipleThreads) {
+ #elif defined(__mips__)
+     pid_t* process_tid_location =
+         reinterpret_cast<pid_t*>(one_thread.mcontext.gregs[1]);
++#elif defined(__powerpc64__)
++    pid_t* process_tid_location =
++        reinterpret_cast<pid_t*>(one_thread.mcontext.gp_regs[8]);
+ #else
+ #error This test has not been ported to this platform.
+ #endif
+@@ -559,6 +562,8 @@ TEST_F(LinuxPtraceDumperTest, SanitizeStackCopy) {
+   uintptr_t heap_addr = thread_info.regs.rcx;
+ #elif defined(__mips__)
+   uintptr_t heap_addr = thread_info.mcontext.gregs[1];
++#elif defined(__powerpc64__)
++  uintptr_t heap_addr = thread_info.mcontext.gp_regs[8];
+ #else
+ #error This test has not been ported to this platform.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc
+index f8cdf2a1c..cb808c151 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc
+@@ -136,7 +136,9 @@ class MinidumpWriter {
+       : fd_(minidump_fd),
+         path_(minidump_path),
+         ucontext_(context ? &context->context : NULL),
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++        vector_state_(context ? &context->vector_state : NULL),
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+         float_state_(context ? &context->float_state : NULL),
+ #endif
+         dumper_(dumper),
+@@ -468,7 +470,9 @@ class MinidumpWriter {
+         if (!cpu.Allocate())
+           return false;
+         my_memset(cpu.get(), 0, sizeof(RawContextCPU));
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++        UContextReader::FillCPUContext(cpu.get(), ucontext_, vector_state_);
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+         UContextReader::FillCPUContext(cpu.get(), ucontext_, float_state_);
+ #else
+         UContextReader::FillCPUContext(cpu.get(), ucontext_);
+@@ -897,7 +901,7 @@ class MinidumpWriter {
+     dirent->location.rva = 0;
+   }
+ 
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || defined(__powerpc64__)
+   bool WriteCPUInformation(MDRawSystemInfo* sys_info) {
+     char vendor_id[sizeof(sys_info->cpu.x86_cpu_info.vendor_id) + 1] = {0};
+     static const char vendor_id_name[] = "vendor_id";
+@@ -917,7 +921,9 @@ class MinidumpWriter {
+ 
+     // processor_architecture should always be set, do this first
+     sys_info->processor_architecture =
+-#if defined(__mips__)
++#if defined(__powerpc64__)
++        MD_CPU_ARCHITECTURE_PPC64;
++#elif defined(__mips__)
+ # if _MIPS_SIM == _ABIO32
+         MD_CPU_ARCHITECTURE_MIPS;
+ # elif _MIPS_SIM == _ABI64
+@@ -1333,7 +1339,9 @@ class MinidumpWriter {
+   const char* path_;  // Path to the file where the minidum should be written.
+ 
+   const ucontext_t* const ucontext_;  // also from the signal handler
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++  const google_breakpad::vstate_t* const vector_state_;
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+   const google_breakpad::fpstate_t* const float_state_;  // ditto
+ #endif
+   LinuxDumper* dumper_;
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h
+index d1cc5624c..320847643 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h
+@@ -47,6 +47,8 @@ class ExceptionHandler;
+ 
+ #if defined(__aarch64__)
+ typedef struct fpsimd_context fpstate_t;
++#elif defined(__powerpc64__)
++typedef vrregset_t vstate_t;
+ #elif !defined(__ARM_EABI__) && !defined(__mips__)
+ typedef struct _fpstate fpstate_t;
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc
+index c951e69d8..e1d6e40d6 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc
+@@ -714,6 +714,9 @@ TEST(MinidumpWriterTest, InvalidStackPointer) {
+ #elif defined(__mips__)
+   context.context.uc_mcontext.gregs[MD_CONTEXT_MIPS_REG_SP] =
+       invalid_stack_pointer;
++#elif defined(__powerpc64__)
++  context.context.uc_mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP] =
++      invalid_stack_pointer;
+ #else
+ # error "This code has not been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc
+index 4e938269f..f0ff15d96 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc
+@@ -65,8 +65,7 @@ bool MemoryMappedFile::Map(const char* path, size_t offset) {
+   }
+ 
+ #if defined(__x86_64__) || defined(__aarch64__) || \
+-   (defined(__mips__) && _MIPS_SIM == _ABI64)
+-
++   (defined(__mips__) && _MIPS_SIM == _ABI64) || defined(__powerpc64__)
+   struct kernel_stat st;
+   if (sys_fstat(fd, &st) == -1 || st.st_size < 0) {
+ #else
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc
+index fad59f40c..616496d67 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc
+@@ -176,9 +176,10 @@ TEST_F(MemoryMappedFileTest, RemapAfterMap) {
+ TEST_F(MemoryMappedFileTest, MapWithOffset) {
+   // Put more data in the test file this time. Offsets can only be
+   // done on page boundaries, so we need a two page file to test this.
+-  const int page_size = 4096;
+-  char data1[2 * page_size];
+-  size_t data1_size = sizeof(data1);
++  const int page_size = getpagesize();
++  char *data1 = static_cast<char*>(malloc(2 * page_size));
++  EXPECT_TRUE(data1 != NULL);
++  size_t data1_size = (2 * page_size);
+   for (size_t i = 0; i < data1_size; ++i) {
+     data1[i] = i & 0x7f;
+   }
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc
+index 43c86314c..27325b813 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc
+@@ -57,8 +57,9 @@
+ 
+   EXPECT_EQ(0U, allocator.pages_allocated());
+   uint8_t* p = reinterpret_cast<uint8_t*>(allocator.Alloc(10000));
++  uint64_t expected_pages = 1 + ((10000 - 1) / getpagesize());
+   ASSERT_FALSE(p == NULL);
+-  EXPECT_EQ(3U, allocator.pages_allocated());
++  EXPECT_EQ(expected_pages, allocator.pages_allocated());
+   for (unsigned i = 1; i < 10; ++i) {
+     uint8_t* p = reinterpret_cast<uint8_t*>(allocator.Alloc(i));
+     ASSERT_FALSE(p == NULL);
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc
+index ccc9f1459..debaed4d6 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc
+@@ -202,12 +202,14 @@ bool ExploitabilityLinux::EndedOnIllegalWrite(uint64_t instruction_ptr) {
+   // Check architecture and set architecture variable to corresponding flag
+   // in objdump.
+   switch (context->GetContextCPU()) {
++#if defined(__i386) || defined(__x86_64)
+     case MD_CONTEXT_X86:
+       architecture = "i386";
+       break;
+     case MD_CONTEXT_AMD64:
+       architecture = "i386:x86-64";
+       break;
++#endif
+     default:
+       // Unsupported architecture. Note that ARM architectures are not
+       // supported because objdump does not support ARM.
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc
+index 528ee5f21..72764d6c1 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc
+@@ -104,6 +104,8 @@ ExploitabilityFor(const string& filename) {
+ }
+ 
+ TEST(ExploitabilityTest, TestWindowsEngine) {
++// The following tests are only executable on an x86-class linux machine.
++#if !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+             ExploitabilityFor("ascii_read_av.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+@@ -136,9 +138,12 @@ TEST(ExploitabilityTest, TestWindowsEngine) {
+             ExploitabilityFor("read_av_clobber_write.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_LOW,
+             ExploitabilityFor("read_av_conditional.dmp"));
++#endif
+ }
+ 
+ TEST(ExploitabilityTest, TestLinuxEngine) {
++// The following tests are only executable on an x86-class linux machine.
++#if defined(__i386) || defined(__x86_64)
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_INTERESTING,
+             ExploitabilityFor("linux_null_read_av.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+@@ -171,7 +176,8 @@ TEST(ExploitabilityTest, TestLinuxEngine) {
+             ExploitabilityFor("linux_executable_heap.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+             ExploitabilityFor("linux_jmp_to_module_not_exe_region.dmp"));
+-#ifndef _WIN32
++#endif
++#if !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+             ExploitabilityFor("linux_write_to_nonwritable_module.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+@@ -182,10 +188,10 @@ TEST(ExploitabilityTest, TestLinuxEngine) {
+             ExploitabilityFor("linux_write_to_outside_module_via_math.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_INTERESTING,
+             ExploitabilityFor("linux_write_to_under_4k.dmp"));
+-#endif  // _WIN32
++#endif  // !defined(_WIN32) && (!defined(__i386) && !defined(__x86_64))
+ }
+ 
+-#ifndef _WIN32
++#if !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
+ TEST(ExploitabilityLinuxUtilsTest, DisassembleBytesTest) {
+   ASSERT_FALSE(ExploitabilityLinuxTest::DisassembleBytes("", NULL, 5, NULL));
+   uint8_t bytes[6] = {0xc7, 0x0, 0x5, 0x0, 0x0, 0x0};
+@@ -301,6 +307,7 @@ TEST(ExploitabilityLinuxUtilsTest, CalculateAddressTest) {
+                                                          context,
+                                                          &write_address));
+ }
+-#endif  // _WIN32
++#endif  // !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
++
+ 
+ }  // namespace
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc
+index 941586e9f..49cdc3fc2 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc
+@@ -76,6 +76,8 @@
+   #define ELF_ARCH  EM_MIPS
+ #elif defined(__aarch64__)
+   #define ELF_ARCH  EM_AARCH64
++#elif defined(__powerpc64__)
++  #define ELF_ARCH  EM_PPC64
+ #endif
+ 
+ #if defined(__arm__)
+@@ -86,6 +88,8 @@ typedef user_regs user_regs_struct;
+ #elif defined (__mips__)
+ // This file-local typedef simplifies the source code.
+ typedef gregset_t user_regs_struct;
++#elif defined(__powerpc64__)
++typedef struct pt_regs user_regs_struct;
+ #endif
+ 
+ using google_breakpad::MDTypeHelper;
+@@ -320,6 +324,9 @@ struct CrashedProcess {
+ #endif
+ #if defined(__aarch64__)
+     user_fpsimd_struct fpregs;
++#endif
++#if defined(__powerpc64__)
++    mcontext_t mcontext;
+ #endif
+     uintptr_t stack_addr;
+     const uint8_t* stack;
+@@ -534,6 +541,38 @@ ParseThreadRegisters(CrashedProcess::Thread* thread,
+   thread->mcontext.fpc_eir = rawregs->float_save.fir;
+ #endif
+ }
++#elif defined(__powerpc64__)
++static void
++ParseThreadRegisters(CrashedProcess::Thread* thread,
++                     const MinidumpMemoryRange& range) {
++  const MDRawContextPPC64* rawregs = range.GetData<MDRawContextPPC64>(0);
++
++  for (int i = 0; i < MD_CONTEXT_PPC64_GPR_COUNT; i++)
++    thread->mcontext.gp_regs[i] = rawregs->gpr[i];
++
++  thread->mcontext.gp_regs[PT_LNK] = rawregs->lr;
++  thread->mcontext.gp_regs[PT_NIP] = rawregs->srr0;
++  thread->mcontext.gp_regs[PT_MSR] = rawregs->srr1;
++  thread->mcontext.gp_regs[PT_CCR] = rawregs->cr;
++  thread->mcontext.gp_regs[PT_XER] = rawregs->xer;
++  thread->mcontext.gp_regs[PT_CTR] = rawregs->ctr;
++  thread->mcontext.v_regs->vrsave = rawregs->vrsave;
++
++  for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
++      thread->mcontext.fp_regs[i] = rawregs->float_save.fpregs[i];
++
++  thread->mcontext.fp_regs[NFPREG-1] = rawregs->float_save.fpscr;
++
++  for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++) {
++      thread->mcontext.v_regs->vrregs[i][0] = rawregs->vector_save.save_vr[i].high >> 32;
++      thread->mcontext.v_regs->vrregs[i][1] = rawregs->vector_save.save_vr[i].high;
++      thread->mcontext.v_regs->vrregs[i][2] = rawregs->vector_save.save_vr[i].low >> 32;
++      thread->mcontext.v_regs->vrregs[i][3] = rawregs->vector_save.save_vr[i].low;
++  }
++
++  thread->mcontext.v_regs->vscr.vscr_word = rawregs->vector_save.save_vscr.low & 0xFFFFFFFF;
++}
++
+ #else
+ #error "This code has not been ported to your platform yet"
+ #endif
+@@ -622,6 +661,12 @@ ParseSystemInfo(const Options& options, CrashedProcess* crashinfo,
+ # else
+ #  error "This mips ABI is currently not supported (n32)"
+ # endif
++#elif defined(__powerpc64__)
++  if (sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_PPC64) {
++    fprintf(stderr,
++            "This version of minidump-2-core only supports PPC64.\n");
++    exit(1);
++  }
+ #else
+ #error "This code has not been ported to your platform yet"
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS b/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS
+index 8724b7f32..8e29424ef 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS
+@@ -13,3 +13,4 @@ Mark Mentovai <mark@chromium.org>
+ Robert Sesek <rsesek@chromium.org>
+ Scott Graham <scottmg@chromium.org>
+ Joshua Peraza <jperaza@chromium.org>
++Shawn Anastasio <shawn@anastas.io>
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h
+index 6ed77a98e..1fd83469a 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h
+@@ -15,6 +15,7 @@
+ #ifndef CRASHPAD_COMPAT_LINUX_SYS_USER_H_
+ #define CRASHPAD_COMPAT_LINUX_SYS_USER_H_
+ 
++#include <cstddef>
+ #include_next <sys/user.h>
+ 
+ #include <features.h>
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h
+index 3a3e603cb..3118d9e9f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h
+@@ -592,6 +592,70 @@ struct MinidumpContextMIPS64 {
+   uint64_t fir;
+ };
+ 
++//! \brief ppc64-specific flags for MinidumpPPC64::context_flags
++//! Based on minidump_cpu_ppc64.h from breakpad
++enum MinidumpContextPPC64Flags : uint32_t {
++  //! \brief Identifies the context as PPC64.
++  kMinidumpContextPPC64 = 0x01000000,
++
++  //! \brief Indicates the validity of general purpose registers.
++  //!
++  //! Registers `r0`-`r31`, `nip`, `msr`, `lr`, etc. are valid.
++  kMinidumpContextPPC64Base = kMinidumpContextPPC64 | 0x00000001,
++
++  //! \brief Indicates the validity of floating point registers.
++  //!
++  //! Registers `fp0`-`fp31`, `fpscr` are valid.
++  kMinidumpContextPPC64Floating = kMinidumpContextPPC64 | 0x00000008,
++
++  //! \brief Indicates the validity of Altivec/VMX registers.
++  //!
++  //! Registers `v0`-`v31`, `vscr`, `vrsave`.
++  kMinidumpContextPPC64Vector = kMinidumpContextPPC64 | 0x00000020,
++
++  //! \brief Indicates the validity of all registers
++  kMinidumpContextPPC64All = kMinidumpContextPPC64Base     |
++                             kMinidumpContextPPC64Floating |
++                             kMinidumpContextPPC64Vector
++};
++
++//! \brief A PPC64 CPU context carried in a minidump file.
++//! Based on minidump_cpu_ppc64.h from breakpad.
++struct MinidumpContextPPC64 {
++  uint64_t context_flags;
++
++  //! \brief General purpose registers.
++  uint64_t nip;
++  uint64_t msr;
++  uint64_t regs[32];
++  uint64_t ccr;
++  uint64_t xer;
++  uint64_t lnk;
++  uint64_t ctr;
++
++  //! \brief Floating point registers.
++  double fpregs[32];
++
++  //! \brief FPU status register.
++  double fpscr;
++
++  //! \brief Altivec/VMX vector registers.
++  struct {
++      //! \brief Vector registers are 128bits.
++      uint128_struct save_vr[32];
++      uint128_struct save_vscr;
++
++      //! \brief Padding included for breakpad compatibiltiy.
++      uint32_t save_pad5[4];
++
++      //! \brief VRSAVE register.
++      uint32_t save_vrsave;
++
++      //! \brief Padding included for breakpad compatibiltiy.
++      uint32_t save_pad6[7];
++  } vregs;
++};
++
+ }  // namespace crashpad
+ 
+ #endif  // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_H_
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
+index d7e53a493..d89eb9e01 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
+@@ -101,6 +101,13 @@ MinidumpContextWriter::CreateFromSnapshot(const CPUContext* context_snapshot) {
+       break;
+     }
+ 
++    case kCPUArchitecturePPC64: {
++      context = std::make_unique<MinidumpContextPPC64Writer>();
++      reinterpret_cast<MinidumpContextPPC64Writer*>(context.get())
++          ->InitalizeFromSnapshot(context_snapshot->ppc64);
++      break;
++    }
++
+     default: {
+       LOG(ERROR) << "unknown context architecture "
+                  << context_snapshot->architecture;
+@@ -453,4 +460,47 @@ size_t MinidumpContextMIPS64Writer::ContextSize() const {
+   return sizeof(context_);
+ }
+ 
++MinidumpContextPPC64Writer::MinidumpContextPPC64Writer()
++  : MinidumpContextWriter(), context_() {
++    context_.context_flags = kMinidumpContextPPC64;
++}
++
++MinidumpContextPPC64Writer::~MinidumpContextPPC64Writer() = default;
++
++void MinidumpContextPPC64Writer::InitalizeFromSnapshot(
++    const CPUContextPPC64* context_snapshot) {
++  DCHECK_EQ(state(), kStateMutable);
++  DCHECK_EQ(context_.context_flags, kMinidumpContextPPC64);
++
++  context_.context_flags = kMinidumpContextPPC64All;
++
++  memcpy(context_.regs, context_snapshot->regs, sizeof(context_.regs));
++  context_.nip = context_snapshot->nip;
++  context_.msr = context_snapshot->msr;
++  context_.ccr = context_snapshot->ccr;
++  context_.xer = context_snapshot->xer;
++  context_.lnk = context_snapshot->lnk;
++  context_.ctr = context_snapshot->ctr;
++
++  memcpy(context_.fpregs, context_snapshot->fpregs, sizeof(context_.fpregs));
++  context_.fpscr = context_snapshot->fpscr;
++
++  memcpy(context_.vregs.save_vr, context_snapshot->vregs.save_vr,
++         sizeof(context_.vregs.save_vr));
++  memcpy(&context_.vregs.save_vscr, &context_snapshot->vregs.save_vscr,
++         sizeof(context_.vregs.save_vscr));
++  context_.vregs.save_vrsave = context_snapshot->vregs.save_vrsave;
++}
++
++bool MinidumpContextPPC64Writer::WriteObject(
++    FileWriterInterface* file_writer) {
++  DCHECK_EQ(state(), kStateWritable);
++  return file_writer->Write(&context_, sizeof(context_));
++}
++
++size_t MinidumpContextPPC64Writer::ContextSize() const {
++  DCHECK_GE(state(), kStateFrozen);
++  return sizeof(context_);
++}
++
+ }  // namespace crashpad
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h
+index d4ab936ee..1d22fc59c 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h
+@@ -315,6 +315,45 @@ class MinidumpContextMIPS64Writer final : public MinidumpContextWriter {
+   DISALLOW_COPY_AND_ASSIGN(MinidumpContextMIPS64Writer);
+ };
+ 
++class MinidumpContextPPC64Writer final : public MinidumpContextWriter {
++ public:
++  MinidumpContextPPC64Writer();
++  ~MinidumpContextPPC64Writer() override;
++
++  //! \brief Initalizes the MinidumpContextPPC64 based on \a context_snapshot.
++  //!
++  //! \param[in] context_snapshot The context snapshot to use as source data.
++  //!
++  //! \note Valid in #kStateMutable. No mutation of context() may be done before
++  //!     calling this method, and it is not normally necessary to alter
++  //!     context() after calling this method.
++  void InitalizeFromSnapshot(const CPUContextPPC64* context_snapshot);
++
++  //! \brief Returns a pointer to the context structure that this object will
++  //!     write.
++  //!
++  //! \attention This returns a non-`const` pointer to this object’s private
++  //!     data so that a caller can populate the context structure directly.
++  //!     This is done because providing setter interfaces to each field in the
++  //!     context structure would be unwieldy and cumbersome. Care must be taken
++  //!     to populate the context structure correctly. The context structure
++  //!     must only be modified while this object is in the #kStateMutable
++  //!     state.
++  MinidumpContextPPC64* context() { return &context_; }
++
++ protected:
++  // MinidumpWritable:
++  bool WriteObject(FileWriterInterface* file_writer) override;
++
++  // MinidumpContextWriter:
++  size_t ContextSize() const override;
++
++ private:
++  MinidumpContextPPC64 context_;
++
++  DISALLOW_COPY_AND_ASSIGN(MinidumpContextPPC64Writer);
++};
++
+ }  // namespace crashpad
+ 
+ #endif  // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_WRITER_H_
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc
+index 3216a906b..a9fcbe9d8 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc
+@@ -213,6 +213,21 @@ TEST(MinidumpContextWriter, MIPS64_FromSnapshot) {
+       context, ExpectMinidumpContextMIPS64, kSeed);
+ }
+ 
++TEST(MinidumpContextWriter, PPC64_Zeros) {
++  EmptyContextTest<MinidumpContextPPC64Writer, MinidumpContextPPC64>(
++    ExpectMinidumpContextPPC64);
++}
++
++TEST(MinidumpContextWriter, PPC64_FromSnapshot) {
++  constexpr uint32_t kSeed = 64;
++  CPUContextPPC64 context_ppc64;
++  CPUContext context;
++  context.ppc64 = &context_ppc64;
++  InitializeCPUContextPPC64(&context, kSeed);
++  FromSnapshotTest<MinidumpContextPPC64Writer, MinidumpContextPPC64>(
++      context, ExpectMinidumpContextPPC64, kSeed);
++}
++
+ }  // namespace
+ }  // namespace test
+ }  // namespace crashpad
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc
+index a13407605..95dc92524 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc
+@@ -126,6 +126,8 @@ std::string MinidumpMiscInfoDebugBuildString() {
+   static constexpr char kCPU[] = "mips";
+ #elif defined(ARCH_CPU_MIPS64EL)
+   static constexpr char kCPU[] = "mips64";
++#elif defined(ARCH_CPU_PPC64)
++  static constexpr char kCPU[] = "ppc64";
+ #else
+ #error define kCPU for this CPU
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc
+index a51626ccd..61e0b20a1 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc
+@@ -111,6 +111,11 @@ void CaptureMemory::PointedToByContext(const CPUContext& context,
+   for (size_t i = 0; i < base::size(context.mipsel->regs); ++i) {
+     MaybeCaptureMemoryAround(delegate, context.mipsel->regs[i]);
+   }
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  MaybeCaptureMemoryAround(delegate, context.ppc64->nip);
++  for (size_t i = 0; i < base::size(context.ppc64->regs); ++i) {
++    MaybeCaptureMemoryAround(delegate, context.ppc64->regs[i]);
++  }
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h
+index 811a72095..f4f83981d 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h
+@@ -43,7 +43,10 @@ enum CPUArchitecture {
+   kCPUArchitectureMIPSEL,
+ 
+   //! \brief 64-bit MIPSEL.
+-  kCPUArchitectureMIPS64EL
++  kCPUArchitectureMIPS64EL,
++
++  //! \brief 64-bit PPC64.
++  kCPUArchitecturePPC64
+ };
+ 
+ }  // namespace crashpad
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc
+index 6fb8d7e71..b01f7cad1 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc
+@@ -169,6 +169,8 @@ uint64_t CPUContext::InstructionPointer() const {
+       return arm->pc;
+     case kCPUArchitectureARM64:
+       return arm64->pc;
++    case kCPUArchitecturePPC64:
++      return ppc64->nip;
+     default:
+       NOTREACHED();
+       return ~0ull;
+@@ -185,6 +187,8 @@ uint64_t CPUContext::StackPointer() const {
+       return arm->sp;
+     case kCPUArchitectureARM64:
+       return arm64->sp;
++    case kCPUArchitecturePPC64:
++      return ppc64->regs[1];
+     default:
+       NOTREACHED();
+       return ~0ull;
+@@ -196,6 +200,7 @@ bool CPUContext::Is64Bit() const {
+     case kCPUArchitectureX86_64:
+     case kCPUArchitectureARM64:
+     case kCPUArchitectureMIPS64EL:
++    case kCPUArchitecturePPC64:
+       return true;
+     case kCPUArchitectureX86:
+     case kCPUArchitectureARM:
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h
+index fb23c4679..eebede63c 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h
+@@ -352,6 +352,24 @@ struct CPUContextMIPS64 {
+   uint64_t fir;
+ };
+ 
++//! \brief A context structure carrying PPC64 CPU state.
++struct CPUContextPPC64 {
++  uint64_t nip;
++  uint64_t msr;
++  uint64_t regs[32];
++  uint64_t ccr;
++  uint64_t xer;
++  uint64_t lnk;
++  uint64_t ctr;
++  double fpregs[32];
++  double fpscr;
++  struct {
++    uint128_struct save_vr[32];
++    uint128_struct save_vscr;
++    uint32_t save_vrsave;
++  } vregs;
++};
++
+ //! \brief A context structure capable of carrying the context of any supported
+ //!     CPU architecture.
+ struct CPUContext {
+@@ -382,6 +400,7 @@ struct CPUContext {
+     CPUContextARM64* arm64;
+     CPUContextMIPS* mipsel;
+     CPUContextMIPS64* mips64;
++    CPUContextPPC64* ppc64;
+   };
+ };
+ 
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h
+index 9f46a4897..aa677c4eb 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h
+@@ -15,6 +15,7 @@
+ #ifndef CRASHPAD_SNAPSHOT_LINUX_CPU_CONTEXT_LINUX_H_
+ #define CRASHPAD_SNAPSHOT_LINUX_CPU_CONTEXT_LINUX_H_
+ 
++#include <cstring>
+ #include "build/build_config.h"
+ #include "snapshot/cpu_context.h"
+ #include "snapshot/linux/signal_context.h"
+@@ -174,6 +175,78 @@ void InitializeCPUContextMIPS(
+ 
+ #endif  // ARCH_CPU_MIPS_FAMILY || DOXYGEN
+ 
++#if defined(ARCH_CPU_PPC64_FAMILY) || DOXYGEN
++
++//! \brief Initalizes a CPUContextPPC64 structure from native context
++//!     structures on Linux.
++//!
++//! \param[in] thread_context The native thread context.
++//! \param[in] float_context The native float context.
++//! \param[in] vector_context The native vector context.
++//! \param[out] context The CPUContextPPC64 structure to initalize.
++template <typename Traits>
++void InitializeCPUContextPPC64(
++    const ThreadContext::t64_t& thread_context,
++    const FloatContext::f64_t& float_context,
++    const VectorContext::v64_t& vector_context,
++    typename Traits::CPUContext* context) {
++
++  memcpy(context->regs, thread_context.gpr, sizeof(context->regs));
++  context->nip = thread_context.nip;
++  context->msr = thread_context.msr;
++  context->ccr = thread_context.ccr;
++  context->xer = thread_context.xer;
++  context->lnk = thread_context.lnk;
++  context->ctr = thread_context.ctr;
++
++  memcpy(context->fpregs, float_context.fpregs, sizeof(context->fpregs));
++  context->fpscr = float_context.fpscr;
++
++  for (uint8_t i = 0; i < 32; i++) {
++    context->vregs.save_vr[i] = {
++      (((uint64_t)vector_context.vrregs[i][0]) << 32) |
++        vector_context.vrregs[i][1],
++      (((uint64_t)vector_context.vrregs[i][2]) << 32) |
++        vector_context.vrregs[i][3]
++    };
++  }
++  context->vregs.save_vrsave = vector_context.vrsave;
++  context->vregs.save_vscr = {0, (uint64_t)vector_context.vscr.vscr_word};
++}
++
++template <typename Traits>
++void InitializeCPUContextPPC64(
++    const SignalThreadContext64 &thread_context,
++    const SignalFloatContext64 &float_context,
++    const SignalVectorContext64 &vector_context,
++    typename Traits::CPUContext* context) {
++
++  memcpy(context->regs, thread_context.regs, sizeof(context->regs));
++  context->nip = thread_context.nip;
++  context->msr = thread_context.msr;
++  context->ccr = thread_context.ccr;
++  context->xer = thread_context.xer;
++  context->lnk = thread_context.lnk;
++  context->ctr = thread_context.ctr;
++
++  memcpy(context->fpregs, float_context.regs, sizeof(context->fpregs));
++  context->fpscr = float_context.fpscr;
++
++  for (uint8_t i = 0; i < 32; i++) {
++    context->vregs.save_vr[i] = {
++      (((uint64_t)vector_context.vrregs[i][0]) << 32) |
++        vector_context.vrregs[i][1],
++      (((uint64_t)vector_context.vrregs[i][2]) << 32) |
++        vector_context.vrregs[i][3]
++    };
++  }
++  context->vregs.save_vrsave = vector_context.vrsave;
++  context->vregs.save_vscr = {0, (uint64_t)vector_context.vscr.vscr_word};
++}
++
++
++#endif
++
+ }  // namespace internal
+ }  // namespace crashpad
+ 
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc
+index be22c9031..c5df23d1b 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc
+@@ -159,9 +159,11 @@ void TestAgainstTarget(PtraceConnection* connection) {
+           const bool is_vdso_mapping =
+               device == 0 && inode == 0 && mapping_name == "[vdso]";
+           static constexpr char kPrefix[] = "linux-vdso.so.";
++          static constexpr char kPrefix64[] = "linux-vdso64.so.";
+           return is_vdso_mapping ==
+                  (module_name.empty() ||
+-                  module_name.compare(0, strlen(kPrefix), kPrefix) == 0);
++                  module_name.compare(0, strlen(kPrefix), kPrefix) == 0 ||
++                  module_name.compare(0, strlen(kPrefix64), kPrefix64) == 0);
+         },
+         module_mapping->name,
+         module_mapping->device,
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc
+index cd40b3b12..6bcf23b6f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc
+@@ -323,6 +323,69 @@ bool ExceptionSnapshotLinux::ReadContext<ContextTraits64>(
+       reader, context_address, context_.mips64);
+ }
+ 
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++
++template <typename Traits>
++static bool ReadContext(ProcessReaderLinux* reader,
++                        LinuxVMAddress context_address,
++                        typename Traits::CPUContext* dest_context) {
++  const ProcessMemory* memory = reader->Memory();
++
++  LinuxVMAddress gp_regs_address = context_address +
++                                   offsetof(UContext, mcontext) +
++                                   offsetof(typename Traits::MContext, gp_regs);
++
++  typename Traits::SignalThreadContext thread_context;
++  if (!memory->Read(gp_regs_address, sizeof(thread_context), &thread_context)) {
++    LOG(ERROR) << "Couldn't read gp_regs!";
++    return false;
++  }
++
++  LinuxVMAddress fp_regs_address = context_address +
++                                   offsetof(UContext, mcontext) +
++                                   offsetof(typename Traits::MContext, fp_regs);
++
++  typename Traits::SignalFloatContext fp_context;
++  if (!memory->Read(fp_regs_address, sizeof(fp_context), &fp_context)) {
++    LOG(ERROR) << "Couldn't read fp_regs!";
++    return false;
++  }
++
++  LinuxVMAddress v_regs_ptr_address = context_address +
++                                  offsetof(UContext, mcontext) +
++                                  offsetof(typename Traits::MContext, vmx_reserve) + 8;
++
++  typename Traits::SignalVectorContext v_context;
++  if (!memory->Read(v_regs_ptr_address, sizeof(v_context), &v_context)) {
++    LOG(ERROR) << "Couldn't read v_regs!";
++    return false;
++  }
++
++  InitializeCPUContextPPC64<ContextTraits64>(thread_context, fp_context,
++                            v_context, dest_context);
++
++  return true;
++}
++
++template<>
++bool ExceptionSnapshotLinux::ReadContext<ContextTraits64>(
++    ProcessReaderLinux* reader,
++    LinuxVMAddress context_address) {
++  context_.architecture = kCPUArchitecturePPC64;
++  context_.ppc64 = &context_union_.ppc64;
++
++  return internal::ReadContext<ContextTraits64>(
++      reader, context_address, context_.ppc64);
++}
++
++template<>
++bool ExceptionSnapshotLinux::ReadContext<ContextTraits32>(
++    ProcessReaderLinux* reader,
++    LinuxVMAddress context_address) {
++  // PPC64 is 64-bit
++  return false;
++}
++
+ #endif  // ARCH_CPU_X86_FAMILY
+ 
+ bool ExceptionSnapshotLinux::Initialize(ProcessReaderLinux* process_reader,
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h
+index ea0cd2106..e42df520f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h
+@@ -84,6 +84,8 @@ class ExceptionSnapshotLinux final : public ExceptionSnapshot {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+     CPUContextMIPS mipsel;
+     CPUContextMIPS64 mips64;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    CPUContextPPC64 ppc64;
+ #endif
+   } context_union_;
+   CPUContext context_;
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc
+index e4ff1ab79..25534dd08 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc
+@@ -296,7 +296,28 @@ void ExpectContext(const CPUContext& actual, const NativeCPUContext& expected) {
+             0);
+ #undef CPU_ARCH_NAME
+ }
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++using NativeCPUContext = ucontext_t;
++
++void InitializeContext(NativeCPUContext* context) {
++  for (size_t reg = 0; reg < 32; ++reg) {
++    context->uc_mcontext.gp_regs[reg] = reg;
++  }
++
++  memset(&context->uc_mcontext.fp_regs, 44,
++      sizeof(context->uc_mcontext.fp_regs));
++}
+ 
++void ExpectContext(const CPUContext& actual, const NativeCPUContext& expected) {
++  EXPECT_EQ(actual.architecture, kCPUArchitecturePPC64);
++
++  for (size_t reg = 0; reg < 32; ++reg) {
++    EXPECT_EQ(actual.ppc64->regs[reg], expected.uc_mcontext.gp_regs[reg]);
++  }
++
++  EXPECT_EQ(memcmp(actual.ppc64->fpregs, expected.uc_mcontext.fp_regs,
++            sizeof(actual.ppc64->fpregs)), 0);
++}
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc
+index b96abfe74..df12ca566 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc
+@@ -108,6 +108,8 @@ void ProcessReaderLinux::Thread::InitializeStack(ProcessReaderLinux* reader) {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   stack_pointer = reader->Is64Bit() ? thread_info.thread_context.t64.regs[29]
+                                     : thread_info.thread_context.t32.regs[29];
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  stack_pointer = thread_info.thread_context.t64.gpr[1];
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc
+index 5b5723616..049c32858 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc
+@@ -612,6 +612,8 @@ bool WriteTestModule(const base::FilePath& module_path) {
+   module.ehdr.e_machine = EM_AARCH64;
+ #elif defined(ARCH_CPU_MIPSEL) || defined(ARCH_CPU_MIPS64EL)
+   module.ehdr.e_machine = EM_MIPS;
++#elif defined(ARCH_CPU_PPC64)
++  module.ehdr.e_machine = EM_PPC64;
+ #endif
+ 
+   module.ehdr.e_version = EV_CURRENT;
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+index 110024680..a1f2da259 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+@@ -422,6 +422,89 @@ static_assert(offsetof(UContext<ContextTraits64>, mcontext.fpregs) ==
+               "context offset mismatch");
+ #endif
+ 
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++
++struct SignalThreadContext64 {
++  uint64_t regs[32];
++  uint64_t nip;
++  uint64_t msr;
++  uint64_t orig_r3;
++  uint64_t ctr;
++  uint64_t lnk;
++  uint64_t xer;
++  uint64_t ccr;
++  uint64_t softe;
++  uint64_t trap;
++  uint64_t dar;
++  uint64_t dsisr;
++  uint64_t result;
++  uint64_t dscr;
++  uint64_t fpr0[3];
++};
++
++struct SignalFloatContext64 {
++  double regs[32];
++  double fpscr;
++};
++
++struct SignalVectorContext64 {
++  int32_t vrregs[32][4];
++  struct {
++    int32_t __pad[3];
++    int32_t vscr_word;
++  } vscr;
++  int32_t vrsave;
++  int32_t __pad[3];
++} __attribute__((__aligned__(16)));
++
++
++#pragma pack(pop)
++struct MContext64 {
++  uint64_t reserved[4];
++  int32_t signal;
++  int32_t __pad0;
++  uint64_t handler;
++  uint64_t oldmask;
++  uint64_t pt_regs_ptr;
++  SignalThreadContext64 gp_regs;
++  SignalFloatContext64  fp_regs;
++  SignalVectorContext64 *v_regs;
++  int64_t vmx_reserve[69];
++};
++
++struct ContextTraits64 : public Traits64 {
++  using MContext = MContext64;
++  using SignalThreadContext = SignalThreadContext64;
++  using SignalFloatContext = SignalFloatContext64;
++  using SignalVectorContext = SignalVectorContext64;
++  using CPUContext = CPUContextPPC64;
++};
++
++struct ContextTraits32 : public Traits32 {};
++
++struct UContext {
++  uint64_t flags;
++  uint64_t link;
++  SignalStack<ContextTraits64> stack;
++  Sigset<ContextTraits64> sigmask;
++  MContext64 mcontext;
++};
++#pragma pack(push, 1)
++
++static_assert(sizeof(UContext) == sizeof(ucontext_t),
++              "ucontext_t size mismatch");
++static_assert(sizeof(MContext64) == sizeof(mcontext_t),
++              "mcontext_t size mismatch");
++static_assert(sizeof(SignalThreadContext64) == sizeof(gregset_t),
++              "gregset_t size mismatch");
++static_assert(sizeof(SignalFloatContext64) == sizeof(fpregset_t),
++              "fpregset_t size mismatch");
++static_assert(sizeof(SignalVectorContext64) == sizeof(vrregset_t),
++              "vrregset_t size mismatch");
++static_assert(offsetof(UContext, mcontext) ==
++              offsetof(ucontext_t, uc_mcontext), "mcontext offset mismatch");
++static_assert(offsetof(MContext64, gp_regs) ==
++              offsetof(mcontext_t, gp_regs), "gp_regs offset mismatch");
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc
+index 8564d3d45..b690ecd48 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc
+@@ -203,6 +203,8 @@ CPUArchitecture SystemSnapshotLinux::GetCPUArchitecture() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   return process_reader_->Is64Bit() ? kCPUArchitectureMIPS64EL
+                                     : kCPUArchitectureMIPSEL;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  return kCPUArchitecturePPC64;
+ #else
+ #error port to your architecture
+ #endif
+@@ -218,6 +220,9 @@ uint32_t SystemSnapshotLinux::CPURevision() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   // Not implementable on MIPS
+   return 0;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  // Not yet implemented on PPC64
++  return 0;
+ #else
+ #error port to your architecture
+ #endif
+@@ -238,6 +243,9 @@ std::string SystemSnapshotLinux::CPUVendor() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   // Not implementable on MIPS
+   return std::string();
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  // Not yet implemented on PPC64
++  return std::string();
+ #else
+ #error port to your architecture
+ #endif
+@@ -371,6 +379,9 @@ bool SystemSnapshotLinux::NXEnabled() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   // Not implementable on MIPS
+   return false;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  // Not yet implemented on PPC64
++  return false;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc
+index e3e2bebdd..8ef43752e 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc
+@@ -186,6 +186,14 @@ bool ThreadSnapshotLinux::Initialize(ProcessReaderLinux* process_reader,
+         thread.thread_info.float_context.f32,
+         context_.mipsel);
+   }
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  context_.architecture = kCPUArchitecturePPC64;
++  context_.ppc64 = &context_union_.ppc64;
++  InitializeCPUContextPPC64<ContextTraits64>(
++      thread.thread_info.thread_context.t64,
++      thread.thread_info.float_context.f64,
++      thread.thread_info.vector_context.v64,
++      context_.ppc64);
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h
+index 44cc6f6d9..d4136461e 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h
+@@ -68,6 +68,8 @@ class ThreadSnapshotLinux final : public ThreadSnapshot {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+     CPUContextMIPS mipsel;
+     CPUContextMIPS64 mips64;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    CPUContextPPC64 ppc64;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc
+index d3d5ebdfb..3fd730cb5 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc
+@@ -56,6 +56,11 @@ bool AuxiliaryVector::Read(PtraceConnection* connection) {
+     if (type == AT_IGNORE) {
+       continue;
+     }
++#if defined(ARCH_CPU_PPC64_FAMILY)
++    if (type == AT_IGNOREPPC) {
++      continue;
++    }
++#endif
+     if (!MapInsertOrReplace(&values_, type, value, nullptr)) {
+       LOG(ERROR) << "duplicate auxv entry";
+       return false;
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc
+index 155a1e0c6..5e50ceb5f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc
+@@ -94,8 +94,8 @@ int PtraceBroker::Run() {
+ }
+ 
+ bool PtraceBroker::AllocateAttachments() {
+-  constexpr size_t page_size = 4096;
+-  constexpr size_t alloc_size =
++  static size_t page_size = getpagesize();
++  size_t alloc_size =
+       (sizeof(ScopedPtraceAttach) + page_size - 1) & ~(page_size - 1);
+   void* alloc = sbrk(alloc_size);
+   if (reinterpret_cast<intptr_t>(alloc) == -1) {
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc
+index 557e0d363..08ae434b8 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc
+@@ -398,6 +398,64 @@ bool GetThreadArea64(pid_t tid,
+   return true;
+ }
+ 
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++// PPC64 has had HAVE_ARCH_TRACEHOOK set since 2.6.27 (even before x86 had it).
++// That means we can simply use PTRACE_GETREGESET.
++
++template <typename Destination>
++bool GetRegisterSet(pid_t tid, int set, Destination* dest, bool can_log) {
++  iovec iov;
++  iov.iov_base = reinterpret_cast<void*>(dest);
++  iov.iov_len = sizeof(*dest);
++  if (ptrace(PTRACE_GETREGSET, tid, reinterpret_cast<void*>(set), &iov) != 0) {
++    PLOG_IF(ERROR, can_log) << "ptrace";
++    return false;
++  }
++  if (iov.iov_len != sizeof(*dest)) {
++    LOG_IF(ERROR, can_log) << "Unexpected registers size";
++    return false;
++  }
++  return true;
++}
++
++bool GetVectorRegisters64(pid_t tid,
++                          VectorContext* context,
++                          bool can_log) {
++  return GetRegisterSet(tid, NT_PPC_VMX, &context->v64, can_log);
++}
++
++bool GetFloatingPointRegisters64(pid_t tid,
++                                 FloatContext* context,
++                                 bool can_log) {
++  return GetRegisterSet(tid, NT_PRFPREG, &context->f64, can_log);
++}
++
++bool GetThreadArea64(pid_t tid,
++                     const ThreadContext& context,
++                     LinuxVMAddress* address,
++                     bool can_log) {
++  // PPC64 doesn't have PTRACE_GET_THREAD_AREA since the thread pointer
++  // is stored in GPR 13.
++  ThreadContext::t64_t tc;
++  if (!GetRegisterSet(tid, NT_PRSTATUS, &tc, can_log)) {
++    LOG_IF(ERROR, can_log) << "Unable to get thread pointer!";
++    return false;
++  }
++
++  *address = tc.gpr[13];
++
++  return true;
++}
++
++// Stubs for 32-bit functions not applicable on PPC64
++bool GetFloatingPointRegisters32(pid_t tid,
++                                 FloatContext* context,
++                                 bool can_log) { return false; }
++bool GetThreadArea32(pid_t tid,
++                     const ThreadContext &context,
++                     LinuxVMAddress *address,
++                     bool can_log) { return false; }
++
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -494,6 +552,9 @@ bool Ptracer::GetThreadInfo(pid_t tid, ThreadInfo* info) {
+   if (is_64_bit_) {
+     return GetGeneralPurposeRegisters64(tid, &info->thread_context, can_log_) &&
+            GetFloatingPointRegisters64(tid, &info->float_context, can_log_) &&
++#if defined(ARCH_CPU_PPC64_FAMILY)
++           GetVectorRegisters64(tid, &info->vector_context, can_log_) &&
++#endif
+            GetThreadArea64(tid,
+                            info->thread_context,
+                            &info->thread_specific_data_address,
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+index 5b55c24a7..dea0d1f39 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -28,6 +28,10 @@
+ #include <android/api-level.h>
+ #endif
+ 
++#if defined(ARCH_CPU_PPC64_FAMILY)
++#include <sys/ucontext.h>
++#endif
++
+ namespace crashpad {
+ 
+ //! \brief The set of general purpose registers for an architecture family.
+@@ -79,6 +83,8 @@ union ThreadContext {
+     uint32_t cp0_status;
+     uint32_t cp0_cause;
+     uint32_t padding1_;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // PPC64 is 64-bit
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -132,6 +138,21 @@ union ThreadContext {
+     uint64_t cp0_badvaddr;
+     uint64_t cp0_status;
+     uint64_t cp0_cause;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // Reflects struct pt_regs in asm/ptrace.h.
++    uint64_t gpr[32];
++    uint64_t nip;
++    uint64_t msr;
++    uint64_t orig_gpr3;
++    uint64_t ctr;
++    uint64_t lnk;
++    uint64_t xer;
++    uint64_t ccr;
++    uint64_t softe;
++    uint64_t trap;
++    uint64_t dar;
++    uint64_t dsisr;
++    uint64_t result;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -143,6 +164,8 @@ union ThreadContext {
+   using NativeThreadContext = user_regs;
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+ // No appropriate NativeThreadsContext type available for MIPS
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  using NativeThreadContext = struct pt_regs;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY || ARCH_CPU_ARM64
+@@ -218,6 +241,9 @@ union FloatContext {
+     } fpregs[32];
+     uint32_t fpcsr;
+     uint32_t fpu_id;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // Crashpad's PPC support is 64-bit only, so this
++    // 32bit-only struct is declared as empty.
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -252,6 +278,10 @@ union FloatContext {
+     double fpregs[32];
+     uint32_t fpcsr;
+     uint32_t fpu_id;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // Reflects fpregset_t in sys/ucontext.h
++    double fpregs[32];
++    double fpscr;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -280,6 +310,8 @@ union FloatContext {
+   static_assert(sizeof(f64) == sizeof(user_fpsimd_struct), "Size mismatch");
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+ // No appropriate floating point context native type for available MIPS.
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  static_assert(sizeof(f64) == sizeof(fpregset_t), "Size mismatch");
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86
+@@ -287,6 +319,26 @@ union FloatContext {
+ static_assert(std::is_standard_layout<FloatContext>::value,
+               "Not standard layout");
+ 
++//! \brief The vector registers used for an architecture family
++union VectorContext {
++  struct v32_t {} v32;
++#if defined(ARCH_CPU_PPC64_FAMILY)
++  __attribute__((__aligned__(16))) // Vector context must be doubleword aligned.
++#endif
++  struct v64_t {
++#if defined(ARCH_CPU_PPC64_FAMILY)
++    // Reflects vrregset_t in sys/ucontext.h
++    uint32_t vrregs[32][4];
++    struct {
++      uint32_t __pad[3];
++      uint32_t vscr_word;
++    } vscr;
++    uint32_t vrsave;
++    uint32_t __pad[3];
++#endif
++  } v64;
++};
++
+ //! \brief A collection of `ptrace`-able information about a thread.
+ struct ThreadInfo {
+   ThreadInfo();
+@@ -298,6 +350,9 @@ struct ThreadInfo {
+   //! \brief The floating point registers for the thread.
+   FloatContext float_context;
+ 
++  //! \brief (Optional) The vector registers used for the thread.
++  VectorContext vector_context;
++
+   //! \brief The thread-local storage address for the thread.
+   LinuxVMAddress thread_specific_data_address;
+ };
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h
+index a88a10336..b0d6578bd 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h
+@@ -70,6 +70,7 @@ using NativeCPUContext = ucontext_t;
+ //!     macOS/Linux/Fuchsia | x86_64       | `%%rdi`
+ //!     Linux               | ARM/ARM64    | `r0`/`x0`
+ //!     Linux               | MIPS/MIPS64  | `$a0`
++//!     Linux               | PPC64        | `r3`
+ //!
+ //!     Additionally, the value `LR` on ARM/ARM64 will be the return address of
+ //!     this function.
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S
+index 52215ee5d..b3e4a3ec7 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S
+@@ -32,7 +32,7 @@
+   .balign 4, 0x0
+   .type CAPTURECONTEXT_SYMBOL, %function
+   .type CAPTURECONTEXT_SYMBOL2, %function
+-#elif defined(__mips__)
++#elif defined(__mips__) || defined(__powerpc64__)
+   .balign 4, 0x0
+ #endif
+ 
+@@ -423,4 +423,214 @@ CAPTURECONTEXT_SYMBOL2:
+   jr $ra
+ 
+   .set at
++#elif defined(__powerpc64__)
++  // Store r0-r31
++  std 0, 0xe8(3)   // context->uc_mcontext.gp_regs[0]
++  std 1, 0xf0(3)   // context->uc_mcontext.gp_regs[1]
++  std 2, 0xf8(3)   // context->uc_mcontext.gp_regs[2]
++  // note that r3's original value was lost
++  std 3, 0x100(3)  // context->uc_mcontext.gp_regs[3]
++  std 4, 0x108(3)  // context->uc_mcontext.gp_regs[4]
++  std 5, 0x110(3)  // context->uc_mcontext.gp_regs[5]
++  std 6, 0x118(3)  // context->uc_mcontext.gp_regs[6]
++  std 7, 0x120(3)  // context->uc_mcontext.gp_regs[7]
++  std 8, 0x128(3)  // context->uc_mcontext.gp_regs[8]
++  std 9, 0x130(3)  // context->uc_mcontext.gp_regs[9]
++  std 10, 0x138(3) // context->uc_mcontext.gp_regs[10]
++  std 11, 0x140(3) // context->uc_mcontext.gp_regs[11]
++  std 12, 0x148(3) // context->uc_mcontext.gp_regs[12]
++  std 13, 0x150(3) // context->uc_mcontext.gp_regs[13]
++  std 14, 0x158(3) // context->uc_mcontext.gp_regs[14]
++  std 15, 0x160(3) // context->uc_mcontext.gp_regs[15]
++  std 16, 0x168(3) // context->uc_mcontext.gp_regs[16]
++  std 17, 0x170(3) // context->uc_mcontext.gp_regs[17]
++  std 18, 0x178(3) // context->uc_mcontext.gp_regs[18]
++  std 19, 0x180(3) // context->uc_mcontext.gp_regs[19]
++  std 20, 0x188(3) // context->uc_mcontext.gp_regs[20]
++  std 21, 0x190(3) // context->uc_mcontext.gp_regs[21]
++  std 22, 0x198(3) // context->uc_mcontext.gp_regs[22]
++  std 23, 0x1a0(3) // context->uc_mcontext.gp_regs[23]
++  std 24, 0x1a8(3) // context->uc_mcontext.gp_regs[24]
++  std 25, 0x1b0(3) // context->uc_mcontext.gp_regs[25]
++  std 26, 0x1b8(3) // context->uc_mcontext.gp_regs[26]
++  std 27, 0x1c0(3) // context->uc_mcontext.gp_regs[27]
++  std 28, 0x1c8(3) // context->uc_mcontext.gp_regs[28]
++  std 29, 0x1d0(3) // context->uc_mcontext.gp_regs[29]
++  std 30, 0x1d8(3) // context->uc_mcontext.gp_regs[30]
++  std 31, 0x1e0(3) // context->uc_mcontext.gp_regs[31]
++
++  // For NIP, we can use the value in the link register
++  mflr 0
++  std 0, 0x1e8(3) // context->uc_mcontext.gp_regs[PT_NIP]
++
++  // CTR
++  mfctr 0
++  std 0, 0x200(3) // context->uc_mcontext.gp_regs[PT_CTR]
++
++  // For LNK, we'll use the caller's LR save area (2 stack frames up).
++  // r4 can be used as a scratch register since it has already been saved.
++  ld 4, 0(1)
++  ld 4, 16(4)
++  std 4, 0x208(3) // context->uc_mcontext.gp_regs[PT_LNK]
++
++  // XER
++  mfxer 0
++  std 0, 0x210(3) // context->uc_mcontext.gp_regs[PT_XER]
++
++  // CCR
++  mfcr 0
++  std 0, 0x218(3) // context->uc_mcontext.gp_regs[PT_CCR]
++
++  // MSR, orig_r3, MQ, TRAP, DAR, DSISR, RESULT, DSCR,
++  // not used or not relevant,  zero them out.
++  li 4, 0
++  std 4, 0x1f0(3) // context->uc_mcontext.gp_regs[PT_MSR]
++  std 4, 0x1f8(3) // context->uc_mcontext.gp_regs[PT_ORIG_R3]
++  std 4, 0x220(3) // context->uc_mcontext.gp_regs[PT_MQ]
++  std 4, 0x228(3) // context->uc_mcontext.gp_regs[PT_TRAP]
++  std 4, 0x230(3) // context->uc_mcontext.gp_regs[PT_DAR]
++  std 4, 0x238(3) // context->uc_mcontext.gp_regs[PT_DSISR]
++  std 4, 0x240(3) // context->uc_mcontext.gp_regs[PT_RESULT]
++  std 4, 0x248(3) // context->uc_mcontext.gp_regs[PT_DSCR]
++
++  // Update context->uc_mcontext.regs to point to gp_regs
++  addi 0, 3, 0xe8
++  std 0, 0xe0(3)
++
++  // Save floating point registers 0-31
++  stfd 0, 0x268(3)  // context->uc_mcontext.fp_regs[0]
++  stfd 1, 0x270(3)  // context->uc_mcontext.fp_regs[1]
++  stfd 2, 0x278(3)  // context->uc_mcontext.fp_regs[2]
++  stfd 3, 0x280(3)  // context->uc_mcontext.fp_regs[3]
++  stfd 4, 0x288(3)  // context->uc_mcontext.fp_regs[4]
++  stfd 5, 0x290(3)  // context->uc_mcontext.fp_regs[5]
++  stfd 6, 0x298(3)  // context->uc_mcontext.fp_regs[6]
++  stfd 7, 0x2a0(3)  // context->uc_mcontext.fp_regs[7]
++  stfd 8, 0x2a8(3)  // context->uc_mcontext.fp_regs[8]
++  stfd 9, 0x2b0(3)  // context->uc_mcontext.fp_regs[9]
++  stfd 10, 0x2b8(3) // context->uc_mcontext.fp_regs[10]
++  stfd 11, 0x2c0(3) // context->uc_mcontext.fp_regs[11]
++  stfd 12, 0x2c8(3) // context->uc_mcontext.fp_regs[12]
++  stfd 13, 0x2d0(3) // context->uc_mcontext.fp_regs[13]
++  stfd 14, 0x2d8(3) // context->uc_mcontext.fp_regs[14]
++  stfd 15, 0x2e0(3) // context->uc_mcontext.fp_regs[15]
++  stfd 16, 0x2e8(3) // context->uc_mcontext.fp_regs[16]
++  stfd 17, 0x2f0(3) // context->uc_mcontext.fp_regs[17]
++  stfd 18, 0x2f8(3) // context->uc_mcontext.fp_regs[18]
++  stfd 19, 0x300(3) // context->uc_mcontext.fp_regs[19]
++  stfd 20, 0x308(3) // context->uc_mcontext.fp_regs[20]
++  stfd 21, 0x310(3) // context->uc_mcontext.fp_regs[21]
++  stfd 22, 0x318(3) // context->uc_mcontext.fp_regs[22]
++  stfd 23, 0x320(3) // context->uc_mcontext.fp_regs[23]
++  stfd 24, 0x328(3) // context->uc_mcontext.fp_regs[24]
++  stfd 25, 0x330(3) // context->uc_mcontext.fp_regs[25]
++  stfd 26, 0x338(3) // context->uc_mcontext.fp_regs[26]
++  stfd 27, 0x340(3) // context->uc_mcontext.fp_regs[27]
++  stfd 28, 0x348(3) // context->uc_mcontext.fp_regs[28]
++  stfd 29, 0x350(3) // context->uc_mcontext.fp_regs[29]
++  stfd 30, 0x358(3) // context->uc_mcontext.fp_regs[30]
++  stfd 31, 0x360(3) // context->uc_mcontext.fp_regs[31]
++
++  // FPSCR
++  mffs 0
++  stfd 0, 0x368(3) // context->uc_mcontext.fp_regs[32]
++
++  // Save VMX Vector registers
++  // Update r4 to contain the base address of vmx_reserve
++  addi 4, 3, 0x378
++  // Ensure that it is quadword aligned
++  andi. 5, 4, 0xF
++  beq 1f // No alignment is necessary
++  // Address is doubleword aligned and not quadword aligned, add 8
++  addi 4, 4, 8
++
++1:
++  // Store VMX registers 0-31
++  // r4 will contain the base address
++  // r5 will contain the index
++  li 5, 0
++  stvx 0, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 0]
++  addi 5, 5, 16
++  stvx 1, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 1]
++  addi 5, 5, 16
++  stvx 2, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 2]
++  addi 5, 5, 16
++  stvx 3, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 3]
++  addi 5, 5, 16
++  stvx 4, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 4]
++  addi 5, 5, 16
++  stvx 5, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 5]
++  addi 5, 5, 16
++  stvx 6, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 6]
++  addi 5, 5, 16
++  stvx 7, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 7]
++  addi 5, 5, 16
++  stvx 8, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 8]
++  addi 5, 5, 16
++  stvx 9, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 9]
++  addi 5, 5, 16
++  stvx 10, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 10]
++  addi 5, 5, 16
++  stvx 11, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 11]
++  addi 5, 5, 16
++  stvx 12, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 12]
++  addi 5, 5, 16
++  stvx 13, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 13]
++  addi 5, 5, 16
++  stvx 14, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 14]
++  addi 5, 5, 16
++  stvx 15, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 15]
++  addi 5, 5, 16
++  stvx 16, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 16]
++  addi 5, 5, 16
++  stvx 17, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 17]
++  addi 5, 5, 16
++  stvx 18, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 18]
++  addi 5, 5, 16
++  stvx 19, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 19]
++  addi 5, 5, 16
++  stvx 20, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 20]
++  addi 5, 5, 16
++  stvx 21, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 21]
++  addi 5, 5, 16
++  stvx 22, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 22]
++  addi 5, 5, 16
++  stvx 23, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 23]
++  addi 5, 5, 16
++  stvx 24, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 24]
++  addi 5, 5, 16
++  stvx 25, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 25]
++  addi 5, 5, 16
++  stvx 26, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 26]
++  addi 5, 5, 16
++  stvx 27, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 27]
++  addi 5, 5, 16
++  stvx 28, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 28]
++  addi 5, 5, 16
++  stvx 29, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 29]
++  addi 5, 5, 16
++  stvx 30, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 30]
++  addi 5, 5, 16
++  stvx 31, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 31]
++  addi 5, 5, 16
++
++  // VSCR
++  mfvscr 0
++  stvx 0, 4, 5
++  addi 5, 5, 16
++
++  // VRSAVE
++  mfvrsave 0
++  stwx 0, 4, 5
++
++  // Update context->uc_mcontext.v_regs to point to vmx_reserve + alignment.
++  std 4, 0x370(3)
++
++  // Zero out all unused fields
++  li 4, 0
++  std 4, 0xc8(3) // context->uc_mcontext.signal
++  std 4, 0xd0(3) // context->uc_mcontext.handler
++  std 4, 0xd8(3) // context->uc_mcontext.oldmask
++
++  blr
+ #endif  // __i386__
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc
+index cf23c2def..5f264bc92 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc
+@@ -57,7 +57,7 @@ void TestCaptureContext() {
+   uintptr_t pc = ProgramCounterFromContext(context_1);
+ 
+ #if !defined(ADDRESS_SANITIZER) && !defined(ARCH_CPU_MIPS_FAMILY) && \
+-    !defined(MEMORY_SANITIZER)
++    !defined(MEMORY_SANITIZER) && !defined(ARCH_CPU_PPC64_FAMILY)
+   // Sanitizers can cause enough code bloat that the “nearby” check would
+   // likely fail.
+   const uintptr_t kReferencePC =
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc
+index 9fc5db28c..5f69f8dce 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc
+@@ -36,6 +36,8 @@ void SanityCheckContext(const NativeCPUContext& context) {
+   EXPECT_EQ(context.uc_mcontext.regs[0], FromPointerCast<uintptr_t>(&context));
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   EXPECT_EQ(context.uc_mcontext.gregs[4], FromPointerCast<uintptr_t>(&context));
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  EXPECT_EQ(context.uc_mcontext.gp_regs[3], FromPointerCast<uintptr_t>(&context));
+ #endif
+ }
+ 
+@@ -50,6 +52,8 @@ uintptr_t ProgramCounterFromContext(const NativeCPUContext& context) {
+   return context.uc_mcontext.pc;
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   return context.uc_mcontext.pc;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  return context.uc_mcontext.gp_regs[PT_NIP];
+ #endif
+ }
+ 
+@@ -64,6 +68,8 @@ uintptr_t StackPointerFromContext(const NativeCPUContext& context) {
+   return context.uc_mcontext.sp;
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   return context.uc_mcontext.gregs[29];
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  return context.uc_mcontext.gp_regs[1];
+ #endif
+ }
+ 
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc
+index 58bfa8f83..8fc37c464 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc
+@@ -46,12 +46,12 @@ bool CanCauseSignal(int sig) {
+   return sig == SIGABRT ||
+          sig == SIGALRM ||
+          sig == SIGBUS ||
+-#if !defined(ARCH_CPU_ARM64)
++#if !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+          sig == SIGFPE ||
+-#endif  // !defined(ARCH_CPU_ARM64)
++#endif  // !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARMEL)
+          sig == SIGILL ||
+ #endif  // defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARMEL)
+          sig == SIGPIPE ||
+          sig == SIGSEGV ||
+ #if defined(OS_MACOSX)
+@@ -117,9 +117,11 @@ void CauseSignal(int sig) {
+       break;
+     }
+ 
+-#if !defined(ARCH_CPU_ARM64)
++#if !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+     // ARM64 has hardware integer division instructions that don’t generate a
+     // trap for divide-by-zero, so this doesn’t produce SIGFPE.
++    //
++    // PPC64 fixed-point division by zero also doesn't produce a SIGFPE.
+     case SIGFPE: {
+       // Optimization makes this tricky, so get zero from a system call likely
+       // to succeed, and try to do something with the result.
+@@ -137,7 +139,7 @@ void CauseSignal(int sig) {
+       fstat(quotient, &stat_buf);
+       break;
+     }
+-#endif  // ARCH_CPU_ARM64
++#endif  // !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+ 
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARMEL)
+     case SIGILL: {
+diff --git a/src/3rdparty/chromium/third_party/dav1d/BUILD.gn b/src/3rdparty/chromium/third_party/dav1d/BUILD.gn
+index 788dc6cff..5fd7e8fda 100644
+--- a/src/3rdparty/chromium/third_party/dav1d/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/dav1d/BUILD.gn
+@@ -182,6 +182,8 @@ static_library("dav1d_8bit") {
+     sources += arm_template_sources
+   } else if (current_cpu == "arm64") {
+     sources += arm_template_sources
++  } else if (current_cpu == "ppc64") {
++    sources += ppc64_template_sources
+   }
+ 
+   cflags = dav1d_copts
+@@ -210,6 +212,8 @@ static_library("dav1d_10bit") {
+     sources += arm_template_sources
+   } else if (current_cpu == "arm64") {
+     sources += arm_template_sources
++  } else if (current_cpu == "ppc64") {
++    sources += ppc64_template_sources
+   }
+ 
+   cflags = dav1d_copts
+@@ -256,6 +260,21 @@ if (current_cpu == "x86" || current_cpu == "x64") {
+       ":dav1d_config",
+     ]
+ 
++    cflags = dav1d_copts
++  }
++} else if (current_cpu == "ppc64") {
++  static_library("dav1d_ppc") {
++    sources = [
++      "libdav1d/src/ppc/cpu.c",
++      "libdav1d/src/ppc/cpu.h",
++    ]
++
++    configs -= [ "//build/config/compiler:chromium_code" ]
++    configs += [
++      "//build/config/compiler:no_chromium_code",
++      ":dav1d_config",
++    ]
++
+     cflags = dav1d_copts
+   }
+ }
+@@ -285,5 +304,7 @@ static_library("dav1d") {
+     }
+   } else if (current_cpu == "arm" || current_cpu == "arm64") {
+     deps += [ ":dav1d_arm" ]
++  } else if (current_cpu == "ppc64") {
++    deps += [ ":dav1d_ppc" ]
+   }
+ }
+diff --git a/src/3rdparty/chromium/third_party/dav1d/config/linux/ppc64/config.h b/src/3rdparty/chromium/third_party/dav1d/config/linux/ppc64/config.h
+new file mode 100644
+index 000000000..9fbbf75cc
+--- /dev/null
++++ b/src/3rdparty/chromium/third_party/dav1d/config/linux/ppc64/config.h
+@@ -0,0 +1,39 @@
++/*
++ * Autogenerated by the Meson build system.
++ * Do not edit, your changes will be lost.
++ */
++
++#pragma once
++
++#define ARCH_AARCH64 0
++
++#define ARCH_ARM 0
++
++#define ARCH_PPC64LE 1
++
++#define ARCH_X86 0
++
++#define ARCH_X86_32 0
++
++#define ARCH_X86_64 0
++
++#define CONFIG_16BPC 1
++
++#define CONFIG_8BPC 1
++
++// #define CONFIG_LOG 1 -- Logging is controlled by Chromium
++
++#define ENDIANNESS_BIG 0
++
++#define HAVE_ASM 1
++
++#define HAVE_CLOCK_GETTIME 1
++
++#define HAVE_DLSYM 1
++
++#define HAVE_GETAUXVAL 1
++
++#define HAVE_POSIX_MEMALIGN 1
++
++#define HAVE_UNISTD_H 1
++
+diff --git a/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni b/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni
+index 458935cd8..f0cbc4aed 100644
+--- a/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni
++++ b/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni
+@@ -70,6 +70,11 @@ arm_template_sources = [
+   "libdav1d/src/arm/mc_init_tmpl.c",
+ ]
+ 
++ppc64_template_sources = [
++  "libdav1d/src/ppc/cdef_init_tmpl.c",
++  "libdav1d/src/ppc/looprestoration_init_tmpl.c",
++]
++
+ template_sources = [
+   "libdav1d/src/cdef_apply_tmpl.c",
+   "libdav1d/src/cdef_tmpl.c",
+diff --git a/src/3rdparty/chromium/third_party/dav1d/generate_source.py b/src/3rdparty/chromium/third_party/dav1d/generate_source.py
+index 9ab5e00b8..ad3feffee 100755
+--- a/src/3rdparty/chromium/third_party/dav1d/generate_source.py
++++ b/src/3rdparty/chromium/third_party/dav1d/generate_source.py
+@@ -50,7 +50,8 @@ def WriteGn(fd):
+   WriteArray(fd, "arm32_asm_sources", glob.glob("libdav1d/src/arm/32/*.S"))
+   WriteArray(fd, "arm64_asm_sources", glob.glob("libdav1d/src/arm/64/*.S"))
+   WriteArray(fd, "arm_template_sources", glob.glob("libdav1d/src/arm/*_tmpl.c"))
+-
++  WriteArray(fd, "ppc64_template_sources", glob.glob("libdav1d/src/ppc/*_tmpl.c"))
++ 
+   template_sources = glob.glob("libdav1d/src/*_tmpl.c")
+   WriteArray(fd, "template_sources", template_sources)
+ 
+diff --git a/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h b/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h
+index 0b4bd72f0..a0caa5e71 100644
+--- a/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h
++++ b/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h
+@@ -51,4 +51,19 @@
+ #define u16l_to_i32(v) ((i32x4) vec_mergel((u16x8) v, vec_splat_u16(0)))
+ #define i16l_to_i32(v) ((i32x4) vec_unpackl((i16x8)v))
+ 
++#if defined(__clang__)
++#undef vec_splats
++#define vec_splats(N)                     \
++    _Generic((N),                         \
++        unsigned char:      ((u8x16)(N)), \
++        signed char:        ((i8x16)(N)), \
++        unsigned short:     ((u16x8)(N)), \
++        signed short:       ((i16x8)(N)), \
++        unsigned int:       ((u32x4)(N)), \
++        signed int:         ((i32x4)(N)), \
++        unsigned long long: ((u64x2)(N)), \
++        signed long long:   ((i64x2)(N))  \
++    )
++#endif
++
+ #endif /* DAV1D_SRC_PPC_TYPES_H */
+diff --git a/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c b/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c
+index b7d586591..cead05021 100644
+--- a/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c
++++ b/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c
+@@ -51,10 +51,10 @@
+ #include <sys/ioctl.h>
+ #include <sys/time.h>
+ #include <stdarg.h>
+-#ifdef MAJOR_IN_MKDEV
++#if __has_include(<sys/mkdev.h>)
+ #include <sys/mkdev.h>
+ #endif
+-#ifdef MAJOR_IN_SYSMACROS
++#if __has_include(<sys/sysmacros.h>)
+ #include <sys/sysmacros.h>
+ #endif
+ #include <math.h>
+diff --git a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+index 597d8b6e5..99d1ec0c7 100644
+--- a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
++++ b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+@@ -3931,7 +3931,7 @@ struct kernel_statfs {
+       LSS_REG(2, buf);
+       LSS_BODY(void*, mmap2, "0"(__r2));
+     }
+-#else
++#elif !defined(__powerpc64__) /* ppc64 doesn't have mmap2 */
+     #define __NR__mmap2 __NR_mmap2
+     LSS_INLINE _syscall6(void*, _mmap2,            void*, s,
+                          size_t,                   l, int,               p,
+@@ -4042,7 +4042,7 @@ struct kernel_statfs {
+   #if defined(__i386__) ||                                                    \
+       defined(__ARM_ARCH_3__) || defined(__ARM_EABI__) ||                     \
+      (defined(__mips__) && _MIPS_SIM == _MIPS_SIM_ABI32) ||                   \
+-      defined(__PPC__) ||                                                     \
++     (defined(__PPC__) && !defined(__powerpc64__)) ||                                                     \
+      (defined(__s390__) && !defined(__s390x__))
+     /* On these architectures, implement mmap() with mmap2(). */
+     LSS_INLINE void* LSS_NAME(mmap)(void *s, size_t l, int p, int f, int d,
+diff --git a/src/3rdparty/chromium/third_party/pffft/src/pffft.c b/src/3rdparty/chromium/third_party/pffft/src/pffft.c
+index bdac4d784..51e0f2cac 100644
+--- a/src/3rdparty/chromium/third_party/pffft/src/pffft.c
++++ b/src/3rdparty/chromium/third_party/pffft/src/pffft.c
+@@ -100,6 +100,7 @@
+    Altivec support macros 
+ */
+ #if !defined(PFFFT_SIMD_DISABLE) && (defined(__ppc__) || defined(__ppc64__))
++#include <altivec.h>
+ typedef vector float v4sf;
+ #  define SIMD_SZ 4
+ #  define VZERO() ((vector float) vec_splat_u8(0))
+diff --git a/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp b/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp
+index 88eb1c7d3..4be33fa5b 100644
+--- a/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp
++++ b/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp
+@@ -240,7 +240,12 @@ String to_string(double value) {
+     if (needsDotZero) {
+         buffer << ".0";
+     }
+-    return String(buffer.str().c_str());
++
++    std::string ret(buffer.str());
++    if (signbit(value) && ret[0] == '.') {
++        ret[0] = '-';
++    }
++    return String(ret.c_str());
+ }
+ 
+ SKSL_INT stoi(const String& s) {
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c
+index 1b2c2ec7a..baa2b2a5d 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c
++++ b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c
+@@ -14400,7 +14400,8 @@ typedef INT16_TYPE LogEst;
+ # if defined(i386)      || defined(__i386__)      || defined(_M_IX86) ||    \
+      defined(__x86_64)  || defined(__x86_64__)    || defined(_M_X64)  ||    \
+      defined(_M_AMD64)  || defined(_M_ARM)        || defined(__x86)   ||    \
+-     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
++     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) ||   \
++     defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #   define SQLITE_BYTEORDER    1234
+ # elif defined(sparc)     || defined(__ppc__) || \
+        defined(__ARMEB__) || defined(__AARCH64EB__)
+@@ -187118,7 +187119,7 @@ struct RtreeMatchArg {
+ #if defined(i386)     || defined(__i386__)   || defined(_M_IX86) ||    \
+     defined(__x86_64) || defined(__x86_64__) || defined(_M_X64)  ||    \
+     defined(_M_AMD64) || defined(_M_ARM)     || defined(__x86)   ||    \
+-    defined(__arm__)
++    defined(__arm__) || defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ # define SQLITE_BYTEORDER    1234
+ #elif defined(sparc)    || defined(__ppc__)
+ # define SQLITE_BYTEORDER    4321
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c
+index 734ac355d..43fabe805 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c
++++ b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c
+@@ -14314,7 +14314,8 @@ typedef INT16_TYPE LogEst;
+ # if defined(i386)      || defined(__i386__)      || defined(_M_IX86) ||    \
+      defined(__x86_64)  || defined(__x86_64__)    || defined(_M_X64)  ||    \
+      defined(_M_AMD64)  || defined(_M_ARM)        || defined(__x86)   ||    \
+-     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
++     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) ||   \
++     defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #   define SQLITE_BYTEORDER    1234
+ # elif defined(sparc)     || defined(__ppc__) || \
+        defined(__ARMEB__) || defined(__AARCH64EB__)
+@@ -186514,7 +186515,7 @@ struct RtreeMatchArg {
+ #if defined(i386)     || defined(__i386__)   || defined(_M_IX86) ||    \
+     defined(__x86_64) || defined(__x86_64__) || defined(_M_X64)  ||    \
+     defined(_M_AMD64) || defined(_M_ARM)     || defined(__x86)   ||    \
+-    defined(__arm__)
++    defined(__arm__) || defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ # define SQLITE_BYTEORDER    1234
+ #elif defined(sparc)    || defined(__ppc__)
+ # define SQLITE_BYTEORDER    4321
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c b/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c
+index 1eef1a1b5..b53097b7f 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c
++++ b/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c
+@@ -432,7 +432,7 @@ struct RtreeMatchArg {
+ #if defined(i386)     || defined(__i386__)   || defined(_M_IX86) ||    \
+     defined(__x86_64) || defined(__x86_64__) || defined(_M_X64)  ||    \
+     defined(_M_AMD64) || defined(_M_ARM)     || defined(__x86)   ||    \
+-    defined(__arm__)
++    defined(__arm__) || defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ # define SQLITE_BYTEORDER    1234
+ #elif defined(sparc)    || defined(__ppc__)
+ # define SQLITE_BYTEORDER    4321
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h b/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h
+index 9ef2437b0..6c70148c7 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h
++++ b/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h
+@@ -853,7 +853,8 @@ typedef INT16_TYPE LogEst;
+ # if defined(i386)      || defined(__i386__)      || defined(_M_IX86) ||    \
+      defined(__x86_64)  || defined(__x86_64__)    || defined(_M_X64)  ||    \
+      defined(_M_AMD64)  || defined(_M_ARM)        || defined(__x86)   ||    \
+-     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
++     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) ||   \
++     defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #   define SQLITE_BYTEORDER    1234
+ # elif defined(sparc)     || defined(__ppc__) || \
+        defined(__ARMEB__) || defined(__AARCH64EB__)
+diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc b/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc
+index dd9ab457e..c005d9599 100644
+--- a/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc
++++ b/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc
+@@ -30,11 +30,7 @@
+   static bool (*diff_proc)(const uint8_t*, const uint8_t*) = nullptr;
+ 
+   if (!diff_proc) {
+-#if defined(WEBRTC_ARCH_ARM_FAMILY) || defined(WEBRTC_ARCH_MIPS_FAMILY)
+-    // For ARM and MIPS processors, always use C version.
+-    // TODO(hclam): Implement a NEON version.
+-    diff_proc = &VectorDifference_C;
+-#else
++#if defined(WEBRTC_ARCH_X86_FAMILY)
+     bool have_sse2 = GetCPUInfo(kSSE2) != 0;
+     // For x86 processors, check if SSE2 is supported.
+     if (have_sse2 && kBlockSize == 32) {
+@@ -44,6 +40,10 @@ bool VectorDifference(const uint8_t* image1, const uint8_t* image2) {
+     } else {
+       diff_proc = &VectorDifference_C;
+     }
++#else
++    // For other processors, always use C version.
++    // TODO(hclam): Implement a NEON version.
++    diff_proc = &VectorDifference_C;
+ #endif
+   }
+ 
+diff --git a/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h b/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h
+index ed216e660..25d36c071 100644
+--- a/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h
++++ b/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h
+@@ -50,6 +50,18 @@
+ #elif defined(__EMSCRIPTEN__)
+ #define WEBRTC_ARCH_32_BITS
+ #define WEBRTC_ARCH_LITTLE_ENDIAN
++#elif defined(__PPC__)
++#define WEBRTC_ARCH_PPC_FAMILY
++#if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
++#define WEBRTC_ARCH_LITTLE_ENDIAN
++#else
++#define WEBRTC_ARCH_BIG_ENDIAN
++#endif
++#if defined(__LP64__)
++#define WEBRTC_ARCH_64_BITS
++#else
++#define WEBRTC_ARCH_32_BITS
++#endif
+ #else
+ #error Please add support for your architecture in rtc_base/system/arch.h
+ #endif
+diff --git a/src/3rdparty/chromium/v8/BUILD.gn b/src/3rdparty/chromium/v8/BUILD.gn
+index ab20142de..001921c59 100644
+--- a/src/3rdparty/chromium/v8/BUILD.gn
++++ b/src/3rdparty/chromium/v8/BUILD.gn
+@@ -678,6 +678,12 @@ config("toolchain") {
+     }
+     if (host_byteorder == "little") {
+       defines += [ "V8_TARGET_ARCH_PPC_LE" ]
++        cflags += [
++        # Enable usage of AltiVec, VSX, and other POWER8 and higher features
++        "-mcpu=power8",
++        "-maltivec",
++        "-mvsx",
++      ]
+     } else if (host_byteorder == "big") {
+       defines += [ "V8_TARGET_ARCH_PPC_BE" ]
+       if (current_os == "aix") {
diff --git a/srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch b/srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch
new file mode 100644
index 000000000000..4cd12a7fb419
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch
@@ -0,0 +1,185 @@
+diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+index a6aec544e..2a4a7f1bc 100644
+--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
++++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+@@ -16,7 +16,7 @@
+ #if defined(__mips__)
+ // sys/user.h in eglibc misses size_t definition
+ #include <stddef.h>
+-#elif defined(__powerpc64__)
++#elif defined(__powerpc64__) && defined(__GLIBC__)
+ // Manually define greg_t on ppc64
+ typedef unsigned long long greg_t;
+ #endif
+@@ -361,11 +361,11 @@ typedef struct pt_regs regs_struct;
+ #define SECCOMP_ARCH AUDIT_ARCH_PPC64
+ #endif
+ 
+-#define SECCOMP_REG(_ctx, _reg) ((_ctx)->uc_mcontext.regs->gpr[_reg])
++#define SECCOMP_REG(_ctx, _reg) (((struct pt_regs *)(_ctx)->uc_mcontext.regs)->gpr[_reg])
+ 
+ #define SECCOMP_RESULT(_ctx) SECCOMP_REG(_ctx, 3)
+ #define SECCOMP_SYSCALL(_ctx) SECCOMP_REG(_ctx, 0)
+-#define SECCOMP_IP(_ctx) (_ctx)->uc_mcontext.regs->nip
++#define SECCOMP_IP(_ctx) ((struct pt_regs *)(_ctx)->uc_mcontext.regs)->nip
+ #define SECCOMP_PARM1(_ctx) SECCOMP_REG(_ctx, 3)
+ #define SECCOMP_PARM2(_ctx) SECCOMP_REG(_ctx, 4)
+ #define SECCOMP_PARM3(_ctx) SECCOMP_REG(_ctx, 5)
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+index 10fa5fd07..30b7b3851 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+@@ -497,9 +497,9 @@ void Syscall::PutValueInUcontext(intptr_t ret_val, ucontext_t* ctx) {
+   // Same as MIPS, need to invert ret and set error register (cr0.SO)
+   if (ret_val <= -1 && ret_val >= -4095) {
+     ret_val = -ret_val;
+-    ctx->uc_mcontext.regs->ccr |= (1 << 28);
++    ((struct pt_regs *)ctx->uc_mcontext.regs)->ccr |= (1 << 28);
+   } else {
+-    ctx->uc_mcontext.regs->ccr &= ~(1 << 28);
++    ((struct pt_regs *)ctx->uc_mcontext.regs)->ccr &= ~(1 << 28);
+   }
+ #endif
+   SECCOMP_RESULT(ctx) = static_cast<greg_t>(ret_val);
+diff --git a/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h b/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h
+index cdce9bf8a..73d77dda4 100644
+--- a/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h
++++ b/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h
+@@ -46,7 +46,7 @@
+ 
+ // The following platforms have an implementation of a hardware counter.
+ #if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__) || \
+-  defined(__powerpc__) || defined(__ppc__) || \
++  ((defined(__powerpc__) || defined(__ppc__)) && defined(__GLIBC__)) || \
+   defined(_M_IX86) || defined(_M_X64)
+ #define ABSL_HAVE_UNSCALED_CYCLECLOCK_IMPLEMENTATION 1
+ #else
+--- a/src/3rdparty/chromium/third_party/abseil-cpp/absl/debugging/internal/stacktrace_config.h
++++ b/src/3rdparty/chromium/third_party/abseil-cpp/absl/debugging/internal/stacktrace_config.h
+@@ -64,7 +64,7 @@
+ #elif defined(__i386__) || defined(__x86_64__)
+ #define ABSL_STACKTRACE_INL_HEADER \
+   "absl/debugging/internal/stacktrace_x86-inl.inc"
+-#elif defined(__ppc__) || defined(__PPC__)
++#elif (defined(__ppc__) || defined(__PPC__)) && defined(__GLIBC__)
+ #define ABSL_STACKTRACE_INL_HEADER \
+   "absl/debugging/internal/stacktrace_powerpc-inl.inc"
+ #elif defined(__aarch64__)
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+index 03afec7a5..0264ecf13 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+@@ -273,6 +273,9 @@ void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
+ 
+ #elif defined(__powerpc64__)
+ 
++#include <asm/elf.h>
++#include <asm/ptrace.h>
++
+ uintptr_t ThreadInfo::GetInstructionPointer() const {
+     return mcontext.gp_regs[PT_NIP];
+ }
+@@ -290,9 +293,9 @@ void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
+     out->ctr = mcontext.gp_regs[PT_CTR];
+     
+     for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
+-        out->float_save.fpregs[i] = mcontext.fp_regs[i];
++        out->float_save.fpregs[i] = ((uint64_t *)&mcontext.fp_regs)[i];
+ 
+-    out->float_save.fpscr = mcontext.fp_regs[NFPREG-1];
++    out->float_save.fpscr = ((uint64_t *)&mcontext.fp_regs)[ELF_NFPREG-1];
+ 
+     for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
+         out->vector_save.save_vr[i] = \
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+index 7620cf6f7..54e373611 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+@@ -257,6 +257,9 @@ void UContextReader::FillCPUContext(RawContextCPU *out, const ucontext_t *uc) {
+ 
+ #elif defined(__powerpc64__)
+ 
++#include <asm/elf.h>
++#include <asm/ptrace.h>
++
+ uintptr_t UContextReader::GetStackPointer(const ucontext_t* uc) {
+     return uc->uc_mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP];
+ }
+@@ -280,9 +283,9 @@ void UContextReader::FillCPUContext(RawContextCPU* out, const ucontext_t* uc,
+     out->ctr = uc->uc_mcontext.gp_regs[PT_CTR];
+     
+     for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
+-        out->float_save.fpregs[i] = uc->uc_mcontext.fp_regs[i];
++        out->float_save.fpregs[i] = ((uint64_t *)&uc->uc_mcontext.fp_regs)[i];
+ 
+-    out->float_save.fpscr = uc->uc_mcontext.fp_regs[NFPREG-1];
++    out->float_save.fpscr = ((uint64_t *)&uc->uc_mcontext.fp_regs)[ELF_NFPREG-1];
+ 
+     for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
+         out->vector_save.save_vr[i] =
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+index 901cd68fb..561958c44 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+@@ -105,6 +105,11 @@
+ #define PR_SET_PTRACER 0x59616d61
+ #endif
+ 
++/* musl hack, can't include asm/ptrace.h as that causes conflicts */
++#if defined(__powerpc64__) && !defined(PT_NIP)
++#define PT_NIP 32
++#endif
++
+ namespace google_breakpad {
+ 
+ namespace {
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+index 8e335a09..b2a0f155 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+@@ -469,7 +469,11 @@ struct MContext64 {
+   SignalThreadContext64 gp_regs;
+   SignalFloatContext64  fp_regs;
+   SignalVectorContext64 *v_regs;
++#ifdef __GLIBC__
+  int64_t vmx_reserve[69];
++#else
++  int64_t vmx_reserve[101];
++#endif
+ };
+ 
+ struct ContextTraits64 : public Traits64 {
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+index dea0d1f39..b203e5b2f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -30,6 +30,7 @@
+ 
+ #if defined(ARCH_CPU_PPC64_FAMILY)
+ #include <sys/ucontext.h>
++#include <asm/ptrace.h>
+ #endif
+ 
+ namespace crashpad {
+diff --git a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+index 9955ce44..4c1cc488 100644
+--- a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
++++ b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+@@ -4216,9 +4216,17 @@ struct kernel_statfs {
+     }
+   #endif
+   #if defined(__NR_fstatat64)
++    // musl does #define fstatat64 fstatat
++    #ifndef __GLIBC__
++    #undef fstatat64
++    #endif
+     LSS_INLINE _syscall4(int,   fstatat64,        int,   d,
+                          const char *,      p,
+                          struct kernel_stat64 *,   b,    int,   f)
++    // set it back like it was
++    #ifndef __GLIBC__
++    #define fstatat64 fstatat
++    #endif
+   #endif
+   #if defined(__NR_waitpid)
+     // waitpid is polyfilled below when not available.
diff --git a/srcpkgs/qt6-webengine/patches/0110-size_t.patch b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
new file mode 100644
index 000000000000..462e3202279f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
@@ -0,0 +1,16 @@
+--- a/src/3rdparty/chromium/third_party/angle/include/platform/PlatformMethods.h	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:44:25.477989726 +0100
+@@ -239,11 +239,11 @@
+ using ProgramKeyType   = std::array<uint8_t, 20>;
+ using CacheProgramFunc = void (*)(PlatformMethods *platform,
+                                   const ProgramKeyType &key,
+-                                  size_t programSize,
++                                  std::size_t programSize,
+                                   const uint8_t *programBytes);
+ inline void DefaultCacheProgram(PlatformMethods *platform,
+                                 const ProgramKeyType &key,
+-                                size_t programSize,
++                                std::size_t programSize,
+                                 const uint8_t *programBytes)
+ {}
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
new file mode 100644
index 000000000000..368099b981cc
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/skia/BUILD.gn	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/skia/BUILD.gn	2020-10-06 20:51:48.834970455 +0200
+@@ -772,7 +772,6 @@
+         # Root build config sets -mfpu=$arm_fpu, which we expect to be neon
+         # when running this.
+         if (!arm_use_neon) {
+-          configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
+           cflags += [ "-mfpu=neon" ]
+         }
+       }
diff --git a/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
new file mode 100644
index 000000000000..6e2d62f35ee6
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
@@ -0,0 +1,20 @@
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -17,6 +17,17 @@
+ 
+ #include <stdint.h>
+ #include <sys/user.h>
++#if !defined(__GLIBC__)
++struct user_vfp {
++	unsigned long long fpregs[32];
++	unsigned long fpscr;
++};
++struct user_vfp_exc {
++	unsigned long fpexc;
++	unsigned long fpinst;
++	unsigned long fpinst2;
++};
++#endif /* !defined(__GLIBC__) */
+ 
+ #include <type_traits>
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
new file mode 100644
index 000000000000..5c7cbfc46f65
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
@@ -0,0 +1,18 @@
+--- a/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-10-06 21:28:45.124882085 +0200
+@@ -109,6 +109,15 @@
+ #define HWCAP_IDIV  (HWCAP_IDIVA | HWCAP_IDIVT)
+ #define HWCAP_LPAE  (1 << 20)
+ 
++#ifndef __GLIBC__
++#include <elf.h>
++#ifdef __LP64__
++typedef Elf64_auxv_t elf_auxv_t;
++#else
++typedef Elf32_auxv_t elf_auxv_t;
++#endif
++#endif
++
+ static uint32_t ReadELFHWCaps() {
+ #if V8_GLIBC_PREREQ(2, 16)
+   return static_cast<uint32_t>(getauxval(AT_HWCAP));
diff --git a/srcpkgs/qt6-webengine/patches/0114-time64.patch b/srcpkgs/qt6-webengine/patches/0114-time64.patch
new file mode 100644
index 000000000000..6a98dd4e480e
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0114-time64.patch
@@ -0,0 +1,89 @@
+Description: fix seccomp-bpf failures in syscalls 0403, 0407
+ glibc ≥ 2.31 uses these syscalls on 32-bit platforms:
+ .
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=2e44b10b42d68d98
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=ec138c67cbda8b58
+Author: Andreas Müller <schnitzeltony@gmail.com>
+Forwarded: no
+Last-Update: 2020-09-02
+
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -148,7 +148,14 @@ ResultExpr EvaluateSyscallImpl(int fs_de
+     return Allow();
+ #endif
+ 
+-  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep) {
++  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep
++#if defined(__NR_clock_gettime64)
++                                  || sysno == __NR_clock_gettime64
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++                                  || sysno == __NR_clock_nanosleep_time64
++#endif
++  ) {
+     return RestrictClockID();
+   }
+ 
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
+@@ -60,6 +60,12 @@ class RestrictClockIdPolicy : public bpf
+       case __NR_clock_gettime:
+       case __NR_clock_getres:
+       case __NR_clock_nanosleep:
++#if defined(__NR_clock_nanosleep_time64)
++      case __NR_clock_nanosleep_time64:
++#endif
++#if defined(__NR_clock_gettime64)
++      case __NR_clock_gettime64:
++#endif
+         return RestrictClockID();
+       default:
+         return Allow();
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -39,6 +39,12 @@ bool SyscallSets::IsAllowedGettime(int s
+                                 // filtered by RestrictClokID().
+     case __NR_clock_gettime:    // Parameters filtered by RestrictClockID().
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
++#if defined(__NR_clock_gettime64)
++    case __NR_clock_gettime64:  // Parameters filtered by RestrictClockID().
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++    case __NR_clock_nanosleep_time64:  // Parameters filtered by RestrictClockID().
++#endif
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,14 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_SYSCALL_BASE+403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_SYSCALL_BASE+407)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
+@@ -1433,4 +1433,12 @@
+ #define __NR_memfd_create (__NR_Linux + 354)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_Linux + 403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_Linux + 407)
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_MIPS_LINUX_SYSCALLS_H_
diff --git a/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
new file mode 100644
index 000000000000..3a0ba3b2d854
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
@@ -0,0 +1,144 @@
+# Patch made by Kevin Kofler <Kevin@tigcc.ticalc.org>
+# https://bugzilla.redhat.com/show_bug.cgi?id=1904652
+
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2021-01-20 02:14:53.066223906 +0100
+@@ -257,6 +257,18 @@
+     return RestrictKillTarget(current_pid, sysno);
+   }
+ 
++#if defined(__NR_newfstatat)
++  if (sysno == __NR_newfstatat) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
++#if defined(__NR_fstatat64)
++  if (sysno == __NR_fstatat64) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
+   if (SyscallSets::IsFileSystem(sysno) ||
+       SyscallSets::IsCurrentDirectory(sysno)) {
+     return Error(fs_denied_errno);
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2021-01-22 19:02:55.651668257 +0100
+@@ -6,6 +6,8 @@
+ 
+ #include "sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h"
+ 
++#include <errno.h>
++#include <fcntl.h>
+ #include <stddef.h>
+ #include <stdint.h>
+ #include <string.h>
+@@ -355,6 +357,35 @@
+   return -ENOSYS;
+ }
+ 
++intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args,
++                            void* aux) {
++  switch (args.nr) {
++#if defined(__NR_newfstatat)
++    case __NR_newfstatat:
++#endif
++#if defined(__NR_fstatat64)
++    case __NR_fstatat64:
++#endif
++#if defined(__NR_newfstatat) || defined(__NR_fstatat64)
++      if (*reinterpret_cast<const char *>(args.args[1]) == '\0'
++          && args.args[3] == static_cast<uint64_t>(AT_EMPTY_PATH)) {
++        return sandbox::sys_fstat64(static_cast<int>(args.args[0]),
++                                    reinterpret_cast<struct stat64 *>(args.args[2]));
++      } else {
++        errno = EACCES;
++        return -1;
++      }
++      break;
++#endif
++  }
++
++  CrashSIGSYS_Handler(args, aux);
++
++  // Should never be reached.
++  RAW_CHECK(false);
++  return -ENOSYS;
++}
++
+ bpf_dsl::ResultExpr CrashSIGSYS() {
+   return bpf_dsl::Trap(CrashSIGSYS_Handler, NULL);
+ }
+@@ -387,6 +418,10 @@
+   return bpf_dsl::Trap(SIGSYSSchedHandler, NULL);
+ }
+ 
++bpf_dsl::ResultExpr RewriteFstatatSIGSYS() {
++  return bpf_dsl::Trap(SIGSYSFstatatHandler, NULL);
++}
++
+ void AllocateCrashKeys() {
+ #if !defined(OS_NACL_NONSFI)
+   if (seccomp_crash_key)
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2021-01-20 02:11:04.583714199 +0100
+@@ -62,6 +62,10 @@
+ // sched_setparam(), sched_setscheduler()
+ SANDBOX_EXPORT intptr_t SIGSYSSchedHandler(const arch_seccomp_data& args,
+                                            void* aux);
++// If the fstatat syscall is actually a disguised fstat, calls the regular fstat
++// syscall, otherwise, crashes in the same way as CrashSIGSYS_Handler.
++SANDBOX_EXPORT intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args, 
++                                             void* aux);
+ 
+ // Variants of the above functions for use with bpf_dsl.
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYS();
+@@ -72,6 +76,7 @@
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSFutex();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSPtrace();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteSchedSIGSYS();
++SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteFstatatSIGSYS();
+ 
+ // Allocates a crash key so that Seccomp information can be recorded.
+ void AllocateCrashKeys();
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2021-01-20 02:41:12.033133269 +0100
+@@ -261,4 +261,13 @@
+ 
+ #endif  // defined(MEMORY_SANITIZER)
+ 
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf)
++{
++#if defined(__NR_fstat64)
++    return syscall(__NR_fstat64, fd, buf);
++#else
++    return syscall(__NR_fstat, fd, buf);
++#endif
++}
++
+ }  // namespace sandbox
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2021-01-20 02:40:26.499827829 +0100
+@@ -17,6 +17,7 @@
+ struct rlimit64;
+ struct cap_hdr;
+ struct cap_data;
++struct stat64;
+ 
+ namespace sandbox {
+ 
+@@ -84,6 +85,9 @@
+                                  const struct sigaction* act,
+                                  struct sigaction* oldact);
+ 
++// Recent glibc rewrites fstat to fstatat.
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf);
++
+ }  // namespace sandbox
+ 
+ #endif  // SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_
diff --git a/srcpkgs/qt6-webengine/template b/srcpkgs/qt6-webengine/template
new file mode 100644
index 000000000000..45aeb56b42b1
--- /dev/null
+++ b/srcpkgs/qt6-webengine/template
@@ -0,0 +1,93 @@
+# Template file for 'qt6-webengine'
+pkgname=qt6-webengine
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebengine-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true
+ -DQT_FEATURE_webengine_system_ffmpeg=ON
+ -DQT_FEATURE_webengine_system_libevent=ON
+ -DQT_FEATURE_webengine_system_gn=ON
+ -DPKG_CONFIG_HOST_EXECUTABLE=${PKG_CONFIG_FOR_BUILD}"
+hostmakedepends="qt6-base-devel perl pkg-config nodejs python
+ protobuf gperf flex nss-devel libwebp-devel"
+makedepends="qt6-base-devel qt6-declarative-devel pulseaudio-devel
+ alsa-lib-devel libvpx-devel pciutils-devel opus-devel libxslt-devel
+ libxml2-devel freetype-devel lcms2-devel libwebp-devel icu-devel
+ re2-devel zlib-devel libpng-devel minizip-devel harfbuzz-devel
+ nss-devel libXcursor-devel libXcomposite-devel libXScrnSaver-devel
+ protobuf-devel ffmpeg-devel snappy-devel libevent-devel pipewire-devel
+ qt6-quickcontrols2-devel qt6-location-devel qt6-webchannel-devel"
+short_desc="Cross-platform application and UI framework - Webengine"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-3.0-only, GPL-2.0-only, LGPL-3.0-only BSD-3-Clause"
+homepage="https://www.qt.io"
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebengine-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e509436aa22b952e6195c146cf06a839b85aaa0724feb85f0b78516dc42105a4
+
+if [ -z "$CROSS_BUILD" ];then
+	configure_args+=" -DCMAKE_TOOLCHAIN_FILE=/usr/lib/cmake/Qt6/qt.toolchain.cmake"
+fi
+
+if [ "$XBPS_LIBC" = "musl" ]; then
+	hostmakedepends+=" musl-legacy-compat"
+fi
+
+if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
+	makedepends+=" musl-legacy-compat"
+fi
+
+if [ ! "$XBPS_WORDSIZE" = "$XBPS_TARGET_WORDSIZE" ]; then
+	broken="webengine can be built only if word size matches"
+fi
+
+if [ "$XBPS_WORDSIZE" -eq 32 ]; then
+	nodebug=yes
+	LDFLAGS="-Wl,--no-keep-memory"
+fi
+
+if [ "$XBPS_TARGET_ENDIAN" != "le" ]; then
+	broken="webengine only supports little endian"
+fi
+
+_bootstrap_gn() {
+	# Bootstrap gn (generate ninja)
+	echo "Bootstrapping 'gn'"
+	cd ${wrksrc}/src/3rdparty/gn
+	CFLAGS="$CFLAGS_host" CXXFLAGS="$CXXFLAGS_host" LDFLAGS="$LDFLAGS_host" \
+	PKGCONFIG=/usr/bin/pkgconfig PKG_CONFIG_PATH="/usr/lib/pkgconfig:/usr/share/pkgconfig" \
+		python2 build/gen.py --no-last-commit-position --out-path \
+			${wrksrc}/src/3rdparty/gn/out/Release --cc "${CC_host:-$CC}" \
+			--cxx "${CXX_host:-$CXX}" --ld "${CXX_host:-$CXX}" --ar "${AR_host:-$AR}" \
+			--qt-version "${version}.qtwebengine.qt.io"
+	ninja -C out/Release gn
+	cd ${wrksrc}
+}
+
+pre_configure() {
+	cp ${FILESDIR}/resolv_compat.h ${wrksrc}/src/3rdparty/chromium/net/dns
+	_bootstrap_gn
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+pre_build() {
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+post_install() {
+	rm -r ${DESTDIR}/builddir
+	mv ${DESTDIR}/usr/resources ${DESTDIR}/usr/share/qt6
+	mv ${DESTDIR}/usr/translations ${DESTDIR}/usr/share/qt6
+}
+
+qt6-webengine-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-webchannel-devel>=${version}_1
+	 qt6-declarative-devel>=${version}_1 qt6-location-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+	}
+}

From a40739a8502843ce2e643bf8d270ff4517918adf Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 16:00:28 +0200
Subject: [PATCH 24/24] New package: qt6-location-6.2.0alpha

---
 common/shlibs                 |  1 +
 srcpkgs/qt6-location-devel    |  1 +
 srcpkgs/qt6-location/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-location-devel
 create mode 100644 srcpkgs/qt6-location/template

diff --git a/common/shlibs b/common/shlibs
index e6d1ef7157b4..e3b64dfad96b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2063,6 +2063,7 @@ libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
+libQt6Positioning.so.6 qt6-location-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-location-devel b/srcpkgs/qt6-location-devel
new file mode 120000
index 000000000000..7924c82dd3f4
--- /dev/null
+++ b/srcpkgs/qt6-location-devel
@@ -0,0 +1 @@
+qt6-location
\ No newline at end of file
diff --git a/srcpkgs/qt6-location/template b/srcpkgs/qt6-location/template
new file mode 100644
index 000000000000..3bad3ab8aade
--- /dev/null
+++ b/srcpkgs/qt6-location/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-location'
+pkgname=qt6-location
+version=6.2.0alpha
+revision=1
+wrksrc="qtlocation-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-serialport-devel qt6-declarative-devel GConf-devel"
+short_desc="Cross-platform application and UI framework - location"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlocation-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=514a84d73ccb7af5f7921b99a5742314c8875bd4cb1a982a09b28a8080c117c8
+
+qt6-location-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
  2021-06-27 19:20 ` [PR PATCH] [Updated] " Johnnynator
  2021-06-27 19:37 ` Johnnynator
@ 2021-06-27 19:38 ` Johnnynator
  2021-06-27 20:17 ` [PR REVIEW] " ericonr
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-06-27 19:38 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

There is an updated pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 286434 bytes --]

From b5cde7b93c73f447a644dc06904a4e37de8deceb Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 01/24] qt6-3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..9a45c8c011ef 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt3d-everywhere-src-${version}"
+wrksrc="qt3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - 3d"
 maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=8fff7ac79b3f508df00bfc4e14e401b1dde0a5bc1d67d3cb88c05b04ac12aa1b
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 3bbfbb063956864a2f04fe692e986af042b31bd6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 02/24] qt6-base: update to 6.2.0alpha.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 +++++++++++++++++++
 srcpkgs/qt6-base/template                     | 16 ++++++------
 2 files changed, 33 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index bb043213a360..fad36fe8bc70 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtbase-everywhere-src-${version}"
+wrksrc="qtbase-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
  -DINSTALL_ARCHDATADIR=lib/qt6
@@ -27,8 +27,8 @@ short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtbase-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=eb18d8fc5b5136ab0d177d89c54ec197363904fedb2aecb0d87033ce78ddffcc
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -84,10 +84,10 @@ qt6-gui_package() {
 	short_desc+=" - Gui"
 	pkg_install() {
 		vmove "usr/lib/libQt6Gui.so.*"
-		vmove "usr/lib/libQt6XcbQpa.so.*"
-		vmove "usr/lib/libQt6EglFSDeviceIntegration.so.*"
-		vmove "usr/lib/libQt6EglFsKmsGbmSupport.so.*"
-		vmove "usr/lib/libQt6EglFsKmsSupport.so.*"
+		vmove "usr/lib/libQt6XcbQpaPrivate.so.*"
+		vmove "usr/lib/libQt6EglFSDeviceIntegrationPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsGbmSupportPrivate.so.*"
+		vmove "usr/lib/libQt6EglFsKmsSupportPrivate.so.*"
 		vmove "usr/lib/libQt6OpenGL.so.*"
 		vmove usr/lib/qt6/plugins/generic
 		vmove usr/lib/qt6/plugins/platforms

From 887ee80e9686b8e588deacefd50f56dd74d5d773 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 03/24] qt6-charts: update to 6.2.0alpha.

---
 srcpkgs/qt6-charts/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..1beaf0dbecfd 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtcharts-everywhere-src-${version}"
+wrksrc="qtcharts-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - charts"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtcharts-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=294205bc1e855bb44a0e17c707b981c617fc08d55d071e1d02441ff5a4e7e676
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 69958b3a121927781ae2119dbe7881510d436bb9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 04/24] qt6-declarative: update to 6.2.0alpha.

---
 srcpkgs/qt6-declarative/template | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..bef006df96f0 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,23 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtdeclarative-everywhere-src-${version}"
+wrksrc="qtdeclarative-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel qt6-declarative-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtdeclarative-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=4fd2d9448620586862e56149c43ef93b6dddcb60d6f211ab933bed984d1f1d8a
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +37,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}

From aada910c567270d02619c3dbf850c5bd7020a143 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 05/24] qt6-imageformats: update to 6.2.0alpha.

---
 srcpkgs/qt6-imageformats/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..8207913c89f9 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtimageformats-everywhere-src-${version}"
+wrksrc="qtimageformats-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - imageformats"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtimageformats-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=6e4a3690b5de83733f9a4ad492784b33748684cd99e98aa7cd3c30c97faa2bae

From 15ab172bb800f7d3f236f65bdd36a7c369389c67 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 06/24] qt6-lottie: update to 6.2.0alpha.

---
 srcpkgs/qt6-lottie/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..0a55513d0cb8 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtlottie-everywhere-src-${version}"
+wrksrc="qtlottie-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - lottie"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlottie-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=07e01a8993866abcb372cc8569d299f79cc6a91ebf66a5a85a5abe722527eadc
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From eb078c67d662ab8343f5978c753e39886d639d92 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 07/24] qt6-networkauth: update to 6.2.0alpha.

---
 srcpkgs/qt6-networkauth/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..654a2bb0fd69 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtnetworkauth-everywhere-src-${version}"
+wrksrc="qtnetworkauth-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - networkauth"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtnetworkauth-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=75784d38da1d476b209c3151dbd9afda0708fdcfbfd48d09a520754a442ccda6
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 7c2a671fa4d46b18e000208854b4109a7d2df9ba Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 08/24] qt6-qt5compat: update to 6.2.0alpha.

---
 srcpkgs/qt6-qt5compat/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index d64b37bff575..0567c1b374e5 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qt5compat-everywhere-src-${version}"
+wrksrc="qt5compat-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Compo
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qt5compat-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=210dbe079b51ba47841219fde59ad11a8e77a4a851a73b77121153ed03afb473
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From be6ba0726c80f36232967cce5dfcfb5b9ee65fb8 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 09/24] qt6-quick3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-quick3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..673ec342450f 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquick3d-everywhere-src-${version}"
+wrksrc="qtquick3d-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel qt6-shadertools-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - Quick3d"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquick3d-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=b60012e2d3d4b9d62cbddd84b56dcae985bc7b111b551d0eadd06551772db806
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From b27e77ae879c847b2ac68560fab513afe37b2eea Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:16 +0200
Subject: [PATCH 10/24] qt6-quickcontrols2: update to 6.2.0alpha.

---
 srcpkgs/qt6-quickcontrols2/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
index ab57102a19cf..efd4972c669c 100644
--- a/srcpkgs/qt6-quickcontrols2/template
+++ b/srcpkgs/qt6-quickcontrols2/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quickcontrols2'
 pkgname=qt6-quickcontrols2
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
+wrksrc="qtquickcontrols2-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quickcontrols2"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-2.0-or-later, LGPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquickcontrols2-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=40c8af99adb342c45809bfe06c73ac7d923433518cb7bc7997f6fc40e169c4c5
 
 qt6-quickcontrols2-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"

From 1a17155662858e9d84a7b6cd9ce3653d9361f6e6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 11/24] qt6-quicktimeline: update to 6.2.0alpha.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..bc0225e767bc 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtquicktimeline-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e5b024adf9ae291004b5273465757583796c989f317e3bc62366953f02c7a89a
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 1f5209e2a8751a0772f0bcf681991984aba6afd4 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 12/24] qt6-scxml: update to 6.2.0alpha.

---
 srcpkgs/qt6-scxml/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..f8324f91a3d7 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtscxml-everywhere-src-${version}"
+wrksrc="qtscxml-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - scxml"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtscxml-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e29a333477e84d407421096fd2d90bccfb95ae4b8d0ed0d0785586e56cfa9d0c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From b606a67dc061c1f45b239157b773083b7e4bd395 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 13/24] qt6-shadertools: update to 6.2.0alpha.

---
 srcpkgs/qt6-shadertools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..42fa436708a6 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtshadertools-everywhere-src-${version}"
+wrksrc="qtshadertools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - shadertools"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtshadertools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=08144fa6d96c4382e47b3203d27f999b86d4ed1f1b828e09a48614f32b12ee59
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From 7c296b0c79ade72bae881ca17db1f85a83cf6eb2 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 14/24] qt6-svg: update to 6.2.0alpha.

---
 srcpkgs/qt6-svg/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..c37793e0613b 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtsvg-everywhere-src-${version}"
+wrksrc="qtsvg-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-svg componen
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtsvg-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=dd7c5312b8430130103d91908bd5f19fa2c6bf01c76acb757e5974603b3769c8
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 44c54233dece4657c855e854dec92e411b82041c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 15/24] qt6-tools: update to 6.2.0alpha.

---
 srcpkgs/qt6-tools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..0e7a9126bcf7 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttools-everywhere-src-${version}"
+wrksrc="qttools-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-tools compon
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttools-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=32596431f71f7b4bbcd05e86c0490f97bf68b66e560337e5418a7faee5d86e84
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 7d8b1526b9c0448307dd4aa4a9d4de5377053d3c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 16/24] qt6-translations: update to 6.2.0alpha.

---
 srcpkgs/qt6-translations/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..c8be8fe68426 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qttranslations-everywhere-src-${version}"
+wrksrc="qttranslations-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel qt6-tools-devel perl"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - translations"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qttranslations-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=0fecd5d3e8f8823d1c77e95fbbac80c084b08df5a02f06fe71b2af6ceceb87ad

From 0c0055a85111cada71a12c5c36ba2a21b6e97b2e Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 17/24] qt6-virtualkeyboard: update to 6.2.0alpha.

---
 srcpkgs/qt6-virtualkeyboard/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..c5034fa3e95d 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
+wrksrc="qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
@@ -13,8 +13,8 @@ short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtvirtualkeyboard-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=1675dad7cd41fddb593d1fcf0a6d2a7c0f27ae9962232cba8a0a94dd38044320
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From e5dd139978eaceb3156704b74231c109e41cb7e5 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 18/24] qt6-wayland: update to 6.2.0alpha.

---
 srcpkgs/qt6-wayland/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..77c5eecd2551 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0alpha
 revision=1
-wrksrc="qtwayland-everywhere-src-${version}"
+wrksrc="qtwayland-everywhere-src-${version/alpha/-alpha}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel qt6-wayland-devel"
@@ -14,8 +14,8 @@ short_desc="Cross-platform application and UI framework - Wayland"
 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwayland-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=71209da169478c6ea3555f8e55edd9fe9d758ac9826c404af2a5e912a8fcfa5d
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From 43d52a9d09171ba008c6b8ea1621f3dc7d902242 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:16:54 +0200
Subject: [PATCH 19/24] New package: qt6-serialport-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-serialport-devel    |  1 +
 srcpkgs/qt6-serialport/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-serialport-devel
 create mode 100644 srcpkgs/qt6-serialport/template

diff --git a/common/shlibs b/common/shlibs
index 8a7eef8df8c3..eb023b6275aa 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2060,6 +2060,7 @@ libQt6Help.so.6 qt6-tools-6.1.0_1
 libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
+libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-serialport-devel b/srcpkgs/qt6-serialport-devel
new file mode 120000
index 000000000000..f6a498cf2653
--- /dev/null
+++ b/srcpkgs/qt6-serialport-devel
@@ -0,0 +1 @@
+qt6-serialport
\ No newline at end of file
diff --git a/srcpkgs/qt6-serialport/template b/srcpkgs/qt6-serialport/template
new file mode 100644
index 000000000000..45e5915979cc
--- /dev/null
+++ b/srcpkgs/qt6-serialport/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-serialport'
+pkgname=qt6-serialport
+version=6.2.0alpha
+revision=1
+wrksrc="qtserialport-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel pkg-config"
+makedepends="qt6-base-devel"
+short_desc="Cross-platform application and UI framework - serialport"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtserialport-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=51129c6964c42668e2ea205f1fcb0e0ea099aaeae74607112957343afb531863
+
+qt6-serialport-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 7edd1755472ba68864fb02b77aca9b61aa5ff69a Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:23:48 +0200
Subject: [PATCH 20/24] New package: qt6-websockets-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-websockets-devel    |  1 +
 srcpkgs/qt6-websockets/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-websockets-devel
 create mode 100644 srcpkgs/qt6-websockets/template

diff --git a/common/shlibs b/common/shlibs
index eb023b6275aa..69227af2267f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2061,6 +2061,7 @@ libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
+libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-websockets-devel b/srcpkgs/qt6-websockets-devel
new file mode 120000
index 000000000000..a3c674e42954
--- /dev/null
+++ b/srcpkgs/qt6-websockets-devel
@@ -0,0 +1 @@
+qt6-websockets
\ No newline at end of file
diff --git a/srcpkgs/qt6-websockets/template b/srcpkgs/qt6-websockets/template
new file mode 100644
index 000000000000..6177426904ae
--- /dev/null
+++ b/srcpkgs/qt6-websockets/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-websockets'
+pkgname=qt6-websockets
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebsockets-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel"
+short_desc="Cross-platform application and UI framework - websockets"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebsockets-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=f8277d05192ee5f823356a6c6b72ea816a0187f6a0915b783605bee9549a8761
+
+qt6-websockets-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 13ee41a031d02c96b1d1e015ff33cf3d775a351f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:25:04 +0200
Subject: [PATCH 21/24] New package: qt6-webchannel-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-webchannel-devel    |  1 +
 srcpkgs/qt6-webchannel/template | 28 ++++++++++++++++++++++++++++
 3 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-webchannel-devel
 create mode 100644 srcpkgs/qt6-webchannel/template

diff --git a/common/shlibs b/common/shlibs
index 69227af2267f..e6d1ef7157b4 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2062,6 +2062,7 @@ libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
+libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-webchannel-devel b/srcpkgs/qt6-webchannel-devel
new file mode 120000
index 000000000000..03e8b23d785d
--- /dev/null
+++ b/srcpkgs/qt6-webchannel-devel
@@ -0,0 +1 @@
+qt6-webchannel
\ No newline at end of file
diff --git a/srcpkgs/qt6-webchannel/template b/srcpkgs/qt6-webchannel/template
new file mode 100644
index 000000000000..a1d217810c90
--- /dev/null
+++ b/srcpkgs/qt6-webchannel/template
@@ -0,0 +1,28 @@
+# Template file for 'qt6-webchannel'
+pkgname=qt6-webchannel
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebchannel-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel qt6-websockets-devel"
+short_desc="Cross-platform application and UI framework - webchannel"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebchannel-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=68fd3f0508b6df69b5736d7e142509131f3728630abdcd432a06430e5ca8920c
+
+qt6-webchannel-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1
+	 qt6-websockets-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 5ec2dcc9776c43e878b647e9c87332c3e38511a9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 21:08:25 +0200
Subject: [PATCH 22/24] New package: qt6-multimedia-6.2.0alpha

---
 srcpkgs/qt6-multimedia-devel    |  1 +
 srcpkgs/qt6-multimedia/template | 29 +++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-multimedia-devel
 create mode 100644 srcpkgs/qt6-multimedia/template

diff --git a/srcpkgs/qt6-multimedia-devel b/srcpkgs/qt6-multimedia-devel
new file mode 120000
index 000000000000..9343446502d0
--- /dev/null
+++ b/srcpkgs/qt6-multimedia-devel
@@ -0,0 +1 @@
+qt6-multimedia
\ No newline at end of file
diff --git a/srcpkgs/qt6-multimedia/template b/srcpkgs/qt6-multimedia/template
new file mode 100644
index 000000000000..41a25959361e
--- /dev/null
+++ b/srcpkgs/qt6-multimedia/template
@@ -0,0 +1,29 @@
+# Template file for 'qt6-multimedia'
+pkgname=qt6-multimedia
+version=6.2.0alpha
+revision=1
+wrksrc="qtmultimedia-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_FEATURE_gstreamer=ON"
+hostmakedepends="perl qt6-declarative-devel pkg-config
+ qt6-shadertools-devel"
+makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
+ qt6-shadertools-devel libglib-devel gst-plugins-base1-devel"
+short_desc="Cross-platform application and UI framework - multimedia"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtmultimedia-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=9241fe9456c04ba1feaffd74883d37155c0218baf8aa9fc3dd54642791f378cd
+
+qt6-multimedia-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From efdfc4a2daa9f7438c488e0a01c5cac9456b6a04 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 00:35:33 +0200
Subject: [PATCH 23/24] New package: qt6-webengine-6.2.0alpha

---
 srcpkgs/qt6-webengine-devel                   |    1 +
 srcpkgs/qt6-webengine/files/resolv_compat.h   |   29 +
 ...-compilation-support-to-cmake-builds.patch |  474 +++
 .../patches/0001-mus-cstring.patch            |   10 +
 ...use-target-C-XX-FLAGS-for-host-cmake.patch |   26 +
 .../patches/0002-None-no-debug.patch          |   11 +
 ...reg.h-to-get-__WORDSIZE-on-musl-libc.patch |   26 +
 .../patches/0003-musl-dispatch-to-musl.patch  |  103 +
 .../patches/0004-musl-no-mallinfo.patch       |   39 +
 .../patches/0005-musl-off_t.patch             |   10 +
 .../patches/0006-musl-pread-pwrite.patch      |   18 +
 .../patches/0008-musl-resolve.patch           |   26 +
 .../patches/0009-musl-siginfo_t.patch         |   18 +
 .../patches/0010-musl-stackstart.patch        |   20 +
 .../patches/0011-musl-sandbox.patch           |   71 +
 ...0012-musl-chromium-default-stacksize.patch |   15 +
 .../0014-musl-cross-no-asm_ptrace_h.patch     |   30 +
 .../patches/0015-no-glibc-cmake-check.patch   |   14 +
 .../patches/0016-qt-musl-execinfo.patch       |  106 +
 .../0017-qt-musl-thread-stacksize.patch       |   26 +
 .../patches/0018-sandbox-membarrier.patch     |   60 +
 .../patches/0020-msgvec-push_back.patch       |   14 +
 .../patches/0021-sandbox-sched_getparam.patch |   26 +
 .../0022-canonicalize-file-name-musl.patch    |   11 +
 .../patches/0089-enable-ppc64.patch           |   49 +
 .../patches/0090-qtwebengine-ppc64.patch      | 3604 +++++++++++++++++
 .../patches/0091-chromium-ppc64le-musl.patch  |  185 +
 .../qt6-webengine/patches/0110-size_t.patch   |   16 +
 .../patches/0111-armv7l-neon.patch            |   10 +
 .../patches/0112-arm-user_vfp.patch           |   20 +
 .../patches/0113-arm-elf_auxv_t.patch         |   18 +
 .../qt6-webengine/patches/0114-time64.patch   |   89 +
 .../patches/0121-glibc-2.33.patch             |  144 +
 srcpkgs/qt6-webengine/template                |   94 +
 34 files changed, 5413 insertions(+)
 create mode 120000 srcpkgs/qt6-webengine-devel
 create mode 100644 srcpkgs/qt6-webengine/files/resolv_compat.h
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0110-size_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0114-time64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
 create mode 100644 srcpkgs/qt6-webengine/template

diff --git a/srcpkgs/qt6-webengine-devel b/srcpkgs/qt6-webengine-devel
new file mode 120000
index 000000000000..8e4d1b99c587
--- /dev/null
+++ b/srcpkgs/qt6-webengine-devel
@@ -0,0 +1 @@
+qt6-webengine
\ No newline at end of file
diff --git a/srcpkgs/qt6-webengine/files/resolv_compat.h b/srcpkgs/qt6-webengine/files/resolv_compat.h
new file mode 100644
index 000000000000..4f0e852a19d0
--- /dev/null
+++ b/srcpkgs/qt6-webengine/files/resolv_compat.h
@@ -0,0 +1,29 @@
+#if !defined(__GLIBC__)
+/***************************************************************************
+ * resolv_compat.h
+ *
+ * Mimick GLIBC's res_ninit() and res_nclose() for musl libc
+ * Note: res_init() is actually deprecated according to
+ * http://docs.oracle.com/cd/E36784_01/html/E36875/res-nclose-3resolv.html
+ **************************************************************************/
+#include <string.h>
+
+static inline int res_ninit(res_state statp)
+{
+	int rc = res_init();
+	if (statp != &_res) {
+		memcpy(statp, &_res, sizeof(*statp));
+	}
+	return rc;
+}
+
+static inline int res_nclose(res_state statp)
+{
+	if (!statp)
+		return -1;
+	if (statp != &_res) {
+		memset(statp, 0, sizeof(*statp));
+	}
+	return 0;
+}
+#endif
diff --git a/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
new file mode 100644
index 000000000000..c70f219e5f4d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-Add-cross-compilation-support-to-cmake-builds.patch
@@ -0,0 +1,474 @@
+From 7a22a424ff2997f644d930050635db214c068d10 Mon Sep 17 00:00:00 2001
+From: Michal Klocek <michal.klocek@qt.io>
+Date: Sun, 23 May 2021 17:39:28 +0200
+Subject: [PATCH 1/2] Add cross compilation support to cmake builds
+
+Add arm cross-compile basic support. CMake does not
+support host builds. However we do host build with gn and
+changing that would require an extra effort to keep all necessary
+changes with Chromium upstream. Therefore let gn to perform
+the host build for required tools and just feed gn with all the
+build data.
+
+Add new build steps:
+
+* install gn into QT_HOST_PATH/libexec.
+* run hostBuild project to get native architecture and compiler
+* call PkgConfigHost to pass pkg-config paths to gn
+* create wrapper script for host pkg-config to escape
+  yocto shell pkg config exports
+
+This change also splits gn toolchain into 3 toolchains host,target,v8
+Now hostBuild provides host and v8 toolchain in case of cross compile.
+
+The build optimizations will follow in another patch.
+
+Note this is tested only with yocto based images.
+
+Pick-to: dev
+Task-number: QTBUG-91760
+Change-Id: Ic2bea12229acc71fbd36a848e9ed4fed7e14b485
+---
+ CMakeLists.txt                           | 37 ++++++++++++++++--
+ cmake/FindGn.cmake                       |  9 +++--
+ cmake/FindNinja.cmake                    |  4 +-
+ cmake/FindPkgConfigHost.cmake            | 40 ++++++++++++++++++++
+ cmake/Functions.cmake                    | 45 ++++++++++++++++++++++
+ configure.cmake                          | 10 ++++-
+ src/core/CMakeLists.txt                  | 48 ++++++++++++++++++------
+ src/core/api/configure.cmake             | 10 ++---
+ src/core/configure/BUILD.toolchain.gn.in | 32 ++--------------
+ src/core/configure/CMakeLists.txt        | 35 +++++++++++++++++
+ 10 files changed, 215 insertions(+), 55 deletions(-)
+ create mode 100644 cmake/FindPkgConfigHost.cmake
+ create mode 100644 src/core/configure/CMakeLists.txt
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 8a3ff75c..2a93dca5 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -63,6 +63,7 @@ add_subdirectory(src/process)
+ add_subdirectory(src/webenginewidgets)
+ add_subdirectory(src/webenginequick)
+ qt_build_repo_end()
++get_install_config(installConfig)
+ 
+ ### NINJA
+ 
+@@ -94,9 +95,10 @@ if(NOT Gn_FOUND)
+                    -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
+                    -DCMAKE_PREFIX_PATH:PATH=<INSTALL_DIR>
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+-)
++    )
+ endif()
+ 
++
+ ### LIBS
+ 
+ # on windows source path can be specified without hard drive letter,
+@@ -115,12 +117,14 @@ endif()
+ list(TRANSFORM featureList PREPEND "-D")
+ list(APPEND libsCmakeArgs
+         "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}"
+-        "-DWEBENGINE_ROOT_BUILD_PATH=${CMAKE_CURRENT_BINARY_DIR}"
++        "-DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}"
+         "-DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}"
+         "-DWEBENGINE_REPO_BUILD=TRUE"
+         "${featureList}"
+ )
+-
++if(QT_HOST_PATH)
++    list(APPEND libsCmakeArgs "-DQT_HOST_PATH=${QT_HOST_PATH}")
++endif()
+ if(LINUX)
+     set(cmd "${CMAKE_COMMAND} --build ${CMAKE_CURRENT_BINARY_DIR}/src")
+     file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/src/build.sh CONTENT "ulimit -n 4096 && ${cmd}\n")
+@@ -210,3 +214,30 @@ if(NOT QT_FEATURE_framework)
+         DESTINATION ${CMAKE_INSTALL_PREFIX}
+     )
+ endif()
++
++### CROSS BUILD SETUP
++
++# install gn for cross build
++# TODO: is this really needed, should we skip it and just build gn as host build ?
++if(LINUX AND NOT Gn_FOUND OR INSTALL_GN)
++    set(INSTALL_GN 1 CACHE INTERNAL "")
++    install(
++        PROGRAMS ${installDir}/bin/gn
++        CONFIGURATIONS ${installConfig}
++        RUNTIME DESTINATION "${INSTALL_LIBEXECDIR}"
++    )
++endif()
++
++if(CMAKE_CROSSCOMPILING)
++    externalproject_add(hostBuild
++        SOURCE_DIR  ${CMAKE_CURRENT_LIST_DIR}/src/core/configure
++        BINARY_DIR  ${CMAKE_CURRENT_BINARY_DIR}/configure
++        PREFIX      cross
++        USES_TERMINAL_BUILD ON
++        CMAKE_ARGS -DCMAKE_TOOLCHAIN_FILE=${QT_HOST_PATH}/lib/cmake/Qt6/qt.toolchain.cmake
++                   -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
++                   -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
++                   -DGN_TARGET_CPU=${TEST_architecture_arch}
++    )
++    externalproject_add_stepdependencies(libs install hostBuild)
++endif()
+diff --git a/cmake/FindGn.cmake b/cmake/FindGn.cmake
+index 12a90778..abfa0fe2 100644
+--- a/cmake/FindGn.cmake
++++ b/cmake/FindGn.cmake
+@@ -1,9 +1,10 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/../..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
++endif()
++find_program(Gn_EXECUTABLE NAMES gn PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
++if(NOT QT_HOST_PATH STREQUAL "")
++   find_program(Gn_EXECUTABLE NAMES gn PATHS ${QT_HOST_PATH}/${INSTALL_LIBEXECDIR} NO_DEFAULT_PATH)
+ endif()
+-
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
+-
+ find_program(Gn_EXECUTABLE NAMES gn)
+ 
+ if(Gn_EXECUTABLE)
+diff --git a/cmake/FindNinja.cmake b/cmake/FindNinja.cmake
+index 3615d58b..720e7326 100644
+--- a/cmake/FindNinja.cmake
++++ b/cmake/FindNinja.cmake
+@@ -1,8 +1,8 @@
+ if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
+-    set(WEBENGINE_ROOT_BUILD_DIR  ${CMAKE_CURRENT_BINARY_DIR}/..)
++    set(WEBENGINE_ROOT_BUILD_DIR ${CMAKE_CURRENT_BINARY_DIR})
+ endif()
+ 
+-set(CMAKE_PROGRAM_PATH ${WEBENGINE_ROOT_BUILD_DIR}/install/bin)
++find_program(Ninja_EXECUTABLE NAMES ninja ninja-build PATHS "${WEBENGINE_ROOT_BUILD_DIR}/install/bin" NO_DEFAULT_PATH)
+ find_program(Ninja_EXECUTABLE NAMES ninja ninja-build)
+ 
+ if(Ninja_EXECUTABLE)
+diff --git a/cmake/FindPkgConfigHost.cmake b/cmake/FindPkgConfigHost.cmake
+new file mode 100644
+index 00000000..de021638
+--- /dev/null
++++ b/cmake/FindPkgConfigHost.cmake
+@@ -0,0 +1,40 @@
++# this is just simply pkg config wrapper to pass executable path to gn
++
++if(CMAKE_CROSSCOMPILING)
++   # find pkg-config, use PKG_CONFIG_HOST if set
++   if((NOT PKG_CONFIG_HOST_EXECUTABLE) AND (NOT "$ENV{PKG_CONFIG_HOST}" STREQUAL ""))
++       set(PKG_CONFIG_HOST_EXECUTABLE "$ENV{PKG_CONFIG_HOST}" CACHE FILEPATH "pkg-config host executable")
++   endif()
++
++   find_program(PKG_CONFIG_HOST_EXECUTABLE NAMES "pkg-config" DOC "pkg-config executable"
++       NO_SYSTEM_ENVIRONMENT_PATH
++       NO_CMAKE_FIND_ROOT_PATH
++   )
++
++   if(PKG_CONFIG_HOST_EXECUTABLE)
++       mark_as_advanced(PKG_CONFIG_HOST_EXECUTABLE)
++       execute_process(COMMAND ${PKG_CONFIG_HOST_EXECUTABLE} --version
++           OUTPUT_VARIABLE PKG_CONFIG_HOST_VERSION_STRING
++           OUTPUT_STRIP_TRAILING_WHITESPACE
++           ERROR_QUIET)
++   endif ()
++
++   include(FindPackageHandleStandardArgs)
++   find_package_handle_standard_args(PkgConfigHost
++       FOUND_VAR PkgConfigHost_FOUND
++       VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++       REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++   )
++else() # if not corss build simply wrap FindPkgConfig
++   find_package(PkgConfig)
++   if(PKG_CONFIG_FOUND)
++       include(FindPackageHandleStandardArgs)
++       set(PKG_CONFIG_HOST_VERSION ${PKG_CONFIG_VERSION})
++       set(PKG_CONFIG_HOST_EXECUTABLE ${PKG_CONFIG_EXECUTABLE})
++       find_package_handle_standard_args(PkgConfigHost
++           FOUND_VAR PkgConfigHost_FOUND
++           VERSION_VAR PKG_CONFIG_HOST_VERSION_STRING
++           REQUIRED_VARS PKG_CONFIG_HOST_EXECUTABLE
++       )
++  endif()
++endif()
+diff --git a/cmake/Functions.cmake b/cmake/Functions.cmake
+index d29ed7a4..3cdfdee9 100644
+--- a/cmake/Functions.cmake
++++ b/cmake/Functions.cmake
+@@ -348,3 +348,48 @@ function(qt_internal_add_external_project_dependency_to_root_project name)
+ 
+     cmake_policy(POP)
+ endfunction()
++
++function(get_gn_arch result arch)
++   if("${arch}" STREQUAL "i386")
++      set(${result} "x86" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "x86_64")
++      set(${result} "x64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm")
++      set(${result} "arm" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "arm64")
++      set(${result} "arm64" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel")
++      set(${result} "mipsel" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "mipsel64")
++      set(${result} "mips64el" PARENT_SCOPE)
++   else()
++      message(DEBUG "Unsupported achitecture: ${arch}")
++   endif()
++endfunction()
++
++function(get_v8_arch result targetArch)
++   set(list32 i386 arm mipsel)
++   if("${targetArch}" IN_LIST list32)
++       set(${result} "i386" PARENT_SCOPE)
++   else()
++       set(${result} "x86_64" PARENT_SCOPE)
++   endif()
++endfunction()
++
++function(configure_gn_toolchain name cpuType v8CpuType toolchainIn toolchainOut)
++    set(GN_TOOLCHAIN ${name})
++    get_gn_arch(GN_CPU ${cpuType})
++    get_gn_arch(GN_V8_CPU ${v8CpuType})
++    configure_file(${toolchainIn} ${toolchainOut}/BUILD.gn @ONLY)
++endfunction()
++
++function(create_pkg_config_host_wrapper wrapperName wrapperCmd)
++    file(WRITE ${wrapperName}
++        "#!/bin/sh\n"
++        "unset PKG_CONFIG_LIBDIR\n"
++        "unset PKG_CONFIG_PATH\n"
++        "unset PKG_CONFIG_SYSROOT_DIR\n"
++        "exec ${wrapperCmd} \"$@\""
++    )
++    file(CHMOD ${wrapperName} PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE)
++endfunction()
+diff --git a/configure.cmake b/configure.cmake
+index 53392313..2a8552d7 100644
+--- a/configure.cmake
++++ b/configure.cmake
+@@ -333,9 +333,17 @@ endif()
+ assertTargets(webEngineError webEngineSupport Gui Widgets OpenGL OpenGLWidgets Quick Qml)
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION (LINUX AND NOT CMAKE_CROSSCOMPILING) OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
++   CONDITION LINUX OR (WIN32 AND NOT WIN_ARM_64) OR (MACOS AND NOT MAC_UNIVERSAL)
+    MESSAGE "Build can be done only on Linux, Windows or macOS."
+ )
++if(LINUX AND CMAKE_CROSSCOMPILING)
++   get_gn_arch(testArch ${TEST_architecture_arch})
++   add_check_for_support(webEngineError webEngineSupport
++       MODULE QtWebEngine
++       CONDITION testArch
++       MESSAGE "Cross compiling is not supported for ${TEST_architecture_arch}."
++   )
++endif()
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+    CONDITION NOT QT_FEATURE_static
+diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
+index fd935fe1..40d7fd8e 100644
+--- a/src/core/CMakeLists.txt
++++ b/src/core/CMakeLists.txt
+@@ -24,6 +24,11 @@ find_package(Nodejs 12.0)
+ find_package(PkgConfig)
+ if(PkgConfig_FOUND)
+     pkg_check_modules(XSCRNSAVER xscrnsaver)
++    find_package(PkgConfigHost)
++    if(CMAKE_CROSSCOMPILING)
++        create_pkg_config_host_wrapper("${buildDir}/pkg-config-host_wrapper.sh" "${PKG_CONFIG_HOST_EXECUTABLE}")
++        set(PKG_CONFIG_HOST_EXECUTABLE "${buildDir}/pkg-config-host_wrapper.sh")
++    endif()
+ endif()
+ 
+ get_target_property(qtWebEngineProcessName WebEngineCore QTWEBENGINEPROCESS_NAME)
+@@ -36,6 +41,24 @@ else()
+     set(configs ${CMAKE_BUILD_TYPE})
+ endif()
+ 
++##
++#   TOOLCHAIN SETUP
++##
++
++if(LINUX)
++    if(NOT CMAKE_CROSSCOMPILING) # delivered by hostBuild project
++        configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/host_toolchain)
++        configure_gn_toolchain(v8 ${TEST_architecture_arch} ${TEST_architecture_arch}
++            ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++            ${buildDir}/v8_toolchain)
++    endif()
++    configure_gn_toolchain(target ${TEST_architecture_arch} ${TEST_architecture_arch}
++        ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++        ${buildDir}/target_toolchain)
++endif()
++
+ foreach(config ${configs})
+ 
+ ##
+@@ -250,12 +273,6 @@ foreach(config ${configs})
+     configure_gn_target(${buildGn} ${config}
+         ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.root.gn.in ${buildDir}/${config}/BUILD.gn)
+ 
+-##
+-#   TOOLCHAIN SETUP
+-##
+-
+-    configure_file(${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
+-        ${buildDir}/${config}/toolchain/BUILD.gn @ONLY)
+ 
+ ##
+ #   GN CALL PARAMETERS SETUP
+@@ -419,6 +436,15 @@ foreach(config ${configs})
+         )
+     endif()
+     if(LINUX)
++        get_gn_arch(cpu ${TEST_architecture_arch})
++        if(CMAKE_CROSSCOMPILING)
++            list(APPEND gnArgArg target_cpu="${cpu}")
++        else()
++            list(APPEND gnArgArg host_cpu="${cpu}")
++        endif()
++        if(CMAKE_SYSROOT)
++            list(APPEND gnArgArg target_sysroot="${CMAKE_SYSROOT}")
++        endif()
+         list(APPEND gnArgArg
+             use_cups=false
+             use_gio=false
+@@ -435,11 +461,11 @@ foreach(config ${configs})
+             ozone_platform_external=true
+             ozone_platform="qt"
+             ozone_extra_path="${CMAKE_CURRENT_LIST_DIR}/ozone/ozone_extra.gni"
+-            custom_toolchain="${buildDir}/${config}/toolchain:target"
+-            host_toolchain="${buildDir}/${config}/toolchain:host"
+-            host_cpu="x64"
+-            pkg_config="pkg-config"
+-            host_pkg_config="/usr/bin/pkg-config"
++            custom_toolchain="${buildDir}/target_toolchain:target"
++            host_toolchain="${buildDir}/host_toolchain:host"
++            v8_snapshot_toolchain="${buildDir}/v8_toolchain:v8"
++            pkg_config="${PKG_CONFIG_EXECUTABLE}"
++            host_pkg_config="${PKG_CONFIG_HOST_EXECUTABLE}"
+             use_glib=false
+         )
+         set(systemLibs libjpeg libpng freetype harfbuzz libevent libwebp libxml
+diff --git a/src/core/api/configure.cmake b/src/core/api/configure.cmake
+index 35d28e87..0cf46bf0 100644
+--- a/src/core/api/configure.cmake
++++ b/src/core/api/configure.cmake
+@@ -143,11 +143,11 @@ qt_configure_add_summary_entry(
+     CONDITION UNIX
+ )
+ qt_configure_end_summary_section() # end of "Qt WebEngineCore" section
+-qt_configure_add_report_entry(
+-    TYPE WARNING
+-    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
+-    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
+-)
++#qt_configure_add_report_entry(
++#    TYPE WARNING
++#    MESSAGE "Thumb instruction set is required to build ffmpeg for QtWebEngine."
++#    CONDITION LINUX AND QT_FEATURE_webengine_embedded_build AND NOT QT_FEATURE_webengine_system_ffmpeg AND ( TEST_architecture_arch STREQUAL arm ) AND NOT QT_FEATURE_webengine_arm_thumb
++#)
+ qt_configure_add_report_entry(
+     TYPE WARNING
+     MESSAGE "V8 snapshot cannot be built. Most likely, the 32-bit host compiler does not work. Please make sure you have 32-bit devel environment installed."
+diff --git a/src/core/configure/BUILD.toolchain.gn.in b/src/core/configure/BUILD.toolchain.gn.in
+index e44fa42d..c1bf3845 100644
+--- a/src/core/configure/BUILD.toolchain.gn.in
++++ b/src/core/configure/BUILD.toolchain.gn.in
+@@ -1,6 +1,6 @@
+ import("//build/config/sysroot.gni")
+ import("//build/toolchain/gcc_toolchain.gni")
+-gcc_toolchain("host") {
++gcc_toolchain("@GN_TOOLCHAIN@") {
+   cc = "@CMAKE_C_COMPILER@"
+   cxx = "@CMAKE_CXX_COMPILER@"
+   ld = "@CMAKE_CXX_COMPILER@"
+@@ -9,34 +9,8 @@ gcc_toolchain("host") {
+   extra_cppflags = ""
+   toolchain_args = {
+     current_os = "linux"
+-    current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+-}
+-gcc_toolchain("v8_snapshot") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
+-    v8_current_cpu = "x64"
+-    is_clang = false
+-    use_gold = false
+-  }
+- }
+-gcc_toolchain("target") {
+-  cc = "@CMAKE_C_COMPILER@"
+-  cxx = "@CMAKE_CXX_COMPILER@"
+-  ld = "@CMAKE_CXX_COMPILER@"
+-  ar = "@CMAKE_AR@"
+-  nm = "@CMAKE_NM@"
+-  toolchain_args = {
+-    current_os = "linux"
+-    current_cpu = "x64"
++    current_cpu = "@GN_CPU@"
++    v8_current_cpu = "@GN_V8_CPU@"
+     is_clang = false
+     use_gold = false
+   }
+diff --git a/src/core/configure/CMakeLists.txt b/src/core/configure/CMakeLists.txt
+new file mode 100644
+index 00000000..0ae4b4b4
+--- /dev/null
++++ b/src/core/configure/CMakeLists.txt
+@@ -0,0 +1,35 @@
++cmake_minimum_required(VERSION 3.19)
++
++if(NOT DEFINED WEBENGINE_ROOT_SOURCE_DIR)
++    get_filename_component(WEBENGINE_ROOT_SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/../../.." REALPATH)
++endif()
++if (NOT DEFINED WEBENGINE_ROOT_BUILD_DIR)
++    get_filename_component(WEBENGINE_ROOT_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}/../../.." REALPATH)
++endif()
++
++include(${WEBENGINE_ROOT_SOURCE_DIR}/.cmake.conf)
++include(${WEBENGINE_ROOT_SOURCE_DIR}/cmake/Functions.cmake)
++
++set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${WEBENGINE_ROOT_SOURCE_DIR}/cmake")
++
++project(QtWebEngineConfigure
++    VERSION "${QT_REPO_MODULE_VERSION}"
++    LANGUAGES CXX C)
++
++find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals Core)
++
++set(buildDir ${CMAKE_CURRENT_BINARY_DIR})
++configure_gn_toolchain(host ${TEST_architecture_arch} ${TEST_architecture_arch}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/host_toolchain
++)
++install(FILES ${buildDir}/host_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/host_toolchain
++    )
++get_v8_arch(GN_V8_HOST_CPU ${GN_TARGET_CPU})
++configure_gn_toolchain(v8 ${GN_V8_HOST_CPU} ${GN_TARGET_CPU}
++    ${WEBENGINE_ROOT_SOURCE_DIR}/src/core/configure/BUILD.toolchain.gn.in
++    ${buildDir}/v8_toolchain)
++install(FILES ${buildDir}/v8_toolchain/BUILD.gn
++    DESTINATION ${WEBENGINE_ROOT_BUILD_DIR}/src/core/v8_toolchain
++)
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
new file mode 100644
index 000000000000..d4b22c77ce96
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/mojo/public/cpp/platform/named_platform_channel_posix.cc	2021-03-08 10:30:42.504006604 +0100
++++ -	2021-03-08 10:31:27.415366585 +0100
+@@ -8,6 +8,7 @@
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <unistd.h>
++#include <cstring>
+ 
+ #include "base/files/file_util.h"
+ #include "base/files/scoped_file.h"
diff --git a/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
new file mode 100644
index 000000000000..de6d5abb4461
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-Do-not-use-target-C-XX-FLAGS-for-host-cmake.patch
@@ -0,0 +1,26 @@
+From 8eece1b0c72bef7319069703031543ddd0ca87ee Mon Sep 17 00:00:00 2001
+From: John Zimmermann <me@johnnynator.dev>
+Date: Sun, 27 Jun 2021 20:35:15 +0200
+Subject: [PATCH 2/2] Do not use target C{XX}FLAGS for host cmake
+
+Change-Id: Ia66d153fa9f1aff63491f6a1ec7380b8bda1e3c7
+---
+ CMakeLists.txt | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 2a93dca5..2a8e6cfb 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -238,6 +238,8 @@ if(CMAKE_CROSSCOMPILING)
+                    -DWEBENGINE_ROOT_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}
+                    -DWEBENGINE_ROOT_SOURCE_DIR=${WEBENGINE_ROOT_SOURCE_DIR}
+                    -DGN_TARGET_CPU=${TEST_architecture_arch}
++                   -DCMAKE_CXX_FLAGS=$ENV{CXXFLAGS_FOR_BUILD}
++                   -DCMAKE_C_FLAGS=$ENV{CFLAGS_FOR_BUILD}
+     )
+     externalproject_add_stepdependencies(libs install hostBuild)
+ endif()
+-- 
+2.32.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
new file mode 100644
index 000000000000..4a428fe03b37
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
@@ -0,0 +1,11 @@
+--- a/src/core/CMakeLists.txt	2021-06-27 14:24:18.812840134 +0200
++++ b/src/core/CMakeLists.txt	2021-06-27 14:51:46.825108637 +0200
+@@ -299,6 +299,8 @@
+         endif()
+     elseif(${config} STREQUAL "MinSizeRel")
+         list(APPEND gnArgArg is_debug=false symbol_level=0 optimize_for_size=true)
++    elseif(${config} STREQUAL "None")
++        list(APPEND gnArgArg is_debug=false symbol_level=0)
+     endif()
+ 
+     list(APPEND gnArgArg
diff --git a/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
new file mode 100644
index 000000000000..da4160b21bd3
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
@@ -0,0 +1,26 @@
+From 9001c54d6b974449174a8cee8f3f5d78a9bd6c9e Mon Sep 17 00:00:00 2001
+From: Felix Janda <felix.janda@posteo.de>
+Date: Sun, 1 Feb 2015 14:26:52 +0100
+Subject: [PATCH 3/6] include <sys/reg.h> to get __WORDSIZE on musl libc
+
+---
+ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/common/linux/elf_core_dump.h b/src/common/linux/elf_core_dump.h
+index d03c7a8..02eb391 100644
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
+@@ -36,6 +36,9 @@
+ #include <elf.h>
+ #include <link.h>
+ #include <stddef.h>
++#ifndef __GLIBC__
++#include <sys/reg.h>
++#endif
+ 
+ #include "common/memory_range.h"
+ 
+-- 
+2.0.5
+
diff --git a/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
new file mode 100644
index 000000000000..de32a3dab95c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
@@ -0,0 +1,103 @@
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+@@ -6,6 +6,7 @@
+ 
+ #include <malloc.h>
+ 
++#if defined(__GLIBC__)
+ // This translation unit defines a default dispatch for the allocator shim which
+ // routes allocations to libc functions.
+ // The code here is strongly inspired from tcmalloc's libc_override_glibc.h.
+@@ -73,3 +74,92 @@ const AllocatorDispatch AllocatorDispatch::default_dispatch = {
+     nullptr,               /* free_definite_size_function */
+     nullptr,               /* next */
+ };
++
++#else // defined(__GLIBC__)
++
++#include <dlfcn.h>
++
++extern "C" {
++// Declare function pointers to the memory functions
++typedef void* (*t_libc_malloc)(size_t size);
++typedef void* (*t_libc_calloc)(size_t n, size_t size);
++typedef void* (*t_libc_realloc)(void* address, size_t size);
++typedef void* (*t_libc_memalign)(size_t alignment, size_t size);
++typedef void (*t_libc_free)(void* ptr);
++typedef size_t (*t_libc_malloc_usable_size)(void* ptr);
++
++// Static instances of pointers to libc.so dl symbols
++static t_libc_malloc libc_malloc = NULL;
++static t_libc_calloc libc_calloc = NULL;
++static t_libc_realloc libc_realloc = NULL;
++static t_libc_memalign libc_memalign = NULL;
++static t_libc_free libc_free = NULL;
++static t_libc_malloc_usable_size libc_malloc_usable_size = NULL;
++
++// resolve the symbols in libc.so
++void musl_libc_memory_init(void)
++{
++  libc_malloc = (t_libc_malloc) dlsym(RTLD_NEXT, "malloc");
++  libc_calloc = (t_libc_calloc) dlsym(RTLD_NEXT, "calloc");
++  libc_realloc = (t_libc_realloc) dlsym(RTLD_NEXT, "realloc");
++  libc_memalign = (t_libc_memalign) dlsym(RTLD_NEXT, "memalign");
++  libc_free = (t_libc_free) dlsym(RTLD_NEXT, "free");
++  libc_malloc_usable_size = (t_libc_malloc_usable_size) dlsym(RTLD_NEXT, "malloc_usable_size");
++}
++}  // extern "C"
++
++namespace {
++
++using base::allocator::AllocatorDispatch;
++
++void* MuslMalloc(const AllocatorDispatch*, size_t size, void* context) {
++  if (!libc_malloc)
++    musl_libc_memory_init();
++  return (*libc_malloc)(size);
++}
++
++void* MuslCalloc(const AllocatorDispatch*, size_t n, size_t size, void* context) {
++  if (!libc_calloc)
++    musl_libc_memory_init();
++  return (*libc_calloc)(n, size);
++}
++
++void* MuslRealloc(const AllocatorDispatch*, void* address, size_t size, void* context) {
++  if (!libc_realloc)
++    musl_libc_memory_init();
++  return (*libc_realloc)(address, size);
++}
++
++void* MuslMemalign(const AllocatorDispatch*, size_t alignment, size_t size, void* context) {
++  if (!libc_memalign)
++    musl_libc_memory_init();
++  return (*libc_memalign)(alignment, size);
++}
++
++void MuslFree(const AllocatorDispatch*, void* address, void* context) {
++  if (!libc_free)
++    musl_libc_memory_init();
++  (*libc_free)(address);
++}
++
++size_t MuslGetSizeEstimate(const AllocatorDispatch*, void* address, void* context) {
++  // TODO(siggi, primiano): malloc_usable_size may need redirection in the
++  //     presence of interposing shims that divert allocations.
++  if (!libc_malloc_usable_size)
++    musl_libc_memory_init();
++  return (*libc_malloc_usable_size)(address);
++}
++
++}  // namespace
++
++const AllocatorDispatch AllocatorDispatch::default_dispatch = {
++    &MuslMalloc,           /* alloc_function */
++    &MuslCalloc,           /* alloc_zero_initialized_function */
++    &MuslMemalign,         /* alloc_aligned_function */
++    &MuslRealloc,          /* realloc_function */
++    &MuslFree,             /* free_function */
++    &MuslGetSizeEstimate,  /* get_size_estimate_function */
++    nullptr,               /* next */
++};
++
++#endif
diff --git a/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
new file mode 100644
index 000000000000..36900f907833
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
@@ -0,0 +1,39 @@
+--- qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2017-11-28 14:06:53.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2018-01-27 20:13:26.960932805 +0100
+@@ -243,7 +243,7 @@
+   allocated_objects_count = main_heap_info.block_count;
+ #elif defined(OS_FUCHSIA)
+ // TODO(fuchsia): Port, see https://crbug.com/706592.
+-#else
++#elif defined(__GLIBC__)
+   struct mallinfo info = mallinfo();
+   DCHECK_GE(info.arena + info.hblkhd, info.uordblks);
+ 
+@@ -255,6 +255,8 @@
+ 
+   // Total allocated space is given by |uordblks|.
+   allocated_objects_size = info.uordblks;
++#else
++// musl libc does not support mallinfo()
+ #endif
+ 
+   MemoryAllocatorDump* outer_dump = pmd->CreateAllocatorDump("malloc");
+--- qtwebengine/src/3rdparty/chromium/base/process/process_metrics_posix.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:03:38.579424720 +0100
+@@ -119,14 +119,14 @@
+   malloc_statistics_t stats = {0};
+   malloc_zone_statistics(nullptr, &stats);
+   return stats.size_in_use;
+-#elif defined(OS_LINUX) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
++#elif (defined(OS_LINUX) && defined(__GLIBC__)) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
+   struct mallinfo minfo = mallinfo();
+ #if BUILDFLAG(USE_TCMALLOC)
+   return minfo.uordblks;
+ #else
+   return minfo.hblkhd + minfo.arena;
+ #endif
+-#elif defined(OS_FUCHSIA)
++#else //if defined(OS_FUCHSIA) // also musl doesn't do this.
+   // TODO(fuchsia): Not currently exposed. https://crbug.com/735087.
+   return 0;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
new file mode 100644
index 000000000000..52db3b9ebf46
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0005-musl-off_t.patch
@@ -0,0 +1,10 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-05-26 14:58:54.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/ots/include/opentype-sanitiser.h	2016-10-01 14:31:30.885000000 +0200
+@@ -21,6 +21,7 @@
+ #define htons(x) _byteswap_ushort (x)
+ #else
+ #include <arpa/inet.h>
++#include <sys/types.h>
+ #include <stdint.h>
+ #endif
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
new file mode 100644
index 000000000000..00017bba0172
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
@@ -0,0 +1,18 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:26.639964100 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:11.611964995 +0200
+@@ -1794,6 +1794,15 @@
+ /* End of s390/s390x definitions                                             */
+ #endif
+ 
++#ifndef __GLIBC__
++  /* For Musl libc pread/pread is the same as pread64/pwrite64 */
++#ifndef __NR_pread
++#define __NR_pread              __NR_pread64
++#endif
++#ifndef __NR_pwrite
++#define __NR_pwrite             __NR_pwrite64
++#endif
++#endif /* ifndef __GLIBC__ */
+ 
+ /* After forking, we must make sure to only call system calls.               */
+ #if defined(__BOUNDED_POINTERS__)
diff --git a/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
new file mode 100644
index 000000000000..edfceb79f30a
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
@@ -0,0 +1,26 @@
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-12-20 03:33:11.749059656 +0100
+@@ -9,6 +9,10 @@
+ 
+ #include <resolv.h>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/lazy_instance.h"
+ #include "base/logging.h"
+ #include "base/macros.h"
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-12-20 03:40:07.671953098 +0100
+@@ -6,6 +6,10 @@
+ 
+ #include <string>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/bind.h"
+ #include "base/files/file.h"
+ #include "base/files/file_path.h"
diff --git a/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
new file mode 100644
index 000000000000..fe760be16664
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
@@ -0,0 +1,18 @@
+There's a subtle difference in the internal name of siginfo_t fields
+between glibc and musl. The structure itself is equivalent, so it
+should suffice to add a macro to rename the field.
+
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-02-17 05:57:43.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-06-03 08:20:25.032716427 +0200
+@@ -22,6 +22,11 @@
+ #include "sandbox/linux/services/android_ucontext.h"
+ #endif
+
++// musl libc defines siginfo_t __si_fields instead of _sifields
++#if !defined(__GLIBC__)
++#define _sifields __si_fields
++#endif
++
+ namespace {
+
+ const int kCapacityIncrement = 20;
diff --git a/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
new file mode 100644
index 000000000000..a9f8ab6c252c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
@@ -0,0 +1,20 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:08:43.586475349 +0100
++++ qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:18:22.274505203 +0100
+@@ -28,7 +28,7 @@
+ // FIXME: On Mac OSX and Linux, this method cannot estimate stack size
+ // correctly for the main thread.
+ 
+-#elif defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#elif defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   // pthread_getattr_np() can fail if the thread is not invoked by
+   // pthread_create() (e.g., the main thread of blink_unittests).
+@@ -96,7 +96,7 @@
+ }
+ 
+ void* GetStackStart() {
+-#if defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#if defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   pthread_attr_t attr;
+   int error;
diff --git a/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
new file mode 100644
index 000000000000..d3de1e41183d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
@@ -0,0 +1,71 @@
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-09-13 19:53:53.453780253 +0200
+@@ -129,7 +129,7 @@
+ // CLONE_VM, nor CLONE_THREAD, which includes all fork() implementations.
+ ResultExpr RestrictCloneToThreadsAndEPERMFork() {
+   const Arg<unsigned long> flags(0);
+-
++#if defined(__GLIBC__)
+   // TODO(mdempsky): Extend DSL to support (flags & ~mask1) == mask2.
+   const uint64_t kAndroidCloneMask = CLONE_VM | CLONE_FS | CLONE_FILES |
+                                      CLONE_SIGHAND | CLONE_THREAD |
+@@ -148,6 +148,17 @@
+   return If(IsAndroid() ? android_test : glibc_test, Allow())
+       .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
+       .Else(CrashSIGSYSClone());
++#else
++  const int required = CLONE_VM | CLONE_FS | CLONE_FILES | CLONE_SIGHAND |
++                       CLONE_THREAD | CLONE_SYSVSEM;
++  const int safe = CLONE_SETTLS | CLONE_PARENT_SETTID | CLONE_CHILD_CLEARTID |
++                   CLONE_DETACHED;
++  const BoolExpr thread_clone_ok = (flags&~safe)==required;
++
++  return If(thread_clone_ok, Allow())
++      .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
++      .Else(CrashSIGSYSClone());
++#endif
+ }
+ 
+ ResultExpr RestrictPrctl() {
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-09-13 19:56:31.779773940 +0200
+@@ -375,6 +375,9 @@
+ #if defined(__i386__)
+     case __NR_waitpid:
+ #endif
++#if !defined(__GLIBC__)
++    case __NR_set_tid_address:
++#endif
+       return true;
+     case __NR_clone:  // Should be parameter-restricted.
+     case __NR_setns:  // Privileged.
+@@ -387,7 +390,9 @@
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
+     case __NR_set_thread_area:
+ #endif
++#if defined(__GLIBC__)
+     case __NR_set_tid_address:
++#endif
+     case __NR_unshare:
+ #if !defined(__mips__) && !defined(__aarch64__)
+     case __NR_vfork:
+@@ -496,6 +501,9 @@
+     case __NR_mlock:
+     case __NR_munlock:
+     case __NR_munmap:
++#if !defined(__GLIBC__)
++    case __NR_mremap:
++#endif
+       return true;
+     case __NR_madvise:
+     case __NR_mincore:
+@@ -511,7 +519,9 @@
+     case __NR_modify_ldt:
+ #endif
+     case __NR_mprotect:
++#if defined(__GLIBC__)
+     case __NR_mremap:
++#endif
+     case __NR_msync:
+     case __NR_munlockall:
+     case __NR_readahead:
diff --git a/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
new file mode 100644
index 000000000000..7bf5a22fba71
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
@@ -0,0 +1,15 @@
+--- qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc.orig	2018-09-19 18:05:15.523923703 +0200
++++ qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc	2018-09-19 18:08:05.150932454 +0200
+@@ -173,7 +173,12 @@
+ 
+ size_t GetDefaultThreadStackSize(const pthread_attr_t& attributes) {
+ #if !defined(THREAD_SANITIZER)
++#if defined(__GLIBC__)
+   return 0;
++#else // defined(__GLIBC__)
++  // For Musl libc try with a default stack size of 2 MiB
++  return 2 * 1024 * 1024;
++#endif // !defined(__GLIBC__)
+ #else
+   // ThreadSanitizer bloats the stack heavily. Evidence has been that the
+   // default stack size isn't enough for some browser tests.
diff --git a/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
new file mode 100644
index 000000000000..140742f72c25
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
@@ -0,0 +1,30 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-11-22 00:41:58.522477559 +0100
+@@ -38,7 +38,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_ptrace_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <errno.h>
+ #include <fcntl.h>
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-11-22 00:49:39.533492245 +0100
+@@ -32,7 +32,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_core_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <elf.h>
+ #include <stdio.h>
diff --git a/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
new file mode 100644
index 000000000000..f6c3aadb8421
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
@@ -0,0 +1,14 @@
+--- a/configure.cmake	2021-06-21 23:31:04.000000000 +0200
++++ -	2021-06-27 16:16:32.873528917 +0200
+@@ -373,11 +373,6 @@
+ )
+ add_check_for_support(webEngineError webEngineSupport
+    MODULE QtWebEngine
+-   CONDITION NOT LINUX OR TEST_glibc
+-   MESSAGE "A suitable version >= 2.17 of glibc is required."
+-)
+-add_check_for_support(webEngineError webEngineSupport
+-   MODULE QtWebEngine
+    CONDITION NOT LINUX OR TEST_khr
+    MESSAGE "Build requires Khronos development headers for build - see mesa/libegl1-mesa-dev"
+ )
diff --git a/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
new file mode 100644
index 000000000000..608dd0b4e078
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
@@ -0,0 +1,106 @@
+--- qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc.orig	2019-04-09 09:31:16.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc	2019-05-06 23:16:13.245502467 +0200
+@@ -27,7 +27,7 @@
+ #if !defined(USE_SYMBOLIZE)
+ #include <cxxabi.h>
+ #endif
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ #include <execinfo.h>
+ #endif
+ 
+@@ -86,7 +86,7 @@
+   // Note: code in this function is NOT async-signal safe (std::string uses
+   // malloc internally).
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   std::string::size_type search_from = 0;
+   while (search_from < text->size()) {
+     // Look for the start of a mangled symbol, from search_from.
+@@ -121,7 +121,7 @@
+       search_from = mangled_start + 2;
+     }
+   }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ }
+ #endif  // !defined(USE_SYMBOLIZE)
+ 
+@@ -133,7 +133,7 @@
+   virtual ~BacktraceOutputHandler() = default;
+ };
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void OutputPointer(void* pointer, BacktraceOutputHandler* handler) {
+   // This should be more than enough to store a 64-bit number in hex:
+   // 16 hex digits + 1 for null-terminator.
+@@ -216,7 +216,7 @@
+   }
+ #endif  // defined(USE_SYMBOLIZE)
+ }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ 
+ void PrintToStderr(const char* output) {
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+@@ -812,7 +812,7 @@
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+   // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   // Though the backtrace API man page does not list any possible negative
+   // return values, we take no chance.
+   return base::saturated_cast<size_t>(backtrace(trace, count));
+@@ -825,13 +825,13 @@
+ // NOTE: This code MUST be async-signal safe (it's used by in-process
+ // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   PrintBacktraceOutputHandler handler;
+   ProcessBacktrace(trace_, count_, prefix_string, &handler);
+ #endif
+ }
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void StackTrace::OutputToStreamWithPrefix(std::ostream* os,
+                                           const char* prefix_string) const {
+   StreamBacktraceOutputHandler handler(os);
+--- qtwebengine/src/3rdparty/chromium/base/debug/stack_trace.cc	2019-04-09 09:31:16.000000000 +0200
++++ -	2019-05-06 23:18:14.923566992 +0200
+@@ -233,7 +233,7 @@
+ }
+ std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
+   std::stringstream stream;
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(&stream, prefix_string);
+ #endif
+   return stream.str();
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2017-11-28 14:06:53.000000000 +0100
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2018-01-27 22:46:34.970406807 +0100
+@@ -546,7 +546,7 @@
+ 
+ LogMessage::~LogMessage() {
+   size_t stack_start = stream_.tellp();
+-#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && !defined(__UCLIBC__) && \
++#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && defined(__GLIBC__) && \
+     !defined(OS_AIX)
+   if (severity_ == LOG_FATAL && !base::debug::BeingDebugged()) {
+     // Include a stack trace on a fatal, unless a debugger is attached.
+--- a/src/3rdparty/chromium/base/debug/stack_trace.cc	2021-06-27 18:17:06.834705848 +0200
++++ -	2021-06-27 18:27:53.014102803 +0200
+@@ -217,7 +217,9 @@
+ }
+ 
+ void StackTrace::OutputToStream(std::ostream* os) const {
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(os, nullptr);
++#endif
+ }
+ 
+ std::string StackTrace::ToString() const {
diff --git a/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
new file mode 100644
index 000000000000..496753bef30f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
@@ -0,0 +1,26 @@
+diff --git a/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc b/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+index 02bf49b..05ee182 100644
+--- qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
++++ qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+@@ -13,7 +13,7 @@ namespace pp {
+ namespace {
+ 
+ // Use 2MB default stack size for Native Client, otherwise use system default.
+-#if defined(__native_client__)
++#if defined(__native_client__) || !defined(__GLIBC__)
+ const size_t kDefaultStackSize = 2 * 1024 * 1024;
+ #else
+ const size_t kDefaultStackSize = 0;
+diff --git a/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc b/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+index cf7f3ec..e06a5ce 100644
+--- qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
++++ qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+@@ -761,7 +761,7 @@ void Thread::Start() {
+ #if V8_OS_MACOSX
+     // Default on Mac OS X is 512kB -- bump up to 1MB
+     stack_size = 1 * 1024 * 1024;
+-#elif V8_OS_AIX
++#elif V8_OS_AIX || !defined(__GLIBC__)
+     // Default on AIX is 96kB -- bump up to 2MB
+     stack_size = 2 * 1024 * 1024;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
new file mode 100644
index 000000000000..b73971f24324
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
@@ -0,0 +1,60 @@
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
+@@ -1063,4 +1063,8 @@
+ #define __NR_memfd_create 279
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 283
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_ARM64_LINUX_SYSCALLS_H_
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,10 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier (__NR_SYSCALL_BASE+389)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
+@@ -1422,5 +1422,9 @@
+ #define __NR_memfd_create 356
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 375
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_32_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
+@@ -1290,5 +1290,9 @@
+ #define __NR_memfd_create 319
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 324
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -370,6 +370,7 @@
+   switch (sysno) {
+     case __NR_exit:
+     case __NR_exit_group:
++    case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+ #if defined(__i386__)
diff --git a/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
new file mode 100644
index 000000000000..75481a2889f4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
@@ -0,0 +1,14 @@
+--- qtwebengine-everywhere-src-5.14.0-beta2/src/3rdparty/chromium/net/socket/udp_socket_posix.cc	2019-10-08 08:27:43.000000000 +0200
++++ -	2019-11-11 22:41:46.699068889 +0100
+@@ -1191,7 +1191,11 @@
+     msg_iov->push_back({const_cast<char*>(buffer->data()), buffer->length()});
+   msgvec->reserve(buffers.size());
+   for (size_t j = 0; j < buffers.size(); j++)
++#if defined(__GLIBC__)
+     msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, nullptr, 0, 0}, 0});
++#else
++    msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, 0, 0, 0}, 0});
++#endif
+   int result = HANDLE_EINTR(Sendmmsg(fd, &msgvec[0], buffers.size(), 0));
+   SendResult send_result(0, 0, std::move(buffers));
+   if (result < 0) {
diff --git a/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
new file mode 100644
index 000000000000..d8c6aa15cf66
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
@@ -0,0 +1,26 @@
+Allow SYS_sched_getparam and SYS_sched_getscheduler
+musl uses them for pthread_getschedparam()
+
+source: https://git.alpinelinux.org/aports/commit/community/chromium?id=54af9f8ac24f52d382c5758e2445bf0206eff40e
+
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:13:44.992079145 +0100
+@@ -93,11 +93,18 @@
+     case __NR_sysinfo:
+     case __NR_times:
+     case __NR_uname:
++#if !defined(__GLIBC__)
++    case __NR_sched_getparam:
++    case __NR_sched_getscheduler:
++    case __NR_sched_setscheduler:
++#endif
+       return Allow();
+     case __NR_sched_getaffinity:
++#if defined(__GLIBC__)
+     case __NR_sched_getparam:
+     case __NR_sched_getscheduler:
+     case __NR_sched_setscheduler:
++#endif
+       return RestrictSchedTarget(GetPolicyPid(), sysno);
+     case __NR_prlimit64:
+       // See crbug.com/662450 and setrlimit comment above.
diff --git a/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
new file mode 100644
index 000000000000..893ed2d41bb4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
@@ -0,0 +1,11 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/nasm/nasmlib/realpath.c	2019-09-23 14:24:20.000000000 +0200
++++ -	2019-10-11 06:27:28.450329986 +0200
+@@ -57,7 +57,7 @@
+  */
+ char *nasm_realpath(const char *rel_path)
+ {
+-    char *rp = canonicalize_file_name(rel_path);
++    char *rp = realpath(rel_path, NULL);
+     return rp ? rp : nasm_strdup(rel_path);
+ }
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
new file mode 100644
index 000000000000..b87766825063
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
@@ -0,0 +1,49 @@
+From 463f1234c57a36e78ff666bd55094a9d4e68f296 Mon Sep 17 00:00:00 2001
+From: q66 <daniel@octaforge.org>
+Date: Sat, 18 Jan 2020 23:52:55 +0100
+Subject: [PATCH 1/3] Enable ppc64 builds
+
+---
+ configure.pri                  | 1 +
+ mkspecs/features/functions.prf | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/configure.pri b/configure.pri
+index 3a144e3f8..cabe8b24a 100644
+--- a/configure.pri	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:18:43.124754796 +0100
+@@ -144,6 +144,7 @@
+     contains(QT_ARCH, "arm")|contains(QT_ARCH, "arm64"): return(true)
+     contains(QT_ARCH, "mips"): return(true)
+     contains(QT_ARCH, "mips64"): return(true)
++    contains(QT_ARCH, "power64"): return(true)
+     qtLog("Architecture not supported.")
+     return(false)
+ }
+diff --git a/mkspecs/features/functions.prf b/mkspecs/features/functions.prf
+index 512e2523b..e31123654 100644
+--- a/mkspecs/features/functions.prf	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:19:21.345036293 +0100
+@@ -107,6 +107,7 @@
+     contains(qtArch, "mips"): return(mipsel)
+     contains(qtArch, "mips64"): return(mips64el)
+     contains(qtArch, "mips64el"): return(mips64el)
++    contains(qtArch, "power64"): return(ppc64)
+     return(unknown)
+ }
+ 
+--- a/cmake/Functions.cmake	2021-06-27 21:30:47.236998844 +0200
++++ -	2021-06-27 21:33:50.091794753 +0200
+@@ -362,6 +362,8 @@
+       set(${result} "mipsel" PARENT_SCOPE)
+    elseif("${arch}" STREQUAL "mipsel64")
+       set(${result} "mips64el" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "power64")
++      set(${result} "ppc64" PARENT_SCOPE)
+    else()
+       message(DEBUG "Unsupported achitecture: ${arch}")
+    endif()
+
+-- 
+2.26.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch b/srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch
new file mode 100644
index 000000000000..40f2185bd4c5
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0090-qtwebengine-ppc64.patch
@@ -0,0 +1,3604 @@
+diff --git a/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn b/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn
+index 9c92012ce..a4a5cd86d 100644
+--- a/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn
++++ b/src/3rdparty/chromium/chrome/installer/linux/BUILD.gn
+@@ -65,8 +65,6 @@ packaging_files = packaging_files_binaries + [
+                     "$root_out_dir/xdg-mime",
+                     "$root_out_dir/xdg-settings",
+                     "$root_out_dir/locales/en-US.pak",
+-                    "$root_out_dir/MEIPreload/manifest.json",
+-                    "$root_out_dir/MEIPreload/preloaded_data.pb",
+                   ]
+ 
+ action_foreach("calculate_deb_dependencies") {
+@@ -331,7 +329,6 @@ group("installer_deps") {
+     ":theme_files",
+     "//chrome",
+     "//chrome:packed_resources",
+-    "//chrome/browser/resources/media/mei_preload:component",
+     "//sandbox/linux:chrome_sandbox",
+     "//third_party/crashpad/crashpad/handler:crashpad_handler",
+   ]
+diff --git a/src/3rdparty/chromium/sandbox/features.gni b/src/3rdparty/chromium/sandbox/features.gni
+index 09280d35f..42514157f 100644
+--- a/src/3rdparty/chromium/sandbox/features.gni
++++ b/src/3rdparty/chromium/sandbox/features.gni
+@@ -11,6 +11,7 @@ import("//build/config/nacl/config.gni")
+ use_seccomp_bpf = (is_linux || is_android) &&
+                   (current_cpu == "x86" || current_cpu == "x64" ||
+                    current_cpu == "arm" || current_cpu == "arm64" ||
+-                   current_cpu == "mipsel" || current_cpu == "mips64el")
++                   current_cpu == "mipsel" || current_cpu == "mips64el" ||
++                   current_cpu == "ppc64")
+ 
+ use_seccomp_bpf = use_seccomp_bpf || is_nacl_nonsfi
+diff --git a/src/3rdparty/chromium/sandbox/linux/BUILD.gn b/src/3rdparty/chromium/sandbox/linux/BUILD.gn
+index c27351f9a..9141e1239 100644
+--- a/src/3rdparty/chromium/sandbox/linux/BUILD.gn
++++ b/src/3rdparty/chromium/sandbox/linux/BUILD.gn
+@@ -407,6 +407,8 @@ component("sandbox_services") {
+ 
+ source_set("sandbox_services_headers") {
+   sources = [
++    "system_headers/ppc64_linux_syscalls.h",
++    "system_headers/ppc64_linux_ucontext.h",
+     "system_headers/arm64_linux_syscalls.h",
+     "system_headers/arm_linux_syscalls.h",
+     "system_headers/arm_linux_ucontext.h",
+diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
+index 313511f22..0ca3a326f 100644
+--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
++++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
+@@ -56,6 +56,13 @@
+ #define MAX_PUBLIC_SYSCALL __NR_syscalls
+ #define MAX_SYSCALL MAX_PUBLIC_SYSCALL
+ 
++#elif defined(__powerpc64__)
++
++#include <asm/unistd.h>
++#define MIN_SYSCALL 0u
++#define MAX_PUBLIC_SYSCALL 386u
++#define MAX_SYSCALL MAX_PUBLIC_SYSCALL
++
+ #else
+ #error "Unsupported architecture"
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+index 1a407b952..a6aec544e 100644
+--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
++++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+@@ -16,6 +16,9 @@
+ #if defined(__mips__)
+ // sys/user.h in eglibc misses size_t definition
+ #include <stddef.h>
++#elif defined(__powerpc64__)
++// Manually define greg_t on ppc64
++typedef unsigned long long greg_t;
+ #endif
+ #endif
+ 
+@@ -346,6 +349,51 @@ struct regs_struct {
+ #define SECCOMP_PT_PARM4(_regs) (_regs).regs[3]
+ #define SECCOMP_PT_PARM5(_regs) (_regs).regs[4]
+ #define SECCOMP_PT_PARM6(_regs) (_regs).regs[5]
++
++#elif defined(__powerpc64__)
++#include <asm/ptrace.h>
++
++typedef struct pt_regs regs_struct;
++
++#ifdef ARCH_CPU_LITTLE_ENDIAN
++#define SECCOMP_ARCH AUDIT_ARCH_PPC64LE
++#else
++#define SECCOMP_ARCH AUDIT_ARCH_PPC64
++#endif
++
++#define SECCOMP_REG(_ctx, _reg) ((_ctx)->uc_mcontext.regs->gpr[_reg])
++
++#define SECCOMP_RESULT(_ctx) SECCOMP_REG(_ctx, 3)
++#define SECCOMP_SYSCALL(_ctx) SECCOMP_REG(_ctx, 0)
++#define SECCOMP_IP(_ctx) (_ctx)->uc_mcontext.regs->nip
++#define SECCOMP_PARM1(_ctx) SECCOMP_REG(_ctx, 3)
++#define SECCOMP_PARM2(_ctx) SECCOMP_REG(_ctx, 4)
++#define SECCOMP_PARM3(_ctx) SECCOMP_REG(_ctx, 5)
++#define SECCOMP_PARM4(_ctx) SECCOMP_REG(_ctx, 6)
++#define SECCOMP_PARM5(_ctx) SECCOMP_REG(_ctx, 7)
++#define SECCOMP_PARM6(_ctx) SECCOMP_REG(_ctx, 8)
++
++#define SECCOMP_NR_IDX (offsetof(struct arch_seccomp_data, nr))
++#define SECCOMP_ARCH_IDX (offsetof(struct arch_seccomp_data, arch))
++#define SECCOMP_IP_MSB_IDX \
++  (offsetof(struct arch_seccomp_data, instruction_pointer) + 4)
++#define SECCOMP_IP_LSB_IDX \
++  (offsetof(struct arch_seccomp_data, instruction_pointer) + 0)
++#define SECCOMP_ARG_MSB_IDX(nr) \
++  (offsetof(struct arch_seccomp_data, args) + 8 * (nr) + 4)
++#define SECCOMP_ARG_LSB_IDX(nr) \
++  (offsetof(struct arch_seccomp_data, args) + 8 * (nr) + 0)
++
++#define SECCOMP_PT_RESULT(_regs) (_regs).gpr[3]
++#define SECCOMP_PT_SYSCALL(_regs) (_regs).gpr[0]
++#define SECCOMP_PT_IP(_regs) (_regs).nip
++#define SECCOMP_PT_PARM1(_regs) (_regs).gpr[3]
++#define SECCOMP_PT_PARM2(_regs) (_regs).gpr[4]
++#define SECCOMP_PT_PARM3(_regs) (_regs).gpr[5]
++#define SECCOMP_PT_PARM4(_regs) (_regs).gpr[6]
++#define SECCOMP_PT_PARM5(_regs) (_regs).gpr[7]
++#define SECCOMP_PT_PARM6(_regs) (_regs).gpr[8]
++
+ #else
+ #error Unsupported target platform
+ 
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+index 712f9699a..55f062817 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -88,7 +88,8 @@ bool IsBaselinePolicyWatched(int sysno) {
+          SyscallSets::IsPrctl(sysno) ||
+          SyscallSets::IsProcessGroupOrSession(sysno) ||
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+          SyscallSets::IsSocketCall(sysno) ||
+ #endif
+ #if defined(__arm__)
+@@ -210,7 +211,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno,
+   }
+ 
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+   if (sysno == __NR_mmap)
+     return RestrictMmapFlags();
+ #endif
+@@ -228,7 +229,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno,
+     return RestrictPrctl();
+ 
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+   if (sysno == __NR_socketpair) {
+     // Only allow AF_UNIX, PF_UNIX. Crash if anything else is seen.
+     static_assert(AF_UNIX == PF_UNIX,
+@@ -268,7 +269,8 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno,
+   }
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   if (SyscallSets::IsSocketCall(sysno))
+     return RestrictSocketcallCommand();
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc
+index fc36187c9..1affc9189 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc
+@@ -291,8 +291,10 @@ TEST_BASELINE_SIGSYS(__NR_timer_create)
+ #if !defined(__aarch64__)
+ TEST_BASELINE_SIGSYS(__NR_eventfd)
+ TEST_BASELINE_SIGSYS(__NR_inotify_init)
++#if !defined(__powerpc64__)
+ TEST_BASELINE_SIGSYS(__NR_vserver)
+ #endif
++#endif
+ 
+ #if defined(LIBC_GLIBC) && !defined(OS_CHROMEOS)
+ BPF_TEST_C(BaselinePolicy, FutexEINVAL, BaselinePolicy) {
+diff --git sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc
+index f51915edc..ca2f4f106 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc
++++ a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc
+@@ -40,7 +40,8 @@
+ #include <sys/ptrace.h>
+ #if (defined(OS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \
+     !defined(__arm__) && !defined(__aarch64__) &&           \
+-    !defined(PTRACE_GET_THREAD_AREA)
++    !defined(PTRACE_GET_THREAD_AREA) &&			    \
++    !defined(__powerpc64__)
+ // Also include asm/ptrace-abi.h since ptrace.h in older libc (for instance
+ // the one in Ubuntu 16.04 LTS) is missing PTRACE_GET_THREAD_AREA.
+ // asm/ptrace-abi.h doesn't exist on arm32 and PTRACE_GET_THREAD_AREA isn't
+@@ -49,6 +50,11 @@
+ #endif
+ #endif  // !OS_NACL_NONSFI
+ 
++// On PPC64, TCGETS is defined in terms of struct termios, so we must include termios.h
++#ifdef __powerpc64__
++#include <termios.h>
++#endif
++
+ #if defined(OS_ANDROID)
+ 
+ #if !defined(F_DUPFD_CLOEXEC)
+@@ -98,6 +104,15 @@
+ #endif
+ }
+ 
++inline bool IsArchitecturePPC64() {
++#if defined(__powerpc64__)
++  return true;
++#else
++  return false;
++#endif
++}
++
++
+ // Ubuntu's version of glibc has a race condition in sem_post that can cause
+ // it to call futex(2) with bogus op arguments. To workaround this, we need
+ // to allow those futex(2) calls to fail with EINVAL, instead of crashing the
+@@ -239,6 +254,8 @@
+   uint64_t kOLargeFileFlag = O_LARGEFILE;
+   if (IsArchitectureX86_64() || IsArchitectureI386() || IsArchitectureMips())
+     kOLargeFileFlag = 0100000;
++  else if (IsArchitecturePPC64())
++    kOLargeFileFlag = 0200000;
+ 
+   const Arg<int> cmd(1);
+   const Arg<long> long_arg(2);
+@@ -253,14 +270,23 @@
+               F_SETLKW,
+               F_GETLK,
+               F_DUPFD,
+-              F_DUPFD_CLOEXEC),
+-             Allow())
++              F_DUPFD_CLOEXEC
++#if defined(__powerpc64__)
++// On PPC64, F_SETLK, F_GETLK, F_SETLKW are defined as the 64-bit variants
++// but glibc will sometimes still use the 32-bit versions. Allow both.
++              ,
++              5, /* F_GETLK (32) */
++              6, /* F_SETLK (32) */
++              7  /* F_SETLKW (32) */
++#endif
++              ),
++            Allow())
+       .Case(F_SETFL,
+             If((long_arg & ~kAllowedMask) == 0, Allow()).Else(CrashSIGSYS()))
+       .Default(CrashSIGSYS());
+ }
+ 
+-#if defined(__i386__) || defined(__mips__)
++#if defined(__i386__) || defined(__mips__) || defined(__powerpc64__)
+ ResultExpr RestrictSocketcallCommand() {
+   // Unfortunately, we are unable to restrict the first parameter to
+   // socketpair(2). Whilst initially sounding bad, it's noteworthy that very
+@@ -450,7 +450,7 @@
+ #endif
+   return Switch(request)
+       .CASES((
+-#if !defined(__aarch64__)
++#if !defined(__aarch64__) && !defined(__powerpc64__)
+                  PTRACE_GETREGS, PTRACE_GETFPREGS,
+ #if defined(TRACE_GET_THREAD_AREA)
+                  PTRACE_GET_THREAD_AREA,
+
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h
+index ba4289f05..9a4d5ab2d 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h
+@@ -48,7 +48,7 @@ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictMprotectFlags();
+ // O_NONBLOCK | O_SYNC | O_LARGEFILE | O_CLOEXEC | O_NOATIME.
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictFcntlCommands();
+ 
+-#if defined(__i386__) || defined(__mips__)
++#if defined(__i386__) || defined(__mips__) || defined(__powerpc64__)
+ // Restrict socketcall(2) to only allow socketpair(2), send(2), recv(2),
+ // sendto(2), recvfrom(2), shutdown(2), sendmsg(2) and recvmsg(2).
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictSocketcallCommand();
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+index e16223a5e..8f37dd7dc 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -29,7 +29,8 @@ bool SyscallSets::IsAllowedGettime(int sysno) {
+   switch (sysno) {
+     case __NR_gettimeofday:
+ #if defined(__i386__) || defined(__x86_64__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_time:
+ #endif
+       return true;
+@@ -41,12 +42,14 @@ bool SyscallSets::IsAllowedGettime(int sysno) {
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_ftime:  // Obsolete.
+ #endif
+     case __NR_settimeofday:  // Privileged.
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_stime:
+ #endif
+     default:
+@@ -112,7 +115,7 @@ bool SyscallSets::IsFileSystem(int sysno) {
+     case __NR_faccessat:  // EPERM not a valid errno.
+     case __NR_fchmodat:
+     case __NR_fchownat:  // Should be called chownat ?
+-#if defined(__x86_64__) || defined(__aarch64__)
++#if defined(__x86_64__) || defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_newfstatat:  // fstatat(). EPERM not a valid errno.
+ #elif defined(__i386__) || defined(__arm__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+@@ -131,7 +134,7 @@ bool SyscallSets::IsFileSystem(int sysno) {
+     case __NR_memfd_create:
+     case __NR_mkdirat:
+     case __NR_mknodat:
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_oldlstat:
+     case __NR_oldstat:
+ #endif
+@@ -145,7 +148,8 @@ bool SyscallSets::IsFileSystem(int sysno) {
+ #endif
+     case __NR_statfs:  // EPERM not a valid errno.
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_statfs64:
+ #endif
+     case __NR_symlinkat:
+@@ -155,7 +159,8 @@ bool SyscallSets::IsFileSystem(int sysno) {
+     case __NR_truncate64:
+ #endif
+     case __NR_unlinkat:
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_utime:
+ #endif
+     case __NR_utimensat:  // New.
+@@ -174,7 +179,8 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) {
+ #endif
+       return true;
+ // TODO(jln): these should be denied gracefully as well (moved below).
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_fadvise64:  // EPERM not a valid errno.
+ #endif
+ #if defined(__i386__)
+@@ -187,11 +193,12 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) {
+     case __NR_flock:      // EPERM not a valid errno.
+     case __NR_fstatfs:    // Give information about the whole filesystem.
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_fstatfs64:
+ #endif
+     case __NR_fsync:  // EPERM not a valid errno.
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_oldfstat:
+ #endif
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+@@ -199,6 +206,8 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) {
+     case __NR_sync_file_range:  // EPERM not a valid errno.
+ #elif defined(__arm__)
+     case __NR_arm_sync_file_range:  // EPERM not a valid errno.
++#elif defined(__powerpc64__)
++    case __NR_sync_file_range2: // EPERM not a valid errno.
+ #endif
+     default:
+       return false;
+@@ -224,7 +233,8 @@ bool SyscallSets::IsDeniedFileSystemAccessViaFd(int sysno) {
+ #endif
+     case __NR_getdents64:  // EPERM not a valid errno.
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_readdir:
+ #endif
+       return true;
+@@ -265,7 +275,7 @@ bool SyscallSets::IsGetSimpleId(int sysno) {
+ bool SyscallSets::IsProcessPrivilegeChange(int sysno) {
+   switch (sysno) {
+     case __NR_capset:
+-#if defined(__i386__) || defined(__x86_64__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__)
+     case __NR_ioperm:  // Intel privilege.
+     case __NR_iopl:    // Intel privilege.
+ #endif
+@@ -316,7 +326,8 @@ bool SyscallSets::IsAllowedSignalHandling(int sysno) {
+     case __NR_rt_sigreturn:
+     case __NR_rt_sigtimedwait:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_sigaction:
+     case __NR_sigprocmask:
+     case __NR_sigreturn:
+@@ -332,7 +343,8 @@ bool SyscallSets::IsAllowedSignalHandling(int sysno) {
+ #endif
+     case __NR_signalfd4:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_sigpending:
+     case __NR_sigsuspend:
+ #endif
+@@ -356,7 +368,7 @@ bool SyscallSets::IsAllowedOperationOnFd(int sysno) {
+ #endif
+     case __NR_dup3:
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_shutdown:
+ #endif
+       return true;
+@@ -390,7 +402,7 @@ bool SyscallSets::IsAllowedProcessStartOrDeath(int sysno) {
+     case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_waitpid:
+ #endif
+ #if !defined(__GLIBC__)
+@@ -412,7 +424,7 @@ bool SyscallSets::IsAllowedProcessStartOrDeath(int sysno) {
+     case __NR_set_tid_address:
+ #endif
+     case __NR_unshare:
+-#if !defined(__mips__) && !defined(__aarch64__)
++#if !defined(__mips__) && !defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_vfork:
+ #endif
+     default:
+@@ -461,7 +473,7 @@ bool SyscallSets::IsAllowedGetOrModifySocket(int sysno) {
+       return true;
+     default:
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_socketpair:  // We will want to inspect its argument.
+ #endif
+       return false;
+@@ -471,7 +483,7 @@ bool SyscallSets::IsAllowedGetOrModifySocket(int sysno) {
+ bool SyscallSets::IsDeniedGetOrModifySocket(int sysno) {
+   switch (sysno) {
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_accept:
+     case __NR_accept4:
+     case __NR_bind:
+@@ -486,7 +498,8 @@ bool SyscallSets::IsDeniedGetOrModifySocket(int sysno) {
+ }
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+ // Big multiplexing system call for sockets.
+ bool SyscallSets::IsSocketCall(int sysno) {
+   switch (sysno) {
+@@ -500,7 +513,8 @@ bool SyscallSets::IsSocketCall(int sysno) {
+ }
+ #endif
+ 
+-#if defined(__x86_64__) || defined(__arm__) || defined(__mips__)
++#if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
++    defined(__powerpc64__)
+ bool SyscallSets::IsNetworkSocketInformation(int sysno) {
+   switch (sysno) {
+     case __NR_getpeername:
+@@ -528,7 +542,7 @@ bool SyscallSets::IsAllowedAddressSpaceAccess(int sysno) {
+     case __NR_mincore:
+     case __NR_mlockall:
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_mmap:
+ #endif
+ #if defined(__i386__) || defined(__arm__) || \
+@@ -560,7 +574,8 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) {
+   switch (sysno) {
+     case __NR_lseek:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR__llseek:
+ #endif
+ #if !defined(__aarch64__)
+@@ -572,26 +587,28 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) {
+     case __NR_readv:
+     case __NR_pread64:
+ #if defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_recv:
+ #endif
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_recvfrom:  // Could specify source.
+     case __NR_recvmsg:   // Could specify source.
+ #endif
+-#if defined(__i386__) || defined(__x86_64__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__)
+     case __NR_select:
+ #endif
+-#if defined(__i386__) || defined(__arm__) || defined(__mips__)
++#if defined(__i386__) || defined(__arm__) || defined(__mips__) || defined(__powerpc64__)
+     case __NR__newselect:
+ #endif
+ #if defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_send:
+ #endif
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_sendmsg:  // Could specify destination.
+     case __NR_sendto:   // Could specify destination.
+ #endif
+@@ -648,7 +665,8 @@ bool SyscallSets::IsAllowedBasicScheduler(int sysno) {
+       return true;
+     case __NR_getpriority:
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_nice:
+ #endif
+     case __NR_setpriority:
+@@ -660,7 +678,8 @@ bool SyscallSets::IsAllowedBasicScheduler(int sysno) {
+ bool SyscallSets::IsAdminOperation(int sysno) {
+   switch (sysno) {
+ #if defined(__i386__) || defined(__arm__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_bdflush:
+ #endif
+     case __NR_kexec_load:
+@@ -676,7 +695,8 @@ bool SyscallSets::IsAdminOperation(int sysno) {
+ 
+ bool SyscallSets::IsKernelModule(int sysno) {
+   switch (sysno) {
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_create_module:
+     case __NR_get_kernel_syms:  // Should ENOSYS.
+     case __NR_query_module:
+@@ -709,7 +729,8 @@ bool SyscallSets::IsFsControl(int sysno) {
+     case __NR_swapoff:
+     case __NR_swapon:
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_umount:
+ #endif
+     case __NR_umount2:
+@@ -725,7 +746,7 @@ bool SyscallSets::IsNuma(int sysno) {
+     case __NR_getcpu:
+     case __NR_mbind:
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_migrate_pages:
+ #endif
+     case __NR_move_pages:
+@@ -754,14 +775,15 @@ bool SyscallSets::IsGlobalProcessEnvironment(int sysno) {
+   switch (sysno) {
+     case __NR_acct:  // Privileged.
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_getrlimit:
+ #endif
+-#if defined(__i386__) || defined(__arm__)
++#if defined(__i386__) || defined(__arm__) || defined(__powerpc64__)
+     case __NR_ugetrlimit:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_ulimit:
+ #endif
+     case __NR_getrusage:
+@@ -795,7 +817,7 @@ bool SyscallSets::IsGlobalSystemStatus(int sysno) {
+ #endif
+     case __NR_sysinfo:
+     case __NR_uname:
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__powerpc64__)
+     case __NR_olduname:
+     case __NR_oldolduname:
+ #endif
+@@ -890,7 +912,8 @@ bool SyscallSets::IsSystemVMessageQueue(int sysno) {
+ #endif
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+ // Big system V multiplexing system call.
+ bool SyscallSets::IsSystemVIpc(int sysno) {
+   switch (sysno) {
+@@ -910,7 +933,8 @@ bool SyscallSets::IsAnySystemV(int sysno) {
+   return IsSystemVMessageQueue(sysno) || IsSystemVSemaphores(sysno) ||
+          IsSystemVSharedMemory(sysno);
+ #elif defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   return IsSystemVIpc(sysno);
+ #endif
+ }
+@@ -963,7 +987,8 @@ bool SyscallSets::IsFaNotify(int sysno) {
+ bool SyscallSets::IsTimer(int sysno) {
+   switch (sysno) {
+     case __NR_getitimer:
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_alarm:
+ #endif
+     case __NR_setitimer:
+@@ -1022,18 +1047,22 @@ bool SyscallSets::IsMisc(int sysno) {
+     case __NR_syncfs:
+     case __NR_vhangup:
+ // The system calls below are not implemented.
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_afs_syscall:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_break:
+ #endif
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_getpmsg:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_gtty:
+     case __NR_idle:
+     case __NR_lock:
+@@ -1041,20 +1070,22 @@ bool SyscallSets::IsMisc(int sysno) {
+     case __NR_prof:
+     case __NR_profil:
+ #endif
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \
++    defined(__powerpc64__)
+     case __NR_putpmsg:
+ #endif
+ #if defined(__x86_64__)
+     case __NR_security:
+ #endif
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+     case __NR_stty:
+ #endif
+-#if defined(__x86_64__)
++#if defined(__x86_64__) || defined(__powerpc64__)
+     case __NR_tuxcall:
+ #endif
+-#if !defined(__aarch64__)
++#if !defined(__aarch64__) && !defined(__powerpc64__)
+     case __NR_vserver:
+ #endif
+       return true;
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h
+index 923533ec9..e2bb1db98 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h
+@@ -43,13 +43,14 @@ class SANDBOX_EXPORT SyscallSets {
+   static bool IsDeniedGetOrModifySocket(int sysno);
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   // Big multiplexing system call for sockets.
+   static bool IsSocketCall(int sysno);
+ #endif
+ 
+ #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+   static bool IsNetworkSocketInformation(int sysno);
+ #endif
+ 
+@@ -88,7 +89,8 @@ class SANDBOX_EXPORT SyscallSets {
+ #endif
+ 
+ #if defined(__i386__) || \
+-    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
++    (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \
++    defined(__powerpc64__)
+   // Big system V multiplexing system call.
+   static bool IsSystemVIpc(int sysno);
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+index 34edabd2b..10fa5fd07 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+@@ -16,7 +16,7 @@ namespace sandbox {
+ namespace {
+ 
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \
+-    defined(ARCH_CPU_MIPS_FAMILY)
++    defined(ARCH_CPU_MIPS_FAMILY) || defined (ARCH_CPU_PPC64_FAMILY)
+ // Number that's not currently used by any Linux kernel ABIs.
+ const int kInvalidSyscallNumber = 0x351d3;
+ #else
+@@ -308,12 +308,56 @@ asm(// We need to be able to tell the kernel exactly where we made a
+     // Enter the kernel
+     "svc 0\n"
+     "2:ret\n"
++    ".cfi_endproc\n"
++    ".size SyscallAsm, .-SyscallAsm\n"
++#elif defined(__powerpc64__)
++    ".text\n"
++    ".align 4\n"
++    ".type SyscallAsm @function\n"
++    "SyscallAsm:\n"
++    ".cfi_startproc\n"
++
++    // Check if r3 is negative
++    "cmpdi 3, 0\n"
++    "bgt 2f\n"
++
++    // Load address of 3f into r3 and return
++    "mflr 10\n"
++    "bl 1f\n"
++    "1: mflr 3\n"
++    "mtlr 10\n"
++    "addi 3, 3, 4*13\n"
++    "blr\n"
++
++    // Load arguments from array into r3-8
++    // save param 3 in r10
++    "2:\n"
++    "mr 0, 3\n"
++    "ld 3, 0(4)\n"
++    "ld 5, 16(4)\n"
++    "ld 6, 24(4)\n"
++    "ld 7, 32(4)\n"
++    "ld 8, 40(4)\n"
++    "ld 4, 8(4)\n"
++    "li 9, 0\n"
++
++    // Enter kernel
++    "sc\n"
++
++    // Magic return address
++    "3:\n"
++    // Like MIPS, ppc64 return values are always positive.
++    // Check for error in cr0.SO and negate upon error
++    "bc 4, 3, 4f\n"
++    "neg 3, 3\n"
++    "4: blr\n"
++
+     ".cfi_endproc\n"
+     ".size SyscallAsm, .-SyscallAsm\n"
+ #endif
+     );  // asm
+ 
+-#if defined(__x86_64__)
++#if defined(__x86_64__) || defined(__powerpc64__)
+ extern "C" {
+ intptr_t SyscallAsm(intptr_t nr, const intptr_t args[6]);
+ }
+@@ -427,6 +471,8 @@ intptr_t Syscall::Call(int nr,
+     ret = inout;
+   }
+ 
++#elif defined(__powerpc64__)
++  intptr_t ret = SyscallAsm(nr, args);
+ #else
+ #error "Unimplemented architecture"
+ #endif
+@@ -443,8 +489,18 @@ void Syscall::PutValueInUcontext(intptr_t ret_val, ucontext_t* ctx) {
+     // needs to be changed back.
+     ret_val = -ret_val;
+     SECCOMP_PARM4(ctx) = 1;
+-  } else
++  } else {
+     SECCOMP_PARM4(ctx) = 0;
++  }
++#endif
++#if defined(__powerpc64__)
++  // Same as MIPS, need to invert ret and set error register (cr0.SO)
++  if (ret_val <= -1 && ret_val >= -4095) {
++    ret_val = -ret_val;
++    ctx->uc_mcontext.regs->ccr |= (1 << 28);
++  } else {
++    ctx->uc_mcontext.regs->ccr &= ~(1 << 28);
++  }
+ #endif
+   SECCOMP_RESULT(ctx) = static_cast<greg_t>(ret_val);
+ }
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc
+index 663d9e896..f55e03ed5 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc
+@@ -237,6 +237,20 @@ void Trap::SigSys(int nr, LinuxSigInfo* info, ucontext_t* ctx) {
+       SetIsInSigHandler();
+     }
+ 
++#if defined(__powerpc64__)
++    // On ppc64+glibc, some syscalls seem to accidentally negate the first
++    // parameter which causes checks against it to fail. For now, manually
++    // negate them back.
++    // TODO(shawn@anastas.io): investigate this issue further
++    auto nr = SECCOMP_SYSCALL(ctx);
++    if (nr == __NR_openat || nr == __NR_mkdirat || nr == __NR_faccessat || nr == __NR_readlinkat ||
++        nr == __NR_renameat || nr == __NR_renameat2 || nr == __NR_newfstatat || nr == __NR_unlinkat) {
++        if (static_cast<int>(SECCOMP_PARM1(ctx)) > 0) {
++            SECCOMP_PARM1(ctx) = -SECCOMP_PARM1(ctx);
++        }
++    }
++#endif
++
+     // Copy the seccomp-specific data into a arch_seccomp_data structure. This
+     // is what we are showing to TrapFnc callbacks that the system call
+     // evaluator registered with the sandbox.
+diff --git a/src/3rdparty/chromium/sandbox/linux/services/credentials.cc b/src/3rdparty/chromium/sandbox/linux/services/credentials.cc
+index d7b5d8c44..4adc6d0d4 100644
+--- a/src/3rdparty/chromium/sandbox/linux/services/credentials.cc
++++ b/src/3rdparty/chromium/sandbox/linux/services/credentials.cc
+@@ -81,7 +81,7 @@ bool ChrootToSafeEmptyDir() {
+   pid_t pid = -1;
+   alignas(16) char stack_buf[PTHREAD_STACK_MIN];
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \
+-    defined(ARCH_CPU_MIPS_FAMILY)
++    defined(ARCH_CPU_MIPS_FAMILY) || defined(ARCH_CPU_PPC64_FAMILY)
+   // The stack grows downward.
+   void* stack = stack_buf + sizeof(stack_buf);
+ #else
+diff --git a/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc b/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+index fcfd2aa12..f6eb32fb7 100644
+--- a/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
++++ b/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+@@ -58,7 +58,7 @@ long sys_clone(unsigned long flags,
+ #if defined(ARCH_CPU_X86_64)
+   return syscall(__NR_clone, flags, child_stack, ptid, ctid, tls);
+ #elif defined(ARCH_CPU_X86) || defined(ARCH_CPU_ARM_FAMILY) || \
+-    defined(ARCH_CPU_MIPS_FAMILY)
++    defined(ARCH_CPU_MIPS_FAMILY) || defined(ARCH_CPU_PPC64_FAMILY)
+   // CONFIG_CLONE_BACKWARDS defined.
+   return syscall(__NR_clone, flags, child_stack, ptid, tls, ctid);
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc b/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc
+index 8321d2379..7e5ad1de3 100644
+--- a/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc
++++ b/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc
+@@ -157,7 +157,7 @@ bool BrokerProcess::IsSyscallAllowed(int sysno) const {
+ #if defined(__NR_fstatat)
+     case __NR_fstatat:
+ #endif
+-#if defined(__x86_64__) || defined(__aarch64__)
++#if defined(__x86_64__) || defined(__aarch64__) || defined(__powerpc64__)
+     case __NR_newfstatat:
+ #endif
+       return !fast_check_in_client_ || allowed_command_set_.test(COMMAND_STAT);
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h
+index a60fe2ad3..9dccdb51d 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h
+@@ -29,6 +29,9 @@
+ #ifndef EM_AARCH64
+ #define EM_AARCH64 183
+ #endif
++#ifndef EM_PPC64
++#define EM_PPC64 21
++#endif
+ 
+ #ifndef __AUDIT_ARCH_64BIT
+ #define __AUDIT_ARCH_64BIT 0x80000000
+@@ -54,6 +57,12 @@
+ #ifndef AUDIT_ARCH_AARCH64
+ #define AUDIT_ARCH_AARCH64 (EM_AARCH64 | __AUDIT_ARCH_64BIT | __AUDIT_ARCH_LE)
+ #endif
++#ifndef AUDIT_ARCH_PPC64
++#define AUDIT_ARCH_PPC64 (EM_PPC64 | __AUDIT_ARCH_64BIT)
++#endif
++#ifndef AUDIT_ARCH_PPC64LE
++#define AUDIT_ARCH_PPC64LE (EM_PPC64 | __AUDIT_ARCH_64BIT | __AUDIT_ARCH_LE)
++#endif
+ 
+ // For prctl.h
+ #ifndef PR_SET_SECCOMP
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h
+index f5a736761..515b21a5f 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h
+@@ -13,7 +13,7 @@
+ // (not undefined, but defined different values and in different memory
+ // layouts). So, fill the gap here.
+ #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \
+-    defined(__aarch64__)
++    defined(__aarch64__) || defined(__powerpc64__)
+ 
+ #define LINUX_SIGHUP 1
+ #define LINUX_SIGINT 2
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h
+index 2b78a0cc3..0a70f5ea5 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h
+@@ -35,5 +35,9 @@
+ #include "sandbox/linux/system_headers/arm64_linux_syscalls.h"
+ #endif
+ 
++#if defined(__powerpc64__)
++#include "sandbox/linux/system_headers/ppc64_linux_syscalls.h"
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_LINUX_SYSCALLS_H_
+ 
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h
+index 22ce78027..a69b024c2 100644
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_ucontext.h
+@@ -11,6 +11,8 @@
+ #include "sandbox/linux/system_headers/arm_linux_ucontext.h"
+ #elif defined(__i386__)
+ #include "sandbox/linux/system_headers/i386_linux_ucontext.h"
++#elif defined(__powerpc64__)
++#include "sandbox/linux/system_headers/ppc64_linux_ucontext.h"
+ #else
+ #error "No support for your architecture in PNaCl header"
+ #endif
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_syscalls.h b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_syscalls.h
+new file mode 100644
+index 000000000..ccacffe22
+--- /dev/null
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_syscalls.h
+@@ -0,0 +1,12 @@
++// Copyright 2014 The Chromium Authors. All rights reserved.
++// Use of this source code is governed by a BSD-style license that can be
++// found in the LICENSE file.
++
++#ifndef SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_
++#define SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_
++
++#include <asm/unistd.h>
++
++//TODO: is it necessary to redefine syscall numbers for PPC64?
++
++#endif  // SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_
+diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_ucontext.h b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_ucontext.h
+new file mode 100644
+index 000000000..07728e087
+--- /dev/null
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/ppc64_linux_ucontext.h
+@@ -0,0 +1,12 @@
++// Copyright 2014 The Chromium Authors. All rights reserved.
++// Use of this source code is governed by a BSD-style license that can be
++// found in the LICENSE file.
++
++#ifndef SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_UCONTEXT_H_
++#define SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_UCONTEXT_H_
++
++#include <sys/ucontext.h>
++
++//TODO: is it necessary to redefine ucontext on PPC64?
++
++#endif  // SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_UCONTEXT_H_
+diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc
+index 443e9114b..6df5678d6 100644
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc
++++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc
+@@ -15,6 +15,11 @@
+ #include "sandbox/linux/system_headers/linux_syscalls.h"
+ #include "services/service_manager/sandbox/linux/sandbox_linux.h"
+ 
++// On PPC64, TCGETS is defined in terms of struct termios, so we must include termios.h
++#ifdef __powerpc64__
++#include <termios.h>
++#endif
++
+ // TODO(vignatti): replace the local definitions below with #include
+ // <linux/dma-buf.h> once kernel version 4.6 becomes widely used.
+ #include <linux/types.h>
+diff --git a/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h b/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h
+index 3a807e1e3..5258617a7 100644
+--- a/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h
++++ b/src/3rdparty/chromium/third_party/angle/src/compiler/translator/InfoSink.h
+@@ -92,7 +92,16 @@ class TInfoSinkBase
+             stream.precision(8);
+             stream << f;
+         }
+-        sink.append(stream.str());
++
++        // Hack to work around a bug where negative floating point values
++        // are rendered like '.0.5' instead of '-0.5'
++        std::string res(stream.str());
++
++        if (signbit(f)) { // test if f is negative
++            res[0] = '-';
++        }
++
++        sink.append(res);
+         return *this;
+     }
+     // Write boolean values as their names instead of integral value.
+diff --git a/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h b/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h
+index 746789913..9132b3fc0 100644
+--- a/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h
++++ b/src/3rdparty/chromium/third_party/angle/src/libANGLE/Constants.h
+@@ -9,6 +9,7 @@
+ #ifndef LIBANGLE_CONSTANTS_H_
+ #define LIBANGLE_CONSTANTS_H_
+ 
++#include <cstddef>
+ #include "common/platform.h"
+ 
+ #include <stdint.h>
+diff --git a/src/3rdparty/chromium/third_party/boringssl/BUILD.gn b/src/3rdparty/chromium/third_party/boringssl/BUILD.gn
+index b435499f4..ac8a84b6d 100644
+--- a/src/3rdparty/chromium/third_party/boringssl/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/boringssl/BUILD.gn
+@@ -101,6 +101,13 @@ if (is_win && !is_msan && current_cpu != "arm64") {
+       } else {
+         public_configs = [ ":no_asm_config" ]
+       }
++    } else if (current_cpu == "ppc64") {
++      if (is_linux) {
++        # TODO: ppc64 (be) check
++        sources += crypto_sources_linux_ppc64le
++      } else {
++        public_configs = [ ":no_asm_config" ]
++      }
+     } else {
+       public_configs = [ ":no_asm_config" ]
+     }
+diff --git a/src/3rdparty/chromium/third_party/breakpad/BUILD.gn b/src/3rdparty/chromium/third_party/breakpad/BUILD.gn
+index 5617de88..dc8bc176 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/breakpad/BUILD.gn
+@@ -598,7 +598,6 @@ if (is_linux || is_android) {
+       "breakpad/src/client/minidump_file_writer.h",
+       "breakpad/src/common/convert_UTF.cc",
+       "breakpad/src/common/convert_UTF.h",
+-      "breakpad/src/common/linux/breakpad_getcontext.S",
+       "breakpad/src/common/linux/elf_core_dump.cc",
+       "breakpad/src/common/linux/elf_core_dump.h",
+       "breakpad/src/common/linux/elfutils.cc",
+@@ -636,6 +635,15 @@ if (is_linux || is_android) {
+ 
+     libs = [ "dl" ]
+ 
++    if (current_cpu == "ppc64") {
++        defines = [ "HAVE_GETCONTEXT" ]
++        #libs += [ "ucontext" ]
++    } else {
++        sources += [
++            "breakpad/src/common/linux/breakpad_getcontext.S"
++        ]
++    }
++
+     include_dirs = [
+       ".",
+       "breakpad/src",
+@@ -686,7 +693,6 @@ if (is_linux || is_android) {
+       "breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc",
+       "breakpad/src/client/linux/minidump_writer/minidump_writer_unittest_utils.cc",
+       "breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader_unittest.cc",
+-      "breakpad/src/common/linux/breakpad_getcontext_unittest.cc",
+       "breakpad/src/common/linux/elf_core_dump_unittest.cc",
+       "breakpad/src/common/linux/file_id_unittest.cc",
+       "breakpad/src/common/linux/linux_libc_support_unittest.cc",
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h
+index 07d9171a0..9aed4cb36 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/raw_context_cpu.h
+@@ -44,6 +44,8 @@ typedef MDRawContextARM RawContextCPU;
+ typedef MDRawContextARM64_Old RawContextCPU;
+ #elif defined(__mips__)
+ typedef MDRawContextMIPS RawContextCPU;
++#elif defined(__powerpc64__)
++typedef MDRawContextPPC64 RawContextCPU;
+ #else
+ #error "This code has not been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+index aae1dc13b..03afec7a5 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+@@ -270,7 +270,42 @@ void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
+   out->float_save.fir = mcontext.fpc_eir;
+ #endif
+ }
+-#endif  // __mips__
++
++#elif defined(__powerpc64__)
++
++uintptr_t ThreadInfo::GetInstructionPointer() const {
++    return mcontext.gp_regs[PT_NIP];
++}
++
++void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
++    out->context_flags = MD_CONTEXT_PPC64_FULL;
++    for (int i = 0; i < MD_CONTEXT_PPC64_GPR_COUNT; i++)
++        out->gpr[i] = mcontext.gp_regs[i];
++
++    out->lr = mcontext.gp_regs[PT_LNK];
++    out->srr0 = mcontext.gp_regs[PT_NIP];
++    out->srr1 = mcontext.gp_regs[PT_MSR];
++    out->cr = mcontext.gp_regs[PT_CCR];
++    out->xer = mcontext.gp_regs[PT_XER];
++    out->ctr = mcontext.gp_regs[PT_CTR];
++    
++    for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
++        out->float_save.fpregs[i] = mcontext.fp_regs[i];
++
++    out->float_save.fpscr = mcontext.fp_regs[NFPREG-1];
++
++    for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
++        out->vector_save.save_vr[i] = \
++            {(((uint64_t)vregs.vrregs[i][0]) << 32) 
++                          | vregs.vrregs[i][1], 
++            (((uint64_t)vregs.vrregs[i][2]) << 32)
++                         | vregs.vrregs[i][3]};
++
++    out->vrsave = vregs.vrsave;
++    out->vector_save.save_vscr = {0, vregs.vscr.vscr_word};
++    out->vector_save.save_vrvalid = 0xFFFFFFFF; 
++}
++#endif  // __powerpc64__
+ 
+ void ThreadInfo::GetGeneralPurposeRegisters(void** gp_regs, size_t* size) {
+   assert(gp_regs || size);
+@@ -279,6 +314,11 @@ void ThreadInfo::GetGeneralPurposeRegisters(void** gp_regs, size_t* size) {
+     *gp_regs = mcontext.gregs;
+   if (size)
+     *size = sizeof(mcontext.gregs);
++#elif defined(__powerpc64__)
++  if (gp_regs)
++    *gp_regs = mcontext.gp_regs;
++  if (size)
++    *size = sizeof(mcontext.gp_regs);
+ #else
+   if (gp_regs)
+     *gp_regs = &regs;
+@@ -294,6 +334,11 @@ void ThreadInfo::GetFloatingPointRegisters(void** fp_regs, size_t* size) {
+     *fp_regs = &mcontext.fpregs;
+   if (size)
+     *size = sizeof(mcontext.fpregs);
++#elif defined(__powerpc64__)
++  if (fp_regs)
++    *fp_regs = &mcontext.fp_regs;
++  if (size)
++    *size = sizeof(mcontext.fp_regs);
+ #else
+   if (fp_regs)
+     *fp_regs = &fpregs;
+@@ -302,4 +347,13 @@ void ThreadInfo::GetFloatingPointRegisters(void** fp_regs, size_t* size) {
+ #endif
+ }
+ 
++#if defined(__powerpc64__)
++void ThreadInfo::GetVectorRegisters(void** v_regs, size_t* size) {
++    if (v_regs)
++        *v_regs = &vregs;
++    if (size)
++        *size = sizeof(vregs);
++}
++#endif
++
+ }  // namespace google_breakpad
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h
+index fb216fa6d..593aac822 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.h
+@@ -68,6 +68,10 @@ struct ThreadInfo {
+   // Use the structures defined in <sys/user.h>
+   struct user_regs_struct regs;
+   struct user_fpsimd_struct fpregs;
++#elif defined(__powerpc64__)
++  // Use the structures defined in <sys/ucontext.h>.
++  mcontext_t mcontext;
++  vrregset_t vregs;
+ #elif defined(__mips__)
+   // Use the structure defined in <sys/ucontext.h>.
+   mcontext_t mcontext;
+@@ -84,6 +88,11 @@ struct ThreadInfo {
+ 
+   // Returns the pointer and size of float point register area.
+   void GetFloatingPointRegisters(void** fp_regs, size_t* size);
++
++#if defined(__powerpc64__)
++  // Returns the pointer and size of the vector register area. (PPC64 only)
++  void GetVectorRegisters(void** v_regs, size_t* size);
++#endif
+ };
+ 
+ }  // namespace google_breakpad
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+index a8f9ccc72..7620cf6f7 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+@@ -254,6 +254,48 @@ void UContextReader::FillCPUContext(RawContextCPU *out, const ucontext_t *uc) {
+   out->float_save.fir = uc->uc_mcontext.fpc_eir;  // Unused.
+ #endif
+ }
++
++#elif defined(__powerpc64__)
++
++uintptr_t UContextReader::GetStackPointer(const ucontext_t* uc) {
++    return uc->uc_mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP];
++}
++
++uintptr_t UContextReader::GetInstructionPointer(const ucontext_t* uc) {
++    return uc->uc_mcontext.gp_regs[PT_NIP];
++}
++
++void UContextReader::FillCPUContext(RawContextCPU* out, const ucontext_t* uc,
++                                    const vrregset_t* vregs) {
++    out->context_flags = MD_CONTEXT_PPC64_FULL;
++
++    for (int i = 0; i < MD_CONTEXT_PPC64_GPR_COUNT; i++)
++        out->gpr[i] = uc->uc_mcontext.gp_regs[i];
++
++    out->lr = uc->uc_mcontext.gp_regs[PT_LNK];    
++    out->srr0 = uc->uc_mcontext.gp_regs[PT_NIP];
++    out->srr1 = uc->uc_mcontext.gp_regs[PT_MSR];
++    out->cr = uc->uc_mcontext.gp_regs[PT_CCR];
++    out->xer = uc->uc_mcontext.gp_regs[PT_XER];
++    out->ctr = uc->uc_mcontext.gp_regs[PT_CTR];
++    
++    for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
++        out->float_save.fpregs[i] = uc->uc_mcontext.fp_regs[i];
++
++    out->float_save.fpscr = uc->uc_mcontext.fp_regs[NFPREG-1];
++
++    for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
++        out->vector_save.save_vr[i] =
++            {(((uint64_t)vregs->vrregs[i][0]) << 32) 
++                         | vregs->vrregs[i][1], 
++             (((uint64_t)vregs->vrregs[i][2]) << 32)
++                         | vregs->vrregs[i][3]};
++
++    out->vrsave = vregs->vrsave;
++    out->vector_save.save_vscr = {0, vregs->vscr.vscr_word};
++    out->vector_save.save_vrvalid = 0xFFFFFFFF; 
++}
++
+ #endif
+ 
+ }  // namespace google_breakpad
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h
+index f3dde1f4d..96079169d 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.h
+@@ -54,6 +54,9 @@ struct UContextReader {
+ #elif defined(__aarch64__)
+   static void FillCPUContext(RawContextCPU *out, const ucontext_t *uc,
+                              const struct fpsimd_context* fpregs);
++#elif defined(__powerpc64__)
++  static void FillCPUContext(RawContextCPU *out, const ucontext_t *uc,
++                             const vrregset_t* vregs);
+ #else
+   static void FillCPUContext(RawContextCPU *out, const ucontext_t *uc);
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+index b895f6d7a..901cd68fb 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+@@ -461,9 +461,16 @@ bool ExceptionHandler::HandleSignal(int /*sig*/, siginfo_t* info, void* uc) {
+     memcpy(&g_crash_context_.float_state, fp_ptr,
+            sizeof(g_crash_context_.float_state));
+   }
++#elif defined(__powerpc64__)
++  // On PPC64, we must copy VR state
++  ucontext_t* uc_ptr = (ucontext_t*)uc;
++  if (uc_ptr->uc_mcontext.v_regs) {
++    memcpy(&g_crash_context_.vector_state, uc_ptr->uc_mcontext.v_regs,
++           sizeof(g_crash_context_.vector_state));
++  }
+ #elif !defined(__ARM_EABI__) && !defined(__mips__)
+   // FP state is not part of user ABI on ARM Linux.
+-  // In case of MIPS Linux FP state is already part of ucontext_t
++  // In case of MIPS, Linux FP state is already part of ucontext_t
+   // and 'float_state' is not a member of CrashContext.
+   ucontext_t* uc_ptr = (ucontext_t*)uc;
+   if (uc_ptr->uc_mcontext.fpregs) {
+@@ -701,11 +708,19 @@ bool ExceptionHandler::WriteMinidump() {
+   }
+ #endif
+ 
+-#if !defined(__ARM_EABI__) && !defined(__aarch64__) && !defined(__mips__)
++#if !defined(__ARM_EABI__) && !defined(__aarch64__) && !defined(__mips__) \
++    && !defined(__powerpc64__)
+   // FPU state is not part of ARM EABI ucontext_t.
+   memcpy(&context.float_state, context.context.uc_mcontext.fpregs,
+          sizeof(context.float_state));
+ #endif
++
++#if defined(__powerpc64__)
++  // Vector registers must be copied on PPC64
++  memcpy(&context.vector_state, context.context.uc_mcontext.v_regs,
++         sizeof(context.vector_state));
++#endif
++
+   context.tid = sys_gettid();
+ 
+   // Add an exception stream to the minidump for better reporting.
+@@ -726,6 +741,9 @@ bool ExceptionHandler::WriteMinidump() {
+ #elif defined(__mips__)
+   context.siginfo.si_addr =
+       reinterpret_cast<void*>(context.context.uc_mcontext.pc);
++#elif defined(__powerpc64__)
++  context.siginfo.si_addr =
++      reinterpret_cast<void*>(context.context.uc_mcontext.gp_regs[PT_NIP]);
+ #else
+ #error "This code has not been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h
+index f44483ff0..36ce6d6ce 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.h
+@@ -192,7 +192,11 @@ class ExceptionHandler {
+     siginfo_t siginfo;
+     pid_t tid;  // the crashing thread.
+     ucontext_t context;
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++    // PPC64's FP state is a part of ucontext_t like MIPS but the vector
++    // state is not, so a struct is needed.
++    vstate_t vector_state;
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+     // #ifdef this out because FP state is not part of user ABI for Linux ARM.
+     // In case of MIPS Linux FP state is already part of ucontext_t so
+     // 'float_state' is not required.
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc
+index bcbf9c26f..2c36ed41f 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler_unittest.cc
+@@ -307,7 +307,7 @@ TEST(ExceptionHandlerTest, ParallelChildCrashesDontHang) {
+   }
+ 
+   // Wait a while until the child should have crashed.
+-  usleep(1000000);
++  usleep(2000000);
+   // Kill the child if it is still running.
+   kill(child, SIGKILL);
+ 
+@@ -559,6 +559,8 @@ const unsigned char kIllegalInstruction[] = {
+ #if defined(__mips__)
+   // mfc2 zero,Impl - usually illegal in userspace.
+   0x48, 0x00, 0x00, 0x48
++#elif defined(__powerpc64__)
++  0x01, 0x01, 0x01, 0x01 // Crashes on a tested POWER9 cpu
+ #else
+   // This crashes with SIGILL on x86/x86-64/arm.
+   0xff, 0xff, 0xff, 0xff
+@@ -754,10 +756,10 @@ TEST(ExceptionHandlerTest, InstructionPointerMemoryMaxBound) {
+ 
+   // These are defined here so the parent can use them to check the
+   // data from the minidump afterwards.
+-  // Use 4k here because the OS will hand out a single page even
++  // Use the page size here because the OS will hand out a single page even
+   // if a smaller size is requested, and this test wants to
+   // test the upper bound of the memory range.
+-  const uint32_t kMemorySize = 4096;  // bytes
++  const uint32_t kMemorySize = getpagesize();  // bytes
+   const int kOffset = kMemorySize - sizeof(kIllegalInstruction);
+ 
+   const pid_t child = fork();
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc
+index fa3c1713a..6ce709e2f 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer.cc
+@@ -138,7 +138,9 @@ class MicrodumpWriter {
+                   const MicrodumpExtraInfo& microdump_extra_info,
+                   LinuxDumper* dumper)
+       : ucontext_(context ? &context->context : NULL),
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++        vector_state_(context ? &context->vector_state : NULL),
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+         float_state_(context ? &context->float_state : NULL),
+ #endif
+         dumper_(dumper),
+@@ -337,6 +339,8 @@ class MicrodumpWriter {
+ # else
+ #  error "This mips ABI is currently not supported (n32)"
+ #endif
++#elif defined(__powerpc64__)
++    const char kArch[] = "ppc64";
+ #else
+ #error "This code has not been ported to your platform yet"
+ #endif
+@@ -409,7 +413,9 @@ class MicrodumpWriter {
+   void DumpCPUState() {
+     RawContextCPU cpu;
+     my_memset(&cpu, 0, sizeof(RawContextCPU));
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++    UContextReader::FillCPUContext(&cpu, ucontext_, vector_state_);
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+     UContextReader::FillCPUContext(&cpu, ucontext_, float_state_);
+ #else
+     UContextReader::FillCPUContext(&cpu, ucontext_);
+@@ -605,7 +611,9 @@ class MicrodumpWriter {
+   void* Alloc(unsigned bytes) { return dumper_->allocator()->Alloc(bytes); }
+ 
+   const ucontext_t* const ucontext_;
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++  const google_breakpad::vstate_t* const vector_state_;
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+   const google_breakpad::fpstate_t* const float_state_;
+ #endif
+   LinuxDumper* dumper_;
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc
+index c2fea0225..8c62c524a 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/microdump_writer/microdump_writer_unittest.cc
+@@ -278,10 +278,19 @@ TEST(MicrodumpWriterTest, BasicWithMappings) {
+   CrashAndGetMicrodump(mappings, MicrodumpExtraInfo(), &buf);
+   ASSERT_TRUE(ContainsMicrodump(buf));
+ 
++  int page_size = getpagesize();
+ #ifdef __LP64__
+-  ASSERT_NE(std::string::npos,
+-            buf.find("M 0000000000001000 000000000000002A 0000000000001000 "
+-                     "33221100554477668899AABBCCDDEEFF0 libfoo.so"));
++  // This test is only available for the following page sizes
++  ASSERT_TRUE((page_size == 4096) || (page_size == 65536));
++  if (page_size == 4096) { 
++    ASSERT_NE(std::string::npos,
++              buf.find("M 0000000000001000 000000000000002A 0000000000001000 "
++                       "33221100554477668899AABBCCDDEEFF0 libfoo.so"));
++  } else {
++    ASSERT_NE(std::string::npos,
++              buf.find("M 0000000000010000 000000000000002A 0000000000010000 "
++                       "33221100554477668899AABBCCDDEEFF0 libfoo.so"));
++  }
+ #else
+   ASSERT_NE(std::string::npos,
+             buf.find("M 00001000 0000002A 00001000 "
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc
+index 4756a5416..4805fb694 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc
+@@ -117,6 +117,9 @@ bool LinuxCoreDumper::GetThreadInfoByIndex(size_t index, ThreadInfo* info) {
+ #elif defined(__mips__)
+   stack_pointer =
+       reinterpret_cast<uint8_t*>(info->mcontext.gregs[MD_CONTEXT_MIPS_REG_SP]);
++#elif defined(__powerpc64__)
++  stack_pointer =
++      reinterpret_cast<uint8_t*>(info->mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP]);
+ #else
+ #error "This code hasn't been ported to your platform yet."
+ #endif
+@@ -202,7 +205,10 @@ bool LinuxCoreDumper::EnumerateThreads() {
+         memset(&info, 0, sizeof(ThreadInfo));
+         info.tgid = status->pr_pgrp;
+         info.ppid = status->pr_ppid;
+-#if defined(__mips__)
++#if defined(__powerpc64__)
++        for (int i = 0; i < 31; i++)
++            info.mcontext.gp_regs[i] = status->pr_reg[i];
++#elif defined(__mips__)
+ #if defined(__ANDROID__)
+         for (int i = EF_R0; i <= EF_R31; i++)
+           info.mcontext.gregs[i - EF_R0] = status->pr_reg[i];
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc
+index 1112035bc..8523dad63 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.cc
+@@ -765,7 +765,9 @@ bool LinuxDumper::GetStackInfo(const void** stack, size_t* stack_len,
+       reinterpret_cast<uint8_t*>(int_stack_pointer & ~(page_size - 1));
+ 
+   // The number of bytes of stack which we try to capture.
+-  static const ptrdiff_t kStackToCapture = 32 * 1024;
++  // This now depends on page_size to avoid missing data
++  // on systems with larger page sizes.
++  static const ptrdiff_t kStackToCapture = 8 * page_size;
+ 
+   const MappingInfo* mapping = FindMapping(stack_pointer);
+   if (!mapping)
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h
+index f4a75d906..020981f57 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper.h
+@@ -63,7 +63,8 @@ namespace google_breakpad {
+  (defined(__mips__) && _MIPS_SIM == _ABIO32)
+ typedef Elf32_auxv_t elf_aux_entry;
+ #elif defined(__x86_64) || defined(__aarch64__) || \
+-     (defined(__mips__) && _MIPS_SIM != _ABIO32)
++     (defined(__mips__) && _MIPS_SIM != _ABIO32) || \
++     defined(__powerpc64__)
+ typedef Elf64_auxv_t elf_aux_entry;
+ #endif
+ 
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc
+index 3ad48e501..1688c365e 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc
+@@ -51,6 +51,8 @@
+ #define TID_PTR_REGISTER "rcx"
+ #elif defined(__mips__)
+ #define TID_PTR_REGISTER "$1"
++#elif defined(__powerpc64__)
++#define TID_PTR_REGISTER "r8"
+ #else
+ #error This test has not been ported to this platform.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc
+index 8a3f04e29..e607b28d5 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc
+@@ -154,19 +154,27 @@ bool LinuxPtraceDumper::CopyFromProcess(void* dest, pid_t child,
+   return true;
+ }
+ 
+-bool LinuxPtraceDumper::ReadRegisterSet(ThreadInfo* info, pid_t tid)
+-{
++bool LinuxPtraceDumper::ReadRegisterSet(ThreadInfo* info, pid_t tid) {
+ #ifdef PTRACE_GETREGSET
+   struct iovec io;
+   info->GetGeneralPurposeRegisters(&io.iov_base, &io.iov_len);
+-  if (sys_ptrace(PTRACE_GETREGSET, tid, (void*)NT_PRSTATUS, (void*)&io) == -1) {
++  if (ptrace(PTRACE_GETREGSET, tid, (void*)NT_PRSTATUS, (void*)&io) == -1) {
+     return false;
+   }
+ 
+   info->GetFloatingPointRegisters(&io.iov_base, &io.iov_len);
+-  if (sys_ptrace(PTRACE_GETREGSET, tid, (void*)NT_FPREGSET, (void*)&io) == -1) {
++  if (ptrace(PTRACE_GETREGSET, tid, (void*)NT_FPREGSET, (void*)&io) == -1) {
+     return false;
+   }
++
++#if defined(__powerpc64__)
++  // Grab the vector registers on PPC64 too
++  info->GetVectorRegisters(&io.iov_base, &io.iov_len);
++  if (ptrace(PTRACE_GETREGSET, tid, (void*)NT_PPC_VMX, (void*)&io) == -1) {
++    return false;
++  }
++#endif // defined(__powerpc64__)
++
+   return true;
+ #else
+   return false;
+@@ -303,6 +311,9 @@ bool LinuxPtraceDumper::GetThreadInfoByIndex(size_t index, ThreadInfo* info) {
+ #elif defined(__mips__)
+   stack_pointer =
+       reinterpret_cast<uint8_t*>(info->mcontext.gregs[MD_CONTEXT_MIPS_REG_SP]);
++#elif defined(__powerpc64__)
++  stack_pointer =
++      reinterpret_cast<uint8_t*>(info->mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP]);
+ #else
+ #error "This code hasn't been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc
+index a41dafce0..31743940d 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper_unittest.cc
+@@ -462,6 +462,9 @@ TEST(LinuxPtraceDumperTest, VerifyStackReadWithMultipleThreads) {
+ #elif defined(__mips__)
+     pid_t* process_tid_location =
+         reinterpret_cast<pid_t*>(one_thread.mcontext.gregs[1]);
++#elif defined(__powerpc64__)
++    pid_t* process_tid_location =
++        reinterpret_cast<pid_t*>(one_thread.mcontext.gp_regs[8]);
+ #else
+ #error This test has not been ported to this platform.
+ #endif
+@@ -559,6 +562,8 @@ TEST_F(LinuxPtraceDumperTest, SanitizeStackCopy) {
+   uintptr_t heap_addr = thread_info.regs.rcx;
+ #elif defined(__mips__)
+   uintptr_t heap_addr = thread_info.mcontext.gregs[1];
++#elif defined(__powerpc64__)
++  uintptr_t heap_addr = thread_info.mcontext.gp_regs[8];
+ #else
+ #error This test has not been ported to this platform.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc
+index f8cdf2a1c..cb808c151 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.cc
+@@ -136,7 +136,9 @@ class MinidumpWriter {
+       : fd_(minidump_fd),
+         path_(minidump_path),
+         ucontext_(context ? &context->context : NULL),
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++        vector_state_(context ? &context->vector_state : NULL),
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+         float_state_(context ? &context->float_state : NULL),
+ #endif
+         dumper_(dumper),
+@@ -468,7 +470,9 @@ class MinidumpWriter {
+         if (!cpu.Allocate())
+           return false;
+         my_memset(cpu.get(), 0, sizeof(RawContextCPU));
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++        UContextReader::FillCPUContext(cpu.get(), ucontext_, vector_state_);
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+         UContextReader::FillCPUContext(cpu.get(), ucontext_, float_state_);
+ #else
+         UContextReader::FillCPUContext(cpu.get(), ucontext_);
+@@ -897,7 +901,7 @@ class MinidumpWriter {
+     dirent->location.rva = 0;
+   }
+ 
+-#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
++#if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || defined(__powerpc64__)
+   bool WriteCPUInformation(MDRawSystemInfo* sys_info) {
+     char vendor_id[sizeof(sys_info->cpu.x86_cpu_info.vendor_id) + 1] = {0};
+     static const char vendor_id_name[] = "vendor_id";
+@@ -917,7 +921,9 @@ class MinidumpWriter {
+ 
+     // processor_architecture should always be set, do this first
+     sys_info->processor_architecture =
+-#if defined(__mips__)
++#if defined(__powerpc64__)
++        MD_CPU_ARCHITECTURE_PPC64;
++#elif defined(__mips__)
+ # if _MIPS_SIM == _ABIO32
+         MD_CPU_ARCHITECTURE_MIPS;
+ # elif _MIPS_SIM == _ABI64
+@@ -1333,7 +1339,9 @@ class MinidumpWriter {
+   const char* path_;  // Path to the file where the minidum should be written.
+ 
+   const ucontext_t* const ucontext_;  // also from the signal handler
+-#if !defined(__ARM_EABI__) && !defined(__mips__)
++#if defined(__powerpc64__)
++  const google_breakpad::vstate_t* const vector_state_;
++#elif !defined(__ARM_EABI__) && !defined(__mips__)
+   const google_breakpad::fpstate_t* const float_state_;  // ditto
+ #endif
+   LinuxDumper* dumper_;
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h
+index d1cc5624c..320847643 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer.h
+@@ -47,6 +47,8 @@ class ExceptionHandler;
+ 
+ #if defined(__aarch64__)
+ typedef struct fpsimd_context fpstate_t;
++#elif defined(__powerpc64__)
++typedef vrregset_t vstate_t;
+ #elif !defined(__ARM_EABI__) && !defined(__mips__)
+ typedef struct _fpstate fpstate_t;
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc
+index c951e69d8..e1d6e40d6 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/minidump_writer_unittest.cc
+@@ -714,6 +714,9 @@ TEST(MinidumpWriterTest, InvalidStackPointer) {
+ #elif defined(__mips__)
+   context.context.uc_mcontext.gregs[MD_CONTEXT_MIPS_REG_SP] =
+       invalid_stack_pointer;
++#elif defined(__powerpc64__)
++  context.context.uc_mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP] =
++      invalid_stack_pointer;
+ #else
+ # error "This code has not been ported to your platform yet."
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc
+index 4e938269f..f0ff15d96 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file.cc
+@@ -65,8 +65,7 @@ bool MemoryMappedFile::Map(const char* path, size_t offset) {
+   }
+ 
+ #if defined(__x86_64__) || defined(__aarch64__) || \
+-   (defined(__mips__) && _MIPS_SIM == _ABI64)
+-
++   (defined(__mips__) && _MIPS_SIM == _ABI64) || defined(__powerpc64__)
+   struct kernel_stat st;
+   if (sys_fstat(fd, &st) == -1 || st.st_size < 0) {
+ #else
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc
+index fad59f40c..616496d67 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/memory_mapped_file_unittest.cc
+@@ -176,9 +176,10 @@ TEST_F(MemoryMappedFileTest, RemapAfterMap) {
+ TEST_F(MemoryMappedFileTest, MapWithOffset) {
+   // Put more data in the test file this time. Offsets can only be
+   // done on page boundaries, so we need a two page file to test this.
+-  const int page_size = 4096;
+-  char data1[2 * page_size];
+-  size_t data1_size = sizeof(data1);
++  const int page_size = getpagesize();
++  char *data1 = static_cast<char*>(malloc(2 * page_size));
++  EXPECT_TRUE(data1 != NULL);
++  size_t data1_size = (2 * page_size);
+   for (size_t i = 0; i < data1_size; ++i) {
+     data1[i] = i & 0x7f;
+   }
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc
+index 43c86314c..27325b813 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/memory_allocator_unittest.cc
+@@ -57,8 +57,9 @@
+ 
+   EXPECT_EQ(0U, allocator.pages_allocated());
+   uint8_t* p = reinterpret_cast<uint8_t*>(allocator.Alloc(10000));
++  uint64_t expected_pages = 1 + ((10000 - 1) / getpagesize());
+   ASSERT_FALSE(p == NULL);
+-  EXPECT_EQ(3U, allocator.pages_allocated());
++  EXPECT_EQ(expected_pages, allocator.pages_allocated());
+   for (unsigned i = 1; i < 10; ++i) {
+     uint8_t* p = reinterpret_cast<uint8_t*>(allocator.Alloc(i));
+     ASSERT_FALSE(p == NULL);
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc
+index ccc9f1459..debaed4d6 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_linux.cc
+@@ -202,12 +202,14 @@ bool ExploitabilityLinux::EndedOnIllegalWrite(uint64_t instruction_ptr) {
+   // Check architecture and set architecture variable to corresponding flag
+   // in objdump.
+   switch (context->GetContextCPU()) {
++#if defined(__i386) || defined(__x86_64)
+     case MD_CONTEXT_X86:
+       architecture = "i386";
+       break;
+     case MD_CONTEXT_AMD64:
+       architecture = "i386:x86-64";
+       break;
++#endif
+     default:
+       // Unsupported architecture. Note that ARM architectures are not
+       // supported because objdump does not support ARM.
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc
+index 528ee5f21..72764d6c1 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/processor/exploitability_unittest.cc
+@@ -104,6 +104,8 @@ ExploitabilityFor(const string& filename) {
+ }
+ 
+ TEST(ExploitabilityTest, TestWindowsEngine) {
++// The following tests are only executable on an x86-class linux machine.
++#if !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+             ExploitabilityFor("ascii_read_av.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+@@ -136,9 +138,12 @@ TEST(ExploitabilityTest, TestWindowsEngine) {
+             ExploitabilityFor("read_av_clobber_write.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_LOW,
+             ExploitabilityFor("read_av_conditional.dmp"));
++#endif
+ }
+ 
+ TEST(ExploitabilityTest, TestLinuxEngine) {
++// The following tests are only executable on an x86-class linux machine.
++#if defined(__i386) || defined(__x86_64)
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_INTERESTING,
+             ExploitabilityFor("linux_null_read_av.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+@@ -171,7 +176,8 @@ TEST(ExploitabilityTest, TestLinuxEngine) {
+             ExploitabilityFor("linux_executable_heap.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+             ExploitabilityFor("linux_jmp_to_module_not_exe_region.dmp"));
+-#ifndef _WIN32
++#endif
++#if !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+             ExploitabilityFor("linux_write_to_nonwritable_module.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_HIGH,
+@@ -182,10 +188,10 @@ TEST(ExploitabilityTest, TestLinuxEngine) {
+             ExploitabilityFor("linux_write_to_outside_module_via_math.dmp"));
+   ASSERT_EQ(google_breakpad::EXPLOITABILITY_INTERESTING,
+             ExploitabilityFor("linux_write_to_under_4k.dmp"));
+-#endif  // _WIN32
++#endif  // !defined(_WIN32) && (!defined(__i386) && !defined(__x86_64))
+ }
+ 
+-#ifndef _WIN32
++#if !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
+ TEST(ExploitabilityLinuxUtilsTest, DisassembleBytesTest) {
+   ASSERT_FALSE(ExploitabilityLinuxTest::DisassembleBytes("", NULL, 5, NULL));
+   uint8_t bytes[6] = {0xc7, 0x0, 0x5, 0x0, 0x0, 0x0};
+@@ -301,6 +307,7 @@ TEST(ExploitabilityLinuxUtilsTest, CalculateAddressTest) {
+                                                          context,
+                                                          &write_address));
+ }
+-#endif  // _WIN32
++#endif  // !defined(_WIN32) && (defined(__i386) || defined(__x86_64))
++
+ 
+ }  // namespace
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc
+index 941586e9f..49cdc3fc2 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/tools/linux/md2core/minidump-2-core.cc
+@@ -76,6 +76,8 @@
+   #define ELF_ARCH  EM_MIPS
+ #elif defined(__aarch64__)
+   #define ELF_ARCH  EM_AARCH64
++#elif defined(__powerpc64__)
++  #define ELF_ARCH  EM_PPC64
+ #endif
+ 
+ #if defined(__arm__)
+@@ -86,6 +88,8 @@ typedef user_regs user_regs_struct;
+ #elif defined (__mips__)
+ // This file-local typedef simplifies the source code.
+ typedef gregset_t user_regs_struct;
++#elif defined(__powerpc64__)
++typedef struct pt_regs user_regs_struct;
+ #endif
+ 
+ using google_breakpad::MDTypeHelper;
+@@ -320,6 +324,9 @@ struct CrashedProcess {
+ #endif
+ #if defined(__aarch64__)
+     user_fpsimd_struct fpregs;
++#endif
++#if defined(__powerpc64__)
++    mcontext_t mcontext;
+ #endif
+     uintptr_t stack_addr;
+     const uint8_t* stack;
+@@ -534,6 +541,38 @@ ParseThreadRegisters(CrashedProcess::Thread* thread,
+   thread->mcontext.fpc_eir = rawregs->float_save.fir;
+ #endif
+ }
++#elif defined(__powerpc64__)
++static void
++ParseThreadRegisters(CrashedProcess::Thread* thread,
++                     const MinidumpMemoryRange& range) {
++  const MDRawContextPPC64* rawregs = range.GetData<MDRawContextPPC64>(0);
++
++  for (int i = 0; i < MD_CONTEXT_PPC64_GPR_COUNT; i++)
++    thread->mcontext.gp_regs[i] = rawregs->gpr[i];
++
++  thread->mcontext.gp_regs[PT_LNK] = rawregs->lr;
++  thread->mcontext.gp_regs[PT_NIP] = rawregs->srr0;
++  thread->mcontext.gp_regs[PT_MSR] = rawregs->srr1;
++  thread->mcontext.gp_regs[PT_CCR] = rawregs->cr;
++  thread->mcontext.gp_regs[PT_XER] = rawregs->xer;
++  thread->mcontext.gp_regs[PT_CTR] = rawregs->ctr;
++  thread->mcontext.v_regs->vrsave = rawregs->vrsave;
++
++  for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
++      thread->mcontext.fp_regs[i] = rawregs->float_save.fpregs[i];
++
++  thread->mcontext.fp_regs[NFPREG-1] = rawregs->float_save.fpscr;
++
++  for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++) {
++      thread->mcontext.v_regs->vrregs[i][0] = rawregs->vector_save.save_vr[i].high >> 32;
++      thread->mcontext.v_regs->vrregs[i][1] = rawregs->vector_save.save_vr[i].high;
++      thread->mcontext.v_regs->vrregs[i][2] = rawregs->vector_save.save_vr[i].low >> 32;
++      thread->mcontext.v_regs->vrregs[i][3] = rawregs->vector_save.save_vr[i].low;
++  }
++
++  thread->mcontext.v_regs->vscr.vscr_word = rawregs->vector_save.save_vscr.low & 0xFFFFFFFF;
++}
++
+ #else
+ #error "This code has not been ported to your platform yet"
+ #endif
+@@ -622,6 +661,12 @@ ParseSystemInfo(const Options& options, CrashedProcess* crashinfo,
+ # else
+ #  error "This mips ABI is currently not supported (n32)"
+ # endif
++#elif defined(__powerpc64__)
++  if (sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_PPC64) {
++    fprintf(stderr,
++            "This version of minidump-2-core only supports PPC64.\n");
++    exit(1);
++  }
+ #else
+ #error "This code has not been ported to your platform yet"
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS b/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS
+index 8724b7f32..8e29424ef 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/CONTRIBUTORS
+@@ -13,3 +13,4 @@ Mark Mentovai <mark@chromium.org>
+ Robert Sesek <rsesek@chromium.org>
+ Scott Graham <scottmg@chromium.org>
+ Joshua Peraza <jperaza@chromium.org>
++Shawn Anastasio <shawn@anastas.io>
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h
+index 6ed77a98e..1fd83469a 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/compat/linux/sys/user.h
+@@ -15,6 +15,7 @@
+ #ifndef CRASHPAD_COMPAT_LINUX_SYS_USER_H_
+ #define CRASHPAD_COMPAT_LINUX_SYS_USER_H_
+ 
++#include <cstddef>
+ #include_next <sys/user.h>
+ 
+ #include <features.h>
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h
+index 3a3e603cb..3118d9e9f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context.h
+@@ -592,6 +592,70 @@ struct MinidumpContextMIPS64 {
+   uint64_t fir;
+ };
+ 
++//! \brief ppc64-specific flags for MinidumpPPC64::context_flags
++//! Based on minidump_cpu_ppc64.h from breakpad
++enum MinidumpContextPPC64Flags : uint32_t {
++  //! \brief Identifies the context as PPC64.
++  kMinidumpContextPPC64 = 0x01000000,
++
++  //! \brief Indicates the validity of general purpose registers.
++  //!
++  //! Registers `r0`-`r31`, `nip`, `msr`, `lr`, etc. are valid.
++  kMinidumpContextPPC64Base = kMinidumpContextPPC64 | 0x00000001,
++
++  //! \brief Indicates the validity of floating point registers.
++  //!
++  //! Registers `fp0`-`fp31`, `fpscr` are valid.
++  kMinidumpContextPPC64Floating = kMinidumpContextPPC64 | 0x00000008,
++
++  //! \brief Indicates the validity of Altivec/VMX registers.
++  //!
++  //! Registers `v0`-`v31`, `vscr`, `vrsave`.
++  kMinidumpContextPPC64Vector = kMinidumpContextPPC64 | 0x00000020,
++
++  //! \brief Indicates the validity of all registers
++  kMinidumpContextPPC64All = kMinidumpContextPPC64Base     |
++                             kMinidumpContextPPC64Floating |
++                             kMinidumpContextPPC64Vector
++};
++
++//! \brief A PPC64 CPU context carried in a minidump file.
++//! Based on minidump_cpu_ppc64.h from breakpad.
++struct MinidumpContextPPC64 {
++  uint64_t context_flags;
++
++  //! \brief General purpose registers.
++  uint64_t nip;
++  uint64_t msr;
++  uint64_t regs[32];
++  uint64_t ccr;
++  uint64_t xer;
++  uint64_t lnk;
++  uint64_t ctr;
++
++  //! \brief Floating point registers.
++  double fpregs[32];
++
++  //! \brief FPU status register.
++  double fpscr;
++
++  //! \brief Altivec/VMX vector registers.
++  struct {
++      //! \brief Vector registers are 128bits.
++      uint128_struct save_vr[32];
++      uint128_struct save_vscr;
++
++      //! \brief Padding included for breakpad compatibiltiy.
++      uint32_t save_pad5[4];
++
++      //! \brief VRSAVE register.
++      uint32_t save_vrsave;
++
++      //! \brief Padding included for breakpad compatibiltiy.
++      uint32_t save_pad6[7];
++  } vregs;
++};
++
+ }  // namespace crashpad
+ 
+ #endif  // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_H_
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
+index d7e53a493..d89eb9e01 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
+@@ -101,6 +101,13 @@ MinidumpContextWriter::CreateFromSnapshot(const CPUContext* context_snapshot) {
+       break;
+     }
+ 
++    case kCPUArchitecturePPC64: {
++      context = std::make_unique<MinidumpContextPPC64Writer>();
++      reinterpret_cast<MinidumpContextPPC64Writer*>(context.get())
++          ->InitalizeFromSnapshot(context_snapshot->ppc64);
++      break;
++    }
++
+     default: {
+       LOG(ERROR) << "unknown context architecture "
+                  << context_snapshot->architecture;
+@@ -453,4 +460,47 @@ size_t MinidumpContextMIPS64Writer::ContextSize() const {
+   return sizeof(context_);
+ }
+ 
++MinidumpContextPPC64Writer::MinidumpContextPPC64Writer()
++  : MinidumpContextWriter(), context_() {
++    context_.context_flags = kMinidumpContextPPC64;
++}
++
++MinidumpContextPPC64Writer::~MinidumpContextPPC64Writer() = default;
++
++void MinidumpContextPPC64Writer::InitalizeFromSnapshot(
++    const CPUContextPPC64* context_snapshot) {
++  DCHECK_EQ(state(), kStateMutable);
++  DCHECK_EQ(context_.context_flags, kMinidumpContextPPC64);
++
++  context_.context_flags = kMinidumpContextPPC64All;
++
++  memcpy(context_.regs, context_snapshot->regs, sizeof(context_.regs));
++  context_.nip = context_snapshot->nip;
++  context_.msr = context_snapshot->msr;
++  context_.ccr = context_snapshot->ccr;
++  context_.xer = context_snapshot->xer;
++  context_.lnk = context_snapshot->lnk;
++  context_.ctr = context_snapshot->ctr;
++
++  memcpy(context_.fpregs, context_snapshot->fpregs, sizeof(context_.fpregs));
++  context_.fpscr = context_snapshot->fpscr;
++
++  memcpy(context_.vregs.save_vr, context_snapshot->vregs.save_vr,
++         sizeof(context_.vregs.save_vr));
++  memcpy(&context_.vregs.save_vscr, &context_snapshot->vregs.save_vscr,
++         sizeof(context_.vregs.save_vscr));
++  context_.vregs.save_vrsave = context_snapshot->vregs.save_vrsave;
++}
++
++bool MinidumpContextPPC64Writer::WriteObject(
++    FileWriterInterface* file_writer) {
++  DCHECK_EQ(state(), kStateWritable);
++  return file_writer->Write(&context_, sizeof(context_));
++}
++
++size_t MinidumpContextPPC64Writer::ContextSize() const {
++  DCHECK_GE(state(), kStateFrozen);
++  return sizeof(context_);
++}
++
+ }  // namespace crashpad
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h
+index d4ab936ee..1d22fc59c 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer.h
+@@ -315,6 +315,45 @@ class MinidumpContextMIPS64Writer final : public MinidumpContextWriter {
+   DISALLOW_COPY_AND_ASSIGN(MinidumpContextMIPS64Writer);
+ };
+ 
++class MinidumpContextPPC64Writer final : public MinidumpContextWriter {
++ public:
++  MinidumpContextPPC64Writer();
++  ~MinidumpContextPPC64Writer() override;
++
++  //! \brief Initalizes the MinidumpContextPPC64 based on \a context_snapshot.
++  //!
++  //! \param[in] context_snapshot The context snapshot to use as source data.
++  //!
++  //! \note Valid in #kStateMutable. No mutation of context() may be done before
++  //!     calling this method, and it is not normally necessary to alter
++  //!     context() after calling this method.
++  void InitalizeFromSnapshot(const CPUContextPPC64* context_snapshot);
++
++  //! \brief Returns a pointer to the context structure that this object will
++  //!     write.
++  //!
++  //! \attention This returns a non-`const` pointer to this object’s private
++  //!     data so that a caller can populate the context structure directly.
++  //!     This is done because providing setter interfaces to each field in the
++  //!     context structure would be unwieldy and cumbersome. Care must be taken
++  //!     to populate the context structure correctly. The context structure
++  //!     must only be modified while this object is in the #kStateMutable
++  //!     state.
++  MinidumpContextPPC64* context() { return &context_; }
++
++ protected:
++  // MinidumpWritable:
++  bool WriteObject(FileWriterInterface* file_writer) override;
++
++  // MinidumpContextWriter:
++  size_t ContextSize() const override;
++
++ private:
++  MinidumpContextPPC64 context_;
++
++  DISALLOW_COPY_AND_ASSIGN(MinidumpContextPPC64Writer);
++};
++
+ }  // namespace crashpad
+ 
+ #endif  // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_WRITER_H_
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc
+index 3216a906b..a9fcbe9d8 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc
+@@ -213,6 +213,21 @@ TEST(MinidumpContextWriter, MIPS64_FromSnapshot) {
+       context, ExpectMinidumpContextMIPS64, kSeed);
+ }
+ 
++TEST(MinidumpContextWriter, PPC64_Zeros) {
++  EmptyContextTest<MinidumpContextPPC64Writer, MinidumpContextPPC64>(
++    ExpectMinidumpContextPPC64);
++}
++
++TEST(MinidumpContextWriter, PPC64_FromSnapshot) {
++  constexpr uint32_t kSeed = 64;
++  CPUContextPPC64 context_ppc64;
++  CPUContext context;
++  context.ppc64 = &context_ppc64;
++  InitializeCPUContextPPC64(&context, kSeed);
++  FromSnapshotTest<MinidumpContextPPC64Writer, MinidumpContextPPC64>(
++      context, ExpectMinidumpContextPPC64, kSeed);
++}
++
+ }  // namespace
+ }  // namespace test
+ }  // namespace crashpad
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc
+index a13407605..95dc92524 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc
+@@ -126,6 +126,8 @@ std::string MinidumpMiscInfoDebugBuildString() {
+   static constexpr char kCPU[] = "mips";
+ #elif defined(ARCH_CPU_MIPS64EL)
+   static constexpr char kCPU[] = "mips64";
++#elif defined(ARCH_CPU_PPC64)
++  static constexpr char kCPU[] = "ppc64";
+ #else
+ #error define kCPU for this CPU
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc
+index a51626ccd..61e0b20a1 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/capture_memory.cc
+@@ -111,6 +111,11 @@ void CaptureMemory::PointedToByContext(const CPUContext& context,
+   for (size_t i = 0; i < base::size(context.mipsel->regs); ++i) {
+     MaybeCaptureMemoryAround(delegate, context.mipsel->regs[i]);
+   }
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  MaybeCaptureMemoryAround(delegate, context.ppc64->nip);
++  for (size_t i = 0; i < base::size(context.ppc64->regs); ++i) {
++    MaybeCaptureMemoryAround(delegate, context.ppc64->regs[i]);
++  }
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h
+index 811a72095..f4f83981d 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_architecture.h
+@@ -43,7 +43,10 @@ enum CPUArchitecture {
+   kCPUArchitectureMIPSEL,
+ 
+   //! \brief 64-bit MIPSEL.
+-  kCPUArchitectureMIPS64EL
++  kCPUArchitectureMIPS64EL,
++
++  //! \brief 64-bit PPC64.
++  kCPUArchitecturePPC64
+ };
+ 
+ }  // namespace crashpad
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc
+index 6fb8d7e71..b01f7cad1 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.cc
+@@ -169,6 +169,8 @@ uint64_t CPUContext::InstructionPointer() const {
+       return arm->pc;
+     case kCPUArchitectureARM64:
+       return arm64->pc;
++    case kCPUArchitecturePPC64:
++      return ppc64->nip;
+     default:
+       NOTREACHED();
+       return ~0ull;
+@@ -185,6 +187,8 @@ uint64_t CPUContext::StackPointer() const {
+       return arm->sp;
+     case kCPUArchitectureARM64:
+       return arm64->sp;
++    case kCPUArchitecturePPC64:
++      return ppc64->regs[1];
+     default:
+       NOTREACHED();
+       return ~0ull;
+@@ -196,6 +200,7 @@ bool CPUContext::Is64Bit() const {
+     case kCPUArchitectureX86_64:
+     case kCPUArchitectureARM64:
+     case kCPUArchitectureMIPS64EL:
++    case kCPUArchitecturePPC64:
+       return true;
+     case kCPUArchitectureX86:
+     case kCPUArchitectureARM:
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h
+index fb23c4679..eebede63c 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/cpu_context.h
+@@ -352,6 +352,24 @@ struct CPUContextMIPS64 {
+   uint64_t fir;
+ };
+ 
++//! \brief A context structure carrying PPC64 CPU state.
++struct CPUContextPPC64 {
++  uint64_t nip;
++  uint64_t msr;
++  uint64_t regs[32];
++  uint64_t ccr;
++  uint64_t xer;
++  uint64_t lnk;
++  uint64_t ctr;
++  double fpregs[32];
++  double fpscr;
++  struct {
++    uint128_struct save_vr[32];
++    uint128_struct save_vscr;
++    uint32_t save_vrsave;
++  } vregs;
++};
++
+ //! \brief A context structure capable of carrying the context of any supported
+ //!     CPU architecture.
+ struct CPUContext {
+@@ -382,6 +400,7 @@ struct CPUContext {
+     CPUContextARM64* arm64;
+     CPUContextMIPS* mipsel;
+     CPUContextMIPS64* mips64;
++    CPUContextPPC64* ppc64;
+   };
+ };
+ 
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h
+index 9f46a4897..aa677c4eb 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h
+@@ -15,6 +15,7 @@
+ #ifndef CRASHPAD_SNAPSHOT_LINUX_CPU_CONTEXT_LINUX_H_
+ #define CRASHPAD_SNAPSHOT_LINUX_CPU_CONTEXT_LINUX_H_
+ 
++#include <cstring>
+ #include "build/build_config.h"
+ #include "snapshot/cpu_context.h"
+ #include "snapshot/linux/signal_context.h"
+@@ -174,6 +175,78 @@ void InitializeCPUContextMIPS(
+ 
+ #endif  // ARCH_CPU_MIPS_FAMILY || DOXYGEN
+ 
++#if defined(ARCH_CPU_PPC64_FAMILY) || DOXYGEN
++
++//! \brief Initalizes a CPUContextPPC64 structure from native context
++//!     structures on Linux.
++//!
++//! \param[in] thread_context The native thread context.
++//! \param[in] float_context The native float context.
++//! \param[in] vector_context The native vector context.
++//! \param[out] context The CPUContextPPC64 structure to initalize.
++template <typename Traits>
++void InitializeCPUContextPPC64(
++    const ThreadContext::t64_t& thread_context,
++    const FloatContext::f64_t& float_context,
++    const VectorContext::v64_t& vector_context,
++    typename Traits::CPUContext* context) {
++
++  memcpy(context->regs, thread_context.gpr, sizeof(context->regs));
++  context->nip = thread_context.nip;
++  context->msr = thread_context.msr;
++  context->ccr = thread_context.ccr;
++  context->xer = thread_context.xer;
++  context->lnk = thread_context.lnk;
++  context->ctr = thread_context.ctr;
++
++  memcpy(context->fpregs, float_context.fpregs, sizeof(context->fpregs));
++  context->fpscr = float_context.fpscr;
++
++  for (uint8_t i = 0; i < 32; i++) {
++    context->vregs.save_vr[i] = {
++      (((uint64_t)vector_context.vrregs[i][0]) << 32) |
++        vector_context.vrregs[i][1],
++      (((uint64_t)vector_context.vrregs[i][2]) << 32) |
++        vector_context.vrregs[i][3]
++    };
++  }
++  context->vregs.save_vrsave = vector_context.vrsave;
++  context->vregs.save_vscr = {0, (uint64_t)vector_context.vscr.vscr_word};
++}
++
++template <typename Traits>
++void InitializeCPUContextPPC64(
++    const SignalThreadContext64 &thread_context,
++    const SignalFloatContext64 &float_context,
++    const SignalVectorContext64 &vector_context,
++    typename Traits::CPUContext* context) {
++
++  memcpy(context->regs, thread_context.regs, sizeof(context->regs));
++  context->nip = thread_context.nip;
++  context->msr = thread_context.msr;
++  context->ccr = thread_context.ccr;
++  context->xer = thread_context.xer;
++  context->lnk = thread_context.lnk;
++  context->ctr = thread_context.ctr;
++
++  memcpy(context->fpregs, float_context.regs, sizeof(context->fpregs));
++  context->fpscr = float_context.fpscr;
++
++  for (uint8_t i = 0; i < 32; i++) {
++    context->vregs.save_vr[i] = {
++      (((uint64_t)vector_context.vrregs[i][0]) << 32) |
++        vector_context.vrregs[i][1],
++      (((uint64_t)vector_context.vrregs[i][2]) << 32) |
++        vector_context.vrregs[i][3]
++    };
++  }
++  context->vregs.save_vrsave = vector_context.vrsave;
++  context->vregs.save_vscr = {0, (uint64_t)vector_context.vscr.vscr_word};
++}
++
++
++#endif
++
+ }  // namespace internal
+ }  // namespace crashpad
+ 
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc
+index be22c9031..c5df23d1b 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc
+@@ -159,9 +159,11 @@ void TestAgainstTarget(PtraceConnection* connection) {
+           const bool is_vdso_mapping =
+               device == 0 && inode == 0 && mapping_name == "[vdso]";
+           static constexpr char kPrefix[] = "linux-vdso.so.";
++          static constexpr char kPrefix64[] = "linux-vdso64.so.";
+           return is_vdso_mapping ==
+                  (module_name.empty() ||
+-                  module_name.compare(0, strlen(kPrefix), kPrefix) == 0);
++                  module_name.compare(0, strlen(kPrefix), kPrefix) == 0 ||
++                  module_name.compare(0, strlen(kPrefix64), kPrefix64) == 0);
+         },
+         module_mapping->name,
+         module_mapping->device,
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc
+index cd40b3b12..6bcf23b6f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc
+@@ -323,6 +323,69 @@ bool ExceptionSnapshotLinux::ReadContext<ContextTraits64>(
+       reader, context_address, context_.mips64);
+ }
+ 
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++
++template <typename Traits>
++static bool ReadContext(ProcessReaderLinux* reader,
++                        LinuxVMAddress context_address,
++                        typename Traits::CPUContext* dest_context) {
++  const ProcessMemory* memory = reader->Memory();
++
++  LinuxVMAddress gp_regs_address = context_address +
++                                   offsetof(UContext, mcontext) +
++                                   offsetof(typename Traits::MContext, gp_regs);
++
++  typename Traits::SignalThreadContext thread_context;
++  if (!memory->Read(gp_regs_address, sizeof(thread_context), &thread_context)) {
++    LOG(ERROR) << "Couldn't read gp_regs!";
++    return false;
++  }
++
++  LinuxVMAddress fp_regs_address = context_address +
++                                   offsetof(UContext, mcontext) +
++                                   offsetof(typename Traits::MContext, fp_regs);
++
++  typename Traits::SignalFloatContext fp_context;
++  if (!memory->Read(fp_regs_address, sizeof(fp_context), &fp_context)) {
++    LOG(ERROR) << "Couldn't read fp_regs!";
++    return false;
++  }
++
++  LinuxVMAddress v_regs_ptr_address = context_address +
++                                  offsetof(UContext, mcontext) +
++                                  offsetof(typename Traits::MContext, vmx_reserve) + 8;
++
++  typename Traits::SignalVectorContext v_context;
++  if (!memory->Read(v_regs_ptr_address, sizeof(v_context), &v_context)) {
++    LOG(ERROR) << "Couldn't read v_regs!";
++    return false;
++  }
++
++  InitializeCPUContextPPC64<ContextTraits64>(thread_context, fp_context,
++                            v_context, dest_context);
++
++  return true;
++}
++
++template<>
++bool ExceptionSnapshotLinux::ReadContext<ContextTraits64>(
++    ProcessReaderLinux* reader,
++    LinuxVMAddress context_address) {
++  context_.architecture = kCPUArchitecturePPC64;
++  context_.ppc64 = &context_union_.ppc64;
++
++  return internal::ReadContext<ContextTraits64>(
++      reader, context_address, context_.ppc64);
++}
++
++template<>
++bool ExceptionSnapshotLinux::ReadContext<ContextTraits32>(
++    ProcessReaderLinux* reader,
++    LinuxVMAddress context_address) {
++  // PPC64 is 64-bit
++  return false;
++}
++
+ #endif  // ARCH_CPU_X86_FAMILY
+ 
+ bool ExceptionSnapshotLinux::Initialize(ProcessReaderLinux* process_reader,
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h
+index ea0cd2106..e42df520f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h
+@@ -84,6 +84,8 @@ class ExceptionSnapshotLinux final : public ExceptionSnapshot {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+     CPUContextMIPS mipsel;
+     CPUContextMIPS64 mips64;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    CPUContextPPC64 ppc64;
+ #endif
+   } context_union_;
+   CPUContext context_;
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc
+index e4ff1ab79..25534dd08 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc
+@@ -296,7 +296,28 @@ void ExpectContext(const CPUContext& actual, const NativeCPUContext& expected) {
+             0);
+ #undef CPU_ARCH_NAME
+ }
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++using NativeCPUContext = ucontext_t;
++
++void InitializeContext(NativeCPUContext* context) {
++  for (size_t reg = 0; reg < 32; ++reg) {
++    context->uc_mcontext.gp_regs[reg] = reg;
++  }
++
++  memset(&context->uc_mcontext.fp_regs, 44,
++      sizeof(context->uc_mcontext.fp_regs));
++}
+ 
++void ExpectContext(const CPUContext& actual, const NativeCPUContext& expected) {
++  EXPECT_EQ(actual.architecture, kCPUArchitecturePPC64);
++
++  for (size_t reg = 0; reg < 32; ++reg) {
++    EXPECT_EQ(actual.ppc64->regs[reg], expected.uc_mcontext.gp_regs[reg]);
++  }
++
++  EXPECT_EQ(memcmp(actual.ppc64->fpregs, expected.uc_mcontext.fp_regs,
++            sizeof(actual.ppc64->fpregs)), 0);
++}
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc
+index b96abfe74..df12ca566 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc
+@@ -108,6 +108,8 @@ void ProcessReaderLinux::Thread::InitializeStack(ProcessReaderLinux* reader) {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   stack_pointer = reader->Is64Bit() ? thread_info.thread_context.t64.regs[29]
+                                     : thread_info.thread_context.t32.regs[29];
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  stack_pointer = thread_info.thread_context.t64.gpr[1];
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc
+index 5b5723616..049c32858 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux_test.cc
+@@ -612,6 +612,8 @@ bool WriteTestModule(const base::FilePath& module_path) {
+   module.ehdr.e_machine = EM_AARCH64;
+ #elif defined(ARCH_CPU_MIPSEL) || defined(ARCH_CPU_MIPS64EL)
+   module.ehdr.e_machine = EM_MIPS;
++#elif defined(ARCH_CPU_PPC64)
++  module.ehdr.e_machine = EM_PPC64;
+ #endif
+ 
+   module.ehdr.e_version = EV_CURRENT;
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+index 110024680..a1f2da259 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+@@ -422,6 +422,89 @@ static_assert(offsetof(UContext<ContextTraits64>, mcontext.fpregs) ==
+               "context offset mismatch");
+ #endif
+ 
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++
++struct SignalThreadContext64 {
++  uint64_t regs[32];
++  uint64_t nip;
++  uint64_t msr;
++  uint64_t orig_r3;
++  uint64_t ctr;
++  uint64_t lnk;
++  uint64_t xer;
++  uint64_t ccr;
++  uint64_t softe;
++  uint64_t trap;
++  uint64_t dar;
++  uint64_t dsisr;
++  uint64_t result;
++  uint64_t dscr;
++  uint64_t fpr0[3];
++};
++
++struct SignalFloatContext64 {
++  double regs[32];
++  double fpscr;
++};
++
++struct SignalVectorContext64 {
++  int32_t vrregs[32][4];
++  struct {
++    int32_t __pad[3];
++    int32_t vscr_word;
++  } vscr;
++  int32_t vrsave;
++  int32_t __pad[3];
++} __attribute__((__aligned__(16)));
++
++
++#pragma pack(pop)
++struct MContext64 {
++  uint64_t reserved[4];
++  int32_t signal;
++  int32_t __pad0;
++  uint64_t handler;
++  uint64_t oldmask;
++  uint64_t pt_regs_ptr;
++  SignalThreadContext64 gp_regs;
++  SignalFloatContext64  fp_regs;
++  SignalVectorContext64 *v_regs;
++  int64_t vmx_reserve[69];
++};
++
++struct ContextTraits64 : public Traits64 {
++  using MContext = MContext64;
++  using SignalThreadContext = SignalThreadContext64;
++  using SignalFloatContext = SignalFloatContext64;
++  using SignalVectorContext = SignalVectorContext64;
++  using CPUContext = CPUContextPPC64;
++};
++
++struct ContextTraits32 : public Traits32 {};
++
++struct UContext {
++  uint64_t flags;
++  uint64_t link;
++  SignalStack<ContextTraits64> stack;
++  Sigset<ContextTraits64> sigmask;
++  MContext64 mcontext;
++};
++#pragma pack(push, 1)
++
++static_assert(sizeof(UContext) == sizeof(ucontext_t),
++              "ucontext_t size mismatch");
++static_assert(sizeof(MContext64) == sizeof(mcontext_t),
++              "mcontext_t size mismatch");
++static_assert(sizeof(SignalThreadContext64) == sizeof(gregset_t),
++              "gregset_t size mismatch");
++static_assert(sizeof(SignalFloatContext64) == sizeof(fpregset_t),
++              "fpregset_t size mismatch");
++static_assert(sizeof(SignalVectorContext64) == sizeof(vrregset_t),
++              "vrregset_t size mismatch");
++static_assert(offsetof(UContext, mcontext) ==
++              offsetof(ucontext_t, uc_mcontext), "mcontext offset mismatch");
++static_assert(offsetof(MContext64, gp_regs) ==
++              offsetof(mcontext_t, gp_regs), "gp_regs offset mismatch");
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc
+index 8564d3d45..b690ecd48 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/system_snapshot_linux.cc
+@@ -203,6 +203,8 @@ CPUArchitecture SystemSnapshotLinux::GetCPUArchitecture() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   return process_reader_->Is64Bit() ? kCPUArchitectureMIPS64EL
+                                     : kCPUArchitectureMIPSEL;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  return kCPUArchitecturePPC64;
+ #else
+ #error port to your architecture
+ #endif
+@@ -218,6 +220,9 @@ uint32_t SystemSnapshotLinux::CPURevision() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   // Not implementable on MIPS
+   return 0;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  // Not yet implemented on PPC64
++  return 0;
+ #else
+ #error port to your architecture
+ #endif
+@@ -238,6 +243,9 @@ std::string SystemSnapshotLinux::CPUVendor() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   // Not implementable on MIPS
+   return std::string();
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  // Not yet implemented on PPC64
++  return std::string();
+ #else
+ #error port to your architecture
+ #endif
+@@ -371,6 +379,9 @@ bool SystemSnapshotLinux::NXEnabled() const {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   // Not implementable on MIPS
+   return false;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  // Not yet implemented on PPC64
++  return false;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc
+index e3e2bebdd..8ef43752e 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.cc
+@@ -186,6 +186,14 @@ bool ThreadSnapshotLinux::Initialize(ProcessReaderLinux* process_reader,
+         thread.thread_info.float_context.f32,
+         context_.mipsel);
+   }
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  context_.architecture = kCPUArchitecturePPC64;
++  context_.ppc64 = &context_union_.ppc64;
++  InitializeCPUContextPPC64<ContextTraits64>(
++      thread.thread_info.thread_context.t64,
++      thread.thread_info.float_context.f64,
++      thread.thread_info.vector_context.v64,
++      context_.ppc64);
+ #else
+ #error Port.
+ #endif
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h
+index 44cc6f6d9..d4136461e 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/thread_snapshot_linux.h
+@@ -68,6 +68,8 @@ class ThreadSnapshotLinux final : public ThreadSnapshot {
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+     CPUContextMIPS mipsel;
+     CPUContextMIPS64 mips64;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    CPUContextPPC64 ppc64;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc
+index d3d5ebdfb..3fd730cb5 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/auxiliary_vector.cc
+@@ -56,6 +56,11 @@ bool AuxiliaryVector::Read(PtraceConnection* connection) {
+     if (type == AT_IGNORE) {
+       continue;
+     }
++#if defined(ARCH_CPU_PPC64_FAMILY)
++    if (type == AT_IGNOREPPC) {
++      continue;
++    }
++#endif
+     if (!MapInsertOrReplace(&values_, type, value, nullptr)) {
+       LOG(ERROR) << "duplicate auxv entry";
+       return false;
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc
+index 155a1e0c6..5e50ceb5f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptrace_broker.cc
+@@ -94,8 +94,8 @@ int PtraceBroker::Run() {
+ }
+ 
+ bool PtraceBroker::AllocateAttachments() {
+-  constexpr size_t page_size = 4096;
+-  constexpr size_t alloc_size =
++  static size_t page_size = getpagesize();
++  size_t alloc_size =
+       (sizeof(ScopedPtraceAttach) + page_size - 1) & ~(page_size - 1);
+   void* alloc = sbrk(alloc_size);
+   if (reinterpret_cast<intptr_t>(alloc) == -1) {
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc
+index 557e0d363..08ae434b8 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/ptracer.cc
+@@ -398,6 +398,64 @@ bool GetThreadArea64(pid_t tid,
+   return true;
+ }
+ 
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++// PPC64 has had HAVE_ARCH_TRACEHOOK set since 2.6.27 (even before x86 had it).
++// That means we can simply use PTRACE_GETREGESET.
++
++template <typename Destination>
++bool GetRegisterSet(pid_t tid, int set, Destination* dest, bool can_log) {
++  iovec iov;
++  iov.iov_base = reinterpret_cast<void*>(dest);
++  iov.iov_len = sizeof(*dest);
++  if (ptrace(PTRACE_GETREGSET, tid, reinterpret_cast<void*>(set), &iov) != 0) {
++    PLOG_IF(ERROR, can_log) << "ptrace";
++    return false;
++  }
++  if (iov.iov_len != sizeof(*dest)) {
++    LOG_IF(ERROR, can_log) << "Unexpected registers size";
++    return false;
++  }
++  return true;
++}
++
++bool GetVectorRegisters64(pid_t tid,
++                          VectorContext* context,
++                          bool can_log) {
++  return GetRegisterSet(tid, NT_PPC_VMX, &context->v64, can_log);
++}
++
++bool GetFloatingPointRegisters64(pid_t tid,
++                                 FloatContext* context,
++                                 bool can_log) {
++  return GetRegisterSet(tid, NT_PRFPREG, &context->f64, can_log);
++}
++
++bool GetThreadArea64(pid_t tid,
++                     const ThreadContext& context,
++                     LinuxVMAddress* address,
++                     bool can_log) {
++  // PPC64 doesn't have PTRACE_GET_THREAD_AREA since the thread pointer
++  // is stored in GPR 13.
++  ThreadContext::t64_t tc;
++  if (!GetRegisterSet(tid, NT_PRSTATUS, &tc, can_log)) {
++    LOG_IF(ERROR, can_log) << "Unable to get thread pointer!";
++    return false;
++  }
++
++  *address = tc.gpr[13];
++
++  return true;
++}
++
++// Stubs for 32-bit functions not applicable on PPC64
++bool GetFloatingPointRegisters32(pid_t tid,
++                                 FloatContext* context,
++                                 bool can_log) { return false; }
++bool GetThreadArea32(pid_t tid,
++                     const ThreadContext &context,
++                     LinuxVMAddress *address,
++                     bool can_log) { return false; }
++
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -494,6 +552,9 @@ bool Ptracer::GetThreadInfo(pid_t tid, ThreadInfo* info) {
+   if (is_64_bit_) {
+     return GetGeneralPurposeRegisters64(tid, &info->thread_context, can_log_) &&
+            GetFloatingPointRegisters64(tid, &info->float_context, can_log_) &&
++#if defined(ARCH_CPU_PPC64_FAMILY)
++           GetVectorRegisters64(tid, &info->vector_context, can_log_) &&
++#endif
+            GetThreadArea64(tid,
+                            info->thread_context,
+                            &info->thread_specific_data_address,
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+index 5b55c24a7..dea0d1f39 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -28,6 +28,10 @@
+ #include <android/api-level.h>
+ #endif
+ 
++#if defined(ARCH_CPU_PPC64_FAMILY)
++#include <sys/ucontext.h>
++#endif
++
+ namespace crashpad {
+ 
+ //! \brief The set of general purpose registers for an architecture family.
+@@ -79,6 +83,8 @@ union ThreadContext {
+     uint32_t cp0_status;
+     uint32_t cp0_cause;
+     uint32_t padding1_;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // PPC64 is 64-bit
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -132,6 +138,21 @@ union ThreadContext {
+     uint64_t cp0_badvaddr;
+     uint64_t cp0_status;
+     uint64_t cp0_cause;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // Reflects struct pt_regs in asm/ptrace.h.
++    uint64_t gpr[32];
++    uint64_t nip;
++    uint64_t msr;
++    uint64_t orig_gpr3;
++    uint64_t ctr;
++    uint64_t lnk;
++    uint64_t xer;
++    uint64_t ccr;
++    uint64_t softe;
++    uint64_t trap;
++    uint64_t dar;
++    uint64_t dsisr;
++    uint64_t result;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -143,6 +164,8 @@ union ThreadContext {
+   using NativeThreadContext = user_regs;
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+ // No appropriate NativeThreadsContext type available for MIPS
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  using NativeThreadContext = struct pt_regs;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY || ARCH_CPU_ARM64
+@@ -218,6 +241,9 @@ union FloatContext {
+     } fpregs[32];
+     uint32_t fpcsr;
+     uint32_t fpu_id;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // Crashpad's PPC support is 64-bit only, so this
++    // 32bit-only struct is declared as empty.
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -252,6 +278,10 @@ union FloatContext {
+     double fpregs[32];
+     uint32_t fpcsr;
+     uint32_t fpu_id;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++    // Reflects fpregset_t in sys/ucontext.h
++    double fpregs[32];
++    double fpscr;
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86_FAMILY
+@@ -280,6 +310,8 @@ union FloatContext {
+   static_assert(sizeof(f64) == sizeof(user_fpsimd_struct), "Size mismatch");
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+ // No appropriate floating point context native type for available MIPS.
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  static_assert(sizeof(f64) == sizeof(fpregset_t), "Size mismatch");
+ #else
+ #error Port.
+ #endif  // ARCH_CPU_X86
+@@ -287,6 +319,26 @@ union FloatContext {
+ static_assert(std::is_standard_layout<FloatContext>::value,
+               "Not standard layout");
+ 
++//! \brief The vector registers used for an architecture family
++union VectorContext {
++  struct v32_t {} v32;
++#if defined(ARCH_CPU_PPC64_FAMILY)
++  __attribute__((__aligned__(16))) // Vector context must be doubleword aligned.
++#endif
++  struct v64_t {
++#if defined(ARCH_CPU_PPC64_FAMILY)
++    // Reflects vrregset_t in sys/ucontext.h
++    uint32_t vrregs[32][4];
++    struct {
++      uint32_t __pad[3];
++      uint32_t vscr_word;
++    } vscr;
++    uint32_t vrsave;
++    uint32_t __pad[3];
++#endif
++  } v64;
++};
++
+ //! \brief A collection of `ptrace`-able information about a thread.
+ struct ThreadInfo {
+   ThreadInfo();
+@@ -298,6 +350,9 @@ struct ThreadInfo {
+   //! \brief The floating point registers for the thread.
+   FloatContext float_context;
+ 
++  //! \brief (Optional) The vector registers used for the thread.
++  VectorContext vector_context;
++
+   //! \brief The thread-local storage address for the thread.
+   LinuxVMAddress thread_specific_data_address;
+ };
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h
+index a88a10336..b0d6578bd 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context.h
+@@ -70,6 +70,7 @@ using NativeCPUContext = ucontext_t;
+ //!     macOS/Linux/Fuchsia | x86_64       | `%%rdi`
+ //!     Linux               | ARM/ARM64    | `r0`/`x0`
+ //!     Linux               | MIPS/MIPS64  | `$a0`
++//!     Linux               | PPC64        | `r3`
+ //!
+ //!     Additionally, the value `LR` on ARM/ARM64 will be the return address of
+ //!     this function.
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S
+index 52215ee5d..b3e4a3ec7 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_linux.S
+@@ -32,7 +32,7 @@
+   .balign 4, 0x0
+   .type CAPTURECONTEXT_SYMBOL, %function
+   .type CAPTURECONTEXT_SYMBOL2, %function
+-#elif defined(__mips__)
++#elif defined(__mips__) || defined(__powerpc64__)
+   .balign 4, 0x0
+ #endif
+ 
+@@ -423,4 +423,214 @@ CAPTURECONTEXT_SYMBOL2:
+   jr $ra
+ 
+   .set at
++#elif defined(__powerpc64__)
++  // Store r0-r31
++  std 0, 0xe8(3)   // context->uc_mcontext.gp_regs[0]
++  std 1, 0xf0(3)   // context->uc_mcontext.gp_regs[1]
++  std 2, 0xf8(3)   // context->uc_mcontext.gp_regs[2]
++  // note that r3's original value was lost
++  std 3, 0x100(3)  // context->uc_mcontext.gp_regs[3]
++  std 4, 0x108(3)  // context->uc_mcontext.gp_regs[4]
++  std 5, 0x110(3)  // context->uc_mcontext.gp_regs[5]
++  std 6, 0x118(3)  // context->uc_mcontext.gp_regs[6]
++  std 7, 0x120(3)  // context->uc_mcontext.gp_regs[7]
++  std 8, 0x128(3)  // context->uc_mcontext.gp_regs[8]
++  std 9, 0x130(3)  // context->uc_mcontext.gp_regs[9]
++  std 10, 0x138(3) // context->uc_mcontext.gp_regs[10]
++  std 11, 0x140(3) // context->uc_mcontext.gp_regs[11]
++  std 12, 0x148(3) // context->uc_mcontext.gp_regs[12]
++  std 13, 0x150(3) // context->uc_mcontext.gp_regs[13]
++  std 14, 0x158(3) // context->uc_mcontext.gp_regs[14]
++  std 15, 0x160(3) // context->uc_mcontext.gp_regs[15]
++  std 16, 0x168(3) // context->uc_mcontext.gp_regs[16]
++  std 17, 0x170(3) // context->uc_mcontext.gp_regs[17]
++  std 18, 0x178(3) // context->uc_mcontext.gp_regs[18]
++  std 19, 0x180(3) // context->uc_mcontext.gp_regs[19]
++  std 20, 0x188(3) // context->uc_mcontext.gp_regs[20]
++  std 21, 0x190(3) // context->uc_mcontext.gp_regs[21]
++  std 22, 0x198(3) // context->uc_mcontext.gp_regs[22]
++  std 23, 0x1a0(3) // context->uc_mcontext.gp_regs[23]
++  std 24, 0x1a8(3) // context->uc_mcontext.gp_regs[24]
++  std 25, 0x1b0(3) // context->uc_mcontext.gp_regs[25]
++  std 26, 0x1b8(3) // context->uc_mcontext.gp_regs[26]
++  std 27, 0x1c0(3) // context->uc_mcontext.gp_regs[27]
++  std 28, 0x1c8(3) // context->uc_mcontext.gp_regs[28]
++  std 29, 0x1d0(3) // context->uc_mcontext.gp_regs[29]
++  std 30, 0x1d8(3) // context->uc_mcontext.gp_regs[30]
++  std 31, 0x1e0(3) // context->uc_mcontext.gp_regs[31]
++
++  // For NIP, we can use the value in the link register
++  mflr 0
++  std 0, 0x1e8(3) // context->uc_mcontext.gp_regs[PT_NIP]
++
++  // CTR
++  mfctr 0
++  std 0, 0x200(3) // context->uc_mcontext.gp_regs[PT_CTR]
++
++  // For LNK, we'll use the caller's LR save area (2 stack frames up).
++  // r4 can be used as a scratch register since it has already been saved.
++  ld 4, 0(1)
++  ld 4, 16(4)
++  std 4, 0x208(3) // context->uc_mcontext.gp_regs[PT_LNK]
++
++  // XER
++  mfxer 0
++  std 0, 0x210(3) // context->uc_mcontext.gp_regs[PT_XER]
++
++  // CCR
++  mfcr 0
++  std 0, 0x218(3) // context->uc_mcontext.gp_regs[PT_CCR]
++
++  // MSR, orig_r3, MQ, TRAP, DAR, DSISR, RESULT, DSCR,
++  // not used or not relevant,  zero them out.
++  li 4, 0
++  std 4, 0x1f0(3) // context->uc_mcontext.gp_regs[PT_MSR]
++  std 4, 0x1f8(3) // context->uc_mcontext.gp_regs[PT_ORIG_R3]
++  std 4, 0x220(3) // context->uc_mcontext.gp_regs[PT_MQ]
++  std 4, 0x228(3) // context->uc_mcontext.gp_regs[PT_TRAP]
++  std 4, 0x230(3) // context->uc_mcontext.gp_regs[PT_DAR]
++  std 4, 0x238(3) // context->uc_mcontext.gp_regs[PT_DSISR]
++  std 4, 0x240(3) // context->uc_mcontext.gp_regs[PT_RESULT]
++  std 4, 0x248(3) // context->uc_mcontext.gp_regs[PT_DSCR]
++
++  // Update context->uc_mcontext.regs to point to gp_regs
++  addi 0, 3, 0xe8
++  std 0, 0xe0(3)
++
++  // Save floating point registers 0-31
++  stfd 0, 0x268(3)  // context->uc_mcontext.fp_regs[0]
++  stfd 1, 0x270(3)  // context->uc_mcontext.fp_regs[1]
++  stfd 2, 0x278(3)  // context->uc_mcontext.fp_regs[2]
++  stfd 3, 0x280(3)  // context->uc_mcontext.fp_regs[3]
++  stfd 4, 0x288(3)  // context->uc_mcontext.fp_regs[4]
++  stfd 5, 0x290(3)  // context->uc_mcontext.fp_regs[5]
++  stfd 6, 0x298(3)  // context->uc_mcontext.fp_regs[6]
++  stfd 7, 0x2a0(3)  // context->uc_mcontext.fp_regs[7]
++  stfd 8, 0x2a8(3)  // context->uc_mcontext.fp_regs[8]
++  stfd 9, 0x2b0(3)  // context->uc_mcontext.fp_regs[9]
++  stfd 10, 0x2b8(3) // context->uc_mcontext.fp_regs[10]
++  stfd 11, 0x2c0(3) // context->uc_mcontext.fp_regs[11]
++  stfd 12, 0x2c8(3) // context->uc_mcontext.fp_regs[12]
++  stfd 13, 0x2d0(3) // context->uc_mcontext.fp_regs[13]
++  stfd 14, 0x2d8(3) // context->uc_mcontext.fp_regs[14]
++  stfd 15, 0x2e0(3) // context->uc_mcontext.fp_regs[15]
++  stfd 16, 0x2e8(3) // context->uc_mcontext.fp_regs[16]
++  stfd 17, 0x2f0(3) // context->uc_mcontext.fp_regs[17]
++  stfd 18, 0x2f8(3) // context->uc_mcontext.fp_regs[18]
++  stfd 19, 0x300(3) // context->uc_mcontext.fp_regs[19]
++  stfd 20, 0x308(3) // context->uc_mcontext.fp_regs[20]
++  stfd 21, 0x310(3) // context->uc_mcontext.fp_regs[21]
++  stfd 22, 0x318(3) // context->uc_mcontext.fp_regs[22]
++  stfd 23, 0x320(3) // context->uc_mcontext.fp_regs[23]
++  stfd 24, 0x328(3) // context->uc_mcontext.fp_regs[24]
++  stfd 25, 0x330(3) // context->uc_mcontext.fp_regs[25]
++  stfd 26, 0x338(3) // context->uc_mcontext.fp_regs[26]
++  stfd 27, 0x340(3) // context->uc_mcontext.fp_regs[27]
++  stfd 28, 0x348(3) // context->uc_mcontext.fp_regs[28]
++  stfd 29, 0x350(3) // context->uc_mcontext.fp_regs[29]
++  stfd 30, 0x358(3) // context->uc_mcontext.fp_regs[30]
++  stfd 31, 0x360(3) // context->uc_mcontext.fp_regs[31]
++
++  // FPSCR
++  mffs 0
++  stfd 0, 0x368(3) // context->uc_mcontext.fp_regs[32]
++
++  // Save VMX Vector registers
++  // Update r4 to contain the base address of vmx_reserve
++  addi 4, 3, 0x378
++  // Ensure that it is quadword aligned
++  andi. 5, 4, 0xF
++  beq 1f // No alignment is necessary
++  // Address is doubleword aligned and not quadword aligned, add 8
++  addi 4, 4, 8
++
++1:
++  // Store VMX registers 0-31
++  // r4 will contain the base address
++  // r5 will contain the index
++  li 5, 0
++  stvx 0, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 0]
++  addi 5, 5, 16
++  stvx 1, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 1]
++  addi 5, 5, 16
++  stvx 2, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 2]
++  addi 5, 5, 16
++  stvx 3, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 3]
++  addi 5, 5, 16
++  stvx 4, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 4]
++  addi 5, 5, 16
++  stvx 5, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 5]
++  addi 5, 5, 16
++  stvx 6, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 6]
++  addi 5, 5, 16
++  stvx 7, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 7]
++  addi 5, 5, 16
++  stvx 8, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 8]
++  addi 5, 5, 16
++  stvx 9, 4, 5   // context->uc_mcontext.vmx_reserve[(align) + 9]
++  addi 5, 5, 16
++  stvx 10, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 10]
++  addi 5, 5, 16
++  stvx 11, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 11]
++  addi 5, 5, 16
++  stvx 12, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 12]
++  addi 5, 5, 16
++  stvx 13, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 13]
++  addi 5, 5, 16
++  stvx 14, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 14]
++  addi 5, 5, 16
++  stvx 15, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 15]
++  addi 5, 5, 16
++  stvx 16, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 16]
++  addi 5, 5, 16
++  stvx 17, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 17]
++  addi 5, 5, 16
++  stvx 18, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 18]
++  addi 5, 5, 16
++  stvx 19, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 19]
++  addi 5, 5, 16
++  stvx 20, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 20]
++  addi 5, 5, 16
++  stvx 21, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 21]
++  addi 5, 5, 16
++  stvx 22, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 22]
++  addi 5, 5, 16
++  stvx 23, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 23]
++  addi 5, 5, 16
++  stvx 24, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 24]
++  addi 5, 5, 16
++  stvx 25, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 25]
++  addi 5, 5, 16
++  stvx 26, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 26]
++  addi 5, 5, 16
++  stvx 27, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 27]
++  addi 5, 5, 16
++  stvx 28, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 28]
++  addi 5, 5, 16
++  stvx 29, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 29]
++  addi 5, 5, 16
++  stvx 30, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 30]
++  addi 5, 5, 16
++  stvx 31, 4, 5  // context->uc_mcontext.vmx_reserve[(align) + 31]
++  addi 5, 5, 16
++
++  // VSCR
++  mfvscr 0
++  stvx 0, 4, 5
++  addi 5, 5, 16
++
++  // VRSAVE
++  mfvrsave 0
++  stwx 0, 4, 5
++
++  // Update context->uc_mcontext.v_regs to point to vmx_reserve + alignment.
++  std 4, 0x370(3)
++
++  // Zero out all unused fields
++  li 4, 0
++  std 4, 0xc8(3) // context->uc_mcontext.signal
++  std 4, 0xd0(3) // context->uc_mcontext.handler
++  std 4, 0xd8(3) // context->uc_mcontext.oldmask
++
++  blr
+ #endif  // __i386__
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc
+index cf23c2def..5f264bc92 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test.cc
+@@ -57,7 +57,7 @@ void TestCaptureContext() {
+   uintptr_t pc = ProgramCounterFromContext(context_1);
+ 
+ #if !defined(ADDRESS_SANITIZER) && !defined(ARCH_CPU_MIPS_FAMILY) && \
+-    !defined(MEMORY_SANITIZER)
++    !defined(MEMORY_SANITIZER) && !defined(ARCH_CPU_PPC64_FAMILY)
+   // Sanitizers can cause enough code bloat that the “nearby” check would
+   // likely fail.
+   const uintptr_t kReferencePC =
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc
+index 9fc5db28c..5f69f8dce 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc
+@@ -36,6 +36,8 @@ void SanityCheckContext(const NativeCPUContext& context) {
+   EXPECT_EQ(context.uc_mcontext.regs[0], FromPointerCast<uintptr_t>(&context));
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   EXPECT_EQ(context.uc_mcontext.gregs[4], FromPointerCast<uintptr_t>(&context));
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  EXPECT_EQ(context.uc_mcontext.gp_regs[3], FromPointerCast<uintptr_t>(&context));
+ #endif
+ }
+ 
+@@ -50,6 +52,8 @@ uintptr_t ProgramCounterFromContext(const NativeCPUContext& context) {
+   return context.uc_mcontext.pc;
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   return context.uc_mcontext.pc;
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  return context.uc_mcontext.gp_regs[PT_NIP];
+ #endif
+ }
+ 
+@@ -64,6 +68,8 @@ uintptr_t StackPointerFromContext(const NativeCPUContext& context) {
+   return context.uc_mcontext.sp;
+ #elif defined(ARCH_CPU_MIPS_FAMILY)
+   return context.uc_mcontext.gregs[29];
++#elif defined(ARCH_CPU_PPC64_FAMILY)
++  return context.uc_mcontext.gp_regs[1];
+ #endif
+ }
+ 
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc
+index 58bfa8f83..8fc37c464 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/posix/signals_test.cc
+@@ -46,12 +46,12 @@ bool CanCauseSignal(int sig) {
+   return sig == SIGABRT ||
+          sig == SIGALRM ||
+          sig == SIGBUS ||
+-#if !defined(ARCH_CPU_ARM64)
++#if !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+          sig == SIGFPE ||
+-#endif  // !defined(ARCH_CPU_ARM64)
++#endif  // !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARMEL)
+          sig == SIGILL ||
+ #endif  // defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARMEL)
+          sig == SIGPIPE ||
+          sig == SIGSEGV ||
+ #if defined(OS_MACOSX)
+@@ -117,9 +117,11 @@ void CauseSignal(int sig) {
+       break;
+     }
+ 
+-#if !defined(ARCH_CPU_ARM64)
++#if !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+     // ARM64 has hardware integer division instructions that don’t generate a
+     // trap for divide-by-zero, so this doesn’t produce SIGFPE.
++    //
++    // PPC64 fixed-point division by zero also doesn't produce a SIGFPE.
+     case SIGFPE: {
+       // Optimization makes this tricky, so get zero from a system call likely
+       // to succeed, and try to do something with the result.
+@@ -137,7 +139,7 @@ void CauseSignal(int sig) {
+       fstat(quotient, &stat_buf);
+       break;
+     }
+-#endif  // ARCH_CPU_ARM64
++#endif  // !defined(ARCH_CPU_ARM64) && !defined(ARCH_CPU_PPC64)
+ 
+ #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARMEL)
+     case SIGILL: {
+diff --git a/src/3rdparty/chromium/third_party/dav1d/BUILD.gn b/src/3rdparty/chromium/third_party/dav1d/BUILD.gn
+index 788dc6cff..5fd7e8fda 100644
+--- a/src/3rdparty/chromium/third_party/dav1d/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/dav1d/BUILD.gn
+@@ -182,6 +182,8 @@ static_library("dav1d_8bit") {
+     sources += arm_template_sources
+   } else if (current_cpu == "arm64") {
+     sources += arm_template_sources
++  } else if (current_cpu == "ppc64") {
++    sources += ppc64_template_sources
+   }
+ 
+   cflags = dav1d_copts
+@@ -210,6 +212,8 @@ static_library("dav1d_10bit") {
+     sources += arm_template_sources
+   } else if (current_cpu == "arm64") {
+     sources += arm_template_sources
++  } else if (current_cpu == "ppc64") {
++    sources += ppc64_template_sources
+   }
+ 
+   cflags = dav1d_copts
+@@ -256,6 +260,21 @@ if (current_cpu == "x86" || current_cpu == "x64") {
+       ":dav1d_config",
+     ]
+ 
++    cflags = dav1d_copts
++  }
++} else if (current_cpu == "ppc64") {
++  static_library("dav1d_ppc") {
++    sources = [
++      "libdav1d/src/ppc/cpu.c",
++      "libdav1d/src/ppc/cpu.h",
++    ]
++
++    configs -= [ "//build/config/compiler:chromium_code" ]
++    configs += [
++      "//build/config/compiler:no_chromium_code",
++      ":dav1d_config",
++    ]
++
+     cflags = dav1d_copts
+   }
+ }
+@@ -285,5 +304,7 @@ static_library("dav1d") {
+     }
+   } else if (current_cpu == "arm" || current_cpu == "arm64") {
+     deps += [ ":dav1d_arm" ]
++  } else if (current_cpu == "ppc64") {
++    deps += [ ":dav1d_ppc" ]
+   }
+ }
+diff --git a/src/3rdparty/chromium/third_party/dav1d/config/linux/ppc64/config.h b/src/3rdparty/chromium/third_party/dav1d/config/linux/ppc64/config.h
+new file mode 100644
+index 000000000..9fbbf75cc
+--- /dev/null
++++ b/src/3rdparty/chromium/third_party/dav1d/config/linux/ppc64/config.h
+@@ -0,0 +1,39 @@
++/*
++ * Autogenerated by the Meson build system.
++ * Do not edit, your changes will be lost.
++ */
++
++#pragma once
++
++#define ARCH_AARCH64 0
++
++#define ARCH_ARM 0
++
++#define ARCH_PPC64LE 1
++
++#define ARCH_X86 0
++
++#define ARCH_X86_32 0
++
++#define ARCH_X86_64 0
++
++#define CONFIG_16BPC 1
++
++#define CONFIG_8BPC 1
++
++// #define CONFIG_LOG 1 -- Logging is controlled by Chromium
++
++#define ENDIANNESS_BIG 0
++
++#define HAVE_ASM 1
++
++#define HAVE_CLOCK_GETTIME 1
++
++#define HAVE_DLSYM 1
++
++#define HAVE_GETAUXVAL 1
++
++#define HAVE_POSIX_MEMALIGN 1
++
++#define HAVE_UNISTD_H 1
++
+diff --git a/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni b/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni
+index 458935cd8..f0cbc4aed 100644
+--- a/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni
++++ b/src/3rdparty/chromium/third_party/dav1d/dav1d_generated.gni
+@@ -70,6 +70,11 @@ arm_template_sources = [
+   "libdav1d/src/arm/mc_init_tmpl.c",
+ ]
+ 
++ppc64_template_sources = [
++  "libdav1d/src/ppc/cdef_init_tmpl.c",
++  "libdav1d/src/ppc/looprestoration_init_tmpl.c",
++]
++
+ template_sources = [
+   "libdav1d/src/cdef_apply_tmpl.c",
+   "libdav1d/src/cdef_tmpl.c",
+diff --git a/src/3rdparty/chromium/third_party/dav1d/generate_source.py b/src/3rdparty/chromium/third_party/dav1d/generate_source.py
+index 9ab5e00b8..ad3feffee 100755
+--- a/src/3rdparty/chromium/third_party/dav1d/generate_source.py
++++ b/src/3rdparty/chromium/third_party/dav1d/generate_source.py
+@@ -50,7 +50,8 @@ def WriteGn(fd):
+   WriteArray(fd, "arm32_asm_sources", glob.glob("libdav1d/src/arm/32/*.S"))
+   WriteArray(fd, "arm64_asm_sources", glob.glob("libdav1d/src/arm/64/*.S"))
+   WriteArray(fd, "arm_template_sources", glob.glob("libdav1d/src/arm/*_tmpl.c"))
+-
++  WriteArray(fd, "ppc64_template_sources", glob.glob("libdav1d/src/ppc/*_tmpl.c"))
++ 
+   template_sources = glob.glob("libdav1d/src/*_tmpl.c")
+   WriteArray(fd, "template_sources", template_sources)
+ 
+diff --git a/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h b/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h
+index 0b4bd72f0..a0caa5e71 100644
+--- a/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h
++++ b/src/3rdparty/chromium/third_party/dav1d/libdav1d/src/ppc/types.h
+@@ -51,4 +51,19 @@
+ #define u16l_to_i32(v) ((i32x4) vec_mergel((u16x8) v, vec_splat_u16(0)))
+ #define i16l_to_i32(v) ((i32x4) vec_unpackl((i16x8)v))
+ 
++#if defined(__clang__)
++#undef vec_splats
++#define vec_splats(N)                     \
++    _Generic((N),                         \
++        unsigned char:      ((u8x16)(N)), \
++        signed char:        ((i8x16)(N)), \
++        unsigned short:     ((u16x8)(N)), \
++        signed short:       ((i16x8)(N)), \
++        unsigned int:       ((u32x4)(N)), \
++        signed int:         ((i32x4)(N)), \
++        unsigned long long: ((u64x2)(N)), \
++        signed long long:   ((i64x2)(N))  \
++    )
++#endif
++
+ #endif /* DAV1D_SRC_PPC_TYPES_H */
+diff --git a/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c b/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c
+index b7d586591..cead05021 100644
+--- a/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c
++++ b/src/3rdparty/chromium/third_party/libdrm/src/xf86drm.c
+@@ -51,10 +51,10 @@
+ #include <sys/ioctl.h>
+ #include <sys/time.h>
+ #include <stdarg.h>
+-#ifdef MAJOR_IN_MKDEV
++#if __has_include(<sys/mkdev.h>)
+ #include <sys/mkdev.h>
+ #endif
+-#ifdef MAJOR_IN_SYSMACROS
++#if __has_include(<sys/sysmacros.h>)
+ #include <sys/sysmacros.h>
+ #endif
+ #include <math.h>
+diff --git a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+index 597d8b6e5..99d1ec0c7 100644
+--- a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
++++ b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+@@ -3931,7 +3931,7 @@ struct kernel_statfs {
+       LSS_REG(2, buf);
+       LSS_BODY(void*, mmap2, "0"(__r2));
+     }
+-#else
++#elif !defined(__powerpc64__) /* ppc64 doesn't have mmap2 */
+     #define __NR__mmap2 __NR_mmap2
+     LSS_INLINE _syscall6(void*, _mmap2,            void*, s,
+                          size_t,                   l, int,               p,
+@@ -4042,7 +4042,7 @@ struct kernel_statfs {
+   #if defined(__i386__) ||                                                    \
+       defined(__ARM_ARCH_3__) || defined(__ARM_EABI__) ||                     \
+      (defined(__mips__) && _MIPS_SIM == _MIPS_SIM_ABI32) ||                   \
+-      defined(__PPC__) ||                                                     \
++     (defined(__PPC__) && !defined(__powerpc64__)) ||                                                     \
+      (defined(__s390__) && !defined(__s390x__))
+     /* On these architectures, implement mmap() with mmap2(). */
+     LSS_INLINE void* LSS_NAME(mmap)(void *s, size_t l, int p, int f, int d,
+diff --git a/src/3rdparty/chromium/third_party/pffft/src/pffft.c b/src/3rdparty/chromium/third_party/pffft/src/pffft.c
+index bdac4d784..51e0f2cac 100644
+--- a/src/3rdparty/chromium/third_party/pffft/src/pffft.c
++++ b/src/3rdparty/chromium/third_party/pffft/src/pffft.c
+@@ -100,6 +100,7 @@
+    Altivec support macros 
+ */
+ #if !defined(PFFFT_SIMD_DISABLE) && (defined(__ppc__) || defined(__ppc64__))
++#include <altivec.h>
+ typedef vector float v4sf;
+ #  define SIMD_SZ 4
+ #  define VZERO() ((vector float) vec_splat_u8(0))
+diff --git a/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp b/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp
+index 88eb1c7d3..4be33fa5b 100644
+--- a/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp
++++ b/src/3rdparty/chromium/third_party/skia/src/sksl/SkSLString.cpp
+@@ -240,7 +240,12 @@ String to_string(double value) {
+     if (needsDotZero) {
+         buffer << ".0";
+     }
+-    return String(buffer.str().c_str());
++
++    std::string ret(buffer.str());
++    if (signbit(value) && ret[0] == '.') {
++        ret[0] = '-';
++    }
++    return String(ret.c_str());
+ }
+ 
+ SKSL_INT stoi(const String& s) {
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c
+index 1b2c2ec7a..baa2b2a5d 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c
++++ b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation/sqlite3.c
+@@ -14400,7 +14400,8 @@ typedef INT16_TYPE LogEst;
+ # if defined(i386)      || defined(__i386__)      || defined(_M_IX86) ||    \
+      defined(__x86_64)  || defined(__x86_64__)    || defined(_M_X64)  ||    \
+      defined(_M_AMD64)  || defined(_M_ARM)        || defined(__x86)   ||    \
+-     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
++     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) ||   \
++     defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #   define SQLITE_BYTEORDER    1234
+ # elif defined(sparc)     || defined(__ppc__) || \
+        defined(__ARMEB__) || defined(__AARCH64EB__)
+@@ -187118,7 +187119,7 @@ struct RtreeMatchArg {
+ #if defined(i386)     || defined(__i386__)   || defined(_M_IX86) ||    \
+     defined(__x86_64) || defined(__x86_64__) || defined(_M_X64)  ||    \
+     defined(_M_AMD64) || defined(_M_ARM)     || defined(__x86)   ||    \
+-    defined(__arm__)
++    defined(__arm__) || defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ # define SQLITE_BYTEORDER    1234
+ #elif defined(sparc)    || defined(__ppc__)
+ # define SQLITE_BYTEORDER    4321
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c
+index 734ac355d..43fabe805 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c
++++ b/src/3rdparty/chromium/third_party/sqlite/src/amalgamation_dev/sqlite3.c
+@@ -14314,7 +14314,8 @@ typedef INT16_TYPE LogEst;
+ # if defined(i386)      || defined(__i386__)      || defined(_M_IX86) ||    \
+      defined(__x86_64)  || defined(__x86_64__)    || defined(_M_X64)  ||    \
+      defined(_M_AMD64)  || defined(_M_ARM)        || defined(__x86)   ||    \
+-     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
++     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) ||   \
++     defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #   define SQLITE_BYTEORDER    1234
+ # elif defined(sparc)     || defined(__ppc__) || \
+        defined(__ARMEB__) || defined(__AARCH64EB__)
+@@ -186514,7 +186515,7 @@ struct RtreeMatchArg {
+ #if defined(i386)     || defined(__i386__)   || defined(_M_IX86) ||    \
+     defined(__x86_64) || defined(__x86_64__) || defined(_M_X64)  ||    \
+     defined(_M_AMD64) || defined(_M_ARM)     || defined(__x86)   ||    \
+-    defined(__arm__)
++    defined(__arm__) || defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ # define SQLITE_BYTEORDER    1234
+ #elif defined(sparc)    || defined(__ppc__)
+ # define SQLITE_BYTEORDER    4321
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c b/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c
+index 1eef1a1b5..b53097b7f 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c
++++ b/src/3rdparty/chromium/third_party/sqlite/src/ext/rtree/rtree.c
+@@ -432,7 +432,7 @@ struct RtreeMatchArg {
+ #if defined(i386)     || defined(__i386__)   || defined(_M_IX86) ||    \
+     defined(__x86_64) || defined(__x86_64__) || defined(_M_X64)  ||    \
+     defined(_M_AMD64) || defined(_M_ARM)     || defined(__x86)   ||    \
+-    defined(__arm__)
++    defined(__arm__) || defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ # define SQLITE_BYTEORDER    1234
+ #elif defined(sparc)    || defined(__ppc__)
+ # define SQLITE_BYTEORDER    4321
+diff --git a/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h b/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h
+index 9ef2437b0..6c70148c7 100644
+--- a/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h
++++ b/src/3rdparty/chromium/third_party/sqlite/src/src/sqliteInt.h
+@@ -853,7 +853,8 @@ typedef INT16_TYPE LogEst;
+ # if defined(i386)      || defined(__i386__)      || defined(_M_IX86) ||    \
+      defined(__x86_64)  || defined(__x86_64__)    || defined(_M_X64)  ||    \
+      defined(_M_AMD64)  || defined(_M_ARM)        || defined(__x86)   ||    \
+-     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
++     defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) ||   \
++     defined(__powerpc64__) && (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #   define SQLITE_BYTEORDER    1234
+ # elif defined(sparc)     || defined(__ppc__) || \
+        defined(__ARMEB__) || defined(__AARCH64EB__)
+diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc b/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc
+index dd9ab457e..c005d9599 100644
+--- a/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc
++++ b/src/3rdparty/chromium/third_party/webrtc/modules/desktop_capture/differ_block.cc
+@@ -30,11 +30,7 @@
+   static bool (*diff_proc)(const uint8_t*, const uint8_t*) = nullptr;
+ 
+   if (!diff_proc) {
+-#if defined(WEBRTC_ARCH_ARM_FAMILY) || defined(WEBRTC_ARCH_MIPS_FAMILY)
+-    // For ARM and MIPS processors, always use C version.
+-    // TODO(hclam): Implement a NEON version.
+-    diff_proc = &VectorDifference_C;
+-#else
++#if defined(WEBRTC_ARCH_X86_FAMILY)
+     bool have_sse2 = GetCPUInfo(kSSE2) != 0;
+     // For x86 processors, check if SSE2 is supported.
+     if (have_sse2 && kBlockSize == 32) {
+@@ -44,6 +40,10 @@ bool VectorDifference(const uint8_t* image1, const uint8_t* image2) {
+     } else {
+       diff_proc = &VectorDifference_C;
+     }
++#else
++    // For other processors, always use C version.
++    // TODO(hclam): Implement a NEON version.
++    diff_proc = &VectorDifference_C;
+ #endif
+   }
+ 
+diff --git a/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h b/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h
+index ed216e660..25d36c071 100644
+--- a/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h
++++ b/src/3rdparty/chromium/third_party/webrtc/rtc_base/system/arch.h
+@@ -50,6 +50,18 @@
+ #elif defined(__EMSCRIPTEN__)
+ #define WEBRTC_ARCH_32_BITS
+ #define WEBRTC_ARCH_LITTLE_ENDIAN
++#elif defined(__PPC__)
++#define WEBRTC_ARCH_PPC_FAMILY
++#if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
++#define WEBRTC_ARCH_LITTLE_ENDIAN
++#else
++#define WEBRTC_ARCH_BIG_ENDIAN
++#endif
++#if defined(__LP64__)
++#define WEBRTC_ARCH_64_BITS
++#else
++#define WEBRTC_ARCH_32_BITS
++#endif
+ #else
+ #error Please add support for your architecture in rtc_base/system/arch.h
+ #endif
+diff --git a/src/3rdparty/chromium/v8/BUILD.gn b/src/3rdparty/chromium/v8/BUILD.gn
+index ab20142de..001921c59 100644
+--- a/src/3rdparty/chromium/v8/BUILD.gn
++++ b/src/3rdparty/chromium/v8/BUILD.gn
+@@ -678,6 +678,12 @@ config("toolchain") {
+     }
+     if (host_byteorder == "little") {
+       defines += [ "V8_TARGET_ARCH_PPC_LE" ]
++        cflags += [
++        # Enable usage of AltiVec, VSX, and other POWER8 and higher features
++        "-mcpu=power8",
++        "-maltivec",
++        "-mvsx",
++      ]
+     } else if (host_byteorder == "big") {
+       defines += [ "V8_TARGET_ARCH_PPC_BE" ]
+       if (current_os == "aix") {
diff --git a/srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch b/srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch
new file mode 100644
index 000000000000..4cd12a7fb419
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0091-chromium-ppc64le-musl.patch
@@ -0,0 +1,185 @@
+diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+index a6aec544e..2a4a7f1bc 100644
+--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
++++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h
+@@ -16,7 +16,7 @@
+ #if defined(__mips__)
+ // sys/user.h in eglibc misses size_t definition
+ #include <stddef.h>
+-#elif defined(__powerpc64__)
++#elif defined(__powerpc64__) && defined(__GLIBC__)
+ // Manually define greg_t on ppc64
+ typedef unsigned long long greg_t;
+ #endif
+@@ -361,11 +361,11 @@ typedef struct pt_regs regs_struct;
+ #define SECCOMP_ARCH AUDIT_ARCH_PPC64
+ #endif
+ 
+-#define SECCOMP_REG(_ctx, _reg) ((_ctx)->uc_mcontext.regs->gpr[_reg])
++#define SECCOMP_REG(_ctx, _reg) (((struct pt_regs *)(_ctx)->uc_mcontext.regs)->gpr[_reg])
+ 
+ #define SECCOMP_RESULT(_ctx) SECCOMP_REG(_ctx, 3)
+ #define SECCOMP_SYSCALL(_ctx) SECCOMP_REG(_ctx, 0)
+-#define SECCOMP_IP(_ctx) (_ctx)->uc_mcontext.regs->nip
++#define SECCOMP_IP(_ctx) ((struct pt_regs *)(_ctx)->uc_mcontext.regs)->nip
+ #define SECCOMP_PARM1(_ctx) SECCOMP_REG(_ctx, 3)
+ #define SECCOMP_PARM2(_ctx) SECCOMP_REG(_ctx, 4)
+ #define SECCOMP_PARM3(_ctx) SECCOMP_REG(_ctx, 5)
+diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+index 10fa5fd07..30b7b3851 100644
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc
+@@ -497,9 +497,9 @@ void Syscall::PutValueInUcontext(intptr_t ret_val, ucontext_t* ctx) {
+   // Same as MIPS, need to invert ret and set error register (cr0.SO)
+   if (ret_val <= -1 && ret_val >= -4095) {
+     ret_val = -ret_val;
+-    ctx->uc_mcontext.regs->ccr |= (1 << 28);
++    ((struct pt_regs *)ctx->uc_mcontext.regs)->ccr |= (1 << 28);
+   } else {
+-    ctx->uc_mcontext.regs->ccr &= ~(1 << 28);
++    ((struct pt_regs *)ctx->uc_mcontext.regs)->ccr &= ~(1 << 28);
+   }
+ #endif
+   SECCOMP_RESULT(ctx) = static_cast<greg_t>(ret_val);
+diff --git a/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h b/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h
+index cdce9bf8a..73d77dda4 100644
+--- a/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h
++++ b/src/3rdparty/chromium/third_party/abseil-cpp/absl/base/internal/unscaledcycleclock.h
+@@ -46,7 +46,7 @@
+ 
+ // The following platforms have an implementation of a hardware counter.
+ #if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__) || \
+-  defined(__powerpc__) || defined(__ppc__) || \
++  ((defined(__powerpc__) || defined(__ppc__)) && defined(__GLIBC__)) || \
+   defined(_M_IX86) || defined(_M_X64)
+ #define ABSL_HAVE_UNSCALED_CYCLECLOCK_IMPLEMENTATION 1
+ #else
+--- a/src/3rdparty/chromium/third_party/abseil-cpp/absl/debugging/internal/stacktrace_config.h
++++ b/src/3rdparty/chromium/third_party/abseil-cpp/absl/debugging/internal/stacktrace_config.h
+@@ -64,7 +64,7 @@
+ #elif defined(__i386__) || defined(__x86_64__)
+ #define ABSL_STACKTRACE_INL_HEADER \
+   "absl/debugging/internal/stacktrace_x86-inl.inc"
+-#elif defined(__ppc__) || defined(__PPC__)
++#elif (defined(__ppc__) || defined(__PPC__)) && defined(__GLIBC__)
+ #define ABSL_STACKTRACE_INL_HEADER \
+   "absl/debugging/internal/stacktrace_powerpc-inl.inc"
+ #elif defined(__aarch64__)
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+index 03afec7a5..0264ecf13 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/thread_info.cc
+@@ -273,6 +273,9 @@ void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
+ 
+ #elif defined(__powerpc64__)
+ 
++#include <asm/elf.h>
++#include <asm/ptrace.h>
++
+ uintptr_t ThreadInfo::GetInstructionPointer() const {
+     return mcontext.gp_regs[PT_NIP];
+ }
+@@ -290,9 +293,9 @@ void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
+     out->ctr = mcontext.gp_regs[PT_CTR];
+     
+     for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
+-        out->float_save.fpregs[i] = mcontext.fp_regs[i];
++        out->float_save.fpregs[i] = ((uint64_t *)&mcontext.fp_regs)[i];
+ 
+-    out->float_save.fpscr = mcontext.fp_regs[NFPREG-1];
++    out->float_save.fpscr = ((uint64_t *)&mcontext.fp_regs)[ELF_NFPREG-1];
+ 
+     for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
+         out->vector_save.save_vr[i] = \
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+index 7620cf6f7..54e373611 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc
+@@ -257,6 +257,9 @@ void UContextReader::FillCPUContext(RawContextCPU *out, const ucontext_t *uc) {
+ 
+ #elif defined(__powerpc64__)
+ 
++#include <asm/elf.h>
++#include <asm/ptrace.h>
++
+ uintptr_t UContextReader::GetStackPointer(const ucontext_t* uc) {
+     return uc->uc_mcontext.gp_regs[MD_CONTEXT_PPC64_REG_SP];
+ }
+@@ -280,9 +283,9 @@ void UContextReader::FillCPUContext(RawContextCPU* out, const ucontext_t* uc,
+     out->ctr = uc->uc_mcontext.gp_regs[PT_CTR];
+     
+     for (int i = 0; i < MD_FLOATINGSAVEAREA_PPC_FPR_COUNT; i++)
+-        out->float_save.fpregs[i] = uc->uc_mcontext.fp_regs[i];
++        out->float_save.fpregs[i] = ((uint64_t *)&uc->uc_mcontext.fp_regs)[i];
+ 
+-    out->float_save.fpscr = uc->uc_mcontext.fp_regs[NFPREG-1];
++    out->float_save.fpscr = ((uint64_t *)&uc->uc_mcontext.fp_regs)[ELF_NFPREG-1];
+ 
+     for (int i = 0; i < MD_VECTORSAVEAREA_PPC_VR_COUNT; i++)
+         out->vector_save.save_vr[i] =
+diff --git a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+index 901cd68fb..561958c44 100644
+--- a/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
++++ b/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/handler/exception_handler.cc
+@@ -105,6 +105,11 @@
+ #define PR_SET_PTRACER 0x59616d61
+ #endif
+ 
++/* musl hack, can't include asm/ptrace.h as that causes conflicts */
++#if defined(__powerpc64__) && !defined(PT_NIP)
++#define PT_NIP 32
++#endif
++
+ namespace google_breakpad {
+ 
+ namespace {
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+index 8e335a09..b2a0f155 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/snapshot/linux/signal_context.h
+@@ -469,7 +469,11 @@ struct MContext64 {
+   SignalThreadContext64 gp_regs;
+   SignalFloatContext64  fp_regs;
+   SignalVectorContext64 *v_regs;
++#ifdef __GLIBC__
+  int64_t vmx_reserve[69];
++#else
++  int64_t vmx_reserve[101];
++#endif
+ };
+ 
+ struct ContextTraits64 : public Traits64 {
+diff --git a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+index dea0d1f39..b203e5b2f 100644
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -30,6 +30,7 @@
+ 
+ #if defined(ARCH_CPU_PPC64_FAMILY)
+ #include <sys/ucontext.h>
++#include <asm/ptrace.h>
+ #endif
+ 
+ namespace crashpad {
+diff --git a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+index 9955ce44..4c1cc488 100644
+--- a/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
++++ b/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h
+@@ -4216,9 +4216,17 @@ struct kernel_statfs {
+     }
+   #endif
+   #if defined(__NR_fstatat64)
++    // musl does #define fstatat64 fstatat
++    #ifndef __GLIBC__
++    #undef fstatat64
++    #endif
+     LSS_INLINE _syscall4(int,   fstatat64,        int,   d,
+                          const char *,      p,
+                          struct kernel_stat64 *,   b,    int,   f)
++    // set it back like it was
++    #ifndef __GLIBC__
++    #define fstatat64 fstatat
++    #endif
+   #endif
+   #if defined(__NR_waitpid)
+     // waitpid is polyfilled below when not available.
diff --git a/srcpkgs/qt6-webengine/patches/0110-size_t.patch b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
new file mode 100644
index 000000000000..462e3202279f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
@@ -0,0 +1,16 @@
+--- a/src/3rdparty/chromium/third_party/angle/include/platform/PlatformMethods.h	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:44:25.477989726 +0100
+@@ -239,11 +239,11 @@
+ using ProgramKeyType   = std::array<uint8_t, 20>;
+ using CacheProgramFunc = void (*)(PlatformMethods *platform,
+                                   const ProgramKeyType &key,
+-                                  size_t programSize,
++                                  std::size_t programSize,
+                                   const uint8_t *programBytes);
+ inline void DefaultCacheProgram(PlatformMethods *platform,
+                                 const ProgramKeyType &key,
+-                                size_t programSize,
++                                std::size_t programSize,
+                                 const uint8_t *programBytes)
+ {}
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
new file mode 100644
index 000000000000..368099b981cc
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/skia/BUILD.gn	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/skia/BUILD.gn	2020-10-06 20:51:48.834970455 +0200
+@@ -772,7 +772,6 @@
+         # Root build config sets -mfpu=$arm_fpu, which we expect to be neon
+         # when running this.
+         if (!arm_use_neon) {
+-          configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
+           cflags += [ "-mfpu=neon" ]
+         }
+       }
diff --git a/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
new file mode 100644
index 000000000000..6e2d62f35ee6
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
@@ -0,0 +1,20 @@
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -17,6 +17,17 @@
+ 
+ #include <stdint.h>
+ #include <sys/user.h>
++#if !defined(__GLIBC__)
++struct user_vfp {
++	unsigned long long fpregs[32];
++	unsigned long fpscr;
++};
++struct user_vfp_exc {
++	unsigned long fpexc;
++	unsigned long fpinst;
++	unsigned long fpinst2;
++};
++#endif /* !defined(__GLIBC__) */
+ 
+ #include <type_traits>
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
new file mode 100644
index 000000000000..5c7cbfc46f65
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
@@ -0,0 +1,18 @@
+--- a/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-10-06 21:28:45.124882085 +0200
+@@ -109,6 +109,15 @@
+ #define HWCAP_IDIV  (HWCAP_IDIVA | HWCAP_IDIVT)
+ #define HWCAP_LPAE  (1 << 20)
+ 
++#ifndef __GLIBC__
++#include <elf.h>
++#ifdef __LP64__
++typedef Elf64_auxv_t elf_auxv_t;
++#else
++typedef Elf32_auxv_t elf_auxv_t;
++#endif
++#endif
++
+ static uint32_t ReadELFHWCaps() {
+ #if V8_GLIBC_PREREQ(2, 16)
+   return static_cast<uint32_t>(getauxval(AT_HWCAP));
diff --git a/srcpkgs/qt6-webengine/patches/0114-time64.patch b/srcpkgs/qt6-webengine/patches/0114-time64.patch
new file mode 100644
index 000000000000..6a98dd4e480e
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0114-time64.patch
@@ -0,0 +1,89 @@
+Description: fix seccomp-bpf failures in syscalls 0403, 0407
+ glibc ≥ 2.31 uses these syscalls on 32-bit platforms:
+ .
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=2e44b10b42d68d98
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=ec138c67cbda8b58
+Author: Andreas Müller <schnitzeltony@gmail.com>
+Forwarded: no
+Last-Update: 2020-09-02
+
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -148,7 +148,14 @@ ResultExpr EvaluateSyscallImpl(int fs_de
+     return Allow();
+ #endif
+ 
+-  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep) {
++  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep
++#if defined(__NR_clock_gettime64)
++                                  || sysno == __NR_clock_gettime64
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++                                  || sysno == __NR_clock_nanosleep_time64
++#endif
++  ) {
+     return RestrictClockID();
+   }
+ 
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
+@@ -60,6 +60,12 @@ class RestrictClockIdPolicy : public bpf
+       case __NR_clock_gettime:
+       case __NR_clock_getres:
+       case __NR_clock_nanosleep:
++#if defined(__NR_clock_nanosleep_time64)
++      case __NR_clock_nanosleep_time64:
++#endif
++#if defined(__NR_clock_gettime64)
++      case __NR_clock_gettime64:
++#endif
+         return RestrictClockID();
+       default:
+         return Allow();
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -39,6 +39,12 @@ bool SyscallSets::IsAllowedGettime(int s
+                                 // filtered by RestrictClokID().
+     case __NR_clock_gettime:    // Parameters filtered by RestrictClockID().
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
++#if defined(__NR_clock_gettime64)
++    case __NR_clock_gettime64:  // Parameters filtered by RestrictClockID().
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++    case __NR_clock_nanosleep_time64:  // Parameters filtered by RestrictClockID().
++#endif
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,14 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_SYSCALL_BASE+403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_SYSCALL_BASE+407)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
+@@ -1433,4 +1433,12 @@
+ #define __NR_memfd_create (__NR_Linux + 354)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_Linux + 403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_Linux + 407)
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_MIPS_LINUX_SYSCALLS_H_
diff --git a/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
new file mode 100644
index 000000000000..3a0ba3b2d854
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0121-glibc-2.33.patch
@@ -0,0 +1,144 @@
+# Patch made by Kevin Kofler <Kevin@tigcc.ticalc.org>
+# https://bugzilla.redhat.com/show_bug.cgi?id=1904652
+
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc	2021-01-20 02:14:53.066223906 +0100
+@@ -257,6 +257,18 @@
+     return RestrictKillTarget(current_pid, sysno);
+   }
+ 
++#if defined(__NR_newfstatat)
++  if (sysno == __NR_newfstatat) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
++#if defined(__NR_fstatat64)
++  if (sysno == __NR_fstatat64) {
++    return RewriteFstatatSIGSYS();
++  }
++#endif
++
+   if (SyscallSets::IsFileSystem(sysno) ||
+       SyscallSets::IsCurrentDirectory(sysno)) {
+     return Error(fs_denied_errno);
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc	2021-01-22 19:02:55.651668257 +0100
+@@ -6,6 +6,8 @@
+ 
+ #include "sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h"
+ 
++#include <errno.h>
++#include <fcntl.h>
+ #include <stddef.h>
+ #include <stdint.h>
+ #include <string.h>
+@@ -355,6 +357,35 @@
+   return -ENOSYS;
+ }
+ 
++intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args,
++                            void* aux) {
++  switch (args.nr) {
++#if defined(__NR_newfstatat)
++    case __NR_newfstatat:
++#endif
++#if defined(__NR_fstatat64)
++    case __NR_fstatat64:
++#endif
++#if defined(__NR_newfstatat) || defined(__NR_fstatat64)
++      if (*reinterpret_cast<const char *>(args.args[1]) == '\0'
++          && args.args[3] == static_cast<uint64_t>(AT_EMPTY_PATH)) {
++        return sandbox::sys_fstat64(static_cast<int>(args.args[0]),
++                                    reinterpret_cast<struct stat64 *>(args.args[2]));
++      } else {
++        errno = EACCES;
++        return -1;
++      }
++      break;
++#endif
++  }
++
++  CrashSIGSYS_Handler(args, aux);
++
++  // Should never be reached.
++  RAW_CHECK(false);
++  return -ENOSYS;
++}
++
+ bpf_dsl::ResultExpr CrashSIGSYS() {
+   return bpf_dsl::Trap(CrashSIGSYS_Handler, NULL);
+ }
+@@ -387,6 +418,10 @@
+   return bpf_dsl::Trap(SIGSYSSchedHandler, NULL);
+ }
+ 
++bpf_dsl::ResultExpr RewriteFstatatSIGSYS() {
++  return bpf_dsl::Trap(SIGSYSFstatatHandler, NULL);
++}
++
+ void AllocateCrashKeys() {
+ #if !defined(OS_NACL_NONSFI)
+   if (seccomp_crash_key)
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.h	2021-01-20 02:11:04.583714199 +0100
+@@ -62,6 +62,10 @@
+ // sched_setparam(), sched_setscheduler()
+ SANDBOX_EXPORT intptr_t SIGSYSSchedHandler(const arch_seccomp_data& args,
+                                            void* aux);
++// If the fstatat syscall is actually a disguised fstat, calls the regular fstat
++// syscall, otherwise, crashes in the same way as CrashSIGSYS_Handler.
++SANDBOX_EXPORT intptr_t SIGSYSFstatatHandler(const struct arch_seccomp_data& args, 
++                                             void* aux);
+ 
+ // Variants of the above functions for use with bpf_dsl.
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYS();
+@@ -72,6 +76,7 @@
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSFutex();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr CrashSIGSYSPtrace();
+ SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteSchedSIGSYS();
++SANDBOX_EXPORT bpf_dsl::ResultExpr RewriteFstatatSIGSYS();
+ 
+ // Allocates a crash key so that Seccomp information can be recorded.
+ void AllocateCrashKeys();
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc	2021-01-20 02:41:12.033133269 +0100
+@@ -261,4 +261,13 @@
+ 
+ #endif  // defined(MEMORY_SANITIZER)
+ 
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf)
++{
++#if defined(__NR_fstat64)
++    return syscall(__NR_fstat64, fd, buf);
++#else
++    return syscall(__NR_fstat, fd, buf);
++#endif
++}
++
+ }  // namespace sandbox
+diff -ur qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h
+--- qtwebengine-everywhere-src-5.15.2/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2020-11-07 02:22:36.000000000 +0100
++++ qtwebengine-everywhere-src-5.15.2-#1904652/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.h	2021-01-20 02:40:26.499827829 +0100
+@@ -17,6 +17,7 @@
+ struct rlimit64;
+ struct cap_hdr;
+ struct cap_data;
++struct stat64;
+ 
+ namespace sandbox {
+ 
+@@ -84,6 +85,9 @@
+                                  const struct sigaction* act,
+                                  struct sigaction* oldact);
+ 
++// Recent glibc rewrites fstat to fstatat.
++SANDBOX_EXPORT int sys_fstat64(int fd, struct stat64 *buf);
++
+ }  // namespace sandbox
+ 
+ #endif  // SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_
diff --git a/srcpkgs/qt6-webengine/template b/srcpkgs/qt6-webengine/template
new file mode 100644
index 000000000000..3743fc6664cb
--- /dev/null
+++ b/srcpkgs/qt6-webengine/template
@@ -0,0 +1,94 @@
+# Template file for 'qt6-webengine'
+pkgname=qt6-webengine
+version=6.2.0alpha
+revision=1
+wrksrc="qtwebengine-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true
+ -DQT_FEATURE_webengine_system_ffmpeg=ON
+ -DQT_FEATURE_webengine_system_libevent=ON
+ -DQT_FEATURE_webengine_system_gn=ON
+ -DPKG_CONFIG_HOST_EXECUTABLE=${PKG_CONFIG_FOR_BUILD}"
+hostmakedepends="qt6-base-devel perl pkg-config nodejs python
+ protobuf gperf flex nss-devel libwebp-devel"
+makedepends="qt6-base-devel qt6-declarative-devel pulseaudio-devel
+ alsa-lib-devel libvpx-devel pciutils-devel opus-devel libxslt-devel
+ libxml2-devel freetype-devel lcms2-devel libwebp-devel icu-devel
+ re2-devel zlib-devel libpng-devel minizip-devel harfbuzz-devel
+ nss-devel libXcursor-devel libXcomposite-devel libXScrnSaver-devel
+ protobuf-devel ffmpeg-devel snappy-devel libevent-devel pipewire-devel
+ qt6-quickcontrols2-devel qt6-location-devel qt6-webchannel-devel"
+short_desc="Cross-platform application and UI framework - Webengine"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-3.0-only, GPL-2.0-only, LGPL-3.0-only BSD-3-Clause"
+homepage="https://www.qt.io"
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtwebengine-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=e509436aa22b952e6195c146cf06a839b85aaa0724feb85f0b78516dc42105a4
+
+if [ -z "$CROSS_BUILD" ];then
+	configure_args+=" -DCMAKE_TOOLCHAIN_FILE=/usr/lib/cmake/Qt6/qt.toolchain.cmake"
+fi
+
+if [ "$XBPS_LIBC" = "musl" ]; then
+	hostmakedepends+=" musl-legacy-compat"
+fi
+
+if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
+	makedepends+=" musl-legacy-compat"
+fi
+
+if [ ! "$XBPS_WORDSIZE" = "$XBPS_TARGET_WORDSIZE" ]; then
+	broken="webengine can be built only if word size matches"
+fi
+
+if [ "$XBPS_WORDSIZE" -eq 32 ]; then
+	nodebug=yes
+	LDFLAGS="-Wl,--no-keep-memory"
+fi
+
+if [ "$XBPS_TARGET_ENDIAN" != "le" ]; then
+	broken="webengine only supports little endian"
+fi
+
+_bootstrap_gn() {
+	# Bootstrap gn (generate ninja)
+	echo "Bootstrapping 'gn'"
+	cd ${wrksrc}/src/3rdparty/gn
+	CFLAGS="$CFLAGS_host" CXXFLAGS="$CXXFLAGS_host" LDFLAGS="$LDFLAGS_host" \
+	PKGCONFIG=/usr/bin/pkgconfig PKG_CONFIG_PATH="/usr/lib/pkgconfig:/usr/share/pkgconfig" \
+		python2 build/gen.py --no-last-commit-position --out-path \
+			${wrksrc}/src/3rdparty/gn/out/Release --cc "${CC_host:-$CC}" \
+			--cxx "${CXX_host:-$CXX}" --ld "${CXX_host:-$CXX}" --ar "${AR_host:-$AR}" \
+			--qt-version "${version}.qtwebengine.qt.io"
+	ninja -C out/Release gn
+	cd ${wrksrc}
+}
+
+pre_configure() {
+	cp ${FILESDIR}/resolv_compat.h ${wrksrc}/src/3rdparty/chromium/net/dns
+	_bootstrap_gn
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+pre_build() {
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+post_install() {
+	# XXX: the install target is currently horribly broken
+	rm -r ${DESTDIR}/builddir
+	mv ${DESTDIR}/usr/resources ${DESTDIR}/usr/share/qt6
+	mv ${DESTDIR}/usr/translations ${DESTDIR}/usr/share/qt6
+}
+
+qt6-webengine-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-webchannel-devel>=${version}_1
+	 qt6-declarative-devel>=${version}_1 qt6-location-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+	}
+}

From a3c475da6d180598cb2f2238bca5afc5b82ef892 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 16:00:28 +0200
Subject: [PATCH 24/24] New package: qt6-location-6.2.0alpha

---
 common/shlibs                 |  1 +
 srcpkgs/qt6-location-devel    |  1 +
 srcpkgs/qt6-location/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-location-devel
 create mode 100644 srcpkgs/qt6-location/template

diff --git a/common/shlibs b/common/shlibs
index e6d1ef7157b4..e3b64dfad96b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2063,6 +2063,7 @@ libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
+libQt6Positioning.so.6 qt6-location-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-location-devel b/srcpkgs/qt6-location-devel
new file mode 120000
index 000000000000..7924c82dd3f4
--- /dev/null
+++ b/srcpkgs/qt6-location-devel
@@ -0,0 +1 @@
+qt6-location
\ No newline at end of file
diff --git a/srcpkgs/qt6-location/template b/srcpkgs/qt6-location/template
new file mode 100644
index 000000000000..3bad3ab8aade
--- /dev/null
+++ b/srcpkgs/qt6-location/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-location'
+pkgname=qt6-location
+version=6.2.0alpha
+revision=1
+wrksrc="qtlocation-everywhere-src-${version/alpha/-alpha}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-serialport-devel qt6-declarative-devel GConf-devel"
+short_desc="Cross-platform application and UI framework - location"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/alpha/-alpha}/submodules/qtlocation-everywhere-src-${version/alpha/-alpha}.tar.xz"
+checksum=514a84d73ccb7af5f7921b99a5742314c8875bd4cb1a982a09b28a8080c117c8
+
+qt6-location-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (2 preceding siblings ...)
  2021-06-27 19:38 ` Johnnynator
@ 2021-06-27 20:17 ` ericonr
  2021-06-27 20:29 ` Johnnynator
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ericonr @ 2021-06-27 20:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 420 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/31686#discussion_r659370545

Comment:
Unless they actually touch `_res` internals (which would be kinda broken in most cases anyway), you can just do `#define res_ninit(r) res_init`; musl's resolver is completely stateless (maybe you can even do it as a CFLAGS define? nto sure). Should save you some trouble ;)

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (3 preceding siblings ...)
  2021-06-27 20:17 ` [PR REVIEW] " ericonr
@ 2021-06-27 20:29 ` Johnnynator
  2021-09-12 14:47 ` [PR PATCH] [Updated] " Johnnynator
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-06-27 20:29 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 375 bytes --]

New review comment by Johnnynator on void-packages repository

https://github.com/void-linux/void-packages/pull/31686#discussion_r659372338

Comment:
This file is there since 6 years in qt5-webengine and never changed in that time. So I would call changing it more trouble :p.
But I could probably get the qtwebengine musl patchset to be more in line with the chromium one.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (4 preceding siblings ...)
  2021-06-27 20:29 ` Johnnynator
@ 2021-09-12 14:47 ` Johnnynator
  2021-10-03 13:14 ` Johnnynator
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-09-12 14:47 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

There is an updated pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 96606 bytes --]

From e0ec95f8fb265a426cc3d6a054f6ffb152581e71 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 01/23] qt6-3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..a76d23b74b33 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qt3d-everywhere-src-${version}"
+wrksrc="qt3d-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - 3d"
 maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qt3d-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=5e385eccf30bd001cf117491ea0bc59497417ef4c589408044b7e9a2d559220b
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 902e35f1bd8704f90c314af2e175e3ded8dec0c2 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 02/23] qt6-base: update to 6.2.0alpha.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 ++++++++++++++
 srcpkgs/qt6-base/template                     | 34 +++++++++++++++----
 srcpkgs/qt6-plugin-networkinformation         |  1 +
 srcpkgs/qt6-plugin-tls-openssl                |  1 +
 srcpkgs/qt6-plugin-tls-qcertonly              |  1 +
 5 files changed, 56 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
 create mode 120000 srcpkgs/qt6-plugin-networkinformation
 create mode 120000 srcpkgs/qt6-plugin-tls-openssl
 create mode 120000 srcpkgs/qt6-plugin-tls-qcertonly

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index 0b3dd492fb1f..3aa87007db3d 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
-revision=2
-wrksrc="qtbase-everywhere-src-${version}"
+version=6.2.0beta4
+revision=1
+wrksrc="qtbase-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
  -DINSTALL_ARCHDATADIR=lib/qt6
@@ -22,13 +22,14 @@ makedepends="zlib-devel libzstd-devel dbus-devel
  libpng-devel tslib-devel libinput-devel gtk+3-devel
  libmariadbclient-devel postgresql-libs-devel libatomic-devel
  unixodbc-devel cups-devel libproxy-devel brotli-devel
- sqlite-devel Vulkan-Headers mit-krb5-devel vulkan-loader libb2-devel"
+ sqlite-devel Vulkan-Headers mit-krb5-devel vulkan-loader libb2-devel
+ libXevie-devel libXcursor-devel"
 short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtbase-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=2a80b83c05dd394384ba33bdc79616b275f97211062d58d2345fa891ef6a2875
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -207,6 +208,27 @@ qt6-plugin-sqlite_package() {
 	}
 }
 
+qt6-plugin-tls-openssl_package() {
+	short_desc+=" - TLS plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/tls/libqopensslbackend.so
+	}
+}
+
+qt6-plugin-tls-qcertonly_package() {
+	short_desc+=" - TLS plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/tls/libqcertonlybackend.so
+	}
+}
+
+qt6-plugin-networkinformation() {
+	short_desc+=" - Networkinformation plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/networkinformation/libqnetworkmanager.so
+	}
+}
+
 qt6-base-devel_package() {
 	short_desc+=" - Development files"
 	depends="qt6-base>=${version}_${revision}
diff --git a/srcpkgs/qt6-plugin-networkinformation b/srcpkgs/qt6-plugin-networkinformation
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-networkinformation
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file
diff --git a/srcpkgs/qt6-plugin-tls-openssl b/srcpkgs/qt6-plugin-tls-openssl
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-tls-openssl
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file
diff --git a/srcpkgs/qt6-plugin-tls-qcertonly b/srcpkgs/qt6-plugin-tls-qcertonly
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-tls-qcertonly
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file

From 4fff69af2865bb19b47b8619296c14edd19b0c75 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 03/23] qt6-charts: update to 6.2.0alpha.

---
 srcpkgs/qt6-charts/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..aab1c54febcb 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtcharts-everywhere-src-${version}"
+wrksrc="qtcharts-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - charts"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtcharts-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=eef4b39cf785b3e41c807a8fedf9ecbfd98bdafcfaa3931e45f3fc8671c469f8
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 409a0f3382adc0b21dff19034eb498304e045747 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 04/23] qt6-declarative: update to 6.2.0alpha.

---
 common/shlibs                       |  8 ++++----
 srcpkgs/qt6-declarative/template    | 28 ++++++++++++++++++----------
 srcpkgs/qt6-quickcontrols2-devel    |  1 -
 srcpkgs/qt6-quickcontrols2/template | 27 ---------------------------
 srcpkgs/qt6-quickcontrols2/update   |  1 -
 5 files changed, 22 insertions(+), 43 deletions(-)
 delete mode 120000 srcpkgs/qt6-quickcontrols2-devel
 delete mode 100644 srcpkgs/qt6-quickcontrols2/template
 delete mode 100644 srcpkgs/qt6-quickcontrols2/update

diff --git a/common/shlibs b/common/shlibs
index 840fbc0b9a9f..82d78d8b3629 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2010,7 +2010,7 @@ libQt6LabsSharedImage.so.6 qt6-declarative-6.1.0_1
 libQt6LabsWavefrontMesh.so.6 qt6-declarative-6.1.0_1
 libQt6QmlLocalStorage.so.6 qt6-declarative-6.1.0_1
 libQt6QmlWorkerScript.so.6 qt6-declarative-6.0.0_1
-libQt6QuickTest.so.6 qt6-declarative-6.0.0_1
+libQt6QuickTest.so.6 qt6-declarative-devel-6.2.0beta4_1
 libQt6QuickShapes.so.6 qt6-declarative-6.0.0_1
 libQt6QuickWidgets.so.6 qt6-declarative-6.0.0_1
 libQt6Quick.so.6 qt6-declarative-6.0.0_1
@@ -2024,9 +2024,9 @@ libQt6Quick3DUtils.so.6 qt6-quick3d-6.0.0_1
 libQt6Quick3DAssetImport.so.6 qt6-quick3d-6.0.0_1
 libQt6Quick3DIblBaker.so.6 qt6-quick3d-6.0.3_1
 libQt6Quick3DParticles.so.6 qt6-quick3d-6.1.0_1
-libQt6QuickControls2Impl.so.6 qt6-quickcontrols2-6.0.0_1
-libQt6QuickControls2.so.6 qt6-quickcontrols2-6.0.0_1
-libQt6QuickTemplates2.so.6 qt6-quickcontrols2-6.0.0_1
+libQt6QuickControls2Impl.so.6 qt6-declarative-6.0.0_1
+libQt6QuickControls2.so.6 qt6-declarative-6.0.0_1
+libQt6QuickTemplates2.so.6 qt6-declarative-6.0.0_1
 libQt6NetworkAuth.so.6 qt6-networkauth-6.1.0rc2_1
 libQt6ScxmlQml.so.6 qt6-scxml-6.1.0rc2_1
 libQt6Scxml.so.6 qt6-scxml-6.1.0rc2_1
diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..edac493fab40 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,24 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtdeclarative-everywhere-src-${version}"
+wrksrc="qtdeclarative-everywhere-src-${version/beta/-beta}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtdeclarative-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=8c483d14109e337b10cec145d7f056f803ed44cac1e1f0b24edc9d8f1c159872
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+	hostmakedepends+=" qt6-declarative-devel"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +38,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}
@@ -50,6 +55,9 @@ qt6-declarative-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/libQt6QuickTest.so.*"
+		vmove usr/lib/qt6/qml/QtTest
+		vmove usr/lib/qt6/bin/qmltestrunner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}
diff --git a/srcpkgs/qt6-quickcontrols2-devel b/srcpkgs/qt6-quickcontrols2-devel
deleted file mode 120000
index 280bc162057d..000000000000
--- a/srcpkgs/qt6-quickcontrols2-devel
+++ /dev/null
@@ -1 +0,0 @@
-qt6-quickcontrols2
\ No newline at end of file
diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
deleted file mode 100644
index ab57102a19cf..000000000000
--- a/srcpkgs/qt6-quickcontrols2/template
+++ /dev/null
@@ -1,27 +0,0 @@
-# Template file for 'qt6-quickcontrols2'
-pkgname=qt6-quickcontrols2
-version=6.1.1
-revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
-build_style=cmake
-configure_args="-DQT_HOST_PATH=/usr "
-hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
-makedepends="qt6-base-devel qt6-declarative-devel"
-short_desc="Cross-platform application and UI framework - quickcontrols2"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later, LGPL-3.0-or-later"
-homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
-
-qt6-quickcontrols2-devel_package() {
-	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"
-	short_desc+=" - development files"
-	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/cmake
-		vmove usr/lib/qt6/mkspecs
-		vmove "usr/lib/*.so"
-		vmove "usr/lib/*.prl"
-	}
-}
diff --git a/srcpkgs/qt6-quickcontrols2/update b/srcpkgs/qt6-quickcontrols2/update
deleted file mode 100644
index 844552465222..000000000000
--- a/srcpkgs/qt6-quickcontrols2/update
+++ /dev/null
@@ -1 +0,0 @@
-pkgname="${pkgname/6-/}-everywhere-src"

From 7e5bb59331244cecc5ce2e63d69572a8e9371c45 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 05/23] qt6-imageformats: update to 6.2.0alpha.

---
 srcpkgs/qt6-imageformats/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..0b7db4fc6f85 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtimageformats-everywhere-src-${version}"
+wrksrc="qtimageformats-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - imageformats"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtimageformats-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=73324dd7344dd3a19699ea651cefd4608a9adb722fc1a777b888a3a43c19a577

From b65c2c1b18a254f94dd8cbb8f72c24b577134cb7 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 06/23] qt6-lottie: update to 6.2.0alpha.

---
 srcpkgs/qt6-lottie/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..9139a493849b 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtlottie-everywhere-src-${version}"
+wrksrc="qtlottie-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - lottie"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtlottie-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=e3adf788bedff70e6dc99eed1a0d0dfb9e2302af1402c50197bb960336b3ead4
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 23fc259e9955fb83d842dbed5325db558c2986ba Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 07/23] qt6-networkauth: update to 6.2.0alpha.

---
 srcpkgs/qt6-networkauth/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..feb78f780576 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtnetworkauth-everywhere-src-${version}"
+wrksrc="qtnetworkauth-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - networkauth"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtnetworkauth-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=32e8e8565278265b5738b5097f05c515bac928fe8ed926abcb75ba8edb1aa227
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 0fe543c734a63d6be58864b3e0c99225576a5a0d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 08/23] qt6-qt5compat: update to 6.2.0alpha.

---
 srcpkgs/qt6-qt5compat/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index 06837849b3f1..cee06a1ae4af 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
-revision=2
-wrksrc="qt5compat-everywhere-src-${version}"
+version=6.2.0beta4
+revision=1
+wrksrc="qt5compat-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Compo
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qt5compat-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=af9196015d2bb8cce587a3475fb0f3bbaa8c74d8ddb4b8468de688df0f72f485
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 1b7f2432134d6dcbd9e353e58305a1937ef974a8 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 09/23] qt6-quick3d: update to 6.2.0alpha.

---
 srcpkgs/qt6-quick3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..8f81ed6b82bf 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtquick3d-everywhere-src-${version}"
+wrksrc="qtquick3d-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel qt6-shadertools-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - Quick3d"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtquick3d-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=2bde4a44d52d82da425285ad4af6c33cc12a771294af52136c977235abf834bc
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From 7a58b201ff322fcc10dc9069be851d4e3438e626 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 10/23] qt6-quicktimeline: update to 6.2.0alpha.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..d28240bfacfa 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtquicktimeline-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=f72df262920460076ac90a883345d5baaa1247d7f8a18714abbe9b95321577b7
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From e842f2d10ec9626963f881fbc95fb43d6cf064ec Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 11/23] qt6-scxml: update to 6.2.0alpha.

---
 srcpkgs/qt6-scxml/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..b72227aefb0f 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtscxml-everywhere-src-${version}"
+wrksrc="qtscxml-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - scxml"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtscxml-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=6d74721e9aa44eb590d5dac5b710668b03d33b7a69ba87da252d43a651167817
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 2b25c861f02d1f29ac76676af794b49ba6275b05 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 12/23] qt6-shadertools: update to 6.2.0alpha.

---
 srcpkgs/qt6-shadertools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..3f3c6bc5c5a7 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtshadertools-everywhere-src-${version}"
+wrksrc="qtshadertools-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - shadertools"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtshadertools-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=12872cabf24b4b8051a7ee3b75d753a97935c6ba81426b26fc335d9da147c8b1
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From 451fc76865f773e1cb46ab579630346402b84d6d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 13/23] qt6-svg: update to 6.2.0alpha.

---
 srcpkgs/qt6-svg/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..15aaf1253ae3 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtsvg-everywhere-src-${version}"
+wrksrc="qtsvg-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-svg componen
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtsvg-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=2e6a0bf518ee0566375be267ed2c1a9eb69fefb54d20b0d97e1bfee458745d4e
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From ea5e6fb9ef21aa46e21c072b77c0d4912a156342 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 14/23] qt6-tools: update to 6.2.0alpha.

---
 srcpkgs/qt6-tools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..c32e0aa46144 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qttools-everywhere-src-${version}"
+wrksrc="qttools-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-tools compon
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qttools-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=324967044be6a1a3e3a5bbbdc6c5e2461baad38b98cafde6c4faec9b777b076b
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From bcc74e6f53a11b6c631f994ef1f5510cf72856a4 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 15/23] qt6-translations: update to 6.2.0alpha.

---
 srcpkgs/qt6-translations/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..1c3c7444e173 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qttranslations-everywhere-src-${version}"
+wrksrc="qttranslations-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel qt6-tools-devel perl"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - translations"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qttranslations-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=04856dc5bf4dce9f970218c8310038acbc1d0d177d4eb915d55f0eb0469bd9c6

From ec108f1fc48d2af2ffc00ae5b8804fac27da133d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 16/23] qt6-virtualkeyboard: update to 6.2.0alpha.

---
 srcpkgs/qt6-virtualkeyboard/template | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..9bf9cfad97c3 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,20 +1,18 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
+wrksrc="qtvirtualkeyboard-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
-makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
- qt6-svg-devel hunspell-devel"
-depends="qt6-quickcontrols2"
+makedepends="qt6-declarative-devel qt6-svg-devel hunspell-devel"
 short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtvirtualkeyboard-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=08a0a70141b0c8a0c2b88f7accffe5da181f0df656863eae56da33ec45b4c925
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From b13c0d15fd8e151fe655a5ef0c655b9c26a8a017 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 17/23] qt6-wayland: update to 6.2.0alpha.

---
 srcpkgs/qt6-wayland/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..e9bbf8d8c33e 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0beta4
 revision=1
-wrksrc="qtwayland-everywhere-src-${version}"
+wrksrc="qtwayland-everywhere-src-${version/beta/-beta}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel qt6-wayland-devel"
@@ -14,8 +14,8 @@ short_desc="Cross-platform application and UI framework - Wayland"
 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtwayland-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=4e76297acaea3bab1dd7ff03e1beec92adac7036f977fdd69dc1799f0c053df5
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From 6f3875d8ef91b54d2954146ec4e51c947394ba50 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:16:54 +0200
Subject: [PATCH 18/23] New package: qt6-serialport-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-serialport-devel    |  1 +
 srcpkgs/qt6-serialport/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-serialport-devel
 create mode 100644 srcpkgs/qt6-serialport/template

diff --git a/common/shlibs b/common/shlibs
index 82d78d8b3629..4a3c0f235f43 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2052,6 +2052,7 @@ libQt6Help.so.6 qt6-tools-6.1.0_1
 libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
+libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-serialport-devel b/srcpkgs/qt6-serialport-devel
new file mode 120000
index 000000000000..f6a498cf2653
--- /dev/null
+++ b/srcpkgs/qt6-serialport-devel
@@ -0,0 +1 @@
+qt6-serialport
\ No newline at end of file
diff --git a/srcpkgs/qt6-serialport/template b/srcpkgs/qt6-serialport/template
new file mode 100644
index 000000000000..49f4e003e306
--- /dev/null
+++ b/srcpkgs/qt6-serialport/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-serialport'
+pkgname=qt6-serialport
+version=6.2.0beta4
+revision=1
+wrksrc="qtserialport-everywhere-src-${version/beta/-beta}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel pkg-config"
+makedepends="qt6-base-devel"
+short_desc="Cross-platform application and UI framework - serialport"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtserialport-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=ba6ee91ea4ec2539bdd92698199052e3c42d56f05a973a8bd550248db37e9712
+
+qt6-serialport-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From a29435ef2e0da5a8119d9c2b88f027b47d3abb15 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:23:48 +0200
Subject: [PATCH 19/23] New package: qt6-websockets-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-websockets-devel    |  1 +
 srcpkgs/qt6-websockets/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-websockets-devel
 create mode 100644 srcpkgs/qt6-websockets/template

diff --git a/common/shlibs b/common/shlibs
index 4a3c0f235f43..96a56bfadde2 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2053,6 +2053,7 @@ libQt6UiTools.so.6 qt6-tools-6.1.0_1
 libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
+libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-websockets-devel b/srcpkgs/qt6-websockets-devel
new file mode 120000
index 000000000000..a3c674e42954
--- /dev/null
+++ b/srcpkgs/qt6-websockets-devel
@@ -0,0 +1 @@
+qt6-websockets
\ No newline at end of file
diff --git a/srcpkgs/qt6-websockets/template b/srcpkgs/qt6-websockets/template
new file mode 100644
index 000000000000..8762c98f130f
--- /dev/null
+++ b/srcpkgs/qt6-websockets/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-websockets'
+pkgname=qt6-websockets
+version=6.2.0beta4
+revision=1
+wrksrc="qtwebsockets-everywhere-src-${version/beta/-beta}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel"
+short_desc="Cross-platform application and UI framework - websockets"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtwebsockets-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=b4f407df46bbd66cf930aeffdf58ec7ac5704325fb1fe30bfa43b56c56b56e46
+
+qt6-websockets-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From 7a780f7bd0b7e12647c6c60ab8d1dec8a9893a4f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 12:25:04 +0200
Subject: [PATCH 20/23] New package: qt6-webchannel-6.2.0alpha

---
 common/shlibs                   |  1 +
 srcpkgs/qt6-webchannel-devel    |  1 +
 srcpkgs/qt6-webchannel/template | 28 ++++++++++++++++++++++++++++
 3 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-webchannel-devel
 create mode 100644 srcpkgs/qt6-webchannel/template

diff --git a/common/shlibs b/common/shlibs
index 96a56bfadde2..33c9fda80cc4 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2054,6 +2054,7 @@ libQt6HunspellInputMethod.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
+libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-webchannel-devel b/srcpkgs/qt6-webchannel-devel
new file mode 120000
index 000000000000..03e8b23d785d
--- /dev/null
+++ b/srcpkgs/qt6-webchannel-devel
@@ -0,0 +1 @@
+qt6-webchannel
\ No newline at end of file
diff --git a/srcpkgs/qt6-webchannel/template b/srcpkgs/qt6-webchannel/template
new file mode 100644
index 000000000000..0b6d86157a22
--- /dev/null
+++ b/srcpkgs/qt6-webchannel/template
@@ -0,0 +1,28 @@
+# Template file for 'qt6-webchannel'
+pkgname=qt6-webchannel
+version=6.2.0beta4
+revision=1
+wrksrc="qtwebchannel-everywhere-src-${version/beta/-beta}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-base-devel qt6-declarative-devel qt6-websockets-devel"
+short_desc="Cross-platform application and UI framework - webchannel"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtwebchannel-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=786276e1e54c9824366b983d0069c894c8d37a5b1e40463d480cacc3a90f0489
+
+qt6-webchannel-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1
+	 qt6-websockets-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From e6120600a264cd817584d3ad77ec8df1995e9cce Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 26 Jun 2021 21:08:25 +0200
Subject: [PATCH 21/23] New package: qt6-multimedia-6.2.0alpha

---
 srcpkgs/qt6-multimedia-devel    |  1 +
 srcpkgs/qt6-multimedia/template | 29 +++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+)
 create mode 120000 srcpkgs/qt6-multimedia-devel
 create mode 100644 srcpkgs/qt6-multimedia/template

diff --git a/srcpkgs/qt6-multimedia-devel b/srcpkgs/qt6-multimedia-devel
new file mode 120000
index 000000000000..9343446502d0
--- /dev/null
+++ b/srcpkgs/qt6-multimedia-devel
@@ -0,0 +1 @@
+qt6-multimedia
\ No newline at end of file
diff --git a/srcpkgs/qt6-multimedia/template b/srcpkgs/qt6-multimedia/template
new file mode 100644
index 000000000000..37634635d647
--- /dev/null
+++ b/srcpkgs/qt6-multimedia/template
@@ -0,0 +1,29 @@
+# Template file for 'qt6-multimedia'
+pkgname=qt6-multimedia
+version=6.2.0beta4
+revision=1
+wrksrc="qtmultimedia-everywhere-src-${version/beta/-beta}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_FEATURE_gstreamer=ON"
+hostmakedepends="perl qt6-declarative-devel pkg-config
+ qt6-shadertools-devel"
+makedepends="qt6-declarative-devel
+ qt6-shadertools-devel libglib-devel gst-plugins-base1-devel"
+short_desc="Cross-platform application and UI framework - multimedia"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtmultimedia-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=819ee34291b0612bf5e383caa38a0728e01b614d106808f93fd9204c25ebfbf2
+
+qt6-multimedia-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

From c0ec17baed24f46567588795f8d5cac4f341de94 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 00:35:33 +0200
Subject: [PATCH 22/23] New package: qt6-webengine-6.2.0alpha

---
 srcpkgs/qt6-webengine-devel                   |   1 +
 srcpkgs/qt6-webengine/files/resolv_compat.h   |  29 +++++
 .../patches/0001-mus-cstring.patch            |  10 ++
 .../patches/0002-None-no-debug.patch          |  11 ++
 ...reg.h-to-get-__WORDSIZE-on-musl-libc.patch |  26 +++++
 .../patches/0003-musl-dispatch-to-musl.patch  | 103 +++++++++++++++++
 .../patches/0004-musl-no-mallinfo.patch       |  39 +++++++
 .../patches/0006-musl-pread-pwrite.patch      |  18 +++
 .../patches/0008-musl-resolve.patch           |  26 +++++
 .../patches/0009-musl-siginfo_t.patch         |  18 +++
 .../patches/0010-musl-stackstart.patch        |  20 ++++
 .../patches/0011-musl-sandbox.patch           |  71 ++++++++++++
 ...0012-musl-chromium-default-stacksize.patch |  15 +++
 .../0014-musl-cross-no-asm_ptrace_h.patch     |  30 +++++
 .../patches/0015-no-glibc-cmake-check.patch   |  17 +++
 .../patches/0016-qt-musl-execinfo.patch       | 106 ++++++++++++++++++
 .../0017-qt-musl-thread-stacksize.patch       |  26 +++++
 .../patches/0018-sandbox-membarrier.patch     |  60 ++++++++++
 .../patches/0020-msgvec-push_back.patch       |  14 +++
 .../patches/0021-sandbox-sched_getparam.patch |  26 +++++
 .../0022-canonicalize-file-name-musl.patch    |  11 ++
 .../patches/0089-enable-ppc64.patch           |  49 ++++++++
 .../qt6-webengine/patches/0110-size_t.patch   |  16 +++
 .../patches/0111-armv7l-neon.patch            |  10 ++
 .../patches/0112-arm-user_vfp.patch           |  20 ++++
 .../patches/0113-arm-elf_auxv_t.patch         |  18 +++
 .../qt6-webengine/patches/0114-time64.patch   |  89 +++++++++++++++
 .../patches/pthread_getname_np-mus.patch      |  15 +++
 srcpkgs/qt6-webengine/template                |  87 ++++++++++++++
 29 files changed, 981 insertions(+)
 create mode 120000 srcpkgs/qt6-webengine-devel
 create mode 100644 srcpkgs/qt6-webengine/files/resolv_compat.h
 create mode 100644 srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0110-size_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/0114-time64.patch
 create mode 100644 srcpkgs/qt6-webengine/patches/pthread_getname_np-mus.patch
 create mode 100644 srcpkgs/qt6-webengine/template

diff --git a/srcpkgs/qt6-webengine-devel b/srcpkgs/qt6-webengine-devel
new file mode 120000
index 000000000000..8e4d1b99c587
--- /dev/null
+++ b/srcpkgs/qt6-webengine-devel
@@ -0,0 +1 @@
+qt6-webengine
\ No newline at end of file
diff --git a/srcpkgs/qt6-webengine/files/resolv_compat.h b/srcpkgs/qt6-webengine/files/resolv_compat.h
new file mode 100644
index 000000000000..4f0e852a19d0
--- /dev/null
+++ b/srcpkgs/qt6-webengine/files/resolv_compat.h
@@ -0,0 +1,29 @@
+#if !defined(__GLIBC__)
+/***************************************************************************
+ * resolv_compat.h
+ *
+ * Mimick GLIBC's res_ninit() and res_nclose() for musl libc
+ * Note: res_init() is actually deprecated according to
+ * http://docs.oracle.com/cd/E36784_01/html/E36875/res-nclose-3resolv.html
+ **************************************************************************/
+#include <string.h>
+
+static inline int res_ninit(res_state statp)
+{
+	int rc = res_init();
+	if (statp != &_res) {
+		memcpy(statp, &_res, sizeof(*statp));
+	}
+	return rc;
+}
+
+static inline int res_nclose(res_state statp)
+{
+	if (!statp)
+		return -1;
+	if (statp != &_res) {
+		memset(statp, 0, sizeof(*statp));
+	}
+	return 0;
+}
+#endif
diff --git a/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
new file mode 100644
index 000000000000..d4b22c77ce96
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0001-mus-cstring.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/mojo/public/cpp/platform/named_platform_channel_posix.cc	2021-03-08 10:30:42.504006604 +0100
++++ -	2021-03-08 10:31:27.415366585 +0100
+@@ -8,6 +8,7 @@
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <unistd.h>
++#include <cstring>
+ 
+ #include "base/files/file_util.h"
+ #include "base/files/scoped_file.h"
diff --git a/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
new file mode 100644
index 000000000000..b3ee486e3d25
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-None-no-debug.patch
@@ -0,0 +1,11 @@
+--- a/cmake/Functions.cmake
++++ b/cmake/Functions.cmake
+@@ -682,6 +682,8 @@ macro(append_build_type_setup)
+         endif()
+     elseif(${config} STREQUAL "MinSizeRel")
+         list(APPEND gnArgArg is_debug=false symbol_level=0 optimize_for_size=true)
++    elseif(${config} STREQUAL "None")
++        list(APPEND gnArgArg is_debug=false symbol_level=0)
+     endif()
+     if(FEATURE_developer_build OR (${config} STREQUAL "Debug"))
+         list(APPEND gnArgArg
diff --git a/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
new file mode 100644
index 000000000000..da4160b21bd3
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0002-include-sys-reg.h-to-get-__WORDSIZE-on-musl-libc.patch
@@ -0,0 +1,26 @@
+From 9001c54d6b974449174a8cee8f3f5d78a9bd6c9e Mon Sep 17 00:00:00 2001
+From: Felix Janda <felix.janda@posteo.de>
+Date: Sun, 1 Feb 2015 14:26:52 +0100
+Subject: [PATCH 3/6] include <sys/reg.h> to get __WORDSIZE on musl libc
+
+---
+ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/common/linux/elf_core_dump.h b/src/common/linux/elf_core_dump.h
+index d03c7a8..02eb391 100644
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/common/linux/elf_core_dump.h
+@@ -36,6 +36,9 @@
+ #include <elf.h>
+ #include <link.h>
+ #include <stddef.h>
++#ifndef __GLIBC__
++#include <sys/reg.h>
++#endif
+ 
+ #include "common/memory_range.h"
+ 
+-- 
+2.0.5
+
diff --git a/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
new file mode 100644
index 000000000000..de32a3dab95c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0003-musl-dispatch-to-musl.patch
@@ -0,0 +1,103 @@
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+--- qtwebengine/src/3rdparty/chromium/base/allocator/allocator_shim_default_dispatch_to_glibc.cc
+@@ -6,6 +6,7 @@
+ 
+ #include <malloc.h>
+ 
++#if defined(__GLIBC__)
+ // This translation unit defines a default dispatch for the allocator shim which
+ // routes allocations to libc functions.
+ // The code here is strongly inspired from tcmalloc's libc_override_glibc.h.
+@@ -73,3 +74,92 @@ const AllocatorDispatch AllocatorDispatch::default_dispatch = {
+     nullptr,               /* free_definite_size_function */
+     nullptr,               /* next */
+ };
++
++#else // defined(__GLIBC__)
++
++#include <dlfcn.h>
++
++extern "C" {
++// Declare function pointers to the memory functions
++typedef void* (*t_libc_malloc)(size_t size);
++typedef void* (*t_libc_calloc)(size_t n, size_t size);
++typedef void* (*t_libc_realloc)(void* address, size_t size);
++typedef void* (*t_libc_memalign)(size_t alignment, size_t size);
++typedef void (*t_libc_free)(void* ptr);
++typedef size_t (*t_libc_malloc_usable_size)(void* ptr);
++
++// Static instances of pointers to libc.so dl symbols
++static t_libc_malloc libc_malloc = NULL;
++static t_libc_calloc libc_calloc = NULL;
++static t_libc_realloc libc_realloc = NULL;
++static t_libc_memalign libc_memalign = NULL;
++static t_libc_free libc_free = NULL;
++static t_libc_malloc_usable_size libc_malloc_usable_size = NULL;
++
++// resolve the symbols in libc.so
++void musl_libc_memory_init(void)
++{
++  libc_malloc = (t_libc_malloc) dlsym(RTLD_NEXT, "malloc");
++  libc_calloc = (t_libc_calloc) dlsym(RTLD_NEXT, "calloc");
++  libc_realloc = (t_libc_realloc) dlsym(RTLD_NEXT, "realloc");
++  libc_memalign = (t_libc_memalign) dlsym(RTLD_NEXT, "memalign");
++  libc_free = (t_libc_free) dlsym(RTLD_NEXT, "free");
++  libc_malloc_usable_size = (t_libc_malloc_usable_size) dlsym(RTLD_NEXT, "malloc_usable_size");
++}
++}  // extern "C"
++
++namespace {
++
++using base::allocator::AllocatorDispatch;
++
++void* MuslMalloc(const AllocatorDispatch*, size_t size, void* context) {
++  if (!libc_malloc)
++    musl_libc_memory_init();
++  return (*libc_malloc)(size);
++}
++
++void* MuslCalloc(const AllocatorDispatch*, size_t n, size_t size, void* context) {
++  if (!libc_calloc)
++    musl_libc_memory_init();
++  return (*libc_calloc)(n, size);
++}
++
++void* MuslRealloc(const AllocatorDispatch*, void* address, size_t size, void* context) {
++  if (!libc_realloc)
++    musl_libc_memory_init();
++  return (*libc_realloc)(address, size);
++}
++
++void* MuslMemalign(const AllocatorDispatch*, size_t alignment, size_t size, void* context) {
++  if (!libc_memalign)
++    musl_libc_memory_init();
++  return (*libc_memalign)(alignment, size);
++}
++
++void MuslFree(const AllocatorDispatch*, void* address, void* context) {
++  if (!libc_free)
++    musl_libc_memory_init();
++  (*libc_free)(address);
++}
++
++size_t MuslGetSizeEstimate(const AllocatorDispatch*, void* address, void* context) {
++  // TODO(siggi, primiano): malloc_usable_size may need redirection in the
++  //     presence of interposing shims that divert allocations.
++  if (!libc_malloc_usable_size)
++    musl_libc_memory_init();
++  return (*libc_malloc_usable_size)(address);
++}
++
++}  // namespace
++
++const AllocatorDispatch AllocatorDispatch::default_dispatch = {
++    &MuslMalloc,           /* alloc_function */
++    &MuslCalloc,           /* alloc_zero_initialized_function */
++    &MuslMemalign,         /* alloc_aligned_function */
++    &MuslRealloc,          /* realloc_function */
++    &MuslFree,             /* free_function */
++    &MuslGetSizeEstimate,  /* get_size_estimate_function */
++    nullptr,               /* next */
++};
++
++#endif
diff --git a/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
new file mode 100644
index 000000000000..36900f907833
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0004-musl-no-mallinfo.patch
@@ -0,0 +1,39 @@
+--- qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2017-11-28 14:06:53.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/base/trace_event/malloc_dump_provider.cc	2018-01-27 20:13:26.960932805 +0100
+@@ -243,7 +243,7 @@
+   allocated_objects_count = main_heap_info.block_count;
+ #elif defined(OS_FUCHSIA)
+ // TODO(fuchsia): Port, see https://crbug.com/706592.
+-#else
++#elif defined(__GLIBC__)
+   struct mallinfo info = mallinfo();
+   DCHECK_GE(info.arena + info.hblkhd, info.uordblks);
+ 
+@@ -255,6 +255,8 @@
+ 
+   // Total allocated space is given by |uordblks|.
+   allocated_objects_size = info.uordblks;
++#else
++// musl libc does not support mallinfo()
+ #endif
+ 
+   MemoryAllocatorDump* outer_dump = pmd->CreateAllocatorDump("malloc");
+--- qtwebengine/src/3rdparty/chromium/base/process/process_metrics_posix.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:03:38.579424720 +0100
+@@ -119,14 +119,14 @@
+   malloc_statistics_t stats = {0};
+   malloc_zone_statistics(nullptr, &stats);
+   return stats.size_in_use;
+-#elif defined(OS_LINUX) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
++#elif (defined(OS_LINUX) && defined(__GLIBC__)) || defined(OS_CHROMEOS) || defined(OS_ANDROID)
+   struct mallinfo minfo = mallinfo();
+ #if BUILDFLAG(USE_TCMALLOC)
+   return minfo.uordblks;
+ #else
+   return minfo.hblkhd + minfo.arena;
+ #endif
+-#elif defined(OS_FUCHSIA)
++#else //if defined(OS_FUCHSIA) // also musl doesn't do this.
+   // TODO(fuchsia): Not currently exposed. https://crbug.com/735087.
+   return 0;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
new file mode 100644
index 000000000000..00017bba0172
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0006-musl-pread-pwrite.patch
@@ -0,0 +1,18 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:26.639964100 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/lss/linux_syscall_support.h	2018-09-07 21:25:11.611964995 +0200
+@@ -1794,6 +1794,15 @@
+ /* End of s390/s390x definitions                                             */
+ #endif
+ 
++#ifndef __GLIBC__
++  /* For Musl libc pread/pread is the same as pread64/pwrite64 */
++#ifndef __NR_pread
++#define __NR_pread              __NR_pread64
++#endif
++#ifndef __NR_pwrite
++#define __NR_pwrite             __NR_pwrite64
++#endif
++#endif /* ifndef __GLIBC__ */
+ 
+ /* After forking, we must make sure to only call system calls.               */
+ #if defined(__BOUNDED_POINTERS__)
diff --git a/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
new file mode 100644
index 000000000000..edfceb79f30a
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0008-musl-resolve.patch
@@ -0,0 +1,26 @@
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_reloader.cc	2016-12-20 03:33:11.749059656 +0100
+@@ -9,6 +9,10 @@
+ 
+ #include <resolv.h>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/lazy_instance.h"
+ #include "base/logging.h"
+ #include "base/macros.h"
+--- qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-11-07 15:46:18.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/net/dns/dns_config_service_posix.cc	2016-12-20 03:40:07.671953098 +0100
+@@ -6,6 +6,10 @@
+ 
+ #include <string>
+ 
++#if !defined(__GLIBC__)
++#include "resolv_compat.h"
++#endif
++
+ #include "base/bind.h"
+ #include "base/files/file.h"
+ #include "base/files/file_path.h"
diff --git a/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
new file mode 100644
index 000000000000..fe760be16664
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0009-musl-siginfo_t.patch
@@ -0,0 +1,18 @@
+There's a subtle difference in the internal name of siginfo_t fields
+between glibc and musl. The structure itself is equivalent, so it
+should suffice to add a macro to rename the field.
+
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-02-17 05:57:43.000000000 +0100
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc	2015-06-03 08:20:25.032716427 +0200
+@@ -22,6 +22,11 @@
+ #include "sandbox/linux/services/android_ucontext.h"
+ #endif
+
++// musl libc defines siginfo_t __si_fields instead of _sifields
++#if !defined(__GLIBC__)
++#define _sifields __si_fields
++#endif
++
+ namespace {
+
+ const int kCapacityIncrement = 20;
diff --git a/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
new file mode 100644
index 000000000000..a9f8ab6c252c
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0010-musl-stackstart.patch
@@ -0,0 +1,20 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:08:43.586475349 +0100
++++ qtwebengine/src/3rdparty/chromium/third_party/blink/renderer/platform/wtf/stack_util.cc	2018-01-27 23:18:22.274505203 +0100
+@@ -28,7 +28,7 @@
+ // FIXME: On Mac OSX and Linux, this method cannot estimate stack size
+ // correctly for the main thread.
+ 
+-#elif defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#elif defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   // pthread_getattr_np() can fail if the thread is not invoked by
+   // pthread_create() (e.g., the main thread of blink_unittests).
+@@ -96,7 +96,7 @@
+ }
+ 
+ void* GetStackStart() {
+-#if defined(__GLIBC__) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
++#if defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_FREEBSD) || \
+     defined(OS_FUCHSIA)
+   pthread_attr_t attr;
+   int error;
diff --git a/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
new file mode 100644
index 000000000000..d3de1e41183d
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0011-musl-sandbox.patch
@@ -0,0 +1,71 @@
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc	2018-09-13 19:53:53.453780253 +0200
+@@ -129,7 +129,7 @@
+ // CLONE_VM, nor CLONE_THREAD, which includes all fork() implementations.
+ ResultExpr RestrictCloneToThreadsAndEPERMFork() {
+   const Arg<unsigned long> flags(0);
+-
++#if defined(__GLIBC__)
+   // TODO(mdempsky): Extend DSL to support (flags & ~mask1) == mask2.
+   const uint64_t kAndroidCloneMask = CLONE_VM | CLONE_FS | CLONE_FILES |
+                                      CLONE_SIGHAND | CLONE_THREAD |
+@@ -148,6 +148,17 @@
+   return If(IsAndroid() ? android_test : glibc_test, Allow())
+       .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
+       .Else(CrashSIGSYSClone());
++#else
++  const int required = CLONE_VM | CLONE_FS | CLONE_FILES | CLONE_SIGHAND |
++                       CLONE_THREAD | CLONE_SYSVSEM;
++  const int safe = CLONE_SETTLS | CLONE_PARENT_SETTID | CLONE_CHILD_CLEARTID |
++                   CLONE_DETACHED;
++  const BoolExpr thread_clone_ok = (flags&~safe)==required;
++
++  return If(thread_clone_ok, Allow())
++      .ElseIf((flags & (CLONE_VM | CLONE_THREAD)) == 0, Error(EPERM))
++      .Else(CrashSIGSYSClone());
++#endif
+ }
+ 
+ ResultExpr RestrictPrctl() {
+--- qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-06-15 09:47:20.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc	2018-09-13 19:56:31.779773940 +0200
+@@ -375,6 +375,9 @@
+ #if defined(__i386__)
+     case __NR_waitpid:
+ #endif
++#if !defined(__GLIBC__)
++    case __NR_set_tid_address:
++#endif
+       return true;
+     case __NR_clone:  // Should be parameter-restricted.
+     case __NR_setns:  // Privileged.
+@@ -387,7 +390,9 @@
+ #if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
+     case __NR_set_thread_area:
+ #endif
++#if defined(__GLIBC__)
+     case __NR_set_tid_address:
++#endif
+     case __NR_unshare:
+ #if !defined(__mips__) && !defined(__aarch64__)
+     case __NR_vfork:
+@@ -496,6 +501,9 @@
+     case __NR_mlock:
+     case __NR_munlock:
+     case __NR_munmap:
++#if !defined(__GLIBC__)
++    case __NR_mremap:
++#endif
+       return true;
+     case __NR_madvise:
+     case __NR_mincore:
+@@ -511,7 +519,9 @@
+     case __NR_modify_ldt:
+ #endif
+     case __NR_mprotect:
++#if defined(__GLIBC__)
+     case __NR_mremap:
++#endif
+     case __NR_msync:
+     case __NR_munlockall:
+     case __NR_readahead:
diff --git a/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
new file mode 100644
index 000000000000..7bf5a22fba71
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0012-musl-chromium-default-stacksize.patch
@@ -0,0 +1,15 @@
+--- qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc.orig	2018-09-19 18:05:15.523923703 +0200
++++ qtwebengine/src/3rdparty/chromium/base/threading/platform_thread_linux.cc	2018-09-19 18:08:05.150932454 +0200
+@@ -173,7 +173,12 @@
+ 
+ size_t GetDefaultThreadStackSize(const pthread_attr_t& attributes) {
+ #if !defined(THREAD_SANITIZER)
++#if defined(__GLIBC__)
+   return 0;
++#else // defined(__GLIBC__)
++  // For Musl libc try with a default stack size of 2 MiB
++  return 2 * 1024 * 1024;
++#endif // !defined(__GLIBC__)
+ #else
+   // ThreadSanitizer bloats the stack heavily. Evidence has been that the
+   // default stack size isn't enough for some browser tests.
diff --git a/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
new file mode 100644
index 000000000000..140742f72c25
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0014-musl-cross-no-asm_ptrace_h.patch
@@ -0,0 +1,30 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc	2018-11-22 00:41:58.522477559 +0100
+@@ -38,7 +38,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_ptrace_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <errno.h>
+ #include <fcntl.h>
+--- qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-08-27 10:21:31.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium/third_party/breakpad/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc	2018-11-22 00:49:39.533492245 +0100
+@@ -32,7 +32,12 @@
+ 
+ #include "client/linux/minidump_writer/linux_core_dumper.h"
+ 
++#if defined(__GLIBC__)
+ #include <asm/ptrace.h>
++#else
++/* For arm*-musl this definition is missing */
++#define ARM_sp uregs[13]
++#endif
+ #include <assert.h>
+ #include <elf.h>
+ #include <stdio.h>
diff --git a/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
new file mode 100644
index 000000000000..faca4d205151
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0015-no-glibc-cmake-check.patch
@@ -0,0 +1,17 @@
+diff --git a/configure.cmake b/configure.cmake
+index 28318587..8ecc66af 100644
+--- a/configure.cmake
++++ b/configure.cmake
+@@ -388,11 +388,6 @@ add_check_for_support(
+    CONDITION NOT LINUX OR PkgConfig_FOUND
+    MESSAGE "A pkg-config support is required."
+ )
+-add_check_for_support(
+-   MODULES QtWebEngine QtPdf
+-   CONDITION NOT LINUX OR TEST_glibc
+-   MESSAGE "A suitable version >= 2.17 of glibc is required."
+-)
+ add_check_for_support(
+    MODULES QtWebEngine QtPdf
+    CONDITION NOT LINUX OR TEST_khr
+
diff --git a/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
new file mode 100644
index 000000000000..608dd0b4e078
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0016-qt-musl-execinfo.patch
@@ -0,0 +1,106 @@
+--- qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc.orig	2019-04-09 09:31:16.000000000 +0200
++++ qtwebengine/src/3rdparty/chromium//base/debug/stack_trace_posix.cc	2019-05-06 23:16:13.245502467 +0200
+@@ -27,7 +27,7 @@
+ #if !defined(USE_SYMBOLIZE)
+ #include <cxxabi.h>
+ #endif
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ #include <execinfo.h>
+ #endif
+ 
+@@ -86,7 +86,7 @@
+   // Note: code in this function is NOT async-signal safe (std::string uses
+   // malloc internally).
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   std::string::size_type search_from = 0;
+   while (search_from < text->size()) {
+     // Look for the start of a mangled symbol, from search_from.
+@@ -121,7 +121,7 @@
+       search_from = mangled_start + 2;
+     }
+   }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ }
+ #endif  // !defined(USE_SYMBOLIZE)
+ 
+@@ -133,7 +133,7 @@
+   virtual ~BacktraceOutputHandler() = default;
+ };
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void OutputPointer(void* pointer, BacktraceOutputHandler* handler) {
+   // This should be more than enough to store a 64-bit number in hex:
+   // 16 hex digits + 1 for null-terminator.
+@@ -216,7 +216,7 @@
+   }
+ #endif  // defined(USE_SYMBOLIZE)
+ }
+-#endif  // !defined(__UCLIBC__) && !defined(_AIX)
++#endif  // !defined(__GLIBC__) && !defined(_AIX)
+ 
+ void PrintToStderr(const char* output) {
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+@@ -812,7 +812,7 @@
+   // NOTE: This code MUST be async-signal safe (it's used by in-process
+   // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   // Though the backtrace API man page does not list any possible negative
+   // return values, we take no chance.
+   return base::saturated_cast<size_t>(backtrace(trace, count));
+@@ -825,13 +825,13 @@
+ // NOTE: This code MUST be async-signal safe (it's used by in-process
+ // stack dumping signal handler). NO malloc or stdio is allowed here.
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   PrintBacktraceOutputHandler handler;
+   ProcessBacktrace(trace_, count_, prefix_string, &handler);
+ #endif
+ }
+ 
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+ void StackTrace::OutputToStreamWithPrefix(std::ostream* os,
+                                           const char* prefix_string) const {
+   StreamBacktraceOutputHandler handler(os);
+--- qtwebengine/src/3rdparty/chromium/base/debug/stack_trace.cc	2019-04-09 09:31:16.000000000 +0200
++++ -	2019-05-06 23:18:14.923566992 +0200
+@@ -233,7 +233,7 @@
+ }
+ std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const {
+   std::stringstream stream;
+-#if !defined(__UCLIBC__) && !defined(_AIX)
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(&stream, prefix_string);
+ #endif
+   return stream.str();
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2017-11-28 14:06:53.000000000 +0100
+--- qtwebengine/src/3rdparty/chromium//base/logging.cc	2018-01-27 22:46:34.970406807 +0100
+@@ -546,7 +546,7 @@
+ 
+ LogMessage::~LogMessage() {
+   size_t stack_start = stream_.tellp();
+-#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && !defined(__UCLIBC__) && \
++#if !defined(OFFICIAL_BUILD) && !defined(OS_NACL) && defined(__GLIBC__) && \
+     !defined(OS_AIX)
+   if (severity_ == LOG_FATAL && !base::debug::BeingDebugged()) {
+     // Include a stack trace on a fatal, unless a debugger is attached.
+--- a/src/3rdparty/chromium/base/debug/stack_trace.cc	2021-06-27 18:17:06.834705848 +0200
++++ -	2021-06-27 18:27:53.014102803 +0200
+@@ -217,7 +217,9 @@
+ }
+ 
+ void StackTrace::OutputToStream(std::ostream* os) const {
++#if defined(__GLIBC__) && !defined(_AIX)
+   OutputToStreamWithPrefix(os, nullptr);
++#endif
+ }
+ 
+ std::string StackTrace::ToString() const {
diff --git a/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
new file mode 100644
index 000000000000..496753bef30f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0017-qt-musl-thread-stacksize.patch
@@ -0,0 +1,26 @@
+diff --git a/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc b/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+index 02bf49b..05ee182 100644
+--- qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
++++ qtwebengine/src/3rdparty/chromium/ppapi/utility/threading/simple_thread.cc
+@@ -13,7 +13,7 @@ namespace pp {
+ namespace {
+ 
+ // Use 2MB default stack size for Native Client, otherwise use system default.
+-#if defined(__native_client__)
++#if defined(__native_client__) || !defined(__GLIBC__)
+ const size_t kDefaultStackSize = 2 * 1024 * 1024;
+ #else
+ const size_t kDefaultStackSize = 0;
+diff --git a/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc b/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+index cf7f3ec..e06a5ce 100644
+--- qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
++++ qtwebengine/src/3rdparty/chromium/v8/src/base/platform/platform-posix.cc
+@@ -761,7 +761,7 @@ void Thread::Start() {
+ #if V8_OS_MACOSX
+     // Default on Mac OS X is 512kB -- bump up to 1MB
+     stack_size = 1 * 1024 * 1024;
+-#elif V8_OS_AIX
++#elif V8_OS_AIX || !defined(__GLIBC__)
+     // Default on AIX is 96kB -- bump up to 2MB
+     stack_size = 2 * 1024 * 1024;
+ #endif
diff --git a/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
new file mode 100644
index 000000000000..b73971f24324
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0018-sandbox-membarrier.patch
@@ -0,0 +1,60 @@
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm64_linux_syscalls.h
+@@ -1063,4 +1063,8 @@
+ #define __NR_memfd_create 279
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 283
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_ARM64_LINUX_SYSCALLS_H_
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,10 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier (__NR_SYSCALL_BASE+389)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_32_linux_syscalls.h
+@@ -1422,5 +1422,9 @@
+ #define __NR_memfd_create 356
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 375
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_32_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/system_headers/x86_64_linux_syscalls.h
+@@ -1290,5 +1290,9 @@
+ #define __NR_memfd_create 319
+ #endif
+ 
++#if !defined(__NR_membarrier)
++#define __NR_membarrier 324
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_SYSCALLS_H_
+ 
+--- qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ qtwebengine/src/3rdparty/chromium//sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -370,6 +370,7 @@
+   switch (sysno) {
+     case __NR_exit:
+     case __NR_exit_group:
++    case __NR_membarrier:
+     case __NR_wait4:
+     case __NR_waitid:
+ #if defined(__i386__)
diff --git a/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
new file mode 100644
index 000000000000..75481a2889f4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0020-msgvec-push_back.patch
@@ -0,0 +1,14 @@
+--- qtwebengine-everywhere-src-5.14.0-beta2/src/3rdparty/chromium/net/socket/udp_socket_posix.cc	2019-10-08 08:27:43.000000000 +0200
++++ -	2019-11-11 22:41:46.699068889 +0100
+@@ -1191,7 +1191,11 @@
+     msg_iov->push_back({const_cast<char*>(buffer->data()), buffer->length()});
+   msgvec->reserve(buffers.size());
+   for (size_t j = 0; j < buffers.size(); j++)
++#if defined(__GLIBC__)
+     msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, nullptr, 0, 0}, 0});
++#else
++    msgvec->push_back({{nullptr, 0, &msg_iov[j], 1, 0, 0, 0}, 0});
++#endif
+   int result = HANDLE_EINTR(Sendmmsg(fd, &msgvec[0], buffers.size(), 0));
+   SendResult send_result(0, 0, std::move(buffers));
+   if (result < 0) {
diff --git a/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
new file mode 100644
index 000000000000..d8c6aa15cf66
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0021-sandbox-sched_getparam.patch
@@ -0,0 +1,26 @@
+Allow SYS_sched_getparam and SYS_sched_getscheduler
+musl uses them for pthread_getschedparam()
+
+source: https://git.alpinelinux.org/aports/commit/community/chromium?id=54af9f8ac24f52d382c5758e2445bf0206eff40e
+
+--- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:13:44.992079145 +0100
+@@ -93,11 +93,18 @@
+     case __NR_sysinfo:
+     case __NR_times:
+     case __NR_uname:
++#if !defined(__GLIBC__)
++    case __NR_sched_getparam:
++    case __NR_sched_getscheduler:
++    case __NR_sched_setscheduler:
++#endif
+       return Allow();
+     case __NR_sched_getaffinity:
++#if defined(__GLIBC__)
+     case __NR_sched_getparam:
+     case __NR_sched_getscheduler:
+     case __NR_sched_setscheduler:
++#endif
+       return RestrictSchedTarget(GetPolicyPid(), sysno);
+     case __NR_prlimit64:
+       // See crbug.com/662450 and setrlimit comment above.
diff --git a/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
new file mode 100644
index 000000000000..893ed2d41bb4
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0022-canonicalize-file-name-musl.patch
@@ -0,0 +1,11 @@
+--- qtwebengine/src/3rdparty/chromium/third_party/nasm/nasmlib/realpath.c	2019-09-23 14:24:20.000000000 +0200
++++ -	2019-10-11 06:27:28.450329986 +0200
+@@ -57,7 +57,7 @@
+  */
+ char *nasm_realpath(const char *rel_path)
+ {
+-    char *rp = canonicalize_file_name(rel_path);
++    char *rp = realpath(rel_path, NULL);
+     return rp ? rp : nasm_strdup(rel_path);
+ }
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
new file mode 100644
index 000000000000..b87766825063
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0089-enable-ppc64.patch
@@ -0,0 +1,49 @@
+From 463f1234c57a36e78ff666bd55094a9d4e68f296 Mon Sep 17 00:00:00 2001
+From: q66 <daniel@octaforge.org>
+Date: Sat, 18 Jan 2020 23:52:55 +0100
+Subject: [PATCH 1/3] Enable ppc64 builds
+
+---
+ configure.pri                  | 1 +
+ mkspecs/features/functions.prf | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/configure.pri b/configure.pri
+index 3a144e3f8..cabe8b24a 100644
+--- a/configure.pri	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:18:43.124754796 +0100
+@@ -144,6 +144,7 @@
+     contains(QT_ARCH, "arm")|contains(QT_ARCH, "arm64"): return(true)
+     contains(QT_ARCH, "mips"): return(true)
+     contains(QT_ARCH, "mips64"): return(true)
++    contains(QT_ARCH, "power64"): return(true)
+     qtLog("Architecture not supported.")
+     return(false)
+ }
+diff --git a/mkspecs/features/functions.prf b/mkspecs/features/functions.prf
+index 512e2523b..e31123654 100644
+--- a/mkspecs/features/functions.prf	2021-02-24 10:45:58.000000000 +0100
++++ -	2021-03-07 21:19:21.345036293 +0100
+@@ -107,6 +107,7 @@
+     contains(qtArch, "mips"): return(mipsel)
+     contains(qtArch, "mips64"): return(mips64el)
+     contains(qtArch, "mips64el"): return(mips64el)
++    contains(qtArch, "power64"): return(ppc64)
+     return(unknown)
+ }
+ 
+--- a/cmake/Functions.cmake	2021-06-27 21:30:47.236998844 +0200
++++ -	2021-06-27 21:33:50.091794753 +0200
+@@ -362,6 +362,8 @@
+       set(${result} "mipsel" PARENT_SCOPE)
+    elseif("${arch}" STREQUAL "mipsel64")
+       set(${result} "mips64el" PARENT_SCOPE)
++   elseif("${arch}" STREQUAL "power64")
++      set(${result} "ppc64" PARENT_SCOPE)
+    else()
+       message(DEBUG "Unsupported achitecture: ${arch}")
+    endif()
+
+-- 
+2.26.0
+
diff --git a/srcpkgs/qt6-webengine/patches/0110-size_t.patch b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
new file mode 100644
index 000000000000..462e3202279f
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0110-size_t.patch
@@ -0,0 +1,16 @@
+--- a/src/3rdparty/chromium/third_party/angle/include/platform/PlatformMethods.h	2021-02-23 16:36:59.000000000 +0100
++++ -	2021-03-07 21:44:25.477989726 +0100
+@@ -239,11 +239,11 @@
+ using ProgramKeyType   = std::array<uint8_t, 20>;
+ using CacheProgramFunc = void (*)(PlatformMethods *platform,
+                                   const ProgramKeyType &key,
+-                                  size_t programSize,
++                                  std::size_t programSize,
+                                   const uint8_t *programBytes);
+ inline void DefaultCacheProgram(PlatformMethods *platform,
+                                 const ProgramKeyType &key,
+-                                size_t programSize,
++                                std::size_t programSize,
+                                 const uint8_t *programBytes)
+ {}
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
new file mode 100644
index 000000000000..368099b981cc
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0111-armv7l-neon.patch
@@ -0,0 +1,10 @@
+--- a/src/3rdparty/chromium/skia/BUILD.gn	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/skia/BUILD.gn	2020-10-06 20:51:48.834970455 +0200
+@@ -772,7 +772,6 @@
+         # Root build config sets -mfpu=$arm_fpu, which we expect to be neon
+         # when running this.
+         if (!arm_use_neon) {
+-          configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
+           cflags += [ "-mfpu=neon" ]
+         }
+       }
diff --git a/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
new file mode 100644
index 000000000000..6e2d62f35ee6
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0112-arm-user_vfp.patch
@@ -0,0 +1,20 @@
+--- a/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
++++ b/src/3rdparty/chromium/third_party/crashpad/crashpad/util/linux/thread_info.h
+@@ -17,6 +17,17 @@
+ 
+ #include <stdint.h>
+ #include <sys/user.h>
++#if !defined(__GLIBC__)
++struct user_vfp {
++	unsigned long long fpregs[32];
++	unsigned long fpscr;
++};
++struct user_vfp_exc {
++	unsigned long fpexc;
++	unsigned long fpinst;
++	unsigned long fpinst2;
++};
++#endif /* !defined(__GLIBC__) */
+ 
+ #include <type_traits>
+ 
diff --git a/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
new file mode 100644
index 000000000000..5c7cbfc46f65
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0113-arm-elf_auxv_t.patch
@@ -0,0 +1,18 @@
+--- a/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-09-01 13:02:34.000000000 +0200
++++ b/src/3rdparty/chromium/v8/src/base/cpu.cc	2020-10-06 21:28:45.124882085 +0200
+@@ -109,6 +109,15 @@
+ #define HWCAP_IDIV  (HWCAP_IDIVA | HWCAP_IDIVT)
+ #define HWCAP_LPAE  (1 << 20)
+ 
++#ifndef __GLIBC__
++#include <elf.h>
++#ifdef __LP64__
++typedef Elf64_auxv_t elf_auxv_t;
++#else
++typedef Elf32_auxv_t elf_auxv_t;
++#endif
++#endif
++
+ static uint32_t ReadELFHWCaps() {
+ #if V8_GLIBC_PREREQ(2, 16)
+   return static_cast<uint32_t>(getauxval(AT_HWCAP));
diff --git a/srcpkgs/qt6-webengine/patches/0114-time64.patch b/srcpkgs/qt6-webengine/patches/0114-time64.patch
new file mode 100644
index 000000000000..6a98dd4e480e
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/0114-time64.patch
@@ -0,0 +1,89 @@
+Description: fix seccomp-bpf failures in syscalls 0403, 0407
+ glibc ≥ 2.31 uses these syscalls on 32-bit platforms:
+ .
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=2e44b10b42d68d98
+ - https://sourceware.org/git/?p=glibc.git;a=commit;h=ec138c67cbda8b58
+Author: Andreas Müller <schnitzeltony@gmail.com>
+Forwarded: no
+Last-Update: 2020-09-02
+
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc
+@@ -148,7 +148,14 @@ ResultExpr EvaluateSyscallImpl(int fs_de
+     return Allow();
+ #endif
+ 
+-  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep) {
++  if (sysno == __NR_clock_gettime || sysno == __NR_clock_nanosleep
++#if defined(__NR_clock_gettime64)
++                                  || sysno == __NR_clock_gettime64
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++                                  || sysno == __NR_clock_nanosleep_time64
++#endif
++  ) {
+     return RestrictClockID();
+   }
+ 
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc
+@@ -60,6 +60,12 @@ class RestrictClockIdPolicy : public bpf
+       case __NR_clock_gettime:
+       case __NR_clock_getres:
+       case __NR_clock_nanosleep:
++#if defined(__NR_clock_nanosleep_time64)
++      case __NR_clock_nanosleep_time64:
++#endif
++#if defined(__NR_clock_gettime64)
++      case __NR_clock_gettime64:
++#endif
+         return RestrictClockID();
+       default:
+         return Allow();
+--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+@@ -39,6 +39,12 @@ bool SyscallSets::IsAllowedGettime(int s
+                                 // filtered by RestrictClokID().
+     case __NR_clock_gettime:    // Parameters filtered by RestrictClockID().
+     case __NR_clock_nanosleep:  // Parameters filtered by RestrictClockID().
++#if defined(__NR_clock_gettime64)
++    case __NR_clock_gettime64:  // Parameters filtered by RestrictClockID().
++#endif
++#if defined(__NR_clock_nanosleep_time64)
++    case __NR_clock_nanosleep_time64:  // Parameters filtered by RestrictClockID().
++#endif
+     case __NR_clock_settime:    // Privileged.
+ #if defined(__i386__) || \
+     (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS))
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/arm_linux_syscalls.h
+@@ -1385,6 +1385,14 @@
+ #define __NR_memfd_create (__NR_SYSCALL_BASE+385)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_SYSCALL_BASE+403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_SYSCALL_BASE+407)
++#endif
++
+ // ARM private syscalls.
+ #if !defined(__ARM_NR_BASE)
+ #define __ARM_NR_BASE (__NR_SYSCALL_BASE + 0xF0000)
+--- a/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/mips_linux_syscalls.h
+@@ -1433,4 +1433,12 @@
+ #define __NR_memfd_create (__NR_Linux + 354)
+ #endif
+ 
++#if !defined(__NR_clock_gettime64)
++#define __NR_clock_gettime64 (__NR_Linux + 403)
++#endif
++
++#if !defined(__NR_clock_nanosleep_time64)
++#define __NR_clock_nanosleep_time64 (__NR_Linux + 407)
++#endif
++
+ #endif  // SANDBOX_LINUX_SYSTEM_HEADERS_MIPS_LINUX_SYSCALLS_H_
diff --git a/srcpkgs/qt6-webengine/patches/pthread_getname_np-mus.patch b/srcpkgs/qt6-webengine/patches/pthread_getname_np-mus.patch
new file mode 100644
index 000000000000..aabaa51b9015
--- /dev/null
+++ b/srcpkgs/qt6-webengine/patches/pthread_getname_np-mus.patch
@@ -0,0 +1,15 @@
+--- a/src/3rdparty/chromium/third_party/perfetto/include/perfetto/ext/base/thread_utils.h	2021-09-12 00:49:47.623538583 +0200
++++ -	2021-09-12 00:50:07.673426016 +0200
+@@ -61,9 +61,11 @@
+ #if PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID)
+   if (prctl(PR_GET_NAME, buf) != 0)
+     return false;
+-#else
++#elif defined(__GLIBC__)
+   if (pthread_getname_np(pthread_self(), buf, sizeof(buf)) != 0)
+     return false;
++#else
++  return false;
+ #endif
+   out_result = std::string(buf);
+   return true;
diff --git a/srcpkgs/qt6-webengine/template b/srcpkgs/qt6-webengine/template
new file mode 100644
index 000000000000..a9a64b246748
--- /dev/null
+++ b/srcpkgs/qt6-webengine/template
@@ -0,0 +1,87 @@
+# Template file for 'qt6-webengine'
+pkgname=qt6-webengine
+version=6.2.0beta4
+revision=1
+wrksrc="qtwebengine-everywhere-src-${version/beta/-beta}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true
+ -DQT_FEATURE_webengine_system_ffmpeg=ON
+ -DQT_FEATURE_webengine_system_libevent=ON
+ -DQT_FEATURE_webengine_system_gn=ON
+ -DPKG_CONFIG_HOST_EXECUTABLE=${PKG_CONFIG_FOR_BUILD}"
+hostmakedepends="qt6-base-devel perl pkg-config nodejs python
+ qt6-declarative-devel protobuf gperf flex nss-devel libwebp-devel"
+makedepends="qt6-base-devel qt6-declarative-devel pulseaudio-devel
+ alsa-lib-devel libvpx-devel pciutils-devel opus-devel libxslt-devel
+ libxml2-devel freetype-devel lcms2-devel libwebp-devel icu-devel
+ re2-devel zlib-devel libpng-devel minizip-devel harfbuzz-devel
+ nss-devel libXcursor-devel libXcomposite-devel libXScrnSaver-devel
+ protobuf-devel ffmpeg-devel snappy-devel libevent-devel pipewire-devel
+ libxkbfile-devel qt6-location-devel qt6-webchannel-devel"
+short_desc="Cross-platform application and UI framework - Webengine"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-3.0-only, GPL-2.0-only, LGPL-3.0-only BSD-3-Clause"
+homepage="https://www.qt.io"
+distfiles="https://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtwebengine-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=0fc904e6c9b36096382ec340b5b3989e08b33dca6530052c7611c76bb75e6e1e
+
+if [ -z "$CROSS_BUILD" ];then
+	configure_args+=" -DCMAKE_TOOLCHAIN_FILE=/usr/lib/cmake/Qt6/qt.toolchain.cmake"
+fi
+
+if [ "$XBPS_LIBC" = "musl" ]; then
+	hostmakedepends+=" musl-legacy-compat"
+fi
+
+if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
+	makedepends+=" musl-legacy-compat"
+fi
+
+if [ ! "$XBPS_WORDSIZE" = "$XBPS_TARGET_WORDSIZE" ]; then
+	broken="webengine can be built only if word size matches"
+fi
+
+if [ "$XBPS_WORDSIZE" -eq 32 ]; then
+	nodebug=yes
+	LDFLAGS="-Wl,--no-keep-memory"
+fi
+
+if [ "$XBPS_TARGET_ENDIAN" != "le" ]; then
+	broken="webengine only supports little endian"
+fi
+
+_bootstrap_gn() {
+	# Bootstrap gn (generate ninja)
+	echo "Bootstrapping 'gn'"
+	cd ${wrksrc}/src/3rdparty/gn
+	CFLAGS="$CFLAGS_host" CXXFLAGS="$CXXFLAGS_host" LDFLAGS="$LDFLAGS_host" \
+	PKGCONFIG=/usr/bin/pkgconfig PKG_CONFIG_PATH="/usr/lib/pkgconfig:/usr/share/pkgconfig" \
+		python2 build/gen.py --no-last-commit-position --out-path \
+			${wrksrc}/src/3rdparty/gn/out/Release --cc "${CC_host:-$CC}" \
+			--cxx "${CXX_host:-$CXX}" --ld "${CXX_host:-$CXX}" --ar "${AR_host:-$AR}" \
+			--qt-version "${version}.qtwebengine.qt.io"
+	ninja -C out/Release gn
+	cd ${wrksrc}
+}
+
+pre_configure() {
+	cp ${FILESDIR}/resolv_compat.h ${wrksrc}/src/3rdparty/chromium/net/dns
+	_bootstrap_gn
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+pre_build() {
+	export PATH="$PATH:${wrksrc}/src/3rdparty/gn/out/Release"
+}
+
+qt6-webengine-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-webchannel-devel>=${version}_1
+	 qt6-declarative-devel>=${version}_1 qt6-location-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+	}
+}

From f9d188cb340299a93dbd29a716f61a69a9afeae3 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sun, 27 Jun 2021 16:00:28 +0200
Subject: [PATCH 23/23] New package: qt6-location-6.2.0alpha

---
 common/shlibs                 |  1 +
 srcpkgs/qt6-location-devel    |  1 +
 srcpkgs/qt6-location/template | 27 +++++++++++++++++++++++++++
 3 files changed, 29 insertions(+)
 create mode 120000 srcpkgs/qt6-location-devel
 create mode 100644 srcpkgs/qt6-location/template

diff --git a/common/shlibs b/common/shlibs
index 33c9fda80cc4..512a425fd16e 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2055,6 +2055,7 @@ libQt6VirtualKeyboard.so.6 qt6-virtualkeyboard-6.1.0_1
 libQt6SerialPort.so.6 qt6-serialport-6.2.0alpha_1
 libQt6WebSockets.so.6 qt6-websockets-6.2.0alpha_1
 libQt6WebChannel.so.6 qt6-webchannel-6.2.0alpha_1
+libQt6Positioning.so.6 qt6-location-6.2.0alpha_1
 libnpth.so.0 npth-1.1_1
 libnpupnp.so.4 libnpupnp-4.0.2_1
 libglfw.so.3 glfw-3.0.4_1
diff --git a/srcpkgs/qt6-location-devel b/srcpkgs/qt6-location-devel
new file mode 120000
index 000000000000..7924c82dd3f4
--- /dev/null
+++ b/srcpkgs/qt6-location-devel
@@ -0,0 +1 @@
+qt6-location
\ No newline at end of file
diff --git a/srcpkgs/qt6-location/template b/srcpkgs/qt6-location/template
new file mode 100644
index 000000000000..8c7915c6b2fa
--- /dev/null
+++ b/srcpkgs/qt6-location/template
@@ -0,0 +1,27 @@
+# Template file for 'qt6-location'
+pkgname=qt6-location
+version=6.2.0beta4
+revision=1
+wrksrc="qtlocation-everywhere-src-${version/beta/-beta}"
+build_style=cmake
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
+makedepends="qt6-serialport-devel qt6-declarative-devel GConf-devel"
+short_desc="Cross-platform application and UI framework - location"
+maintainer="John <me@johnnynator.dev>"
+license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
+homepage="https://qt.io/"
+distfiles="http://download.qt.io/development_releases/qt/${version%.*}/${version/beta/-beta}/submodules/qtlocation-everywhere-src-${version/beta/-beta}.tar.xz"
+checksum=14e455b383c9cb3ab015b4539f0447a284966d6acd8e00cf05e10b318347d222
+
+qt6-location-devel_package() {
+	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"
+	short_desc+=" - development files"
+	pkg_install() {
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/*.so"
+		vmove "usr/lib/*.prl"
+	}
+}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (5 preceding siblings ...)
  2021-09-12 14:47 ` [PR PATCH] [Updated] " Johnnynator
@ 2021-10-03 13:14 ` Johnnynator
  2021-10-03 13:22 ` Johnnynator
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-10-03 13:14 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

There is an updated pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 40311 bytes --]

From c8592aae66ae56ff5972845450ec66c1783a4690 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 01/22] qt6-3d: update to 6.2.0.

---
 srcpkgs/qt6-3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..9a660ea8b7d3 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qt3d-everywhere-src-${version}"
+wrksrc="qt3d-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - 3d"
 maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qt3d-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=304352ae74fc8e7fe50a822413d69094efb25f15a2323e083a2a53dc5a43a6c6
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 31f443416cdae8d483989913d9190bd76640205d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 02/22] qt6-base: update to 6.2.0.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 ++++++++++++++
 srcpkgs/qt6-base/template                     | 34 +++++++++++++++----
 srcpkgs/qt6-plugin-networkinformation         |  1 +
 srcpkgs/qt6-plugin-tls-openssl                |  1 +
 srcpkgs/qt6-plugin-tls-qcertonly              |  1 +
 5 files changed, 56 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
 create mode 120000 srcpkgs/qt6-plugin-networkinformation
 create mode 120000 srcpkgs/qt6-plugin-tls-openssl
 create mode 120000 srcpkgs/qt6-plugin-tls-qcertonly

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index 0b3dd492fb1f..0ac74ecf7553 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
-revision=2
-wrksrc="qtbase-everywhere-src-${version}"
+version=6.2.0
+revision=1
+wrksrc="qtbase-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
  -DINSTALL_ARCHDATADIR=lib/qt6
@@ -22,13 +22,14 @@ makedepends="zlib-devel libzstd-devel dbus-devel
  libpng-devel tslib-devel libinput-devel gtk+3-devel
  libmariadbclient-devel postgresql-libs-devel libatomic-devel
  unixodbc-devel cups-devel libproxy-devel brotli-devel
- sqlite-devel Vulkan-Headers mit-krb5-devel vulkan-loader libb2-devel"
+ sqlite-devel Vulkan-Headers mit-krb5-devel vulkan-loader libb2-devel
+ libXevie-devel libXcursor-devel"
 short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+distfiles="https://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtbase-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=fdfff0716d093bcb6bcd53746ce1d3c9701a6bf3326d47813866d43949b47769
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -207,6 +208,27 @@ qt6-plugin-sqlite_package() {
 	}
 }
 
+qt6-plugin-tls-openssl_package() {
+	short_desc+=" - TLS plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/tls/libqopensslbackend.so
+	}
+}
+
+qt6-plugin-tls-qcertonly_package() {
+	short_desc+=" - TLS plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/tls/libqcertonlybackend.so
+	}
+}
+
+qt6-plugin-networkinformation() {
+	short_desc+=" - Networkinformation plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/networkinformation/libqnetworkmanager.so
+	}
+}
+
 qt6-base-devel_package() {
 	short_desc+=" - Development files"
 	depends="qt6-base>=${version}_${revision}
diff --git a/srcpkgs/qt6-plugin-networkinformation b/srcpkgs/qt6-plugin-networkinformation
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-networkinformation
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file
diff --git a/srcpkgs/qt6-plugin-tls-openssl b/srcpkgs/qt6-plugin-tls-openssl
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-tls-openssl
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file
diff --git a/srcpkgs/qt6-plugin-tls-qcertonly b/srcpkgs/qt6-plugin-tls-qcertonly
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-tls-qcertonly
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file

From 06031da8ba852ed54c9c7bf5b336969b42ed0e69 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 03/22] qt6-charts: update to 6.2.0.

---
 srcpkgs/qt6-charts/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..91c4b4245154 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtcharts-everywhere-src-${version}"
+wrksrc="qtcharts-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - charts"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtcharts-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=9114d4e05e63f5b9d5f07d53d72bf2fbfb22ffae283cc98d3371d73f04b6f4fc
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From b6508bdc57846395d7b7100c8c806db4211fb238 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 04/22] qt6-declarative: update to 6.2.0.

---
 common/shlibs                       |  8 ++++----
 srcpkgs/qt6-declarative/template    | 28 ++++++++++++++++++----------
 srcpkgs/qt6-quickcontrols2-devel    |  1 -
 srcpkgs/qt6-quickcontrols2/template | 27 ---------------------------
 srcpkgs/qt6-quickcontrols2/update   |  1 -
 5 files changed, 22 insertions(+), 43 deletions(-)
 delete mode 120000 srcpkgs/qt6-quickcontrols2-devel
 delete mode 100644 srcpkgs/qt6-quickcontrols2/template
 delete mode 100644 srcpkgs/qt6-quickcontrols2/update

diff --git a/common/shlibs b/common/shlibs
index c5e88324a924..44d61909c7b3 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2010,7 +2010,7 @@ libQt6LabsSharedImage.so.6 qt6-declarative-6.1.0_1
 libQt6LabsWavefrontMesh.so.6 qt6-declarative-6.1.0_1
 libQt6QmlLocalStorage.so.6 qt6-declarative-6.1.0_1
 libQt6QmlWorkerScript.so.6 qt6-declarative-6.0.0_1
-libQt6QuickTest.so.6 qt6-declarative-6.0.0_1
+libQt6QuickTest.so.6 qt6-declarative-devel-6.2.0beta4_1
 libQt6QuickShapes.so.6 qt6-declarative-6.0.0_1
 libQt6QuickWidgets.so.6 qt6-declarative-6.0.0_1
 libQt6Quick.so.6 qt6-declarative-6.0.0_1
@@ -2024,9 +2024,9 @@ libQt6Quick3DUtils.so.6 qt6-quick3d-6.0.0_1
 libQt6Quick3DAssetImport.so.6 qt6-quick3d-6.0.0_1
 libQt6Quick3DIblBaker.so.6 qt6-quick3d-6.0.3_1
 libQt6Quick3DParticles.so.6 qt6-quick3d-6.1.0_1
-libQt6QuickControls2Impl.so.6 qt6-quickcontrols2-6.0.0_1
-libQt6QuickControls2.so.6 qt6-quickcontrols2-6.0.0_1
-libQt6QuickTemplates2.so.6 qt6-quickcontrols2-6.0.0_1
+libQt6QuickControls2Impl.so.6 qt6-declarative-6.0.0_1
+libQt6QuickControls2.so.6 qt6-declarative-6.0.0_1
+libQt6QuickTemplates2.so.6 qt6-declarative-6.0.0_1
 libQt6NetworkAuth.so.6 qt6-networkauth-6.1.0rc2_1
 libQt6ScxmlQml.so.6 qt6-scxml-6.1.0rc2_1
 libQt6Scxml.so.6 qt6-scxml-6.1.0rc2_1
diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..137f115986ad 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,24 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtdeclarative-everywhere-src-${version}"
+wrksrc="qtdeclarative-everywhere-src-${version/rc/-rc}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+distfiles="https://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtdeclarative-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=46737feceb9e54d63ad0c87a08d33f08ca58f4b8920ccefad8f1ebd64f0d1270
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+	hostmakedepends+=" qt6-declarative-devel"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +38,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}
@@ -50,6 +55,9 @@ qt6-declarative-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/libQt6QuickTest.so.*"
+		vmove usr/lib/qt6/qml/QtTest
+		vmove usr/lib/qt6/bin/qmltestrunner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}
diff --git a/srcpkgs/qt6-quickcontrols2-devel b/srcpkgs/qt6-quickcontrols2-devel
deleted file mode 120000
index 280bc162057d..000000000000
--- a/srcpkgs/qt6-quickcontrols2-devel
+++ /dev/null
@@ -1 +0,0 @@
-qt6-quickcontrols2
\ No newline at end of file
diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
deleted file mode 100644
index ab57102a19cf..000000000000
--- a/srcpkgs/qt6-quickcontrols2/template
+++ /dev/null
@@ -1,27 +0,0 @@
-# Template file for 'qt6-quickcontrols2'
-pkgname=qt6-quickcontrols2
-version=6.1.1
-revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
-build_style=cmake
-configure_args="-DQT_HOST_PATH=/usr "
-hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
-makedepends="qt6-base-devel qt6-declarative-devel"
-short_desc="Cross-platform application and UI framework - quickcontrols2"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later, LGPL-3.0-or-later"
-homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
-
-qt6-quickcontrols2-devel_package() {
-	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"
-	short_desc+=" - development files"
-	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/cmake
-		vmove usr/lib/qt6/mkspecs
-		vmove "usr/lib/*.so"
-		vmove "usr/lib/*.prl"
-	}
-}
diff --git a/srcpkgs/qt6-quickcontrols2/update b/srcpkgs/qt6-quickcontrols2/update
deleted file mode 100644
index 844552465222..000000000000
--- a/srcpkgs/qt6-quickcontrols2/update
+++ /dev/null
@@ -1 +0,0 @@
-pkgname="${pkgname/6-/}-everywhere-src"

From 7ee56f4748fb9a662aec75c804ed7606122dfdcc Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 05/22] qt6-imageformats: update to 6.2.0.

---
 srcpkgs/qt6-imageformats/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..288ee812b07e 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtimageformats-everywhere-src-${version}"
+wrksrc="qtimageformats-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - imageformats"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtimageformats-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=fdaa35536c3d0f8f5f313d0d52dedfbf6d8fcd81a82d6a56f473253f135072ad

From c3a570108d699e262824ac6201e67b3642710989 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 06/22] qt6-lottie: update to 6.2.0.

---
 srcpkgs/qt6-lottie/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..244a463742b1 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtlottie-everywhere-src-${version}"
+wrksrc="qtlottie-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - lottie"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtlottie-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=aa129261d409b5d935221acd6e38f56d68eac5e467a1990c96c654e81a2522ff
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 9657e08fee966b4a3460199196e3a4e0987cdb47 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 07/22] qt6-networkauth: update to 6.2.0.

---
 srcpkgs/qt6-networkauth/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..a29953dae394 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtnetworkauth-everywhere-src-${version}"
+wrksrc="qtnetworkauth-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - networkauth"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtnetworkauth-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=e71504c8d6ae4cf4d573f1d91ff756f90f441e22b0af12eae2424f7e0c01d450
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 886505cdcfcfe97c89ac55d716145bc300110325 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 08/22] qt6-qt5compat: update to 6.2.0.

---
 srcpkgs/qt6-qt5compat/template | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index 06837849b3f1..ae9165bdbbce 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,18 +1,18 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
-revision=2
-wrksrc="qt5compat-everywhere-src-${version}"
+version=6.2.0
+revision=1
+wrksrc="qt5compat-everywhere-src-${version/rc/-rc}"
 build_style=cmake
-configure_args="-DQT_HOST_PATH=/usr "
-hostmakedepends="qt6-base-devel perl"
-makedepends="qt6-base-devel"
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="qt6-base-devel qt6-declarative-devel perl pkg-config"
+makedepends="qt6-base-devel qt6-declarative-devel"
 short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Component"
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qt5compat-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=c2e2f058ecee36a96c1b15937badeda9b7b03eb5278fa01af4ff386c4f1854fb
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From bd120637ed211077756caaaa525f8ff410d87205 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 09/22] qt6-quick3d: update to 6.2.0.

---
 srcpkgs/qt6-quick3d/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..7bfb9e9f39bc 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtquick3d-everywhere-src-${version}"
+wrksrc="qtquick3d-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel qt6-shadertools-devel"
@@ -12,8 +12,8 @@ short_desc="Cross-platform application and UI framework - Quick3d"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtquick3d-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=e8f8163237468e158ace7737d60a0a722209ffda444c57c786fc53db1af851e1
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From ea56639d4d8d6bebd799d76298a5480855165a55 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 10/22] qt6-quicktimeline: update to 6.2.0.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..4c0912d93347 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtquicktimeline-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=67d644ad12df94e937bac3a1cb8a81a96213ec0102759a86c59ba7834ac90c8c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From af9e152e90d4753455f45ead89b2731c442fa73f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 11/22] qt6-scxml: update to 6.2.0.

---
 srcpkgs/qt6-scxml/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..a9680c2ce03b 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtscxml-everywhere-src-${version}"
+wrksrc="qtscxml-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - scxml"
 maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtscxml-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=90d4af011a17f04a003cbd453c7e0720787e6cdacb8dfce7167179c2cd7dc839
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 101afd32dc2bd126b5f20cf4a52f0abc5d42189e Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 12/22] qt6-shadertools: update to 6.2.0.

---
 srcpkgs/qt6-shadertools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..e497d4102d24 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtshadertools-everywhere-src-${version}"
+wrksrc="qtshadertools-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - shadertools"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtshadertools-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=5f66d43610a3a6739fc360d836a2c045135107c0ecd40eb3ed18ce5f3dd79c42
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From e222d164875a36456fd312787d2bf2a1bc49458f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 13/22] qt6-svg: update to 6.2.0.

---
 srcpkgs/qt6-svg/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..96afb3ff76b9 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtsvg-everywhere-src-${version}"
+wrksrc="qtsvg-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-svg componen
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtsvg-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=af9eabefbb0dcb772f18fae4d2c39bcc23579a5dfff569c35ea7e497591db3d4
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From b145b680b608b3cde682d183ef95c8c4f269e585 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 14/22] qt6-tools: update to 6.2.0.

---
 srcpkgs/qt6-tools/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..3bccc8541643 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qttools-everywhere-src-${version}"
+wrksrc="qttools-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel perl"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework (QT6) - qt6-tools compon
 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://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qttools-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=a903d005f8ab39545aed88a13b04f13ddbbe073da7007203a91fb8b42b890057
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From eb625f167fe3be24bcb8fd4ffd26841afced6f77 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 15/22] qt6-translations: update to 6.2.0.

---
 srcpkgs/qt6-translations/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..024306e08fa4 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qttranslations-everywhere-src-${version}"
+wrksrc="qttranslations-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="qt6-base-devel qt6-tools-devel perl"
@@ -11,5 +11,5 @@ short_desc="Cross-platform application and UI framework - translations"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qttranslations-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=5b4ecb1ee35363444f03b1eb10637d79af1d19be5a5cc53657dc0925a78b2240

From 6709cbd4ddb9de8bcf21e9982e8aebde9eb178ab Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 16/22] qt6-virtualkeyboard: update to 6.2.0.

---
 srcpkgs/qt6-virtualkeyboard/template | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..ece682a51e84 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,20 +1,18 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
+wrksrc="qtvirtualkeyboard-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
-makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
- qt6-svg-devel hunspell-devel"
-depends="qt6-quickcontrols2"
+makedepends="qt6-declarative-devel qt6-svg-devel hunspell-devel"
 short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtvirtualkeyboard-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=1055e7fe1dfaecbfd4b69f40ec1135fda1980e6e21adbe757a8a4affbfb9bcee
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From aaa642cfd49c804ecef955c436ad2a2957f7f905 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 17/22] qt6-wayland: update to 6.2.0.

---
 srcpkgs/qt6-wayland/template | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..d03a97229a03 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtwayland-everywhere-src-${version}"
+wrksrc="qtwayland-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel qt6-wayland-devel"
@@ -14,8 +14,8 @@ short_desc="Cross-platform application and UI framework - Wayland"
 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+distfiles="https://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtwayland-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=d6787fce74bde1a3386bcbe43c078c712471bab09f1946c40fc2327232d27d4c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From a93d6793eb70f238e86b1928d003963c4c8f8fde Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 18:59:44 +0200
Subject: [PATCH 18/22] double-conversion: update to 3.1.5.

---
 common/shlibs                      |  2 +-
 srcpkgs/double-conversion/template | 14 +++++++-------
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 44d61909c7b3..7e5289f58f66 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2980,7 +2980,7 @@ libnss_libvirt_guest.so.2 libvirt-3.1.0_1
 libvirt-admin.so.0 libvirt-3.1.0_1
 libnss_libvirt.so.2 libvirt-3.1.0_1
 libassimp.so.5 libassimp-5.0.0_1
-libdouble-conversion.so.1 double-conversion-2.0.1_1
+libdouble-conversion.so.3 double-conversion-3.1.5_1
 libspectrum.so.8 libspectrum-1.2.2_1
 libbearssl.so.0 bearssl-0.3_1
 libXfont2.so.2 libXfont2-2.0.1_1
diff --git a/srcpkgs/double-conversion/template b/srcpkgs/double-conversion/template
index e67aa3b7d01a..fa03b83c3a81 100644
--- a/srcpkgs/double-conversion/template
+++ b/srcpkgs/double-conversion/template
@@ -1,15 +1,16 @@
 # Template file for 'double-conversion'
 pkgname=double-conversion
-version=3.1.1
+version=3.1.5
 revision=1
-build_style=scons
+build_style=cmake
+configure_args="-DBUILD_SHARED_LIBS=ON -DBUILD_TESTING=ON"
 short_desc="Efficient binary-decimal and decimal-binary routines for IEEE doubles"
 maintainer="Diogo Leal <diogo@diogoleal.com>"
 license="BSD-3-Clause"
 homepage="https://github.com/google/double-conversion"
 changelog="https://raw.githubusercontent.com/google/double-conversion/master/Changelog"
 distfiles="https://github.com/google/double-conversion/archive/v${version}.tar.gz"
-checksum=c49a6b3fa9c917f827b156c8e0799ece88ae50440487a99fc2f284cfd357a5b9
+checksum=a63ecb93182134ba4293fd5f22d6e08ca417caafa244afaa751cbfddf6415b13
 
 post_install() {
 	vlicense LICENSE
@@ -19,9 +20,8 @@ double-conversion-devel_package() {
 	short_desc+=" - development files"
 	depends="${sourcepkg}>=${version}_${revision}"
 	pkg_install() {
-		vmkdir usr/include/double-conversion
-		vcopy double-conversion/*.h usr/include/double-conversion/
-		vmove usr/lib/*.a
-		vmove usr/lib/*.so
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove "usr/lib/*.so"
 	}
 }

From 6c7dfec80db94667d4c884f738f2808813d0ffe4 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 19/22] qt5: update to 5.15.3+20211001.

---
 srcpkgs/qt5/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 790ccc808d9e..c1d822ef021d 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,6 +1,6 @@
 # Template file for 'qt5'
 pkgname=qt5
-version=5.15.3+20210924
+version=5.15.3+20211001
 # commit fcca82ca40a5d8a02a4ddd90846d070f2c58cfad
 # base repo: https://invent.kde.org/qt/qt/qt5
 revision=1
@@ -27,7 +27,7 @@ homepage="https://qt.io/"
 # to keep the size smaller qtwebengine, qtwebview, qtdocgallery, qtactiveqt and qtpim
 # can be marked with the export-ignore attribute
 distfiles="https://void.johnnynator.dev/distfiles/qt5-${version}.tar.gz"
-checksum=251dad114f9506bfb98fd96825ac8065a90a6932e9c847ddb9ce0887f19e7304
+checksum=6bff56434b4c2413ec0c9e57ffdcfed1f0966754d1ccf34dafe31840f4006c5a
 python_version=2 #unverified
 replaces="qt5-doc<5.6.0 qt5-quick1<5.6.0 qt5-quick1-devel<5.6.0 qt5-webkit<5.6.0 qt5-webkit-devel<5.6.0
  qt5-enginio<5.7.1 qt5-enginio-devel<5.7.1 qt5-plugin-gtk<5.7.1 qt5-canvas3d<5.13.0"

From 355211be46c67bbafd1b53bc8d61fe5f082b9df7 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 20/22] vtk: rebuild against double-conversion-3.1.5

---
 srcpkgs/vtk/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/vtk/template b/srcpkgs/vtk/template
index 4c1710087f83..8811247ae7e5 100644
--- a/srcpkgs/vtk/template
+++ b/srcpkgs/vtk/template
@@ -1,7 +1,7 @@
 # Template file for 'vtk'
 pkgname=vtk
 version=9.0.1
-revision=5
+revision=6
 wrksrc=VTK-${version}
 build_style=cmake
 # vtk can be huge, especially with -DVTK_BUILD_ALL_MODULES=ON"

From 433a91cb5ab208ee7d6b346af3129b5c2380352d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 21/22] inkscape: rebuild against double-conversion-3.1.5

---
 srcpkgs/inkscape/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/inkscape/template b/srcpkgs/inkscape/template
index 238426b17f97..f8b76d630bea 100644
--- a/srcpkgs/inkscape/template
+++ b/srcpkgs/inkscape/template
@@ -1,7 +1,7 @@
 # Template file for 'inkscape'
 pkgname=inkscape
 version=1.1
-revision=2
+revision=3
 wrksrc="inkscape-${version}_2021-05-24_c4e8f9ed74"
 build_style=cmake
 # builds executables then runs checks

From 1947f341650d24fa784528ba8e487032a603e9ea Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 22/22] openscad: rebuild against double-conversion-3.1.5

---
 srcpkgs/openscad/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openscad/template b/srcpkgs/openscad/template
index 693931379a26..60d45d60615f 100644
--- a/srcpkgs/openscad/template
+++ b/srcpkgs/openscad/template
@@ -1,7 +1,7 @@
 # Template file for 'openscad'
 pkgname=openscad
 version=2021.01
-revision=1
+revision=2
 build_style=qmake
 hostmakedepends="bison flex pkg-config gettext qt5-qmake qt5-host-tools"
 makedepends="cgal-devel harfbuzz-devel opencsg-devel qscintilla-qt5-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (6 preceding siblings ...)
  2021-10-03 13:14 ` Johnnynator
@ 2021-10-03 13:22 ` Johnnynator
  2021-10-03 13:25 ` [PR PATCH] [Merged]: " Johnnynator
  2021-10-15 23:13 ` vSLG
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-10-03 13:22 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

There is an updated pull request by Johnnynator against master on the void-packages repository

https://github.com/Johnnynator/void-packages qt6.2
https://github.com/void-linux/void-packages/pull/31686

[wip] qt6: update to 6.2 (alpha)
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


A patch file from https://github.com/void-linux/void-packages/pull/31686.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-qt6.2-31686.patch --]
[-- Type: text/x-diff, Size: 35273 bytes --]

From b346720bd9e4855f91429f327dfb4acd5077bf27 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:32 +0200
Subject: [PATCH 01/22] qt6-3d: update to 6.2.0.

---
 srcpkgs/qt6-3d/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-3d/template b/srcpkgs/qt6-3d/template
index dec8bdebf98f..3946df557887 100644
--- a/srcpkgs/qt6-3d/template
+++ b/srcpkgs/qt6-3d/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-3d'
 pkgname=qt6-3d
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qt3d-everywhere-src-${version}"
 build_style=cmake
@@ -13,7 +13,7 @@ maintainer="John <me@johnnynator.dev>"
 license="(LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only) AND GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt3d-everywhere-src-${version}.tar.xz"
-checksum=66e25fcf0bd965374f9814ef8fb960ff7c0414ec9480dcdc57caad17f23ede08
+checksum=304352ae74fc8e7fe50a822413d69094efb25f15a2323e083a2a53dc5a43a6c6
 
 qt6-3d-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From 1a80d787770e59a178c45ae62997fd5a0755517c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:41 +0200
Subject: [PATCH 02/22] qt6-base: update to 6.2.0.

---
 .../qt6-base/patches/musl-usr-path-hack.patch | 25 ++++++++++++++++
 srcpkgs/qt6-base/template                     | 30 ++++++++++++++++---
 srcpkgs/qt6-plugin-networkinformation         |  1 +
 srcpkgs/qt6-plugin-tls-openssl                |  1 +
 srcpkgs/qt6-plugin-tls-qcertonly              |  1 +
 5 files changed, 54 insertions(+), 4 deletions(-)
 create mode 100644 srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
 create mode 120000 srcpkgs/qt6-plugin-networkinformation
 create mode 120000 srcpkgs/qt6-plugin-tls-openssl
 create mode 120000 srcpkgs/qt6-plugin-tls-qcertonly

diff --git a/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
new file mode 100644
index 000000000000..a2ec7550e7bb
--- /dev/null
+++ b/srcpkgs/qt6-base/patches/musl-usr-path-hack.patch
@@ -0,0 +1,25 @@
+Source: @Johnnynator
+Upsteam: No
+Subject: Musl always returns /lib/libQt6Core.so.6 for Dl_info.dli_fname. 
+This also happens sometimes with qtwebengine on glibc.
+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()
+     int result = dladdr(reinterpret_cast<void *>(&QLibraryInfo::isDebugBuild), &info);
+     if (result > 0 && info.dli_fname)
+         prefixPath = prefixFromQtCoreLibraryHelper(QString::fromLocal8Bit(info.dli_fname));
++#if 1
++    QDir preDir(prefixPath);
++    if (preDir.isRoot()) {
++        prefixPath = QStringLiteral("/usr");
++    }
++#endif
+ #elif defined(Q_OS_WIN)
+     HMODULE hModule = getWindowsModuleHandle();
+     const int kBufferSize = 4096;
diff --git a/srcpkgs/qt6-base/template b/srcpkgs/qt6-base/template
index 0b3dd492fb1f..3c7ba930d920 100644
--- a/srcpkgs/qt6-base/template
+++ b/srcpkgs/qt6-base/template
@@ -1,7 +1,7 @@
 # Template file for 'qt6-base'
 pkgname=qt6-base
-version=6.1.1
-revision=2
+version=6.2.0
+revision=1
 wrksrc="qtbase-everywhere-src-${version}"
 build_style=cmake
 configure_args="-DINSTALL_DATADIR=share/qt6
@@ -22,13 +22,14 @@ makedepends="zlib-devel libzstd-devel dbus-devel
  libpng-devel tslib-devel libinput-devel gtk+3-devel
  libmariadbclient-devel postgresql-libs-devel libatomic-devel
  unixodbc-devel cups-devel libproxy-devel brotli-devel
- sqlite-devel Vulkan-Headers mit-krb5-devel vulkan-loader libb2-devel"
+ sqlite-devel Vulkan-Headers mit-krb5-devel vulkan-loader libb2-devel
+ libXevie-devel libXcursor-devel"
 short_desc="Cross-platform application and UI framework (QT6)"
 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=21a8aa9f07170e047270c668c8b037536f40226db7adbc529a0b41c3a3cb3ff2
+checksum=fdfff0716d093bcb6bcd53746ce1d3c9701a6bf3326d47813866d43949b47769
 python_version=3
 
 if [ "$CROSS_BUILD" ]; then
@@ -207,6 +208,27 @@ qt6-plugin-sqlite_package() {
 	}
 }
 
+qt6-plugin-tls-openssl_package() {
+	short_desc+=" - TLS plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/tls/libqopensslbackend.so
+	}
+}
+
+qt6-plugin-tls-qcertonly_package() {
+	short_desc+=" - TLS plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/tls/libqcertonlybackend.so
+	}
+}
+
+qt6-plugin-networkinformation() {
+	short_desc+=" - Networkinformation plugin"
+	pkg_install() {
+		vmove usr/lib/qt6/plugins/networkinformation/libqnetworkmanager.so
+	}
+}
+
 qt6-base-devel_package() {
 	short_desc+=" - Development files"
 	depends="qt6-base>=${version}_${revision}
diff --git a/srcpkgs/qt6-plugin-networkinformation b/srcpkgs/qt6-plugin-networkinformation
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-networkinformation
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file
diff --git a/srcpkgs/qt6-plugin-tls-openssl b/srcpkgs/qt6-plugin-tls-openssl
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-tls-openssl
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file
diff --git a/srcpkgs/qt6-plugin-tls-qcertonly b/srcpkgs/qt6-plugin-tls-qcertonly
new file mode 120000
index 000000000000..8ddee598d5ed
--- /dev/null
+++ b/srcpkgs/qt6-plugin-tls-qcertonly
@@ -0,0 +1 @@
+qt6-base
\ No newline at end of file

From 791bb33b476d78c19134786b849797448958edd6 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:45 +0200
Subject: [PATCH 03/22] qt6-charts: update to 6.2.0.

---
 srcpkgs/qt6-charts/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-charts/template b/srcpkgs/qt6-charts/template
index 1645fe5b4507..88764df95f41 100644
--- a/srcpkgs/qt6-charts/template
+++ b/srcpkgs/qt6-charts/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-charts'
 pkgname=qt6-charts
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtcharts-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtcharts-everywhere-src-${version}.tar.xz"
-checksum=a245b8e1b3edd22c5319d8cf0ee18f95901cfc39e4f94b34b59befffc17af60a
+checksum=9114d4e05e63f5b9d5f07d53d72bf2fbfb22ffae283cc98d3371d73f04b6f4fc
 
 qt6-charts-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"

From e166f4cafebcfa790450156c85fab8e5818aa11d Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:51 +0200
Subject: [PATCH 04/22] qt6-declarative: update to 6.2.0.

---
 common/shlibs                       |  8 ++++----
 srcpkgs/qt6-declarative/template    | 26 ++++++++++++++++++--------
 srcpkgs/qt6-quickcontrols2-devel    |  1 -
 srcpkgs/qt6-quickcontrols2/template | 27 ---------------------------
 srcpkgs/qt6-quickcontrols2/update   |  1 -
 5 files changed, 22 insertions(+), 41 deletions(-)
 delete mode 120000 srcpkgs/qt6-quickcontrols2-devel
 delete mode 100644 srcpkgs/qt6-quickcontrols2/template
 delete mode 100644 srcpkgs/qt6-quickcontrols2/update

diff --git a/common/shlibs b/common/shlibs
index c5e88324a924..44d61909c7b3 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2010,7 +2010,7 @@ libQt6LabsSharedImage.so.6 qt6-declarative-6.1.0_1
 libQt6LabsWavefrontMesh.so.6 qt6-declarative-6.1.0_1
 libQt6QmlLocalStorage.so.6 qt6-declarative-6.1.0_1
 libQt6QmlWorkerScript.so.6 qt6-declarative-6.0.0_1
-libQt6QuickTest.so.6 qt6-declarative-6.0.0_1
+libQt6QuickTest.so.6 qt6-declarative-devel-6.2.0beta4_1
 libQt6QuickShapes.so.6 qt6-declarative-6.0.0_1
 libQt6QuickWidgets.so.6 qt6-declarative-6.0.0_1
 libQt6Quick.so.6 qt6-declarative-6.0.0_1
@@ -2024,9 +2024,9 @@ libQt6Quick3DUtils.so.6 qt6-quick3d-6.0.0_1
 libQt6Quick3DAssetImport.so.6 qt6-quick3d-6.0.0_1
 libQt6Quick3DIblBaker.so.6 qt6-quick3d-6.0.3_1
 libQt6Quick3DParticles.so.6 qt6-quick3d-6.1.0_1
-libQt6QuickControls2Impl.so.6 qt6-quickcontrols2-6.0.0_1
-libQt6QuickControls2.so.6 qt6-quickcontrols2-6.0.0_1
-libQt6QuickTemplates2.so.6 qt6-quickcontrols2-6.0.0_1
+libQt6QuickControls2Impl.so.6 qt6-declarative-6.0.0_1
+libQt6QuickControls2.so.6 qt6-declarative-6.0.0_1
+libQt6QuickTemplates2.so.6 qt6-declarative-6.0.0_1
 libQt6NetworkAuth.so.6 qt6-networkauth-6.1.0rc2_1
 libQt6ScxmlQml.so.6 qt6-scxml-6.1.0rc2_1
 libQt6Scxml.so.6 qt6-scxml-6.1.0rc2_1
diff --git a/srcpkgs/qt6-declarative/template b/srcpkgs/qt6-declarative/template
index a61861576499..40a3d9607a1e 100644
--- a/srcpkgs/qt6-declarative/template
+++ b/srcpkgs/qt6-declarative/template
@@ -1,20 +1,25 @@
 # Template file for 'qt6-declarative'
 pkgname=qt6-declarative
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtdeclarative-everywhere-src-${version}"
 build_style=cmake
-configure_args=" -DQT_HOST_PATH=/usr
- -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+configure_args=" -DQT_HOST_PATH=/usr"
 hostmakedepends="qt6-base-devel perl pkg-config wayland-devel
- qt6-declarative-devel"
+ qt6-shadertools-devel"
 makedepends="qt6-base-devel Vulkan-Headers"
 short_desc="Cross-platform application and UI framework - Declarative"
 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/qtdeclarative-everywhere-src-${version}.tar.xz"
-checksum=805394307479ebca9899996af8357037c4f1ff8b783162ade0c5a05cea7ee2d2
+checksum=46737feceb9e54d63ad0c87a08d33f08ca58f4b8920ccefad8f1ebd64f0d1270
+replaces="qt6-quickcontrols2>=0"
+
+if [ "$CROSS_BUILD" ]; then
+	configure_args+=" -DQT_BUILD_TOOLS_WHEN_CROSSCOMPILING=true"
+	hostmakedepends+=" qt6-declarative-devel"
+fi
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -34,9 +39,10 @@ qt6-declarative-tools_package() {
 	short_desc+=" - tools"
 	pkg_install() {
 		vmove usr/lib/qt6/plugins/qmltooling
-		for bin in qmlcachegen qmleasing qmlformat qmlimportscanner \
-			qmllint qmlplugindump qmlpreview qmlprofiler qmlscene \
-			qmltestrunner qmltime qmltyperegistrar; do
+		for bin in qmlcachegen qmlimportscanner qmltyperegistrar; do
+			vmove usr/lib/qt6/libexec/$bin
+		done
+		for bin in qmlformat qmllint qmlpreview qmlprofiler; do
 			vmove usr/lib/qt6/bin/$bin
 		done
 	}
@@ -46,10 +52,14 @@ qt6-declarative-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1
 	 qt6-declarative-tools>=${version}_${revision}"
 	short_desc+=" - development files"
+	replaces="qt6-quickcontrols2-devel>=0"
 	pkg_install() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
+		vmove "usr/lib/libQt6QuickTest.so.*"
+		vmove usr/lib/qt6/qml/QtTest
+		vmove usr/lib/qt6/bin/qmltestrunner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}
diff --git a/srcpkgs/qt6-quickcontrols2-devel b/srcpkgs/qt6-quickcontrols2-devel
deleted file mode 120000
index 280bc162057d..000000000000
--- a/srcpkgs/qt6-quickcontrols2-devel
+++ /dev/null
@@ -1 +0,0 @@
-qt6-quickcontrols2
\ No newline at end of file
diff --git a/srcpkgs/qt6-quickcontrols2/template b/srcpkgs/qt6-quickcontrols2/template
deleted file mode 100644
index ab57102a19cf..000000000000
--- a/srcpkgs/qt6-quickcontrols2/template
+++ /dev/null
@@ -1,27 +0,0 @@
-# Template file for 'qt6-quickcontrols2'
-pkgname=qt6-quickcontrols2
-version=6.1.1
-revision=1
-wrksrc="qtquickcontrols2-everywhere-src-${version}"
-build_style=cmake
-configure_args="-DQT_HOST_PATH=/usr "
-hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
-makedepends="qt6-base-devel qt6-declarative-devel"
-short_desc="Cross-platform application and UI framework - quickcontrols2"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later, LGPL-3.0-or-later"
-homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquickcontrols2-everywhere-src-${version}.tar.xz"
-checksum=7ebc99724bedd97a2c6a606ba2726feb66bb76eb9f30262ae13cd246f5665ea4
-
-qt6-quickcontrols2-devel_package() {
-	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel"
-	short_desc+=" - development files"
-	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/cmake
-		vmove usr/lib/qt6/mkspecs
-		vmove "usr/lib/*.so"
-		vmove "usr/lib/*.prl"
-	}
-}
diff --git a/srcpkgs/qt6-quickcontrols2/update b/srcpkgs/qt6-quickcontrols2/update
deleted file mode 100644
index 844552465222..000000000000
--- a/srcpkgs/qt6-quickcontrols2/update
+++ /dev/null
@@ -1 +0,0 @@
-pkgname="${pkgname/6-/}-everywhere-src"

From 8672685f1107b8519063ff4fa7ad576f611c9382 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:53 +0200
Subject: [PATCH 05/22] qt6-imageformats: update to 6.2.0.

---
 srcpkgs/qt6-imageformats/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-imageformats/template b/srcpkgs/qt6-imageformats/template
index 45c34a253e53..fe5400ba7287 100644
--- a/srcpkgs/qt6-imageformats/template
+++ b/srcpkgs/qt6-imageformats/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-imageformats'
 pkgname=qt6-imageformats
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtimageformats-everywhere-src-${version}"
 build_style=cmake
@@ -12,4 +12,4 @@ maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtimageformats-everywhere-src-${version}.tar.xz"
-checksum=d7ee9d96ed6958241acde2b5d505f89d7dcfd710d0944b100ac6de203b0e107d
+checksum=fdaa35536c3d0f8f5f313d0d52dedfbf6d8fcd81a82d6a56f473253f135072ad

From 6ee22ac3f90358e2da63b938d14f079c40c2f4c9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:56 +0200
Subject: [PATCH 06/22] qt6-lottie: update to 6.2.0.

---
 srcpkgs/qt6-lottie/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-lottie/template b/srcpkgs/qt6-lottie/template
index 775396bcac64..be9c41bf120c 100644
--- a/srcpkgs/qt6-lottie/template
+++ b/srcpkgs/qt6-lottie/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-lottie'
 pkgname=qt6-lottie
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtlottie-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtlottie-everywhere-src-${version}.tar.xz"
-checksum=df8ee26ea3aa4524f82703f602449d990724ca232cb98498746e8f49e23037ed
+checksum=aa129261d409b5d935221acd6e38f56d68eac5e467a1990c96c654e81a2522ff
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 6a5dcf7c4870c770556634de0b2f55d28e5574d9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:58:58 +0200
Subject: [PATCH 07/22] qt6-networkauth: update to 6.2.0.

---
 srcpkgs/qt6-networkauth/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-networkauth/template b/srcpkgs/qt6-networkauth/template
index 8ffb44cad94a..bb3bc0fae104 100644
--- a/srcpkgs/qt6-networkauth/template
+++ b/srcpkgs/qt6-networkauth/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-networkauth'
 pkgname=qt6-networkauth
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtnetworkauth-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtnetworkauth-everywhere-src-${version}.tar.xz"
-checksum=4e1b7f6584fe21e8a04ee6d9c5761e5858587e8bab01a522ee53f82dfd1efdd7
+checksum=e71504c8d6ae4cf4d573f1d91ff756f90f441e22b0af12eae2424f7e0c01d450
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From be23b9e2fbd0a1682c4602e85b54cd42fc1c2a15 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:02 +0200
Subject: [PATCH 08/22] qt6-qt5compat: update to 6.2.0.

---
 srcpkgs/qt6-qt5compat/template | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/srcpkgs/qt6-qt5compat/template b/srcpkgs/qt6-qt5compat/template
index 06837849b3f1..fd3b0d42bc7e 100644
--- a/srcpkgs/qt6-qt5compat/template
+++ b/srcpkgs/qt6-qt5compat/template
@@ -1,18 +1,18 @@
 # Template file for 'qt6-qt5compat'
 pkgname=qt6-qt5compat
-version=6.1.1
-revision=2
+version=6.2.0
+revision=1
 wrksrc="qt5compat-everywhere-src-${version}"
 build_style=cmake
-configure_args="-DQT_HOST_PATH=/usr "
-hostmakedepends="qt6-base-devel perl"
-makedepends="qt6-base-devel"
+configure_args="-DQT_HOST_PATH=/usr"
+hostmakedepends="qt6-base-devel qt6-declarative-devel perl pkg-config"
+makedepends="qt6-base-devel qt6-declarative-devel"
 short_desc="Cross-platform application and UI framework - Qt5 Compatibilty Component"
 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://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qt5compat-everywhere-src-${version}.tar.xz"
-checksum=7d08f1044cb09f8b3ee31af0de25771bae72936a6f9a699134d9b8d29dfaa5a7
+checksum=c2e2f058ecee36a96c1b15937badeda9b7b03eb5278fa01af4ff386c4f1854fb
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 13711e7ece44a513d20f58a5cc92652d818b3c16 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:12 +0200
Subject: [PATCH 09/22] qt6-quick3d: update to 6.2.0.

---
 srcpkgs/qt6-quick3d/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-quick3d/template b/srcpkgs/qt6-quick3d/template
index d75bd8c086ca..1ef03c32b1cf 100644
--- a/srcpkgs/qt6-quick3d/template
+++ b/srcpkgs/qt6-quick3d/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-quick3d'
 pkgname=qt6-quick3d
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtquick3d-everywhere-src-${version}"
 build_style=cmake
@@ -13,7 +13,7 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquick3d-everywhere-src-${version}.tar.xz"
-checksum=94b45ae9d08495d701cfb586f1f85b12a1a10f8c29865de0d427a2366ae4507c
+checksum=e8f8163237468e158ace7737d60a0a722209ffda444c57c786fc53db1af851e1
 
 if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
 	# possibly a qt6-shadertools bug, actually

From e81e94f84f4953515901a7edc9c6dc2cfafb26b3 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:18 +0200
Subject: [PATCH 10/22] qt6-quicktimeline: update to 6.2.0.

---
 srcpkgs/qt6-quicktimeline/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/qt6-quicktimeline/template b/srcpkgs/qt6-quicktimeline/template
index e9c02e2440c2..4c0912d93347 100644
--- a/srcpkgs/qt6-quicktimeline/template
+++ b/srcpkgs/qt6-quicktimeline/template
@@ -1,8 +1,8 @@
 # Template file for 'qt6-quicktimeline'
 pkgname=qt6-quicktimeline
-version=6.1.1
+version=6.2.0
 revision=1
-wrksrc="qtquicktimeline-everywhere-src-${version}"
+wrksrc="qtquicktimeline-everywhere-src-${version/rc/-rc}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr "
 hostmakedepends="perl qt6-base-devel qt6-declarative-devel"
@@ -11,8 +11,8 @@ short_desc="Cross-platform application and UI framework - quicktimeline"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
-distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtquicktimeline-everywhere-src-${version}.tar.xz"
-checksum=40fb664eadf295001d2c49c333032406b6f45f14acddee7e72b8d6c5ea26a6a2
+distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version/rc/-rc}/submodules/qtquicktimeline-everywhere-src-${version/rc/-rc}.tar.xz"
+checksum=67d644ad12df94e937bac3a1cb8a81a96213ec0102759a86c59ba7834ac90c8c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From c31475ce8d5ec68ad7add51227e17ed19d3ae285 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:21 +0200
Subject: [PATCH 11/22] qt6-scxml: update to 6.2.0.

---
 srcpkgs/qt6-scxml/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-scxml/template b/srcpkgs/qt6-scxml/template
index e3a594de99e3..36bc0fc689b2 100644
--- a/srcpkgs/qt6-scxml/template
+++ b/srcpkgs/qt6-scxml/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-scxml'
 pkgname=qt6-scxml
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtscxml-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ maintainer="John <me@johnnynator.dev>"
 license="LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtscxml-everywhere-src-${version}.tar.xz"
-checksum=ffeb650458bb60bb076ac3460588f77f7c841b4f4b1de706960b9b34984dc528
+checksum=90d4af011a17f04a003cbd453c7e0720787e6cdacb8dfce7167179c2cd7dc839
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From c4cfa9788f4091df783d9fb276ece8ffc02c6a0e Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:23 +0200
Subject: [PATCH 12/22] qt6-shadertools: update to 6.2.0.

---
 srcpkgs/qt6-shadertools/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-shadertools/template b/srcpkgs/qt6-shadertools/template
index 9b55463602b7..9fc700d72927 100644
--- a/srcpkgs/qt6-shadertools/template
+++ b/srcpkgs/qt6-shadertools/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-shadertools'
 pkgname=qt6-shadertools
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtshadertools-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-or-later"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtshadertools-everywhere-src-${version}.tar.xz"
-checksum=324a9f6f87d4e82c0b5f80e6301c7dbc47617dbe752f3e3726c141bd85855512
+checksum=5f66d43610a3a6739fc360d836a2c045135107c0ecd40eb3ed18ce5f3dd79c42
 
 qt6-shadertools-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision} qt6-base-devel>=${version}_1"

From 37909efe4cc3a47ec751f05a520c9689b89e92f9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:26 +0200
Subject: [PATCH 13/22] qt6-svg: update to 6.2.0.

---
 srcpkgs/qt6-svg/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-svg/template b/srcpkgs/qt6-svg/template
index 9042cc483ff9..81a0c5ad25c0 100644
--- a/srcpkgs/qt6-svg/template
+++ b/srcpkgs/qt6-svg/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-svg'
 pkgname=qt6-svg
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtsvg-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0, GPL-2.0-or-later, LGPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtsvg-everywhere-src-${version}.tar.xz"
-checksum=e2f62385c940de76dea480a2615c9b11dd2bf0cec2cc778096c0bebfa1ef15ec
+checksum=af9eabefbb0dcb772f18fae4d2c39bcc23579a5dfff569c35ea7e497591db3d4
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 5a6b1f819d1f90208a54b04fa0433daf711d3098 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:30 +0200
Subject: [PATCH 14/22] qt6-tools: update to 6.2.0.

---
 srcpkgs/qt6-tools/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-tools/template b/srcpkgs/qt6-tools/template
index 16b20c72d05a..576a7aef7449 100644
--- a/srcpkgs/qt6-tools/template
+++ b/srcpkgs/qt6-tools/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-tools'
 pkgname=qt6-tools
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qttools-everywhere-src-${version}"
 build_style=cmake
@@ -12,7 +12,7 @@ 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://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttools-everywhere-src-${version}.tar.xz"
-checksum=cba8d9a836e83b7a5e6d068239635b261f7ca4a059992b2b66cd546380091273
+checksum=a903d005f8ab39545aed88a13b04f13ddbbe073da7007203a91fb8b42b890057
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 9f3b61dc8f8479a4a33e7f4983313e54ae9835bd Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:32 +0200
Subject: [PATCH 15/22] qt6-translations: update to 6.2.0.

---
 srcpkgs/qt6-translations/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt6-translations/template b/srcpkgs/qt6-translations/template
index 088d21f4bdc8..19d44548bc8f 100644
--- a/srcpkgs/qt6-translations/template
+++ b/srcpkgs/qt6-translations/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-translations'
 pkgname=qt6-translations
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qttranslations-everywhere-src-${version}"
 build_style=cmake
@@ -12,4 +12,4 @@ maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only with Qt-GPL-exception-1.0"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qttranslations-everywhere-src-${version}.tar.xz"
-checksum=6cf3d191335a6b3a64864e7ba41819e7be461d1d2861d643babe836f81d4c393
+checksum=5b4ecb1ee35363444f03b1eb10637d79af1d19be5a5cc53657dc0925a78b2240

From 07387cafe5bd3a011f16ec1b56551c03de96c213 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:35 +0200
Subject: [PATCH 16/22] qt6-virtualkeyboard: update to 6.2.0.

---
 srcpkgs/qt6-virtualkeyboard/template | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/srcpkgs/qt6-virtualkeyboard/template b/srcpkgs/qt6-virtualkeyboard/template
index 07c4a4475f2e..f5188228e6bd 100644
--- a/srcpkgs/qt6-virtualkeyboard/template
+++ b/srcpkgs/qt6-virtualkeyboard/template
@@ -1,20 +1,18 @@
 # Template file for 'qt6-virtualkeyboard'
 pkgname=qt6-virtualkeyboard
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtvirtualkeyboard-everywhere-src-${version}"
 build_style=cmake
 configure_args="-DQT_HOST_PATH=/usr"
 hostmakedepends="perl pkg-config qt6-declarative-devel"
-makedepends="qt6-declarative-devel qt6-quickcontrols2-devel
- qt6-svg-devel hunspell-devel"
-depends="qt6-quickcontrols2"
+makedepends="qt6-declarative-devel qt6-svg-devel hunspell-devel"
 short_desc="Cross-platform application and UI framework - virtualkeyboard"
 maintainer="John <me@johnnynator.dev>"
 license="GPL-3.0-only"
 homepage="https://qt.io/"
 distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtvirtualkeyboard-everywhere-src-${version}.tar.xz"
-checksum=246d1acdcd953819b09b1da22bd359335d145d8a3550d9e827dc1fd27b6bd3ff
+checksum=1055e7fe1dfaecbfd4b69f40ec1135fda1980e6e21adbe757a8a4affbfb9bcee
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"

From 35b7db1fe2dc4232407bbf96c722f9505bf1c927 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Thu, 24 Jun 2021 20:59:37 +0200
Subject: [PATCH 17/22] qt6-wayland: update to 6.2.0.

---
 srcpkgs/qt6-wayland/template | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/qt6-wayland/template b/srcpkgs/qt6-wayland/template
index fff2a9b1e8e4..06b2cbbaa08c 100644
--- a/srcpkgs/qt6-wayland/template
+++ b/srcpkgs/qt6-wayland/template
@@ -1,6 +1,6 @@
 # Template file for 'qt6-wayland'
 pkgname=qt6-wayland
-version=6.1.1
+version=6.2.0
 revision=1
 wrksrc="qtwayland-everywhere-src-${version}"
 build_style=cmake
@@ -15,7 +15,7 @@ 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/qtwayland-everywhere-src-${version}.tar.xz"
-checksum=2cfb2b5403eb2037670549dd2d3968eaa30a9ce523dd08314c5bc677fdf27db6
+checksum=d6787fce74bde1a3386bcbe43c078c712471bab09f1946c40fc2327232d27d4c
 
 if [ "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DQT_BUILD_TESTS=ON"
@@ -33,7 +33,7 @@ qt6-wayland-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/qt6/mkspecs
-		vmove usr/lib/qt6/bin/qtwaylandscanner
+		vmove usr/lib/qt6/libexec/qtwaylandscanner
 		vmove "usr/lib/*.so"
 		vmove "usr/lib/*.prl"
 	}

From b52200d6b013a351089555e10b04e259e4d6dfe1 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 18:59:44 +0200
Subject: [PATCH 18/22] double-conversion: update to 3.1.5.

---
 common/shlibs                      |  2 +-
 srcpkgs/double-conversion/template | 14 +++++++-------
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 44d61909c7b3..7e5289f58f66 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2980,7 +2980,7 @@ libnss_libvirt_guest.so.2 libvirt-3.1.0_1
 libvirt-admin.so.0 libvirt-3.1.0_1
 libnss_libvirt.so.2 libvirt-3.1.0_1
 libassimp.so.5 libassimp-5.0.0_1
-libdouble-conversion.so.1 double-conversion-2.0.1_1
+libdouble-conversion.so.3 double-conversion-3.1.5_1
 libspectrum.so.8 libspectrum-1.2.2_1
 libbearssl.so.0 bearssl-0.3_1
 libXfont2.so.2 libXfont2-2.0.1_1
diff --git a/srcpkgs/double-conversion/template b/srcpkgs/double-conversion/template
index e67aa3b7d01a..fa03b83c3a81 100644
--- a/srcpkgs/double-conversion/template
+++ b/srcpkgs/double-conversion/template
@@ -1,15 +1,16 @@
 # Template file for 'double-conversion'
 pkgname=double-conversion
-version=3.1.1
+version=3.1.5
 revision=1
-build_style=scons
+build_style=cmake
+configure_args="-DBUILD_SHARED_LIBS=ON -DBUILD_TESTING=ON"
 short_desc="Efficient binary-decimal and decimal-binary routines for IEEE doubles"
 maintainer="Diogo Leal <diogo@diogoleal.com>"
 license="BSD-3-Clause"
 homepage="https://github.com/google/double-conversion"
 changelog="https://raw.githubusercontent.com/google/double-conversion/master/Changelog"
 distfiles="https://github.com/google/double-conversion/archive/v${version}.tar.gz"
-checksum=c49a6b3fa9c917f827b156c8e0799ece88ae50440487a99fc2f284cfd357a5b9
+checksum=a63ecb93182134ba4293fd5f22d6e08ca417caafa244afaa751cbfddf6415b13
 
 post_install() {
 	vlicense LICENSE
@@ -19,9 +20,8 @@ double-conversion-devel_package() {
 	short_desc+=" - development files"
 	depends="${sourcepkg}>=${version}_${revision}"
 	pkg_install() {
-		vmkdir usr/include/double-conversion
-		vcopy double-conversion/*.h usr/include/double-conversion/
-		vmove usr/lib/*.a
-		vmove usr/lib/*.so
+		vmove usr/include
+		vmove usr/lib/cmake
+		vmove "usr/lib/*.so"
 	}
 }

From 443d95d3aede3664f5f778e593b5828d2195ef82 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 19/22] qt5: update to 5.15.3+20211001.

---
 srcpkgs/qt5/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 790ccc808d9e..c1d822ef021d 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,6 +1,6 @@
 # Template file for 'qt5'
 pkgname=qt5
-version=5.15.3+20210924
+version=5.15.3+20211001
 # commit fcca82ca40a5d8a02a4ddd90846d070f2c58cfad
 # base repo: https://invent.kde.org/qt/qt/qt5
 revision=1
@@ -27,7 +27,7 @@ homepage="https://qt.io/"
 # to keep the size smaller qtwebengine, qtwebview, qtdocgallery, qtactiveqt and qtpim
 # can be marked with the export-ignore attribute
 distfiles="https://void.johnnynator.dev/distfiles/qt5-${version}.tar.gz"
-checksum=251dad114f9506bfb98fd96825ac8065a90a6932e9c847ddb9ce0887f19e7304
+checksum=6bff56434b4c2413ec0c9e57ffdcfed1f0966754d1ccf34dafe31840f4006c5a
 python_version=2 #unverified
 replaces="qt5-doc<5.6.0 qt5-quick1<5.6.0 qt5-quick1-devel<5.6.0 qt5-webkit<5.6.0 qt5-webkit-devel<5.6.0
  qt5-enginio<5.7.1 qt5-enginio-devel<5.7.1 qt5-plugin-gtk<5.7.1 qt5-canvas3d<5.13.0"

From 02921022e176dfb62cebdce1c73a91fb5747d858 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 20/22] vtk: rebuild against double-conversion-3.1.5

---
 srcpkgs/vtk/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/vtk/template b/srcpkgs/vtk/template
index 4c1710087f83..8811247ae7e5 100644
--- a/srcpkgs/vtk/template
+++ b/srcpkgs/vtk/template
@@ -1,7 +1,7 @@
 # Template file for 'vtk'
 pkgname=vtk
 version=9.0.1
-revision=5
+revision=6
 wrksrc=VTK-${version}
 build_style=cmake
 # vtk can be huge, especially with -DVTK_BUILD_ALL_MODULES=ON"

From 4c9bf1ff877ed76e0c2da025418e1e6cf3e42dfc Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 21/22] inkscape: rebuild against double-conversion-3.1.5

---
 srcpkgs/inkscape/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/inkscape/template b/srcpkgs/inkscape/template
index 238426b17f97..f8b76d630bea 100644
--- a/srcpkgs/inkscape/template
+++ b/srcpkgs/inkscape/template
@@ -1,7 +1,7 @@
 # Template file for 'inkscape'
 pkgname=inkscape
 version=1.1
-revision=2
+revision=3
 wrksrc="inkscape-${version}_2021-05-24_c4e8f9ed74"
 build_style=cmake
 # builds executables then runs checks

From e2b99255e9001dbe00ebfe8da9718f2280cc6e83 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Sat, 2 Oct 2021 19:10:49 +0200
Subject: [PATCH 22/22] openscad: rebuild against double-conversion-3.1.5

---
 srcpkgs/openscad/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openscad/template b/srcpkgs/openscad/template
index 693931379a26..60d45d60615f 100644
--- a/srcpkgs/openscad/template
+++ b/srcpkgs/openscad/template
@@ -1,7 +1,7 @@
 # Template file for 'openscad'
 pkgname=openscad
 version=2021.01
-revision=1
+revision=2
 build_style=qmake
 hostmakedepends="bison flex pkg-config gettext qt5-qmake qt5-host-tools"
 makedepends="cgal-devel harfbuzz-devel opencsg-devel qscintilla-qt5-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Merged]: [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (7 preceding siblings ...)
  2021-10-03 13:22 ` Johnnynator
@ 2021-10-03 13:25 ` Johnnynator
  2021-10-15 23:13 ` vSLG
  9 siblings, 0 replies; 11+ messages in thread
From: Johnnynator @ 2021-10-03 13:25 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2355 bytes --]

There's a merged pull request on the void-packages repository

[wip] qt6: update to 6.2 (alpha)
https://github.com/void-linux/void-packages/pull/31686

Description:
- qt6-3d: update to 6.2.0alpha.
- qt6-base: update to 6.2.0alpha.
- qt6-charts: update to 6.2.0alpha.
- qt6-declarative: update to 6.2.0alpha.
- qt6-imageformats: update to 6.2.0alpha.
- qt6-lottie: update to 6.2.0alpha.
- qt6-networkauth: update to 6.2.0alpha.
- qt6-qt5compat: update to 6.2.0alpha.
- qt6-quick3d: update to 6.2.0alpha.
- qt6-quickcontrols2: update to 6.2.0alpha.
- qt6-quicktimeline: update to 6.2.0alpha.
- qt6-scxml: update to 6.2.0alpha.
- qt6-shadertools: update to 6.2.0alpha.
- qt6-svg: update to 6.2.0alpha.
- qt6-tools: update to 6.2.0alpha.
- qt6-translations: update to 6.2.0alpha.
- qt6-virtualkeyboard: update to 6.2.0alpha.
- qt6-wayland: update to 6.2.0alpha.
- New package: qt6-serialport-6.2.0alpha
- New package: qt6-websockets-6.2.0alpha
- New package: qt6-webchannel-6.2.0alpha
- New package: qt6-multimedia-6.2.0alpha
- New package: qt6-webengine-6.2.0alpha
- New package: qt6-location-6.2.0alpha

<!-- Mark items with [x] where applicable -->

#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
--> 
#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (ARCH-LIBC)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [x] aarch64-musl
  - [x] armv7l
  - [x] armv6l-musl
[ci skip]


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [wip] qt6: update to 6.2 (alpha)
  2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
                   ` (8 preceding siblings ...)
  2021-10-03 13:25 ` [PR PATCH] [Merged]: " Johnnynator
@ 2021-10-15 23:13 ` vSLG
  9 siblings, 0 replies; 11+ messages in thread
From: vSLG @ 2021-10-15 23:13 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 198 bytes --]

New comment by vSLG on void-packages repository

https://github.com/void-linux/void-packages/pull/31686#issuecomment-944800366

Comment:
Is `qt6-websockets` to be found anywhere? I can't find it...

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-10-15 23:14 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-27 19:18 [PR PATCH] [wip] qt6: update to 6.2 (alpha) Johnnynator
2021-06-27 19:20 ` [PR PATCH] [Updated] " Johnnynator
2021-06-27 19:37 ` Johnnynator
2021-06-27 19:38 ` Johnnynator
2021-06-27 20:17 ` [PR REVIEW] " ericonr
2021-06-27 20:29 ` Johnnynator
2021-09-12 14:47 ` [PR PATCH] [Updated] " Johnnynator
2021-10-03 13:14 ` Johnnynator
2021-10-03 13:22 ` Johnnynator
2021-10-03 13:25 ` [PR PATCH] [Merged]: " Johnnynator
2021-10-15 23:13 ` vSLG

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).