I emerged gcj-jdk to provide jdk:1.5, but it was not automatically set as system-vm (/etc/java-config-2/current-system-vm did not exist). I had to run "java-config -S 1" manually, after some packages failed to build because of "java -version" outputting some spurious "basename" related error message: --- basename: missing operand Try `basename --help' for more information. * Home for VM '' does not exist: * Invalid System VM: --- Reproducible: Always
All JREs and JDKs are supposed to update the symlink if necessary. gcj-jdk not doing this is deliberate. Excerpt from gcj-jdk-4.5.3.ebuild: # Do not set as system VM (see below) # java-vm-2_pkg_postinst ewarn "gcj does not currently provide all the 1.5 APIs." ewarn "See http://builder.classpath.org/japi/libgcj-jdk15.html" ewarn "Check for existing bugs relating to missing APIs and file" ewarn "new ones at http://gcc.gnu.org/bugzilla/" ewarn ewarn "Due to this and limited manpower, we currently cannot support" ewarn "using gcj-jdk as a system VM. Its main purpose is to bootstrap" ewarn "IcedTea without prior binary VM installation. To do that, execute:" ewarn ewarn "emerge -o icedtea && emerge icedtea"