#!/bin/sh
# $Id: generic-build,v 1.1.1.1 2002/01/22 19:54:41 hartmans Exp $
if test $# -ne 1 -a $# -ne 2; then
  echo "Usage: $0 file [directory]"
  exit 1
fi
filename=$1
if test $# -gt 1; then
  b=$2
else
  b=`basename $filename .tar.gz`
fi
obj=$b-obj

gzip -dc $filename | tar xvf - >&4 2>&1 || exit 1
cd $b || exit 1
./configure >&4 || exit 1
make $MAKEFLAGS >&4 || exit 1
