1 # Contributor: Philanecros Heliostein <philanecros@gmail.com>
3 pkgname="python2-mmseg"
6 pkgdesc="Chinese Segment On MMSeg Algorithm"
10 url="http://pypi.python.org/pypi/mmseg/"
15 depends=('python2>=2.6')
29 source=('http://pypi.python.org/packages/source/m/mmseg/mmseg-1.2.4.tar.gz')
31 md5sums=('a0531287013bb08f258f9e2023c212b1')
34 cd "${srcdir}/mmseg-${pkgver}"
36 # replace /usr/bin/env python with python2
37 find . -name '*.py' -exec sed -i -e '1 s/python\s*$/python2/' {} \;
39 python2 ./setup.py build || return 1
43 cd "${srcdir}/mmseg-${pkgver}"
45 python2 ./setup.py install --root=${pkgdir} --prefix=/usr || return 1