views:

34

answers:

1

Java compiler provides incremental build, so javac ant task as well. But most other processes don't.

Considering build processes, they transform some set of files (source) into another set of files (target).

I can distinct two cases here:

  1. Transformator cannot take a subset of source files, only the whole set. Here we can only make lazy build - if no files from source was modified - we skip processing.
  2. Transformator can take a subset of sources files and produce a partial result - incremental build.

What are ant internal, third-party extensions or other tools to implement lazy and incremental build? Can you provide some widespread buildfile examples?

I am interested this to work with GWT compiler in particular.

+1  A: 

Related to GWT, it's not possible to do incremental builds because the GWT compiler looks at all the source code at once and optimizes and inlines code. This means code that wasn't changed could be evaluated differently, for example if you start using a method from a class that wasn't changed, the method was in the previous compilation step left out, but now needs to be compiled in.

Hilbrand