updated on Sat Jan 21 04:00:54 UTC 2012
[aur-mirror.git] / pdfminer-svn / PKGBUILD
blobe53e6f4df4832c6a55706db9a7080fcb91d93feb
1 # Contributor: James Feng Cao <jamesfengcao@yahoo.com>
3 pkgname=pdfminer-svn
4 pkgver=159
5 pkgrel=1
6 pkgdesc="python utils to extract& analyze text data of PDF files."
7 arch=('i686' 'x86_64')
8 url="http://www.unixuser.org/~euske/python/pdfminer/"
9 license=('MIT/X')
10 depends=('python')
11 makedepends=('subversion')
12 conflicts=('pdfminer')
13 source=()
14 md5sums=()
16 _svnurl="http://pdfminerr.googlecode.com/svn/trunk/"
17 _svnmod="pdfminerr-read-only"
19 build() {
20   cd "$srcdir"
21   if [ -e "${_svnmod}"/.svn ]
22         then
23                 msg "Starting SVN update ..."
24                 cd "${_svnmod}"
25                 svn up
26                 cd "${srcdir}"
27                 msg "... updating finished."
28         else
29                 msg "Starting SVN checkout ..."
30           svn co $_svnurl $_svnmod
31                 msg "... checkout finished."
32         fi
34         if [ -e "${_svnmod}"-build ]
35         then
36                 rm -rf "${_svnmod}"-build
37         fi
39   cp -r "${_svnmod}" "${_svnmod}"-build
40   cd "${_svnmod}"-build
41   
42   msg "SVN checkout done or server timeout"
43   msg "Starting make..."
45   cd $srcdir/${_svnmod}-build/pdfminer
46   cp Makefile Makefile.bak
47   sed 's/PREFIX=\/usr\/local//' Makefile.bak > Makefile
48   make PREFIX=$pkgdir/usr install || return 1
49   rm Makefile.bak