#Maintainer: Shador pkgname=xpenguins pkgver=2.2 pkgrel=1ab arch=x86_64 source=("http://xpenguins.seul.org/xpenguins-2.2.tar.gz" "xpenguins.png") sourcetemplate="http://gaia.homelinux.org/salix/packages-x86_64/$pkgname/$pkgver/" docs=("readme" "install" "copying" "changelog" "authors" "news") url='http://xpenguins.seul.org/' slackdesc=\ ( #|-----handy-ruler------------------------------------------------------| "$pkgname (a Desktop decoration with walking penguins)" "Ever wanted cute little penguins walking along the tops of your" "windows? Ever wanted to send an army of cute little penguins to invade" "the screen of someone else on your network? Probably not, but why not" "try this program out anyway - it's free (licensed under the GNU GPL)." ) 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 mkdir -vp $startdir/pkg/usr/bin/ cat >$startdir/pkg/usr/bin/xpenguins-menu </dev/null 2>&1; then xpenguins >/dev/null 2>&1 & sleep 2s exit else killall xpenguins >/dev/null 2>&1 fi sleep 4s if pgrep "^xpenguins$" >/dev/null 2>&1; then killall -9 xpenguins >/dev/null 2>&1 fi EOF chmod +x $startdir/pkg/usr/bin/xpenguins-menu mkdir -vp $startdir/pkg/usr/share/applications/ cat >$startdir/pkg/usr/share/applications/xpenguins.desktop <