Remove configurable values from providers
Providers are data exported from one module to another.
Configurable properties are the collection of all possible values of a
property, to be resolved under the module's configuration.
If you export a configurable from one module to another and then resolve
it there, it will be evaluated with the wrong configuration.
Bug: 394967253
Test: m nothing
Change-Id: I934b08538bcc3267b3ec44925591f16a1c59292c
diff --git a/cc/cmake_snapshot.go b/cc/cmake_snapshot.go
index 71fbcce..3f6a01d 100644
--- a/cc/cmake_snapshot.go
+++ b/cc/cmake_snapshot.go
@@ -204,24 +204,19 @@
return info.CompilerInfo.AidlInterfaceInfo
},
"getCflagsProperty": func(ctx android.ModuleContext, info *CcInfo) []string {
- prop := info.CompilerInfo.Cflags
- return prop.GetOrDefault(ctx, nil)
+ return info.CompilerInfo.Cflags
},
"getWholeStaticLibsProperty": func(ctx android.ModuleContext, info *CcInfo) []string {
- prop := info.LinkerInfo.WholeStaticLibs
- return prop.GetOrDefault(ctx, nil)
+ return info.LinkerInfo.WholeStaticLibs
},
"getStaticLibsProperty": func(ctx android.ModuleContext, info *CcInfo) []string {
- prop := info.LinkerInfo.StaticLibs
- return prop.GetOrDefault(ctx, nil)
+ return info.LinkerInfo.StaticLibs
},
"getSharedLibsProperty": func(ctx android.ModuleContext, info *CcInfo) []string {
- prop := info.LinkerInfo.SharedLibs
- return prop.GetOrDefault(ctx, nil)
+ return info.LinkerInfo.SharedLibs
},
"getHeaderLibsProperty": func(ctx android.ModuleContext, info *CcInfo) []string {
- prop := info.LinkerInfo.HeaderLibs
- return prop.GetOrDefault(ctx, nil)
+ return info.LinkerInfo.HeaderLibs
},
"getExtraLibs": getExtraLibs,
"getIncludeDirs": getIncludeDirs,
@@ -552,7 +547,7 @@
func getIncludeDirs(ctx android.ModuleContext, m android.ModuleProxy, info *CcInfo) []string {
moduleDir := ctx.OtherModuleDir(m) + string(filepath.Separator)
if info.CompilerInfo.LibraryDecoratorInfo != nil {
- return sliceWithPrefix(moduleDir, info.CompilerInfo.LibraryDecoratorInfo.ExportIncludeDirs.GetOrDefault(ctx, nil))
+ return sliceWithPrefix(moduleDir, info.CompilerInfo.LibraryDecoratorInfo.ExportIncludeDirs)
}
return nil
}