From d8ce324e6a98c20dd24ee9a1b7818c36d8abebc0 Mon Sep 17 00:00:00 2001 From: Spandan Das Date: Fri, 10 Jan 2025 00:54:11 +0000 Subject: Add a partial IMAGES/ subdir for target_files.zip With this CL, a handful of .img files will be added to the soong built target_files.zip. Other .img files (like super.img, vbmeta*) and other *map artifacts will be added in followup CLs. Test: Built the soong generated target_files.zip locally Bug: 388635097 Change-Id: Ia60fadb825d872100b49e56e404e22d0b1ece8a5 --- filesystem/android_device.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'filesystem/android_device.go') diff --git a/filesystem/android_device.go b/filesystem/android_device.go index 8e2b9f7ab..e1eb9f55b 100644 --- a/filesystem/android_device.go +++ b/filesystem/android_device.go @@ -186,6 +186,9 @@ func (a *androidDevice) buildTargetFilesZip(ctx android.ModuleContext) { toCopy = append(toCopy, targetFilesZipCopy{a.partitionProps.Recovery_partition_name, "VENDOR_BOOT/RAMDISK"}) } + // Create an IMAGES/ subdirectory + builder.Command().Textf("mkdir -p %s/IMAGES/", targetFilesDir.String()) + for _, zipCopy := range toCopy { if zipCopy.srcModule == nil { continue @@ -206,6 +209,7 @@ func (a *androidDevice) buildTargetFilesZip(ctx android.ModuleContext) { // Create the ROOT partition in target_files.zip builder.Command().Textf("rsync --links --exclude=system/* %s/ -r %s/ROOT", fsInfo.RootDir, targetFilesDir.String()) } + builder.Command().Textf("cp %s %s/IMAGES/", fsInfo.Output, targetFilesDir.String()) } // Copy cmdline, kernel etc. files of boot images if a.partitionProps.Vendor_boot_partition_name != nil { -- cgit v1.2.3-59-g8ed1b