Consolidate the logic for the sdk prebuilt module names.

I'm making some changes to it, and found the names are scattered
in various places. Make a macro and re-use the logic instead.

Bug: 77525052
Test: make droid
Change-Id: I0f2da80b8b4d427353509b27ec720d024eee7a6e
This commit is contained in:
Anton Hansson
2018-04-10 16:16:33 +01:00
parent f05573eb91
commit 400673cf1e
4 changed files with 20 additions and 13 deletions

View File

@@ -406,7 +406,7 @@ endif
proguard_dictionary := $(intermediates.COMMON)/proguard_dictionary
# When an app contains references to APIs that are not in the SDK specified by
# its LOCAL_SDK_VERSION for example added by support library or by runtime
# its LOCAL_SDK_VERSION for example added by support library or by runtime
# classes added by desugar, we artifically raise the "SDK version" "linked" by
# ProGuard, to
# - suppress ProGuard warnings of referencing symbols unknown to the lower SDK version.
@@ -416,7 +416,7 @@ my_proguard_sdk_raise :=
ifdef LOCAL_SDK_VERSION
ifdef TARGET_BUILD_APPS
ifeq (,$(filter current system_current test_current core_current, $(LOCAL_SDK_VERSION)))
my_proguard_sdk_raise := $(call java-lib-header-files, sdk_vcurrent)
my_proguard_sdk_raise := $(call java-lib-header-files, $(call resolve-prebuilt-sdk-module,current))
endif
else
# For platform build, we can't just raise to the "current" SDK,