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

Commit f9842b24 authored by Dario Freni's avatar Dario Freni Committed by Automerger Merge Worker
Browse files

Retry: Enable mainline prebuilts on tm-dev branch. am: c7b5e2c0

parents d873f7a1 c7b5e2c0
Loading
Loading
Loading
Loading
+39 −1
Original line number Diff line number Diff line
@@ -39,7 +39,45 @@ $(call add_soong_config_var,ANDROID,PRODUCT_INSTALL_DEBUG_POLICY_TO_SYSTEM_EXT)
# Default behavior for the tree wrt building modules or using prebuilts. This
# can always be overridden by setting the environment variable
# MODULE_BUILD_FROM_SOURCE.
BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := false

ifneq ($(SANITIZE_TARGET)$(EMMA_INSTRUMENT_FRAMEWORK),)
  # Always use sources when building the framework with Java coverage or
  # sanitized builds as they both require purpose built prebuilts which we do
  # not provide.
  BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := true
endif

# TODO(b/172063604): Remove once products no longer use dex2oat(d)s.
# If the product uses dex2oats and/or dex2oatds then build from sources as
# ART does not currently provide prebuilts of those tools.
ifneq (,$(filter dex2oats dex2oatds,$(PRODUCT_HOST_PACKAGES)))
  BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := true
endif

# ART does not provide linux_bionic variants needed for products that
# set HOST_CROSS_OS=linux_bionic.
ifeq (linux_bionic,${HOST_CROSS_OS})
  BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := true
endif

# ART does not provide host side arm64 variants needed for products that
# set HOST_CROSS_ARCH=arm64.
ifeq (arm64,${HOST_CROSS_ARCH})
  BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := true
endif

# TV based devices do not seem to work with prebuilts, so build from source
# for now and fix in a follow up.
ifneq (,$(filter tv,$(subst $(comma),$(space),${PRODUCT_CHARACTERISTICS})))
  BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := true
endif

# ATV based devices do not seem to work with prebuilts, so build from source
# for now and fix in a follow up.
ifneq (,${PRODUCT_IS_ATV})
  BRANCH_DEFAULT_MODULE_BUILD_FROM_SOURCE := true
endif

ifneq (,$(MODULE_BUILD_FROM_SOURCE))
  # Keep an explicit setting.