Define UseBazel in Config am: 0c1c456643
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1496658 Change-Id: I713abab31350b3f81a5787bc875fd7943f8e1510
This commit is contained in:
commit
5439d1cf68
2 changed files with 12 additions and 4 deletions
|
@ -471,11 +471,9 @@ func make(ctx build.Context, config build.Config, _ []string, logsDir string) {
|
|||
ctx.Fatal("done")
|
||||
}
|
||||
|
||||
var toBuild int
|
||||
if _, ok := config.Environment().Get("USE_BAZEL"); ok {
|
||||
toBuild := build.BuildAll
|
||||
if config.UseBazel() {
|
||||
toBuild = build.BuildAllWithBazel
|
||||
} else {
|
||||
toBuild = build.BuildAll
|
||||
}
|
||||
|
||||
if config.Checkbuild() {
|
||||
|
|
|
@ -840,6 +840,16 @@ func (c *configImpl) UseRBE() bool {
|
|||
return false
|
||||
}
|
||||
|
||||
func (c *configImpl) UseBazel() bool {
|
||||
if v, ok := c.environ.Get("USE_BAZEL"); ok {
|
||||
v = strings.TrimSpace(v)
|
||||
if v != "" && v != "false" {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (c *configImpl) StartRBE() bool {
|
||||
if !c.UseRBE() {
|
||||
return false
|
||||
|
|
Loading…
Reference in a new issue