Add *_dlkm properties to android.ModuleBase
To aid mk->bp migration of (system|vendor|odm)_dlkm.img files,
https://r.android.com/3331335 introduced properties to prebuilt_etc to
allow installation of soong etc modules in these partitions. The dlkm.img
files package .ko files and build.prop files. The current plan is to use
`prebuilt_kernel_modules` soong module type to package the .ko files and
create additional modules.* metadata files.
To aid this migration, this CL moves the _dlkm_specific properties to
android.ModuleBase and updates `modulePartition` to return the
corresponding dlkm partition.
Bug: 377562851
Test: m nothing --no-skip-soong-tests
Test: m installclean && m fs_config_files_system_dlkm
verified that $PRODUCT_OUT/system_dlkm/etc/fs_config_files exists
Change-Id: Ia398a85a9a2b81532871a5ab88454317039f44b9
diff --git a/android/module_context.go b/android/module_context.go
index 1f5e706..41cb0cc 100644
--- a/android/module_context.go
+++ b/android/module_context.go
@@ -196,6 +196,9 @@
InstallInOdm() bool
InstallInProduct() bool
InstallInVendor() bool
+ InstallInSystemDlkm() bool
+ InstallInVendorDlkm() bool
+ InstallInOdmDlkm() bool
InstallForceOS() (*OsType, *ArchType)
RequiredModuleNames(ctx ConfigurableEvaluatorContext) []string
@@ -493,6 +496,18 @@
return m.module.InstallInVendor()
}
+func (m *moduleContext) InstallInSystemDlkm() bool {
+ return m.module.InstallInSystemDlkm()
+}
+
+func (m *moduleContext) InstallInVendorDlkm() bool {
+ return m.module.InstallInVendorDlkm()
+}
+
+func (m *moduleContext) InstallInOdmDlkm() bool {
+ return m.module.InstallInOdmDlkm()
+}
+
func (m *moduleContext) skipInstall() bool {
if m.module.base().commonProperties.SkipInstall {
return true