summaryrefslogtreecommitdiff
path: root/extra/djvulibre/PKGBUILD
blob: 75cd92aef37d07b6dd7561edac0bd4d64350582d (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
# $Id: PKGBUILD 148700 2012-02-05 11:47:29Z ibiru $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: mgushee

pkgname=djvulibre
pkgver=3.5.24
pkgrel=3
pkgdesc="Suite to create, manipulate and view DjVu ('déjà vu') documents"
arch=("i686" "x86_64")
license=('GPL')
url="http://djvu.sourceforge.net/"
depends=('gcc-libs' 'libtiff>=4.0.0' 'bash' 'hicolor-icon-theme')
makedepends=('pkg-config')
provides=("libdjvu=${pkgver}")
replaces=('libdjvu')
conflicts=('libdjvu')
optdepends=('djview4: Viewer application')
options=('!libtool')
install=djvulibre.install
source=(http://downloads.sourceforge.net/djvu/${pkgname}-${pkgver}.tar.gz
        git-fixes.patch)
md5sums=('af83d27af5083198432a178d22b259c5'
         'ff3798e383e9c3fae407455d8a51deec')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  patch -Np1 -i "${srcdir}/git-fixes.patch"
  ./configure --prefix=/usr --disable-desktopfiles
  make
}

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

  #Install icons for mime-types.
  install -m755 -d ${pkgdir}/usr/share/icons/hicolor/{22x22,32x32,48x48,64x64}/mimetypes
  for sz in 22 32 48 64; do
    install -m644 desktopfiles/prebuilt-hi${sz}-djvu.png "${pkgdir}/usr/share/icons/hicolor/${sz}x${sz}/mimetypes/image-vnd.djvu.mime.png"
  done
}