Merge "Sanity check LOCAL_SRC_FILES_EXCLUDE" am: cc3b2a5854 am: a4769d2956
am: 2b661fe7e0

* commit '2b661fe7e03b73be082b1d5be0d21e9c64393f4b':
  Sanity check LOCAL_SRC_FILES_EXCLUDE
diff --git a/core/binary.mk b/core/binary.mk
index 9437fa3..02dfeb9 100644
--- a/core/binary.mk
+++ b/core/binary.mk
@@ -177,6 +177,11 @@
 my_c_includes += $(LOCAL_C_INCLUDES_$($(my_prefix)$(LOCAL_2ND_ARCH_VAR_PREFIX)ARCH)) $(LOCAL_C_INCLUDES_$(my_32_64_bit_suffix))
 my_generated_sources += $(LOCAL_GENERATED_SOURCES_$($(my_prefix)$(LOCAL_2ND_ARCH_VAR_PREFIX)ARCH)) $(LOCAL_GENERATED_SOURCES_$(my_32_64_bit_suffix))
 
+my_missing_exclude_files := $(filter-out $(my_src_files),$(my_src_files_exclude))
+ifneq ($(my_missing_exclude_files),)
+$(warning Files are listed in LOCAL_SRC_FILES_EXCLUDE but not LOCAL_SRC_FILES)
+$(error $(my_missing_exclude_files))
+endif
 my_src_files := $(filter-out $(my_src_files_exclude),$(my_src_files))
 
 my_clang := $(strip $(LOCAL_CLANG))