add nodejs

This commit is contained in:
Ella-0 2021-10-25 11:26:47 +00:00
parent 5c6531dc76
commit 0fa4d5617c
2 changed files with 65 additions and 0 deletions

38
extra/nodejs/build.sh Normal file
View file

@ -0,0 +1,38 @@
pkgname=nodejs
pkgver=16.6.1
fetch() {
curl -L "https://nodejs.org/dist/v$pkgver/node-v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mv node-v$pkgver $pkgname-$pkgver
cd $pkgname-$pkgver
sed -i 's/-latomic//' node.gyp
}
build() {
cd $pkgname-$pkgver
./configure \
--shared-zlib \
--shared-openssl \
--with-intl=none \
--without-etw \
--without-dtrace \
--without-report \
--without-node-snapshot \
--without-node-code-cache \
--ninja
samu -C out/Release
}
package() {
cd $pkgname-$pkgver
./tools/install.py install $pkgdir /usr
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

View file

@ -0,0 +1,27 @@
From 8dbc49deefb50f4af05710d3e6ad1ca7ff6dbfac Mon Sep 17 00:00:00 2001
From: Ishimoto Shinobu <nagakamira@gmail.com>
Date: Sun, 21 Feb 2021 09:43:21 +0900
Subject: [PATCH] remove -latomic library
Signed-off-by: Ishimoto Shinobu <nagakamira@gmail.com>
---
node.gyp | 3 ---
1 file changed, 3 deletions(-)
diff --git a/node.gyp b/node.gyp
index 131461de..051d2816 100644
--- a/node.gyp
+++ b/node.gyp
@@ -343,9 +343,6 @@
'-Wl,-bnoerrmsg',
],
}],
- ['OS == "linux" and llvm_version != "0.0"', {
- 'libraries': ['-latomic'],
- }],
],
},
--
2.29.2