ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From RPea...@360commerce.com
Subject Naughty JAXB xjc task is forcing recompilation
Date Tue, 21 Sep 2004 18:06:52 GMT
This is not Ant specific (custom JAXB target), but I was hoping someone on 
this list could help me out...

I have a series of directories in my project that contain code. One 
contains xsd files that use the xjc target to generate java files. Since I 
want to leverage my existing javac targets, I have the xjc output go to my 
source directory. It seems that the xjc target will overwrite those 
generated java files always. Thus, my javac target picks up on the change 
and recompiles. This is a pain for my developers who are forced to 
recompile this project during every build.

This output below, just ain't right....

[xjc] the last modified time of this inputs is  1095263076735
[xjc] the last modified time of the outputs is -9223372036854775808

Heres the target:

<target name="jaxb.compile" description="Compile xjc files" 
unless="dont.jaxb.compile">
        <xjc target="${java.source.dir}" package="${jaxb.package}">
                <schema dir="${jaxb.source.dir}" includes="*.xsd" 
excludes="${jaxb.exclude}"/>
                <depends dir="${jaxb.source.dir}" includes="*.xsd" 
excludes="${jaxb.exclude}"/>
                <produces dir="${java.source.dir}" includes="* impl/*"/>
        </xjc>
</target>

My guess is that I'm simply not understanding the "Up-to-date Check" 
section on this page: 
http://java.sun.com/webservices/docs/1.4/jaxb/ant.html. But, it looks like 
I have my <depends> and <produces> targets setup correctly.

Thanks,

Robert

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message