From 5ff00345b91a38a0288b13ac3574a890b4e557e7 Mon Sep 17 00:00:00 2001 From: Jack Rosenthal Date: Fri, 29 Oct 2021 17:52:48 -0600 Subject: zephyr: zmake: Upgrade to new BUILD.py format go/zephyr-variants defines a BUILD.py format that replaces zmake.yaml. BUILD.py is inspired by Bazel build definitions, allowing for arbitrary Python code to be used as the config format. This enables defining multiple projects in a single directory, and projects to make program-specific customizations to the config definition functions. The other following changes are of note: - Projects can still be referenced by directory name, but can be referenced by the much shorter project name. For example, both of the following work equivalently: $ zmake configure -b zephyr/projects/volteer/delbin $ zmake configure -b delbin - The default build directory was changed to: build/zephyr/${name} This implements the new format, drops the old YAML+jsonschema, and migrates all our projects to the new format. BUG=b:193815337 BRANCH=none TEST=unit tests TEST=zmake testall Signed-off-by: Jack Rosenthal Change-Id: Ib1e53d9abf558063117cc3f86a5d636e69cf77fe Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3253969 Reviewed-by: Jeremy Bettis Reviewed-by: Keith Short --- zephyr/zmake/zmake/__main__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'zephyr/zmake/zmake/__main__.py') diff --git a/zephyr/zmake/zmake/__main__.py b/zephyr/zmake/zmake/__main__.py index ea639584cc..ad4a7d96f0 100644 --- a/zephyr/zmake/zmake/__main__.py +++ b/zephyr/zmake/zmake/__main__.py @@ -200,7 +200,8 @@ def main(argv=None): help="Test the .elf file after configuration", ) configure.add_argument( - "project_dir", type=pathlib.Path, help="Path to the project to build" + "project_name_or_dir", + help="Path to the project to build", ) configure.add_argument( "-c", -- cgit v1.2.1