compat: interfaces: backend: radio: config: Use a macro to declare the libs
Change-Id: I03251612315270d15474b740078ada17e17e522d
This commit is contained in:
parent
00551f44d6
commit
543ade588a
1 changed files with 18 additions and 51 deletions
|
@ -18,58 +18,25 @@ else
|
||||||
_lib_dir := lib
|
_lib_dir := lib
|
||||||
endif
|
endif
|
||||||
|
|
||||||
include $(CLEAR_VARS)
|
define _shim_hidl_library_template
|
||||||
_version := 1.0
|
_version := $(1)
|
||||||
_sed_pattern := "s|$(_frontend_hidl_package_name)@$(_version)::$(_frontend_hidl_interface_name)|$(_backend_hidl_package_name)@$(_version)::$(_backend_hidl_interface_name)|g;s|$(_frontend_hidl_package_name)(@1\.[0-9]\.so)|$(_shim_hidl_library_name)\1|g"
|
_sed_pattern := "s|$$(_frontend_hidl_package_name)@$$(_version)::$$(_frontend_hidl_interface_name)|$$(_backend_hidl_package_name)@$$(_version)::$$(_backend_hidl_interface_name)|g;s|$$(_frontend_hidl_package_name)(@[0-9]+\.[0-9]+\.so)|$$(_shim_hidl_library_name)\1|g"
|
||||||
|
|
||||||
LOCAL_MODULE := $(_shim_hidl_library_name)@$(_version)
|
include $$(CLEAR_VARS)
|
||||||
LOCAL_MODULE_STEM := $(LOCAL_MODULE).so
|
|
||||||
LOCAL_MODULE_CLASS := DATA
|
|
||||||
LOCAL_MODULE_TAGS := optional
|
|
||||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/$(_lib_dir)
|
|
||||||
LOCAL_REQUIRED_MODULES := $(_frontend_hidl_package_name)@$(_version).vendor
|
|
||||||
LOCAL_PREBUILT_MODULE_FILE := $(TARGET_OUT_VENDOR)/$(_lib_dir)/$(_frontend_hidl_package_name)@$(_version).so
|
|
||||||
LOCAL_POST_INSTALL_CMD := /usr/bin/sed -E -i $(_sed_pattern) $(LOCAL_MODULE_PATH)/$(LOCAL_MODULE_STEM)
|
|
||||||
include $(BUILD_PREBUILT)
|
|
||||||
|
|
||||||
include $(CLEAR_VARS)
|
LOCAL_MODULE := $$(_shim_hidl_library_name)@$$(_version)
|
||||||
_version := 1.1
|
|
||||||
_sed_pattern := "s|$(_frontend_hidl_package_name)@$(_version)::$(_frontend_hidl_interface_name)|$(_backend_hidl_package_name)@$(_version)::$(_backend_hidl_interface_name)|g;s|$(_frontend_hidl_package_name)(@1\.[0-9]\.so)|$(_shim_hidl_library_name)\1|g"
|
|
||||||
|
|
||||||
LOCAL_MODULE := $(_shim_hidl_library_name)@$(_version)
|
LOCAL_MODULE_STEM := $$(LOCAL_MODULE).so
|
||||||
LOCAL_MODULE_STEM := $(LOCAL_MODULE).so
|
LOCAL_MODULE_CLASS := DATA
|
||||||
LOCAL_MODULE_CLASS := DATA
|
LOCAL_MODULE_TAGS := optional
|
||||||
LOCAL_MODULE_TAGS := optional
|
LOCAL_MODULE_PATH := $$(TARGET_OUT_VENDOR)/$$(_lib_dir)
|
||||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/$(_lib_dir)
|
LOCAL_REQUIRED_MODULES := $$(_frontend_hidl_package_name)@$$(_version).vendor
|
||||||
LOCAL_REQUIRED_MODULES := $(_frontend_hidl_package_name)@$(_version).vendor
|
LOCAL_PREBUILT_MODULE_FILE := $$(TARGET_OUT_VENDOR)/$$(_lib_dir)/$$(_frontend_hidl_package_name)@$$(_version).so
|
||||||
LOCAL_PREBUILT_MODULE_FILE := $(TARGET_OUT_VENDOR)/$(_lib_dir)/$(_frontend_hidl_package_name)@$(_version).so
|
LOCAL_POST_INSTALL_CMD := /usr/bin/sed -E -i $$(_sed_pattern) $$(LOCAL_MODULE_PATH)/$$(LOCAL_MODULE_STEM)
|
||||||
LOCAL_POST_INSTALL_CMD := /usr/bin/sed -E -i $(_sed_pattern) $(LOCAL_MODULE_PATH)/$(LOCAL_MODULE_STEM)
|
include $$(BUILD_PREBUILT)
|
||||||
include $(BUILD_PREBUILT)
|
endef
|
||||||
|
|
||||||
include $(CLEAR_VARS)
|
$(eval $(call _shim_hidl_library_template,1.0))
|
||||||
_version := 1.2
|
$(eval $(call _shim_hidl_library_template,1.1))
|
||||||
_sed_pattern := "s|$(_frontend_hidl_package_name)@$(_version)::$(_frontend_hidl_interface_name)|$(_backend_hidl_package_name)@$(_version)::$(_backend_hidl_interface_name)|g;s|$(_frontend_hidl_package_name)(@1\.[0-9]\.so)|$(_shim_hidl_library_name)\1|g"
|
$(eval $(call _shim_hidl_library_template,1.2))
|
||||||
|
$(eval $(call _shim_hidl_library_template,1.3))
|
||||||
LOCAL_MODULE := $(_shim_hidl_library_name)@$(_version)
|
|
||||||
LOCAL_MODULE_STEM := $(LOCAL_MODULE).so
|
|
||||||
LOCAL_MODULE_CLASS := DATA
|
|
||||||
LOCAL_MODULE_TAGS := optional
|
|
||||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/$(_lib_dir)
|
|
||||||
LOCAL_REQUIRED_MODULES := $(_frontend_hidl_package_name)@$(_version).vendor
|
|
||||||
LOCAL_PREBUILT_MODULE_FILE := $(TARGET_OUT_VENDOR)/$(_lib_dir)/$(_frontend_hidl_package_name)@$(_version).so
|
|
||||||
LOCAL_POST_INSTALL_CMD := /usr/bin/sed -E -i $(_sed_pattern) $(LOCAL_MODULE_PATH)/$(LOCAL_MODULE_STEM)
|
|
||||||
include $(BUILD_PREBUILT)
|
|
||||||
|
|
||||||
include $(CLEAR_VARS)
|
|
||||||
_version := 1.3
|
|
||||||
_sed_pattern := "s|$(_frontend_hidl_package_name)@$(_version)::$(_frontend_hidl_interface_name)|$(_backend_hidl_package_name)@$(_version)::$(_backend_hidl_interface_name)|g;s|$(_frontend_hidl_package_name)(@1\.[0-9]\.so)|$(_shim_hidl_library_name)\1|g"
|
|
||||||
|
|
||||||
LOCAL_MODULE := $(_shim_hidl_library_name)@$(_version)
|
|
||||||
LOCAL_MODULE_STEM := $(LOCAL_MODULE).so
|
|
||||||
LOCAL_MODULE_CLASS := DATA
|
|
||||||
LOCAL_MODULE_TAGS := optional
|
|
||||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/$(_lib_dir)
|
|
||||||
LOCAL_REQUIRED_MODULES := $(_frontend_hidl_package_name)@$(_version).vendor
|
|
||||||
LOCAL_PREBUILT_MODULE_FILE := $(TARGET_OUT_VENDOR)/$(_lib_dir)/$(_frontend_hidl_package_name)@$(_version).so
|
|
||||||
LOCAL_POST_INSTALL_CMD := /usr/bin/sed -E -i $(_sed_pattern) $(LOCAL_MODULE_PATH)/$(LOCAL_MODULE_STEM)
|
|
||||||
include $(BUILD_PREBUILT)
|
|
||||||
|
|
Loading…
Reference in a new issue