1#################################### 2# ART boot image installation 3# Input variable: 4# my_boot_image_name: the boot image to install 5# 6#################################### 7 8# Install primary arch vdex files into a shared location, and then symlink them to both the primary 9# and secondary arch directories. 10my_vdex_copy_pairs := $(DEXPREOPT_IMAGE_VDEX_BUILT_INSTALLED_$(my_boot_image_name)_$(TARGET_ARCH)) 11my_installed := $(foreach v,$(my_vdex_copy_pairs),$(PRODUCT_OUT)$(call word-colon,2,$(v))) 12$(firstword $(my_installed)): $(wordlist 2,9999,$(my_installed)) 13 14my_built_vdex_dir := $(dir $(call word-colon,1,$(firstword $(my_vdex_copy_pairs)))) 15my_installed_vdex_dir := $(PRODUCT_OUT)$(dir $(call word-colon,2,$(firstword $(my_vdex_copy_pairs)))) 16 17$(my_installed): $(my_installed_vdex_dir)% : $(my_built_vdex_dir)% 18 @echo "Install: $@" 19 @rm -f $@ 20 $(copy-file-to-target) 21 mkdir -p $(dir $@)/$(TARGET_ARCH) 22 ln -sfn ../$(notdir $@) $(dir $@)/$(TARGET_ARCH) 23ifdef TARGET_2ND_ARCH 24 ifneq ($(TARGET_TRANSLATE_2ND_ARCH),true) 25 mkdir -p $(dir $@)/$(TARGET_2ND_ARCH) 26 ln -sfn ../$(notdir $@) $(dir $@)/$(TARGET_2ND_ARCH) 27 endif 28endif 29 30my_dexpreopt_image_extra_deps := $(firstword $(my_installed)) 31 32my_2nd_arch_prefix := 33include $(BUILD_SYSTEM)/dex_preopt_libart_boot.mk 34 35ifdef TARGET_2ND_ARCH 36 ifneq ($(TARGET_TRANSLATE_2ND_ARCH),true) 37 my_2nd_arch_prefix := $(TARGET_2ND_ARCH_VAR_PREFIX) 38 include $(BUILD_SYSTEM)/dex_preopt_libart_boot.mk 39 endif 40endif 41 42my_2nd_arch_prefix := 43 44 45my_vdex_copy_pairs := 46my_installed := 47my_built_vdex_dir := 48my_installed_vdex_dir := 49my_dexpreopt_image_extra_deps := 50