#!/bin/sh
# MANUAL COMPILE ONLY, NOT INSTALL

usage() {
cat <<EOF
bp - Build one or more tarball directories

usage: bp <path-to-tar.bz2> 

Examples:
   bp src/cli/CORE/vasm2
   bp src/cli/CORE/*
EOF
}

if [ -z "$1" ] || [ "$1" = "-h" ] || [ "$1" = "--help" ]; then
    usage
    exit 0
fi

. ./config.extra

export OVERWRITE_PKG=yes
export INSTALL_PKG="no"
export INSTALL_HOST="no"

CWD=`pwd`
while [ $1 ]; do
    if [ -d $1 ] && [ "${1##*.}" != "bak" ]; then
        cd $1
	PLONG=`pwd`
	GLONG=`dirname $PLONG`
	GSHORT=${GLONG#$TAR_BASE/}
	install-group $GSHORT `basename $1`
    fi
    cd $CWD
    shift
done


