The FLEX compiler uses the GNU Project's free implementation of the Java standard class libraries, called GNU Classpath. If you are only interested in analyzing Java bytecode you will not (necessarily) need to install GNU Classpath, but if you will if you want to use FLEX to generate executable code.
There are several different ways to install GNU Classpath:
Simply use the command (as root):
apt-get install classpath jikes-classpath
FLEX will now find the classpath installation in its
standard location. However, you will also want to make sure you are
using FLEX properties files which match the version of classpath you
have installed. Since debian currently packages Classpath
version 0.05 in unstable and 0.04 in testing/stable
(check
here for the latest package status), you will need to execute
something like the following:
cd ~/Harpoon/Code && make cvs-update-classpath-0.05
Configure the Runtime with: --with-classpath
Assuming you've checked our FLEX into the ~/Harpoon
directory, as recommended:
cd ~/Harpoon
cvs -d `cat Code/CVS/Root` checkout Classpath
cd Classpath
./build
and, if you are cross-compiling for StrongARM, you also need:
cd ~/Harpoon/Classpath && ./build-arm
Presumably you will also need to set the
CLASSPATH_HOME
variable in your environment.
Configure the Runtime with:
--with-classpath=$HOME/Harpoon/Classpath/install/lib/classpath
It's not too hard to build GNU Classpath direct from GNU's source distribution.
classpath-0.05.tar.gz
via FTP from alpha.gnu.org/gnu/classpath
.
~/Harpoon
:
cd ~/Harpoon && tar -xzf classpath-0.05.tar.gz
cd ~/Harpoon/classpath-0.05
./configure --with-jikes --enable-jni --prefix=$HOME/Harpoon/classpath-install
cd ~/Harpoon/classpath-0.05
make && make install
~/.bash_profile
:
export CLASSPATH_HOME=$HOME/Harpoon/classpath-0.05
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/Harpoon/classpath-install/lib/classpath
(If you are using csh
, some slight changes will be required.)
cd ~/Harpoon/Code && make cvs-update-classpath-0.05
Configure the Runtime with:
--with-classpath=$HOME/Harpoon/classpath-install/lib/classpath
Verbatim copying and distribution is permitted in any medium, provided this notice is preserved. |
cananian Last updated: 21 July 2003 |