diff options
author | Leonardo Arena <rnalrd@alpinelinux.org> | 2019-01-16 15:16:42 +0000 |
---|---|---|
committer | Leonardo Arena <rnalrd@alpinelinux.org> | 2019-01-16 15:18:32 +0000 |
commit | 4ad883906b506b950ac0c335926e7b325c08b7bb (patch) | |
tree | 7afc1c02d98d2e66dbfdc346099e32e845767505 /testing/py-ruamel | |
parent | 74ad9f86d5cc7f6acf321b7f3c76e790ac458167 (diff) | |
download | aports-4ad883906b506b950ac0c335926e7b325c08b7bb.tar.bz2 aports-4ad883906b506b950ac0c335926e7b325c08b7bb.tar.xz |
testing/py-ruamel: new aport
Diffstat (limited to 'testing/py-ruamel')
-rw-r--r-- | testing/py-ruamel/APKBUILD | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/testing/py-ruamel/APKBUILD b/testing/py-ruamel/APKBUILD new file mode 100644 index 0000000000..5abe8184ba --- /dev/null +++ b/testing/py-ruamel/APKBUILD @@ -0,0 +1,56 @@ +# Contributor: Leonardo Arena <rnalrd@alpinelinux.org> +# Maintainer: +pkgname=py-ruamel +pkgver=0.15.86 +pkgrel=0 +pkgdesc="A YAML parser/emitter" +url="https://bitbucket.org/ruamel/yaml" +arch="all" +license="MIT" +depends="" +makedepends="python2-dev python3-dev py-setuptools" +checkdepends="" +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +options="!check" # no test suite +source="$pkgname-$pkgver.tar.bz2::https://bitbucket.org/ruamel/yaml/get/$pkgver.tar.bz2" +builddir="$srcdir"/ruamel-$pkgver + +# tarball has commit_id in path +unpack() { + mkdir -p "$builddir" + tar xjf "$srcdir"/$pkgname-$pkgver.tar.bz2 \ + --strip-components=1 -C $builddir +} + +build() { + cd "$builddir" + python2 setup.py --quiet build + python3 setup.py --quiet build +} + +package() { + cd "$builddir" + mkdir -p "$pkgdir"/usr/bin +} + +_py2() { + 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 --quiet install --prefix=/usr --root="$subpkgdir" +} + +sha512sums="bd67f45013118fc7d93435e25972e999c777a697f6df6f542d811fb558c6a3acb765ed819a5a0893fa2bc99685d6179d41ab9717aad2879e2f141e9899a72af7 py-ruamel-0.15.86.tar.bz2" |