#!/bin/sh # Set initial variables: CWD=`pwd` if [ "$TMP" = "" ]; then TMP=/tmp fi PKG=$TMP/package-cmatrix 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 # Explode the package framework: cd $PKG explodepkg $CWD/_cmatrix.tar.gz echo "+==============+" echo "| cmatrix-1.0b |" echo "+==============+" cd $TMP tar xzvf $CWD/cmatrix-1.0b.tar.gz cd cmatrix-1.0b make clean make cat cmatrix > $PKG/usr/bin/cmatrix cat cmatrix.1 | gzip -9c > $PKG/usr/man/man1/cmatrix.1.gz cat matrix.fnt > $PKG/usr/lib/kbd/consolefonts/matrix.fnt cat matrix.psf.gz > $PKG/usr/lib/kbd/consolefonts/matrix.psf.gz cat mtx.pcf > $PKG/usr/X11R6/lib/fonts/misc/mtx.pcf cp -a COPYING Changelog README README.fonts TODO \ $PKG/usr/doc/cmatrix-1.0b chown root.root $PKG/usr/doc/cmatrix-1.0b/* chmod 644 $PKG/usr/doc/cmatrix-1.0b/* # Build the package: cd $PKG echo "n" | makepkg $TMP/cmatrix.tgz # Clean up the extra stuff: if [ "$1" = "--cleanup" ]; then rm -rf $TMP/cmatrix-1.0b rm -rf $PKG fi