From a16690c38cfde0aab151225067d6fdac1f5166f3 Mon Sep 17 00:00:00 2001 From: Jesse Hall Date: Mon, 5 Oct 2020 19:13:42 -0700 Subject: [PATCH] Skip unneeded notice files for DATA modules. Non-installable generated intermediate data modules can have notice files attached when they're defined in the same LOCAL_PATH as the installable module that depends on them. This makes uninstallable DATA modules silently ignore the fact that the build doesn't know where to install the notice file. Bug: 160248517 Test: build Change-Id: I09a8a253dda52c2d78a1ebc0c33cd96e3505e2e3 Merged-In: I09a8a253dda52c2d78a1ebc0c33cd96e3505e2e3 --- core/notice_files.mk | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/notice_files.mk b/core/notice_files.mk index 721a03411..0430007c3 100644 --- a/core/notice_files.mk +++ b/core/notice_files.mk @@ -79,8 +79,9 @@ else endif module_installed_filename := \ $(patsubst $(PRODUCT_OUT)/%,%,$($(my_prefix)OUT_JAVA_LIBRARIES))/$(module_leaf) - else ifeq ($(LOCAL_MODULE_CLASS),ETC) - # ETC modules may be uninstallable, yet still have a NOTICE file. e.g. apex components + else ifneq ($(filter ETC DATA,$(LOCAL_MODULE_CLASS)),) + # ETC and DATA modules may be uninstallable, yet still have a NOTICE file. + # e.g. apex components module_installed_filename := else ifneq (,$(and $(filter %.sdk,$(LOCAL_MODULE)),$(filter $(patsubst %.sdk,%,$(LOCAL_MODULE)),$(SOONG_SDK_VARIANT_MODULES)))) # Soong produces uninstallable *.sdk shared libraries for embedding in APKs.