aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authorAndré Klitzing <aklitzing@gmail.com>2017-03-27 20:47:17 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2017-05-25 11:24:08 +0000
commit5bb70e15e5fb2e62402825ae6712d9776a3244f1 (patch)
treedf29115475d221a08d66cd8c36cd5b2d85197154 /testing
parent140658f032d006250507e0e4f8f2f25d564644b2 (diff)
downloadaports-5bb70e15e5fb2e62402825ae6712d9776a3244f1.tar.bz2
aports-5bb70e15e5fb2e62402825ae6712d9776a3244f1.tar.xz
testing/py-sortedcontainers: new aport
Diffstat (limited to 'testing')
-rw-r--r--testing/py-sortedcontainers/APKBUILD46
1 files changed, 46 insertions, 0 deletions
diff --git a/testing/py-sortedcontainers/APKBUILD b/testing/py-sortedcontainers/APKBUILD
new file mode 100644
index 0000000000..9cc312378a
--- /dev/null
+++ b/testing/py-sortedcontainers/APKBUILD
@@ -0,0 +1,46 @@
+# Contributor: André Klitzing <aklitzing@gmail.com>
+# Maintainer: André Klitzing <aklitzing@gmail.com>
+pkgname=py-sortedcontainers
+_pkgname=sortedcontainers
+pkgver=1.5.7
+pkgrel=0
+pkgdesc="Python Sorted Container Types: SortedList, SortedDict, and SortedSet"
+url="http://www.grantjenks.com/docs/sortedcontainers/"
+arch="noarch"
+license="Apache"
+makedepends="python2-dev py-setuptools python3-dev"
+subpackages="py3-${pkgname#py-}:_py3 py2-${pkgname#py-}:_py2"
+options="!check"
+source="$_pkgname-$pkgver.tar.gz::https://github.com/grantjenks/sorted_containers/archive/v$pkgver.tar.gz"
+builddir="$srcdir/sorted_containers-$pkgver"
+
+build() {
+ cd "$builddir"
+ python2 setup.py build || return 1
+ python3 setup.py build || return 1
+}
+
+package() {
+ mkdir -p "$pkgdir"
+}
+
+_py() {
+ local python="$1"
+ pkgdesc="$pkgdesc (for $python)"
+ depends="$python"
+ install_if="$pkgname=$pkgver-r$pkgrel $python"
+
+ cd "$builddir"
+ $python setup.py install --prefix=/usr --root="$subpkgdir"
+}
+
+_py2() {
+ replaces="$pkgname"
+ _py python2
+}
+
+_py3() {
+ _py python3
+}
+
+sha512sums="9b6aef9c95c5543e06e7ee8bd89f86de7ce8f5b518663256113fdbbbd5a9f800c2e9f0ad993acc497f78ae665dd8473369912b3780df565403aee1c519b72814 sortedcontainers-1.5.7.tar.gz"