Since the beta of NetBeans 5.0 has been launched, and "Early Availability" versions of Java Studio Creator 2 and Java Studio Enterprise 8 are available, and the next release of Ubuntu is just about out the door, I thought it was time to update my previous post on doing Java development on Ubuntu.
First, I guess some folks might say "Ubuntu? Don't you work for Sun? Why not Solaris X86?". Too easy, I reckon: that's a supported platform, and you should have no problem getting Java and the tools we'll be talking about up and running together on Solaris. For those of you who - like me - are interested in the progress of Linux on the desktop, and would like to have our development tools available in that environment, this is for you. And besides, the new release of Ubuntu is a wonderful desktop on my new Inspiron 9300.
OK, excuses over, let's get to it. Our first step is an easy one, and basically the same as described before. First download the most recent jdk: at the time of writing, this is jdk-1_5_0_05-linux-i586.bin. Be sure to get the .bin, not the .rpm.
Next install - either with synaptics or apt-get or wajig, whatever your preference, the package "java-package": for example, sudo apt-get install java-package. Note that this will also install the package "fakeroot", if you don't already have it installed. Note also that java-package is in "multiverse", so your repository list /etc/apt/sources.list needs to contain, for example:
deb http://au.archive.ubuntu.com/ubuntu breezy multiverse
deb-src http://au.archive.ubuntu.com/ubuntu breezy multiverse
Create a Debian java package with fakeroot make-jpkg, for example
fakeroot make-jpkg jdk-1_5_0_05-linux-i586.bin
Important: don't use sudo to do this, and expect to get some warning/ error "permission denied" messages. This should create a debian package - sun-j2sdk1.5_1.5.0+update05_i386.deb - ready to install with dpkg or wajig. For example,
sudo dpkg -i sun-j2sdk1.5_1.5.0+update05_i386.deb
Once you've installed it, you'll be up and running with the latest jdk: your JAVA_HOME is now, for example, /usr/lib/j2sdk1.5-sun. Get a command line, and enter java -version: you should see something like:
java version "1.5.0_05"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode, sharing)
Next installment, NetBeans!

