commit | 3edfbc214a07c2e7689b1eb749ea9df6796a6e91 | [log] [tgz] |
---|---|---|
author | Yo Chiang <yochiang@google.com> | Tue Mar 03 15:42:52 2020 +0800 |
committer | Yo Chiang <yochiang@google.com> | Wed Mar 04 09:46:17 2020 +0800 |
tree | b550301c980428dd3250d754a38f514877db378b | |
parent | 03d3ee51f62c8453ed5d034579fc10a9ec4bd896 [diff] |
Set bpmodify usage function golang `flag` package's default FlagSet `flag.CommandLine` calls `flag.Usage` and `os.Exit(2)` on error to print the usage string. Set `flag.Usage` to our custom usage function. Test: m bpmodify; bpmodify -h; bpmodify --help Change-Id: Ida107b0dbb07c291c3d7ea90eda9147d04a7cd51
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.