# Contributor: Jan de Groot <jgc@archlinux.org>; sfs
# Maintainer: Florian Bruhin (The-Compiler) <archlinux.org@the-compiler.org>

pkgname=('poppler-light')
pkgver=0.26.5
pkgrel=1
arch=(i686 x86_64)
license=('GPL')
#makedepends=('icu')
options=('!libtool' '!emptydirs')
pkgdesc="PDF rendering library based on xpdf 3.0"
#depends=('fontconfig' 'gcc-libs')
depends=('cairo-small' 'libtiff' 'libjpeg-turbo' 'glib2' 'libpng')
conflicts=("poppler")
provides=("poppler" "poppler-glib")
url="http://poppler.freedesktop.org/"
source=(http://poppler.freedesktop.org/poppler-${pkgver}.tar.xz)
sha1sums=('SKIP')

build() {
  cd "${srcdir}/poppler-${pkgver}"

  sed -i -e '/AC_PATH_XTRA/d' configure.ac
  sed -i "s:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:" configure.ac
  autoreconf -fi

  ./configure --prefix=/usr --sysconfdir=/etc \
      --localstatedir=/var --disable-static 
  make
}

package() {
  cd "${srcdir}/poppler-${pkgver}"
  make DESTDIR="${pkgdir}" install
}

