blob: 6d5fc7906dd25e6842593de6ab0cdbdd18bc065d [file] [log] [blame]
Ying Wange7874c42010-09-17 16:36:06 -07001####################################
Brian Carlstromced4bff2013-11-14 23:44:56 -08002# dexpreopt support - typically used on user builds to run dexopt (for Dalvik) or dex2oat (for ART) ahead of time
Ying Wange7874c42010-09-17 16:36:06 -07003#
4####################################
5
Colin Cross6db5b0e2018-11-16 21:26:33 -08006include $(BUILD_SYSTEM)/dex_preopt_config.mk
Alex Light4e358ab2016-06-16 14:47:10 -07007
Nicolas Geoffraycdd43432017-03-24 14:45:59 +00008# Method returning whether the install path $(1) should be for system_other.
Andreas Gampe4ed21d12017-06-16 10:24:54 -07009# Under SANITIZE_LITE, we do not want system_other. Just put things under /data/asan.
10ifeq ($(SANITIZE_LITE),true)
11install-on-system-other =
12else
Nicolas Geoffray4a0ad4a2017-06-12 15:19:16 +010013install-on-system-other = $(filter-out $(PRODUCT_DEXPREOPT_SPEED_APPS) $(PRODUCT_SYSTEM_SERVER_APPS),$(basename $(notdir $(filter $(foreach f,$(SYSTEM_OTHER_ODEX_FILTER),$(TARGET_OUT)/$(f)),$(1)))))
Andreas Gampe4ed21d12017-06-16 10:24:54 -070014endif
Nicolas Geoffraycdd43432017-03-24 14:45:59 +000015
Brian Carlstromced4bff2013-11-14 23:44:56 -080016include $(BUILD_SYSTEM)/dex_preopt_libart.mk
17
Calin Juravle8955a992018-05-10 11:33:27 -070018ifeq ($(PRODUCT_DIST_BOOT_AND_SYSTEM_JARS),true)
19boot_profile_jars_zip := $(PRODUCT_OUT)/boot_profile_jars.zip
20all_boot_jars := \
Calin Juravle9e1fb1b2019-01-29 16:43:21 -080021 $(DEXPREOPT_BOOTCLASSPATH_DEX_FILES) \
Calin Juravle8955a992018-05-10 11:33:27 -070022 $(foreach m,$(PRODUCT_SYSTEM_SERVER_JARS),$(PRODUCT_OUT)/system/framework/$(m).jar)
23
24$(boot_profile_jars_zip): PRIVATE_JARS := $(all_boot_jars)
25$(boot_profile_jars_zip): $(all_boot_jars) $(SOONG_ZIP)
26 echo "Create boot profiles package: $@"
27 rm -f $@
Colin Cross1a81e372018-10-01 10:30:04 -070028 $(SOONG_ZIP) -o $@ -C $(PRODUCT_OUT) $(addprefix -f ,$(PRIVATE_JARS))
Calin Juravle8955a992018-05-10 11:33:27 -070029
30droidcore: $(boot_profile_jars_zip)
31
32$(call dist-for-goals, droidcore, $(boot_profile_jars_zip))
33endif