You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by "Duffey, Kevin" <KD...@BUYMEDIA.com> on 2001/03/20 02:30:33 UTC

Always builds ALL files and not those that changed.

Hi all,

I am curious as to why recently my build scripts build all files now, and
not those that changed. I read in the doc that it only builds files with
.class files older than the .java source. When I save a .java source, it
should automatically become newer than the .class. When Ant (1.3) builds
files, doesn't it match up the date/time of the .class file to the .java
file so they are identical (or uses the current date/time so the .class is
newer)? I have a simple init target that has the <tstamp/> call in it. This
used to work fine. Now, it for some reason does a full build. The only thing
we changed is in the folders of our packages, but code is still the same. Do
I need to run a touch on every .java file and every .class file. What is the
secret to getting Ant to build only files that have changed. Oh..I am using
various src dirs in the javac command, not sure if that makes a difference.

Thanks.