diff options
-rw-r--r-- | android/variable.go | 1 | ||||
-rw-r--r-- | filesystem/android_device.go | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/android/variable.go b/android/variable.go index 419f778a3..aace6ed05 100644 --- a/android/variable.go +++ b/android/variable.go @@ -665,6 +665,7 @@ type PartitionVariables struct { ProductVirtualAbCowVersion string `json:",omitempty"` AbOtaUpdater bool `json:",omitempty"` AbOtaPartitions []string `json:",omitempty"` + AbOtaKeys []string `json:",omitempty"` // Avb (android verified boot) stuff BoardAvbEnable bool `json:",omitempty"` diff --git a/filesystem/android_device.go b/filesystem/android_device.go index d42927a6e..514fd2816 100644 --- a/filesystem/android_device.go +++ b/filesystem/android_device.go @@ -72,6 +72,7 @@ type DeviceProperties struct { Ab_ota_updater *bool Ab_ota_partitions []string + Ab_ota_keys []string } type androidDevice struct { @@ -449,6 +450,10 @@ func (a *androidDevice) copyMetadataToTargetZip(ctx android.ModuleContext, build abPartitionsSorted := android.SortedUniqueStrings(a.deviceProps.Ab_ota_partitions) abPartitionsSortedString := proptools.ShellEscape(strings.Join(abPartitionsSorted, "\\n")) builder.Command().Textf("echo -e").Flag(abPartitionsSortedString).Textf(" > %s/META/ab_partitions.txt", targetFilesDir.String()) + // otakeys.txt + abOtaKeysSorted := android.SortedUniqueStrings(a.deviceProps.Ab_ota_keys) + abOtaKeysSortedString := proptools.ShellEscape(strings.Join(abOtaKeysSorted, "\\n")) + builder.Command().Textf("echo -e").Flag(abOtaKeysSortedString).Textf(" > %s/META/otakeys.txt", targetFilesDir.String()) } } |