4 pkgdesc='A fast and modern javascript engine'
5 arch=('i686' 'x86_64' 'arm')
6 url='http://code.google.com/p/v8'
8 makedepends=('subversion' 'scons')
11 source=('werror.patch')
12 md5sums=('fd95683b3b9f389a11391d83e1b5cfb8')
14 _svntrunk=http://v8.googlecode.com/svn/branches/bleeding_edge/
19 if [[ -d "$_svnmod/.svn" ]]; then
20 (cd "$_svnmod" && svn up -r "$pkgver")
22 svn co "$_svntrunk" "$_svnmod"
24 rm -rf "$srcdir/$_svnmod-build"
25 cp -r "$srcdir/$_svnmod" "$srcdir/$_svnmod-build"
26 cd "$srcdir/$_svnmod-build"
28 # https://github.com/joyent/node/issues/1377
29 patch -Np1 -i $srcdir/werror.patch
31 [ "$CARCH" = 'i686' ] && SCONS_ARCH=ia32
32 [ "$CARCH" = 'x86_64' ] && SCONS_ARCH=x64
34 scons mode=release library=shared arch=$SCONS_ARCH
35 scons d8 arch=$SCONS_ARCH
38 cd "$srcdir/$_svnmod-build"
39 find include -type f -exec install -Dm644 {} $pkgdir/usr/{} \;
40 rm -rf $pkgdir/usr/include/.svn
41 install -Dm755 d8 "$pkgdir/usr/bin/d8"
42 install -Dm755 libv8.so "$pkgdir/usr/lib/libv8.so"