summaryrefslogtreecommitdiff
path: root/libre/mcomix-libre/PKGBUILD
blob: d30bbb1a3a3b44e07e8f8891d7afb8adfd2e9921 (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
# $Id$
# Maintainer: schuay <jakob.gruber@gmail.com>
# Contributor: Ray Powell <ray_al@xphoniexx.net>
# Maintainer (Parabola): André Silva <emulatorman@lavabit.com>

_pkgname=mcomix
pkgname=mcomix-libre
pkgver=0.99
pkgrel=1
pkgdesc="A user-friendly, customizable image viewer specifically designed to handle comic books"
arch=('any')
url="http://sourceforge.net/projects/mcomix/"
license=('GPL')
depends=('pygtk' 'python-imaging' 'xdg-utils' 'python2' \
         'desktop-file-utils' 'hicolor-icon-theme' 'python2-distribute')
makedepends=('gettext' 'intltool')
optdepends=('ununrar: for rar compressed comics')
conflicts=('mcomix' 'comix')
replaces=('mcomix' 'comix')
provides=("mcomix=${pkgver}")
install='mcomix.install'
source=("http://downloads.sourceforge.net/project/mcomix/MComix-${pkgver}/mcomix-${pkgver}.tar.bz2")

build() {
  cd ${srcdir}/${_pkgname}-${pkgver}

  # python2 fix
  for file in $(grep -Rl "/usr/bin/env python" .);
  do
    sed -i 's_#!/usr/bin/env python_#!/usr/bin/env python2_' $file
  done
}

package() {
  cd ${srcdir}/${_pkgname}-${pkgver}

  export PYTHONPATH=${pkgdir}/usr/lib/python2.7/site-packages/
  mkdir -p $PYTHONPATH

  python2 setup.py install --prefix=${pkgdir}/usr --optimize=1 \
    --single-version-externally-managed --root=/

  install -Dm644 mime/comicbook.schemas \
    ${pkgdir}/usr/share/gconf/schemas/mcomix.schemas
}

md5sums=('a1ff7e1955042069d5005b4034e7a914')