running Groovy on JDK9
Jochen Theodorou
blackdrag at gmx.org
Sat Apr 16 09:11:51 UTC 2016
On 10.04.2016 20:29, Jochen Theodorou wrote:
[...]
>> Compile error during compilation with javac.
>> /tmp/stubgentests77510877964035184621460309483098/bar/GroovyClass.java:12:
>> error: package groovy.lang does not exist
>> groovy.lang.GroovyObject {
Looks like I actually found out why this happens. For javac to know how
to compile the file, we did scan the the classloader hierarchy for
URLClassLoader and all the paths it has to the classpath for javac to
look for precompiled classes. Since there is no longer a URLClassLoader
with jigsaw, this no longer works. We can supply an additional
classpath, I guess I will have to use something like
GroovyObject.class.getProtectionDomain().getCodeSource().getLocation()
instead. If it is useable solution for the future I am not sure, I guess
it works for now.... once real modules come into play I suspect I will
have to do a lot more work here
That way I get at least 30 failures less ;)
bye Jochen
More information about the jigsaw-dev
mailing list