diff options
author | Fabian Affolter <fabian@affolter-engineering.ch> | 2016-12-28 15:43:40 +0000 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2016-12-28 19:20:01 +0200 |
commit | 98d1dca9e329dbe39ee3f3f807827444c47bc85e (patch) | |
tree | 50a938aeaf23e10c2ed386ad81c60d2599654762 /testing/py-transitions | |
parent | 30693297afc4818b64cdc72f88b0b893563dce09 (diff) | |
download | aports-98d1dca9e329dbe39ee3f3f807827444c47bc85e.tar.bz2 aports-98d1dca9e329dbe39ee3f3f807827444c47bc85e.tar.xz |
testing/py-transitions: new aport
A lightweight, object-oriented Python state machine implementation
https://github.com/tyarkoni/transitions
Diffstat (limited to 'testing/py-transitions')
-rw-r--r-- | testing/py-transitions/APKBUILD | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/testing/py-transitions/APKBUILD b/testing/py-transitions/APKBUILD new file mode 100644 index 0000000000..78ec0fea4e --- /dev/null +++ b/testing/py-transitions/APKBUILD @@ -0,0 +1,50 @@ +# Contributor: Fabian Affolter <fabian@affolter-engineering.ch> +# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch> +pkgname=py-transitions +_pkgname=transitions +pkgver=0.4.2 +pkgrel=0 +pkgdesc="A lightweight, object-oriented Python state machine implementation" +url="https://github.com/tyarkoni/transitions" +arch="noarch" +license="MIT" +depends="py-six" +makedepends="python2-dev py-setuptools python3-dev" +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz" +builddir="$srcdir"/$_pkgname-$pkgver + +build() { + cd "$builddir" + python2 setup.py build || return 1 + python3 setup.py build || return 1 +} + +package() { + mkdir -p "$pkgdir" +} + +_py2() { + replaces="$pkgname" + depends="${depends//py-/py2-}" + _py python2 +} + +_py3() { + depends="${depends//py-/py3-}" + _py python3 +} + +_py() { + local python="$1" + pkgdesc="$pkgdesc (for $python)" + depends="$depends $python" + install_if="$pkgname=$pkgver-r$pkgrel $python" + + cd "$builddir" + $python setup.py install --prefix=/usr --root="$subpkgdir" +} + +md5sums="47c77f7ee61a997e297251a55e4e3019 transitions-0.4.2.tar.gz" +sha256sums="94752bed6d33351bf8bd07a944b27b446a1ecda48bdba16a57505a8beb3fac61 transitions-0.4.2.tar.gz" +sha512sums="8dc876ad12b8cc9813eb81a33a9b1e2cee669cdc2acf7dc18169b5aee3a91b2f55997054f35f0cb50261e66c43fc5d6bddc8d9f35125d2a690fcd0f2469d5802 transitions-0.4.2.tar.gz" |