Posted by Richard Relos on October 03, 2005 at 07:33 PM EST #
RE: Why do u have to create a .deb package? The .bin installer works straight out of the box. And you might want to download the JDK + NetBeans bundle. It does save some effort. And yes, I installed it on Ubuntu.
Posted by Zach on October 04, 2005 at 10:17 PM EST #
Posted by Atleta on October 06, 2005 at 07:26 AM EST #
I know, you're holding your nose. But Gentoo isn't really that hard to install, and a graphical installer is almost here.
After that, installing Java is easy:
emerge "=dev-java/blackdown-jdk"
For the sun JDK it's a two step process:
1) Download JDK and place in /usr/portage/distfiles
2) emerge "=dev-java/sun-jdk"
Keeping up with updates is even easier:
emerge world
See? What could be simpler? (Note the evil grin...)
Posted by Greg Barton on October 07, 2005 at 12:36 AM EST #
Posted by eitan on October 07, 2005 at 01:24 AM EST #
Posted by Juan C Nuno on October 19, 2005 at 06:33 AM EST #
Posted by Jeremy Allen on October 20, 2005 at 02:36 PM EST #
Posted by Tim Finney on October 23, 2005 at 01:09 PM EST #
Posted by Tim Finney on November 04, 2005 at 07:41 AM EST #
Posted by David Coldrick on November 04, 2005 at 09:06 AM EST #
Posted by David Coldrick on November 04, 2005 at 09:12 AM EST #
I'm using Ubuntu, with Java 6 (mustang). Binary snapshots are available (just google it). NetBeans 5 works great on it - much better than with Java 5; the font treatment is much better. See http://blogs.sun.com/roller/page/tor?entry=new_toys_hot_workstation_and. I don't actually install packages; I just unzip the JDK in a directory, and point to it in my etc/netbeans.conf. (I like to have multiple JDK's (and ant's, etc.) installed, and switch between them using aliases and path environment variables.)
Posted by Tor Norbye on November 10, 2005 at 04:24 PM EST #
Posted by Raja Iskandar Shah on November 17, 2005 at 09:16 PM EST #
Posted by Grady Lambert on November 18, 2005 at 09:24 AM EST #
Posted by David Coldrick on November 18, 2005 at 10:28 AM EST #
Posted by Lars on November 30, 2005 at 04:23 PM EST #
Posted by David Coldrick on December 01, 2005 at 09:27 AM EST #
Posted by Lars on December 01, 2005 at 01:17 PM EST #
Posted by MarkJ on December 19, 2005 at 06:51 AM EST #
Posted by funkyAde on February 17, 2006 at 10:37 PM EST #
Posted by John on July 17, 2006 at 08:18 PM EST #
Posted by Coldrick on July 17, 2006 at 08:40 PM EST #
Error: could not find libjava.so
Error: could not find Java 2 Runtime Environment.
I can only guess that the installation doesn't know where to look for these files. Doing an env command doesn't show any java specific environment variables ie JAVA_HOME etc.
Any thoughts on what might be a possible solution?
Gary
Posted by Gary J on July 22, 2006 at 11:58 AM EST #
Posted by David Coldrick on July 22, 2006 at 08:54 PM EST #
I had to use the sudo update-alternatives --config java function as it was still pointing to the original install when I typed 'which java'.
Gary.
Posted by GaryJ on July 24, 2006 at 12:08 AM EST #
Posted by owen on September 23, 2006 at 09:15 AM EST #
when i do update-alternatives and get the list of the available java i see a "+" sign next to "/usr/lib/jvm/java-gcj/jre/bin/java" what does the "+" sign means? as the "*" is for the default of Sun's java "/usr/lib/j2sdk1.5-sun/bin/java"
last but not least, how do i remove the old existing jvm?
thank you in advance
Posted by Makoto Ishijima on December 06, 2006 at 12:09 PM EST #
It's me again guys, and i need suggestion as i'm new in this linux debian.
the next step that i got confused with is whether to install j2ee package (java_ee_sdk-5_01-linux.bin ) by using "sudo java_ee_sdk-5_01-linux.bin" or i need to make it as a .deb first like the jdk 1.5?
because i'm affraid if i do that the j2ee only be installed on the current folder and it doesn't installed on the system.
this question goes along with the netbeans 5.5, so i make it as .deb first or just do a "sudo xxx.bin"?
your help would be greatly appreciated
Posted by Makoto Ishijima on December 06, 2006 at 12:23 PM EST #
Posted by David Coldrick on December 06, 2006 at 05:32 PM EST #
Posted by Makoto Ishijima on December 19, 2006 at 07:08 PM EST #
Posted by caroline kuo on July 25, 2007 at 12:45 PM EST #
Posted by David Coldrick on July 25, 2007 at 03:28 PM EST #
I have Ubuntu 7.10 on my laptop. I am trying to use Matlab on desktop but the graphical interface won't appear (just grey square). Reading the ubuntu help tells me that typing "which java" I should get "usr/local/bin" and I get "usr/bin/java". Can you help me to fix this?
Thank You!
Posted by Simo on November 21, 2007 at 07:39 AM EST #
http://www.batteryfast.co.uk/hp/dv9500.htm hp dv9500 battery,
http://www.batteryfast.co.uk/hp/dv9600.htm hp dv9600 battery,
http://www.batteryfast.co.uk/hp/dv9700.htm hp dv9700 battery,
Posted by laptop battery on October 24, 2008 at 05:50 PM EST #
Do you want to own some betteries which have more function , more economical and long life? Please visit the following Web site: http://www.adapterlist.com/hp/dv9100.htm hp dv9100 battery,it will help you find the ideal battery.
Posted by laptop bettery on March 03, 2009 at 05:31 PM EST #