I have to ammend my this post..

The problem I am seeing I think I know why its doing it..i just don't know
how to fix it. We have a source tree. I have a few build scripts. One build
script compiles a sub-tree of the source. For example,
com.mycompany.myproject is one of many subtrees below the mycompany tree.
Our dir is /src/com/mycompany/* where * = myproject, myotherproject, and so
on. I want to build JUST the files under myproject, to speed up compilation.
The main reason we are doing this is each of the sub-trees are tied to its
own version. We have different developers working on different subtrees,
each being a separate project with their own release dates (for web
application development). Therefore, each developer can build JUST the
source for their tree, which can be hundreds of source files. The main
reason I am using various scripts is because a couple of the sub-trees get
compiled into .jar files and not into the WEB-INF/classes dir..therefore
they would ALWAYS build. They would always build because after creating the
.jar, I remove the .class files. This isn't absolutely necessary, but I do
it to make sure the entire .jar source is compiled completely..just in case.

So I guess the question is, how can I compile a subset of the source tree
but build it to the same WEB-INF/classes folder, so that only changed files
compile?

Thanks again.


> -----Original Message-----
> From: Duffey, Kevin [mailto:[EMAIL PROTECTED]]
> Sent: Monday, March 19, 2001 5:31 PM
> To: '[EMAIL PROTECTED]'
> Subject: 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.
> 

Reply via email to