javadoc in ant build file(no source files and no packages specified)
843810Oct 9 2003 — edited Nov 6 2007Hi all,
I have 3 packages: com.test.client, com.test.common, com.test.server. Each package contains many java source files(*.java). And I 'd like to write an ant script that has a target to javadoc all packages and source code files, but so far failed. Please help. (all other targets like compile, jar, war, ... all works but javadoc!). I have tried many but none are works. like
1/
<target name="javadoc" depends="copying, compile, jar">
<javadoc
packagenames="com.test.client*,com.test.common,com.test.server.*"
destdir="${docs}">
<sourcepath location="${src_dir}"/>
<classpath refid="compile.classpath"/>
</javadoc>
</target>
2/
<target name="javadoc"
<javadoc packagenames="com.test.*" sourcepath="${src_dir}" destdir="${docs}" classpath refid="compile.classpath"/>
</target>
3/
<target name="javadoc"...
<javadoc destdir="${docs}>
<package name="com.test.client.*"/>
<package name="com.test.common.*"/>
<package name="com.test.server.*"/>
<classpath refid="compile.classpath"/>
</javadoc>
</target>
the error always:
no source files and no packages have been specified