Monday, April 23, 2007

Installing and setting up Sun Java

To install Sun Java, you need to install the sun-java6-bin and sun-java6-jre packages. Additionally, if you intend to program your own Java applications, you need to install sun-java6-jdk. Multiverse has to be enabled.

sudo aptitude install sun-java6-bin sun-java6-jre sun-java6-jdk

Next, to make Sun Java the default Java interpreter (rather than GCJ):
sudo update-alternatives --config java

and choose the correct option for Sun Java, ie. /usr/lib/jvm/java-6-sun/jre/bin/java.

Links of Interest
Ubuntu's Wiki page concerning Java

No comments: