diff --git a/cmd/soong_ui/main.go b/cmd/soong_ui/main.go index e86246ca8..7a19286c8 100644 --- a/cmd/soong_ui/main.go +++ b/cmd/soong_ui/main.go @@ -119,9 +119,11 @@ func main() { logsDir = filepath.Join(config.DistDir(), "logs") } + buildErrorFile := filepath.Join(logsDir, logsPrefix+"build_error") rbeMetricsFile := filepath.Join(logsDir, logsPrefix+"rbe_metrics.pb") soongMetricsFile := filepath.Join(logsDir, logsPrefix+"soong_metrics") - defer build.UploadMetrics(buildCtx, config, simpleOutput, buildStarted, rbeMetricsFile, soongMetricsFile) + defer build.UploadMetrics(buildCtx, config, simpleOutput, buildStarted, buildErrorFile, rbeMetricsFile, soongMetricsFile) + defer build.PrintGomaDeprecation(buildCtx, config) os.MkdirAll(logsDir, 0777) diff --git a/ui/build/rbe.go b/ui/build/rbe.go index 6a26063b0..67bcebb75 100644 --- a/ui/build/rbe.go +++ b/ui/build/rbe.go @@ -128,3 +128,13 @@ func DumpRBEMetrics(ctx Context, config Config, filename string) { ctx.Fatalf("failed to copy %q to %q: %v\n", metricsFile, filename, err) } } + +// PrintGomaDeprecation prints a PSA on the deprecation of Goma if it is set for the build. +func PrintGomaDeprecation(ctx Context, config Config) { + if config.UseGoma() { + fmt.Fprintln(ctx.Writer, "") + fmt.Fprintln(ctx.Writer, "Goma for Android is being deprecated and replaced with RBE.") + fmt.Fprintln(ctx.Writer, "See go/goma_android_deprecation for more details.") + fmt.Fprintln(ctx.Writer, "") + } +}