diff options
author | Aleksandar Pokopec <aleksandar.prokopec@epfl.ch> | 2011-01-17 15:18:03 +0000 |
---|---|---|
committer | Aleksandar Pokopec <aleksandar.prokopec@epfl.ch> | 2011-01-17 15:18:03 +0000 |
commit | be2778d50f1a73a941c6ffe6355f0ed401d6d8eb (patch) | |
tree | 54cd12023d74a8e172b68106911036c7e32a2321 /test/instrumented/mkinstrumented | |
parent | cf820b8907e60214df974a3b2a88ca0a7e877298 (diff) | |
download | scala-be2778d50f1a73a941c6ffe6355f0ed401d6d8eb.tar.gz scala-be2778d50f1a73a941c6ffe6355f0ed401d6d8eb.tar.bz2 scala-be2778d50f1a73a941c6ffe6355f0ed401d6d8eb.zip |
Added 'specialized' tests.
Added a new test group - specialized.
Modified partest to add a jar with instrumented classes to classpath when compiling and running tests.
Added a primary version of the instrumented BoxesRuntime, and a script to produce a jar for it.
Added the 'speclib' folder to partest files, which contains the jar with the instrumented classes.
Review by dragos.
Diffstat (limited to 'test/instrumented/mkinstrumented')
-rwxr-xr-x | test/instrumented/mkinstrumented | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/test/instrumented/mkinstrumented b/test/instrumented/mkinstrumented new file mode 100755 index 0000000000..a87e8cb94f --- /dev/null +++ b/test/instrumented/mkinstrumented @@ -0,0 +1,46 @@ +# +# +# Used to compile a jar with instrumented versions of certain classes. +# + + + + +if [ $# -ne 1 ] +then + echo "Must provide build dir ('target' or 'build')." + exit 1 +fi + + +BUILDDIR=$1 +TOPDIR=../.. +SCALAC=$TOPDIR/$BUILDDIR/pack/bin/scalac +SRC_DIR=library/ +SCALALIB=$TOPDIR/$BUILDDIR/pack/lib/scala-library.jar +CLASSDIR=classes/ +ARTIFACT=instrumented.jar + + +# compile it +rm -rf $CLASSDIR +mkdir $CLASSDIR +JSOURCES=`find $SRC_DIR -name "*.java" -print` +SOURCES=`find $SRC_DIR \( -name "*.scala" -o -name "*.java" \) -print` +echo $SOURCES +$SCALAC -d $CLASSDIR $SOURCES +javac -cp $SCALALIB -d $CLASSDIR $JSOURCES + + +# jar it up +rm $ARTIFACT +cd $CLASSDIR +jar cf $ARTIFACT . +mv $ARTIFACT ../ +cd .. + + + + + + |