On Tue, 8 May 2001, Ceki G�lc� wrote:
> Hi Craig,
>
> >Ceki, could you expand on why you're objecting to the multistage
> build >process? I'm with Peter on this one ... multi-stage builds
> save time for >the developers (because they do the minimum amount of
> work required), and >also make the "dist" target work better: > >-
> They reuse what's already been done, with transformations as needed >
> (so it runs faster, versus rebuilding everything again)
>
> Indeed.
>
> >- They add any *extra* steps needed (create Javadocs, copy sources,
> etc.) > that are appropriate for the binary distribution.
>
> There is nothing wrong with a multistage build process. It is pretty
> obvious that one needs to split the build process into multiple
> stages. Having a multistaged build is not the same as requiring a
> intermediary build directory.
>
Ok, but ...
> IMHO, the intermediate build directory can and should be avoided.
> Instead of selectively copying from the intermediate build/ directory
> to dist/, one can generate directly to dist/ and use tar/zip
> selectively to create the distribution. The latter solution keeps just
> one copy of files which saves space. More importantly the latter is
> less error-prone as there is only one place to edit files. Does that
> make sense? Ceki
>
It doesn't make sense from my Tomcat perspective. Remember that my goal
for the intermediate directory is *not* to create the equivalent of a
binary distribution -- it is to turn around compiles as quickly as
possible so that I can fix the next problem. My day-to-day work lives in
the intermediate directory, and the "dist" target is used very rarely.
(On a slow box, building Tomcat 4.0 from scratch to the intermediate
target takes a couple of minutes, while running the "dist" target triples
or quadruples that. Multiply this by lots of edit-compile-test cycles
during a day and it *really* adds up.)
Can I get rid of it? Sure, but that costs me having to duplicate *all* of
the compile commands in the "deploy-main" target into the "dist" target as
well, and hope that I don't forget to update in both places when I add
somethng new. The very original Tomcat 3.0 build worked that way, and
proved to be incredibly error prone.
I should say that disk space is absolutely not an issue for me, but even
if it was, the fact that I never create the "dist" target under normal
circumsances makes it moot.
> >- Most fundamentally, they let the "shape" of the intermediate build
> > directory tree be different from that of the binary distribution >
> if that's appropriate to your project.
>
> Couldn't selective tar or zip operation work? Couldn't the <copy>
> operation be avoided?
>
The <copy> operation is what saves me from having to have two sets of
<javac> and <jar> commands (one for the intermediate directory and
one for the dist directory), and all the worry about having to keep
them in synch. It is very very very much worth it for that.
> >What is it that you believe we are missing?
>
> I dunno. The only difference I see is the requirement for an
> intermediate directory. Regards, Ceki
>
See above :-)
Craig
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]