Various cleanup in soong_ui to aid new feature
- Rename the "BuildX" variables to "RunX"
- Remove redundant comments
- Inline all the "what to do" based on config in build.go
- Inline some constants only used in one place
Bug: 189187214
Test: m nothing
Test: build/soong/build_test.bash
Change-Id: I111a69e642212d7938d4971283545e0d9acbb01a
Merged-In: I111a69e642212d7938d4971283545e0d9acbb01a
(cherry picked from commit d274ea9196
)
This commit is contained in:
@@ -460,19 +460,21 @@ func buildProduct(mpctx *mpContext, product string) {
|
||||
}
|
||||
}()
|
||||
|
||||
buildWhat := build.BuildProductConfig
|
||||
config.SetSkipNinja(true)
|
||||
|
||||
buildWhat := build.RunProductConfig
|
||||
if !*onlyConfig {
|
||||
buildWhat |= build.BuildSoong
|
||||
buildWhat |= build.RunSoong
|
||||
if !*onlySoong {
|
||||
buildWhat |= build.BuildKati
|
||||
buildWhat |= build.RunKati
|
||||
}
|
||||
}
|
||||
|
||||
before := time.Now()
|
||||
build.Build(ctx, config, buildWhat)
|
||||
build.Build(ctx, config)
|
||||
|
||||
// Save std_full.log if Kati re-read the makefiles
|
||||
if buildWhat&build.BuildKati != 0 {
|
||||
if buildWhat&build.RunKati != 0 {
|
||||
if after, err := os.Stat(config.KatiBuildNinjaFile()); err == nil && after.ModTime().After(before) {
|
||||
err := copyFile(stdLog, filepath.Join(filepath.Dir(stdLog), "std_full.log"))
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user