Bug 62424 - Requesting support for module-aware switches for the <javadoc> task
Summary: Requesting support for module-aware switches for the <javadoc> task
Status: RESOLVED FIXED
Alias: None
Product: Ant
Classification: Unclassified
Component: Core tasks (show other bugs)
Version: 1.10.2
Hardware: PC All
: P2 normal (vote)
Target Milestone: 1.10.6
Assignee: Ant Notifications List
URL:
Keywords:
: 62776 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-06-04 00:02 UTC by rick.hillegas
Modified: 2018-09-29 15:56 UTC (History)
1 user (show)



Attachments
Tarball of sample project which demonstates the described behavior. (11.50 KB, application/x-tar)
2018-06-04 00:02 UTC, rick.hillegas
Details

Note You need to log in before you can comment on or make changes to this bug.
Description rick.hillegas 2018-06-04 00:02:59 UTC
Created attachment 35953 [details]
Tarball of sample project which demonstates the described behavior.

JDK 9 introduced a new set of module-aware switches for the javadoc tool. The ant <javadoc> task does not support these switches, not even as nested <arg> elements. I can get ant to build javadoc by using the <exec> task. I will attach a tarball of source code for a sample project which demonstrates this behavior. The "javadoc" target uses the <exec> task and it succeeds. The "javadoc2" target uses the <javadoc> task and it fails.
Comment 1 Gintas Grigelionis 2018-06-10 19:28:51 UTC
I see --module and --module-source-path, but javadoc in Java 9+
adds a bunch of module-related switches, like
--add-modules, --add-exports, --add-reads, --limit-modules,
--module-path, --show-module-contents,
--show-packages, --system, --upgrade-module-path

Of those, --add-exports and --add-reads are not printed by --help,
but are documented in Javadoc Guide [1]

For completeness sake, there are three more new switches:
--show-members, --show-types, and --release
apart from HTML version switches mentioned in [2]

[1] https://docs.oracle.com/javase/9/javadoc/JSJAV.pdf
[2] https://bz.apache.org/bugzilla/show_bug.cgi?id=62441
Comment 2 Stefan Bodewig 2018-09-28 18:45:32 UTC
1.10.6 and 1.9.14 add support for --module --module-path and --module-source-path.

--module is the only one that really is required so that the task knows you are actually specifying "things to document".
Comment 3 Stefan Bodewig 2018-09-29 15:56:35 UTC
*** Bug 62776 has been marked as a duplicate of this bug. ***