How can I install a headless JDK on an Ubuntu Jaunty server?
This has been discussed in the following ubuntu bug.
As far as I can see you have the following options:
- Use the non-free Java JDK from Sun. (You can use the JavaPackage program from debian/ubuntu to create a deb pacakge of the non-free java JDK).
- Work with ubuntu developers to solve this issue.
- Create your own OpenJDK-headless package.
Of course, option 2 is the best in the long term, as it solves the problem for everyone, and options 1 and 3 solve it only for you, however 1 and 3 are quicker.
Couldn't you just download and install Sun's JDK? No compiling, no X11 required. I prefer it to the packaged options.
chmod +x ~/jdk-6u14-linux-i586.bin
cd /usr
sudo mkdir java
cd java
sudo ~/jdk-6u14-linux-i586.bin
export JAVA_HOME=/usr/java/jdk1.6.0_14
export PATH=$JAVA_HOME/bin:$PATH