I want to enable automatic Javadoc generation for a library project on each build. I have 3 issues to tackle:
-
How to integrate such an automated script in IDE’s build process ? (Eclipse and IDEA).
-
How do I exclude the auto-generated
RandBuildclasses from docs
processing, as they are always generated under the source’s
namespace. -
Pack and place Javadoc as a jar next to the build jar file.
The question is a bit broad, But I’m sure a good consolidated answer in one place will save the trouble for many.
Two ways:
Apache Ant: the default ant build file lies insdk_path/tools/ant/build.xml, this is imported into project’sbuild xml. Hence custom targets can be added for some additional work. Best place to put them is in acustom_rules.xmlfile at project root and import in project’sbuild.xml.custom_rules.xml:To create package, simply run
ant package_libraryfrom project root. You can include these in a build target so, they run on every build.