summaryrefslogtreecommitdiff
path: root/android/module.go
diff options
context:
space:
mode:
author Yu Liu <yudiliu@google.com> 2025-02-12 18:27:03 +0000
committer Yu Liu <yudiliu@google.com> 2025-02-13 19:43:22 +0000
commitdf0b83966161d767714909dff032648c0d83d4c8 (patch)
tree8fbc01fd9a303604a99c73bd2a1f2a878e3f3088 /android/module.go
parentcbf8ee89a8d292ec0b4ba5052bd58c13289abb4f (diff)
Convert CheckMinSdkVersion to use providers.
Next step is to convert it to use ModuleProxy once IsDepInSameApex is converted to use providers. Bug: 377723687 Test: Unit tests and compare the ninja and mk files generated. Change-Id: I20cb052666fa95eb964e63e3302ac892d3324183
Diffstat (limited to 'android/module.go')
-rw-r--r--android/module.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/android/module.go b/android/module.go
index 55dd119e0..0ffb6cb53 100644
--- a/android/module.go
+++ b/android/module.go
@@ -1912,6 +1912,8 @@ type CommonModuleInfo struct {
SkipInstall bool
IsStubsModule bool
Host bool
+ MinSdkVersionSupported ApiLevel
+ ModuleWithMinSdkVersionCheck bool
}
type ApiLevelOrPlatform struct {
@@ -2292,7 +2294,13 @@ func (m *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext)
commonData.CanHaveApexVariants = am.CanHaveApexVariants()
commonData.NotAvailableForPlatform = am.NotAvailableForPlatform()
commonData.NotInPlatform = am.NotInPlatform()
+ commonData.MinSdkVersionSupported = am.MinSdkVersionSupported(ctx)
}
+
+ if _, ok := m.module.(ModuleWithMinSdkVersionCheck); ok {
+ commonData.ModuleWithMinSdkVersionCheck = true
+ }
+
if st, ok := m.module.(StubsAvailableModule); ok {
commonData.IsStubsModule = st.IsStubsModule()
}