# Contributor: Carlo Landmeter # Maintainer: Fabian Affolter pkgname=py-snowballstemmer _pkgname=snowballstemmer pkgver=1.9.1 pkgrel=0 pkgdesc="Snowball stemming library collection for Python" url="https://github.com/shibukawa/snowball_py" arch="noarch" license="BSD-3-Clause" makedepends="py3-setuptools 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 python3 setup.py build } 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" } sha512sums="014cad553ce5be67e614f51a6023e1673c34ee6cdaad7de872aadad385c3ab5599cc06fa7449819da5f61a91ea45eab8fcf85315a2c2b89979edb70c7d29501b snowballstemmer-1.9.1.tar.gz"