On 7/19/07, Jeff Mutonho <[EMAIL PROTECTED]> wrote:



On 7/19/07, Wayne Fay <[EMAIL PROTECTED]> wrote:
>
> You should be able to put the java6 exec in front of java4 in your
> PATH pretty trivially. Just put that EXPORT command in .bashrc or
> equivalent for your user and never worry about it again.
>
> Wayne
>
> That exactly what I did in my  ".profile" file and doesn't seem to
work.When I login , and run "which java"  ,  the 1.4 one is 
displayed.Iliterally have to force it to use the
1.6 one buying doing a " . .profile"


Here's what my  .profile file looks like :

SHELL=/usr/bin/bash;export SHELL
JAVA_HOME=/app/maven/java/java6/jdk1.6.0_01;export JAVA_HOME
HUDSON_HOME=/app/maven/HUDSON-BUILDS;export HUDSON_HOME

MAVEN_HOME=/app/maven/M2/maven-2.0.4;export MAVEN_HOME
MAVEN_OPTS="-Xmx1024m -Xms1024m -XX:MaxPermSize=512m";export MAVEN_OPTS
PATH=$JAVA_HOME/bin:$PATH:/usr/local/bin:$MAVEN_HOME/bin;export PATH


However when I when I do "which java"   and echo $JAVA_HOME i get the
following:

bash-2.05$ which java
/usr/bin/java
bash-2.05$ echo $JAVA_HOME
/app/maven/java/java6/jdk1.6.0_01
bash-2.05$

I literally have to force the usage of  the 1.6 version by doing a ".
.profile"  as shown below :

bash-2.05$ . .profile
bash-2.05$ which java
/app/maven/java/java6/jdk1.6.0_01/bin/java
bash-2.05$


Without doing that , it uses the 1.4 version.


--

"Don't take the name of root in vain."

Jeff  Mutonho
Cape Town
South Africa

GoogleTalk : ejbengine
Skype        : ejbengine
Registered Linux user number 366042

Reply via email to