sysroot: Add a new option to use Bazel to build packages
BUG=b:262460632
TEST=build_packages --board=amd64-generic --bazel --no-withdev --no-withdebug --no-withfactory --no-withtest --no-withautotest && build_image --board=amd64-generic base
Cq-Depend: chromium:4592613
Change-Id: I8e00c0f4c70cd48ff821c15950ac9aedd503d49b
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/chromite/+/4591373
Tested-by: Ryo Hashimoto <hashimoto@chromium.org>
Reviewed-by: Tim Bain <tbain@google.com>
Reviewed-by: Alex Klein <saklein@chromium.org>
Commit-Queue: Ryo Hashimoto <hashimoto@chromium.org>
diff --git a/api/controller/sysroot.py b/api/controller/sysroot.py
index 5a9ba36..93ab544 100644
--- a/api/controller/sysroot.py
+++ b/api/controller/sysroot.py
@@ -351,6 +351,9 @@
# Allow cros workon packages to build from the unstable ebuilds.
workon = input_proto.flags.workon
+ # Use Bazel to build packages.
+ bazel = input_proto.flags.bazel
+
if not target_sysroot.IsToolchainInstalled():
cros_build_lib.Die("Toolchain must first be installed.")
@@ -370,6 +373,7 @@
dryrun=dryrun,
backtrack=DEFAULT_BACKTRACK,
workon=workon,
+ bazel=bazel,
)
try: