************************************************************************
*        Busy Wait Analyser - BWA - http://bwa.sourceforge.net/        *
*                                                                      *
*      (C) 2005  Raul Fechete, Georg Kienesberger, Peter Minarik.      *
************************************************************************


In order to get a running BWA, classes of the following packages need to
be in your CLASSPATH:
bwa-1.0, soot-2.2.1, jasmin-2.2.1, polyglot-1.3 
Basically, there are two ways to accomplish that:  

Using Jars
==========

  1. First you need to get the following packages:

	bwa-1.0.jar
     from http://bwa.sourceforge.net/downloads.html

	sootclasses-2.2.1.jar,
	polyglotclasses-1.3.jar,
	jasminclasses-2.2.1.jar
     from http://www.sable.mcgill.ca/soot/soot_download.html

  2. Move them to a directory of your choice and set the CLASSPATH so
     that it contains all 4 jar files. Remember that in contrast to the
     inclusion of class files the jar file itself must be listed in the
     CLASSPATH: Inclusion of the directory where the files reside
     doesn't do the job. e.g.:

	mkdir bwa

	mv bwa-1.0.jar sootclasses-2.2.1.jar polyglotclasses-1.3.jar \
	jasminclasses-2.2.1.jar bwa

	cd bwa

	export CLASSPATH=$CLASSPATH:$PWD/bwa-1.0.jar:\
	$PWD/sootclasses-2.2.1.jar:$PWD/polyglotclasses-1.3.jar\
	:$PWD/jasminclasses-2.2.1.jar

  3. Make sure the classes you want to analyse are in the CLASSPATH too.

  4. Finally start BWA with the following command to get some usage
     information (for details see the README):

	java bwa.Main


Compiling The Source
====================

To compile BWA using the build.xml you will need Apache Ant
(http://ant.apache.org/).

  1. Download bwa-1.0.src.tar.gz from
     http://bwa.sourceforge.net/downloads.html and extract it with

	tar -xzf bwa-1.0.src.tar.gz

  2. Get Soot (a xor b):
	a) If you don't want to compile Soot yourself, download
              sootclasses-2.2.1.jar,
	      polyglotclasses-1.3.jar,
	      jasminclasses-2.2.1.jar
           from http://www.sable.mcgill.ca/soot/soot_download.html
	   and set the CLASSPATH so that it contains all 3 jar files.
           Remember that in contrast to the inclusion of class files the
           jar file itself must be listed in the CLASSPATH: Inclusion of
           the directory where the files reside doesn't do the job.

	b) If you want to compile Soot yourself, download
              sootsrc-2.2.1.tar.gz,
              jasminsrc-2.2.1.tar.gz,
              polyglotsrc-1.3.tar.gz
           from http://www.sable.mcgill.ca/soot/soot_download.html
           and follow the instructions contained therein.
	   In case you decided to build jar files, follow the
           instructions in section a. Otherwise include the following
           directories in your CLASSPATH:
              soot-2.2.1/classes
              jasmin-2.2.1/classes
              polyglot-1.3/classes
              polyglot-1.3/cup-classes  

  3. `cd' into bwa-1.0 and type `ant' to compile the source, generate
     Javadoc and build a jar. Alternatively you may compile the source
     only with `ant compile' (`ant -projecthelp' for a list of all
     targets).

  4. If you created a jar file, add it to your CLASSPATH as described
     above, otherwise add the bwa-1.0/classes directory. 

  5. Finally start BWA with the following command to get some usage
     information (for details see the README):

	java bwa.Main


