Merge "Create hidden API lists" am: b6a5c92b50
am: 265863f9d9
Change-Id: I4d32dccc7c00216102b6bd91ed1f185c03c2c048
This commit is contained in:
22
Android.mk
22
Android.mk
@@ -697,6 +697,28 @@ LOCAL_SRC_FILES := \
|
||||
include $(BUILD_HOST_JAVA_LIBRARY)
|
||||
|
||||
|
||||
# ==== hiddenapi lists =======================================
|
||||
|
||||
# Generate light greylist as private API minus (blacklist plus dark greylist).
|
||||
|
||||
$(INTERNAL_PLATFORM_HIDDENAPI_LIGHT_GREYLIST): PRIVATE_API := $(INTERNAL_PLATFORM_PRIVATE_DEX_API_FILE)
|
||||
$(INTERNAL_PLATFORM_HIDDENAPI_LIGHT_GREYLIST): BLACKLIST := $(INTERNAL_PLATFORM_HIDDENAPI_BLACKLIST)
|
||||
$(INTERNAL_PLATFORM_HIDDENAPI_LIGHT_GREYLIST): DARK_GREYLIST := $(INTERNAL_PLATFORM_HIDDENAPI_DARK_GREYLIST)
|
||||
$(INTERNAL_PLATFORM_HIDDENAPI_LIGHT_GREYLIST): $(INTERNAL_PLATFORM_PRIVATE_DEX_API_FILE) \
|
||||
$(INTERNAL_PLATFORM_HIDDENAPI_BLACKLIST) \
|
||||
$(INTERNAL_PLATFORM_HIDDENAPI_DARK_GREYLIST)
|
||||
if [ ! -z "`comm -12 <(sort $(BLACKLIST)) <(sort $(DARK_GREYLIST))`" ]; then \
|
||||
echo "There should be no overlap between $(BLACKLIST) and $(DARK_GREYLIST)" 1>&2; \
|
||||
exit 1; \
|
||||
elif [ ! -z "`comm -13 <(sort $(PRIVATE_API)) <(sort $(BLACKLIST))`" ]; then \
|
||||
echo "$(BLACKLIST) must be a subset of $(PRIVATE_API)" 1>&2; \
|
||||
exit 2; \
|
||||
elif [ ! -z "`comm -13 <(sort $(PRIVATE_API)) <(sort $(DARK_GREYLIST))`" ]; then \
|
||||
echo "$(DARK_GREYLIST) must be a subset of $(PRIVATE_API)" 1>&2; \
|
||||
exit 3; \
|
||||
fi
|
||||
comm -23 <(sort $(PRIVATE_API)) <(sort $(BLACKLIST) $(DARK_GREYLIST)) > $@
|
||||
|
||||
# Include subdirectory makefiles
|
||||
# ============================================================
|
||||
|
||||
|
||||
0
config/hiddenapi-blacklist.txt
Normal file
0
config/hiddenapi-blacklist.txt
Normal file
0
config/hiddenapi-dark-greylist.txt
Normal file
0
config/hiddenapi-dark-greylist.txt
Normal file
Reference in New Issue
Block a user