summaryrefslogtreecommitdiff
path: root/npm/Pkgfile
diff options
context:
space:
mode:
Diffstat (limited to 'npm/Pkgfile')
-rw-r--r--npm/Pkgfile43
1 files changed, 43 insertions, 0 deletions
diff --git a/npm/Pkgfile b/npm/Pkgfile
new file mode 100644
index 000000000..fab3bddd2
--- /dev/null
+++ b/npm/Pkgfile
@@ -0,0 +1,43 @@
+# Description: nodejs package manager
+# URL: https://nodejs.org/
+# Maintainer: Tim Biermann, tbier at posteo dot de
+# Depends on: nodejs
+# Optional: icu brotli ninja
+
+# c-ares wait until a newer release than 1.16.1
+
+name=npm
+version=15.5.1
+release=1
+source=(https://nodejs.org/dist/v$version/node-v$version.tar.xz)
+
+build() {
+ cd node-v$version
+
+ [ -e '/usr/lib/pkgconfig/icu-i18n.pc' ] && PKGMK_NODEJS+=' --with-intl=system-icu'
+ [ -e '/usr/lib/pkgconfig/libbrotlicommon.pc' ] && PKGMK_NODEJS+=' --shared-brotli'
+ [ -e '/usr/bin/ninja' ] && PKGMK_NODEJS+=' --ninja'
+
+ ./configure ${PKGMK_NODEJS} \
+ --prefix=/usr \
+ --shared-libuv \
+ --shared-zlib \
+ --shared-openssl
+ # -shared-cares
+
+ make
+ make DESTDIR=$PKG install
+
+ rm -r $PKG/usr/include/
+ rm -r $PKG/usr/bin/node
+ rm -rf $PKG/usr/share/{doc,man,systemtap}
+
+ # 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
+}

Generated by cgit