History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: APF-674
Type: Improvement Improvement
Status: Open Open
Priority: Minor Minor
Assignee: Matt Raible
Reporter: Christian Giese
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
AppFuse

add ' useexternalfile="yes" ' to javadoc task in build.xml

Created: 02/Mar/07 12:14 PM   Updated: 08/Oct/07 01:52 PM
Component/s: Build, Test, or Deploy Process
Affects Version/s: 1.9.4
Fix Version/s: 1.9.5

Environment: any


 Description  « Hide
"ant javadoc" runs into errors for projects with a large number of source files or libraries because the command sent to the OS becomes too long.
Easy fix is adding useexternalfile="yes" into build.xml. Officially supported in ant 1.7.0, but works with 1.6.5 also.
Original mail from AppFuse-User Mailing List:

=======================================================================================
Hi all,

I just ran into errors using "ant javadoc" in appfuse 1.9.4.
As soon as you get enough source files or libs you run into a "java.io.IOException: CreateProcess ..."(mostly means binaries are not in the PATH). Took me some time to find this:
http://www.nabble.com/javadoc-task-tf2315.html#a7568 stating that the command line simply is too long (each appgen-run from pojo adds at least 300-500 chars depending on absolute source path) and pointing to the "useexternalfile" attribute usable from ant 1.7.0 on (see http://ant.apache.org/manual/CoreTasks/javadoc.html ). Interestingly it already works with ant 1.6.5.

I changed my build.xml like shown in the snippet below (only inserted 'useexternalfile="yes"') and it works like a charm. It cut my command line from 33637 to 5302 characters :) .

I hope this information helps people who search nabble for javadoc errors in the future :-)
Maybe it's even worth updating the build.xml for 1.9.4 even with 2.0 so close?

Cheers,
Chris

---8<--- snip ---->8----
<target name="javadoc" depends="java2html"
    description="Generate JavaDoc API docs">
    <javadoc
        destdir="${build.dir}/docs/api"
        packagenames="com.garderos.acconfigserver.*"
        author="true"
        version="true"
        windowtitle="${webapp.name} api"
        doctitle="&lt;h1&gt;${webapp.name} javadocs for
            version ${webapp.version}&lt;/h1&gt;"
        bottom="Copyright &#169; 2002-${copyright.year}"
        stylesheetfile="${build.dir}/docs/api/stylesheet.css"
        useexternalfile="yes">
        <fileset dir="${src}">
            <patternset refid="java.files.pattern"/>
        </fileset>
---8<--- snip ---->8----



 All   Comments   Change History   FishEye      Sort Order:
There are no comments yet on this issue.