#Maintainer: Shador pkgname=powertop pkgver=1.11 pkgrel=1ab arch=i486 source=("http://www.lesswatts.org/projects/powertop/download/powertop-$pkgver.tar.gz") sourcetemplate="http://gaia.homelinux.org/salix/packages/$pkgname/$pkgver/" docs=("readme" "copying" "changelog") url='http://www.lesswatts.org/projects/powertop/' slackdesc=\ ( #|-----handy-ruler------------------------------------------------------| "$pkgname (a tool to improve powersaving on Intel)" "PowerTOP is a Linux tool that helps you find those programs that are" "misbehaving while your computer is idle. PowerTOP has these 4 goals:" "* Show how well your system is using the various hardware power-saving" " features" "* Show you the culprit software components that are preventing optimal" " usage of your hardware power savings" "* Help Linux developers test their application and achieve optimal" " behavior" "* Provide you with tuning suggestions to achieve low power consumption" ) 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/powertop-$pkgver make $threads || return 1 make install DESTDIR=$startdir/pkg || return 1 }