mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-09 00:23:52 +02:00
nodejs: update to 18.16.0.
This commit is contained in:
parent
78574d756c
commit
c6d44d3f9a
3 changed files with 35 additions and 52 deletions
|
@ -1,31 +0,0 @@
|
||||||
https://github.com/nxhack/openwrt-node-packages/blob/master/node/patches/v16.x/999-deps-v8-src-trap-handler-trap-handler.h.patch
|
|
||||||
|
|
||||||
--- a/deps/v8/src/trap-handler/trap-handler.h
|
|
||||||
+++ b/deps/v8/src/trap-handler/trap-handler.h
|
|
||||||
@@ -17,19 +17,16 @@ namespace v8 {
|
|
||||||
namespace internal {
|
|
||||||
namespace trap_handler {
|
|
||||||
|
|
||||||
-// X64 on Linux, Windows, MacOS, FreeBSD.
|
|
||||||
-#if V8_HOST_ARCH_X64 && V8_TARGET_ARCH_X64 && \
|
|
||||||
- ((V8_OS_LINUX && !V8_OS_ANDROID) || V8_OS_WIN || V8_OS_MACOSX || \
|
|
||||||
- V8_OS_FREEBSD)
|
|
||||||
+#if V8_TARGET_ARCH_X64 && V8_OS_LINUX && !V8_OS_ANDROID
|
|
||||||
#define V8_TRAP_HANDLER_SUPPORTED true
|
|
||||||
-// Arm64 (non-simulator) on Mac.
|
|
||||||
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_ARM64 && V8_OS_MACOSX
|
|
||||||
+#elif V8_TARGET_ARCH_X64 && V8_OS_WIN
|
|
||||||
#define V8_TRAP_HANDLER_SUPPORTED true
|
|
||||||
-// Arm64 simulator on x64 on Linux or Mac.
|
|
||||||
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_X64 && (V8_OS_LINUX || V8_OS_MACOSX)
|
|
||||||
-#define V8_TRAP_HANDLER_VIA_SIMULATOR
|
|
||||||
+#elif V8_TARGET_ARCH_X64 && V8_OS_MACOSX
|
|
||||||
+#define V8_TRAP_HANDLER_SUPPORTED true
|
|
||||||
+#elif V8_TARGET_ARCH_X64 && V8_OS_FREEBSD
|
|
||||||
+#define V8_TRAP_HANDLER_SUPPORTED true
|
|
||||||
+#elif V8_HOST_ARCH_ARM64 && V8_TARGET_ARCH_ARM64 && V8_OS_MACOSX
|
|
||||||
#define V8_TRAP_HANDLER_SUPPORTED true
|
|
||||||
-// Everything else is unsupported.
|
|
||||||
#else
|
|
||||||
#define V8_TRAP_HANDLER_SUPPORTED false
|
|
||||||
#endif
|
|
|
@ -1,29 +1,43 @@
|
||||||
From 4ac90c41065d338c4305cf6dc39e3084b21a7f79 Mon Sep 17 00:00:00 2001
|
From 6bdf9dc3ec7dbff00acef081f4e3dd3e061fd744 Mon Sep 17 00:00:00 2001
|
||||||
From: Michal Vasilek <michal@vasilek.cz>
|
From: Ben Noordhuis <info@bnoordhuis.nl>
|
||||||
Date: Sun, 20 Nov 2022 19:22:03 +0100
|
Date: Tue, 6 Dec 2022 11:27:49 +0100
|
||||||
Subject: [PATCH] Revert "build: enable pointer authentication for branch
|
Subject: [PATCH] build: fix arm64 cross-compilation
|
||||||
protection on arm64"
|
|
||||||
|
|
||||||
This reverts commit 938212f3e74a74d0b436941aa24e71425ff666c5.
|
Commit 938212f added -msign-return-address=all to _all_ cflags but that
|
||||||
|
is wrong when cross-compiling, it should only be added to the target's
|
||||||
|
cflags.
|
||||||
|
|
||||||
|
Fixes: https://github.com/nodejs/node/issues/42888
|
||||||
---
|
---
|
||||||
configure.py | 4 ----
|
configure.py | 2 --
|
||||||
1 file changed, 4 deletions(-)
|
node.gyp | 3 +++
|
||||||
|
2 files changed, 3 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
diff --git a/configure.py b/configure.py
|
diff --git a/configure.py b/configure.py
|
||||||
index d3192ca04c..2d049eb938 100755
|
index 40e0395e..9de3148f 100755
|
||||||
--- a/configure.py
|
--- a/configure.py
|
||||||
+++ b/configure.py
|
+++ b/configure.py
|
||||||
@@ -1241,10 +1241,6 @@ def configure_node(o):
|
@@ -1294,9 +1294,7 @@ def configure_node(o):
|
||||||
|
|
||||||
o['variables']['want_separate_host_toolset'] = int(cross_compiling)
|
o['variables']['want_separate_host_toolset'] = int(cross_compiling)
|
||||||
|
|
||||||
- # Enable branch protection for arm64
|
- # Enable branch protection for arm64
|
||||||
- if target_arch == 'arm64':
|
if target_arch == 'arm64':
|
||||||
- o['cflags']+=['-msign-return-address=all']
|
- o['cflags']+=['-msign-return-address=all']
|
||||||
-
|
o['variables']['arm_fpu'] = options.arm_fpu or 'neon'
|
||||||
if options.node_snapshot_main is not None:
|
|
||||||
if options.shared:
|
|
||||||
# This should be possible to fix, but we will need to refactor the
|
|
||||||
--
|
|
||||||
2.38.1
|
|
||||||
|
|
||||||
|
if options.node_snapshot_main is not None:
|
||||||
|
diff --git a/node.gyp b/node.gyp
|
||||||
|
index cf52281b..5218d941 100644
|
||||||
|
--- a/node.gyp
|
||||||
|
+++ b/node.gyp
|
||||||
|
@@ -112,6 +112,9 @@
|
||||||
|
},
|
||||||
|
|
||||||
|
'conditions': [
|
||||||
|
+ ['target_arch=="arm64"', {
|
||||||
|
+ 'cflags': ['-msign-return-address=all'], # Pointer authentication.
|
||||||
|
+ }],
|
||||||
|
['OS in "aix os400"', {
|
||||||
|
'ldflags': [
|
||||||
|
'-Wl,-bnoerrmsg',
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# Template file for 'nodejs'
|
# Template file for 'nodejs'
|
||||||
pkgname=nodejs
|
pkgname=nodejs
|
||||||
version=16.19.0
|
version=18.16.0
|
||||||
revision=3
|
revision=1
|
||||||
# Need these for host v8 for torque, see https://github.com/nodejs/node/pull/21079
|
# Need these for host v8 for torque, see https://github.com/nodejs/node/pull/21079
|
||||||
hostmakedepends="which pkg-config python3 libatomic-devel zlib-devel
|
hostmakedepends="which pkg-config python3 libatomic-devel zlib-devel
|
||||||
$(vopt_if icu icu-devel) $(vopt_if ssl openssl-devel) $(vopt_if libuv libuv-devel)
|
$(vopt_if icu icu-devel) $(vopt_if ssl openssl-devel) $(vopt_if libuv libuv-devel)
|
||||||
|
@ -15,7 +15,7 @@ maintainer="Enno Boland <gottox@voidlinux.org>"
|
||||||
license="MIT"
|
license="MIT"
|
||||||
homepage="https://nodejs.org/"
|
homepage="https://nodejs.org/"
|
||||||
distfiles="https://nodejs.org/dist/v${version}/node-v${version}.tar.gz"
|
distfiles="https://nodejs.org/dist/v${version}/node-v${version}.tar.gz"
|
||||||
checksum=8b8a2939fa5f654ff61cae29b12118c24109273458ecbe6162ad8a8858309e0d
|
checksum=6a4f5c5d76e5c50cef673099e56f19bc3266ae363f56ca0ab77dd2f3c5088c6d
|
||||||
python_version=3
|
python_version=3
|
||||||
|
|
||||||
build_options="ssl libuv icu nghttp2 cares"
|
build_options="ssl libuv icu nghttp2 cares"
|
||||||
|
@ -41,7 +41,7 @@ fi
|
||||||
|
|
||||||
case "$XBPS_TARGET_MACHINE" in
|
case "$XBPS_TARGET_MACHINE" in
|
||||||
ppc64*) ;;
|
ppc64*) ;;
|
||||||
ppc*) broken="Node 16.x does not support 32-bit ppc" ;;
|
ppc*) broken="Node 18.x does not support 32-bit ppc" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
|
CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
|
||||||
|
|
Loading…
Add table
Reference in a new issue