Somehow "patch #0" of my series didn't go out.  So, I'm sending it
separately.  Sorry about that.  I don't know what happened, so I
wouldn't be totally surprised if it made its way to the list some day :)


This patch series resurrects my automatic dependency tracking patch from
eons ago.

That patch was ultimately reverted due to a GNU make bug.  This time
around, thanks to git, I chose to make a patch series.  This way, even
if we stumble across the bug again (it is not clear it was ever
fixed), we can determine which patch triggers it, and still possibly
gain some benefit from the remaining patches.

This series is not "complete" in the sense that there are automatic
dependency tracking opportunities that it does not implement.  In
particular, these still remain to be converted:

* The files in config/
* The Ada front end
* The "build" objects

Still, I think this series is a big improvement over the status quo.
If you read patch #14, you'll see that it deletes a huge number of
hand-maintained dependencies.

The overall approach used here is the one that has been used by many
projects for many years -- at least including all automake-based
projects, libcpp, and gdb.  It is reasonably robust.

Dependencies are generated as a side effect of compilation.  These
dependencies are then written to ".Po" files in the build tree; they
are included into the Makefile via the GNU make "include" feature.

The only difficulty here is that generated files must be built before
object files.  In order to avoid hand-maintaining dependencies on
generated files, we have an order-only dependency (another GNU make
feature) to ensure that generated files are built before we build any
host .o.

This series fixes a few latent bugs in the current Makefiles.

I tested this by bootstrapping it on x86-64 Fedora 18, and also PPC64
Fedora 18 (gcc110 -- nice machine).

I also did a number of clean builds of the gcc directory at various -j
levels (including -j129 -- thank you gcc110) to try to flush out any
missing dependencies on generated files.

This is essentially the same series as appears on the branch in
gcc.git.  It has just been rebased into a patch series form.  Thank
you again, git.

Let me know what you think.

Tom

Reply via email to