LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   gcj javac instead of jdk javac (https://www.linuxquestions.org/questions/linux-newbie-8/gcj-javac-instead-of-jdk-javac-429689/)

rvindiola 03-29-2006 12:31 PM

gcj javac instead of jdk javac
 
javac is referring to gcj's javac instead of jdk's javac.
how do i switch it so that javac refers to jdk's javac?

Vgui 03-29-2006 06:50 PM

I'm not sure of your relative skill level, so I'm just going to explain what I'd do, if you need step by step instructions let me know though.
First I'd figure out what my JAVA_HOME environment variable is, and which javac binary is being used. Then I'd backup whatever javac binary is being pointed too, and link to the gcj javac instead. You might have to fool around with JAVA_HOME, but ideally you could just run the gcj javac and be good to go.
As I said, ask for specifics if you need.

rvindiola 03-29-2006 08:18 PM

problem solved.

actually, i wanted to switch from the gnu java compiler to sun's java compiler. JAVA_HOME was pointing to the right directory. thanks for the suggestion though.

i ended up using the commands "which javac" and "whereis javac" to find that the symbolic link was in /usr/bin. so then i removed the link:

rm /usr/bin/javac

and created a new one pointing to the one i wanted to use:

ln -s /usr/local/jdk1.5.0_06/bin/javac /usr/bin/javac


All times are GMT -5. The time now is 07:34 AM.