diff options
author | 2025-01-15 00:27:02 +0000 | |
---|---|---|
committer | 2025-01-15 20:54:38 +0000 | |
commit | 2da9d9abca8e1a355f8b9fcbb3ae550bfb40a8b6 (patch) | |
tree | 4f1bb3e56679ae539a4afbac1143281a39804c34 /android/module.go | |
parent | c41eae5e45123a48fd3ec9a3723fdf7adbb6f148 (diff) |
Convert dex2oatPathFromDep to use ModuleProxy.
Bug: 377723687
Test: Unit tests and compare the ninja and mk files generated.
Change-Id: I99ffe88179991da8e5963605bf76666c8945d290
Diffstat (limited to 'android/module.go')
-rw-r--r-- | android/module.go | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/android/module.go b/android/module.go index c88d04556..b9489b482 100644 --- a/android/module.go +++ b/android/module.go @@ -1891,15 +1891,16 @@ var CommonModuleInfoKey = blueprint.NewProvider[CommonModuleInfo]() type PrebuiltModuleInfo struct { SourceExists bool + UsePrebuilt bool } var PrebuiltModuleInfoProvider = blueprint.NewProvider[PrebuiltModuleInfo]() -type HostToolProviderData struct { +type HostToolProviderInfo struct { HostToolPath OptionalPath } -var HostToolProviderKey = blueprint.NewProvider[HostToolProviderData]() +var HostToolProviderInfoProvider = blueprint.NewProvider[HostToolProviderInfo]() type SourceFileGenerator interface { GeneratedSourceFiles() Paths @@ -2212,10 +2213,11 @@ func (m *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext) if p, ok := m.module.(PrebuiltInterface); ok && p.Prebuilt() != nil { SetProvider(ctx, PrebuiltModuleInfoProvider, PrebuiltModuleInfo{ SourceExists: p.Prebuilt().SourceExists(), + UsePrebuilt: p.Prebuilt().UsePrebuilt(), }) } if h, ok := m.module.(HostToolProvider); ok { - SetProvider(ctx, HostToolProviderKey, HostToolProviderData{ + SetProvider(ctx, HostToolProviderInfoProvider, HostToolProviderInfo{ HostToolPath: h.HostToolPath()}) } |