API flagging macro until/starting_at for private and public
- Applies the starting_at_board_api macro also to private types
- Add a macro complementary to the starting_at_board_api macro to write rules if
the the board api level is lower than the specified api
(Re-land of aosp/3229062 without proc_compaction_proactiveness.
Cause: b/363981334)
Bug: 356832676
Bug: 358516352
Change-Id: I923d26ac581da3b947f8e8dde0db993e3bb637ba
diff --git a/build/soong/policy.go b/build/soong/policy.go
index 4476f94..29685ea 100644
--- a/build/soong/policy.go
+++ b/build/soong/policy.go
@@ -225,17 +225,7 @@
}
func (c *policyConf) boardApiLevel(ctx android.ModuleContext) string {
- level := proptools.StringDefault(c.properties.Board_api_level, "system")
-
- if level == "system" {
- // aribtrary value greater than any other vendor API levels
- return "1000000"
- } else if level == "vendor" {
- return ctx.Config().VendorApiLevel()
- } else {
- return level
- }
-
+ return ctx.Config().VendorApiLevel()
}
func findPolicyConfOrder(name string) int {