mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-10-09 06:21:59 +02:00
Update ppc patch due to a refactor in sampler.cc internals introduced in [1] where 'state' variable is now treated as a pointer. [1] https://goo.gl/YwyjCC
77 lines
2.5 KiB
Plaintext
77 lines
2.5 KiB
Plaintext
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
|
|
# Maintainer: Jose-Luis Rivas <ghostbar@riseup.net>
|
|
pkgname=nodejs-current
|
|
# The current stable version, i.e. non-LTS.
|
|
pkgver=7.9.0
|
|
pkgrel=0
|
|
pkgdesc="JavaScript runtime built on V8 engine - current stable version"
|
|
url="http://nodejs.org/"
|
|
arch="all"
|
|
license="MIT"
|
|
depends="ca-certificates"
|
|
depends_dev="libuv"
|
|
# gold is needed for mksnapshot
|
|
makedepends="$depends_dev python2 openssl-dev zlib-dev libuv-dev linux-headers
|
|
paxmark binutils-gold http-parser-dev ca-certificates"
|
|
subpackages="$pkgname-dev $pkgname-doc $pkgname-npm::noarch"
|
|
provides="nodejs"
|
|
replaces="nodejs nodejs-lts" # nodejs-lts for backward compatibility
|
|
source="https://nodejs.org/dist/v$pkgver/node-v$pkgver.tar.gz
|
|
dont-run-gyp-files-for-bundled-deps.patch
|
|
ppc-fix-musl-mcontext.patch"
|
|
builddir="$srcdir/node-v$pkgver"
|
|
|
|
prepare() {
|
|
default_prepare || return 1
|
|
|
|
# Remove bundled dependencies that we're not using.
|
|
rm -rf deps/http_parser deps/openssl deps/uv deps/zlib
|
|
}
|
|
|
|
build() {
|
|
cd "$builddir"
|
|
|
|
./configure --prefix=/usr \
|
|
--shared-zlib \
|
|
--shared-libuv \
|
|
--shared-openssl \
|
|
--shared-http-parser \
|
|
--openssl-use-def-ca-store \
|
|
|| return 1
|
|
|
|
# we need run mksnapshot at build time so paxmark it early
|
|
make -C out mksnapshot BUILDTYPE=Release \
|
|
&& paxmark -m out/Release/mksnapshot \
|
|
&& make || return 1
|
|
}
|
|
|
|
package() {
|
|
cd "$builddir"
|
|
|
|
make DESTDIR="$pkgdir" install || return 1
|
|
# paxmark so JIT works
|
|
paxmark -m "$pkgdir"/usr/bin/node || return 1
|
|
|
|
cp -pr "$pkgdir"/usr/lib/node_modules/npm/man "$pkgdir"/usr/share || return 1
|
|
local d; for d in doc html man; do
|
|
rm -r "$pkgdir"/usr/lib/node_modules/npm/$d || return 1
|
|
done
|
|
}
|
|
|
|
npm() {
|
|
pkgdesc="A package manager for JavaScript"
|
|
depends="$pkgname"
|
|
provides="nodejs-npm"
|
|
replaces="nodejs-npm $pkgname" # $pkgname for backward compatibility
|
|
|
|
mkdir -p "$subpkgdir"/usr/bin
|
|
mv "$pkgdir"/usr/bin/npm "$subpkgdir"/usr/bin/ || return 1
|
|
|
|
mkdir -p "$subpkgdir"/usr/lib/node_modules
|
|
mv "$pkgdir"/usr/lib/node_modules/npm "$subpkgdir"/usr/lib/node_modules/
|
|
}
|
|
|
|
sha512sums="38ae9a8084ab5f20d895b8f2fb6c4f010789f5c01a05f3260ab290d85c3e7c00b79c0f412a3f1ca2bc2e3bd0d644146a7455fdcd384b532bb56cf16e9ad2bca3 node-v7.9.0.tar.gz
|
|
ba95f21b1e80717ef63941854e7ed412f64a91da068c0dbf0d6d9697333ee266c9f4cd7bf1a01111eeb28aa66adefd8a58cfb3e82debb84b43e35e9dc914dd36 dont-run-gyp-files-for-bundled-deps.patch
|
|
fba595afa968810a705c0c5794329e888e2ff78b797861b80aa6f021c27770ea716cda544962cbf0abf4ba152eeee7869b58f1b042ed9b3f543c63f527c569a2 ppc-fix-musl-mcontext.patch"
|