# Contributor: Chris Schwaab
pkgname=ats-lang-anairiats
pkgver=0.2.9
pkgrel=1
pkgdesc="A dependantly typed ML style programming language."
arch=('i686' 'x86_64')
url="http://www.ats-lang.org/"
license=('GPL3')
depends=('gmp')
provides=('ats-lang')
source=("http://downloads.sourceforge.net/project/ats-lang/ats-lang/anairiats-$pkgver/$pkgname-$pkgver.tgz")
md5sums=('2e05925f56b5062e86ebf51c98d8c4ae')

build() {
	cd "$pkgname-$pkgver"

	export ATSHOME="$(readlink -e `pwd`)"
	export ATSHOMERELOC=ATS-$pkgver
	./configure --prefix=/usr
	sed -i 's~bin/atsdoc~ccomp/runtime/GCATS/gc.o bin/atsdoc~' Makefile
        make -j1 all
        make DESTDIR=$pkgdir install
}