Date: Saturday, June 1, 2019 @ 10:58:38 Author: felixonmars Revision: 476388
upgpkg: pifpaf 2.2.2-2 remove python2 sibling Modified: pifpaf/trunk/PKGBUILD ----------+ PKGBUILD | 60 +++++++++++++++--------------------------------------------- 1 file changed, 15 insertions(+), 45 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2019-06-01 10:57:34 UTC (rev 476387) +++ PKGBUILD 2019-06-01 10:58:38 UTC (rev 476388) @@ -1,72 +1,42 @@ # Maintainer: Felix Yan <[email protected]> -pkgbase=pifpaf -pkgname=('pifpaf' 'python2-pifpaf') +pkgname=pifpaf pkgver=2.2.2 -pkgrel=1 +pkgrel=2 pkgdesc='Suite of tools and fixtures to manage daemons for testing' arch=('any') license=('Apache') url='https://github.com/jd/pifpaf' -makedepends=('python-setuptools' 'python2-setuptools' 'python-pbr' 'python2-pbr' 'python-click' - 'python2-click' 'python-six' 'python2-six' 'python-daiquiri' 'python2-daiquiri' - 'python-fixtures' 'python2-fixtures' 'python-psutil' 'python2-psutil' - 'python-jinja' 'python2-jinja' 'python-xattr' 'python2-xattr') -checkdepends=('python-testrepository' 'python2-testrepository' 'python-requests' 'python2-requests' - 'python-testtools' 'python2-testtools' 'python-oslotest' 'python2-oslotest' - 'memcached' 'mongodb' 'percona-server' 'percona-server-clients' 'postgresql' 'redis' +depends=('python-daiquiri' 'python-click' 'python-pbr' 'python-jinja' 'python-six' + 'python-fixtures' 'python-psutil' 'python-xattr') +provides=("python-pifpaf=$pkgver") +conflicts=('python-pifpaf') +replaces=('python-pifpaf') +makedepends=('python-setuptools') +checkdepends=('python-testrepository' 'python-requests' 'python-testtools' 'python-oslotest' + 'memcached' 'percona-server' 'percona-server-clients' 'postgresql' 'redis' 'ceph' 'consul' 'couchdb') # 'elasticsearch': test fails # 'rabbitmq': test hangs -source=("$pkgbase-$pkgver.tar.gz::https://github.com/jd/pifpaf/archive/$pkgver.tar.gz") +source=("$pkgname-$pkgver.tar.gz::https://github.com/jd/pifpaf/archive/$pkgver.tar.gz") sha512sums=('ca06da6b641eca723e6818c9bd81bd68fb0e1f8687e7ca32e4c7c36439b769f52d23a0e1a14e74b7731c69210d7de2b9ce2f68daf992424d54f4a3c7f0e6877f') -prepare() { - cp -a pifpaf-$pkgver{,-py2} +export PBR_VERSION=$pkgver - export LC_CTYPE=en_US.UTF-8 - export PBR_VERSION=$pkgver -} - build() { - cd "$srcdir"/pifpaf-$pkgver + cd pifpaf-$pkgver python setup.py build - - cd "$srcdir"/pifpaf-$pkgver-py2 - python2 setup.py build } check() { # Hack entry points by installing it - cd "$srcdir"/pifpaf-$pkgver + cd pifpaf-$pkgver python setup.py install --root="$PWD/tmp_install" --optimize=1 PYTHONPATH="$PWD/tmp_install/usr/lib/python3.7/site-packages" PATH="$PWD/tmp_install/usr/bin:$PATH" python setup.py testr - - cd "$srcdir"/pifpaf-$pkgver-py2 - python2 setup.py install --root="$PWD/tmp_install" --optimize=1 - PYTHONPATH="$PWD/tmp_install/usr/lib/python2.7/site-packages" PATH="$PWD/tmp_install/usr/bin:$PATH" PYTHON=python2 python2 setup.py testr } -package_pifpaf() { - depends=('python-daiquiri' 'python-click' 'python-pbr' 'python-jinja' 'python-six' - 'python-fixtures' 'python-psutil' 'python-xattr') - provides=("python-pifpaf=$pkgver") - conflicts=('python-pifpaf') - replaces=('python-pifpaf') - +package() { cd pifpaf-$pkgver python setup.py install --root="$pkgdir" --optimize=1 } - -package_python2-pifpaf() { - depends=('python2-pbr' 'python2-click' 'python2-six' 'python2-fixtures' 'python2-daiquiri' - 'python2-psutil' 'python2-jinja' 'python2-xattr') - - cd pifpaf-$pkgver-py2 - python2 setup.py install --root="$pkgdir" --optimize=1 - - mv "$pkgdir"/usr/bin/pifpaf{,2} -} - -# vim:set ts=2 sw=2 et:
