Skip old file cleanup for non-full builds.
There are few build targets that don't generate an installed file list,
e.g. product-graph. Skip the old installed file cleanup step so that the
func doesn't complain about a lack of the list file.
Fixes: 168105598
Test: m product-graph
Change-Id: Ib7dce6b801979bb565b74d6355143bac23b84fe6
diff --git a/ui/build/dumpvars.go b/ui/build/dumpvars.go
index fe0aca9..be6f00a 100644
--- a/ui/build/dumpvars.go
+++ b/ui/build/dumpvars.go
@@ -214,6 +214,9 @@
// So that later Kati runs can find BoardConfig.mk faster
"TARGET_DEVICE_DIR",
+ // To decide whether to skip the old installed cleanup step.
+ "FULL_BUILD",
+
// Whether --werror_overriding_commands will work
"BUILD_BROKEN_DUP_RULES",
@@ -278,6 +281,7 @@
config.SetNinjaArgs(strings.Fields(makeVars["NINJA_GOALS"]))
config.SetTargetDevice(makeVars["TARGET_DEVICE"])
config.SetTargetDeviceDir(makeVars["TARGET_DEVICE_DIR"])
+ config.SetFullBuild(makeVars["FULL_BUILD"] == "true")
config.SetBuildBrokenDupRules(makeVars["BUILD_BROKEN_DUP_RULES"] == "true")
config.SetBuildBrokenUsesNetwork(makeVars["BUILD_BROKEN_USES_NETWORK"] == "true")