summaryrefslogtreecommitdiff
path: root/pcr/phantomjs/PKGBUILD
diff options
context:
space:
mode:
authorAndreas Grapentin <andreas@grapentin.org>2018-04-21 23:50:46 +0200
committerAndreas Grapentin <andreas@grapentin.org>2018-04-21 23:51:04 +0200
commitaf1e996fd2ee7c69c39921f76f68ed8c1f2b16d9 (patch)
treebc5f2d9dad6e51b3902292a7892eed269067aa3a /pcr/phantomjs/PKGBUILD
parent72218b3a454ffeb07f62e1b81d1c2cd6058e139c (diff)
downloadabslibre-af1e996fd2ee7c69c39921f76f68ed8c1f2b16d9.tar.gz
abslibre-af1e996fd2ee7c69c39921f76f68ed8c1f2b16d9.tar.bz2
abslibre-af1e996fd2ee7c69c39921f76f68ed8c1f2b16d9.zip
pcr/phantomjs: added
Diffstat (limited to 'pcr/phantomjs/PKGBUILD')
-rw-r--r--pcr/phantomjs/PKGBUILD51
1 files changed, 51 insertions, 0 deletions
diff --git a/pcr/phantomjs/PKGBUILD b/pcr/phantomjs/PKGBUILD
new file mode 100644
index 000000000..cf93077d3
--- /dev/null
+++ b/pcr/phantomjs/PKGBUILD
@@ -0,0 +1,51 @@
+# $Id$
+# Maintainer (AUR): Felix Yan <felixonmars@archlinux.org>
+# Contributor (AUR): grimsock <lord.grimsock at gmail dot com>
+# Contributor (AUR): Dieter Plaetinck <dieter@plaetinck.be>
+# Contributor (AUR): Vladimir Chizhov <jagoterr@gmail.com>
+# Contributor (AUR): Henry Tang <henryykt@gmail.com>
+
+pkgname=phantomjs
+pkgver=2.1.1
+pkgrel=11
+pkgdesc="Headless WebKit with JavaScript API"
+url="http://www.phantomjs.org/"
+license=('BSD' 'LGPL' 'MIT')
+arch=('x86_64' 'i686')
+depends=('icu>=61' 'icu<62' 'libjpeg-turbo' 'libpng' 'fontconfig' 'gperf' 'ruby' 'python2' 'openssl-1.0')
+makedepends=('git')
+source=("git+https://github.com/ariya/${pkgname}.git#tag=$pkgver"
+ icu59.patch)
+sha512sums=('SKIP'
+ 'e349a14c5d32e5627f28be6ebd20104370ec6b7f086f670e7f19b484b38839220cfeb49178765f38d918d05fb889bbc990f8a3809db6d9e1cbde0af5b9dd923b')
+
+prepare() {
+ cd $pkgname
+ git submodule update --init
+ patch -Np1 -d src/qt/qtwebkit <../icu59.patch
+ mkdir "$srcdir/python2-path"
+ ln -s /usr/bin/python2 "$srcdir/python2-path/python"
+}
+
+build() {
+ cd $pkgname
+ export PATH="$srcdir/python2-path:$PATH" PYTHON=/usr/bin/python2
+ export CXXFLAGS+=" -I/usr/include/openssl-1.0"
+ export OPENSSL_LIBS='-L/usr/lib/openssl-1.0 -lssl -lcrypto'
+
+ CFLAGS+=" -Wno-expansion-to-defined"
+ CXXFLAGS+=" -Wno-expansion-to-defined"
+
+ python2 build.py --confirm --release --qt-config='-no-rpath'
+}
+
+package() {
+ install -Dm755 "$srcdir/$pkgname/bin/phantomjs" "$pkgdir/usr/bin/phantomjs"
+
+ mkdir -p "$pkgdir/usr/share/$pkgname"
+ cp -r "$srcdir/$pkgname/examples" "$pkgdir/usr/share/$pkgname"/
+
+ install -Dm644 "$srcdir/$pkgname/LICENSE.BSD" "$pkgdir/usr/share/licenses/$pkgname/LICENSE.BSD"
+ install -Dm644 "$srcdir/$pkgname/third-party.txt" "$pkgdir/usr/share/licenses/$pkgname/third-party.txt"
+}
+