commit | 9403b5a790a8750cc98036d0265fed99b2610b5b | [log] [tgz] |
---|---|---|
author | Colin Cross <ccross@android.com> | Wed Nov 13 20:11:04 2019 -0800 |
committer | Colin Cross <ccross@android.com> | Thu Nov 14 12:58:52 2019 -0800 |
tree | 2398af7a701ee460dcc83e87d445be1732f73edb | |
parent | d03b59d03e765ff7cc8258f0fddfaefca3b26d70 [diff] |
Delay allocating variationMaps until populating them Modules are created with a nil variantionMap, which avoids allocating an empty map if the module will never be split. Context.addVariationDependencies constructs a variationMap to compare against the variationMap of each variant, but constructed an empty variationMap if no variations were specified. A nil map is not the same as an empty map, so consistently use a nil map and create it when populating the first entry. Change-Id: I48b604659f9cdb23326b504a093cdfe5a3eb4f68
Blueprint is a meta-build system that reads in Blueprints files that describe modules that need to be built, and produces a Ninja manifest describing the commands that need to be run and their dependencies. Where most build systems use built-in rules or a domain-specific language to describe the logic for converting module descriptions to build rules, Blueprint delegates this to per-project build logic written in Go. For large, heterogenous projects this allows the inherent complexity of the build logic to be maintained in a high-level language, while still allowing simple changes to individual modules by modifying easy to understand Blueprints files.