blob: 84403fe83a53d92d8fb58a543c586729295e79f3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
# Contributor: William Pitcock <nenolod@dereferenced.org>
# Contributor: Jose-Luis Rivas <ghostbar@riseup.net>
# Maintainer: Eivind Uggedal <eivind@uggedal.com>
pkgname=nodejs
pkgver=4.4.2
pkgrel=0
pkgdesc='Evented I/O for V8 javascript'
url='http://nodejs.org/'
arch='all'
license='MIT'
# gold is needed for mksnapshot
makedepends="$depends_dev python openssl-dev zlib-dev libuv-dev
linux-headers paxmark binutils-gold"
subpackages="$pkgname-dev $pkgname-doc"
source="https://nodejs.org/dist/v$pkgver/node-v$pkgver.tar.gz"
_builddir="$srcdir"/node-v$pkgver
prepare() {
local i
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
}
build() {
cd "$_builddir"
./configure --prefix=/usr \
--shared-zlib \
--shared-libuv \
--shared-openssl \
|| 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() {
local d
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
for d in doc html man; do
rm -r "$pkgdir"/usr/lib/node_modules/npm/$d || return 1
done
}
md5sums="a0f91fa97aa837658c1eaf9a9b80c873 node-v4.4.2.tar.gz"
sha256sums="ae91cb0a31f87b5b13bb2665178845d99abf1037dc3636fa88f442b4a4c65297 node-v4.4.2.tar.gz"
sha512sums="87f97f009bb5d12a7c6d67101311d5c6c6f73a5a5f64b14352c6a07ed4ec08059890eaf8e08ee59909bfdf6b8c0f31d86201d5ea81df0e828c4f88b33b06fc6c node-v4.4.2.tar.gz"
|