Date: Thursday, December 24, 2020 @ 12:59:53 Author: archange Revision: 787194
Initial addition of python-textdistance to [community] Added: python-textdistance/ python-textdistance/repos/ python-textdistance/trunk/ python-textdistance/trunk/PKGBUILD ----------+ PKGBUILD | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) Added: python-textdistance/trunk/PKGBUILD =================================================================== --- python-textdistance/trunk/PKGBUILD (rev 0) +++ python-textdistance/trunk/PKGBUILD 2020-12-24 12:59:53 UTC (rev 787194) @@ -0,0 +1,47 @@ +# Maintainer: Bruno Pagani <[email protected]> + +_pkg=textdistance +pkgname=python-${_pkg} +pkgver=4.2.0 +pkgrel=1 +pkgdesc="Compute distance between sequences" +arch=(any) +url="https://github.com/life4/textdistance" +license=(MIT) +depends=( + python-abydos + python-jellyfish + python-numpy + python-levenshtein + python-pyxdameraulevenshtein +) +makedepends=(python-setuptools) +checkdepends=( + python-pytest + python-hypothesis + python-isort + python-pylev + python-py_stringmatching + python-tabulate +) +# PyPi tarballs do not have the tests +#source=(https://files.pythonhosted.org/packages/source/${_pkg::1}/${_pkg}/${_pkg}-${pkgver}.tar.gz) +source=(${url}/archive/v.${pkgver}/${_pkg}-${pkgver}.tar.gz) +sha256sums=('b2c9865b47a4c83e461337bcd9f038d8c202af18987d531be8a6ea5abc62b25e') + +build() { + cd ${_pkg}-v.${pkgver} + python setup.py build +} + +check() { + cd ${_pkg}-v.${pkgver} + # Failing tests, nowhere to report them… + pytest --deselect tests/test_external.py +} + +package() { + cd ${_pkg}-v.${pkgver} + python setup.py install --prefix=/usr --root="${pkgdir}" --skip-build --optimize=1 + install -Dm644 LICENSE -t "${pkgdir}"/usr/share/licenses/${pkgname} +}
