summaryrefslogtreecommitdiff
path: root/android/config.go
diff options
context:
space:
mode:
author Colin Cross <ccross@android.com> 2025-02-24 12:33:45 -0800
committer Colin Cross <ccross@android.com> 2025-02-24 13:34:18 -0800
commit589f22dd2f23a19862b49dc04a30aa7f4cc1e77d (patch)
tree4c97ea8abad4bd60a11dde24256f9088b057b4b4 /android/config.go
parent71b7fee478fa2ab3af8cf438b269eea8ae3df82c (diff)
Return false from UseDebugArt when using prebuilt art apex
UseDebugArt is returning true even when the prebuilt art apex is selected, causing duplicate rules to copy service-art.jar to out/soong/system_server_dexjars/service-art.jar. Force UseDebugArt to return false when RELEASE_APEX_CONTRIBUTIONS_ART is enabled. Bug: 398836954 Test: manual Change-Id: Ifd94db5e93b60a64ce589372ff7ccc3ec6b53e53
Diffstat (limited to 'android/config.go')
-rw-r--r--android/config.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/android/config.go b/android/config.go
index f6d08b841..a5edf0da8 100644
--- a/android/config.go
+++ b/android/config.go
@@ -2275,10 +2275,18 @@ func (c *config) OemProperties() []string {
}
func (c *config) UseDebugArt() bool {
+ // If the ArtTargetIncludeDebugBuild product variable is set then return its value.
if c.productVariables.ArtTargetIncludeDebugBuild != nil {
return Bool(c.productVariables.ArtTargetIncludeDebugBuild)
}
+ // If the RELEASE_APEX_CONTRIBUTIONS_ART build flag is set to use a prebuilt ART apex
+ // then don't use the debug apex.
+ if val, ok := c.GetBuildFlag("RELEASE_APEX_CONTRIBUTIONS_ART"); ok && val != "" {
+ return false
+ }
+
+ // Default to the debug apex for eng builds.
return Bool(c.productVariables.Eng)
}