From 584e4724ba73af5ac8e79ad6ff6b71753879f22c Mon Sep 17 00:00:00 2001 From: Dan Willemsen Date: Fri, 9 Sep 2016 23:18:22 -0700 Subject: [PATCH] Remove --ignore_dirty=$(OUT_DIR)/% from Kati flags We really should be re-running Kati when a file in here changes, since it may actually affect the result. The general problem we've run into is when there are two kati output files that are clean according to the current rules, but if they actually ran we'd force an installclean. This also had the side-effect of not running shell commands that touched $OUT_DIR, like writing files using $(shell echo ... >out/...), now those may be run. This will cause Kati to re-read the makefiles more often -- twice when a CleanSpec.mk changes, twice when switching products on the same device. Basically every time we read the old state, do something about it, and write out the new state, we need to rerun the next time so we aren't continuously cleaning up what changed. Bug: 30947985 Test: Manual, switching between configurations; enable --regen_debug Change-Id: I888f9f8295f318f8214b2c79525cf94f457a5a8b --- core/ninja.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/ninja.mk b/core/ninja.mk index 8a5a904c3..af2ede091 100644 --- a/core/ninja.mk +++ b/core/ninja.mk @@ -97,7 +97,7 @@ ifeq ($(KATI_EMULATE_FIND),false) endif $(KATI_BUILD_NINJA): $(CKATI) $(MAKEPARALLEL) $(DUMMY_OUT_MKS) run_soong FORCE @echo Running kati to generate build$(KATI_NINJA_SUFFIX).ninja... - +$(hide) $(KATI_MAKEPARALLEL) $(CKATI) --ninja --ninja_dir=$(OUT_DIR) --ninja_suffix=$(KATI_NINJA_SUFFIX) --regen --ignore_dirty=$(OUT_DIR)/% --no_ignore_dirty=$(SOONG_OUT_DIR)/%.mk --ignore_optional_include=$(OUT_DIR)/%.P --detect_android_echo $(KATI_FIND_EMULATOR) -f build/core/main.mk $(KATI_GOALS) --gen_all_targets BUILDING_WITH_NINJA=true SOONG_ANDROID_MK=$(SOONG_ANDROID_MK) SOONG_MAKEVARS_MK=$(SOONG_MAKEVARS_MK) + +$(hide) $(KATI_MAKEPARALLEL) $(CKATI) --ninja --ninja_dir=$(OUT_DIR) --ninja_suffix=$(KATI_NINJA_SUFFIX) --regen --ignore_optional_include=$(OUT_DIR)/%.P --detect_android_echo $(KATI_FIND_EMULATOR) -f build/core/main.mk $(KATI_GOALS) --gen_all_targets BUILDING_WITH_NINJA=true SOONG_ANDROID_MK=$(SOONG_ANDROID_MK) SOONG_MAKEVARS_MK=$(SOONG_MAKEVARS_MK) .PHONY: FORCE FORCE: