manolakis |
03-22-2007 11:55 AM |
Ant problem with JAVA_HOME
Hi there
I will be really glad if anyone was familiar with the following?
Quote:
BT ant $ ant all
Unable to locate tools.jar. Expected to find it in /usr/lib/java/lib/tools.jar
Buildfile: build.xml
initialise:
compile:
[javac] Compiling 180 source files to /home/manos/Desktop/downloads/jcommon-1.0.8/build
BUILD FAILED
/home/manos/Desktop/downloads/jcommon-1.0.8/ant/build.xml:51: Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
It is currently set to "/usr/lib/java"
Total time: 1 second
|
I recently downloaded Ant and I set the environment variables to /etc/profile
This is how i set up the variables in the end of etc/profile
Quote:
# For non-root users, add the current directory to the search path:
if [ ! "`id -u`" = "0" ]; then
PATH=/home/manos/Desktop/downloads/jdk1.6.0/bin/:$PATH
export ANT_HOME=/home/manos/Desktop/downloads/apache-ant-1.7.0/
export PATH="${PATH}:${ANT_HOME}/bin"
fi
|
Any ideas how can i set JAVA_HOME ?
Thanks for your time
manolakis
|