desktop/python-pyenchant/PKGBUILD

54 lines
1.4 KiB
Bash

# Contributor: Pierre Buard <pierre.buard@gmail.com>
# Contributor: Allan McRae <allan@archlinux.org>
# Contributor: Sebastien Piccand <sebcactus gmail com>
# Contributor: Daniel J Griffiths <ghost1227@archlinux.us>
# Maintainer: Jelle van der Waa <jelle@archlinux.org>
pkgname=('python3-pyenchant' 'python2-pyenchant')
pkgver=2.0.0
pkgrel=2
arch=('any')
url="https://pypi.python.org/pypi/pyenchant"
license=('LGPL')
makedepends=('python2-setuptools' 'python3-setuptools' 'enchant')
source=("https://github.com/rfk/pyenchant/archive/v${pkgver}.tar.gz"
"enchant-2.patch")
md5sums=('e969ea446971410a780c3e5aac23978c'
'5db60f4ad048772599f4e496b9f93385')
prepare() {
cd ${srcdir}/pyenchant-${pkgver}
patch -Np1 -i "${srcdir}/enchant-2.patch"
}
build() {
cp -r pyenchant-${pkgver} pyenchant2-${pkgver}
cd ${srcdir}/pyenchant-${pkgver}
python3 setup.py build
cd ${srcdir}/pyenchant2-${pkgver}
python2 setup.py build
}
package_python3-pyenchant() {
pkgdesc="PyEnchant is a spellchecking library for Python3 based on the Enchant library"
depends=('python3' 'enchant')
cd pyenchant-${pkgver}
python3 setup.py install --root=${pkgdir} --optimize=1
}
package_python2-pyenchant() {
pkgdesc="PyEnchant is a spellchecking library for Python2 based on the Enchant library"
depends=('python2' 'enchant')
cd pyenchant2-${pkgver}
python2 setup.py install --root=${pkgdir} --optimize=1
}