Merge "Revert "Support <dir>:<file> for LOCAL_JAVA_RESOURCE_FILES"" am: 7d607a1917

am: 0b42833ae3

Change-Id: I9a535f635da245473130345643e1e0b0250885df
This commit is contained in:
Colin Cross 2017-09-22 20:56:41 +00:00 committed by android-build-merger
commit 8cfde56105

View file

@ -105,18 +105,12 @@ ifneq ($(LOCAL_JAVA_RESOURCE_DIRS),)
java_resource_file_groups := $(filter-out %:,$(java_resource_file_groups))
endif # LOCAL_JAVA_RESOURCE_DIRS
LOCAL_JAVA_RESOURCE_FILES := $(strip $(LOCAL_JAVA_RESOURCE_FILES))
ifneq ($(LOCAL_JAVA_RESOURCE_FILES),)
# Converts LOCAL_JAVA_RESOURCE_FILES := <file> to $(dir $(file))::$(notdir $(file))
# and LOCAL_JAVA_RESOURCE_FILES := <dir>:<file> to <dir>::<file>
java_resource_file_groups += $(strip $(foreach res,$(LOCAL_JAVA_RESOURCE_FILES), \
$(eval _file := $(call word-colon,2,$(res))) \
$(if $(_file), \
$(eval _base := $(call word-colon,1,$(res))), \
$(eval _base := $(dir $(res))) \
$(eval _file := $(notdir $(res)))) \
$(if $(filter /%,$(_base) $(_file)),$(call pretty-error,LOCAL_JAVA_RESOURCE_FILES may not include absolute paths: $(_base) $(_file))) \
$(patsubst %/,%,$(_base))::$(_file)))
java_resource_file_groups += \
$(foreach f,$(LOCAL_JAVA_RESOURCE_FILES), \
$(patsubst %/,%,$(dir $(f)))::$(notdir $(f)) \
)
endif # LOCAL_JAVA_RESOURCE_FILES
ifdef java_resource_file_groups