From e51ff957ad1fb2ecc03d82e293069c764c014c3c Mon Sep 17 00:00:00 2001 From: Spandan Das Date: Thu, 9 Jan 2025 18:11:59 +0000 Subject: Add android-info.txt to OTA/ subdir of target_files.zip This information will be provided by an explicit `Android_info` property on `andorid_device`. An alternative would be to propagate this information from vendor_partition dependency, but that might run into issues if android_info.txt is no longer used a prop file input for building vendor's build.prop file Test: diff'd target_files.zip of make and soong Fixes: 388633397 Change-Id: Iaacffd0526b6ce7a7ce1566774753d4e20d9f9a2 --- filesystem/android_device.go | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'filesystem/android_device.go') diff --git a/filesystem/android_device.go b/filesystem/android_device.go index 4b615bc51..406f47cbe 100644 --- a/filesystem/android_device.go +++ b/filesystem/android_device.go @@ -57,6 +57,8 @@ type PartitionNameProperties struct { type DeviceProperties struct { // Path to the prebuilt bootloader that would be copied to PRODUCT_OUT Bootloader *string `android:"path"` + // Path to android-info.txt file containing board specific info. + Android_info *string `android:"path"` } type androidDevice struct { @@ -231,6 +233,11 @@ func (a *androidDevice) buildTargetFilesZip(ctx android.ModuleContext) { } } + if a.deviceProps.Android_info != nil { + builder.Command().Textf("mkdir -p %s/OTA", targetFilesDir) + builder.Command().Textf("cp %s %s/OTA/android-info.txt", android.PathForModuleSrc(ctx, proptools.String(a.deviceProps.Android_info)), targetFilesDir) + } + builder.Command(). BuiltTool("soong_zip"). Text("-d"). -- cgit v1.2.3-59-g8ed1b