javac with --module-source-path and without --module

forax at univ-mlv.fr forax at univ-mlv.fr
Sun Sep 17 12:17:24 UTC 2017


> De: "Christian Stein" <sormuras at gmail.com>
> À: "Remi Forax" <forax at univ-mlv.fr>
> Cc: "jdk9-dev" <jdk9-dev at openjdk.java.net>
> Envoyé: Dimanche 17 Septembre 2017 14:14:05
> Objet: Re: javac with --module-source-path and without --module

> On Sun, Sep 17, 2017 at 1:04 PM, Remi Forax < [ mailto:forax at univ-mlv.fr |
> forax at univ-mlv.fr ] > wrote:

>> Hi Christian,
>> javac --module-source-path src/main
>> should work.

> Then javac reports

> javac: no source files

yes, you need to specify the source files: 
javac --module-source-path src/main */*/*/*/*/java 

Rémi 

> When I add an empty module as a synthetic root reading all other modules and
> use:

> javac --module-source-path src/main --module root

> it works. But if your application/library consists of independent module graphs,
> you can't compile them in one go.

> An advantage of the combination of "--module-source-path" and "--module" options
> is, you don't have to specify any .java source file.


More information about the jdk9-dev mailing list