aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py3-rarfile/APKBUILD
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2019-07-02 04:17:44 -0300
committerLeo <thinkabit.ukim@gmail.com>2019-07-03 08:06:01 -0300
commit8e4fc9523c0af77c074392aa1cbb2840608973b9 (patch)
tree231a8c0dd5e6284fe2fd05e6b279de5cc52d0777 /testing/py3-rarfile/APKBUILD
parentda068f57db55cd931f2d5afc64ba6412be6722a2 (diff)
downloadaports-8e4fc9523c0af77c074392aa1cbb2840608973b9.tar.bz2
aports-8e4fc9523c0af77c074392aa1cbb2840608973b9.tar.xz
testing/py3-rarfile: rename from py-rarfile
Diffstat (limited to 'testing/py3-rarfile/APKBUILD')
-rw-r--r--testing/py3-rarfile/APKBUILD47
1 files changed, 47 insertions, 0 deletions
diff --git a/testing/py3-rarfile/APKBUILD b/testing/py3-rarfile/APKBUILD
new file mode 100644
index 0000000000..2d24dd525b
--- /dev/null
+++ b/testing/py3-rarfile/APKBUILD
@@ -0,0 +1,47 @@
+# Contributor: Fabian Affolter <fabian@affolter-engineering.ch>
+# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
+pkgname=py-rarfile
+_pkgname=rarfile
+pkgver=3.0
+pkgrel=2
+pkgdesc="A RAR archive reader"
+url="https://github.com/markokr/rarfile"
+arch="noarch"
+license="ISC"
+makedepends="python2-dev python3-dev py-setuptools"
+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"
+ _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"
+}
+
+md5sums="d7e9a8b429f5604730400b4db3362038 rarfile-3.0.tar.gz"
+sha256sums="e816409e3b36794507cbe0b678bed3e4703d7412c5f7f9201a510ed6fdc66c35 rarfile-3.0.tar.gz"
+sha512sums="b0b816bf09fe455e4d8d35b447c30e7810468a6927555164a1b513d4161f3fd4e77a37439620bd935c3a12e46b1e5eda3e35d7d281899d2f9fd26b6e989aa6e4 rarfile-3.0.tar.gz"