#!/bin/sh # Set initial variables: CWD=`pwd` if [ "$TMP" = "" ]; then TMP=/tmp fi PKG=$TMP/package-workbone VERSION=2.40 ARCH=i386 BUILD=2 if [ ! -d $TMP ]; then mkdir -p $TMP # location to build the source fi if [ ! -d $PKG ]; then mkdir -p $PKG # place for the package to be built fi echo "+===============+" echo "| workbone-$VERSION |" echo "+===============+" cd $TMP tar xzvf $CWD/workbone_$VERSION.orig.tar.gz cd workbone-2.4 zcat $CWD/workbone_$VERSION-2.diff.gz | patch -p1 make mkdir -p $PKG/usr/bin cat workbone > $PKG/usr/bin/workbone chmod 755 $PKG/usr/bin/workbone chown -R root.bin $PKG/usr/bin mkdir -p $PKG/usr/man/man1 cat workbone.1 | gzip -9c > $PKG/usr/man/man1/workbone.1.gz mkdir -p $PKG/usr/doc/workbone-$VERSION cp -a README $PKG/usr/doc/workbone-$VERSION chown root.root $PKG/usr/doc/workbone-$VERSION/README chmod 644 $PKG/usr/doc/workbone-$VERSION/README mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc # Build the package: cd $PKG makepkg -l y -c n $TMP/workbone-$VERSION-$ARCH-$BUILD.tgz # Clean up the extra stuff: if [ "$1" = "--cleanup" ]; then rm -rf $TMP/workbone-$VERSION.orig rm -rf $PKG fi