# Contributor: William Pitcock # Maintainer: William Pitcock setvar pkgname = 'v8' setvar pkgver = '3.30.33.16' setvar pkgrel = '0' setvar pkgdesc = ""V8 JavaScript/ECMAScript Engine"" setvar url = ""http://www.chromium.org/"" setvar arch = ""all"" setvar license = ""BSD"" setvar depends = """" setvar depends_dev = ""icu-dev readline-dev"" setvar makedepends = ""${depends_dev} python paxmark"" setvar install = """" setvar subpackages = ""$pkgname-dev"" # look for updates: http://gsdview.appspot.com/chromium-browser-official/?marker=v8-3.30.22.tar.bz2.hashe%40 setvar source = ""http://gsdview.appspot.com/chromium-browser-official/v8-$pkgver.tar.bz2 v8.pc"" setvar builddir = ""$srcdir"/v8-$pkgver" test $CARCH = 'x86' && setvar ARCH = 'ia32' test $CARCH = 'x86_64' && setvar ARCH = 'x64' proc prepare { local i cd $builddir for i in $source { case (i) { *.patch { msg $i; patch -p1 -i "$srcdir"/$i || return 1} } } sed "s/@VERSION@/$pkgver/g" -i "$srcdir/v8.pc" } proc build { cd $builddir local paxflags="-m" test $CARCH = "x86" && setvar paxflags = ""-msp"" msg "Start building..." export CXXFLAGS="$CXXFLAGS -fno-delete-null-pointer-checks" build/gyp_v8 \ -Dv8_enable_i18n_support=1 \ -Duse_system_icu=1 \ -Dconsole=readline \ -Dcomponent=shared_library \ -Dv8_target_arch=$ARCH \ -Dwerror= \ --generator-output=out \ -f make cd out make BUILDTYPE=Release Release/mksnapshot || return 1 paxmark $paxflags Release/mksnapshot || return 1 make BUILDTYPE=Release } proc package { cd $builddir shell { set -e install -Dm755 out/Release/d8 "$pkgdir"/usr/bin/d8 install -Dm755 out/Release/lib.target/libv8.so "$pkgdir"/usr/lib/libv8.so install -d "$pkgdir"/usr/include install -Dm644 include/*.h "$pkgdir"/usr/include install -d "$pkgdir"/usr/lib/pkgconfig install -m644 "$srcdir/v8.pc" "$pkgdir"/usr/lib/pkgconfig install -d "$pkgdir"/usr/share/licenses/v8 install -m644 LICENSE* "$pkgdir"/usr/share/licenses/v8 } } setvar md5sums = ""935177ef0ca8119511c49b697e4d16f4 v8-3.30.33.16.tar.bz2 082724bc560e90d846c0aa441847020c v8.pc"" setvar sha256sums = ""85d0a3a599a34a572813d134b038f4eea774671398a7097af944e267c60aeeab v8-3.30.33.16.tar.bz2 2b054309df9af9fb2e3e14527e88360b44745649b4866e592fb357ac90935f5d v8.pc"" setvar sha512sums = ""af7c44e050d254dc51d5485dbf1c3208bb3aeed658a25689eb7c93a723ec704a6dfe771caab5c137624ee0cdbf7f9ff9f3a19a24c3af4a1ac736983e4592dd61 v8-3.30.33.16.tar.bz2 67848ce85a6e4b674cf8775a21e687884530748a0296a2259373636729c9a230a27b7ebfbf5fafff3c1e9c102956246ec4eb744853e564fc8337b42a125aeea8 v8.pc""