summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-devtools/nodejs
Commit message (Collapse)AuthorAgeFilesLines
* nodejs: cleanupJ. S.2024-11-192-118/+0
| | | | | | | | | | | | Drop two patches which haven't been referenced by the nodejs recipe since the 20.11.0 version checkin. 0001-build-fix-build-with-Python-3.12.patch 0001-gyp-resolve-python-3.12-issues.patch Signed-off-by: Jason Schonberg <schonm@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com> (cherry picked from commit 2698039ac432d861465b84fc650fcaa8526c8a3c) Signed-off-by: Armin Kuster <akuster808@gmail.com>
* nodejs: upgrade 20.17.0 -> 20.18.0J. S.2024-11-194-3/+3
| | | | | | | | | | | | | | | | License checksum change due to whitespace changes. https://github.com/nodejs/node/commit/1dfd238781 libatomic.patch change due to changes in node.gyp https://github.com/nodejs/node/commit/25c788009f1fa7a392af51cb97d0a55f0f4a6983 Changelog : https://github.com/nodejs/node/blob/main/doc/changelogs/CHANGELOG_V20.md#20.18.0 Signed-off-by: Jason Schonberg <schonm@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com> (cherry picked from commit 410a442f89ea394710d20d337b9da397b537cc25) Signed-off-by: Armin Kuster <akuster808@gmail.com>
* nodejs: Fix build with libc++ 19Khem Raj2024-09-052-0/+183
| | | | | | | | | | | | | | | | | | | | | | | | | | | As noted in the libc++ 19 release notes [1], std::char_traits<> is now only provided for char, char8_t, char16_t, char32_t and wchar_t, and any instantiation for other types will fail. This causes nodejs-20 to fail to compile with clang 19 and libc++ 19, resulting in errors similar to: /usr/include/c++/v1/string:820:42: error: implicit instantiation of undefined template 'std::char_traits<unsigned short>' 820 | static_assert(is_same<_CharT, typename traits_type::char_type>::value, | ^ ../deps/v8/src/inspector/string-16.h:114:28: note: in instantiation of template class 'std::basic_string<unsigned short>' requested here 114 | std::basic_string<UChar> m_impl; | ^ /usr/include/c++/v1/__fwd/string.h:23:29: note: template is declared here 23 | struct _LIBCPP_TEMPLATE_VIS char_traits; | ^ Upstream v8 has fixed this in commit 182d9c05e78 [2], so add it as a backported patch, until the next version of node is released. [1] https://libcxx.llvm.org/ReleaseNotes/19.html#deprecations-and-removals [2] https://chromium.googlesource.com/v8/v8.git/+/182d9c05e78 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: upgrade 20.16.0 -> 20.17.0J. S.2024-09-013-2/+2
| | | | | | | | | | | | | | | | commit c1ddc60fd25456da07d8402c89157c4354fde5ac Author: Jason Schonberg <schonm@gmail.com> Date: Wed Aug 21 17:40:03 2024 -0400 License change - remove highlight.js https://github.com/nodejs/node/commit/1c5fe040a0a73b483cc3e3fef76efe2d1712205b Changelog : https://github.com/nodejs/node/blob/main/doc/changelogs/CHANGELOG_V20.md#20.17.0 nodejs: upgrade 20.16.0 -> 20.17.0 Signed-off-by: Jason Schonberg <schonm@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: support cross compile without qemu user conditionallyHongxu Jia2024-08-222-45/+126
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to the scope of supported BSPs by qemu-user is limited, such as a segment fault on armv9 after qemu apply commit [target/arm: Convert LDAPR/STLR (imm) to decodetree][1] ``` |tmp-glibc/work/neoversen2-crypto-wrs-linux/nodejs/20.5.1/node-v20.5.1/out/ Release/v8-qemu-wrapper.sh: line 7: 3179613 Segmentation fault (core dumped) PSEUDO_UNLOAD=1 qemu-aarch64 -r 5.15 -L tmp-glibc/work/neoversen2-crypto-wrs-linux/ nodejs/20.5.1/recipe-sysroot -E LD_LIBRARY_PATH=tmp-glibc/work/neoversen2-crypto-wrs-linux/ nodejs/20.5.1/recipe-sysroot/usr/lib64:tmp-glibc/work/neoversen2-crypto-wrs-linux/ nodejs/20.5.1/recipe-sysroot/usr/lib64 "$@" ``` Upstream nodejs have cross compile support, but it needs host and target have same bit width (e.g. a x86_64 host targeting arrch64 to produce a 64-bit binary). So: 1. If host and target have different bit width, build with QEMU user as usual; 2. If host and target have same bit width, enable notejs cross compile support: - The build tools of nodejs is GYP[2], set CC_host, CFLAGS_host, CXX_host, CXXFLAGS_host, LDFLAGS_host, AR_host for host build which is separated with target build [3] - Satisfy layer compatibility, set GYP variables in prefuncs of do_configure, do_compile and do_install other than in recipe parsing - Add missing native packages to fix library missing on host build - Rework libatomic.patch, explicitly link to libatomic for clang conditionally [1] https://github.com/qemu/qemu/commit/2521b6073b7b4b505533a941d4f9600f7585dc78 [2] https://github.com/nodejs/node-gyp [3] https://github.com/nodejs/node-gyp/blob/main/gyp/docs/UserDocumentation.md#cross-compiling Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: upgrade 20.13.0 -> 20.16.0Jason Schonberg2024-08-093-1/+1
| | | | | Signed-off-by: Jason Schonberg <schonm@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* recipes: ignore various issues fatal with gcc-14Martin Jansa2024-07-081-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | work arounds for: meta-oe/meta-oe/recipes-devtools/nodejs/nodejs_20.12.2.bb:do_compile meta-oe/meta-oe/recipes-support/pidgin/pidgin_2.14.2.bb:do_compile meta-oe/meta-oe/recipes-devtools/uw-imap/uw-imap_2007f.bb:do_compile meta-oe/meta-oe/recipes-extended/rrdtool/rrdtool_1.8.0.bb:do_compile meta-oe/meta-oe/recipes-extended/cmpi-bindings/cmpi-bindings_1.0.4.bb:do_compile meta-oe/meta-python/recipes-devtools/python/python3-gevent_24.2.1.bb:do_compile meta-oe/meta-oe/recipes-support/avro/avro-c++_1.11.3.bb:do_compile meta-oe/meta-python/recipes-devtools/python/python3-h5py_3.10.0.bb:do_compile meta-oe/meta-oe/recipes-multimedia/cdrkit/cdrkit_1.1.11.bb:do_compile meta-oe/meta-networking/recipes-connectivity/openthread/ot-br-posix_git.bb:do_compile meta-oe/meta-oe/recipes-devtools/heaptrack/heaptrack_1.2.0.bb:do_configure meta-oe/meta-oe/recipes-support/avro/avro-c_1.11.3.bb:do_compile meta-oe/meta-oe/recipes-core/usleep/usleep_1.2.bb:do_compile meta-oe/meta-networking/recipes-protocols/openflow/openflow_git.bb:do_compile meta-oe/meta-oe/recipes-extended/sblim-sfcc/sblim-sfcc_2.2.8.bb:do_compile meta-oe/meta-networking/recipes-support/linux-atm/linux-atm_2.5.2.bb:do_compile meta-oe/meta-oe/recipes-kernel/ipmitool/ipmitool_1.8.19.bb:do_compile meta-oe/meta-networking/recipes-support/ssmping/ssmping_0.9.1.bb:do_compile meta-oe/meta-oe/recipes-connectivity/wifi-test-suite/wifi-test-suite_10.10.1.bb:do_compile meta-oe/meta-oe/recipes-extended/zsync/zsync-curl_git.bb:do_compile meta-oe/meta-python/recipes-devtools/python/python3-kivy_2.3.0.bb:do_compile meta-oe/meta-oe/recipes-support/openct/openct_0.6.20.bb:do_compile meta-oe/meta-oe/recipes-benchmark/dhrystone/dhrystone_2.1.bb:do_compile meta-oe/meta-networking/recipes-daemons/ncftp/ncftp_3.2.7.bb:do_compile meta-oe/meta-oe/recipes-support/daemontools/daemontools_0.76.bb:do_compile meta-oe/meta-oe/recipes-devtools/libgee/libgee_0.20.6.bb:do_compile meta-oe/meta-oe/recipes-devtools/mcpp/mcpp_2.7.2.bb:do_compile meta-oe/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb:do_compile meta-oe/meta-networking/recipes-connectivity/dibbler/dibbler_git.bb:do_compile meta-oe/meta-oe/recipes-devtools/glade/glade_3.22.2.bb:do_compile http://errors.yoctoproject.org/Errors/Build/183124/ Signed-off-by: Martin Jansa <martin.jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs-oe-cache-native: use UNPACKDIRMartin Jansa2024-05-231-1/+4
| | | | | | | | | | | | | * oe-npm-cache is now in UNPACKDIR not WORKDIR * fixes: http://errors.yoctoproject.org/Errors/Details/771012/ /OE/build/oe-core/tmp-glibc/work/x86_64-linux/nodejs-oe-cache-native/20.13/temp/run.do_configure.1268826: line 142: /OE/build/oe-core/tmp-glibc/work/x86_64-linux/nodejs-oe-cache-native/20.13/oe-npm-cache: No such file or directory * set S and UNPACKDIR to avoid this as well: WARNING: nodejs-oe-cache-native-20.13-r0 do_unpack: nodejs-oe-cache-native: the directory ${WORKDIR}/${BP} (/OE/build/oe-core/tmp-glibc/work/x86_64-linux/nodejs-oe-cache-native/20.13/nodejs-oe-cache-20.13) pointed to by the S variable doesn't exist - please set S within the recipe to point to where the source has been unpacked to Signed-off-by: Martin Jansa <martin.jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Upgrade to 20.13.0 releaseKhem Raj2024-05-093-2/+2
| | | | | | | | | | | nodejs release notes [1] License-Update: Copyright year changed for Unicode License [2] [1] https://nodejs.org/en/blog/release/v20.13.0 [2] https://github.com/nodejs/node/commit/d5a316f5ea3fade3140c2ae35c144b500fb5d758 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs-oe-cache: fix offline install of dependenciesMartin Hundebøll2024-05-031-1/+1
| | | | | | | | | | | | | | | | | | | Apparently, npm has changed its request accept header, so that cache lookup misses. This causes an ENOTCACHED error when doing the offline install in do_compile() from npm.bbclass. Fix it by updating the fake cache entry to match the newest behaviour from npm. Note that npm doesn't agree with itself, as it still uses the previous header value when doing `npm cache add <pkg>`, but the new value when doing `npm install <pkg>`. Bug submitted upstream: https://github.com/npm/cli/issues/7465 Signed-off-by: Martin Hundebøll <martin@geanix.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: upgrade 20.11.1 -> 20.12.2Archana Polampalli2024-04-293-2/+2
| | | | | | | | | | | | | | | | | | License-Update: Copyright year updated zlib version updated GN files License update https://github.com/nodejs/node/commit/b5bc597871ca701bab750c46d31ed626decd7f89 https://github.com/nodejs/node/commit/c8233912e9fd7464898b549d6762130722bf0bf4 Changelog: https://github.com/nodejs/node/releases/tag/v20.12.2 https://github.com/nodejs/node/releases/tag/v20.12.1 https://github.com/nodejs/node/releases/tag/v20.12.0 Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: don't always disable io_uringChangqing Li2024-04-112-36/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | The original idea was always disable io_uring to avoid follwing failure even when UV_USE_IO_URING is set to true, refer [1][2]: 0608: try: *** 0609: update_hash(" %10s" % pwd.getpwuid(s.st_uid).pw_name) 0610: update_hash(" %10s" % grp.getgrgid(s.st_gid).gr_name) 0611: except KeyError as e: 0612: msg = ("KeyError: %s\nPath %s is owned by uid %d, gid %d, which doesn't match " 0613: "any user/group on target. This may be due to host contamination." % Exception: Exception: KeyError: 'getpwuid(): uid not found: 20561' But since 20.11.1, for fix CVE-2024-22017, io_uring is disabled by default, refer [3]. So maybe patch 0001-deps-disable-io_uring-support-in-libuv.patch is not needed. For case UV_USE_IO_URING is set to true, user can fix above failure by "chown root:root -R ${D}" in do_install. [1] https://lists.openembedded.org/g/openembedded-devel/message/105583 [2] https://bugzilla.yoctoproject.org/show_bug.cgi?id=15244 [3] https://github.com/nodejs/node/commit/686da19abbb83b7e01d48be19f832ab081b87084 [4] https://nvd.nist.gov/vuln/detail/CVE-2024-22017 Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: upgrade 20.11.0 -> 20.11.1Changqing Li2024-03-044-5220/+37
| | | | | | | | | | | | | Drop patches for revert io_uring support in libuv: 0001-Revert-io_uring-changes-from-libuv-1.46.0.patch 0002-Revert-io_uring-changes-from-libuv-1.45.0.patch Change to just always disable io_uring in libuv, in this way, we don't have to pick out io_uring related changes and revert them when internal libuv upgraded. Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: update to latest v20 version 20.11.0Archana Polampalli2024-02-143-4/+2
| | | | | | | | | | | | | | | | | | | | | License-Update: update c-ares to 1.20.0 [1] Copyright update [2] Removed below patches as these are availbe in 20.11.0 0001-build-fix-build-with-Python-3.12.patch [3] 0001-gyp-resolve-python-3.12-issues.patch [4] Changelog: https://github.com/nodejs/node/releases/tag/v20.11.0 [1] https://github.com/nodejs/node/commit/b705e19a95b5fc5a2edc9fc11a7649d6eb32d70b [2] https://github.com/nodejs/node/commit/347e1dd06a5f927d9fd64ce72d776c56d5101910 [3] https://github.com/nodejs/node/commit/0a5e9c12cf961a56bd63005974b953bbc0bc62a7 [4] https://github.com/nodejs/node/commit/68ec1e5eeb4ff984868c625f0ce808210169360d Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Set CVE_PRODUCT to "node.js"virendra thakur2024-02-091-0/+2
| | | | | | | Set CVE_PRODUCT to 'node.js' for nodjs recipe Signed-off-by: virendra thakur <virendrak@kpit.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: backport (partially) python 3.12 supportAlexander Kanavin2023-12-213-1/+121
| | | | | Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* Revert "nodejs: backport (partially) python 3.12 support"Khem Raj2023-12-203-121/+1
| | | | This reverts commit f4bf27dbdb751aa146c9c23fc436358a2cc01d9b.
* nodejs: backport (partially) python 3.12 supportAlexander Kanavin2023-12-183-1/+121
| | | | | Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Revert io_uring support from bundled libuv-1.46.0Martin Jansa2023-10-193-0/+5219
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Pseudo fails to intercept some of the syscalls used by the new version as documented in: https://github.com/shr-project/com.webos.app.minimal/tree/recipes Now we have 3 options: 1) every use of nodejs-native where io_uring might be used (like in webpack) needs to export UV_USE_IO_URING=0 before using node, but be aware that the PR says it's only temporary and this variable might be removed in future. Unfortunately many people are lucky enough not to know what pseudo even is, so they might not realize that host-user-contamination QA issues or "KeyError: 'getpwuid(): uid not found" might be related to this (and they probably won't find this e-mail as well: https://lists.openembedded.org/g/openembedded-devel/message/105583 2) revert the io_uring changes from bundled libuv, to make sure it stays disabled. The changes are massive and it will be PIA to update them for every nodejs release I've already separated them for nodejs-20.3.0 where I've initialy tested this on top of libuv-1.45.0 and for 20.4.0 this need another patch for changes from libuv-1.46.0. Patch for keeping UV_USE_IO_URING support after it's removed from upstream libuv will be much smaller, but PIA to use UV_USE_IO_URING whenever using nodejs-native during build. 3) fix pseudo to correctly work with io_uring calls, definitely best long-term solution as more and more tools will now switch to io_uring, but without active maintainer of pseudo it might be _very_ difficult to implement this and there aren't many people willing to touch this beast. Signed-off-by: Martin Jansa <martin.jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: update to latest v20 version 20.8.1Martin Jansa2023-10-181-2/+2
| | | | | | | | | | | | | | | | * updates to latest v20 version * LIC_FILES_CHKSUM changed due to small Copyright update from: https://github.com/nodejs/node/commit/660da785e687ab0517397616a9e55b5782582ff5 * this still doesn't resolve the issue with pseudo reported in: https://lists.openembedded.org/g/openembedded-devel/message/105308 and further debugged in: https://github.com/shr-project/com.webos.app.minimal/tree/recipes which shows that it's easily reproducible with plain webpack "Hello world". Signed-off-by: Martin Jansa <martin.jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Fix ptest result reportingKhem Raj2023-10-021-0/+5
| | | | | | | | | This fixes AssertionError:- ptests which had no test results: ['nodejs'] Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: upgrade 18.17.1 -> 20.5.1Archana Polampalli2023-09-288-125/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update to latest release of latest LTS 20 release * node v20 introduces several new features and fixes many bugs and CVEs as shown in [1] * Refresh 0001-liftoff-Correct-function-signatures.patch against 20.5.1 * License-Update: - Change zlib version 1.2.13, October 13th, 2022 to version 1.2.13.1, October xxth, 2022 [2] - Change Copyright 2023 from Ada authors to Yagiz Nizipli and Daniel Lemire [4] * Remove big-endian.patch as it is merged in v20.x [5] [6] * Remove below list of patches since mips32 is deleted from v8 as part of update V8 to 10.7.193.13 [7] [8] - mips-less-memory.patch - 0001-mips-Use-32bit-cast-for-operand-on-mips32.patch * Update Using-native-binaries.patch for node_js2c, it resolved below do_compile error [9] Error: /bin/sh: line 1: build/tmp/work/core2-64-poky-linux/nodejs/20.5.1/node-v20.5.1/out/Release/node_js2c: No such file or directory * Remove obsolete dtrace & etw configure options (we had: --without-<feature>) from the recipe [10] https://github.com/nodejs/node/releases/tag/v20.5.1 [1] https://github.com/nodejs/node/blob/main/doc/changelogs/CHANGELOG_V20.md [2] https://github.com/nodejs/node/commit/f1007325753e62b13083f6e9e499fdc33f753d7d [3] https://github.com/nodejs/node/commit/900ae1bda76caaa7213431a5268560b578ed2d55 [4] https://github.com/nodejs/node/commit/d2465369243bc4313d9840b62c2393c4f179ffbb [5] https://github.com/v8/v8/commit/3cea5d5425c3a0d7d1768b3758269ac98875de77 [6] https://github.com/nodejs/node/commit/f226350fcbebd4449fb0034fdaffa147e4de28ea [7] https://github.com/v8/v8/commit/a26ca5ed147dde47f02d70c5b38d8befc1c93cb3 [8] https://github.com/nodejs/node/commit/6bd756d7c6dfb7dc25daee329ad70df68c14223e [9] https://github.com/nodejs/node/commit/4da7bc915c714989eba7eab753db9eb9ebd8451a [10] https://github.com/nodejs/node/commit/aa3a572e6bee116cde69508dc29478b40f40551a Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: upgrade 18.17.0 -> 18.17.1Archana Polampalli2023-08-281-1/+1
| | | | | | | | | | | | | This is a security release. The following CVEs are fixed in this release: CVE-2023-32002 CVE-2023-32006 CVE-2023-32559 https://github.com/nodejs/node/releases/tag/v18.17.1 Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Upgrade to 18.17.0Khem Raj2023-08-053-2/+2
| | | | | | | | | | | | Update to latest release of latest LTS 18 release License-Update: [1] [2] [3] [1] https://github.com/nodejs/node/commit/0cfdb3affa518bf55cfd8120f0286099fabfb22a [2] https://github.com/nodejs/node/commit/2ea6e030038d86376dea748f702ed14018f99aba [3] https://github.com/nodejs/node/commit/261e1d23d11053b373ea51745f6c1187440c2b08 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: use PIE for host binariesMartin Jansa2023-06-281-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * mksnapshot is built as host binary, but then gets executed under qemu-arm, because for 32bit target we need to run 32bit mksnapshot even when building on x86-64 host * unfortunately since upgrade to qemu-8 in: https://git.openembedded.org/openembedded-core/commit/?id=fe8125565af07b73f9b29db2188ecb6e884bcc70 the mksnapshot fails to execute with: LD_LIBRARY_PATH=/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/lib.host:/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/lib.target:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH; cd ../tools/v8_gypfiles; mkdir -p /OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/obj.target/v8_snapshot/geni; "/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/v8-qemu-wrapper.sh" "/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/mksnapshot" --turbo_instruction_scheduling "--target_os=linux" "--target_arch=arm" --startup_src "/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/obj.target/v8_snapshot/geni/snapshot.cc" --embedded_variant Default --embedded_src "/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/obj.target/v8_snapshot/geni/embedded.S" --no-native-code-counters # # Fatal process OOM in Failed to reserve virtual memory for CodeRange # /OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/node-v18.16.0/out/Release/v8-qemu-wrapper.sh: line 7: 669880 Trace/breakpoint trap (core dumped) PSEUDO_UNLOAD=1 qemu-arm -r 5.15 -L /OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/recipe-sysroot -E LD_LIBRARY_PATH=/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/recipe-sysroot/usr/lib:/OE/build/oe-core/tmp-glibc/work/cortexa8t2hf-neon-oe-linux-gnueabi/nodejs/18.16.0-r0/recipe-sysroot/lib "$@" It was failing only in some of my builds first, in the end I was able to narrow the difference between the build where it fails and where it doesn't fail to require conf/distro/include/security_flags.inc then GCCPIE = "--enable-default-pie" and lastly this PIE enabled just for nodejs to work around this issue without downgrading qemu-native. * using -strace with qemu doesn't help much, just confirms that the OOM error message is really caused by failed mmap2: --- SIGPROF {si_signo=SIGPROF, si_code=SI_TKILL, si_pid=2908258, si_uid=1026} --- clock_gettime64(CLOCK_MONOTONIC,0x407ef640) = 0 ({tv_sec=20187,tv_nsec=678404286}) rt_sigreturn(0x407efb70) = -1 errno=513 (Successful exit from sigreturn) write(3,0x141e538,28) = 28 write(3,0x141e538,28) = 28 write(3,0x141e538,32) = 32 mmap2(0x0097a000,33554432,PROT_NONE,MAP_PRIVATE|MAP_ANONYMOUS|MAP_NORESERVE,-1,0) = -1 errno=12 (Cannot allocate memory) mmap2(0x0097a000,33554432,PROT_NONE,MAP_PRIVATE|MAP_ANONYMOUS|MAP_NORESERVE,-1,0) = -1 errno=12 (Cannot allocate memory) * diffoscope on this 1.7G binary didn't really help as it got killed by OOMK after a while Out of memory: Killed process 1136999 (diffoscope) total-vm:404300108kB, anon-rss:122594688kB, file-rss:512kB, shmem-rss:0kB, UID:1026 pgtables:764240kB oom_score_adj:0 Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* *.patch: add Upstream-Status to all patchesMartin Jansa2023-06-211-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is new patch-status QA check in oe-core: https://git.openembedded.org/openembedded-core/commit/?id=76a685bfcf927593eac67157762a53259089ea8a This is temporary work around just to hide _many_ warnings from optional patch-status (if you add it to WARN_QA). This just added Upstream-Status: Pending everywhere without actually investigating what's the proper status. This is just to hide current QA warnings and to catch new .patch files being added without Upstream-Status, but the number of Pending patches is now terrible: 5 (26%) meta-xfce 6 (50%) meta-perl 15 (42%) meta-webserver 21 (36%) meta-gnome 25 (57%) meta-filesystems 26 (43%) meta-initramfs 45 (45%) meta-python 47 (55%) meta-multimedia 312 (63%) meta-networking 756 (61%) meta-oe Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Upgrade to 18.16.0Khem Raj2023-05-104-3/+3
| | | | | | | | | | | License-Update: Add missing licenses for Ada [1] BSD, Simduf [2] BSD, posteject [3] MIT [1] https://github.com/nodejs/node/commit/0bc4c17e5705ea042cda392343d7301bb91873ed [2] https://github.com/nodejs/node/commit/c9845fc3341fcdce298ad7f1630e329d71a6e746 [3] https://github.com/nodejs/node/commit/4aaec0726694ad0d3cb05d7f2593a90363c32f32 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* Nodejs: add missing run_ptest scriptArchana Polampalli2023-03-252-0/+4
| | | | | | | ptest-runner is not available for Nodejs on target hence added run-ptest script Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: package-split between nodejs and nodejs-npmJan Feemers2023-03-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | The nodejs package contains a symbolic link `/usr/bin/corepack` to a file from the nodejs-npm package. ```shell build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/packages-split/nodejs/usr/bin$ ls -l total 31932 lrwxrwxrwx 1 jan jan 45 Feb 21 05:08 corepack -> ../lib/node_modules/corepack/dist/corepack.js -rwxr-xr-x 2 jan jan 32694304 Feb 21 05:08 node build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/packages-split/nodejs-npm/usr/lib/node_modules/corepack/dist$ ls -l total 2428 -rwxr-xr-x 2 jan jan 614216 Feb 21 05:08 corepack.js ``` Due to the link, the build system detects a dependency from package `nodejs` to package `nodejs-npm`. Since the `nodejs-npm` package depends on plenty more packages the link should be moved to the `nodejs-npm` package. Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Depend on file-nativeKhem Raj2023-03-141-1/+3
| | | | | | | | | | | | | | | | | | | | | | | Some older distribution e.g. alma8 has a version of file utility which is version 5.33 but more importantly missing this patch [1] from version 5.40 which causes package failures in wasm files e.g. ERROR: nodejs-18.14.2-r0 do_package: Fatal errors occurred in subprocesses: Command '['file', '-b', '/home/pokybuild/yocto-worker/meta-oe/build/build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/package/usr/lib/nodejs/ptest/test/wasi/wasm/write_file.wasm']' returned non-zero exit status 1. Subprocess output:ERROR: Bad magic format `version %#x (MVP)' (bad format char: #) Command '['file', '-b', '/home/pokybuild/yocto-worker/meta-oe/build/build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/package/usr/lib/nodejs/ptest/test/wasi/wasm/symlink_loop.wasm']' returned non-zero exit status 1. Subprocess output:ERROR: Bad magic format `version %#x (MVP)' (bad format char: #) Command '['file', '-b', '/home/pokybuild/yocto-worker/meta-oe/build/build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/package/usr/lib/nodejs/ptest/test/wasi/wasm/notdir.wasm']' returned non-zero exit status 1. Subprocess output:ERROR: Bad magic format `version %#x (MVP)' (bad format char: #) Command '['file', '-b', '/home/pokybuild/yocto-worker/meta-oe/build/build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/package/usr/lib/nodejs/ptest/test/wasi/wasm/preopen_populates.wasm']' returned non-zero exit status 1. Subprocess output:ERROR: Bad magic format `version %#x (MVP)' (bad format char: #) Command '['file', '-b', '/home/pokybuild/yocto-worker/meta-oe/build/build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/package/usr/lib/nodejs/ptest/test/wasi/wasm/clock_getres.wasm']' returned non-zero exit status 1. Subprocess output:ERROR: Bad magic format `version %#x (MVP)' (bad format char: #) Command '['file', '-b', '/home/pokybuild/yocto-worker/meta-oe/build/build/tmp/work/core2-64-poky-linux/nodejs/18.14.2-r0/package/usr/lib/nodejs/ptest/test/wasi/wasm/main_args.wasm']' returned non-zero exit status 1. [1] https://github.com/file/file/commit/85b7ab83257b3191a1a7ca044589a092bcef2bb3 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Upgrade to 18.14.2Khem Raj2023-03-045-78/+5
| | | | | | | | | License-Update: Add base64 license information [1] and postject [2] [1] https://github.com/nodejs/node/commit/2ec8092e2cf70267e765dfe4baf13d72838a58ed [2] https://github.com/nodejs/node/commit/4aaec0726694ad0d3cb05d7f2593a90363c32f32 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: remove redundant commentRoss Burton2023-02-241-2/+0
| | | | | | | This commented-out assignment should have been removed in 3ff0235. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: no need to stage binaries for targetRoss Burton2023-02-221-13/+0
| | | | | | | | Target nodejs doesn't depend on nodejs-native to build anymore, so there is no need to stage these binaries. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: remove LD assignmentRoss Burton2023-02-221-2/+2
| | | | | | | | | | | The purpose of this appears to have been lost, and the build succeeds without it. If it is needed, then it should be added to EXTRA_OEMAKE alongside the CC and CXX assignments. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: don't force cross-compilation in native buildsRoss Burton2023-02-221-1/+5
| | | | | | | | | | By not forcing the cross-compile build logic in native builds the build is a _lot_ faster. Walltime in buildstats-diff on my machine: nodejs-native do_compile -475.6s -41.2% 1153.4s -> 677.7s Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: use a postfunc to prune source treeRoss Burton2023-02-221-2/+2
| | | | | | | | Instead of overriding do_unpack entirely and calling into base_do_unpack, use a postfunc. This keeps the prune logic separated neatly. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: run configure.py in verbose modeRoss Burton2023-02-221-1/+1
| | | | | | | It's useful to know what configure is detecting, so pass --verbose. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: remove redundant expand=True to getVar()Ross Burton2023-02-221-6/+6
| | | | | | | The expand argument defaults to True, so there's no need to specify it. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: add Upstream-StatusMartin Jansa2023-02-183-0/+38
| | | | | | | | * unfortunately all 3 have very long unclear history, I've tried to at least partially document in commit message Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: fix do_install failure with 'shared' PACKAGECONFIGMartin Jansa2023-02-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * tools/install.py uses: output_lib = 'libnode.' + variables.get('shlib_suffix') action([output_prefix + output_lib], variables.get('libdir') + '/'+ output_lib) and when libdir is absolute path (either ${D}${libdir} before: https://git.openembedded.org/meta-openembedded/commit/?id=42c0f0120ad1caf25118d079314c988d4633a437 or just ${libdir} "/usr/lib") it doesn't respect prefix nor ${D} and fails to write to host's directory when "shared" PACKAGECONFIG is enabled: http://errors.yoctoproject.org/Errors/Details/689959/ if [ ! -r node ] || [ ! -L node ]; then \ ln -fs out/Release/node node; fi TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/recipe-sysroot-native/usr/bin/python3-native/python3 tools/install.py install 'TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/image' '/usr' installing TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/image/usr/bin/node installing /usr/lib/libnode.so.108 Traceback (most recent call last): File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/node-v18.12.1/tools/install.py", line 351, in <module> run(sys.argv[:]) File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/node-v18.12.1/tools/install.py", line 342, in run files(install) File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/node-v18.12.1/tools/install.py", line 179, in files action([output_prefix + output_lib], variables.get('libdir') + '/' + output_lib) File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/node-v18.12.1/tools/install.py", line 77, in install try_copy(path, dst) File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/node-v18.12.1/tools/install.py", line 67, in try_copy return shutil.copy2(source_path, target_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/recipe-sysroot-native/usr/lib/python3.11/shutil.py", line 436, in copy2 copyfile(src, dst, follow_symlinks=follow_symlinks) File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/nodejs/18.12.1-r0/recipe-sysroot-native/usr/lib/python3.11/shutil.py", line 258, in copyfile with open(dst, 'wb') as fdst: ^^^^^^^^^^^^^^^ PermissionError: [Errno 13] Permission denied: '/usr/lib/libnode.so.108' make: *** [Makefile:189: install] Error 1 * use just baselib "lib" so that it respects ${D} as well as ${prefix} while using e.g. lib32 or lib64 when multilib is enabled * similarly as 'node' binary is installed to relative hardcoded path "bin" with: action([output_prefix + output_file], 'bin/' + output_file) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* Nodejs: fix buildpaths warningArchana Polampalli2023-02-081-1/+1
| | | | | | | | | | | | | Correct libdir used at configure time to avoid packaging warnings WARNING: nodejs-18.12.1-r0 do_package_qa: QA Issue: File /usr/bin/node in package nodejs contains reference to TMPDIR [buildpaths] File /usr/bin/.debug/node in package nodejs-dbg contains reference to TMPDIR File /usr/lib64/nodejs/ptest/.debug/cctest in package nodejs-dbg contains reference to TMPDIR [buildpaths] File /usr/lib64/nodejs/ptest/cctest in package nodejs-ptest contains reference to TMPDIR [buildpaths] File /usr/include/node/config.gypi in package nodejs-dev contains reference to TMPDIR [buildpaths] Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: add CVE_PRODUCTChen Qi2023-02-071-0/+2
| | | | | | | | Some old nodejs CVEs use 'nodejs', and recent nodejs CVEs use 'node.js'. Add CVE_PRODUCT to include both. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* meta: remove True option to getVar calls (again)Martin Jansa2023-02-011-1/+1
| | | | | | | | | | | | | * True is default since 2016 and most layers were already updated not to pass this parameter where not necessary, e.g. oe-core was updated couple times, first in: https://git.openembedded.org/openembedded-core/commit/?id=7c552996597faaee2fbee185b250c0ee30ea3b5f Updated with the same regexp as later oe-core update: https://git.openembedded.org/openembedded-core/commit/?id=9f551d588693328e4d99d33be94f26684eafcaba Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Fix build with gcc13Khem Raj2023-02-012-0/+71
| | | | Signed-off-by: Khem Raj <raj.khem@gmail.com>
* Nodejs: Upgrade to 18.12.1Archana Polampalli2023-01-255-29/+42
| | | | | | | | | | | | | | | | | | | | | Node-18 is the current LTS release, node-19 is a development release and node-20 is scheduled to be released until 2023-04-18 which is too late for YP-4.2 https://github.com/nodejs/release * Refresh below two patches - 0001-Using-native-binaries.patch - 0001-liftoff-Correct-function-signatures.patch * Copy openssl.cnf from sysroot_native to nodejs-openssl.cnf otherwise do_compile failed: make[1]: *** No rule to make target '../deps/openssl/nodejs-openssl.cnf', needed by 'Release/obj.target/deps/openssl/openssl.cnf'. Stop. * Add initial ptest support using ctest only, it covered 20% of the nodejs tests. There are some more tests exist to add but will require additional work. Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* Nodejs - Upgrade to 16.18.1Archana Polampalli2022-11-186-268/+27
| | | | | | | | | * Drop Openssl legacy provider patch and install both binaries patch which are already available in 16.x * Refresh native binaries patch against 16.x base Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs-oe-cache-native: initial checkinEnrico Scholz2022-05-202-0/+98
| | | | | | | | | | | | | This implements an 'npm cache add' like functionality but allows to specify the key of the data and sets metadata which are required to find the data. It is used to cache information as done during 'npm install'. Keyformat and metadata are nodejs version specific. Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Upgrade to 16.14.2Khem Raj2022-04-202-1/+36
| | | | | | Fix build with mips32, found with gcc12 Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: Disable for powerpcKhem Raj2022-03-141-0/+1
| | | | | | | Fixes ../deps/v8/src/objects/code.h:564:2: error: #error Unknown architecture. Signed-off-by: Khem Raj <raj.khem@gmail.com>
* nodejs: add option to use openssl legacy providers againAndrej Valek2022-03-092-0/+152
| | | | | | | | | | | | | | | Current nodejs version v16 does not fully support new OpenSSL, so add option to use legacy provider. | opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ], | library: 'digital envelope routines', | reason: 'unsupported', | code: 'ERR_OSSL_EVP_UNSUPPORTED' It was blindly removed by upgrade to 16.14.0 version Signed-off-by: Andrej Valek <andrej.valek@siemens.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>