blob: f0b3dbe0355a6feb4aef466c60a7e39faa2f8481 (
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
|
# $Id: PKGBUILD 113062 2014-06-12 12:41:47Z foutrelis $
# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
pkgname=wkhtmltopdf
pkgver=0.12.0
pkgrel=1
pkgdesc="Command line tools to render HTML into PDF and various image formats"
arch=('i686' 'x86_64')
url="http://wkhtmltopdf.org/"
license=('GPL3')
depends=('qtwebkit')
optdepends=('xorg-server: wkhtmltopdf needs X or Xvfb to operate')
source=($pkgname-$pkgver.tar.gz::https://github.com/wkhtmltopdf/wkhtmltopdf/archive/$pkgver.tar.gz
0001-fix-spurious-exit-with-code-1-due-to-http-error-1xxx.patch
0002-fix-compilation-failures-when-not-building-with-patc.patch)
sha256sums=('ad3449acc772bd687b3853e087033b7223e6298f4a59d21d09c08c9d006f693f'
'bc9ffc8a99a32f66882e406f25962a0753129c161530879ad23ee5bd189a2a66'
'ece5abbee4c9f37ab4b5df856dd708562dbf4e14374b9c60b41109f00c82c44b')
prepare() {
cd "$srcdir/$pkgname-$pkgver"
# https://github.com/wkhtmltopdf/wkhtmltopdf/issues/1502
patch -Np1 -i "$srcdir/0001-fix-spurious-exit-with-code-1-due-to-http-error-1xxx.patch"
# Fix build with system Qt
patch -Np1 -i "$srcdir/0002-fix-compilation-failures-when-not-building-with-patc.patch"
}
build() {
cd "$srcdir/$pkgname-$pkgver"
qmake-qt4 wkhtmltopdf.pro
make
}
package() {
cd "$srcdir/$pkgname-$pkgver"
make INSTALL_ROOT="$pkgdir/usr" install
# Generate and install man page
install -d "$pkgdir/usr/share/man/man1"
LD_LIBRARY_PATH=bin ./bin/wkhtmltopdf --manpage \
>"$pkgdir/usr/share/man/man1/wkhtmltopdf.1"
LD_LIBRARY_PATH=bin ./bin/wkhtmltoimage --manpage \
>"$pkgdir/usr/share/man/man1/wkhtmltoimage.1"
}
# vim:set ts=2 sw=2 et:
|