in maven-plugin/src/main/java/com/spotify/missinglink/maven/CheckMojo.java [491:510]
private String bootClassPathToUse() {
if (this.bootClasspath != null) {
getLog().debug("using configured boot classpath: " + this.bootClasspath);
return this.bootClasspath;
}
// Maven executes plugins with a customized ClassLoader to provide isolation between
// plugins and the Maven installation. If we tried to inspect the 'java.class.path' property,
// all we would see is a single entry for plexus-classworlds.jar.
// (more info at https://cwiki.apache.org/confluence/display/MAVEN/Maven+3.x+Class+Loading )
//
// To be able to load the Java platform classes (i.e. java.util.*), we have to look at the
// bootstrap class path - not sure about the standard way to find this.
// (http://docs.oracle.com/javase/7/docs/technotes/tools/findingclasses.html)
// TODO 6/4/15 mbrown -- warn users that bootclasspath might be a different version (JAVA_HOME
// probably) than what they use for javac
final String bootClasspath = System.getProperty("sun.boot.class.path");
getLog().debug("derived bootclasspath: " + bootClasspath);
return bootClasspath;
}