2017-06-17 13:12:52 +02:00
|
|
|
# Description: Evented I/O for V8 javascript.
|
2020-06-21 12:21:42 +02:00
|
|
|
# URL: https://nodejs.org/
|
2017-06-17 13:12:52 +02:00
|
|
|
# Maintainer: Danny Rawlins, crux at romster dot me
|
2021-05-08 07:31:30 +02:00
|
|
|
# Depends on: openssl libuv zlib
|
2021-06-26 15:47:27 +02:00
|
|
|
# Optional: brotli c-ares icu nghttp2-libs ninja
|
2020-11-10 09:08:13 +01:00
|
|
|
|
2017-06-17 13:12:52 +02:00
|
|
|
name=nodejs
|
2021-11-14 12:52:03 +01:00
|
|
|
version=17.1.0
|
2017-06-17 13:12:52 +02:00
|
|
|
release=1
|
2021-08-26 16:43:23 +02:00
|
|
|
source=(https://nodejs.org/dist/v$version/node-v$version.tar.xz
|
|
|
|
system-c-ares.patch)
|
2017-06-17 13:12:52 +02:00
|
|
|
|
|
|
|
build() {
|
|
|
|
cd node-v$version
|
|
|
|
|
2021-06-26 15:47:27 +02:00
|
|
|
prt-get isinst brotli && PKGMK_NODEJS+=' --shared-brotli'
|
|
|
|
prt-get isinst c-ares && PKGMK_NODEJS+=' --shared-cares'
|
2021-08-26 16:43:23 +02:00
|
|
|
prt-get isinst c-ares && patch -Rp1 -i $SRC/system-c-ares.patch
|
2021-06-26 15:47:27 +02:00
|
|
|
prt-get isinst icu && PKGMK_NODEJS+=' --with-intl=system-icu'
|
|
|
|
prt-get isinst nghttp2-libs && PKGMK_NODEJS+=' --experimental-http-parser --shared-nghttp2'
|
|
|
|
prt-get isinst ninja && PKGMK_NODEJS+=' --ninja'
|
2019-01-28 08:49:53 +01:00
|
|
|
|
|
|
|
./configure ${PKGMK_NODEJS} \
|
2017-06-17 13:12:52 +02:00
|
|
|
--prefix=/usr \
|
2021-07-08 01:12:11 +02:00
|
|
|
--enable-lto \
|
2017-06-17 13:12:52 +02:00
|
|
|
--without-npm \
|
2020-10-20 11:40:42 +02:00
|
|
|
--shared-libuv \
|
2019-10-24 09:05:18 +02:00
|
|
|
--shared-zlib \
|
|
|
|
--shared-openssl
|
2018-11-03 11:37:36 +01:00
|
|
|
|
2017-06-17 13:12:52 +02:00
|
|
|
make
|
|
|
|
make DESTDIR=$PKG install
|
|
|
|
|
|
|
|
rm -r $PKG/usr/share/doc
|
|
|
|
|
|
|
|
# clean up
|
|
|
|
find $PKG -type f \( \
|
|
|
|
-name 'README.md' -o \
|
|
|
|
-name 'AUTHORS.md' -o \
|
|
|
|
-name 'INSTALL.md' -o \
|
|
|
|
-name 'TODO.org' -o \
|
|
|
|
-name 'ChangeLog' -o \
|
|
|
|
-name 'NEWS' \) -delete
|
|
|
|
}
|