zyxist / chainsaw

Gradle plugin: adds support for building Java 9 modules.
Apache License 2.0
70 stars 4 forks source link

Windows: failing to patch modules for which two or more JARs have been specified #41

Open siordache opened 5 years ago

siordache commented 5 years ago

Oracle's Tools Reference incorrectly shows the : character as separator for the files that patch a given module:

--patch-module module=file(:file)*

The actual separator, as specified in JEP 261 is the host platform's path-separator character:

--patch-module <module>=<file>(<pathsep><file>)*

A look at the source code reveals that javac handles this option in accordance with JEP 261.

On Windows, due to the above mentioned inaccuracy, the plugin fails to patch modules for which two or more JARs have been specified.

I will provide a PR shortly.