# Maintainer (AUR): Kevin Brubeck Unhammer <unhammer@fsfe.org>
# Contributor: bill-auger <bill-auger@programmer.net>


_upstream_name=cg3
pkgname=vislcg3
pkgver=1.3.2
pkgrel=1
pkgdesc="Compiler and parser for Constraint Grammar (CG), a paradigm for robust, rule-based Natural Language Parsing."
arch=(x86_64)
arch+=(armv7h i686)
url=http://beta.visl.sdu.dk/cg3.html
license=(GPL3)

depends_armv7h=(libicui18n.so libicuuc.so)
depends_i686=(libicui18n.so libicuuc.so)
depends_x86_64=(libicui18n.so libicuuc.so)
makedepends=(boost gperftools cmake)
optdepends=("perl: cg3-autobin.pl auto-compile-and-run wrapper")
options=(!libtool)
install=vislcg3.install

source=(${pkgname}-${pkgver}.tar.gz::https://github.com/TinoDidriksen/${_upstream_name}/archive/v${pkgver}.tar.gz)
sha256sums=('ce1a954f761137cad0b740c4f5e37220589cbd056b4fd69e30dd51e141d96da3')
b2sums=('c598620ab4b673ed202a6817d9d3d0d5f738fcb2f88b31b1ad27825442471ef7d2d235fc758c326561862de774cf2d843f4061982e44a734e9b89f38f9d09397')


build()
{
  cd "$srcdir"/${_upstream_name}-${pkgver}

  ./cmake.sh -D CMAKE_INSTALL_PREFIX=/usr && make
}

package()
{
  cd "$srcdir"/${_upstream_name}-${pkgver}

  make DESTDIR="${pkgdir}"/ install
}
