RFR: JDK-8076060 Improve make bootstrap process

Magnus Ihse Bursie magnus.ihse.bursie at oracle.com
Thu Mar 26 10:54:36 UTC 2015


The process of actually starting to build the proper targets in Main.gmk 
is not straightforward. Somewhat similar to how configure prepares the 
ground for make, the initial part of the make logic needs to handle the 
make process "bootstrapping".

Unfortunately, this logic has been spread out in multiple places, and 
not very clear. This makes it fragile and hard to improve.

This patch collects all bootstrapping logic into a new Init.gmk, with 
hopefully a clear flow showing how the system is initialized.

It also improves handling of outdated spec files by a new CHECK_CONF 
control variable, along with various other small fixes to issues 
typically related to make bootstrapping. For instance, bash completion 
support for make targets is sped up considerably. A few slightly 
unrelated spring cleaning fixes are also included, for good measure.

One of the ideas behind this patch is that the top-level Makefile should 
be a thin wrapper, so all actual build logic is in the make directory. 
In the end, it turned out to be best to have some sanity checking on 
make itself in that file.

Going forward, I'd like to see an even better way of gathering the real 
make targets and modules, rather than polling Main.gmk.  But now at 
least we're prepared for such a step.

Bug: https://bugs.openjdk.java.net/browse/JDK-8076060
WebRev: 
http://cr.openjdk.java.net/~ihse/JDK-8076060-improve-make-bootstrap/webrev.01

/Magnus




More information about the build-dev mailing list