RFR: 8326947: Minimize MakeBase.gmk

Erik Joelsson erikj at openjdk.org
Wed Feb 28 14:05:43 UTC 2024


On Wed, 28 Feb 2024 11:24:06 GMT, Magnus Ihse Bursie <ihse at openjdk.org> wrote:

> This is part of a general "spring cleaning" of the build system, addressing old code that has bit-rotted, been subject to lava flow, or just had bad or smelly code that we've never gotten around to fix.
> 
> This particular patch tries to make MakeBase truly minimal; only including the core parts of the build system that all makefiles will need. This is now limited to essential functionality for named parameter functions, variable dependency, tool execution, logging and fixpath functionality. MakeBase still includes Utils.gmk and FileUtils.gmk, and thus "provides" this functionality as well. Separating these out as well will be the subject of a future patch.

The distinction between Utils.gmk and BaseUtils.gmk seems a bit arbitrary at a glance, especially since both are still included from MakeBase.gmk. How would you know in which file to add a new macro?

make/ReleaseFile.gmk line 40:

> 38: # A file containing a way to uniquely identify the source code revision that
> 39: # the build was created from
> 40: SOURCE_REVISION_TRACKER := $(SUPPORT_OUTPUTDIR)/src-rev/source-revision-tracker

Other file locations that need to be shared between different makefiles are defined in spec.gmk.in. Not ideal either, but perhaps better for now than having to define the value twice?

-------------

PR Review: https://git.openjdk.org/jdk/pull/18041#pullrequestreview-1906328783
PR Review Comment: https://git.openjdk.org/jdk/pull/18041#discussion_r1506000674


More information about the build-dev mailing list