diff --git a/core/cleanspec.mk b/core/cleanspec.mk index af289540f3..4441e2ac3f 100644 --- a/core/cleanspec.mk +++ b/core/cleanspec.mk @@ -64,6 +64,6 @@ INTERNAL_CLEAN_BUILD_VERSION := 6 # ************************************************ subdir_cleanspecs := \ - $(file <$(OUT_DIR)/.module_paths/CleanSpec.mk.list) + $(shell build/tools/findleaves.py $(FIND_LEAVES_EXCLUDES) . CleanSpec.mk) include $(subdir_cleanspecs) subdir_cleanspecs := diff --git a/core/main.mk b/core/main.mk index 61dc9e6d3a..ea128e869f 100644 --- a/core/main.mk +++ b/core/main.mk @@ -420,7 +420,7 @@ ifneq ($(dont_bother),true) # Include all of the makefiles in the system # -subdir_makefiles := $(SOONG_ANDROID_MK) $(file <$(OUT_DIR)/.module_paths/Android.mk.list) +subdir_makefiles := $(SOONG_ANDROID_MK) $(call first-makefiles-under,$(TOP)) subdir_makefiles_total := $(words $(subdir_makefiles)) .KATI_READONLY := subdir_makefiles_total