So I managed to get the `groovy-xml` module build pass and test with
Jigsaw. It requires the latest snapshot of Gradle, and confirms that using
`-release` instead of {`-source`, `-target`, `-addmods`} work. There's a
big drawback with using `-release` though. Typically `groovy-core` uses the
API of JDK 7 (for invokedynamic) but we generate Java 6 bytecode. It's not
possible to do this with `-release`, so we still have to rely on the "old"
options.Our build is still not fully Jigsaw compatible, there are still a significant number of errors, including spurious classloading issues: https://scans.gradle.com/s/jaefpwpny743e 2016-07-09 10:27 GMT+02:00 Jochen Theodorou <[email protected]>: > On 09.07.2016 09:03, Remi Forax wrote: > >> >> >> ----- Mail original ----- >> >>> De: "Jochen Theodorou" <[email protected]> >>> À: [email protected] >>> Envoyé: Vendredi 8 Juillet 2016 21:51:18 >>> Objet: Re: JDK 9 Jigsaw builds >>> >>> actually, I think I did see somewhere that JDK9 will support only 8 and >>> 7 as targets. Maybe someone can confirm that. >>> >> >> not at all ! >> >> It's not the JDK, it's just javac. >> > > ups, yes, I did mean javac. > > javac only support 4 releases, it's not something new, i think that policy >> was introduced with javac 7, >> to be able to remove old code. So javac 9 support 9, 8, 7, and 6. And for >> the last supported platform, javac emits a warning. >> > > 4, ok, I had something like the current plus the last two in mind. Seems I > did remember wrong and seems like we then can still go with 1.6 as target > level then. > > so on my laptop, >> >> $ /usr/jdk/jdk-9/bin/javac -source 1.5 Foo.java >> warning: [options] bootstrap class path not set in conjunction with >> -source 1.5 >> error: Source option 1.5 is no longer supported. Use 1.6 or later. >> >> $ /usr/jdk/jdk-9/bin/javac -source 1.6 Foo.java >> warning: [options] bootstrap class path not set in conjunction with >> -source 1.6 >> warning: [options] source value 1.6 is obsolete and will be removed in a >> future release >> warning: [options] To suppress warnings about obsolete options, use >> -Xlint:-options. >> 3 warnings >> > > I see, thanks. > > bye Jochen >
