Merge "Build with OpenJDK 9 -target 1.8 by default (attempt 3)."
This commit is contained in:
committed by
Android (Google) Code Review
commit
ac1e12846c
@@ -299,7 +299,10 @@ func NewConfig(srcDir, buildDir string) (Config, error) {
|
||||
func (c *config) fromEnv() error {
|
||||
switch c.Getenv("EXPERIMENTAL_USE_OPENJDK9") {
|
||||
case "":
|
||||
// Use OpenJDK8
|
||||
if c.Getenv("RUN_ERROR_PRONE") != "true" {
|
||||
// Use OpenJDK9, but target 1.8
|
||||
c.useOpenJDK9 = true
|
||||
}
|
||||
case "false":
|
||||
// Use OpenJDK8
|
||||
case "1.8":
|
||||
@@ -310,7 +313,7 @@ func (c *config) fromEnv() error {
|
||||
c.useOpenJDK9 = true
|
||||
c.targetOpenJDK9 = true
|
||||
default:
|
||||
return fmt.Errorf(`Invalid value for EXPERIMENTAL_USE_OPENJDK9, should be "", "1.8", or "true"`)
|
||||
return fmt.Errorf(`Invalid value for EXPERIMENTAL_USE_OPENJDK9, should be "", "false", "1.8", or "true"`)
|
||||
}
|
||||
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user