summaryrefslogtreecommitdiff
path: root/ant-common.sh
diff options
context:
space:
mode:
authormichelou <michelou@epfl.ch>2005-08-31 09:25:58 +0000
committermichelou <michelou@epfl.ch>2005-08-31 09:25:58 +0000
commit6c2eeae273552ed0be32b90d0c5604d07509e454 (patch)
tree61912ce22d91c79aff7e56105ae20cd932a7c9ab /ant-common.sh
parent573e3db24e87633552d803ef3ebac11ca5dcbc17 (diff)
downloadscala-6c2eeae273552ed0be32b90d0c5604d07509e454.tar.gz
scala-6c2eeae273552ed0be32b90d0c5604d07509e454.tar.bz2
scala-6c2eeae273552ed0be32b90d0c5604d07509e454.zip
- added shell variables.
- added CVS header.
Diffstat (limited to 'ant-common.sh')
-rwxr-xr-xant-common.sh38
1 files changed, 32 insertions, 6 deletions
diff --git a/ant-common.sh b/ant-common.sh
index 7da266bd54..2ff38e8eca 100755
--- a/ant-common.sh
+++ b/ant-common.sh
@@ -1,19 +1,45 @@
-#!/bin/sh
+#!/bin/bash
+########################################################-*-Shell-script-*-####
+# Common settings
+##############################################################################
+# $Id$
-export ANT_OPTS=-Xmx256m
+##############################################################################
+# Apache Ant
-awk '/^$/ {next;} /^#/ {next;} {print "export " $1 $2 $3}' build-nsc.properties > env.sh
+ANT_CMD=ant
+#ANT_OPTS='-Xmx256m -Xms256M'
+ANT_OPTS=
+
+##############################################################################
+# Shell commands
+
+AWK=awk
+CP=cp
+ECHO=echo
+RM='rm -f'
+SED=sed
+
+##############################################################################
+# set user environment
+
+$AWK '/^$/ {next;} /^#/ {next;} {print "export " $1 $2 $3}' \
+ build-nsc.properties > env.sh
. env.sh
# ------- don't change these, change build-nsc.properties instead
function addJar() { # string -> void
- if [ -f $1 ]; then
- CLASSPATH=$1:$CLASSPATH;
+ local jarfile="$1"; shift 1;
+ local jarname="$1";
+ if [ -f $jarfile ]; then
+ CLASSPATH=$jarfile:$CLASSPATH;
return 0;
else
- echo you supplied $1 for $2, but it does not exists;
+ $ECHO you supplied $jarfile for $jarname, but it does not exists;
return -1;
fi
}
+
+##############################################################################