diff mbox series

[meta-oe] mozjs-128: update 128.5.2 -> 128-14-0

Message ID 20260121200056.2789828-1-f_l_k@t-online.de
State Under Review
Headers show
Series [meta-oe] mozjs-128: update 128.5.2 -> 128-14-0 | expand

Commit Message

Markus Volk Jan. 21, 2026, 8 p.m. UTC
- add a patch to fix build with python 3.14, taken from fedora

Signed-off-by: Markus Volk <f_l_k@t-online.de>
---
 .../mozjs/mozjs-128/D261512.1755672843.patch  | 69 +++++++++++++++++++
 ...s-128_128.5.2.bb => mozjs-128_128.14.0.bb} | 34 ++++-----
 2 files changed, 87 insertions(+), 16 deletions(-)
 create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/D261512.1755672843.patch
 rename meta-oe/recipes-extended/mozjs/{mozjs-128_128.5.2.bb => mozjs-128_128.14.0.bb} (69%)
diff mbox series

Patch

diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/D261512.1755672843.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/D261512.1755672843.patch
new file mode 100644
index 0000000000..ddc481bcec
--- /dev/null
+++ b/meta-oe/recipes-extended/mozjs/mozjs-128/D261512.1755672843.patch
@@ -0,0 +1,69 @@ 
+This patch fixes configure with python 3.14 and was taken from fedora
+
+Upstream-Status: Pending [https://src.fedoraproject.org/fork/churchyard/rpms/mozjs128/c/c9a3e719a87ba3313915195802ca6efcb9966fa3]
+
+Signed-off-by: Markus Volk <f_l_k@t-online.de>
+
+
+diff --git a/python/mozbuild/mozbuild/frontend/reader.py b/python/mozbuild/mozbuild/frontend/reader.py
+index 5cb627b..c2dcafe 100644
+--- a/python/mozbuild/mozbuild/frontend/reader.py
++++ b/python/mozbuild/mozbuild/frontend/reader.py
+@@ -470,7 +470,7 @@ class TemplateFunction(object):
+             return c(
+                 ast.Subscript(
+                     value=c(ast.Name(id=self._global_name, ctx=ast.Load())),
+-                    slice=c(ast.Index(value=c(ast.Str(s=node.id)))),
++                    slice=c(ast.Index(value=c(ast.Constant(value=node.id)))),
+                     ctx=node.ctx,
+                 )
+             )
+@@ -1035,8 +1035,8 @@ class BuildReader(object):
+                 else:
+                     # Others
+                     assert isinstance(target.slice, ast.Index)
+-                    assert isinstance(target.slice.value, ast.Str)
+-                    key = target.slice.value.s
++                    assert isinstance(target.slice.value, ast.Constant)
++                    key = target.slice.value.value
+ 
+             return name, key
+ 
+@@ -1044,11 +1044,11 @@ class BuildReader(object):
+             value = node.value
+             if isinstance(value, ast.List):
+                 for v in value.elts:
+-                    assert isinstance(v, ast.Str)
+-                    yield v.s
++                    assert isinstance(v, ast.Constant)
++                    yield v.value
+             else:
+-                assert isinstance(value, ast.Str)
+-                yield value.s
++                assert isinstance(value, ast.Constant)
++                yield value.value
+ 
+         assignments = []
+ 
+diff --git a/python/mozbuild/mozbuild/vendor/rewrite_mozbuild.py b/python/mozbuild/mozbuild/vendor/rewrite_mozbuild.py
+index 1590267..151d27c 100644
+--- a/python/mozbuild/mozbuild/vendor/rewrite_mozbuild.py
++++ b/python/mozbuild/mozbuild/vendor/rewrite_mozbuild.py
+@@ -327,15 +327,13 @@ def assignment_node_to_source_filename_list(code, node):
+     """
+     if isinstance(node.value, ast.List) and "elts" in node.value._fields:
+         for f in node.value.elts:
+-            if not isinstance(f, ast.Constant) and not isinstance(f, ast.Str):
++            if not isinstance(f, ast.Constant):
+                 log(
+                     "Found non-constant source file name in list: ",
+                     ast_get_source_segment(code, f),
+                 )
+                 return []
+-        return [
+-            f.value if isinstance(f, ast.Constant) else f.s for f in node.value.elts
+-        ]
++        return [f.value for f in node.value.elts]
+     elif isinstance(node.value, ast.ListComp):
+         # SOURCES += [f for f in foo if blah]
+         log("Could not find the files for " + ast_get_source_segment(code, node.value))
diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb b/meta-oe/recipes-extended/mozjs/mozjs-128_128.14.0.bb
similarity index 69%
rename from meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb
rename to meta-oe/recipes-extended/mozjs/mozjs-128_128.14.0.bb
index fbbe3749ba..635cad96cf 100644
--- a/meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb
+++ b/meta-oe/recipes-extended/mozjs/mozjs-128_128.14.0.bb
@@ -3,22 +3,24 @@  HOMEPAGE = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonk
 LICENSE = "MPL-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=dc9b6ecd19a14a54a628edaaf23733bf"
 
-SRC_URI = "https://archive.mozilla.org/pub/firefox/releases/${PV}esr/source/firefox-${PV}esr.source.tar.xz \
-           file://0001-Cargo.toml-do-not-abort-on-panic.patch \
-           file://0002-moz.configure-do-not-look-for-llvm-objdump.patch \
-           file://0003-rust.configure-do-not-try-to-find-a-suitable-upstrea.patch \
-           file://0004-use-asm-sgidefs.h.patch \
-           file://0005-Add-RISCV32-support.patch \
-           file://0006-util.configure-fix-one-occasionally-reproduced-confi.patch \
-           file://0007-Rewrite-cargo-host-linker-in-python3.patch  \
-           file://0008-Musl-does-not-have-stack-unwinder-like-glibc-therefo.patch \
-           file://0009-Backport-patch-from-firefox-bugzilla-to-fix-compile-.patch \
-           file://0010-The-ISB-instruction-isn-t-available-in-ARMv5-or-v6-s.patch \
-           file://0011-Link-with-icu-uc-to-fix-build-with-ICU-76.patch \
-           file://0012-Recognise-riscv64gc-and-riscv32gc-as-valid-architect.patch \
-           file://0013-Fix-build-error-with-musl.patch \
-           "
-SRC_URI[sha256sum] = "25d633eb81499cbda44b8c64fa1c1a5879d55024b864ef495d4997154d68358f"
+SRC_URI = " \
+    https://archive.mozilla.org/pub/firefox/releases/${PV}esr/source/firefox-${PV}esr.source.tar.xz \
+    file://0001-Cargo.toml-do-not-abort-on-panic.patch \
+    file://0002-moz.configure-do-not-look-for-llvm-objdump.patch \
+    file://0003-rust.configure-do-not-try-to-find-a-suitable-upstrea.patch \
+    file://0004-use-asm-sgidefs.h.patch \
+    file://0005-Add-RISCV32-support.patch \
+    file://0006-util.configure-fix-one-occasionally-reproduced-confi.patch \
+    file://0007-Rewrite-cargo-host-linker-in-python3.patch  \
+    file://0008-Musl-does-not-have-stack-unwinder-like-glibc-therefo.patch \
+    file://0009-Backport-patch-from-firefox-bugzilla-to-fix-compile-.patch \
+    file://0010-The-ISB-instruction-isn-t-available-in-ARMv5-or-v6-s.patch \
+    file://0011-Link-with-icu-uc-to-fix-build-with-ICU-76.patch \
+    file://0012-Recognise-riscv64gc-and-riscv32gc-as-valid-architect.patch \
+    file://0013-Fix-build-error-with-musl.patch \
+    file://D261512.1755672843.patch \
+"
+SRC_URI[sha256sum] = "93b9ef6229f41cb22ff109b95bbf61a78395a0fe4b870192eeca22947cb09a53"
 
 UPSTREAM_CHECK_URI = "https://tracker.debian.org/pkg/mozjs128"
 UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)"