PDA

View Full Version : [SOLVED] Java 7 Installation



anieruddha
September 3rd, 2011, 02:52 PM
I install Sun-Jdk 7 by following steps mention in

http://strug.wordpress.com/2009/02/22/installing-java-7-snapshot-on-ubuntu/

Now the problem is




aniruddha@aniruddha-laptop:~/works/java$ java -version
java version "1.7.0"
Java(TM) SE Runtime Environment (build 1.7.0-b147)
Java HotSpot(TM) 64-Bit Server VM (build 21.0-b17, mixed mode)




aniruddha@aniruddha-laptop:~/works/java$ javac -version
javac 1.6.0_26

doobrie
September 3rd, 2011, 02:57 PM
I've not installed Java 7 yet, but I imagine you need to run:


update-alternatives --config javac

anieruddha
September 3rd, 2011, 03:20 PM
I've not installed Java 7 yet, but I imagine you need to run:


update-alternatives --config javac

Nope after executing the above command, it says

Nothing to configure.

but javac version still 1.6.XX

raja.genupula
September 4th, 2011, 01:58 AM
java 7 is the run time environment in your system . i mean if you installed any java supported software then to run them successfully you need java . so here that java version 7 (JRE).


to compile the java programs you need JDK that JDK is 6 th version .

jfed
September 4th, 2011, 02:05 AM
This might be better off in the "General Help" section. It doesn't have to do much with Desktop Environments :P

anieruddha
September 4th, 2011, 05:32 PM
Hey thanks for reply.

As a workaround I point java-6-sun link to jdk1.7.0 instead of jdk1.6.xx


But I found solution here :
http://brunoreis.com/tech/intalling-java-ubuntu-natty/