From 238c6ba8fe9527b85e0ab7dda9d10e8bd407d63f Mon Sep 17 00:00:00 2001 From: Yifan Hong Date: Tue, 9 Jan 2018 17:17:32 -0800 Subject: [PATCH] add to VINTF. Test: libvintf_test Test: vintf_object_test Test: build and verify that tags are in framework manifest and device compatibility matrix. Fixes: 36400653 Change-Id: I4d44bff81fecc8fd2f7ab8e15770544b7b85aef9 --- target/board/Android.mk | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/target/board/Android.mk b/target/board/Android.mk index ae6be9210..3768ece4f 100644 --- a/target/board/Android.mk +++ b/target/board/Android.mk @@ -53,6 +53,13 @@ include $(BUILD_PREBUILT) BUILT_VENDOR_MANIFEST := $(LOCAL_BUILT_MODULE) endif +# VNDK Version in device compatibility matrix and framework manifest +ifeq ($(BOARD_VNDK_VERSION),current) +VINTF_VNDK_VERSION := $(PLATFORM_VNDK_VERSION) +else +VINTF_VNDK_VERSION := $(BOARD_VNDK_VERSION) +endif + # Device Compatibility Matrix ifdef DEVICE_MATRIX_FILE include $(CLEAR_VARS) @@ -62,9 +69,11 @@ LOCAL_MODULE_CLASS := ETC LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR) GEN := $(local-generated-sources-dir)/compatibility_matrix.xml + +$(GEN): PRIVATE_VINTF_VNDK_VERSION := $(VINTF_VNDK_VERSION) $(GEN): $(DEVICE_MATRIX_FILE) $(HOST_OUT_EXECUTABLES)/assemble_vintf - # TODO(b/37342627): put BOARD_VNDK_VERSION & BOARD_VNDK_LIBRARIES into device matrix. - $(HOST_OUT_EXECUTABLES)/assemble_vintf -i $< -o $@ + REQUIRED_VNDK_VERSION=$(PRIVATE_VINTF_VNDK_VERSION) \ + $(HOST_OUT_EXECUTABLES)/assemble_vintf -i $< -o $@ LOCAL_PREBUILT_MODULE_FILE := $(GEN) include $(BUILD_PREBUILT) @@ -89,9 +98,12 @@ $(GEN): PRIVATE_FLAGS += -c "$(BUILT_VENDOR_MATRIX)" endif endif +$(GEN): PRIVATE_VINTF_VNDK_VERSION := $(VINTF_VNDK_VERSION) $(GEN): PRIVATE_FRAMEWORK_MANIFEST_INPUT_FILES := $(FRAMEWORK_MANIFEST_INPUT_FILES) $(GEN): $(FRAMEWORK_MANIFEST_INPUT_FILES) $(HOST_OUT_EXECUTABLES)/assemble_vintf - BOARD_SEPOLICY_VERS=$(BOARD_SEPOLICY_VERS) $(HOST_OUT_EXECUTABLES)/assemble_vintf \ + BOARD_SEPOLICY_VERS=$(BOARD_SEPOLICY_VERS) \ + PROVIDED_VNDK_VERSIONS="$(PRIVATE_VINTF_VNDK_VERSION) $(PRODUCT_EXTRA_VNDK_VERSIONS)" \ + $(HOST_OUT_EXECUTABLES)/assemble_vintf \ -i $(call normalize-path-list,$(PRIVATE_FRAMEWORK_MANIFEST_INPUT_FILES)) \ -o $@ $(PRIVATE_FLAGS) @@ -99,3 +111,4 @@ LOCAL_PREBUILT_MODULE_FILE := $(GEN) include $(BUILD_PREBUILT) BUILT_SYSTEM_MANIFEST := $(LOCAL_BUILT_MODULE) +VINTF_VNDK_VERSION :=