#Maintainer: Shador pkgname=pv pkgver=1.1.4 pkgrel=1ab arch=x86_64 source=("http://pipeviewer.googlecode.com/files/pv-$pkgver.tar.bz2") sourcetemplate="http://gaia.homelinux.org/salix/packages-x86_64/$pkgname/$pkgver/" docs=("readme") url='http://www.ivarch.com/programs/pv.shtml' slackdesc=\ ( #|-----handy-ruler------------------------------------------------------| "$pkgname (Pipe Viewer)" "It's a terminal-based tool for monitoring the progress of data through" "a pipeline. It can be inserted into any normal pipeline between two" "processes to give a visual indication of how quickly data is passing" "through, how long it has taken, how near to completion it is, and an" "estimate of how long it will be until completion." ) build() { threadcount=$(($(sed -ne '/cpu cores/h;${g;s/[^0-9]*//p}' \ < /proc/cpuinfo)*2)) if [ $threadcount -lt 2 ]; then threadcount=2 elif [ $threadcount -gt 8 ]; then threadcount=8 fi threads="-j${threadcount}" cd $startdir/src/$pkgname-$pkgver ./configure \ --prefix=/usr \ --libdir=/usr/lib${LIBDIRSUFFIX} \ --localstatedir=/var \ --sysconfdir=/etc \ --mandir=/usr/man || return 1 make $threads || return 1 make install DESTDIR=$startdir/pkg || return 1 for file in doc/*; do install -vD -m644 $file $startdir/pkg/usr/doc/pv-$pkgver/${file#doc/} done }