aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py-s3transfer/APKBUILD
blob: c2560fd63b929a8d5ad133684512b7f3dcf20746 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Maintainer: Valery Kartel <valery.kartel@gmail.com>
# Contributor: Valery Kartel <valery.kartel@gmail.com>
pkgname=py-s3transfer
_pkgname=${pkgname#py-}
pkgver=0.1.10
pkgrel=0
pkgdesc="Amazon S3 Transfer Manager for Python"
url="https://github.com/boto/s3transfer"
arch="noarch"
license="apache2"
makedepends="python2-dev python3-dev py-setuptools"
subpackages="py3-$_pkgname:_py3 py2-$_pkgname:_py2"
source="$_pkgname-$pkgver.tar.gz::https://github.com/boto/$_pkgname/archive/$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="25d8d4d134d9b820b58e139803330e8a  s3transfer-0.1.10.tar.gz"
sha256sums="9d5083fdefc22bd9a4e1c5bc84682f43db308403a034dbe8898850c030a428e8  s3transfer-0.1.10.tar.gz"
sha512sums="9d8b2ef688e90809c8edff42e3ea9a9c5d4a4f908cbcd7d90ab9630eb4a5cdd3326b9a4f3f9b4534e494d9accc9a236c43a5fa627048d6f79a2d3d7650e64e37  s3transfer-0.1.10.tar.gz"