The current java-config generates CLASSPATH's that have two instants of the Java system libraries. This is because they appear both in /etc/env.d/20java and /etc/env.d/21java-classpath. '.' entries also occur in both these files. This leads to a CLASSPATH containing duplicates of each of the above entries. I've modified java-config so that this no longer happens, and that '.' appears once, and is always the last entry in the CLASSPATH. Changes are: * java-config: calc_full_classpath() - I removed the concatenation of '.' to the end of classpaths. Also, it no longer adds on from the current CLASSPATH env variable (combining multiple CLASSPATH from different files in /etc/env.d is already handled by env-update). vm_envvars() - normalise_classpath() now gets applied before writing CLASSPATH entries. normalise_classpath() will remove any '.' paths. * 30java-finalclasspath (New file): This file simply contains "CLASSPATH=." and is placed in the /etc/env.d directory. This results in a '.' being appened to the generated CLASSPATH. Attached are: * The patch for the changes to java-config (generated by 'diff -c java-config /usr/portage/dev-java/java-config/files/0.2.6/java-config'). * The new 30java-finalclasspath file. * Patch for creating the new eBuild that will install the '30java-finalclasspath' file, too.
Created attachment 4635 [details, diff] java-config.patch
Created attachment 4636 [details, diff] java-config-0.2.7.ebuild.patch
Created attachment 4637 [details] 30java-finalclasspath
Thanks a bundle. I'll get to this as soon as I can. There's some discussion on changing parts of the java-config stuff now. This is relevant regardless of the outcome of the debate, but I'd like to introduce most of the updates in one painful go instead of many small nuisances :)
Fixed in java-config-0.2.7.ebuild Thanks, for the patches.