Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a485d093 authored by Jingwen Chen's avatar Jingwen Chen
Browse files

Delete mixedBuildSupportedCcTest.

We can just rely on the prod/staging allowlists which name the modules directly.

Test: presubmits
Test: m nothing; showcommands adbd_test | grep bazel-out
Fixes: 279004435
Change-Id: I666855d6bbe63c628256c3eebd7ae581c0cbdedb
parent 0933fd59
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -939,6 +939,11 @@ var (

		"libandroidfw_tests", "aapt2_tests", // failing due to data path issues

		// error: overriding commands for target
		// `out/host/linux-x86/nativetest64/gmock_tests/gmock_tests__cc_runner_test',
		// previously defined at out/soong/installs-aosp_arm.mk:64919`
		"gmock_tests",

		// cc_test with unconverted deps, or are device-only (and not verified to pass yet)
		"AMRWBEncTest",
		"AmrnbDecoderTest",     // depends on unconverted modules: libaudioutils, libsndfile
+1 −18
Original line number Diff line number Diff line
@@ -1890,26 +1890,9 @@ func (c *Module) QueueBazelCall(ctx android.BaseModuleContext) {
	c.bazelHandler.QueueBazelCall(ctx, c.getBazelModuleLabel(ctx))
}

var (
	mixedBuildSupportedCcTest = []string{
		"adbd_test",
		"adb_crypto_test",
		"adb_pairing_auth_test",
		"adb_pairing_connection_test",
		"adb_tls_connection_test",
	}
)

// IsMixedBuildSupported returns true if the module should be analyzed by Bazel
// in any of the --bazel-mode(s). This filters at the module level and takes
// precedence over the allowlists in allowlists/allowlists.go.
// in any of the --bazel-mode(s).
func (c *Module) IsMixedBuildSupported(ctx android.BaseModuleContext) bool {
	_, isForTesting := ctx.Config().BazelContext.(android.MockBazelContext)
	if c.testBinary() && !android.InList(c.Name(), mixedBuildSupportedCcTest) && !isForTesting {
		// Per-module rollout of mixed-builds for cc_test modules.
		return false
	}

	// TODO(b/261058727): Remove this (enable mixed builds for modules with UBSan)
	// Currently we can only support ubsan when minimum runtime is used.
	return c.bazelHandler != nil && (!isUbsanEnabled(c) || c.MinimalRuntimeNeeded())