summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7b131c7297dad28fa7a7fa5a57e37e3769eb55ee (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
# Maintainer: sleduc <sebastien@sleduc.fr>
# Contributor: shadyabhi <abhijeet.1989@gmail.com>
# Author : Christian Kreutzer

pkgname=python2-tvrage
_realname=python-tvrage
pkgver=0.4.1
pkgrel=2
pkgdesc="Object oriented client interface for tvrage.com's XML based api feeds"
url="https://pypi.python.org/pypi/python-tvrage"
arch=('any')
license=('GPL')
depends=('python2'
         'python2-beautifulsoup3')
makedepends=('python2-distribute')
source=("http://pypi.python.org/packages/source/p/$_realname/$_realname-$pkgver.tar.gz")
md5sums=('cdfec252158c5047b626861900186dfb')

package(){
  #Really ugly, but what can be done.
  cd "$srcdir/ckreutzer-python-tvrage-c8e9781"

  # python2 fix
  for file in $(find . -name '*.py' -print); do
    sed -i 's_#!.*/usr/bin/python_#!/usr/bin/python2_' $file
    sed -i 's_#!.*/usr/bin/env.*python_#!/usr/bin/env python2_' $file
  done

  python2 setup.py install --root="$pkgdir" --optimize=1
}