blob: 5bd9f5f27226148495911b83b7c362bc27748485 (
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
|
# Maintainer: Vianney le Clément <vleclement AT gmail·com>
pkgname=jbig2enc-git
pkgver=20120803
pkgrel=2
pkgdesc="A JBIG2 image encoder"
arch=('i686' 'x86_64')
url="https://github.com/agl/jbig2enc"
license=('Apache')
depends=('gcc-libs' 'leptonica>=1.68' 'libpng' 'libjpeg' 'libtiff')
optdepends=('python2: for pdf.py')
makedepends=('git')
_gitroot="https://github.com/agl/jbig2enc.git"
_gitname="jbig2enc"
build() {
cd "$srcdir"
msg "Connecting to GIT server..."
if [ -d $_gitname ] ; then
cd $_gitname && git pull origin
msg "The local files are updated."
else
git clone $_gitroot $_gitname
fi
msg "GIT checkout done or server timeout"
rm -rf "$srcdir/$_gitname-build"
git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
cd "$srcdir/$_gitname-build"
msg "Patching sources..."
sed -i 's@^#!/usr/bin/python$@#!/usr/bin/env python2@' pdf.py
msg "Building..."
./autogen.sh
./configure --prefix=/usr
make
}
package() {
cd "$srcdir/$_gitname-build"
make install DESTDIR="$pkgdir"
}
|