#!/bin/sh

ANT_OPTS="-Xms128m -Xmx512m -XX:MaxPermSize=512m"

#
# setup to use bundled of ant
#

if test -d ../../apache-ant
then
    ANT_HOME=../../apache-ant
    export ANT_HOME
    ANT_RUN=$ANT_HOME/bin/ant
    export ANT_RUN
    PATH=$ANT_HOME/bin:$PATH
    export PATH
else
    echo "INFO: No bundled ant found (../../apache-ant). Using existing ant"
    ANT_RUN=ant
fi

#
# Collect the command line args
#

CMD_LINE_ARGS=$*

$ANT_RUN --noconfig -nouserlib -f build.xml $CMD_LINE_ARGS

