Use soong_ui directly, instead of make
This will use ckati instead of make for dumping variables, for
consistent makefile parsing. It may also sandbox executions, etc.
Also skip the legacy make wrapper to build, and use soong_ui instead.
The command line arguments are equivalent, but -j is no longer
necessary, we'll default to a sane value.
Test: bit -b framework
Change-Id: Idc2c9d1abe84b6b783b8702925de5493d47a4509
diff --git a/tools/bit/main.cpp b/tools/bit/main.cpp
index ad23971..e81898f 100644
--- a/tools/bit/main.cpp
+++ b/tools/bit/main.cpp
@@ -588,12 +588,13 @@
const string buildProduct = get_required_env("TARGET_PRODUCT", false);
const string buildVariant = get_required_env("TARGET_BUILD_VARIANT", false);
const string buildType = get_required_env("TARGET_BUILD_TYPE", false);
- const string buildDevice = get_build_var(buildTop, "TARGET_DEVICE", false);
- const string buildId = get_build_var(buildTop, "BUILD_ID", false);
- const string buildOut = get_out_dir();
chdir_or_exit(buildTop.c_str());
+ const string buildDevice = get_build_var("TARGET_DEVICE", false);
+ const string buildId = get_build_var("BUILD_ID", false);
+ const string buildOut = get_out_dir();
+
// Get the modules for the targets
map<string,Module> modules;
read_modules(buildOut, buildDevice, &modules, false);