# Contributor: Cameron Banta <cbanta@gmail.com>
# Maintainer: Cameron Banta <cbanta@gmail.com>
pkgname=less
pkgver=529
pkgrel=0
pkgdesc="File pager"
url="http://www.greenwoodsoftware.com/less/"
arch="all"
license="GPL"
options="!check"
makedepends="ncurses-dev"
subpackages="$pkgname-doc"
source="http://www.greenwoodsoftware.com/$pkgname/$pkgname-$pkgver.tar.gz"
builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	default_prepare

	cd "$builddir"
	chmod +x configure
}

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

sha512sums="902e3ed86161c5a9eb3c08567b6b702371b5c88a85ef0b21beada223eaa47e0abf4d4d166a4a7a195caef67509fa683d07d0b6a40b529d703ee26aa8910c360a  less-529.tar.gz"
