Date: Tuesday, April 11, 2023 @ 16:09:48 Author: dvzrv Revision: 1444686
upgpkg: python-jarowinkler 1.2.3-2: Rebuild against Python 3.11. Remove overly strict build requirement. Run tests against temporary installation in check(). Modified: python-jarowinkler/trunk/PKGBUILD ----------+ PKGBUILD | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2023-04-11 16:07:43 UTC (rev 1444685) +++ PKGBUILD 2023-04-11 16:09:48 UTC (rev 1444686) @@ -4,18 +4,36 @@ _name=jarowinkler pkgname=python-$_name pkgver=1.2.3 -pkgrel=1 +pkgrel=2 pkgdesc='A library for fast approximate string matching using Jaro and Jaro-Winkler similarity' arch=(x86_64) url='https://github.com/maxbachmann/JaroWinkler' license=(MIT) -depends=(python) -#makedepends=(jarowinkler-cpp python-rapidfuzz-capi python-scikit-build) -makedepends=(python-build python-installer python-setuptools python-scikit-build python-rapidfuzz-capi ninja) -checkdepends=(python-hypothesis python-pytest) +depends=( + gcc-libs + glibc + python +) +makedepends=( + python-build + python-installer + python-rapidfuzz-capi + python-scikit-build + python-setuptools + ninja +) +checkdepends=( + python-hypothesis + python-pytest +) source=("https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz") sha256sums=('af28ea284cfbd1b21b29ff94b759f20e94e4f7c06f424b0b4702e701c2a21668') +prepare() { + # remove strict build dependencies... + sed -e 's/==/>=/' -i $_name-$pkgver/pyproject.toml +} + build() { cd $_name-$pkgver JAROWINKLER_BUILD_EXTENSION=1 \ @@ -23,10 +41,12 @@ } check() { + local site_packages=$(python -c "import site; print(site.getsitepackages()[0])") + cd $_name-$pkgver - python -m venv --system-site-packages test-env - test-env/bin/python -m installer dist/*.whl - test-env/bin/python -m pytest + python -m installer --destdir=test_dir dist/*.whl + export PYTHONPATH="test_dir/$site_packages:$PYTHONPATH" + pytest -vv } package() {
