#Packager: Shador pkgname=stressapptest pkgver=1.0.3 pkgrel=1ab #arch=x86_64 source=("http://stressapptest.googlecode.com/files/stressapptest-${pkgver}_autoconf.tar.gz") sourcetemplate="http://gaia.homelinux.org/salix/packages-x86_64/$pkgname/$pkgver/" docs=("copying") url='http://code.google.com/p/stressapptest/' slackdesc=\ ( #|-----handy-ruler------------------------------------------------------| "$pkgname (Stressful Application Test)" "Stressful Application Test (or stressapptest, its unix name) tries to" "maximize randomized traffic to memory from processor and I/O, with the" "intent of creating a realistic high load situation in order to test" "the existing hardware devices in a computer." ) 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/stressapptest-${pkgver}_autoconf sed -e 's#LIBS="$LIBS -static -lrt -pthread -laio"#LIBS="$LIBS -lrt -pthread -laio"#' \ -i configure ./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 install -vD -m644 $startdir/pkg/usr/share/doc/stressapptest/stressapptest.1 $startdir/pkg/usr/man/man1/stressapptest.1 rm -r $startdir/pkg/usr/share/ }