Date: Tuesday, November 29, 2022 @ 05:42:31 Author: felixonmars Revision: 1354979
upgpkg: python-pystemmer 2.2.0-1 Modified: python-pystemmer/trunk/PKGBUILD ----------+ PKGBUILD | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2022-11-29 05:28:41 UTC (rev 1354978) +++ PKGBUILD 2022-11-29 05:42:31 UTC (rev 1354979) @@ -1,34 +1,41 @@ # Maintainer: Felix Yan <[email protected]> pkgname=python-pystemmer -pkgver=2.0.1 -pkgrel=4 +pkgver=2.2.0 +pkgrel=1 pkgdesc="Snowball stemming algorithms, for information retrieval" arch=('x86_64') license=('BSD' 'MIT') url="http://snowball.tartarus.org" -depends=('python') +depends=('python' 'libstemmer') makedepends=('cython' 'python-setuptools') -source=("https://pypi.io/packages/source/P/PyStemmer/PyStemmer-$pkgver.tar.gz") -sha512sums=('3ac0ef16f0caae74cb19a73e7de7a56e3947a6f81a14273885b3461392f7f33e82a433d4ffa7b4a61d87bb94aff7e12c8e0c9726de2eb6b386a9f2c558678a6c') +source=("https://pypi.io/packages/source/P/PyStemmer/PyStemmer-$pkgver.tar.gz" + $pkgname-fix-tests.patch::https://github.com/snowballstem/pystemmer/pull/38.patch + $pkgname-system-libstemmer.patch::https://github.com/snowballstem/pystemmer/pull/39.patch) +sha512sums=('4499cf725de30b168f4a0c341653f5286e45a86e1bcd1fa8cb62ebf9ea3c05dd17479aa5c6780b4fb386c63becbc9faeb3e4e23037b677bb2bd59501ee061fea' + 'b62f42cacb1d1d7c38f1ecde8c50b1a5df2285a26ca67f777f500c5d34d5f0c16fbb0be42dc54bdee656f99b7e03f6b09b4cb5bdf638418167aa1c14f3ffaacd' + 'ee521e8e64a66d1fb84d5cb7cfbdf61631822e82f3c65a2478b27ac92c11d6b7685d44e87c216c9f990624afe767ab50375f1f60ab41b1f83d0494cdd24c2c9d') prepare() { # Force cython rebuild rm PyStemmer-$pkgver/src/Stemmer.c + + patch -d PyStemmer-$pkgver -p1 -i ../$pkgname-fix-tests.patch + patch -d PyStemmer-$pkgver -p1 -i ../$pkgname-system-libstemmer.patch } build() { - cd "$srcdir/PyStemmer-$pkgver" - python setup.py build + cd PyStemmer-$pkgver + PYSTEMMER_SYSTEM_LIBSTEMMER=1 python setup.py build } check() { - cd "$srcdir/PyStemmer-$pkgver" - PYTHONPATH="$PWD/build/lib.linux-$CARCH-3.10:$PYTHONPATH" python runtests.py + cd PyStemmer-$pkgver + PYTHONPATH="$PWD/build/lib.linux-$CARCH-cpython-310" python runtests.py } package() { cd PyStemmer-$pkgver - python setup.py install --root="${pkgdir}" --optimize=1 - install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + PYSTEMMER_SYSTEM_LIBSTEMMER=1 python setup.py install --root="$pkgdir" --optimize=1 + install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/ }
