From e7e3ec80d639c321f075c8fe58f0adad44e230ef Mon Sep 17 00:00:00 2001 From: Jihoon Kang Date: Thu, 2 Jan 2025 21:29:14 +0000 Subject: Specify additional generated partitions for android_device module Defines vendor_boot, init_boot and recovery partition module name properties in android_device. Also, specifies the above properties and boot_partition_name properties in filesystem_creator when generating android_device module. Dependency is now added via `AddFarVariationDependencies`, given that boot images are `MultilibFirst`. This change also improves the comments of the properties of android_device module type. Test: build auto generated android_device module Change-Id: I5426e28aa355efeda5cb5f140dd82db7ed06b84c --- filesystem/android_device.go | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) (limited to 'filesystem/android_device.go') diff --git a/filesystem/android_device.go b/filesystem/android_device.go index ea46556f0..19e93ae8f 100644 --- a/filesystem/android_device.go +++ b/filesystem/android_device.go @@ -22,21 +22,27 @@ import ( ) type PartitionNameProperties struct { - // Name of the Boot_partition_name partition filesystem module + // Name of the boot partition filesystem module Boot_partition_name *string - // Name of the System partition filesystem module + // Name of the vendor boot partition filesystem module + Vendor_boot_partition_name *string + // Name of the init boot partition filesystem module + Init_boot_partition_name *string + // Name of the system partition filesystem module System_partition_name *string - // Name of the System_ext partition filesystem module + // Name of the system_ext partition filesystem module System_ext_partition_name *string - // Name of the Product partition filesystem module + // Name of the product partition filesystem module Product_partition_name *string - // Name of the Vendor partition filesystem module + // Name of the vendor partition filesystem module Vendor_partition_name *string - // Name of the Odm partition filesystem module + // Name of the odm partition filesystem module Odm_partition_name *string + // Name of the recovery partition filesystem module + Recovery_partition_name *string // The vbmeta partition and its "chained" partitions Vbmeta_partitions []string - // Name of the Userdata partition filesystem module + // Name of the userdata partition filesystem module Userdata_partition_name *string } @@ -62,7 +68,7 @@ var filesystemDepTag partitionDepTagType func (a *androidDevice) DepsMutator(ctx android.BottomUpMutatorContext) { addDependencyIfDefined := func(dep *string) { if dep != nil { - ctx.AddDependency(ctx.Module(), filesystemDepTag, proptools.String(dep)) + ctx.AddFarVariationDependencies(nil, filesystemDepTag, proptools.String(dep)) } } -- cgit v1.2.3-59-g8ed1b