BUILD_PREBUILT

2019-06-12  本文已影响0人  小磊长江大
LOCAL_PATH:= $(call my-dir)

multi_apk := $(patsubst $(LOCAL_PATH)/app/%.apk,%,$(wildcard $(LOCAL_PATH)/app/*.apk))

$(foreach t,$(multi_apk), \
    $(eval include $(CLEAR_VARS)) \
    $(eval LOCAL_MODULE     := $(notdir $(t))) \
    $(eval LOCAL_MODULE_CLASS := APPS) \
    $(eval LOCAL_SRC_FILES   := app/$(t).apk) \
    $(eval LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX)) \
    $(eval LOCAL_CERTIFICATE := PRESIGNED) \
    $(eval include $(BUILD_PREBUILT)) \
    )

multi_so := $(patsubst $(LOCAL_PATH)/lib/%.so,%,$(wildcard $(LOCAL_PATH)/lib/*.so))

$(foreach t,$(multi_so), \
    $(eval include $(CLEAR_VARS)) \
    $(eval LOCAL_MODULE     := $(notdir $(t))) \
    $(eval LOCAL_MODULE_TAGS := optional) \
    $(eval LOCAL_MODULE_CLASS := SHARED_LIBRARIES) \
    $(eval LOCAL_SRC_FILES   := lib/$(t).so) \
    $(eval LOCAL_MODULE_SUFFIX := $(TARGET_SHLIB_SUFFIX)) \
    $(eval include $(BUILD_PREBUILT)) \
    )


multi_bin := $(patsubst $(LOCAL_PATH)/bin/%,%,$(wildcard $(LOCAL_PATH)/bin/*))

$(foreach t,$(multi_bin), \
    $(eval include $(CLEAR_VARS)) \
    $(eval LOCAL_MODULE     := $(notdir $(t))) \
    $(eval LOCAL_MODULE_CLASS := EXECUTABLES) \
    $(eval LOCAL_SRC_FILES   := bin/$(t)) \
    $(eval LOCAL_MODULE_SUFFIX := $(TARGET_EXECUTABLE_SUFFIX)) \
    $(eval include $(BUILD_PREBUILT)) \
    )

multi_etc := $(patsubst $(LOCAL_PATH)/etc/%,%,$(wildcard $(LOCAL_PATH)/etc/*))


$(foreach t,$(multi_etc), \
    $(eval include $(CLEAR_VARS)) \
    $(eval LOCAL_MODULE     := $(notdir $(t))) \
    $(eval LOCAL_MODULE_CLASS := ETC) \
    $(eval LOCAL_SRC_FILES   := etc/$(t)) \
    $(eval LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/myetc) \
    $(eval include $(BUILD_PREBUILT)) \
    )
上一篇下一篇

猜你喜欢

热点阅读