You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Bill Clinton <bc...@snipermail.com> on 2001/06/12 16:45:53 UTC
??? Warning: JAVA_HOME environment variable is not set. ???
Hello,
When I came in this morning, my ant builds are failing with this
message:
Warning: JAVA_HOME environment variable is not set.
If build fails because sun.* classes could not be found
you will need to set the JAVA_HOME environment variable
to the installation directory of java.
however, when I type: echo $JAVA_HOME
I get: /usr/java/jdk1.3.1
I have been using ant for about a week now with no problems, and I am
unsure of what I could have done yesterday to cause this error. If I
log in as root, ant does run with the same JAVA_HOME.
I looked at the /usr/local/jakarta-ant-1.3/bin/ant file and saw that it
was testing for the existance of $JAVA_HOME/lib/tools.jar, which does
exist on my system.
I don't know what I did yesterday to cause this problem today, and I am
unsure of how I should proceed to debug it. Has anyone ever seen this
problem before and could offer me a suggestion?
Thanks, Bill
Re: ??? Warning: JAVA_HOME environment variable is not set. ???
Posted by Bill Clinton <bc...@snipermail.com>.
Hello,
I found the problem on this one. Apparently gnomes hacked into my
machine and commented the export line in my .bashrc. I was not aware
that one could "echo $VARS" and still see a value without exporting them
So, when I was typing "echo $JAVA_HOME" and seeing a result, I wrongly
assumed that my CLASSPATH, JAVA_HOME, etc were set when they were not.
Bill
Bill Clinton wrote:
> Hello,
> When I came in this morning, my ant builds are failing with this
> message:
>
> Warning: JAVA_HOME environment variable is not set.
> If build fails because sun.* classes could not be found
> you will need to set the JAVA_HOME environment variable
> to the installation directory of java.
>
> however, when I type: echo $JAVA_HOME
> I get: /usr/java/jdk1.3.1
>
> I have been using ant for about a week now with no problems, and I am
> unsure of what I could have done yesterday to cause this error. If I
> log in as root, ant does run with the same JAVA_HOME.
>
> I looked at the /usr/local/jakarta-ant-1.3/bin/ant file and saw that it
> was testing for the existance of $JAVA_HOME/lib/tools.jar, which does
> exist on my system.
>
> I don't know what I did yesterday to cause this problem today, and I am
> unsure of how I should proceed to debug it. Has anyone ever seen this
> problem before and could offer me a suggestion?
>
> Thanks, Bill