Adding the latest beta SUN JDK to the Gentoo <tt>java-config</tt> VM list

2008-03-28 13:14

Gentoo Linux has a very nice java integration; you can have more than one JDK distributions in your machine and switch the VM in system-wide and per-user manner. To switch your current VM, you can simply enter 'java-config --set-user-vm=VM' and that's all.

However, you need to know how java-config works if you want to add any JDK which is not in the portage. It's pretty simple to add a JDK, but it can be tricky for a beginner. Please follow the following steps:
  1. Install your JDK somewhere. (e.g. 1.6.0.10-beta in /opt/sun-jdk-1.6.0.10)
  2. Add the profile of the newly installed JDK into /usr/share/java-config-2/vm/. Copy from an existing one and replace some version numbers. (e.g. cp sun-jdk-1.6 sun-jdk-1.6.0.10; perl -pi -e "s/1\\.6\\.0\\.03/1.6.0.10/g" sun-jdk-1.6.0.10)
  3. Create a symbolic link to the JDK directory in /usr/lib/jvm/. (e.g. ln -s /opt/sun-jdk-1.6.0.10)
  4. Confirm that the new VM is recognized by java-config by typing 'java-config -L'.
---

Comments

No comments yet. Be the first!

 
  • Preview 버튼 누르고 reCAPTCHA 입력 후 Submit 버튼까지 눌러야 실제로 게시됩니다.
  • Make sure to answer the reCAPTCHA and click the Submit button to get your comment posted. It's not enough to click the Preview button only! -- See why.
---