pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/lang/nodejs18



Module Name:    pkgsrc
Committed By:   adam
Date:           Sat Dec  3 16:59:22 UTC 2022

Added Files:
        pkgsrc/lang/nodejs18: DESCR Makefile PLIST buildlink3.mk distinfo
        pkgsrc/lang/nodejs18/patches: patch-common.gypi
            patch-deps_cares_cares.gyp patch-deps_uv_common.gypi
            patch-deps_uvwasi_include_wasi__serdes.h
            patch-deps_v8_src_base_platform_platform-freebsd.cc
            patch-deps_v8_src_base_platform_platform-openbsd.cc
            patch-deps_v8_src_base_platform_platform-posix.cc
            patch-deps_v8_src_base_platform_semaphore.cc
            patch-deps_v8_src_base_strings.h
            patch-deps_v8_src_codegen_arm_cpu-arm.cc
            patch-deps_v8_src_common_globals.h
            patch-deps_v8_src_compiler_types.h
            patch-deps_v8_src_heap_code-range.cc
            patch-deps_v8_tools_run-llprof.sh patch-node.gypi
            patch-src_crypto_crypto__rsa.cc patch-src_inspector__agent.cc
            patch-src_node__postmortem__metadata.cc
            patch-tools_gyp_pylib_gyp_generator_make.py
            patch-tools_gyp_pylib_gyp_xcode__emulation.py
            patch-tools_install.py patch-tools_v8_gypfiles_v8.gyp

Log Message:
nodejs18: moved from nodejs, version 18.2.1


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 pkgsrc/lang/nodejs18/DESCR \
    pkgsrc/lang/nodejs18/Makefile pkgsrc/lang/nodejs18/PLIST \
    pkgsrc/lang/nodejs18/buildlink3.mk pkgsrc/lang/nodejs18/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/lang/nodejs18/patches/patch-common.gypi \
    pkgsrc/lang/nodejs18/patches/patch-deps_cares_cares.gyp \
    pkgsrc/lang/nodejs18/patches/patch-deps_uv_common.gypi \
    pkgsrc/lang/nodejs18/patches/patch-deps_uvwasi_include_wasi__serdes.h \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-freebsd.cc \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-openbsd.cc \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-posix.cc \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_semaphore.cc \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_strings.h \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_codegen_arm_cpu-arm.cc \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_common_globals.h \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_compiler_types.h \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_heap_code-range.cc \
    pkgsrc/lang/nodejs18/patches/patch-deps_v8_tools_run-llprof.sh \
    pkgsrc/lang/nodejs18/patches/patch-node.gypi \
    pkgsrc/lang/nodejs18/patches/patch-src_crypto_crypto__rsa.cc \
    pkgsrc/lang/nodejs18/patches/patch-src_inspector__agent.cc \
    pkgsrc/lang/nodejs18/patches/patch-src_node__postmortem__metadata.cc \
    pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_generator_make.py \
    pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_xcode__emulation.py \
    pkgsrc/lang/nodejs18/patches/patch-tools_install.py \
    pkgsrc/lang/nodejs18/patches/patch-tools_v8_gypfiles_v8.gyp

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Added files:

