diff options
| author | 2024-11-20 18:34:16 +0000 | |
|---|---|---|
| committer | 2024-12-02 18:25:20 +0000 | |
| commit | 71be42d93951aaaf95ba520281a9837f32bd738c (patch) | |
| tree | db0e8e09776e00dfd1d18ef4c57ce6a688ed31cb /fsgen/filesystem_creator.go | |
| parent | f0eabbf94ffa8acf87e88822ec85c162f33b973e (diff) | |
Automatically add system and system_ext autogen RRO to vendor/product
This CL creates a dependency edge from vendor/product to system and
system_ext. A post deps mutator will walk the transitive closure and add
the corresponding autogenerated RROs to deps.
Bug: 374371755
Bug: 375277835
Test: m soong_generated_vendor_filesystem_test
NOTICE is the last diff
Change-Id: Iffe64174a0d639dc224505a08eccd0a1dedc9f39
Diffstat (limited to 'fsgen/filesystem_creator.go')
| -rw-r--r-- | fsgen/filesystem_creator.go | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/fsgen/filesystem_creator.go b/fsgen/filesystem_creator.go index 8325b1ed5..46e93235a 100644 --- a/fsgen/filesystem_creator.go +++ b/fsgen/filesystem_creator.go @@ -205,7 +205,7 @@ func (f *filesystemCreator) createDeviceModule( ctx.CreateModule(filesystem.AndroidDeviceFactory, baseProps, partitionProps) } -func partitionSpecificFsProps(fsProps *filesystem.FilesystemProperties, partitionVars android.PartitionVariables, partitionType string) { +func partitionSpecificFsProps(ctx android.EarlyModuleContext, fsProps *filesystem.FilesystemProperties, partitionVars android.PartitionVariables, partitionType string) { switch partitionType { case "system": fsProps.Build_logtags = proptools.BoolPtr(true) @@ -356,6 +356,10 @@ func partitionSpecificFsProps(fsProps *filesystem.FilesystemProperties, partitio fsProps.Fsverity.Libs = []string{":framework-res{.export-package.apk}"} case "product": fsProps.Gen_aconfig_flags_pb = proptools.BoolPtr(true) + fsProps.Android_filesystem_deps.System = proptools.StringPtr(generatedModuleNameForPartition(ctx.Config(), "system")) + if ctx.DeviceConfig().SystemExtPath() == "system_ext" { + fsProps.Android_filesystem_deps.System_ext = proptools.StringPtr(generatedModuleNameForPartition(ctx.Config(), "system_ext")) + } case "vendor": fsProps.Gen_aconfig_flags_pb = proptools.BoolPtr(true) fsProps.Symlinks = []filesystem.SymlinkDefinition{ @@ -368,6 +372,10 @@ func partitionSpecificFsProps(fsProps *filesystem.FilesystemProperties, partitio Name: proptools.StringPtr("vendor/lib/modules"), }, } + fsProps.Android_filesystem_deps.System = proptools.StringPtr(generatedModuleNameForPartition(ctx.Config(), "system")) + if ctx.DeviceConfig().SystemExtPath() == "system_ext" { + fsProps.Android_filesystem_deps.System_ext = proptools.StringPtr(generatedModuleNameForPartition(ctx.Config(), "system_ext")) + } case "odm": fsProps.Symlinks = []filesystem.SymlinkDefinition{ filesystem.SymlinkDefinition{ @@ -711,7 +719,7 @@ func generateFsProps(ctx android.EarlyModuleContext, partitionType string) (*fil fsProps.Is_auto_generated = proptools.BoolPtr(true) - partitionSpecificFsProps(fsProps, partitionVars, partitionType) + partitionSpecificFsProps(ctx, fsProps, partitionVars, partitionType) // system_image properties that are not set: // - filesystemProperties.Avb_hash_algorithm |