[arch-commits] Commit in python-stestr/repos (community-any community-any/PKGBUILD)

Felix Yan felixonmars at archlinux.org
Thu Nov 30 09:55:07 UTC 2017


    Date: Thursday, November 30, 2017 @ 09:55:06
  Author: felixonmars
Revision: 270837

archrelease: copy trunk to community-any

Added:
  python-stestr/repos/community-any/
  python-stestr/repos/community-any/PKGBUILD
    (from rev 270836, python-stestr/trunk/PKGBUILD)

----------+
 PKGBUILD |   69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 69 insertions(+)

Copied: python-stestr/repos/community-any/PKGBUILD (from rev 270836, python-stestr/trunk/PKGBUILD)
===================================================================
--- community-any/PKGBUILD	                        (rev 0)
+++ community-any/PKGBUILD	2017-11-30 09:55:06 UTC (rev 270837)
@@ -0,0 +1,69 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Simon Sapin <simon dot sapin at exyr dot org>
+# Contributor: Kyle Keen <keenerd at gmail.com>
+
+pkgbase=python-stestr
+pkgname=(python-stestr python2-stestr)
+pkgver=1.1.0
+pkgrel=1
+pkgdesc="The most basic Text::Unidecode port"
+url="https://github.com/kmike/stestr"
+license=('PerlArtistic')
+arch=('any')
+makedepends=('python-future' 'python2-future' 'python-pbr' 'python2-pbr' 'python-subunit'
+             'python2-subunit' 'python-fixtures' 'python2-fixtures' 'python-testtools'
+             'python2-testtools' 'python-yaml' 'python2-yaml')
+checkdepends=('python-hacking' 'python2-hacking' 'python-sphinx' 'python2-sphinx' 'python-mock'
+              'python2-mock' 'python-subunit2sql' 'python2-subunit2sql' 'python-coverage'
+              'python2-coverage' 'python-ddt' 'python2-ddt')
+source=("https://pypi.io/packages/source/s/stestr/stestr-$pkgver.tar.gz")
+sha512sums=('7490f0982c77190adf97daae965a957fc40d0e418a64fc38ccb50817a7266b06224e61f17ae9c84edfe200417eaab726cf834646bfa2efbac67ea029dea54df1')
+
+prepare() {
+  cp -a stestr-$pkgver{,-py2}
+}
+
+build() {
+  cd "$srcdir"/stestr-$pkgver
+  python setup.py build
+
+  cd "$srcdir"/stestr-$pkgver-py2
+  python2 setup.py build
+}
+
+check() {
+  cd "$srcdir"/stestr-$pkgver
+  python setup.py install --root="$PWD/tmp_install" --optimize=1
+  (
+    export PYTHONPATH="$PWD/tmp_install/usr/lib/python3.6/site-packages"
+    export PATH="$PWD/tmp_install/usr/bin:$PATH"
+    stestr run || warning "Tests failed"
+  )
+
+  cd "$srcdir"/stestr-$pkgver-py2
+  python2 setup.py install --root="$PWD/tmp_install" --optimize=1
+  (
+    export PYTHONPATH="$PWD/tmp_install/usr/lib/python2.7/site-packages"
+    export PATH="$PWD/tmp_install/usr/bin:$PATH"
+    stestr run || warning "Tests failed"
+  )
+}
+
+package_python-stestr() {
+  depends=('python-future' 'python-pbr' 'python-subunit' 'python-fixtures' 'python-testtools'
+           'python-yaml')
+
+  cd stestr-$pkgver
+  python setup.py install --root="$pkgdir" --optimize=1
+}
+
+package_python2-stestr() {
+  depends=('python2-future' 'python2-pbr' 'python2-subunit' 'python2-fixtures' 'python2-testtools'
+           'python2-yaml')
+
+  cd stestr-$pkgver-py2
+  python2 setup.py install --root="$pkgdir" --optimize=1
+
+  mv "$pkgdir"/usr/bin/stestr{,2}
+}



More information about the arch-commits mailing list