Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 19fbc1b9 authored by Colin Cross's avatar Colin Cross
Browse files

Don't install boot.art when WITH_DEXPREOPT is false

Don't create the install rules for boot.art when WITH_DEXPREOPT
is not set to true, which will ensure there is no dependency on
boot.art in a normal build, which matches the behavior before
I25163e91886cea6941afa25cdb529ed053278dcb.

This should fix the Mac build, which never sets WITH_DEXPREOPT
and does not support running dex2oat.

Bug: 119412419
Bug: 121130576
Bug: 121183382
Test: lunch aosp_sailfish-eng && m WITH_DEXPREOPT=false
      files does not depend on out/target/product/sailfish/dex_bootjars/system/framework/arm/boot.art
Change-Id: I39e96b1f35f6808d3007cf1785ec3db89e0decb6
parent 7cac3adf
Loading
Loading
Loading
Loading
+10 −8
Original line number Diff line number Diff line
@@ -83,6 +83,7 @@ ifdef LOCAL_SOONG_DEX_JAR
        $(eval $(call hiddenapi-generate-csv,$(full_classes_jar),$(hiddenapi_flags_csv),$(hiddenapi_metadata_csv)))
        $(eval $(call hiddenapi-copy-soong-jar,$(LOCAL_SOONG_DEX_JAR),$(common_javalib.jar)))

        ifeq (true,$(WITH_DEXPREOPT))
          # For libart, the boot jars' odex files are replaced by $(DEFAULT_DEX_PREOPT_INSTALLED_IMAGE).
          # We use this installed_odex trick to get boot.art installed.
          installed_odex := $(DEFAULT_DEX_PREOPT_INSTALLED_IMAGE)
@@ -91,6 +92,7 @@ ifdef LOCAL_SOONG_DEX_JAR
          ALL_MODULES.$(my_register_name).INSTALLED += $(installed_odex)
          # Make sure to install the .odex and .vdex when you run "make <module_name>"
         $(my_all_targets): $(installed_odex)
        endif
      else # !is_boot_jar
        $(eval $(call copy-one-file,$(LOCAL_SOONG_DEX_JAR),$(common_javalib.jar)))
      endif # is_boot_jar