tamada/pochi

Generating javadoc with multiple modules

Closed this issue · 2 comments

Generating Javadoc was failed by introducing the module system.

symptom

javadoc --module ... --module-path ... --module-source-path ...

returns module not found.

javadoc --classpath ... --sourcepath ... @packages

returns too many modules.

ref #43

I got it!!

The --module-source-path option of javadoc parses the base directory for the module source directory.
That is, the following layouts may be assumed.

src/
├── jp.cafebabe.birthmarks
│   ├── module-info.java
│   └── jp
│       └── ...
├── jp.cafebabe.kunai
│   ├── module-info.java
│   └── jp
│       └── ...
└── jp.cafebabe.pochi
    ├── module-info.java
    └── jp
        └── ...

Then, I build the directory layouts like above with symbolic links in the site/Makefile (public/apidocs target).

references

https://stackoverflow.com/questions/49476559/java-9-error-not-in-a-module-on-the-module-source-path
https://stackoverflow.com/questions/53973319/how-to-generate-javadoc-for-multiple-modules

mak