summaryrefslogtreecommitdiff
path: root/user/py3-random2/APKBUILD
diff options
context:
space:
mode:
authorZach van Rijn <me@zv.io>2022-04-22 07:54:28 +0000
committerZach van Rijn <me@zv.io>2022-06-12 23:51:31 +0000
commit860ad76a3d51e31700cbd4897b1a8bf54bf4aac3 (patch)
treecc1bcc77bb11e54c24577e4066f3ea9cfd397264 /user/py3-random2/APKBUILD
parentb4d5da1e571b915a4d276dfd016bf8e124483b8f (diff)
downloadpackages-860ad76a3d51e31700cbd4897b1a8bf54bf4aac3.tar.gz
packages-860ad76a3d51e31700cbd4897b1a8bf54bf4aac3.tar.bz2
packages-860ad76a3d51e31700cbd4897b1a8bf54bf4aac3.tar.xz
packages-860ad76a3d51e31700cbd4897b1a8bf54bf4aac3.zip
user/py3-random2: remove broken test. fixes #556.
Diffstat (limited to 'user/py3-random2/APKBUILD')
-rw-r--r--user/py3-random2/APKBUILD13
1 files changed, 11 insertions, 2 deletions
diff --git a/user/py3-random2/APKBUILD b/user/py3-random2/APKBUILD
index da7838e39..776c0889d 100644
--- a/user/py3-random2/APKBUILD
+++ b/user/py3-random2/APKBUILD
@@ -5,9 +5,9 @@ _pkgname=random2
_p="${_pkgname#?}"
_p="${_pkgname%"$_p"}"
pkgver=1.0.1
-pkgrel=0
+pkgrel=1
pkgdesc="A Python module implementing Python 2's RNG"
-url="https://pypi.python.org/pypi/random2"
+url="https://pypi.org/project/random2/"
arch="noarch"
license="Python-2.0"
depends="python3"
@@ -15,6 +15,15 @@ makedepends="python3-dev"
source="$pkgname-$pkgver.zip::https://files.pythonhosted.org/packages/source/$_p/$_pkgname/$_pkgname-$pkgver.zip"
builddir="$srcdir/$_pkgname-$pkgver"
+prepare() {
+ default_prepare
+
+ # Remove a test that is invalid as of python 3.9
+ # Taken from Fedora .spec
+ # https://src.fedoraproject.org/rpms/python-random2/blob/rawhide/f/python-random2.spec
+ sed -i '/self\.gen\.getrandbits, 0/d' src/tests.py
+}
+
build() {
python3 setup.py build
}