#Packager: Shador <futur~DOT~andy~AT~googlemail.com>

pkgname=mpc
pkgver=0.21
pkgrel=1ab
source=("http://downloads.sourceforge.net/project/musicpd/mpc/0.21/mpc-0.21.tar.bz2")
sourcetemplate="http://gaia.homelinux.org/salix/slkbuilds/$pkgname/"
docs=("readme" "install" "copying" "authors" "news")
url='http://mpd.wikia.com/wiki/Client:Mpc'
options=('noautodotnew')

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"$pkgname (a command line interface to MPD)"
"A minimalist command line interface to MPD, not to be confused with"
"musepack."
)


build() {
	set -e

	cd $startdir/src/$pkgname-$pkgver

	./configure \
		--prefix=/usr \
		--libdir=/usr/lib${LIBDIRSUFFIX} \
		--localstatedir=/var \
		--sysconfdir=/etc \
		--mandir=/usr/man \
		--docdir=/usr/doc/$pkgname-$pkgver/ \
		--build=$arch-slackware-linux|| return 1
	make -j $numjobs || return 1
	make install DESTDIR=$startdir/pkg || return 1

	install -vD -m644 \
		$startdir/pkg/usr/doc/$pkgname-$pkgver/mpc-completion.bash \
		$startdir/pkg/etc/bash_completion.d/mpc
	rm $startdir/pkg/usr/doc/$pkgname-$pkgver/mpc-completion.bash

	set +e
}