diff options
author | Andy Botting | 2017-04-12 16:57:23 +1000 |
---|---|---|
committer | Andy Botting | 2017-04-12 16:57:23 +1000 |
commit | 0d434638f68120cb573388756b3797899650885a (patch) | |
tree | dc06d3a253014502c28d6460e1c6fe583975de86 /PKGBUILD | |
parent | 94d33a75b5982eb173d6545297407a95f29828e7 (diff) | |
download | aur-0d434638f68120cb573388756b3797899650885a.tar.gz |
Update to v1.19.0-2
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 84 |
1 files changed, 59 insertions, 25 deletions
@@ -1,49 +1,83 @@ # Maintainer: Andy Botting <andy@andybotting.com> +_module='shade' pkgname=('python-shade' 'python2-shade') pkgver='1.19.0' -pkgrel='1' +pkgrel='2' pkgdesc='Simple client library for interacting with OpenStack clouds' arch=('any') -url='http://docs.openstack.org/infra/shade' +url="http://docs.openstack.org/infra/${_module}" license=('Apache') -makedepends=('python-setuptools' 'python2-setuptools') -source=("git+https://git.openstack.org/openstack-infra/shade#tag=$pkgver") +makedepends=('git' 'python-setuptools' 'python2-setuptools') +checkdepends=('python-pbr' 'python2-pbr' + 'python-munch' 'python2-munch' + 'python2-decorator' 'python-decorator' + 'python-jmespath' 'python2-jmespath' + 'python-jsonpatch' 'python2-jsonpatch' + 'python2-ipaddress' 'python2-futures' + 'python-os-client-config' 'python2-os-client-config' + 'python-requestsexceptions' 'python2-requestsexceptions' + 'python-six' 'python2-six' + 'python-keystoneauth1' 'python2-keystoneauth1' + 'python-netifaces' 'python2-netifaces' + 'python-novaclient' 'python2-novaclient' + 'python-keystoneclient' 'python2-keystoneclient' + 'python-cinderclient' 'python2-cinderclient' + 'python-neutronclient' 'python2-neutronclient' + 'python-ironicclient' 'python2-ironicclient' + 'python-designateclient' 'python2-designateclient' + 'python-dogpile.cache' 'python2-dogpile.cache' + 'python-fixtures' 'python2-fixtures' + 'python-mock' 'python2-mock' + 'python-subunit' 'python2-subunit' + 'python-requests-mock' 'python2-requests-mock' + 'python-testtools' 'python2-testtools' + 'python-oslotest' 'python2-oslotest') +source=("git+https://git.openstack.org/openstack-infra/${_module}#tag=${pkgver}") sha256sums=('SKIP') prepare() { - cp -a shade{,-py2} -} - + cp -a "${srcdir}/${_module}"{,-py2} +} + build() { - cd "$srcdir"/shade + cd "${srcdir}/${_module}" + # Fix test function name for Python 3 + sed -i 's/assertItemsEqual/assertCountEqual/g' shade/tests/unit/*.py python setup.py build - cd "$srcdir"/shade-py2 + cd "${srcdir}/${_module}-py2" python2 setup.py build } +check() { + cd "${srcdir}/${_module}" + python setup.py testr + + cd "${srcdir}/${_module}-py2" + PYTHON=python2 python2 setup.py testr +} + package_python-shade(){ - depends=('python-dogpile.cache' 'python-magnumclient' 'python-heatclient' - 'python-swiftclient' 'python-ironicclient' 'python-troveclient' - 'python-neutronclient' 'python-cinderclient' 'python-glanceclient' - 'python-keystoneclient' 'python-novaclient' 'python-netifaces' - 'python-keystoneauth1' 'python-six' 'python-requestsexceptions' - 'python-os-client-config' 'python-jsonpatch' 'python-jmespath' - 'python-decorator' 'python-munch' 'python-pbr') - cd "${srcdir}/shade" + depends=('python-pbr' 'python2-decorator' 'python-jmespath' + 'python-jsonpatch' 'python-os-client-config' + 'python-requestsexceptions' 'python-six' 'python-keystoneauth1' + 'python-netifaces' 'python-novaclient' 'python-keystoneclient' + 'python-cinderclient' 'python-neutronclient' 'python-ironicclient' + 'python-designateclient' 'python-dogpile.cache') + cd "${srcdir}/${_module}" python setup.py install --root="${pkgdir}" --optimize=1 } package_python2-shade() { - depends=('python-dogpile.cache' 'python-magnumclient' 'python-heatclient' - 'python-swiftclient' 'python-ironicclient' 'python-troveclient' - 'python-neutronclient' 'python-cinderclient' 'python-glanceclient' - 'python-keystoneclient' 'python-novaclient' 'python-netifaces' - 'python-keystoneauth1' 'python-six' 'python-requestsexceptions' - 'python-os-client-config' 'python2-ipaddress' 'python-jsonpatch' - 'python-jmespath' 'python-decorator' 'python-munch' 'python-pbr') - cd "${srcdir}/shade-py2" + depends=('python2-pbr' 'python2-decorator' 'python2-jmespath' + 'python2-jsonpatch' 'python2-ipaddress' 'python2-os-client-config' + 'python2-requestsexceptions' 'python2-six' 'python2-futures' + 'python2-keystoneauth1' 'python2-netifaces' 'python2-novaclient' + 'python2-keystoneclient' 'python2-cinderclient' + 'python2-neutronclient' 'python2-ironicclient' + 'python2-designateclient' 'python2-dogpile.cache') + cd "${srcdir}/${_module}-py2" python2 setup.py install --root="${pkgdir}" --optimize=1 mv "${pkgdir}"/usr/bin/shade-inventory{,2} } |