diff options
author | Jakub Jirutka <jakub@jirutka.cz> | 2018-06-26 14:17:36 +0200 |
---|---|---|
committer | Jakub Jirutka <jakub@jirutka.cz> | 2018-06-26 14:34:03 +0200 |
commit | e8837373b8ca34b34195002fb5308b02b70b6c2e (patch) | |
tree | b3d401b1cae8b23c9ce9b4a98ee02d02e937afda /community | |
parent | 2484b3eda99f681c7de0866b438f63cdcc31b5da (diff) | |
download | aports-e8837373b8ca34b34195002fb5308b02b70b6c2e.tar.bz2 aports-e8837373b8ca34b34195002fb5308b02b70b6c2e.tar.xz |
community/py-atomicwrites: new aport
This aport is needed for community/pytest.
Diffstat (limited to 'community')
-rw-r--r-- | community/py-atomicwrites/APKBUILD | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/community/py-atomicwrites/APKBUILD b/community/py-atomicwrites/APKBUILD new file mode 100644 index 0000000000..48c51cb799 --- /dev/null +++ b/community/py-atomicwrites/APKBUILD @@ -0,0 +1,45 @@ +# Contributor: Jakub Jirutka <jakub@jirutka.cz> +# Maintainer: Jakub Jirutka <jakub@jirutka.cz> +pkgname=py-atomicwrites +_pkgname=python-atomicwrites +pkgver=1.1.5 +pkgrel=0 +pkgdesc="Powerful Python library for atomic file writes" +url="https://github.com/untitaker/python-atomicwrites" +arch="noarch" +license="MIT" +makedepends="python2-dev python3-dev py-setuptools" +options="!check" # requires pytest which depends on this aport (cyclic dep) +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +source="https://github.com/untitaker/python-atomicwrites/archive/$pkgver/$_pkgname-$pkgver.tar.gz" +builddir="$srcdir/$_pkgname-$pkgver" + +build() { + cd "$builddir" + python2 setup.py build + python3 setup.py build +} + +package() { + mkdir -p "$pkgdir" +} + +_py2() { + _py python2 +} + +_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" +} + +sha512sums="8fba7bf6270c2a5d2925c14c4620e3b391fe333617ee3ddee5d3559d39ad9cbdd61fafc715bb9c1802b35079c18ae1a8330c29c24a9c980886b4a73660d3941a python-atomicwrites-1.1.5.tar.gz" |