Index: pkgsrc/lang/nodejs18/DESCR
diff -u /dev/null pkgsrc/lang/nodejs18/DESCR:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/DESCR  Sat Dec  3 16:59:22 2022
@@ -0,0 +1,4 @@
+Node.js is an evented I/O framework for the V8 JavaScript engine. It is
+intended for writing scalable network programs such as web servers.
+
+This package holds the 18.x LTS release.
Index: pkgsrc/lang/nodejs18/Makefile
diff -u /dev/null pkgsrc/lang/nodejs18/Makefile:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/Makefile       Sat Dec  3 16:59:22 2022
@@ -0,0 +1,55 @@
+# $NetBSD: Makefile,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+DISTNAME=      node-v18.12.1
+EXTRACT_SUFX=  .tar.xz
+
+USE_LANGUAGES= c gnu++17
+
+BUILD_DEPENDS+=        ${PYPKGPREFIX}-expat>=0:../../textproc/py-expat
+
+.include "../../mk/bsd.prefs.mk"
+
+# XXX: figure out a way to add rpaths to torque
+MAKE_ENV+=     LD_LIBRARY_PATH=${PREFIX}/lib
+
+CONFIGURE_ARGS+=       --shared-brotli
+CONFIGURE_ARGS+=       --shared-nghttp2
+CONFIGURE_ARGS+=       --with-intl=system-icu
+
+PYTHON_VERSIONS_INCOMPATIBLE=  27 311
+
+CHECK_PORTABILITY_SKIP+=       deps/v8/tools/cppgc/export_to_github.sh
+CHECK_PORTABILITY_SKIP+=       deps/v8/tools/cppgc/test_cmake.sh
+CHECK_PORTABILITY_SKIP+=       tools/macos-installer/pkgbuild/npm/scripts/preinstall
+
+REPLACE_NODEJS+=               deps/corepack/dist/*.js
+.include "../../lang/nodejs/application.mk"
+CHECK_INTERPRETER_SKIP+=       lib/node_modules/corepack/shims/*.ps1
+
+.if ${MACHINE_ARCH} == "i386"
+# required for SSE2 code under i386.
+CXXFLAGS+=     -mstackrealign
+.endif
+
+.PHONY: minusx
+post-install: minusx
+minusx:
+       ${CHMOD} -x ${DESTDIR}${PREFIX}/lib/node_modules/corepack/shims/*.cmd
+
+.include "../../lang/nodejs/options.mk"
+
+# Node turns on -latomic for arm, mips and ppc.
+.if ${MACHINE_ARCH:M*arm*} || \
+    ${MACHINE_ARCH:M*powerpc*} || \
+    ${MACHINE_ARCH:M*mips*}
+.include "../../devel/libatomic/buildlink3.mk"
+.endif
+
+.include "../../lang/nodejs/Makefile.common"
+.include "../../archivers/brotli/buildlink3.mk"
+.include "../../textproc/icu/buildlink3.mk"
+# Requires nghttp2_option_set_max_settings
+BUILDLINK_API_DEPENDS.nghttp2+=        nghttp2>=1.41.0
+.include "../../www/nghttp2/buildlink3.mk"
+.include "../../mk/atomic64.mk"
+.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/lang/nodejs18/PLIST
diff -u /dev/null pkgsrc/lang/nodejs18/PLIST:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/PLIST  Sat Dec  3 16:59:22 2022
@@ -0,0 +1,125 @@
+@comment $NetBSD: PLIST,v 1.1 2022/12/03 16:59:22 adam Exp $
+bin/corepack
+bin/node
+include/node/common.gypi
+include/node/config.gypi
+include/node/cppgc/common.h
+include/node/js_native_api.h
+include/node/js_native_api_types.h
+include/node/libplatform/libplatform-export.h
+include/node/libplatform/libplatform.h
+include/node/libplatform/v8-tracing.h
+include/node/node.h
+include/node/node_api.h
+include/node/node_api_types.h
+include/node/node_buffer.h
+include/node/node_object_wrap.h
+include/node/node_version.h
+include/node/v8-array-buffer.h
+include/node/v8-callbacks.h
+include/node/v8-container.h
+include/node/v8-context.h
+include/node/v8-data.h
+include/node/v8-date.h
+include/node/v8-debug.h
+include/node/v8-embedder-heap.h
+include/node/v8-embedder-state-scope.h
+include/node/v8-exception.h
+include/node/v8-extension.h
+include/node/v8-external.h
+include/node/v8-forward.h
+include/node/v8-function-callback.h
+include/node/v8-function.h
+include/node/v8-initialization.h
+include/node/v8-internal.h
+include/node/v8-isolate.h
+include/node/v8-json.h
+include/node/v8-local-handle.h
+include/node/v8-locker.h
+include/node/v8-maybe.h
+include/node/v8-memory-span.h
+include/node/v8-message.h
+include/node/v8-microtask-queue.h
+include/node/v8-microtask.h
+include/node/v8-object.h
+include/node/v8-persistent-handle.h
+include/node/v8-platform.h
+include/node/v8-primitive-object.h
+include/node/v8-primitive.h
+include/node/v8-profiler.h
+include/node/v8-promise.h
+include/node/v8-proxy.h
+include/node/v8-regexp.h
+include/node/v8-script.h
+include/node/v8-snapshot.h
+include/node/v8-statistics.h
+include/node/v8-template.h
+include/node/v8-traced-handle.h
+include/node/v8-typed-array.h
+include/node/v8-unwinder.h
+include/node/v8-value-serializer.h
+include/node/v8-value.h
+include/node/v8-version.h
+include/node/v8-wasm.h
+include/node/v8-weak-callback-info.h
+include/node/v8.h
+include/node/v8config.h
+lib/node_modules/corepack/CHANGELOG.md
+lib/node_modules/corepack/LICENSE.md
+lib/node_modules/corepack/README.md
+lib/node_modules/corepack/dist/corepack.js
+lib/node_modules/corepack/dist/npm.js
+lib/node_modules/corepack/dist/npx.js
+lib/node_modules/corepack/dist/pnpm.js
+lib/node_modules/corepack/dist/pnpx.js
+lib/node_modules/corepack/dist/vcc.js
+lib/node_modules/corepack/dist/vendors-_yarn_berry_cache_proxy-agent-npm-5_0_0-41772f4b01-9_zip_node_modules_proxy-agent_index_js.js
+lib/node_modules/corepack/dist/yarn.js
+lib/node_modules/corepack/dist/yarnpkg.js
+lib/node_modules/corepack/package.json
+lib/node_modules/corepack/shims/corepack
+lib/node_modules/corepack/shims/corepack.cmd
+lib/node_modules/corepack/shims/corepack.ps1
+lib/node_modules/corepack/shims/nodewin/corepack
+lib/node_modules/corepack/shims/nodewin/corepack.cmd
+lib/node_modules/corepack/shims/nodewin/corepack.ps1
+lib/node_modules/corepack/shims/nodewin/npm
+lib/node_modules/corepack/shims/nodewin/npm.cmd
+lib/node_modules/corepack/shims/nodewin/npm.ps1
+lib/node_modules/corepack/shims/nodewin/npx
+lib/node_modules/corepack/shims/nodewin/npx.cmd
+lib/node_modules/corepack/shims/nodewin/npx.ps1
+lib/node_modules/corepack/shims/nodewin/pnpm
+lib/node_modules/corepack/shims/nodewin/pnpm.cmd
+lib/node_modules/corepack/shims/nodewin/pnpm.ps1
+lib/node_modules/corepack/shims/nodewin/pnpx
+lib/node_modules/corepack/shims/nodewin/pnpx.cmd
+lib/node_modules/corepack/shims/nodewin/pnpx.ps1
+lib/node_modules/corepack/shims/nodewin/yarn
+lib/node_modules/corepack/shims/nodewin/yarn.cmd
+lib/node_modules/corepack/shims/nodewin/yarn.ps1
+lib/node_modules/corepack/shims/nodewin/yarnpkg
+lib/node_modules/corepack/shims/nodewin/yarnpkg.cmd
+lib/node_modules/corepack/shims/nodewin/yarnpkg.ps1
+lib/node_modules/corepack/shims/npm
+lib/node_modules/corepack/shims/npm.cmd
+lib/node_modules/corepack/shims/npm.ps1
+lib/node_modules/corepack/shims/npx
+lib/node_modules/corepack/shims/npx.cmd
+lib/node_modules/corepack/shims/npx.ps1
+lib/node_modules/corepack/shims/pnpm
+lib/node_modules/corepack/shims/pnpm.cmd
+lib/node_modules/corepack/shims/pnpm.ps1
+lib/node_modules/corepack/shims/pnpx
+lib/node_modules/corepack/shims/pnpx.cmd
+lib/node_modules/corepack/shims/pnpx.ps1
+lib/node_modules/corepack/shims/yarn
+lib/node_modules/corepack/shims/yarn.cmd
+lib/node_modules/corepack/shims/yarn.ps1
+lib/node_modules/corepack/shims/yarnpkg
+lib/node_modules/corepack/shims/yarnpkg.cmd
+lib/node_modules/corepack/shims/yarnpkg.ps1
+man/man1/node.1
+share/doc/node/gdbinit
+share/doc/node/lldb_commands.py
+share/systemtap/tapset/node.stp
Index: pkgsrc/lang/nodejs18/buildlink3.mk
diff -u /dev/null pkgsrc/lang/nodejs18/buildlink3.mk:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/buildlink3.mk  Sat Dec  3 16:59:22 2022
@@ -0,0 +1,36 @@
+# $NetBSD: buildlink3.mk,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+BUILDLINK_TREE+=       nodejs
+
+.if !defined(NODEJS_BUILDLINK3_MK)
+NODEJS_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.nodejs+= nodejs>=10
+BUILDLINK_ABI_DEPENDS.nodejs+= nodejs>=18.1.0
+BUILDLINK_PKGSRCDIR.nodejs?=   ../../lang/nodejs18
+
+.include "../../mk/bsd.fast.prefs.mk"
+
+.if ${OPSYS} != "Darwin"
+.include "../../devel/libexecinfo/buildlink3.mk"
+.endif
+# Stated by the changelog
+BUILDLINK_API_DEPENDS.libuv+=  libuv>=1.23
+.include "../../devel/libuv/buildlink3.mk"
+.include "../../devel/zlib/buildlink3.mk"
+.include "../../textproc/icu/buildlink3.mk"
+# Requires nghttp2_option_set_max_settings
+BUILDLINK_API_DEPENDS.nghttp2+=        nghttp2>=1.41.0
+.include "../../www/nghttp2/buildlink3.mk"
+.include "../../mk/pthread.buildlink3.mk"
+
+pkgbase := nodejs
+.include "../../mk/pkg-build-options.mk"
+
+.if ${PKG_BUILD_OPTIONS.nodejs:Mopenssl}
+.  include "../../security/openssl/buildlink3.mk"
+.endif
+
+.endif # NODEJS_BUILDLINK3_MK
+
+BUILDLINK_TREE+=       -nodejs
Index: pkgsrc/lang/nodejs18/distinfo
diff -u /dev/null pkgsrc/lang/nodejs18/distinfo:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/distinfo       Sat Dec  3 16:59:22 2022
@@ -0,0 +1,27 @@
+$NetBSD: distinfo,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+BLAKE2s (node-v18.12.1.tar.xz) = 04149195afca2ed0d9582e7ad1bcd1c2618fed8d2b04eed9beb27da18b1663d0
+SHA512 (node-v18.12.1.tar.xz) = 1eb4978a1de19c026561a8484df87bdeb6f7f2ec8ae1eb38b6241d0b0ff6158a4a7d19f42df7e295a63b8047eaf862a7470494143b2e27bb36b65e4663966588
+Size (node-v18.12.1.tar.xz) = 38454588 bytes
+SHA1 (patch-common.gypi) = 80f3645498853b9939167d152365b4fa49528b70
+SHA1 (patch-deps_cares_cares.gyp) = 22b44f2ac59963f694dfe4f4585e08960b3dec32
+SHA1 (patch-deps_uv_common.gypi) = d38a9c8d9e3522f15812aec2f5b1e1e636d4bab3
+SHA1 (patch-deps_uvwasi_include_wasi__serdes.h) = 32b85ef5824b96b35aba9280bbe7aa7899d9e5cf
+SHA1 (patch-deps_v8_src_base_platform_platform-freebsd.cc) = b47025f33d2991275bbcd15dbabb28900afab0e1
+SHA1 (patch-deps_v8_src_base_platform_platform-openbsd.cc) = 5e593879dbab095f99e82593272a0de91043f9a8
+SHA1 (patch-deps_v8_src_base_platform_platform-posix.cc) = 0fdbc003d63429e9e097531d7848d16011f273a8
+SHA1 (patch-deps_v8_src_base_platform_semaphore.cc) = 802a95f1b1d131e0d85c1f99c659cc68b31ba2f6
+SHA1 (patch-deps_v8_src_base_strings.h) = 4d2b37491f2f74f1a573f8c1942790204e23a8bb
+SHA1 (patch-deps_v8_src_codegen_arm_cpu-arm.cc) = 84c75d61bc99c2ff9adeac3152f5b11ebb0e582b
+SHA1 (patch-deps_v8_src_common_globals.h) = 86637724864389f2b24251904de41669a2f00fbc
+SHA1 (patch-deps_v8_src_compiler_types.h) = 2a212282ab9d71e98ae56827fdb1d9778a6047a5
+SHA1 (patch-deps_v8_src_heap_code-range.cc) = b281f76f4e3d8e562f596235049a6be7c5ff4de2
+SHA1 (patch-deps_v8_tools_run-llprof.sh) = 39aa3faf77492ef8dd35b411b7b0e4605b469af3
+SHA1 (patch-node.gypi) = 4a104dba6c22702211009bc60a6be6f87554e2fa
+SHA1 (patch-src_crypto_crypto__rsa.cc) = 9ffd8de2fac76014696c8dfac7ba200eab56f6f6
+SHA1 (patch-src_inspector__agent.cc) = 3fd3d71f9d6013a6eb2a79e0442b31d2e2408a2f
+SHA1 (patch-src_node__postmortem__metadata.cc) = 9938482d724ad6636af5dc3fa719ec26ed8539ff
+SHA1 (patch-tools_gyp_pylib_gyp_generator_make.py) = 570fe9889767c555468a225cd7f0b398ea6a193c
+SHA1 (patch-tools_gyp_pylib_gyp_xcode__emulation.py) = 4ee24115f5e97ffbd23aaa6dc62f408d381d4e22
+SHA1 (patch-tools_install.py) = c01515e3001bebd50f12bcada548f1cc0c25a49f
+SHA1 (patch-tools_v8_gypfiles_v8.gyp) = 997748c6663e7931ead02ee47654933ec051e688

Index: pkgsrc/lang/nodejs18/patches/patch-common.gypi
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-common.gypi:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-common.gypi      Sat Dec  3 16:59:22 2022
@@ -0,0 +1,20 @@
+$NetBSD: patch-common.gypi,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Add support for NetBSD.
+
+--- common.gypi.orig   2022-05-03 08:18:07.000000000 +0000
++++ common.gypi
+@@ -394,11 +394,11 @@
+           'BUILDING_UV_SHARED=1',
+         ],
+       }],
+-      [ 'OS in "linux freebsd openbsd solaris aix"', {
++      [ 'OS in "linux freebsd openbsd netbsd solaris aix"', {
+         'cflags': [ '-pthread' ],
+         'ldflags': [ '-pthread' ],
+       }],
+-      [ 'OS in "linux freebsd openbsd solaris android aix cloudabi"', {
++      [ 'OS in "linux freebsd openbsd netbsd netbsd solaris android aix cloudabi"', {
+         'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', ],
+         'cflags_cc': [ '-fno-rtti', '-fno-exceptions', '-std=gnu++17' ],
+         'defines': [ '__STDC_FORMAT_MACROS' ],
Index: pkgsrc/lang/nodejs18/patches/patch-deps_cares_cares.gyp
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_cares_cares.gyp:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_cares_cares.gyp     Sat Dec  3 16:59:22 2022
@@ -0,0 +1,17 @@
+$NetBSD: patch-deps_cares_cares.gyp,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Add support for NetBSD.
+
+--- deps/cares/cares.gyp.orig  2013-03-14 10:55:24.000000000 +0900
++++ deps/cares/cares.gyp       2013-03-14 10:55:47.000000000 +0900
+@@ -140,6 +140,10 @@
+           'include_dirs': [ 'config/freebsd' ],
+           'sources': [ 'config/freebsd/ares_config.h' ]
+         }],
++        [ 'OS=="netbsd"', {
++          'include_dirs': [ 'config/netbsd' ],
++          'sources': [ 'config/netbsd/ares_config.h' ]
++        }],
+         [ 'OS=="openbsd"', {
+           'include_dirs': [ 'config/openbsd' ],
+           'sources': [ 'config/openbsd/ares_config.h' ]
Index: pkgsrc/lang/nodejs18/patches/patch-deps_uv_common.gypi
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_uv_common.gypi:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_uv_common.gypi      Sat Dec  3 16:59:22 2022
@@ -0,0 +1,15 @@
+$NetBSD: patch-deps_uv_common.gypi,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Add support for NetBSD.
+
+--- deps/uv/common.gypi.orig   2018-04-24 14:41:22.000000000 +0000
++++ deps/uv/common.gypi
+@@ -134,7 +134,7 @@
+           }]
+         ]
+       }],
+-      ['OS in "freebsd dragonflybsd linux openbsd solaris android aix"', {
++      ['OS in "freebsd dragonflybsd linux openbsd netbsd solaris android aix"', {
+         'cflags': [ '-Wall' ],
+         'cflags_cc': [ '-fno-rtti', '-fno-exceptions' ],
+         'target_conditions': [
Index: pkgsrc/lang/nodejs18/patches/patch-deps_uvwasi_include_wasi__serdes.h
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_uvwasi_include_wasi__serdes.h:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_uvwasi_include_wasi__serdes.h       Sat Dec  3 16:59:22 2022
@@ -0,0 +1,21 @@
+$NetBSD: patch-deps_uvwasi_include_wasi__serdes.h,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+NetBSD<9 used to have #define uint8_t etc. which caused issues with complicated
+defines like this one.
+
+--- deps/uvwasi/include/wasi_serdes.h.orig     2020-08-11 14:32:04.000000000 +0000
++++ deps/uvwasi/include/wasi_serdes.h
+@@ -3,6 +3,13 @@
+ 
+ #include "wasi_types.h"
+ 
++#ifdef __NetBSD__
++#undef uint8_t
++#undef uint16_t
++#undef uint32_t
++#undef uint64_t
++#endif
++
+ /* Basic uint{8,16,32,64}_t read/write functions. */
+ 
+ #define BASIC_TYPE(name, type)                                                \
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-freebsd.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-freebsd.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-freebsd.cc    Sat Dec  3 16:59:22 2022
@@ -0,0 +1,33 @@
+$NetBSD: patch-deps_v8_src_base_platform_platform-freebsd.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Overlapping variables, taken from https://github.com/joyent/node/issues/9175
+
+--- deps/v8/src/base/platform/platform-freebsd.cc.orig 2020-01-07 22:07:49.000000000 +0000
++++ deps/v8/src/base/platform/platform-freebsd.cc
+@@ -47,7 +47,7 @@ static unsigned StringToLong(char* buffe
+ }
+ 
+ std::vector<OS::SharedLibraryAddress> OS::GetSharedLibraryAddresses() {
+-  std::vector<SharedLibraryAddress> result;
++  std::vector<SharedLibraryAddress> address_result;
+   int mib[4] = {CTL_KERN, KERN_PROC, KERN_PROC_VMMAP, getpid()};
+   size_t miblen = sizeof(mib) / sizeof(mib[0]);
+   size_t buffer_size;
+@@ -80,7 +80,7 @@ std::vector<OS::SharedLibraryAddress> OS
+           } else {
+             lib_name = std::string(path);
+           }
+-          result.push_back(SharedLibraryAddress(
++          address_result.push_back(SharedLibraryAddress(
+               lib_name, reinterpret_cast<uintptr_t>(map->kve_start),
+               reinterpret_cast<uintptr_t>(map->kve_end)));
+         }
+@@ -89,7 +89,7 @@ std::vector<OS::SharedLibraryAddress> OS
+       }
+     }
+   }
+-  return result;
++  return address_result;
+ }
+ 
+ void OS::SignalCodeMovingGC() {}
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-openbsd.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-openbsd.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-openbsd.cc    Sat Dec  3 16:59:22 2022
@@ -0,0 +1,55 @@
+$NetBSD: patch-deps_v8_src_base_platform_platform-openbsd.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Add support for NetBSD/arm.
+
+--- deps/v8/src/base/platform/platform-openbsd.cc.orig 2017-09-26 21:14:30.000000000 +0000
++++ deps/v8/src/base/platform/platform-openbsd.cc
+@@ -34,6 +34,48 @@
+ namespace v8 {
+ namespace base {
+ 
++#ifdef __arm__
++
++bool OS::ArmUsingHardFloat() {
++  // GCC versions 4.6 and above define __ARM_PCS or __ARM_PCS_VFP to specify
++  // the Floating Point ABI used (PCS stands for Procedure Call Standard).
++  // We use these as well as a couple of other defines to statically determine
++  // what FP ABI used.
++  // GCC versions 4.4 and below don't support hard-fp.
++  // GCC versions 4.5 may support hard-fp without defining __ARM_PCS or
++  // __ARM_PCS_VFP.
++
++#define GCC_VERSION (__GNUC__ * 10000                                          \
++                     + __GNUC_MINOR__ * 100                                    \
++                     + __GNUC_PATCHLEVEL__)
++#if GCC_VERSION >= 40600
++#if defined(__ARM_PCS_VFP)
++  return true;
++#else
++  return false;
++#endif
++
++#elif GCC_VERSION < 40500
++  return false;
++
++#else
++#if defined(__ARM_PCS_VFP)
++  return true;
++#elif defined(__ARM_PCS) || defined(__SOFTFP__) || defined(__SOFTFP) || \
++      !defined(__VFP_FP__)
++  return false;
++#else
++#error "Your version of GCC does not report the FP ABI compiled for."          \
++       "Please report it on this issue"                                        \
++       "http://code.google.com/p/v8/issues/detail?id=2140";
++
++#endif
++#endif
++#undef GCC_VERSION
++}
++
++#endif  // def __arm__
++
+ TimezoneCache* OS::CreateTimezoneCache() {
+   return new PosixDefaultTimezoneCache();
+ }
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-posix.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-posix.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_platform-posix.cc      Sat Dec  3 16:59:22 2022
@@ -0,0 +1,82 @@
+$NetBSD: patch-deps_v8_src_base_platform_platform-posix.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Use sysconf(_SC_THREAD_STACK_MIN) instead of PTHREAD_STACK_MIN.
+Cast explicitly.
+Remove legacy madvise(2) prototypes, prefer posix_madvise(2) if available.
+
+Avoid using a random hint, some low numbers cause spurious ENOMEM on netbsd
+(PR port-arm/55533)
+
+--- deps/v8/src/base/platform/platform-posix.cc.orig   2022-07-26 14:30:08.000000000 +0000
++++ deps/v8/src/base/platform/platform-posix.cc
+@@ -72,14 +72,6 @@
+ #define MAP_ANONYMOUS MAP_ANON
+ #endif
+ 
+-#if defined(V8_OS_SOLARIS)
+-#if (defined(_POSIX_C_SOURCE) && _POSIX_C_SOURCE > 2) || defined(__EXTENSIONS__)
+-extern "C" int madvise(caddr_t, size_t, int);
+-#else
+-extern int madvise(caddr_t, size_t, int);
+-#endif
+-#endif
+-
+ #ifndef MADV_FREE
+ #define MADV_FREE MADV_DONTNEED
+ #endif
+@@ -384,6 +376,10 @@ void* OS::GetRandomMmapAddr() {
+ #endif
+ #endif
+ #endif
++
++#if V8_OS_NETBSD
++  raw_addr = 0;
++#endif
+   return reinterpret_cast<void*>(raw_addr);
+ }
+ 
+@@ -515,12 +511,10 @@ bool OS::DiscardSystemPages(void* addres
+     // MADV_FREE_REUSABLE sometimes fails, so fall back to MADV_DONTNEED.
+     ret = madvise(address, size, MADV_DONTNEED);
+   }
+-#elif defined(_AIX) || defined(V8_OS_SOLARIS)
+-  int ret = madvise(reinterpret_cast<caddr_t>(address), size, MADV_FREE);
++#elif defined(POSIX_MADV_DONTNEED)
++  int ret = posix_madvise(address, size, POSIX_MADV_DONTNEED);
+   if (ret != 0 && errno == ENOSYS)
+     return true;  // madvise is not available on all systems.
+-  if (ret != 0 && errno == EINVAL)
+-    ret = madvise(reinterpret_cast<caddr_t>(address), size, MADV_DONTNEED);
+ #else
+   int ret = madvise(address, size, MADV_DONTNEED);
+ #endif
+@@ -733,6 +727,8 @@ int OS::GetCurrentThreadId() {
+   return static_cast<int>(syscall(__NR_gettid));
+ #elif V8_OS_ANDROID
+   return static_cast<int>(gettid());
++#elif V8_OS_NETBSD || V8_OS_FREEBSD
++  return static_cast<int>(reinterpret_cast<intptr_t>(pthread_self()));
+ #elif V8_OS_AIX
+   return static_cast<int>(thread_self());
+ #elif V8_OS_FUCHSIA
+@@ -1000,7 +996,11 @@ Thread::Thread(const Options& options)
+     : data_(new PlatformData),
+       stack_size_(options.stack_size()),
+       start_semaphore_(nullptr) {
++#if V8_OS_NETBSD
++  const int min_stack_size = sysconf(_SC_THREAD_STACK_MIN);
++#else
+   const int min_stack_size = static_cast<int>(PTHREAD_STACK_MIN);
++#endif
+   if (stack_size_ > 0) stack_size_ = std::max(stack_size_, min_stack_size);
+   set_name(options.name());
+ }
+@@ -1016,7 +1016,7 @@ static void SetThreadName(const char* na
+   pthread_set_name_np(pthread_self(), name);
+ #elif V8_OS_NETBSD
+   STATIC_ASSERT(Thread::kMaxThreadNameLength <= PTHREAD_MAX_NAMELEN_NP);
+-  pthread_setname_np(pthread_self(), "%s", name);
++  pthread_setname_np(pthread_self(), "%s", (void *)name);
+ #elif V8_OS_DARWIN
+   // pthread_setname_np is only available in 10.6 or later, so test
+   // for it at runtime.
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_semaphore.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_semaphore.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_platform_semaphore.cc   Sat Dec  3 16:59:22 2022
@@ -0,0 +1,18 @@
+$NetBSD: patch-deps_v8_src_base_platform_semaphore.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Work around lack of sem_timedwait(3) in NetBSD < 6.99.4.
+Adapted from d4f11c0cf476dd854eaebec1cbacb1afc7bea18e of the Chromium V8 sources.
+
+--- deps/v8/src/base/platform/semaphore.cc.orig        2016-10-25 13:26:03.000000000 +0000
++++ deps/v8/src/base/platform/semaphore.cc
+@@ -11,6 +11,10 @@
+ 
+ #include <errno.h>
+ 
++#if V8_OS_NETBSD
++#include <sys/param.h>        // for __NetBSD_Version__
++#endif
++
+ #include "src/base/logging.h"
+ #include "src/base/platform/elapsed-timer.h"
+ #include "src/base/platform/time.h"
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_strings.h
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_strings.h:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_base_strings.h       Sat Dec  3 16:59:22 2022
@@ -0,0 +1,14 @@
+$NetBSD: patch-deps_v8_src_base_strings.h,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+stdarg.h is needed for va_list on at least NetBSD.
+
+--- deps/v8/src/base/strings.h.orig    2022-02-08 12:37:48.000000000 +0000
++++ deps/v8/src/base/strings.h
+@@ -8,6 +8,7 @@
+ #include "src/base/base-export.h"
+ #include "src/base/macros.h"
+ #include "src/base/vector.h"
++#include <stdarg.h>
+ 
+ namespace v8 {
+ namespace base {
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_codegen_arm_cpu-arm.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_codegen_arm_cpu-arm.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_codegen_arm_cpu-arm.cc       Sat Dec  3 16:59:22 2022
@@ -0,0 +1,26 @@
+$NetBSD: patch-deps_v8_src_codegen_arm_cpu-arm.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+port to NetBSD/arm.
+
+--- deps/v8/src/codegen/arm/cpu-arm.cc.orig    2020-10-07 10:47:41.000000000 -0700
++++ deps/v8/src/codegen/arm/cpu-arm.cc 2020-10-17 00:16:51.732785305 -0700
+@@ -19,6 +19,10 @@
+ 
+ #include "src/codegen/cpu-features.h"
+ 
++#if V8_OS_NETBSD
++#include <machine/sysarch.h>
++#endif
++
+ namespace v8 {
+ namespace internal {
+ 
+@@ -32,6 +36,8 @@
+   struct arm_sync_icache_args args = {
+       .addr = reinterpret_cast<uintptr_t>(start), .len = size};
+   sysarch(ARM_SYNC_ICACHE, reinterpret_cast<void*>(&args));
++#elif V8_OS_NETBSD
++  arm_sync_icache(reinterpret_cast<uintptr_t>(start), size);
+ #else
+   register uint32_t beg asm("r0") = reinterpret_cast<uint32_t>(start);
+   register uint32_t end asm("r1") = beg + size;
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_common_globals.h
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_common_globals.h:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_common_globals.h     Sat Dec  3 16:59:22 2022
@@ -0,0 +1,14 @@
+$NetBSD: patch-deps_v8_src_common_globals.h,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+stdarg.h is needed for va_list on at least NetBSD.
+
+--- deps/v8/src/common/globals.h.orig  2019-11-19 08:29:07.000000000 +0000
++++ deps/v8/src/common/globals.h
+@@ -7,6 +7,7 @@
+ 
+ #include <stddef.h>
+ #include <stdint.h>
++#include <stdarg.h>
+ 
+ #include <limits>
+ #include <ostream>
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_compiler_types.h
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_compiler_types.h:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_compiler_types.h     Sat Dec  3 16:59:22 2022
@@ -0,0 +1,21 @@
+$NetBSD: patch-deps_v8_src_compiler_types.h,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+NetBSD 6 doesn't have nearbyint/nearbyintf.
+
+--- deps/v8/src/compiler/types.h.orig  2019-11-19 08:29:07.000000000 +0000
++++ deps/v8/src/compiler/types.h
+@@ -5,6 +5,14 @@
+ #ifndef V8_COMPILER_TYPES_H_
+ #define V8_COMPILER_TYPES_H_
+ 
++#ifdef __NetBSD__
++#include <sys/param.h>
++#if __NetBSD_Version__ - 0 < 699001700
++#define nearbyint rint
++#define nearbyintf rintf
++#endif
++#endif
++
+ #include "src/base/compiler-specific.h"
+ #include "src/common/globals.h"
+ #include "src/compiler/heap-refs.h"
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_heap_code-range.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_heap_code-range.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_src_heap_code-range.cc   Sat Dec  3 16:59:22 2022
@@ -0,0 +1,20 @@
+$NetBSD: patch-deps_v8_src_heap_code-range.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+nodejs: disable "near code ranges" on NetBSD/evbarm-aarch64 for now.
+It results in mmap(2) errors of the PR kern/55533 variety.
+
+--- deps/v8/src/heap/code-range.cc.orig        2022-05-03 08:18:09.000000000 +0000
++++ deps/v8/src/heap/code-range.cc
+@@ -59,8 +59,12 @@ Address CodeRangeAddressHint::GetAddress
+       // with a higher chances to point to the free address space range.
+       return RoundUp(preferred_region.begin(), alignment);
+     }
++#if V8_OS_NETBSD
++    return 0;
++#else
+     return RoundUp(FUNCTION_ADDR(&FunctionInStaticBinaryForAddressHint),
+                    alignment);
++#endif
+   }
+ 
+   // Try to reuse near code range first.
Index: pkgsrc/lang/nodejs18/patches/patch-deps_v8_tools_run-llprof.sh
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-deps_v8_tools_run-llprof.sh:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-deps_v8_tools_run-llprof.sh      Sat Dec  3 16:59:22 2022
@@ -0,0 +1,15 @@
+$NetBSD: patch-deps_v8_tools_run-llprof.sh,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+POSIX shell portability.
+
+--- deps/v8/tools/run-llprof.sh.orig   2015-03-31 22:13:01.000000000 +0000
++++ deps/v8/tools/run-llprof.sh
+@@ -46,7 +46,7 @@ framework, then calls the low level tick
+ EOF
+ }
+ 
+-if [ $# -eq 0 ] || [ "$1" == "-h" ]  || [ "$1" == "--help" ] ; then
++if [ $# -eq 0 ] || [ "$1" = "-h" ]  || [ "$1" = "--help" ] ; then
+   usage
+   exit 1
+ fi
Index: pkgsrc/lang/nodejs18/patches/patch-node.gypi
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-node.gypi:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-node.gypi        Sat Dec  3 16:59:22 2022
@@ -0,0 +1,14 @@
+$NetBSD: patch-node.gypi,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Linking in libcares requires libsocket.
+
+--- node.gypi.orig     2018-04-24 14:41:37.000000000 +0000
++++ node.gypi
+@@ -251,6 +251,7 @@
+     [ 'OS=="solaris"', {
+       'libraries': [
+         '-lkstat',
++        '-lsocket',
+         '-lumem',
+       ],
+       'defines!': [
Index: pkgsrc/lang/nodejs18/patches/patch-src_crypto_crypto__rsa.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-src_crypto_crypto__rsa.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-src_crypto_crypto__rsa.cc        Sat Dec  3 16:59:22 2022
@@ -0,0 +1,37 @@
+$NetBSD: patch-src_crypto_crypto__rsa.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Fix build with old OpenSSL 1.1.1d, as in NetBSD 9.0
+
+--- src/crypto/crypto_rsa.cc.orig      2022-05-17 11:37:46.000000000 +0000
++++ src/crypto/crypto_rsa.cc
+@@ -12,6 +12,30 @@
+ #include <openssl/bn.h>
+ #include <openssl/rsa.h>
+ 
++#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER <0x1010105fL
++struct rsa_st {
++  int pad;
++  int32_t version;
++  void *meth;
++  void *engine;
++  void *n;
++  void *e;
++  void *d;
++  void *p;
++  void *q;
++  void *dmp1;
++  void *dmq1;
++  void *iqmp;
++  void *prime_infos;
++  RSA_PSS_PARAMS *pss;
++};
++
++static const RSA_PSS_PARAMS *RSA_get0_pss_params(const RSA *r)
++{
++  return r->pss;
++}
++#endif
++
+ namespace node {
+ 
+ using v8::ArrayBuffer;
Index: pkgsrc/lang/nodejs18/patches/patch-src_inspector__agent.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-src_inspector__agent.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-src_inspector__agent.cc  Sat Dec  3 16:59:22 2022
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_inspector__agent.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+NetBSD support.
+
+--- src/inspector_agent.cc.orig        2022-05-03 08:18:11.000000000 +0000
++++ src/inspector_agent.cc
+@@ -96,7 +96,7 @@ static int StartDebugSignalHandler() {
+   CHECK_EQ(0, uv_sem_init(&start_io_thread_semaphore, 0));
+   pthread_attr_t attr;
+   CHECK_EQ(0, pthread_attr_init(&attr));
+-#if defined(PTHREAD_STACK_MIN) && !defined(__FreeBSD__)
++#if defined(PTHREAD_STACK_MIN) && !defined(__FreeBSD__) && !defined(__NetBSD__)
+   // PTHREAD_STACK_MIN is 2 KiB with musl libc, which is too small to safely
+   // receive signals. PTHREAD_STACK_MIN + MINSIGSTKSZ is 8 KiB on arm64, which
+   // is the musl architecture with the biggest MINSIGSTKSZ so let's use that
Index: pkgsrc/lang/nodejs18/patches/patch-src_node__postmortem__metadata.cc
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-src_node__postmortem__metadata.cc:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-src_node__postmortem__metadata.cc        Sat Dec  3 16:59:22 2022
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_node__postmortem__metadata.cc,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+--- src/node_postmortem_metadata.cc.orig       2018-03-23 20:05:49.909811719 +0000
++++ src/node_postmortem_metadata.cc
+@@ -11,6 +11,10 @@
+ #define NODEDBG_OFFSET(Class, Member, Type) \
+     NODEDBG_SYMBOL(offset_ ## Class ## __ ## Member ## __ ## Type)
+ 
++// Some systems provide macros for the types as well, which get expanded
++// by the nested macros here.
++#undef uintptr_t
++
+ // These are the constants describing Node internal structures. Every constant
+ // should use the format described above.  These constants are declared as
+ // global integers so that they'll be present in the generated node binary. They
Index: pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_generator_make.py
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_generator_make.py:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_generator_make.py    Sat Dec  3 16:59:22 2022
@@ -0,0 +1,25 @@
+$NetBSD: patch-tools_gyp_pylib_gyp_generator_make.py,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Use the system libtool on Darwin.
+Add support for NetBSD and DragonFly.
+
+--- tools/gyp/pylib/gyp/generator/make.py.orig 2021-08-03 05:54:27.000000000 +0000
++++ tools/gyp/pylib/gyp/generator/make.py
+@@ -179,7 +179,7 @@ cmd_solink_module = $(LINK.$(TOOLSET)) -
+ 
+ LINK_COMMANDS_MAC = """\
+ quiet_cmd_alink = LIBTOOL-STATIC $@
+-cmd_alink = rm -f $@ && ./gyp-mac-tool filter-libtool libtool $(GYP_LIBTOOLFLAGS) -static -o $@ $(filter %.o,$^)
++cmd_alink = rm -f $@ && ./gyp-mac-tool filter-libtool /usr/bin/libtool $(GYP_LIBTOOLFLAGS) -static -o $@ $(filter %.o,$^)
+ 
+ quiet_cmd_link = LINK($(TOOLSET)) $@
+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o "$@" $(LD_INPUTS) $(LIBS)
+@@ -2335,7 +2335,7 @@ def GenerateOutput(target_list, target_d
+                 "flock_index": 2,
+             }
+         )
+-    elif flavor == "freebsd":
++    elif flavor == "freebsd" or flavor == 'dragonflybsd' or flavor == 'netbsd':
+         # Note: OpenBSD has sysutils/flock. lockf seems to be FreeBSD specific.
+         header_params.update({"flock": "lockf"})
+     elif flavor == "openbsd":
Index: pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_xcode__emulation.py
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_xcode__emulation.py:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-tools_gyp_pylib_gyp_xcode__emulation.py  Sat Dec  3 16:59:22 2022
@@ -0,0 +1,24 @@
+$NetBSD: patch-tools_gyp_pylib_gyp_xcode__emulation.py,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Do not generate debugging symbols (uses lots of disk space).
+
+--- tools/gyp/pylib/gyp/xcode_emulation.py.orig        2020-10-07 17:47:43.000000000 +0000
++++ tools/gyp/pylib/gyp/xcode_emulation.py
+@@ -610,7 +610,7 @@ class XcodeSettings(object):
+ 
+         self._Appendf(cflags, "GCC_OPTIMIZATION_LEVEL", "-O%s", default="s")
+ 
+-        if self._Test("GCC_GENERATE_DEBUGGING_SYMBOLS", "YES", default="YES"):
++        if self._Test("GCC_GENERATE_DEBUGGING_SYMBOLS", "YES", default="NO"):
+             dbg_format = self._Settings().get("DEBUG_INFORMATION_FORMAT", "dwarf")
+             if dbg_format == "dwarf":
+                 cflags.append("-gdwarf-2")
+@@ -1097,7 +1097,7 @@ class XcodeSettings(object):
+         # For static libraries, no dSYMs are created.
+         result = []
+         if (
+-            self._Test("GCC_GENERATE_DEBUGGING_SYMBOLS", "YES", default="YES")
++            self._Test("GCC_GENERATE_DEBUGGING_SYMBOLS", "YES", default="NO")
+             and self._Test(
+                 "DEBUG_INFORMATION_FORMAT", "dwarf-with-dsym", default="dwarf"
+             )
Index: pkgsrc/lang/nodejs18/patches/patch-tools_install.py
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-tools_install.py:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-tools_install.py Sat Dec  3 16:59:22 2022
@@ -0,0 +1,18 @@
+$NetBSD: patch-tools_install.py,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Install man pages under the right directory.
+
+--- tools/install.py.orig      2021-09-10 17:25:14.000000000 +0000
++++ tools/install.py
+@@ -156,10 +156,7 @@ def files(action):
+   action(['deps/v8/tools/gdbinit'], 'share/doc/node/')
+   action(['deps/v8/tools/lldb_commands.py'], 'share/doc/node/')
+ 
+-  if 'freebsd' in sys.platform or 'openbsd' in sys.platform:
+-    action(['doc/node.1'], 'man/man1/')
+-  else:
+-    action(['doc/node.1'], 'share/man/man1/')
++  action(['doc/node.1'], os.environ.get('PKGMANDIR') + '/man1/')
+ 
+   if 'true' == variables.get('node_install_npm'):
+     npm_files(action)
Index: pkgsrc/lang/nodejs18/patches/patch-tools_v8_gypfiles_v8.gyp
diff -u /dev/null pkgsrc/lang/nodejs18/patches/patch-tools_v8_gypfiles_v8.gyp:1.1
--- /dev/null   Sat Dec  3 16:59:22 2022
+++ pkgsrc/lang/nodejs18/patches/patch-tools_v8_gypfiles_v8.gyp Sat Dec  3 16:59:22 2022
@@ -0,0 +1,19 @@
+$NetBSD: patch-tools_v8_gypfiles_v8.gyp,v 1.1 2022/12/03 16:59:22 adam Exp $
+
+Add -larm on netbsd arm platforms.
+
+--- tools/v8_gypfiles/v8.gyp.orig      2022-05-03 08:18:12.000000000 +0000
++++ tools/v8_gypfiles/v8.gyp
+@@ -977,6 +977,12 @@
+         }],
+         # Platforms that don't have Compare-And-Swap (CAS) support need to link atomic library
+         # to implement atomic memory access
++        # NetBSD/arm also needs -larm.
++        ['OS == "netbsd" and v8_current_cpu in ["arm"]', {
++          'link_settings': {
++            'libraries': ['-larm', ],
++          },
++        }],
+         ['v8_current_cpu in ["mips", "mipsel", "mips64", "mips64el", "ppc", "arm", "riscv64", "loong64"]', {
+           'link_settings': {
+             'libraries': ['-latomic', ],



Home | Main Index | Thread Index | Old Index