#Maintainer:Tim Beech (tim~beech~at~gmail~dot~com)

pkgname=libacpi
pkgver=0.2
pkgrel=1tjb
#arch=
source=(http://www.ngolde.de/download/$pkgname-$pkgver.tar.gz)
sourcetemplate="http://people.salixos.org/mimosa/packages/$pkgname/$pkgver"
docs=("AUTHORS" "CHANGEFILE" "LICENSE" "COPYING" "README" "ChangeLog" "NEWS" "TODO" "INSTALL")
url="http://www.ngolde.de/libacpi.html"


slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"libacpi (general purpose library for acpi)"
"libacpi is a general purpose shared library for programs gathering"
"ACPI data on Linux. Features: thermal zones support, battery support,"
"fan support, AC support"

)


build() {
	cd $startdir/src/$pkgname-$pkgver
	# detect and use $LIBDIRSUFFIX
	echo 'LIBDIR = ${PREFIX}/lib${LIBDIRSUFFIX}' >> ./config.mk
	sed 's[${PREFIX}/lib[${LIBDIR}[' -i ./Makefile
	make || return 1
	make install PREFIX=/usr DESTDIR=$startdir/pkg 
	#add version number to name of docdir
	mv $startdir/pkg/usr/share/doc/libacpi $startdir/pkg/usr/share/doc/libacpi-$pkgver
}