Loading tests/bootstrap_test.sh +0 −1 Original line number Diff line number Diff line Loading @@ -547,7 +547,6 @@ function test_bp2build_smoke { function test_bp2build_generates_marker_file { setup create_mock_bazel run_soong bp2build Loading tests/bp2build_bazel_test.sh +0 −4 Original line number Diff line number Diff line Loading @@ -50,7 +50,6 @@ test_bp2build_null_build_with_globs function test_different_relative_outdir { setup create_mock_bazel mkdir -p a touch a/g.txt Loading @@ -73,7 +72,6 @@ test_different_relative_outdir function test_different_absolute_outdir { setup create_mock_bazel mkdir -p a touch a/g.txt Loading @@ -96,7 +94,6 @@ test_different_absolute_outdir function test_bp2build_generates_all_buildfiles { setup create_mock_bazel mkdir -p foo/convertible_soong_module cat > foo/convertible_soong_module/Android.bp <<'EOF' Loading Loading @@ -167,7 +164,6 @@ eval ${_save_trap} function test_cc_correctness { setup create_mock_bazel mkdir -p a cat > a/Android.bp <<EOF Loading tests/lib.sh +1 −1 Original line number Diff line number Diff line Loading @@ -82,10 +82,10 @@ function symlink_directory { } function create_mock_soong { create_mock_bazel copy_directory build/blueprint copy_directory build/soong copy_directory build/make/tools/rbcrun copy_directory prebuilts/bazel/common/proto symlink_directory prebuilts/sdk symlink_directory prebuilts/go Loading tests/mixed_mode_test.sh +2 −4 Original line number Diff line number Diff line Loading @@ -12,7 +12,6 @@ source "$(dirname "$0")/lib.sh" function test_bazel_smoke { setup create_mock_bazel run_soong bp2build Loading @@ -21,7 +20,6 @@ function test_bazel_smoke { function test_add_irrelevant_file { setup create_mock_bazel mkdir -p soong_tests/a/b touch soong_tests/a/b/c.txt Loading @@ -33,7 +31,7 @@ filegroup { } EOF run_soong --bazel-mode nothing run_soong --bazel-mode-staging nothing if [[ ! -e out/soong/bp2build/soong_tests/a/b/BUILD.bazel ]]; then fail "BUILD.bazel not created" Loading @@ -48,7 +46,7 @@ EOF touch soong_tests/a/irrelevant.txt run_soong --bazel-mode nothing run_soong --bazel-mode-staging nothing local mtime_build2=$(stat -c "%y" out/soong/bp2build/soong_tests/a/b/BUILD.bazel) local mtime_ninja2=$(stat -c "%y" out/soong/build.ninja) Loading ui/build/config.go +18 −0 Original line number Diff line number Diff line Loading @@ -236,6 +236,21 @@ func loadEnvConfig(ctx Context, config *configImpl) error { return nil } func defaultBazelProdMode(cfg *configImpl) bool { // Envirnoment flag to disable Bazel for users which experience // broken bazel-handled builds, or significant performance regressions. if cfg.IsBazelMixedBuildForceDisabled() { return false } // Darwin-host builds are currently untested with Bazel. if runtime.GOOS == "darwin" { return false } // TODO(b/255364055): Flip this to true to enable bazel-mode by default // for all users that don't opt out with BUILD_BROKEN_DISABLE_BAZEL. return false } func NewConfig(ctx Context, args ...string) Config { ret := &configImpl{ environ: OsEnvironment(), Loading Loading @@ -774,6 +789,9 @@ func (c *configImpl) parseArgs(ctx Context, args []string) { c.arguments = append(c.arguments, arg) } } if (!c.bazelProdMode) && (!c.bazelDevMode) && (!c.bazelStagingMode) { c.bazelProdMode = defaultBazelProdMode(c) } } func (c *configImpl) configureLocale(ctx Context) { Loading Loading
tests/bootstrap_test.sh +0 −1 Original line number Diff line number Diff line Loading @@ -547,7 +547,6 @@ function test_bp2build_smoke { function test_bp2build_generates_marker_file { setup create_mock_bazel run_soong bp2build Loading
tests/bp2build_bazel_test.sh +0 −4 Original line number Diff line number Diff line Loading @@ -50,7 +50,6 @@ test_bp2build_null_build_with_globs function test_different_relative_outdir { setup create_mock_bazel mkdir -p a touch a/g.txt Loading @@ -73,7 +72,6 @@ test_different_relative_outdir function test_different_absolute_outdir { setup create_mock_bazel mkdir -p a touch a/g.txt Loading @@ -96,7 +94,6 @@ test_different_absolute_outdir function test_bp2build_generates_all_buildfiles { setup create_mock_bazel mkdir -p foo/convertible_soong_module cat > foo/convertible_soong_module/Android.bp <<'EOF' Loading Loading @@ -167,7 +164,6 @@ eval ${_save_trap} function test_cc_correctness { setup create_mock_bazel mkdir -p a cat > a/Android.bp <<EOF Loading
tests/lib.sh +1 −1 Original line number Diff line number Diff line Loading @@ -82,10 +82,10 @@ function symlink_directory { } function create_mock_soong { create_mock_bazel copy_directory build/blueprint copy_directory build/soong copy_directory build/make/tools/rbcrun copy_directory prebuilts/bazel/common/proto symlink_directory prebuilts/sdk symlink_directory prebuilts/go Loading
tests/mixed_mode_test.sh +2 −4 Original line number Diff line number Diff line Loading @@ -12,7 +12,6 @@ source "$(dirname "$0")/lib.sh" function test_bazel_smoke { setup create_mock_bazel run_soong bp2build Loading @@ -21,7 +20,6 @@ function test_bazel_smoke { function test_add_irrelevant_file { setup create_mock_bazel mkdir -p soong_tests/a/b touch soong_tests/a/b/c.txt Loading @@ -33,7 +31,7 @@ filegroup { } EOF run_soong --bazel-mode nothing run_soong --bazel-mode-staging nothing if [[ ! -e out/soong/bp2build/soong_tests/a/b/BUILD.bazel ]]; then fail "BUILD.bazel not created" Loading @@ -48,7 +46,7 @@ EOF touch soong_tests/a/irrelevant.txt run_soong --bazel-mode nothing run_soong --bazel-mode-staging nothing local mtime_build2=$(stat -c "%y" out/soong/bp2build/soong_tests/a/b/BUILD.bazel) local mtime_ninja2=$(stat -c "%y" out/soong/build.ninja) Loading
ui/build/config.go +18 −0 Original line number Diff line number Diff line Loading @@ -236,6 +236,21 @@ func loadEnvConfig(ctx Context, config *configImpl) error { return nil } func defaultBazelProdMode(cfg *configImpl) bool { // Envirnoment flag to disable Bazel for users which experience // broken bazel-handled builds, or significant performance regressions. if cfg.IsBazelMixedBuildForceDisabled() { return false } // Darwin-host builds are currently untested with Bazel. if runtime.GOOS == "darwin" { return false } // TODO(b/255364055): Flip this to true to enable bazel-mode by default // for all users that don't opt out with BUILD_BROKEN_DISABLE_BAZEL. return false } func NewConfig(ctx Context, args ...string) Config { ret := &configImpl{ environ: OsEnvironment(), Loading Loading @@ -774,6 +789,9 @@ func (c *configImpl) parseArgs(ctx Context, args []string) { c.arguments = append(c.arguments, arg) } } if (!c.bazelProdMode) && (!c.bazelDevMode) && (!c.bazelStagingMode) { c.bazelProdMode = defaultBazelProdMode(c) } } func (c *configImpl) configureLocale(ctx Context) { Loading