summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorGrey Christoforo2018-11-27 23:10:19 +0000
committerGrey Christoforo2018-11-27 23:10:19 +0000
commit76313eb555bf33e72dfb54b78363c8a08b34c01a (patch)
tree8a0ea6d079a804a5948ec7382bebe8bbcdfec48d /PKGBUILD
downloadaur-76313eb555bf33e72dfb54b78363c8a08b34c01a.tar.gz
initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD39
1 files changed, 39 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..5c0f9188eafe
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,39 @@
+# Maintainer: Grey Christoforo <first name at last name dot net>
+
+pkgbase=python-tesserocr
+pkgname=('python-tesserocr' 'python2-tesserocr')
+_module='tesserocr'
+pkgver=2.3.1
+pkgrel=1
+pkgdesc="A simple, Pillow-friendly, Python wrapper around tesseract-ocr API using Cython"
+url="https://github.com/sirfz/tesserocr"
+depends=()
+makedepends=('python-setuptools' 'python2-setuptools')
+license=('MIT')
+arch=('any')
+source=("https://files.pythonhosted.org/packages/source/t/tesserocr/tesserocr-${pkgver}.tar.gz")
+md5sums=('99e2001affe861ae3a5aa2e9f233e2d7')
+
+prepare() {
+ cp -a "${srcdir}/${_module}-${pkgver}"{,-python2}
+}
+
+build() {
+ cd "${srcdir}/${_module}-${pkgver}"
+ python setup.py build
+
+ cd "${srcdir}/${_module}-${pkgver}-python2"
+ python2 setup.py build
+}
+
+package_python-tesserocr() {
+ depends+=('python')
+ cd "${srcdir}/${_module}-${pkgver}"
+ python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
+}
+
+package_python2-tesserocr() {
+ depends+=('python2')
+ cd "${srcdir}/${_module}-${pkgver}-python2"
+ python2 setup.py install --root="${pkgdir}" --optimize=1 --skip-build
+}