summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZach van Rijn <me@zv.io>2023-09-14 15:06:17 -0500
committerZach van Rijn <me@zv.io>2023-09-14 22:17:30 -0500
commit4d290403fcae001bca45154271f4b344e503e57e (patch)
tree09e220328d560b4c54530f3d47fe9cc6727999d3
parent747046784c07d8e5aee181ed0e0b4a04e15467e8 (diff)
downloadpackages-4d290403fcae001bca45154271f4b344e503e57e.tar.gz
packages-4d290403fcae001bca45154271f4b344e503e57e.tar.bz2
packages-4d290403fcae001bca45154271f4b344e503e57e.tar.xz
packages-4d290403fcae001bca45154271f4b344e503e57e.zip
user/node: add patch for zlib version check. fixes #1055.
-rw-r--r--user/node/APKBUILD4
-rw-r--r--user/node/zlib-version-regex.patch31
2 files changed, 34 insertions, 1 deletions
diff --git a/user/node/APKBUILD b/user/node/APKBUILD
index f80c30a8f..11570595d 100644
--- a/user/node/APKBUILD
+++ b/user/node/APKBUILD
@@ -15,6 +15,7 @@ subpackages="$pkgname-dev $pkgname-doc"
source="https://nodejs.org/download/release/v$pkgver/node-v$pkgver.tar.xz
pmmx-test.patch
pmmx-time64.patch
+ zlib-version-regex.patch
"
builddir="$srcdir/$pkgname-v$pkgver"
@@ -66,4 +67,5 @@ package() {
sha512sums="e41fcda469809186fd724ef4691e25f4a5bd81357ee99acf3d7faa1190a69c19cb62bd14aea199ca6f8b5cf9687af7d898cdf605ea2414d2c04db87ddb3b4dc8 node-v18.15.0.tar.xz
277e226f3906f791bae6aedd0b74b0e2c52b6154eb2dc0c568417ad94a0722078e4fbbbe15c59d4ba0b59cdb4ad45b5e9620f14d75694a15531857cd29aa044a pmmx-test.patch
-bf78e52c60b4567854eaa9d9433ade8a318a356cb326dded99e800df35a9f475390a0cf8b0c8e595bbdb3702838eafe91801cd646576aa7fa7966b37d794e380 pmmx-time64.patch"
+bf78e52c60b4567854eaa9d9433ade8a318a356cb326dded99e800df35a9f475390a0cf8b0c8e595bbdb3702838eafe91801cd646576aa7fa7966b37d794e380 pmmx-time64.patch
+45d899bd62e39762fde7e9743efcc6dc032161ae087099da8eecebc84f3eaab87eecf00cbc5861f686a45332224025af172ab00ce966771dccf2e925ca48bc6a zlib-version-regex.patch"
diff --git a/user/node/zlib-version-regex.patch b/user/node/zlib-version-regex.patch
new file mode 100644
index 000000000..c06c4a938
--- /dev/null
+++ b/user/node/zlib-version-regex.patch
@@ -0,0 +1,31 @@
+This patch differs from upstream in the following:
+
+ * The regex is modified to support X.Y{,.Z} (upstream)
+ as opposed to custom subrevision X.Y.Z{,.n} (nodejs)
+
+From 43c332fd40293ecc621e74cae90c2565cecbcbd9 Mon Sep 17 00:00:00 2001
+From: Luigi Pinca <luigipinca@gmail.com>
+Date: Sun, 28 May 2023 07:57:21 +0200
+Subject: [PATCH] test: fix zlib version regex
+
+Add support for subrevision in the regular expression for the zlib
+version.
+
+Refs: https://github.com/madler/zlib/blob/48c3741002ac/zlib.h#L40
+---
+ test/parallel/test-process-versions.js | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test/parallel/test-process-versions.js b/test/parallel/test-process-versions.js
+index f706bd060b45f..31886093df8cc 100644
+--- a/test/parallel/test-process-versions.js
++++ b/test/parallel/test-process-versions.js
+@@ -61,7 +61,7 @@ assert.match(process.versions.brotli, commonTemplate);
+ assert.match(process.versions.llhttp, commonTemplate);
+ assert.match(process.versions.node, commonTemplate);
+ assert.match(process.versions.uv, commonTemplate);
+-assert.match(process.versions.zlib, commonTemplate);
++assert.match(process.versions.zlib, /^\d+(\.\d+){1,2}(?:-.*)?$/);
+
+ if (hasUndici) {
+ assert.match(process.versions.undici, commonTemplate);