From c06243d1953c6e62238066c60486db70aa3a3b30 Mon Sep 17 00:00:00 2001 From: Ying Wang Date: Mon, 26 Apr 2010 20:09:56 -0700 Subject: [PATCH] Fix jar dependency on the local manifest file. Change-Id: I1a868885e72c94c4b065723a8d6e890fce5ba1e0 http://b/issue?id=1444634 --- core/base_rules.mk | 4 +++- core/host_java_library.mk | 2 +- core/java.mk | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/core/base_rules.mk b/core/base_rules.mk index f1a2f731fa..c515313128 100644 --- a/core/base_rules.mk +++ b/core/base_rules.mk @@ -384,8 +384,10 @@ ifdef LOCAL_INSTRUMENTATION_FOR full_java_lib_deps += $(link_instr_intermediates_dir.COMMON)/classes-full-names.jar endif +jar_manifest_file := ifneq ($(strip $(LOCAL_JAR_MANIFEST)),) -$(LOCAL_INTERMEDIATE_TARGETS): PRIVATE_JAR_MANIFEST := $(LOCAL_PATH)/$(LOCAL_JAR_MANIFEST) +jar_manifest_file := $(LOCAL_PATH)/$(LOCAL_JAR_MANIFEST) +$(LOCAL_INTERMEDIATE_TARGETS): PRIVATE_JAR_MANIFEST := $(jar_manifest_file) else $(LOCAL_INTERMEDIATE_TARGETS): PRIVATE_JAR_MANIFEST := endif diff --git a/core/host_java_library.mk b/core/host_java_library.mk index 1977115968..3307bf3e00 100644 --- a/core/host_java_library.mk +++ b/core/host_java_library.mk @@ -26,5 +26,5 @@ LOCAL_BUILT_MODULE_STEM := javalib.jar include $(BUILD_SYSTEM)/base_rules.mk $(LOCAL_BUILT_MODULE): PRIVATE_JAVACFLAGS := $(LOCAL_JAVACFLAGS) -$(LOCAL_BUILT_MODULE): $(java_sources) $(java_resource_sources) $(full_java_lib_deps) +$(LOCAL_BUILT_MODULE): $(java_sources) $(java_resource_sources) $(full_java_lib_deps) $(jar_manifest_file) $(transform-host-java-to-package) diff --git a/core/java.mk b/core/java.mk index dd46b5db0e..da53a5c6bf 100644 --- a/core/java.mk +++ b/core/java.mk @@ -172,7 +172,7 @@ ALL_MODULES.$(LOCAL_MODULE).STUBS := $(full_classes_stubs_jar) # Deps for generated source files must be handled separately, # via deps on the target that generates the sources. $(full_classes_compiled_jar): PRIVATE_JAVACFLAGS := $(LOCAL_JAVACFLAGS) -$(full_classes_compiled_jar): $(java_sources) $(full_java_lib_deps) +$(full_classes_compiled_jar): $(java_sources) $(full_java_lib_deps) $(jar_manifest_file) $(transform-java-to-classes.jar) # source files generated from RenderScript must be generated before java compiling