From patchwork Mon Dec 16 09:07:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markus Volk X-Patchwork-Id: 54132 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B552E77180 for ; Mon, 16 Dec 2024 09:07:08 +0000 (UTC) Received: from mailout12.t-online.de (mailout12.t-online.de [194.25.134.22]) by mx.groups.io with SMTP id smtpd.web11.52531.1734340023955414946 for ; Mon, 16 Dec 2024 01:07:04 -0800 Authentication-Results: mx.groups.io; dkim=none (message not signed); spf=pass (domain: t-online.de, ip: 194.25.134.22, mailfrom: f_l_k@t-online.de) Received: from fwd75.aul.t-online.de (fwd75.aul.t-online.de [10.223.144.101]) by mailout12.t-online.de (Postfix) with SMTP id A6E841860 for ; Mon, 16 Dec 2024 10:07:01 +0100 (CET) Received: from intel-corei7-64.fritz.box ([84.154.162.147]) by fwd75.t-online.de with (TLSv1.3:TLS_AES_256_GCM_SHA384 encrypted) esmtp id 1tN746-0Tnsen0; Mon, 16 Dec 2024 10:06:58 +0100 From: Markus Volk To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 1/3] cbindgen: add recipe Date: Mon, 16 Dec 2024 10:07:03 +0100 Message-ID: <20241216090705.1698-1-f_l_k@t-online.de> X-Mailer: git-send-email 2.47.1 MIME-Version: 1.0 X-TOI-EXPURGATEID: 150726::1734340018-1AFFA9DC-356421B5/10/3626336762 SUSPECT URL X-TOI-MSGID: 5b194ec8-91a6-464a-8d3c-128799e98b7f List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Mon, 16 Dec 2024 09:07:08 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/114323 cbindgen creates C/C++11 headers for Rust libraries which expose a public C API It is a required dependency for the current mozjs esr release Signed-off-by: Markus Volk --- .../cbindgen/cbindgen_0.27.0.bb | 148 ++++++++++++++++++ 1 file changed, 148 insertions(+) create mode 100644 meta-oe/recipes-devtools/cbindgen/cbindgen_0.27.0.bb diff --git a/meta-oe/recipes-devtools/cbindgen/cbindgen_0.27.0.bb b/meta-oe/recipes-devtools/cbindgen/cbindgen_0.27.0.bb new file mode 100644 index 0000000000..e395f667c2 --- /dev/null +++ b/meta-oe/recipes-devtools/cbindgen/cbindgen_0.27.0.bb @@ -0,0 +1,148 @@ +SUMMARY = "cbindgen creates C/C++11 headers for Rust libraries which expose a public C API" +HOMEPAGE = "https://github.com/mozilla/cbindgen" +LICENSE = "MPL-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=9741c346eef56131163e13b9db1241b3" + +SRC_URI += "git://github.com/mozilla/cbindgen.git;protocol=https;branch=master" +SRCREV = "58c6156b0d91e82abb03c26187b8d18fa4345ce0" +S = "${WORKDIR}/git" + +inherit cargo pkgconfig + +SRC_URI += " \ + crate://crates.io/anstream/0.6.15 \ + crate://crates.io/anstyle-parse/0.2.5 \ + crate://crates.io/anstyle-query/1.1.1 \ + crate://crates.io/anstyle-wincon/3.0.4 \ + crate://crates.io/anstyle/1.0.8 \ + crate://crates.io/autocfg/1.3.0 \ + crate://crates.io/bitflags/2.6.0 \ + crate://crates.io/cfg-if/1.0.0 \ + crate://crates.io/clap/4.5.15 \ + crate://crates.io/clap_builder/4.5.15 \ + crate://crates.io/clap_lex/0.7.2 \ + crate://crates.io/colorchoice/1.0.2 \ + crate://crates.io/dashmap/5.5.3 \ + crate://crates.io/diff/0.1.13 \ + crate://crates.io/equivalent/1.0.1 \ + crate://crates.io/errno/0.3.9 \ + crate://crates.io/fastrand/2.1.0 \ + crate://crates.io/hashbrown/0.14.5 \ + crate://crates.io/heck/0.4.1 \ + crate://crates.io/indexmap/2.3.0 \ + crate://crates.io/is_terminal_polyfill/1.70.1 \ + crate://crates.io/itoa/1.0.11 \ + crate://crates.io/lazy_static/1.5.0 \ + crate://crates.io/libc/0.2.155 \ + crate://crates.io/linux-raw-sys/0.4.14 \ + crate://crates.io/lock_api/0.4.12 \ + crate://crates.io/log/0.4.22 \ + crate://crates.io/memchr/2.7.4 \ + crate://crates.io/once_cell/1.19.0 \ + crate://crates.io/parking_lot/0.12.3 \ + crate://crates.io/parking_lot_core/0.9.10 \ + crate://crates.io/pretty_assertions/1.4.0 \ + crate://crates.io/proc-macro2/1.0.86 \ + crate://crates.io/quote/1.0.36 \ + crate://crates.io/redox_syscall/0.5.3 \ + crate://crates.io/rustix/0.38.34 \ + crate://crates.io/ryu/1.0.18 \ + crate://crates.io/scopeguard/1.2.0 \ + crate://crates.io/serde/1.0.205 \ + crate://crates.io/serde_derive/1.0.205 \ + crate://crates.io/serde_json/1.0.122 \ + crate://crates.io/serde_spanned/0.6.7 \ + crate://crates.io/serial_test/2.0.0 \ + crate://crates.io/serial_test_derive/2.0.0 \ + crate://crates.io/smallvec/1.13.2 \ + crate://crates.io/strsim/0.11.1 \ + crate://crates.io/syn/2.0.72 \ + crate://crates.io/tempfile/3.12.0 \ + crate://crates.io/toml/0.8.19 \ + crate://crates.io/toml_datetime/0.6.8 \ + crate://crates.io/toml_edit/0.22.20 \ + crate://crates.io/unicode-ident/1.0.12 \ + crate://crates.io/utf8parse/0.2.2 \ + crate://crates.io/windows-sys/0.52.0 \ + crate://crates.io/windows-sys/0.59.0 \ + crate://crates.io/windows-targets/0.52.6 \ + crate://crates.io/windows_aarch64_gnullvm/0.52.6 \ + crate://crates.io/windows_aarch64_msvc/0.52.6 \ + crate://crates.io/windows_i686_gnu/0.52.6 \ + crate://crates.io/windows_i686_gnullvm/0.52.6 \ + crate://crates.io/windows_i686_msvc/0.52.6 \ + crate://crates.io/windows_x86_64_gnu/0.52.6 \ + crate://crates.io/windows_x86_64_gnullvm/0.52.6 \ + crate://crates.io/windows_x86_64_msvc/0.52.6 \ + crate://crates.io/winnow/0.6.18 \ + crate://crates.io/yansi/0.5.1 \ +" + +SRC_URI[anstream-0.6.15.sha256sum] = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" +SRC_URI[anstyle-parse-0.2.5.sha256sum] = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" +SRC_URI[anstyle-query-1.1.1.sha256sum] = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" +SRC_URI[anstyle-wincon-3.0.4.sha256sum] = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" +SRC_URI[anstyle-1.0.8.sha256sum] = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" +SRC_URI[autocfg-1.3.0.sha256sum] = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" +SRC_URI[bitflags-2.6.0.sha256sum] = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" +SRC_URI[cfg-if-1.0.0.sha256sum] = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +SRC_URI[clap-4.5.15.sha256sum] = "11d8838454fda655dafd3accb2b6e2bea645b9e4078abe84a22ceb947235c5cc" +SRC_URI[clap_builder-4.5.15.sha256sum] = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6" +SRC_URI[clap_lex-0.7.2.sha256sum] = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" +SRC_URI[colorchoice-1.0.2.sha256sum] = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" +SRC_URI[dashmap-5.5.3.sha256sum] = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" +SRC_URI[diff-0.1.13.sha256sum] = "56254986775e3233ffa9c4d7d3faaf6d36a2c09d30b20687e9f88bc8bafc16c8" +SRC_URI[equivalent-1.0.1.sha256sum] = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +SRC_URI[errno-0.3.9.sha256sum] = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +SRC_URI[fastrand-2.1.0.sha256sum] = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" +SRC_URI[hashbrown-0.14.5.sha256sum] = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +SRC_URI[heck-0.4.1.sha256sum] = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +SRC_URI[indexmap-2.3.0.sha256sum] = "de3fc2e30ba82dd1b3911c8de1ffc143c74a914a14e99514d7637e3099df5ea0" +SRC_URI[is_terminal_polyfill-1.70.1.sha256sum] = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" +SRC_URI[itoa-1.0.11.sha256sum] = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" +SRC_URI[lazy_static-1.5.0.sha256sum] = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +SRC_URI[libc-0.2.155.sha256sum] = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" +SRC_URI[linux-raw-sys-0.4.14.sha256sum] = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" +SRC_URI[lock_api-0.4.12.sha256sum] = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +SRC_URI[log-0.4.22.sha256sum] = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" +SRC_URI[memchr-2.7.4.sha256sum] = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" +SRC_URI[once_cell-1.19.0.sha256sum] = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +SRC_URI[parking_lot-0.12.3.sha256sum] = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +SRC_URI[parking_lot_core-0.9.10.sha256sum] = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +SRC_URI[pretty_assertions-1.4.0.sha256sum] = "af7cee1a6c8a5b9208b3cb1061f10c0cb689087b3d8ce85fb9d2dd7a29b6ba66" +SRC_URI[proc-macro2-1.0.86.sha256sum] = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" +SRC_URI[quote-1.0.36.sha256sum] = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +SRC_URI[redox_syscall-0.5.3.sha256sum] = "2a908a6e00f1fdd0dfd9c0eb08ce85126f6d8bbda50017e74bc4a4b7d4a926a4" +SRC_URI[rustix-0.38.34.sha256sum] = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +SRC_URI[ryu-1.0.18.sha256sum] = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" +SRC_URI[scopeguard-1.2.0.sha256sum] = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" +SRC_URI[serde-1.0.205.sha256sum] = "e33aedb1a7135da52b7c21791455563facbbcc43d0f0f66165b42c21b3dfb150" +SRC_URI[serde_derive-1.0.205.sha256sum] = "692d6f5ac90220161d6774db30c662202721e64aed9058d2c394f451261420c1" +SRC_URI[serde_json-1.0.122.sha256sum] = "784b6203951c57ff748476b126ccb5e8e2959a5c19e5c617ab1956be3dbc68da" +SRC_URI[serde_spanned-0.6.7.sha256sum] = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d" +SRC_URI[serial_test-2.0.0.sha256sum] = "0e56dd856803e253c8f298af3f4d7eb0ae5e23a737252cd90bb4f3b435033b2d" +SRC_URI[serial_test_derive-2.0.0.sha256sum] = "91d129178576168c589c9ec973feedf7d3126c01ac2bf08795109aa35b69fb8f" +SRC_URI[smallvec-1.13.2.sha256sum] = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +SRC_URI[strsim-0.11.1.sha256sum] = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" +SRC_URI[syn-2.0.72.sha256sum] = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" +SRC_URI[tempfile-3.12.0.sha256sum] = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" +SRC_URI[toml-0.8.19.sha256sum] = "a1ed1f98e3fdc28d6d910e6737ae6ab1a93bf1985935a1193e68f93eeb68d24e" +SRC_URI[toml_datetime-0.6.8.sha256sum] = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" +SRC_URI[toml_edit-0.22.20.sha256sum] = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" +SRC_URI[unicode-ident-1.0.12.sha256sum] = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +SRC_URI[utf8parse-0.2.2.sha256sum] = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" +SRC_URI[windows-sys-0.52.0.sha256sum] = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +SRC_URI[windows-sys-0.59.0.sha256sum] = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +SRC_URI[windows-targets-0.52.6.sha256sum] = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" +SRC_URI[windows_aarch64_gnullvm-0.52.6.sha256sum] = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" +SRC_URI[windows_aarch64_msvc-0.52.6.sha256sum] = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" +SRC_URI[windows_i686_gnu-0.52.6.sha256sum] = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" +SRC_URI[windows_i686_gnullvm-0.52.6.sha256sum] = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" +SRC_URI[windows_i686_msvc-0.52.6.sha256sum] = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" +SRC_URI[windows_x86_64_gnu-0.52.6.sha256sum] = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" +SRC_URI[windows_x86_64_gnullvm-0.52.6.sha256sum] = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" +SRC_URI[windows_x86_64_msvc-0.52.6.sha256sum] = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" +SRC_URI[winnow-0.6.18.sha256sum] = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" +SRC_URI[yansi-0.5.1.sha256sum] = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" + +BBCLASSEXTEND += "native" From patchwork Mon Dec 16 09:07:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markus Volk X-Patchwork-Id: 54133 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7901EE7717F for ; Mon, 16 Dec 2024 09:07:08 +0000 (UTC) Received: from mailout12.t-online.de (mailout12.t-online.de [194.25.134.22]) by mx.groups.io with SMTP id smtpd.web11.52532.1734340023990955090 for ; Mon, 16 Dec 2024 01:07:04 -0800 Authentication-Results: mx.groups.io; dkim=none (message not signed); spf=pass (domain: t-online.de, ip: 194.25.134.22, mailfrom: f_l_k@t-online.de) Received: from fwd75.aul.t-online.de (fwd75.aul.t-online.de [10.223.144.101]) by mailout12.t-online.de (Postfix) with SMTP id A8DC718A8 for ; Mon, 16 Dec 2024 10:07:01 +0100 (CET) Received: from intel-corei7-64.fritz.box ([84.154.162.147]) by fwd75.t-online.de with (TLSv1.3:TLS_AES_256_GCM_SHA384 encrypted) esmtp id 1tN746-0Tnseo0; Mon, 16 Dec 2024 10:06:58 +0100 From: Markus Volk To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 2/3] mozjs: add recipe for mozjs-128 Date: Mon, 16 Dec 2024 10:07:04 +0100 Message-ID: <20241216090705.1698-2-f_l_k@t-online.de> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20241216090705.1698-1-f_l_k@t-online.de> References: <20241216090705.1698-1-f_l_k@t-online.de> MIME-Version: 1.0 X-TOI-EXPURGATEID: 150726::1734340018-B9FF89DC-E31EEE82/0/0 CLEAN NORMAL X-TOI-MSGID: 1795df2d-5f31-4083-80a9-ec8b3ce5c19c List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Mon, 16 Dec 2024 09:07:08 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/114324 mozjs-128 is the current esr release based on firefox 128 Add a new recipe and keep mozjs-115 as its still supported and used by polkit - Remove two backported patches - Remove a (hopefully) unneeded patches for musl (build for qemuarm/musl succeeded) - Add dependency for cbindgen-native Signed-off-by: Markus Volk --- ...001-Cargo.toml-do-not-abort-on-panic.patch | 31 ++++++ ...with-icu-uc-to-fix-build-with-ICU-76.patch | 27 +++++ .../0001-add-arm-to-list-of-mozinline.patch | 31 ++++++ ...-autoconf-s-config.sub-to-canonicali.patch | 44 ++++++++ ...rewrite-cargo-host-linker-in-python3.patch | 53 +++++++++ ...ix-one-occasionally-reproduced-confi.patch | 47 ++++++++ ...nfigure-do-not-look-for-llvm-objdump.patch | 43 ++++++++ ...o-not-try-to-find-a-suitable-upstrea.patch | 65 +++++++++++ .../mozjs-128/0004-use-asm-sgidefs.h.patch | 37 +++++++ .../mozjs/mozjs-128/armv5.patch | 28 +++++ .../mozjs-128/musl-disable-stackwalk.patch | 27 +++++ .../mozjs/mozjs-128/riscv32.patch | 59 ++++++++++ .../mozjs/mozjs-128_128.5.2.bb | 102 ++++++++++++++++++ 13 files changed, 594 insertions(+) create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0001-Cargo.toml-do-not-abort-on-panic.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0001-Link-with-icu-uc-to-fix-build-with-ICU-76.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0001-add-arm-to-list-of-mozinline.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0001-build-do-not-use-autoconf-s-config.sub-to-canonicali.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0001-rewrite-cargo-host-linker-in-python3.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0001-util.configure-fix-one-occasionally-reproduced-confi.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0002-moz.configure-do-not-look-for-llvm-objdump.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0003-rust.configure-do-not-try-to-find-a-suitable-upstrea.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/0004-use-asm-sgidefs.h.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/armv5.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/musl-disable-stackwalk.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128/riscv32.patch create mode 100644 meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0001-Cargo.toml-do-not-abort-on-panic.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-Cargo.toml-do-not-abort-on-panic.patch new file mode 100644 index 0000000000..97a4439628 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-Cargo.toml-do-not-abort-on-panic.patch @@ -0,0 +1,31 @@ +From ddd23f8547f3a56aa542924aa400d3535f734bff Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin +Date: Fri, 1 Oct 2021 13:00:24 +0200 +Subject: [PATCH] Cargo.toml: do not abort on panic + +OE's rust is configured to unwind, and this setting clashes with it/ + +Upstream-Status: Inappropriate [oe-core specific] +Signed-off-by: Alexander Kanavin +--- + Cargo.toml | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/Cargo.toml b/Cargo.toml +index a4248187be..eed8964b3a 100644 +--- a/Cargo.toml ++++ b/Cargo.toml +@@ -67,13 +67,11 @@ opt-level = 1 + rpath = false + lto = false + debug-assertions = true +-panic = "abort" + + [profile.release] + opt-level = 2 + rpath = false + debug-assertions = false +-panic = "abort" + + # Optimize build dependencies, because bindgen and proc macros / style + # compilation take more to run than to build otherwise. diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0001-Link-with-icu-uc-to-fix-build-with-ICU-76.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-Link-with-icu-uc-to-fix-build-with-ICU-76.patch new file mode 100644 index 0000000000..4fb7a28eeb --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-Link-with-icu-uc-to-fix-build-with-ICU-76.patch @@ -0,0 +1,27 @@ +From cbb5cc1022cc27edefc8eabbe21458cac9bda6fb Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sat, 23 Nov 2024 13:28:33 -0800 +Subject: [PATCH] Link with icu-uc to fix build with ICU-76 + +Fixes +https://bugzilla.mozilla.org/show_bug.cgi?id=1927380 + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + js/moz.configure | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/js/moz.configure b/js/moz.configure +index 593b93acee..2181dca34b 100644 +--- a/js/moz.configure ++++ b/js/moz.configure +@@ -1305,7 +1305,7 @@ def enable_system_icu_option(enable_system_icu): + return enable_system_icu + + +-system_icu = pkg_check_modules("MOZ_ICU", "icu-i18n >= 73.1", when="--with-system-icu") ++system_icu = pkg_check_modules("MOZ_ICU", "icu-i18n >= 73.1 icu-uc", when="--with-system-icu") + + + @depends(enable_system_icu_option) diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0001-add-arm-to-list-of-mozinline.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-add-arm-to-list-of-mozinline.patch new file mode 100644 index 0000000000..960b4593c2 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-add-arm-to-list-of-mozinline.patch @@ -0,0 +1,31 @@ +From 2d1fb35bd81acadc12cc077de86361ac59cee2f1 Mon Sep 17 00:00:00 2001 +From: Kai Kang +Date: Fri, 22 Sep 2023 22:59:59 +0000 +Subject: [PATCH] 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 +--- + js/src/jit/GenerateAtomicOperations.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/js/src/jit/GenerateAtomicOperations.py b/js/src/jit/GenerateAtomicOperations.py +index 9194b8b685..145563bb37 100644 +--- a/js/src/jit/GenerateAtomicOperations.py ++++ b/js/src/jit/GenerateAtomicOperations.py +@@ -850,7 +850,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-128/0001-build-do-not-use-autoconf-s-config.sub-to-canonicali.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-build-do-not-use-autoconf-s-config.sub-to-canonicali.patch new file mode 100644 index 0000000000..38496ea56c --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-build-do-not-use-autoconf-s-config.sub-to-canonicali.patch @@ -0,0 +1,44 @@ +From c860dcbe63b0e393c95bfb0131238f91aaac11d3 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin +Date: Thu, 7 Oct 2021 12:44:18 +0200 +Subject: [PATCH] build: do not use autoconf's config.sub to 'canonicalize' + names + +The outcome is that processed names no longer match our custom rust +target definitions, and the build fails. + +Upstream-Status: Inappropriate [oe-core specific] +Signed-off-by: Alexander Kanavin + +--- + build/moz.configure/init.configure | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/build/moz.configure/init.configure ++++ b/build/moz.configure/init.configure +@@ -647,24 +647,7 @@ def help_host_target(help, host, target) + + def config_sub(shell, triplet): + config_sub = os.path.join(os.path.dirname(__file__), "..", "autoconf", "config.sub") +- # Config.sub doesn't like the *-windows-msvc/*-windows-gnu triplets, so +- # munge those before and after calling config.sub. +- suffix = None +- munging = { +- "-windows-msvc": "-mingw32", +- "-windows-gnu": "-mingw32", +- } +- for check_suffix, replacement in munging.items(): +- if triplet.endswith(check_suffix): +- suffix = check_suffix +- triplet = triplet[: -len(suffix)] + replacement +- break +- result = check_cmd_output(shell, config_sub, triplet).strip() +- if suffix: +- assert result.endswith(replacement) +- result = result[: -len(replacement)] + suffix +- return result +- ++ return triplet + + @depends("--host", shell) + @checking("for host system type", lambda h: h.alias) diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0001-rewrite-cargo-host-linker-in-python3.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-rewrite-cargo-host-linker-in-python3.patch new file mode 100644 index 0000000000..94e1651b33 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-rewrite-cargo-host-linker-in-python3.patch @@ -0,0 +1,53 @@ +From 6f6b78628a8edc834aa147c87ebce3eb8e670e7a Mon Sep 17 00:00:00 2001 +From: Changqing Li +Date: Thu, 18 Nov 2021 07:16:39 +0000 +Subject: [PATCH] Rewrite cargo-host-linker in python3 + +Mozjs compile failed with this failure: +/bin/sh: /lib64/libc.so.6: version `GLIBC_2.33' not found (required by /build/tmp-glibc/work/corei7-64-wrs-linux/mozjs/91.1.0-r0/recipe-sysroot-native/usr/lib/libtinfo.so.5) + +Root Cause: +cargo-host-linker has /bin/sh as it's interpreter, but cargo run the cmd +with LD_LIBRARY_PATH set to recipe-sysroot-native. The host /bin/sh links +libtinfo.so.5 under recipe-sysroot-native, which needs higher libc. But +host libc is older libc. So the incompatible problem occurred. + +Solution: +rewrite cargo-host-linker in python3 + +Upstream-Status: Inappropriate [oe specific] + +Signed-off-by: Changqing Li +--- + build/cargo-host-linker | 24 +++++++++++++++++++++--- + 1 file changed, 21 insertions(+), 3 deletions(-) + +diff --git a/build/cargo-host-linker b/build/cargo-host-linker +index cbd0472bf7..87d43ce9ec 100755 +--- a/build/cargo-host-linker ++++ b/build/cargo-host-linker +@@ -1,3 +1,21 @@ +-#!/bin/sh +-# See comment in cargo-linker. +-eval ${MOZ_CARGO_WRAP_HOST_LD} ${MOZ_CARGO_WRAP_HOST_LDFLAGS} '"$@"' ++#!/usr/bin/env python3 ++ ++import os,sys ++ ++if os.environ['MOZ_CARGO_WRAP_HOST_LD'].strip(): ++ binary=os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[0] ++else: ++ sys.exit(0) ++ ++if os.environ['MOZ_CARGO_WRAP_HOST_LDFLAGS'].strip(): ++ if os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[1:]: ++ args=[os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[0]] + os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[1:] + [os.environ['MOZ_CARGO_WRAP_HOST_LDFLAGS']] + sys.argv[1:] ++ else: ++ args=[os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[0]] + [os.environ['MOZ_CARGO_WRAP_HOST_LDFLAGS']] + sys.argv[1:] ++else: ++ if os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[1:]: ++ args=[os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[0]] + os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[1:] + sys.argv[1:] ++ else: ++ args=[os.environ['MOZ_CARGO_WRAP_HOST_LD'].split()[0]] + sys.argv[1:] ++ ++os.execvp(binary, args) diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0001-util.configure-fix-one-occasionally-reproduced-confi.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-util.configure-fix-one-occasionally-reproduced-confi.patch new file mode 100644 index 0000000000..d53cc2bd41 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0001-util.configure-fix-one-occasionally-reproduced-confi.patch @@ -0,0 +1,47 @@ +From 683cd23dd269509a1d913adb2b049b84771e0a94 Mon Sep 17 00:00:00 2001 +From: Changqing Li +Date: Thu, 11 Nov 2021 16:05:54 +0800 +Subject: [PATCH] util.configure: fix one occasionally reproduced configure + failure + +error: +| checking whether the C++ compiler supports -Wno-range-loop-analysis... +| DEBUG: Creating /tmp/conftest.jr1qrcw3.cpp with content: +| DEBUG: | int +| DEBUG: | main(void) +| DEBUG: | { +| DEBUG: | +| DEBUG: | ; +| DEBUG: | return 0; +| DEBUG: | } +| DEBUG: Executing: aarch64-wrs-linux-g++ -mcpu=cortex-a53 -march=armv8-a+crc -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security --sysroot=/mozjs/91.1.0-r0/recipe-sysroot /tmp/conftest.jr1qrcw3.cpp -Werror -Wrange-loop-analysis -c +| DEBUG: The command returned non-zero exit status 1. +| DEBUG: Its error output was: +... +| File "/mozjs/91.1.0-r0/firefox-91.1.0/build/moz.configure/util.configure", line 239, in try_invoke_compiler +| os.remove(path) +| FileNotFoundError: [Errno 2] No such file or directory: '/tmp/conftest.jr1qrcw3.cpp' + +It should be another process that deleted this file by using +"rm -rf conftest*" inappropriately + +Upstream-Status: Submitted [https://bugzilla.mozilla.org/show_bug.cgi?id=1740667] + +Signed-off-by: Changqing Li +--- + build/moz.configure/util.configure | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/build/moz.configure/util.configure b/build/moz.configure/util.configure +index d93b91fcdd..47ab8b92b9 100644 +--- a/build/moz.configure/util.configure ++++ b/build/moz.configure/util.configure +@@ -256,7 +256,7 @@ def try_invoke_compiler( + "C++": ".cpp", + }[language] + +- fd, path = mkstemp(prefix="conftest.", suffix=suffix, text=True) ++ fd, path = mkstemp(prefix="try_invoke_compiler_conftest.", suffix=suffix, text=True) + try: + source = source.encode("ascii", "replace") + diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0002-moz.configure-do-not-look-for-llvm-objdump.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0002-moz.configure-do-not-look-for-llvm-objdump.patch new file mode 100644 index 0000000000..9a82acf77b --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0002-moz.configure-do-not-look-for-llvm-objdump.patch @@ -0,0 +1,43 @@ +From 1a5331f1997788e9a25bbc2b10eb14e2ee418be9 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin +Date: Fri, 1 Oct 2021 13:01:10 +0200 +Subject: [PATCH] moz.configure: do not look for llvm-objdump + +This avoid dragging in a dependency that isn't even needed +for js builds. + +Upstream-Status: Inappropriate [oe-core specific] +Signed-off-by: Alexander Kanavin +--- + moz.configure | 18 +++++++++--------- + 1 file changed, 9 insertions(+), 9 deletions(-) + +diff --git a/moz.configure b/moz.configure +index 804b9a375a..402e79e3b3 100755 +--- a/moz.configure ++++ b/moz.configure +@@ -390,15 +390,15 @@ def plain_llvm_or_prefixed(name, llvm_name=None): + return plain_llvm_or_prefixed + + +-llvm_objdump = check_prog( +- "LLVM_OBJDUMP", +- llvm_tool("llvm-objdump"), +- what="llvm-objdump", +- when="--enable-compile-environment", +- paths=clang_search_path, +-) +- +-add_old_configure_assignment("LLVM_OBJDUMP", llvm_objdump) ++#llvm_objdump = check_prog( ++# "LLVM_OBJDUMP", ++# llvm_tool("llvm-objdump"), ++# what="llvm-objdump", ++# when="--enable-compile-environment", ++# paths=clang_search_path, ++#) ++# ++#add_old_configure_assignment("LLVM_OBJDUMP", llvm_objdump) + + + def validate_readelf(path): diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0003-rust.configure-do-not-try-to-find-a-suitable-upstrea.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0003-rust.configure-do-not-try-to-find-a-suitable-upstrea.patch new file mode 100644 index 0000000000..40025fbc68 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0003-rust.configure-do-not-try-to-find-a-suitable-upstrea.patch @@ -0,0 +1,65 @@ +From 2d7f06cdf631e4d4d94e9d8e33a953dc57672750 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin +Date: Fri, 1 Oct 2021 13:02:17 +0200 +Subject: [PATCH] rust.configure: do not try to find a suitable upstream target + +OE is using custom targets and so this is bound to fail. + +Upstream-Status: Inappropriate [oe-core specific] +Signed-off-by: Alexander Kanavin +--- + build/moz.configure/rust.configure | 34 ++---------------------------- + 1 file changed, 2 insertions(+), 32 deletions(-) + +diff --git a/build/moz.configure/rust.configure b/build/moz.configure/rust.configure +index acac34ec05..ff3b8fc0fd 100644 +--- a/build/moz.configure/rust.configure ++++ b/build/moz.configure/rust.configure +@@ -486,33 +486,7 @@ def assert_rust_compile(host_or_target, rustc_target, rustc): + def rust_host_triple( + rustc, host, compiler_info, rustc_host, rust_supported_targets, arm_target + ): +- rustc_target = detect_rustc_target( +- host, compiler_info, arm_target, rust_supported_targets +- ) +- if rustc_target != rustc_host: +- if host.alias == rustc_target: +- configure_host = host.alias +- else: +- configure_host = "{}/{}".format(host.alias, rustc_target) +- die( +- dedent( +- """\ +- The rust compiler host ({rustc}) is not suitable for the configure host ({configure}). +- +- You can solve this by: +- * Set your configure host to match the rust compiler host by editing your +- mozconfig and adding "ac_add_options --host={rustc}". +- * Or, install the rust toolchain for {configure}, if supported, by running +- "rustup default stable-{rustc_target}" +- """.format( +- rustc=rustc_host, +- configure=configure_host, +- rustc_target=rustc_target, +- ) +- ) +- ) +- assert_rust_compile(host, rustc_target, rustc) +- return rustc_target ++ return rustc_host + + + @depends( +@@ -522,11 +496,7 @@ def rust_host_triple( + def rust_target_triple( + rustc, target, compiler_info, rust_supported_targets, arm_target + ): +- rustc_target = detect_rustc_target( +- target, compiler_info, arm_target, rust_supported_targets +- ) +- assert_rust_compile(target, rustc_target, rustc) +- return rustc_target ++ return target.alias + + + set_config("RUST_TARGET", rust_target_triple) diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/0004-use-asm-sgidefs.h.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/0004-use-asm-sgidefs.h.patch new file mode 100644 index 0000000000..eb3ff452b3 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/0004-use-asm-sgidefs.h.patch @@ -0,0 +1,37 @@ +From 1691939a22ec12245f008993e0b9a1b1dfb91e9c Mon Sep 17 00:00:00 2001 +From: Andre McCurdy +Date: Sat, 30 Apr 2016 15:29:06 -0700 +Subject: [PATCH] use + +Build fix for MIPS with musl libc + +The MIPS specific header is provided by glibc and uclibc +but not by musl. Regardless of the libc, the kernel headers provide + which provides the same definitions, so use that +instead. + +Upstream-Status: Pending + +[Vincent: +Taken from: https://sourceware.org/bugzilla/show_bug.cgi?id=21070] + +Signed-off-by: Andre McCurdy +Signed-off-by: Khem Raj +Signed-off-by: Vicente Olivert Riera +--- + mfbt/RandomNum.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mfbt/RandomNum.cpp b/mfbt/RandomNum.cpp +index 96de5d4055..2cfb2e10ee 100644 +--- a/mfbt/RandomNum.cpp ++++ b/mfbt/RandomNum.cpp +@@ -53,7 +53,7 @@ extern "C" BOOLEAN NTAPI RtlGenRandom(PVOID RandomBuffer, + # elif defined(__s390__) + # define GETRANDOM_NR 349 + # elif defined(__mips__) +-# include ++# include + # if _MIPS_SIM == _MIPS_SIM_ABI32 + # define GETRANDOM_NR 4353 + # elif _MIPS_SIM == _MIPS_SIM_ABI64 diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/armv5.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/armv5.patch new file mode 100644 index 0000000000..564f423fb4 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/armv5.patch @@ -0,0 +1,28 @@ +From 0dd6fdbf6a821898617f1bd8e57123be048c07f5 Mon Sep 17 00:00:00 2001 +From: Ross Burton +Date: Mon, 16 Dec 2024 05:49:57 +0000 +Subject: [PATCH] The ISB instruction isn't available in ARMv5 or v6, so guard + it's use to fix the build on qemuarmv5. + +Upstream-Status: Pending +Signed-off-by: Ross Burton +--- + js/src/jit/arm/Architecture-arm.cpp | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/js/src/jit/arm/Architecture-arm.cpp b/js/src/jit/arm/Architecture-arm.cpp +index d4c5026705..fc0455eaff 100644 +--- a/js/src/jit/arm/Architecture-arm.cpp ++++ b/js/src/jit/arm/Architecture-arm.cpp +@@ -528,9 +528,11 @@ void FlushICache(void* code, size_t size) { + + void FlushExecutionContext() { + #ifndef JS_SIMULATOR_ARM ++#if __ARM_ARCH >= 7 + // Ensure that any instructions already in the pipeline are discarded and + // reloaded from the icache. + asm volatile("isb\n" : : : "memory"); ++#endif + #else + // We assume the icache flushing routines on other platforms take care of this + #endif diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/musl-disable-stackwalk.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/musl-disable-stackwalk.patch new file mode 100644 index 0000000000..3d5452ce4d --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/musl-disable-stackwalk.patch @@ -0,0 +1,27 @@ +From d96e9a40e9da9163e0a4b3475178fe30c26deb19 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 22 Sep 2023 22:59:56 +0000 +Subject: [PATCH] Musl does not have stack unwinder like glibc therefore we can + + not assume that its always available on musl, we do need to check for target + environment as well which could be musl or glibc. + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + mozglue/misc/StackWalk.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mozglue/misc/StackWalk.cpp b/mozglue/misc/StackWalk.cpp +index 18fd3464b0..d3d9208fdb 100644 +--- a/mozglue/misc/StackWalk.cpp ++++ b/mozglue/misc/StackWalk.cpp +@@ -50,7 +50,7 @@ using namespace mozilla; + # define HAVE___LIBC_STACK_END 0 + #endif + +-#if (defined(linux) && \ ++#if (defined(linux) && defined(__GLIBC__) && \ + ((defined(__GNUC__) && (defined(__i386) || defined(PPC))) || \ + defined(HAVE__UNWIND_BACKTRACE)) && \ + (HAVE___LIBC_STACK_END || ANDROID)) diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128/riscv32.patch b/meta-oe/recipes-extended/mozjs/mozjs-128/riscv32.patch new file mode 100644 index 0000000000..67e23c5fcc --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128/riscv32.patch @@ -0,0 +1,59 @@ +From 0cc41bc953974d4852b263708bf8d12f823ca8ad Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sun, 24 Oct 2021 22:32:50 -0700 +Subject: [PATCH] Add RISCV32 support + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + build/moz.configure/init.configure | 3 +++ + python/mozbuild/mozbuild/configure/constants.py | 2 ++ + .../mozbuild/test/configure/test_toolchain_configure.py | 1 + + 3 files changed, 6 insertions(+) + +diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure +index 97b9bab167..d9a5a2035d 100644 +--- a/build/moz.configure/init.configure ++++ b/build/moz.configure/init.configure +@@ -594,6 +594,9 @@ def split_triplet(triplet, allow_wasi=False): + elif cpu.startswith("aarch64"): + canonical_cpu = "aarch64" + endianness = "little" ++ elif cpu in ("riscv32", "riscv32gc"): ++ canonical_cpu = "riscv32" ++ endianness = "little" + elif cpu in ("riscv64", "riscv64gc"): + canonical_cpu = "riscv64" + endianness = "little" +diff --git a/python/mozbuild/mozbuild/configure/constants.py b/python/mozbuild/mozbuild/configure/constants.py +index 25f43bb9f8..3335e69405 100644 +--- a/python/mozbuild/mozbuild/configure/constants.py ++++ b/python/mozbuild/mozbuild/configure/constants.py +@@ -73,6 +73,7 @@ CPU_bitness = { + "mips64": 64, + "ppc": 32, + "ppc64": 64, ++ 'riscv32': 32, + "riscv64": 64, + "s390": 32, + "s390x": 64, +@@ -129,6 +130,7 @@ CPU_preprocessor_checks = OrderedDict( + ("m68k", "__m68k__"), + ("mips64", "__mips64"), + ("mips32", "__mips__"), ++ ("riscv32", "__riscv && __riscv_xlen == 32"), + ("riscv64", "__riscv && __riscv_xlen == 64"), + ("loongarch64", "__loongarch64"), + ("sh4", "__sh__"), +diff --git a/python/mozbuild/mozbuild/test/configure/test_toolchain_configure.py b/python/mozbuild/mozbuild/test/configure/test_toolchain_configure.py +index d438b68eb8..1be0d02e54 100644 +--- a/python/mozbuild/mozbuild/test/configure/test_toolchain_configure.py ++++ b/python/mozbuild/mozbuild/test/configure/test_toolchain_configure.py +@@ -1325,6 +1325,7 @@ class LinuxCrossCompileToolchainTest(BaseToolchainTest): + "m68k-unknown-linux-gnu": big_endian + {"__m68k__": 1}, + "mips64-unknown-linux-gnuabi64": big_endian + {"__mips64": 1, "__mips__": 1}, + "mips-unknown-linux-gnu": big_endian + {"__mips__": 1}, ++ "riscv32-unknown-linux-gnu": little_endian + {"__riscv": 1, "__riscv_xlen": 32}, + "riscv64-unknown-linux-gnu": little_endian + {"__riscv": 1, "__riscv_xlen": 64}, + "sh4-unknown-linux-gnu": little_endian + {"__sh__": 1}, + } diff --git a/meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb b/meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb new file mode 100644 index 0000000000..0fbf3d43f9 --- /dev/null +++ b/meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb @@ -0,0 +1,102 @@ +SUMMARY = "SpiderMonkey is Mozilla's JavaScript engine written in C/C++" +HOMEPAGE = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey" +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://riscv32.patch \ + file://0001-util.configure-fix-one-occasionally-reproduced-confi.patch \ + file://0001-rewrite-cargo-host-linker-in-python3.patch \ + file://musl-disable-stackwalk.patch \ + file://0001-add-arm-to-list-of-mozinline.patch \ + file://armv5.patch \ + file://0001-Link-with-icu-uc-to-fix-build-with-ICU-76.patch \ + " +SRC_URI[sha256sum] = "25d633eb81499cbda44b8c64fa1c1a5879d55024b864ef495d4997154d68358f" + +UPSTREAM_CHECK_URI = "https://tracker.debian.org/pkg/mozjs128" +UPSTREAM_CHECK_REGEX = "(?P\d+(\.\d+)+)" + +S = "${WORKDIR}/firefox-${PV}" + +inherit pkgconfig perlnative python3native rust + +DEPENDS += "zlib cbindgen-native python3 icu" +DEPENDS:remove:mipsarch = "icu" +DEPENDS:remove:powerpc:toolchain-clang = "icu" + +B = "${WORKDIR}/build" + +export PYTHONPATH = "${S}/build:\ +${S}/third_party/python/PyYAML/lib3:\ +${S}/testing/mozbase/mozfile:\ +${S}/python/mozboot:\ +${S}/third_party/python/distro:\ +${S}/testing/mozbase/mozinfo:\ +${S}/config:\ +${S}/testing/mozbase/manifestparser:\ +${S}/third_party/python/pytoml:\ +${S}/testing/mozbase/mozprocess:\ +${S}/third_party/python/six:\ +${S}/python/mozbuild:\ +${S}/python/mozbuild/mozbuild:\ +${S}/python/mach:\ +${S}/third_party/python/jsmin:\ +${S}/python/mozversioncontrol" + +export HOST_CC = "${BUILD_CC}" +export HOST_CXX = "${BUILD_CXX}" +export HOST_CFLAGS = "${BUILD_CFLAGS}" +export HOST_CPPFLAGS = "${BUILD_CPPFLAGS}" +export HOST_CXXFLAGS = "${BUILD_CXXFLAGS}" + +export AS = "${CC}" + +export RUSTFLAGS + +JIT ?= "" +JIT:mipsarch = "--disable-jit" +ICU ?= "--with-system-icu" +ICU:mipsarch = "" +ICU:powerpc:toolchain-clang = "" + +LDFLAGS:append:riscv32 = " -latomic" + +do_configure() { + cd ${B} + python3 ${S}/configure.py \ + --enable-project=js \ + --target=${RUST_HOST_SYS} \ + --host=${BUILD_SYS} \ + --prefix=${prefix} \ + --libdir=${libdir} \ + --disable-jemalloc \ + --disable-strip \ + ${JIT} \ + ${ICU} +} +do_configure[cleandirs] += "${B}" + +do_install() { + oe_runmake 'DESTDIR=${D}' install +} + +inherit multilib_script multilib_header + +MAJ_VER = "${@oe.utils.trim_version("${PV}", 1)}" +MULTILIB_SCRIPTS += "${PN}-dev:${bindir}/js${MAJ_VER}-config" + +do_install:append() { + oe_multilib_header mozjs-${MAJ_VER}/js-config.h + sed -e 's@${STAGING_DIR_HOST}@@g' \ + -i ${D}${bindir}/js${MAJ_VER}-config + rm -f ${D}${libdir}/libjs_static.ajs +} + +PACKAGE_DEBUG_SPLIT_STYLE = "debug-without-src" +PACKAGES =+ "lib${BPN}" +FILES:lib${BPN} += "${libdir}/lib*" From patchwork Mon Dec 16 09:07:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Markus Volk X-Patchwork-Id: 54134 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5F2D2E77180 for ; Mon, 16 Dec 2024 09:07:48 +0000 (UTC) Received: from mailout01.t-online.de (mailout01.t-online.de [194.25.134.80]) by mx.groups.io with SMTP id smtpd.web11.52534.1734340061002193052 for ; Mon, 16 Dec 2024 01:07:41 -0800 Authentication-Results: mx.groups.io; dkim=none (message not signed); spf=pass (domain: t-online.de, ip: 194.25.134.80, mailfrom: f_l_k@t-online.de) Received: from fwd75.aul.t-online.de (fwd75.aul.t-online.de [10.223.144.101]) by mailout01.t-online.de (Postfix) with SMTP id BAD0ABEA for ; Mon, 16 Dec 2024 10:07:01 +0100 (CET) Received: from intel-corei7-64.fritz.box ([84.154.162.147]) by fwd75.t-online.de with (TLSv1.3:TLS_AES_256_GCM_SHA384 encrypted) esmtp id 1tN747-0Tnsep0; Mon, 16 Dec 2024 10:06:59 +0100 From: Markus Volk To: openembedded-devel@lists.openembedded.org Subject: [meta-oe][PATCH 3/3] gjs: update 1.80.2 -> 1.82.1 Date: Mon, 16 Dec 2024 10:07:05 +0100 Message-ID: <20241216090705.1698-3-f_l_k@t-online.de> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20241216090705.1698-1-f_l_k@t-online.de> References: <20241216090705.1698-1-f_l_k@t-online.de> MIME-Version: 1.0 X-TOI-EXPURGATEID: 150726::1734340019-99FF89DC-DDED092D/0/0 CLEAN NORMAL X-TOI-MSGID: 77230e5b-8430-435c-8da5-36fea48d8960 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Mon, 16 Dec 2024 09:07:48 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/114325 - Refresh patches Version 1.82.1 -------------- - Closed bugs and merge requests: * gnome-shell crash when switching user after upgrade from Fedora 40 to Fedora 41 [#647, !955, Philip Chimento] Version 1.82.0 -------------- - Closed bugs and merge requests: * installed tests are failing because they can't load internal typelibs from parent directory [#639, !953, Simon McVittie] * GIMarshalling test has 3 failures with 1.81.90 on i686 [#642, !954, Philip Chimento] Version 1.81.90 --------------- - Closed bugs and merge requests: * callbacks: fix sweeping check for incremental GC [!859, !950, Evan Welsh, Gary Li] * GJS doesn't handle query parameters in imports [#618, !944, Gary Li] * Integrate gobject-introspection-tests as submodule [!946, Philip Chimento] * module: Include full module specifier in import.meta.url [!947, Philip Chimento] * doap: Remove invalid maintainer entry [!948, Sophie Herold] * installed tests have the wrong libexecdir [#636, !949, Jeremy Bicha] * Inheriting final class crashes GJS [#640, !951, Gary Li] * Various maintenance [!952, Philip Chimento] Version 1.81.2 -------------- - New JavaScript features! This version of GJS is based on SpiderMonkey 128, an upgrade from the previous ESR (Extended Support Release) of SpiderMonkey 115. Here are the highlights of the new JavaScript features. For more information, look them up on MDN or devdocs.io. * New APIs + The new `Object.groupBy()` and `Map.groupBy()` static methods group the elements of an iterable according to the return value of a key function. + The new `Promise.withResolvers()` static method returns a Promise as well as its resolve and reject functions, shorthand for a common pattern used when promisifying event-based APIs. + Strings have gained the `isWellFormed()` and `toWellFormed()` methods which help when interoperating with strings that may have unpaired Unicode surrogates. This usually does not come up in the GNOME platform. + ArrayBuffers have gained the `transfer()` and `transferToFixedLength()` methods, which transfer ownership of a data buffer to a new ArrayBuffer object, without copying it, and invalidating ("detaching") any existing references to the buffer. There is also a new property, `detached`, which allows checking whether an ArrayBuffer is in the detached state. + The new `Intl.Segmenter` class allows splitting a string into graphemes, words, or sentences, in a locale-aware way. + `Intl.NumberFormat` has gained `formatRange()` and `formatRangeToParts()` methods, which allow formatting number ranges, like "3–5". + `Intl.PluralRules` has gained a `selectRange()` method, which allows selecting the proper plural form based on a range of numbers, like "30–50 feral hogs". * New behaviour + The `Intl.NumberFormat` and `Intl.PluralRules` constructors support new options: `roundingIncrement`, `roundingMode`, `roundingPriority`, and `trailingZeroDisplay`. + The `Intl.NumberFormat` constructor also supports the new option `useGrouping`. * Backwards-incompatible changes + The behaviour of `Date.parse()` has been changed to be more consistent with other JavaScript engines. (But don't use `Date.parse()`.) - Closed bugs and merge requests: * Invalid search paths cause failed assertions when printing imports.gi [#629, !935, Gary Li] * SpiderMonkey 128 [#630, !936, !945, Philip Chimento] * Pretty-printing byte array in gjs-console throws a type conversion error [#434, !937, Gary Li] * js: Add gjs_debug_callable() debug function [!940, Philip Chimento] * build: Build Cairo from subproject if not found [!941, Philip Chimento] * Bump CI image to Fedora 40 [!942, Philip Chimento] * CI tools updates [!943, Philip Chimento] Version 1.81.1 -------------- - Breaking change: When creating a GObject with the `new` operator, the constructor takes a single argument consisting of a property bag with GObject construct properties and their values. This was often confused with the `new` static method that may take arguments that are not interpreted as property bags. For example, Gio.FileIcon was one of the many affected APIs: new Gio.FileIcon({file: myFile}) vs Gio.FileIcon.new(myFile) Confusion between the two often lead to bug reports when confusing these two and calling `new Gio.FileIcon(myFile)` - the constructor would look for a nonexistent `file` property on `myFile`, causing an improperly initialized object. This is now no longer allowed. The argument to `new Gio.FileIcon(...)` must be a plain JS object, not a GObject. It's possible that existing code legitimately used a GObject here. If your code does this and a quick migration is impractical, please get in touch and we will revert this change before 1.82.0 in favour of a longer deprecation period. - The `get_data()`, `get_qdata()`, `set_data()`, `steal_data()`, `steal_qdata()`, `ref()`, `unref()`, `ref_sink()`, and `force_floating()` methods of GObject now throw if called. These methods never worked, but sometimes they would silently appear to succeed, then cause crashes or memory leaks later. If you were trying to use the `get_data()` family of methods, just set a JS property instead. If you were trying to modify the refcount of a GObject in JS, instead set the object as the value of a JS property on some other object. - Closed bugs and merge requests: * doc: Document how to get a stack trace [!864, Sonny Piers] * TextDecoder should accept GBytes [#587, !903, Sriyansh Shivam] * Possible use-after-free with GLib.Regex.match/GLib.MatchInfo [#589, !920, Philip Chimento] * method `get_line` of `Pango.Layout` doesn't work. [#547, !921, Philip Chimento] * Block calls to g_object_get_data and friends [#423, !922, Philip Chimento] * Crash when calling Pango.Layout.get_pixel_size() with a badly init:ed Pango.Layout [#580, !923, Philip Chimento] * doc: avoid reference to Gio.UnixInputStream [!925, Andy Holmes] * Add a CI check for config.h, and some other useful checks [#447, !926, Philip Chimento] * Incorrect UnixOutputStream warning [#610, !928, Philip Chimento] * Various maintenance [!929, !931, Philip Chimento] * Docs: Various markdown fixes [!930, Frank Dana] * Some build fixes for the main (and gnome-46) branches for Visual Studio [!932, Chun-wei Fan] * GJS doesn't log undefined values [#621, !933, Gary Li] * property objects are printed as empty js objects [#622, !934, Gary Li] Signed-off-by: Markus Volk --- ...01-Support-cross-builds-a-bit-better.patch | 10 +++++----- ...ot-add-dir-installed-tests-when-inst.patch | 19 ++++++++++++------- .../gjs/{gjs_1.80.2.bb => gjs_1.82.1.bb} | 4 ++-- 3 files changed, 19 insertions(+), 14 deletions(-) rename meta-gnome/recipes-gnome/gjs/{gjs_1.80.2.bb => gjs_1.82.1.bb} (90%) diff --git a/meta-gnome/recipes-gnome/gjs/gjs/0001-Support-cross-builds-a-bit-better.patch b/meta-gnome/recipes-gnome/gjs/gjs/0001-Support-cross-builds-a-bit-better.patch index 12b4b08c7e..c66d42da62 100644 --- a/meta-gnome/recipes-gnome/gjs/gjs/0001-Support-cross-builds-a-bit-better.patch +++ b/meta-gnome/recipes-gnome/gjs/gjs/0001-Support-cross-builds-a-bit-better.patch @@ -1,4 +1,4 @@ -From 8a78a7996b01aba21377ceb7547da673fd30a391 Mon Sep 17 00:00:00 2001 +From 8e7a25b0171eb60c802168593355354dff7806f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=BCller?= Date: Wed, 27 Oct 2021 20:18:47 +0200 Subject: [PATCH] Support cross builds a bit better @@ -17,10 +17,10 @@ Signed-off-by: Andreas Müller 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build -index c9b26d6..3058e8c 100644 +index f3081fc..ac958d3 100644 --- a/meson.build +++ b/meson.build -@@ -262,6 +262,7 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with +@@ -252,6 +252,7 @@ release builds of SpiderMonkey. Try configuring SpiderMonkey with --disable-debug.''') endif @@ -28,7 +28,7 @@ index c9b26d6..3058e8c 100644 # Check if a minimal SpiderMonkey program compiles, links, and runs. If not, # it's most likely the case that SpiderMonkey was configured incorrectly, for # example by building mozglue as a shared library. -@@ -292,6 +293,7 @@ elif minimal_program.returncode() != 0 +@@ -282,6 +283,7 @@ elif minimal_program.returncode() != 0 failed to execute. Most likely you should build it with a different configuration.''' + recommended_configuration) endif @@ -36,7 +36,7 @@ index c9b26d6..3058e8c 100644 have_printf_alternative_int = cc.compiles(''' #include -@@ -690,7 +692,7 @@ subdir('installed-tests') +@@ -656,7 +658,7 @@ subdir('installed-tests') # Note: The test program in test/ needs to be ported # to Windows before we can build it on Windows. diff --git a/meta-gnome/recipes-gnome/gjs/gjs/0002-meson.build-Do-not-add-dir-installed-tests-when-inst.patch b/meta-gnome/recipes-gnome/gjs/gjs/0002-meson.build-Do-not-add-dir-installed-tests-when-inst.patch index e932f06d27..bca27c33d4 100644 --- a/meta-gnome/recipes-gnome/gjs/gjs/0002-meson.build-Do-not-add-dir-installed-tests-when-inst.patch +++ b/meta-gnome/recipes-gnome/gjs/gjs/0002-meson.build-Do-not-add-dir-installed-tests-when-inst.patch @@ -1,12 +1,17 @@ -From 29221ae42e424c6100b8c313d2b61801430c872d Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20M=C3=BCller=20installed=5Ftests=20is=20false?= - +From 6a70d3ac658988dda49d51ed8b46584b716a9c7c Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= Date: Wed, 27 Oct 2021 20:04:02 +0200 Subject: [PATCH] meson.build: Do not add dir installed-tests when MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit +From: =?UTF-8?q?Andreas=20M=C3=BCller=20installed=5Ftests=20is=20false?= + +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @@ -19,12 +24,12 @@ Signed-off-by: Andreas Müller 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build -index 3058e8c..06cf8da 100644 +index ac958d3..e773508 100644 --- a/meson.build +++ b/meson.build -@@ -688,7 +688,9 @@ endif - - ### Tests and test setups ###################################################### +@@ -654,7 +654,9 @@ gi_tests = subproject('gobject-introspection-tests', + default_options: ['werror=false', 'cairo=true', + 'install_dir=@0@'.format(installed_tests_execdir)]) -subdir('installed-tests') +if get_option('installed_tests') diff --git a/meta-gnome/recipes-gnome/gjs/gjs_1.80.2.bb b/meta-gnome/recipes-gnome/gjs/gjs_1.82.1.bb similarity index 90% rename from meta-gnome/recipes-gnome/gjs/gjs_1.80.2.bb rename to meta-gnome/recipes-gnome/gjs/gjs_1.82.1.bb index 1d781d078c..c4bccbe7b0 100644 --- a/meta-gnome/recipes-gnome/gjs/gjs_1.80.2.bb +++ b/meta-gnome/recipes-gnome/gjs/gjs_1.82.1.bb @@ -3,11 +3,11 @@ LICENSE = "MIT & LGPL-2.0-or-later" LIC_FILES_CHKSUM = "file://COPYING;md5=8dcea832f6acf45d856abfeb2d51ec48" -DEPENDS = "mozjs-115 cairo" +DEPENDS = "mozjs-128 cairo" inherit gnomebase gsettings gobject-introspection gettext features_check upstream-version-is-even pkgconfig -SRC_URI[archive.sha256sum] = "135e39c5ac591096233e557cfe577d64093f5054411d47cb2e214bad7d4199bd" +SRC_URI[archive.sha256sum] = "fb39aa5636576de0e5a1171f56a1a5825e2bd1a69972fb120ba78bd109b5693c" SRC_URI += " \ file://0001-Support-cross-builds-a-bit-better.patch \ file://0002-meson.build-Do-not-add-dir-installed-tests-when-inst.patch \