am 69c3f457: am dc7fee9f: Set up rules to merge AndroidManifest.xmls
* commit '69c3f4570d80eab99bfcab604209dc7bb3ae5537': Set up rules to merge AndroidManifest.xmls
This commit is contained in:
commit
dd22aee1f4
|
@ -0,0 +1,25 @@
|
||||||
|
# Handle AndroidManifest.xmls
|
||||||
|
# Input: LOCAL_MANIFEST_FILE, LOCAL_FULL_MANIFEST_FILE, LOCAL_FULL_LIBS_MANIFEST_FILES
|
||||||
|
# Output: full_android_manifest
|
||||||
|
|
||||||
|
ifeq ($(strip $(LOCAL_MANIFEST_FILE)),)
|
||||||
|
LOCAL_MANIFEST_FILE := AndroidManifest.xml
|
||||||
|
endif
|
||||||
|
ifdef LOCAL_FULL_MANIFEST_FILE
|
||||||
|
full_android_manifest := $(LOCAL_FULL_MANIFEST_FILE)
|
||||||
|
else
|
||||||
|
full_android_manifest := $(LOCAL_PATH)/$(LOCAL_MANIFEST_FILE)
|
||||||
|
endif
|
||||||
|
|
||||||
|
# Set up rules to merge library manifest files
|
||||||
|
ifdef LOCAL_FULL_LIBS_MANIFEST_FILES
|
||||||
|
main_android_manifest := $(full_android_manifest)
|
||||||
|
full_android_manifest := $(intermediates.COMMON)/AndroidManifest.xml
|
||||||
|
$(full_android_manifest): PRIVATE_LIBS_MANIFESTS := $(LOCAL_FULL_LIBS_MANIFEST_FILES)
|
||||||
|
$(full_android_manifest) : $(main_android_manifest) $(LOCAL_FULL_LIBS_MANIFEST_FILES)
|
||||||
|
@echo "Merge android manifest files: $@ <-- $^"
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
$(hide) $(ANDROID_MANIFEST_MERGER) --main $< --libs $(PRIVATE_LIBS_MANIFESTS) \
|
||||||
|
--out $@
|
||||||
|
|
||||||
|
endif
|
|
@ -109,6 +109,7 @@ LOCAL_EMMA_COVERAGE_FILTER:=
|
||||||
LOCAL_WARNINGS_ENABLE:=
|
LOCAL_WARNINGS_ENABLE:=
|
||||||
LOCAL_FULL_MANIFEST_FILE:=
|
LOCAL_FULL_MANIFEST_FILE:=
|
||||||
LOCAL_MANIFEST_FILE:=
|
LOCAL_MANIFEST_FILE:=
|
||||||
|
LOCAL_FULL_LIBS_MANIFEST_FILES:=
|
||||||
LOCAL_RENDERSCRIPT_INCLUDES:=
|
LOCAL_RENDERSCRIPT_INCLUDES:=
|
||||||
LOCAL_RENDERSCRIPT_INCLUDES_OVERRIDE:=
|
LOCAL_RENDERSCRIPT_INCLUDES_OVERRIDE:=
|
||||||
LOCAL_RENDERSCRIPT_CC:=
|
LOCAL_RENDERSCRIPT_CC:=
|
||||||
|
|
|
@ -348,6 +348,9 @@ ZIPALIGN := $(HOST_OUT_EXECUTABLES)/zipalign$(HOST_EXECUTABLE_SUFFIX)
|
||||||
FINDBUGS := prebuilt/common/findbugs/bin/findbugs
|
FINDBUGS := prebuilt/common/findbugs/bin/findbugs
|
||||||
EMMA_JAR := external/emma/lib/emma$(COMMON_JAVA_PACKAGE_SUFFIX)
|
EMMA_JAR := external/emma/lib/emma$(COMMON_JAVA_PACKAGE_SUFFIX)
|
||||||
|
|
||||||
|
# Tool to merge AndroidManifest.xmls
|
||||||
|
ANDROID_MANIFEST_MERGER := java -classpath prebuilts/devtools/tools/lib/manifest-merger.jar com.android.manifmerger.Main merge
|
||||||
|
|
||||||
YACC_HEADER_SUFFIX:= .hpp
|
YACC_HEADER_SUFFIX:= .hpp
|
||||||
|
|
||||||
# Don't use column under Windows, cygwin or not
|
# Don't use column under Windows, cygwin or not
|
||||||
|
|
|
@ -58,16 +58,6 @@ $(error $(LOCAL_PATH): Package modules may not define LOCAL_MODULE)
|
||||||
endif
|
endif
|
||||||
LOCAL_MODULE := $(LOCAL_PACKAGE_NAME)
|
LOCAL_MODULE := $(LOCAL_PACKAGE_NAME)
|
||||||
|
|
||||||
ifeq ($(strip $(LOCAL_MANIFEST_FILE)),)
|
|
||||||
LOCAL_MANIFEST_FILE := AndroidManifest.xml
|
|
||||||
endif
|
|
||||||
|
|
||||||
# If you need to put the MANIFEST_FILE outside of LOCAL_PATH
|
|
||||||
# you can use FULL_MANIFEST_FILE
|
|
||||||
ifeq ($(strip $(LOCAL_FULL_MANIFEST_FILE)),)
|
|
||||||
LOCAL_FULL_MANIFEST_FILE := $(LOCAL_PATH)/$(LOCAL_MANIFEST_FILE)
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifneq ($(strip $(LOCAL_MODULE_CLASS)),)
|
ifneq ($(strip $(LOCAL_MODULE_CLASS)),)
|
||||||
$(error $(LOCAL_PATH): Package modules may not set LOCAL_MODULE_CLASS)
|
$(error $(LOCAL_PATH): Package modules may not set LOCAL_MODULE_CLASS)
|
||||||
endif
|
endif
|
||||||
|
@ -197,7 +187,8 @@ ifeq ($(LOCAL_SDK_RES_VERSION),)
|
||||||
LOCAL_SDK_RES_VERSION:=$(LOCAL_SDK_VERSION)
|
LOCAL_SDK_RES_VERSION:=$(LOCAL_SDK_VERSION)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
full_android_manifest := $(LOCAL_FULL_MANIFEST_FILE)
|
include $(BUILD_SYSTEM)/android_manifest.mk
|
||||||
|
|
||||||
$(LOCAL_INTERMEDIATE_TARGETS): \
|
$(LOCAL_INTERMEDIATE_TARGETS): \
|
||||||
PRIVATE_ANDROID_MANIFEST := $(full_android_manifest)
|
PRIVATE_ANDROID_MANIFEST := $(full_android_manifest)
|
||||||
ifneq (,$(filter-out current, $(LOCAL_SDK_VERSION)))
|
ifneq (,$(filter-out current, $(LOCAL_SDK_VERSION)))
|
||||||
|
|
|
@ -66,14 +66,7 @@ include $(BUILD_SYSTEM)/java_library.mk
|
||||||
ifneq (,$(all_resources))
|
ifneq (,$(all_resources))
|
||||||
R_file_stamp := $(LOCAL_INTERMEDIATE_SOURCE_DIR)/R.stamp
|
R_file_stamp := $(LOCAL_INTERMEDIATE_SOURCE_DIR)/R.stamp
|
||||||
|
|
||||||
ifeq ($(strip $(LOCAL_MANIFEST_FILE)),)
|
include $(BUILD_SYSTEM)/android_manifest.mk
|
||||||
LOCAL_MANIFEST_FILE := AndroidManifest.xml
|
|
||||||
endif
|
|
||||||
ifdef LOCAL_FULL_MANIFEST_FILE
|
|
||||||
full_android_manifest := $(LOCAL_FULL_MANIFEST_FILE)
|
|
||||||
else
|
|
||||||
full_android_manifest := $(LOCAL_PATH)/$(LOCAL_MANIFEST_FILE)
|
|
||||||
endif
|
|
||||||
|
|
||||||
LOCAL_SDK_RES_VERSION:=$(strip $(LOCAL_SDK_RES_VERSION))
|
LOCAL_SDK_RES_VERSION:=$(strip $(LOCAL_SDK_RES_VERSION))
|
||||||
ifeq ($(LOCAL_SDK_RES_VERSION),)
|
ifeq ($(LOCAL_SDK_RES_VERSION),)
|
||||||
|
|
Loading…
Reference in New Issue