am 00d1d614: am b3e6fa5e: Merge "new LOCAL_DEX_PREOPT option "nostripping"" into ics-mr0
* commit '00d1d614f6e9c29e366b2608cd37814856df5efc': new LOCAL_DEX_PREOPT option "nostripping"
This commit is contained in:
commit
d9ed9eba1b
|
@ -528,7 +528,7 @@ $(LOCAL_INSTALLED_MODULE): $(LOCAL_BUILT_MODULE)
|
|||
$(copy-file-to-target-with-cp)
|
||||
endif
|
||||
|
||||
ifeq ($(LOCAL_DEX_PREOPT),true)
|
||||
ifdef LOCAL_DEX_PREOPT
|
||||
installed_odex := $(basename $(LOCAL_INSTALLED_MODULE)).odex
|
||||
built_odex := $(basename $(LOCAL_BUILT_MODULE)).odex
|
||||
$(installed_odex) : $(built_odex) | $(ACP)
|
||||
|
|
|
@ -109,7 +109,7 @@ LOCAL_RENDERSCRIPT_INCLUDES_OVERRIDE:=
|
|||
LOCAL_RENDERSCRIPT_CC:=
|
||||
LOCAL_RENDERSCRIPT_TARGET_API:=
|
||||
LOCAL_BUILD_HOST_DEX:=
|
||||
LOCAL_DEX_PREOPT:=
|
||||
LOCAL_DEX_PREOPT:= # '',true,false,nostripping
|
||||
LOCAL_PROTOC_OPTIMIZE_TYPE:= # lite(default),micro,full
|
||||
LOCAL_PROTOC_FLAGS:=
|
||||
LOCAL_NO_CRT:=
|
||||
|
|
|
@ -29,13 +29,18 @@ intermediates.COMMON := $(call local-intermediates-dir,COMMON)
|
|||
common_javalib.jar := $(intermediates.COMMON)/$(LOCAL_BUILT_MODULE_STEM)
|
||||
LOCAL_INTERMEDIATE_TARGETS += $(common_javalib.jar)
|
||||
|
||||
ifeq (true,$(WITH_DEXPREOPT))
|
||||
ifneq (true,$(WITH_DEXPREOPT))
|
||||
LOCAL_DEX_PREOPT :=
|
||||
else
|
||||
ifeq (,$(TARGET_BUILD_APPS))
|
||||
ifndef LOCAL_DEX_PREOPT
|
||||
LOCAL_DEX_PREOPT := true
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
ifeq (false,$(LOCAL_DEX_PREOPT))
|
||||
LOCAL_DEX_PREOPT :=
|
||||
endif
|
||||
|
||||
#################################
|
||||
include $(BUILD_SYSTEM)/java.mk
|
||||
|
@ -64,7 +69,7 @@ ifneq ($(extra_jar_args),)
|
|||
$(add-java-resources-to-package)
|
||||
endif
|
||||
|
||||
ifeq ($(LOCAL_DEX_PREOPT),true)
|
||||
ifdef LOCAL_DEX_PREOPT
|
||||
dexpreopt_boot_jar_module := $(filter $(LOCAL_MODULE),$(DEXPREOPT_BOOT_JARS_MODULES))
|
||||
ifneq ($(dexpreopt_boot_jar_module),)
|
||||
# boot jar's rules are defined in dex_preopt.mk
|
||||
|
@ -89,7 +94,9 @@ $(built_odex) : $(common_javalib.jar) | $(DEXPREOPT) $(DEXOPT)
|
|||
|
||||
$(LOCAL_BUILT_MODULE) : $(common_javalib.jar) | $(ACP) $(AAPT)
|
||||
$(call copy-file-to-target)
|
||||
ifneq (nostripping,$(LOCAL_DEX_PREOPT))
|
||||
$(call dexpreopt-remove-classes.dex,$@)
|
||||
endif
|
||||
|
||||
endif # dexpreopt_boot_jar_module
|
||||
|
||||
|
|
|
@ -147,7 +147,9 @@ endif # all_resources
|
|||
endif # !custom
|
||||
LOCAL_PROGUARD_FLAGS := $(addprefix -include ,$(proguard_options_file)) $(LOCAL_PROGUARD_FLAGS)
|
||||
|
||||
ifeq (true,$(WITH_DEXPREOPT))
|
||||
ifneq (true,$(WITH_DEXPREOPT))
|
||||
LOCAL_DEX_PREOPT :=
|
||||
else
|
||||
ifeq (,$(TARGET_BUILD_APPS))
|
||||
ifneq (,$(LOCAL_SRC_FILES))
|
||||
ifndef LOCAL_DEX_PREOPT
|
||||
|
@ -156,6 +158,9 @@ endif
|
|||
endif
|
||||
endif
|
||||
endif
|
||||
ifeq (false,$(LOCAL_DEX_PREOPT))
|
||||
LOCAL_DEX_PREOPT :=
|
||||
endif
|
||||
|
||||
#################################
|
||||
include $(BUILD_SYSTEM)/java.mk
|
||||
|
@ -344,7 +349,7 @@ PACKAGES.$(LOCAL_PACKAGE_NAME).CERTIFICATE := $(certificate)
|
|||
|
||||
# Define the rule to build the actual package.
|
||||
$(LOCAL_BUILT_MODULE): $(AAPT) | $(ZIPALIGN)
|
||||
ifeq ($(LOCAL_DEX_PREOPT),true)
|
||||
ifdef LOCAL_DEX_PREOPT
|
||||
# Make sure the boot jars get dexpreopt-ed first
|
||||
$(LOCAL_BUILT_MODULE): $(DEXPREOPT_BOOT_ODEXS) | $(DEXPREOPT) $(DEXOPT)
|
||||
endif
|
||||
|
@ -374,10 +379,12 @@ endif
|
|||
$(sign-package)
|
||||
@# Alignment must happen after all other zip operations.
|
||||
$(align-package)
|
||||
ifeq ($(LOCAL_DEX_PREOPT),true)
|
||||
ifdef LOCAL_DEX_PREOPT
|
||||
$(hide) rm -f $(patsubst %.apk,%.odex,$@)
|
||||
$(call dexpreopt-one-file,$@,$(patsubst %.apk,%.odex,$@))
|
||||
ifneq (nostripping,$(LOCAL_DEX_PREOPT))
|
||||
$(call dexpreopt-remove-classes.dex,$@)
|
||||
endif
|
||||
|
||||
built_odex := $(basename $(LOCAL_BUILT_MODULE)).odex
|
||||
$(built_odex): $(LOCAL_BUILT_MODULE)
|
||||
|
|
Loading…
Reference in New Issue