desktop/python-py/PKGBUILD
AlmAck 08a66c4024 python3 rebuild for 3.5
new pkg added to fullfill checkdepends
new order file python3.order
2016-03-16 22:36:13 +01:00

55 lines
1.4 KiB
Bash

# Contribution from Arch:
# Contributor: Sebastian Wiesner <lunaryorn googlemail com>
# Contributor: Igor Ramos Tiburcio <irtigor@yahoo.com.br>
pkgbase=python-py
pkgname=('python2-py' 'python3-py')
pkgver=1.4.31
pkgrel=2
pkgdesc="Python rapid development tools"
arch=('any')
license=('MIT')
url="http://pylib.readthedocs.org/en/latest/"
makedepends=("python2-setuptools" "python3-setuptools" )
checkdepends=('python2-pytest' 'python3-pytest')
source=("http://pypi.python.org/packages/source/p/py/py-$pkgver.tar.gz")
sha256sums=('a6501963c725fc2554dabfece8ae9a8fb5e149c0ac0a42fd2b02c5c1c57fc114')
prepare() {
cp -r py-${pkgver}{,-py3}
cp -r py-${pkgver}{,-py2}
}
build() {
cd "$srcdir/py-${pkgver}-py3"
python3 setup.py build
cd "$srcdir/py-${pkgver}-py2"
python2 setup.py build
}
check() {
cd "$srcdir/py-${pkgver}-py3"
PYTHONPATH="$PWD/build/lib:$PYTHONPATH" LC_ALL="en_US.UTF-8" py.test
cd "$srcdir/py-${pkgver}-py2"
PYTHONPATH="$PWD/build/lib:$PYTHONPATH" LC_ALL="en_US.UTF-8" py.test2
}
package_python3-py() {
depends=('python3')
cd py-${pkgver}-py3
python3 setup.py install --root="${pkgdir}" --optimize=1
install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
package_python2-py() {
depends=('python2')
cd py-${pkgver}-py2
python2 setup.py install --root="${pkgdir}" --optimize=1
install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}