From: Kai Kang <kai.k...@windriver.com>

Backport patch from firefox bugzilla to fix compile error for qemuarm
with some armv7ve tunes such as 'armv7vethf' and 'armv7vet-vfpv3d16':

| 
/path/to/build/tmp/work/armv7vet2hf-vfp-poky-linux-gnueabi/mozjs-102/102.5.0-r0/build/js/src/jit/AtomicOperationsGenerated.h:240:17:
  error: 'asm' operand has impossible constraints
|  240 |                 asm volatile (
|      |                 ^~~

Ref:
* https://bugzilla.mozilla.org/show_bug.cgi?id=1761665

Signed-off-by: Kai Kang <kai.k...@windriver.com>
---
 .../0001-add-arm-to-list-of-mozinline.patch   | 25 +++++++++++++++++++
 .../mozjs/mozjs-102_102.5.0.bb                |  1 +
 2 files changed, 26 insertions(+)
 create mode 100644 
meta-oe/recipes-extended/mozjs/mozjs-102/0001-add-arm-to-list-of-mozinline.patch

diff --git 
a/meta-oe/recipes-extended/mozjs/mozjs-102/0001-add-arm-to-list-of-mozinline.patch
 
b/meta-oe/recipes-extended/mozjs/mozjs-102/0001-add-arm-to-list-of-mozinline.patch
new file mode 100644
index 000000000..02f5e5c7e
--- /dev/null
+++ 
b/meta-oe/recipes-extended/mozjs/mozjs-102/0001-add-arm-to-list-of-mozinline.patch
@@ -0,0 +1,25 @@
+Backport patch from firefox bugzilla to fix compile error for qemuarm with
+some armv7ve tunes such as 'armv7vethf' and 'armv7vet-vfpv3d16':
+
+| 
/path/to/build/tmp/work/armv7vet2hf-vfp-poky-linux-gnueabi/mozjs-102/102.5.0-r0/build/js/src/jit/AtomicOperationsGenerated.h:240:17:
+  error: 'asm' operand has impossible constraints
+|  240 |                 asm volatile (
+|      |                 ^~~
+
+Upstream-Status: Submitted 
[https://bugzilla.mozilla.org/show_bug.cgi?id=1761665]
+
+Signed-off-by: Kai Kang <kai.k...@windriver.com>
+
+diff --git a/js/src/jit/GenerateAtomicOperations.py 
b/js/src/jit/GenerateAtomicOperations.py
+index d8a38a0..65f91ab 100644
+--- a/js/src/jit/GenerateAtomicOperations.py
++++ b/js/src/jit/GenerateAtomicOperations.py
+@@ -856,7 +856,7 @@ def generate_atomics_header(c_out):
+ 
+         # Work around a GCC issue on 32-bit x86 by adding MOZ_NEVER_INLINE.
+         # See bug 1756347.
+-        if is_gcc and cpu_arch == "x86":
++        if is_gcc and cpu_arch in ("x86", "arm"):
+             contents = contents.replace("INLINE_ATTR", "MOZ_NEVER_INLINE 
inline")
+         else:
+             contents = contents.replace("INLINE_ATTR", "inline")
diff --git a/meta-oe/recipes-extended/mozjs/mozjs-102_102.5.0.bb 
b/meta-oe/recipes-extended/mozjs/mozjs-102_102.5.0.bb
index d38ae10b8..5e884b6f6 100644
--- a/meta-oe/recipes-extended/mozjs/mozjs-102_102.5.0.bb
+++ b/meta-oe/recipes-extended/mozjs/mozjs-102_102.5.0.bb
@@ -15,6 +15,7 @@ SRC_URI = 
"https://archive.mozilla.org/pub/firefox/releases/${PV}esr/source/fire
            file://0001-rewrite-cargo-host-linker-in-python3.patch  \
            file://py-3.11.patch \
            file://musl-disable-stackwalk.patch \
+           file://0001-add-arm-to-list-of-mozinline.patch \
            "
 SRC_URI[sha256sum] = 
"017dd44b1285913f477074802707a4c76ed1a28270ec5a327bbb76574cc057d8"
 
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#100564): 
https://lists.openembedded.org/g/openembedded-devel/message/100564
Mute This Topic: https://lists.openembedded.org/mt/96249130/21656
Group Owner: openembedded-devel+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to