Skip to contentSkip to conversation

webkitgtk: fix compiling for 32-bit Arm

PATCH In review Gyorgy Sarvari 2 participants 2 messages Aug 9, 2025

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 webkitgtk: fix compiling for 32-bit Arm

When compiling for 32-bit Arm target, the compilation fails with the following error:

| .../webkitgtk/2.48.5/sources/webkitgtk-2.48.5/Source/JavaScriptCore/offlineasm/ast.rb:1004:in 'Instruction#lowerDefault': Unhandled opcode addq at WebAssembly.asm:739 (due to WebAssembly.asm:739) (LoweringError)

Add backported patch to fix this error.

---
 .../webkitgtk/fix-armv7-compilation.patch     | 32 +++++++++++++++++++
 meta/recipes-sato/webkit/webkitgtk_2.48.5.bb  |  1 +
 2 files changed, 33 insertions(+)
 create mode 100644 meta/recipes-sato/webkit/webkitgtk/fix-armv7-compilation.patch
meta/recipes-sato/webkit/webkitgtk/fix-armv7-compilation.patch new file +32 -0
new file mode 100644
index 0000000000..a857d55ae4
@@ -0,0 +1,32 @@
+From 7999ecd5ee4ea3123f7e75634d2bc57f57ca7070 Mon Sep 17 00:00:00 2001
+From: Justin Michaud <[email protected]>
+Date: Wed, 6 Aug 2025 21:14:26 +0300
+Subject: [PATCH] REGRESSION(2.48.5): [WPE][GTK] Does not compile on ARMv7
+ https://bugs.webkit.org/show_bug.cgi?id=296921
+
+Unreviewed build fix.
+
+* Source/JavaScriptCore/llint/WebAssembly.asm: Replace addq with addp
+  for sp on armv7
+
+Canonical link: https://commits.webkit.org/290945.344@webkitglib/2.48
+
+Upstream-Status: Backport [https://github.com/WebKit/WebKit/commit/7999ecd5ee4ea3123f7e75634d2bc57f57ca7070]
+Signed-off-by: Gyorgy Sarvari <[email protected]>
+---
+ Source/JavaScriptCore/llint/WebAssembly.asm | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Source/JavaScriptCore/llint/WebAssembly.asm b/Source/JavaScriptCore/llint/WebAssembly.asm
+index 1ac3e2accf3c..bd9041404eb1 100644
+--- a/Source/JavaScriptCore/llint/WebAssembly.asm
++++ b/Source/JavaScriptCore/llint/WebAssembly.asm
+@@ -736,7 +736,7 @@ if JSVALUE64
+     storep memoryBase, Callee[cfr]
+ else
+     loadp [sp], ws0
+-    addq 2 * SlotSize, sp
++    addp 2 * SlotSize, sp
+     storep ws0, Callee[cfr]
+ end
+ 
meta/recipes-sato/webkit/webkitgtk_2.48.5.bb +1 -0
index 947996450d..35b8ee2a90 100644
@@ -18,6 +18,7 @@ SRC_URI = "https://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \
            file://sys_futex.patch \
            file://0001-Fix-build-errors-on-RISCV-https-bugs.webkit.org-show.patch \
            file://fix-ftbfs-riscv64.patch \
+           file://fix-armv7-compilation.patch \
            "
 SRC_URI[sha256sum] = "bb64ed9d1cfd58e8b5e89ccad71dd31adfed56336bad7695031ad0b668e1987c"
 
#1 lore raw

Thanks for chasing it down. This addresses the root cause.

Quoted 74 lines · Gyorgy Sarvari via lists.openembedded.org

When compiling for 32-bit Arm target, the compilation fails with the following error:

| .../webkitgtk/2.48.5/sources/webkitgtk-2.48.5/Source/JavaScriptCore/offlineasm/ast.rb:1004:in 'Instruction#lowerDefault': Unhandled opcode addq at WebAssembly.asm:739 (due to WebAssembly.asm:739) (LoweringError)

Add backported patch to fix this error.

---
 .../webkitgtk/fix-armv7-compilation.patch     | 32 +++++++++++++++++++
 meta/recipes-sato/webkit/webkitgtk_2.48.5.bb  |  1 +
 2 files changed, 33 insertions(+)
 create mode 100644 meta/recipes-sato/webkit/webkitgtk/fix-armv7-compilation.patch
meta/recipes-sato/webkit/webkitgtk/fix-armv7-compilation.patch new file +32 -0
new file mode 100644
index 0000000000..a857d55ae4
@@ -0,0 +1,32 @@
+From 7999ecd5ee4ea3123f7e75634d2bc57f57ca7070 Mon Sep 17 00:00:00 2001
+From: Justin Michaud <[email protected]>
+Date: Wed, 6 Aug 2025 21:14:26 +0300
+Subject: [PATCH] REGRESSION(2.48.5): [WPE][GTK] Does not compile on ARMv7
+ https://bugs.webkit.org/show_bug.cgi?id=296921
+
+Unreviewed build fix.
+
+* Source/JavaScriptCore/llint/WebAssembly.asm: Replace addq with addp
+  for sp on armv7
+
+Canonical link: https://commits.webkit.org/290945.344@webkitglib/2.48
+
+Upstream-Status: Backport [https://github.com/WebKit/WebKit/commit/7999ecd5ee4ea3123f7e75634d2bc57f57ca7070]
+Signed-off-by: Gyorgy Sarvari <[email protected]>
+---
+ Source/JavaScriptCore/llint/WebAssembly.asm | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Source/JavaScriptCore/llint/WebAssembly.asm b/Source/JavaScriptCore/llint/WebAssembly.asm
+index 1ac3e2accf3c..bd9041404eb1 100644
+--- a/Source/JavaScriptCore/llint/WebAssembly.asm
++++ b/Source/JavaScriptCore/llint/WebAssembly.asm
+@@ -736,7 +736,7 @@ if JSVALUE64
+     storep memoryBase, Callee[cfr]
+ else
+     loadp [sp], ws0
+-    addq 2 * SlotSize, sp
++    addp 2 * SlotSize, sp
+     storep ws0, Callee[cfr]
+ end
+
meta/recipes-sato/webkit/webkitgtk_2.48.5.bb +1 -1
index 947996450d..35b8ee2a90 100644
@@ -18,6 +18,7 @@ SRC_URI = "https://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \
            file://sys_futex.patch \
            file://0001-Fix-build-errors-on-RISCV-https-bugs.webkit.org-show.patch \
            file://fix-ftbfs-riscv64.patch \
+           file://fix-armv7-compilation.patch \
            "
 SRC_URI[sha256sum] = "bb64ed9d1cfd58e8b5e89ccad71dd31adfed56336bad7695031ad0b668e1987c"
 
 
-=-=-=-=-=-=-=-=-=-=-=-

Links: You receive all messages sent to this group.
View/Reply Online (#221688): https://lists.openembedded.org/g/openembedded-core/message/221688
Mute This Topic: https://lists.openembedded.org/mt/114620347/1997914
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-