# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=slang
pkgver=2.3.1a
pkgrel=0
pkgdesc="S-Lang is a powerful interpreted language"
url="http://www.jedsoft.org/slang/"
arch="all"
license="GPL"
subpackages="$pkgname-dev $pkgname-doc"
depends=
makedepends="pcre-dev ncurses-dev"
source="http://www.jedsoft.org/releases/$pkgname/$pkgname-$pkgver.tar.bz2"

builddir="$srcdir"/$pkgname-$pkgver
build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		|| return 1
	make -j1 elf static || return 1
	cd slsh && make || return 1
}

package() {
	cd "$builddir"
	make -j1 install-all DESTDIR="$pkgdir" || return 1
}

sha512sums="e7236a189081ebcbaf4e7f0506671226a4d46aede8826e1a558f1a2f57bcbe3ad58eadeabe2df99cd3d8bacb4c93749996bcbce4f51d338fc9396e0f945933e7  slang-2.3.1a.tar.bz2"
