forked from openkylin/platform_build
Merge "Upgrade to ManifestMerger2"
This commit is contained in:
commit
4971146b2b
|
@ -34,10 +34,12 @@ ifdef my_full_libs_manifest_files
|
|||
main_android_manifest := $(full_android_manifest)
|
||||
full_android_manifest := $(intermediates.COMMON)/AndroidManifest.xml
|
||||
$(full_android_manifest): PRIVATE_LIBS_MANIFESTS := $(my_full_libs_manifest_files)
|
||||
$(full_android_manifest): $(ANDROID_MANIFEST_MERGER_CLASSPATH)
|
||||
$(full_android_manifest) : $(main_android_manifest) $(my_full_libs_manifest_deps)
|
||||
@echo "Merge android manifest files: $@ <-- $< $(PRIVATE_LIBS_MANIFESTS)"
|
||||
@mkdir -p $(dir $@)
|
||||
$(hide) $(ANDROID_MANIFEST_MERGER) --main $< --libs $(PRIVATE_LIBS_MANIFESTS) \
|
||||
$(hide) $(ANDROID_MANIFEST_MERGER) --main $< \
|
||||
--libs $(call normalize-path-list,$(PRIVATE_LIBS_MANIFESTS)) \
|
||||
--out $@
|
||||
|
||||
endif
|
||||
|
|
|
@ -675,7 +675,14 @@ FINDBUGS := $(FINDBUGS_DIR)/findbugs
|
|||
JACOCO_CLI_JAR := $(HOST_OUT_JAVA_LIBRARIES)/jacoco-cli$(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
|
||||
ANDROID_MANIFEST_MERGER_CLASSPATH := \
|
||||
prebuilts/gradle-plugin/com/android/tools/build/manifest-merger/25.3.1/manifest-merger-25.3.1.jar \
|
||||
prebuilts/gradle-plugin/com/android/tools/sdk-common/25.3.1/sdk-common-25.3.1.jar \
|
||||
prebuilts/gradle-plugin/com/android/tools/common/25.3.1/common-25.3.1.jar \
|
||||
prebuilts/misc/common/guava/guava-18.0.jar
|
||||
ANDROID_MANIFEST_MERGER := $(JAVA) \
|
||||
-classpath $(subst $(space),:,$(strip $(ANDROID_MANIFEST_MERGER_CLASSPATH))) \
|
||||
com.android.manifmerger.Merger
|
||||
|
||||
COLUMN:= column
|
||||
|
||||
|
|
Loading…
Reference in New Issue