aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBart Ribbers <bribbers@disroot.org>2021-10-09 13:53:12 +0200
committerBart Ribbers <bribbers@disroot.org>2021-10-10 18:52:24 +0200
commit574376b5c07c5c9b3bb2ed2c105d92cc016090a7 (patch)
treebca6523a4af8b93a08a8ee077756e099222905df
parent0cbff517cf7fd1b975fd9dd55891aaee2ec83e1f (diff)
community/qt5-qtwebengine: update removal of glibc check patch
There seems to have been added some more checks for glibc upstream, meaning QtWebengineCore wasn't being built...
-rw-r--r--community/qt5-qtwebengine/APKBUILD7
-rw-r--r--community/qt5-qtwebengine/fix-chromium-build.patch79
-rw-r--r--community/qt5-qtwebengine/remove-glibc-check.patch73
3 files changed, 150 insertions, 9 deletions
diff --git a/community/qt5-qtwebengine/APKBUILD b/community/qt5-qtwebengine/APKBUILD
index 1281b79d4ea..65471871237 100644
--- a/community/qt5-qtwebengine/APKBUILD
+++ b/community/qt5-qtwebengine/APKBUILD
@@ -3,7 +3,7 @@
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=qt5-qtwebengine
pkgver=5.15.3_git20211006
-pkgrel=0
+pkgrel=1
# latest commit of 5.15 branch at pkgver date
_commit="b99b6ed65f66b4630bdc2b407a97bd0e526165d3"
# latest commit of 87-based branch of qtwebengine-chromium
@@ -24,6 +24,7 @@ depends_dev="
libxcomposite-dev
libxext-dev
libxkbcommon-dev
+ libxkbfile-dev
libxrender-dev
libxslt-dev
mesa-dev
@@ -93,6 +94,7 @@ source="$pkgname-$pkgver.tar.gz::https://invent.kde.org/qt/qt/qtwebengine/-/arch
remove-glibc-check.patch
chromium-harfbuzz-3.0.0.patch
skia-harfbuzz-3.0.0.patch
+ fix-chromium-build.patch
"
builddir="$srcdir/qtwebengine-$_commit"
@@ -265,7 +267,8 @@ ac563e0c444a6d3214ff7465cad2c701692cfa90408c57243d3ae9459937c36e88acd57335bb90da
b5e117f94811c4c65cfd99885b0f23e82cabf25529b2a867f8dec5efdbcef98441d32b5b89e96c9681fed6fb99ccf3850b2a32dd618be957ef9bdcd5f2b6a7e4 qt-musl-stackstart.patch
1b9abcd43238491cca641f4dca36ca27b97f4dba9b54ba0f25e7e5c777d590717838ae6cab4cd8fcce35e994215432c456d376f9239836cff3f9df38d6994a76 qt-musl-sysreg-for__WORDSIZE.patch
f565a31b007db408ef96db3f7d003f465d1db765fb84b50a1f82b449d49949dd4fafa2b374889621a5c431c1d6e758797dfce76e34199282aa2fbe03bbf5aa38 qt-musl-thread-stacksize.patch
-d4c3187d0fc60cbb602123007daf44af1c3a06cc847894a66dad753c48f7a5940e5414219ffcb8bbabe3c545cc974a8ab04f602c0229b78b38e513e48ec37a43 remove-glibc-check.patch
+0ef2adce746a0ee121f04aab8ad9e2e338f996286d045a2bffb20e57c37e9432f22cd0b574fbe06f19b928749c35f3d51d9b3a49967b51e89c3440240f110c35 remove-glibc-check.patch
820a1ef85b82bb4b2107e20680da82503f616923eb4799405ba805248344e38d745938838f50288facf6ed5f4f5eeead63fe7a3c04543d26c396649262488cc7 chromium-harfbuzz-3.0.0.patch
e29705c8ba1503d7010ef6b9a39c6772bc14fa387024b1227f1300dd14ec39f8100106ace0f71bb07032af18d15e97f5108fb6686c537bb4d21f31ff2e64cc1a skia-harfbuzz-3.0.0.patch
+f40f42a33e8d8c9a4129a2e40f3177d1ffc4d1fc28ceda7b8ffab9c8d14cdcca8d0e804c55257a2932e772f89fcf6e7401fe3398a70a045835add6d9c1ba7bb3 fix-chromium-build.patch
"
diff --git a/community/qt5-qtwebengine/fix-chromium-build.patch b/community/qt5-qtwebengine/fix-chromium-build.patch
new file mode 100644
index 00000000000..8b262387204
--- /dev/null
+++ b/community/qt5-qtwebengine/fix-chromium-build.patch
@@ -0,0 +1,79 @@
+diff --git a/src/3rdparty/chromium/v8/src/compiler/backend/arm64/code-generator-arm64.cc b/src/3rdparty/chromium/v8/src/compiler/backend/arm64/code-generator-arm64.cc
+index 1c02aa69a..69e5e58de 100644
+--- a/src/3rdparty/chromium/v8/src/compiler/backend/arm64/code-generator-arm64.cc
++++ b/src/3rdparty/chromium/v8/src/compiler/backend/arm64/code-generator-arm64.cc
+@@ -375,6 +375,74 @@ Condition FlagsConditionToCondition(FlagsCondition condition) {
+ UNREACHABLE();
+ }
+
++class WasmOutOfLineTrap : public OutOfLineCode {
++ public:
++ WasmOutOfLineTrap(CodeGenerator* gen, Instruction* instr)
++ : OutOfLineCode(gen), gen_(gen), instr_(instr) {}
++ void Generate() override {
++ Arm64OperandConverter i(gen_, instr_);
++ TrapId trap_id =
++ static_cast<TrapId>(i.InputInt32(instr_->InputCount() - 1));
++ GenerateCallToTrap(trap_id);
++ }
++
++ protected:
++ CodeGenerator* gen_;
++
++ void GenerateWithTrapId(TrapId trap_id) { GenerateCallToTrap(trap_id); }
++
++ private:
++ void GenerateCallToTrap(TrapId trap_id) {
++ if (trap_id == TrapId::kInvalid) {
++ // We cannot test calls to the runtime in cctest/test-run-wasm.
++ // Therefore we emit a call to C here instead of a call to the runtime.
++ __ CallCFunction(ExternalReference::wasm_call_trap_callback_for_testing(),
++ 0);
++ __ LeaveFrame(StackFrame::WASM);
++ auto call_descriptor = gen_->linkage()->GetIncomingDescriptor();
++ int pop_count = static_cast<int>(call_descriptor->StackParameterCount());
++ pop_count += (pop_count & 1); // align
++ __ Drop(pop_count);
++ __ Ret();
++ } else {
++ gen_->AssembleSourcePosition(instr_);
++ // A direct call to a wasm runtime stub defined in this module.
++ // Just encode the stub index. This will be patched when the code
++ // is added to the native module and copied into wasm code space.
++ __ Call(static_cast<Address>(trap_id), RelocInfo::WASM_STUB_CALL);
++ ReferenceMap* reference_map =
++ gen_->zone()->New<ReferenceMap>(gen_->zone());
++ gen_->RecordSafepoint(reference_map, Safepoint::kNoLazyDeopt);
++ __ AssertUnreachable(AbortReason::kUnexpectedReturnFromWasmTrap);
++ }
++ }
++
++ Instruction* instr_;
++};
++
++class WasmProtectedInstructionTrap final : public WasmOutOfLineTrap {
++ public:
++ WasmProtectedInstructionTrap(CodeGenerator* gen, int pc, Instruction* instr)
++ : WasmOutOfLineTrap(gen, instr), pc_(pc) {}
++
++ void Generate() override {
++ gen_->AddProtectedInstructionLanding(pc_, __ pc_offset());
++ GenerateWithTrapId(TrapId::kTrapMemOutOfBounds);
++ }
++
++ private:
++ int pc_;
++};
++
++void EmitOOLTrapIfNeeded(Zone* zone, CodeGenerator* codegen,
++ InstructionCode opcode, Instruction* instr, int pc) {
++ const MemoryAccessMode access_mode =
++ static_cast<MemoryAccessMode>(MiscField::decode(opcode));
++ if (access_mode == kMemoryAccessProtected) {
++ zone->New<WasmProtectedInstructionTrap>(codegen, pc, instr);
++ }
++}
++
+ void EmitWordLoadPoisoningIfNeeded(CodeGenerator* codegen,
+ InstructionCode opcode, Instruction* instr,
+ Arm64OperandConverter const& i) {
diff --git a/community/qt5-qtwebengine/remove-glibc-check.patch b/community/qt5-qtwebengine/remove-glibc-check.patch
index 287987298c1..1d94b6b9af1 100644
--- a/community/qt5-qtwebengine/remove-glibc-check.patch
+++ b/community/qt5-qtwebengine/remove-glibc-check.patch
@@ -1,19 +1,78 @@
Qt checks if glibc is available and if not disables large part of Qt5WebEngine and thus cripples functionality.
However these parts work fine with Musl so there is no need to disable them.
-Just remove the check so it builds again. Since 5.15.1 is the last version of Qt to be released with this build system it'll be obsolete with Qt6 and there is no real point in fixing this upstream.
+Just remove the check so it builds again. Since 5.15.1 is the last version of Qt to be released with this build system it'll be obsolete with Qt6 and there is no real point in fixing this upstream.
+
+diff --git a/src/buildtools/config/support.pri b/src/buildtools/config/support.pri
+index e7f869a1..de18523d 100644
+--- a/src/buildtools/config/support.pri
++++ b/src/buildtools/config/support.pri
+@@ -189,15 +189,6 @@ defineTest(qtwebengine_checkForHostPkgCfg) {
+ return(true)
+ }
+
+-defineTest(qtwebengine_checkForGlibc) {
+- module = $$1
+- !qtConfig(webengine-system-glibc) {
+- qtwebengine_skipBuild("A suitable version >= 2.27 of libc required to build $${module} could not be found.")
+- return(false)
+- }
+- return(true)
+-}
+-
+ defineTest(qtwebengine_checkForKhronos) {
+ module = $$1
+ !qtConfig(webengine-system-khr) {
diff --git a/src/buildtools/configure.json b/src/buildtools/configure.json
-index 1ca6214a..3783c223 100644
+index 88d1790c..8623f6d7 100644
--- a/src/buildtools/configure.json
+++ b/src/buildtools/configure.json
-@@ -378,8 +378,7 @@
- && features.webengine-nodejs
+@@ -264,18 +264,6 @@
+ "label": "system gn",
+ "type": "detectGn"
+ },
+- "webengine-glibc": {
+- "label": "glibc > 2.16",
+- "type": "compile",
+- "test": {
+- "include": "features.h",
+- "tail": [
+- "#if __GLIBC__ < 2 || __GLIBC_MINOR__ < 17",
+- "#error glibc versions below 2.17 are not supported",
+- "#endif"
+- ]
+- }
+- },
+ "webengine-gperf": {
+ "label": "gperf",
+ "type": "detectGperf"
+@@ -379,7 +367,6 @@
&& (!config.sanitizer || features.webengine-sanitizer)
&& (!config.linux || features.pkg-config)
-- && (!config.linux || features.webengine-host-pkg-config)
+ && (!config.linux || features.webengine-host-pkg-config)
- && (!config.linux || features.webengine-system-glibc)
-+ && (!config.linux || features.webengine-host-pkg-config)
&& (!config.linux || features.webengine-system-khr)
&& (!config.linux || features.webengine-system-nss)
&& (!config.linux || features.webengine-system-dbus)
-
+@@ -517,11 +504,6 @@
+ "condition": "config.unix && !config.darwin && libs.webengine-nss",
+ "output": [ "privateFeature" ]
+ },
+- "webengine-system-glibc": {
+- "label": "glibc",
+- "condition": "config.linux && tests.webengine-glibc",
+- "output": [ "privateFeature" ]
+- },
+ "webengine-system-x11" : {
+ "label": "x11",
+ "condition": "config.unix && libs.webengine-x11",
+@@ -782,8 +764,7 @@
+ "webengine-system-fontconfig",
+ "webengine-system-dbus",
+ "webengine-system-nss",
+- "webengine-system-khr",
+- "webengine-system-glibc"
++ "webengine-system-khr"
+ ]
+ },
+ {