From 05597c0cc44964f11c8e711d2d03b8dea221b7b9 Mon Sep 17 00:00:00 2001 From: Jeff Sharkey Date: Tue, 1 Jun 2021 12:12:31 -0600 Subject: [PATCH] Hacky workaround for half-finalized builds. Metalava increments the SDK level by one when it's not "REL", so we temporarily force the build to be "REL" while we're still in the process of finalizing it. This CL must be reverted as part of actually declaring "REL". Bug: 171506470 Test: Build Change-Id: I95ee4879268eab3e28a653ca8c169bf6a83e2a19 --- java/droidstubs.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/java/droidstubs.go b/java/droidstubs.go index 2154ec943..7bfdc55dd 100644 --- a/java/droidstubs.go +++ b/java/droidstubs.go @@ -363,7 +363,8 @@ func (d *Droidstubs) apiLevelsAnnotationsFlags(ctx android.ModuleContext, cmd *a cmd.FlagWithOutput("--generate-api-levels ", d.apiVersionsXml) cmd.FlagWithInput("--apply-api-levels ", d.apiVersionsXml) cmd.FlagWithArg("--current-version ", ctx.Config().PlatformSdkVersion().String()) - cmd.FlagWithArg("--current-codename ", ctx.Config().PlatformSdkCodename()) + // STOPSHIP: RESTORE THIS LOGIC WHEN DECLARING "REL" BUILD + // cmd.FlagWithArg("--current-codename ", ctx.Config().PlatformSdkCodename()) filename := proptools.StringDefault(d.properties.Api_levels_jar_filename, "android.jar")