From 972e06c41f822750b8b8b62dfced90313f0eb6d4 Mon Sep 17 00:00:00 2001 From: Jiyong Park Date: Mon, 15 Mar 2021 23:32:49 +0900 Subject: Add vbmeta module type The module type is to create vbmeta image out of other partitions. Bug: 180676957 Test: m microdroid_vbmeta microdroid_vbmeta_system Inspect the built image using `avbtool info_image --image ` Change-Id: Iac92e9ab1640dcd488af69842e09850a91262bf1 --- filesystem/filesystem.go | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'filesystem/filesystem.go') diff --git a/filesystem/filesystem.go b/filesystem/filesystem.go index 7f36308df..8974eba4f 100644 --- a/filesystem/filesystem.go +++ b/filesystem/filesystem.go @@ -385,6 +385,10 @@ func (f *filesystem) OutputFiles(tag string) (android.Paths, error) { type Filesystem interface { android.Module OutputPath() android.Path + + // Returns the output file that is signed by avbtool. If this module is not signed, returns + // nil. + SignedOutputPath() android.Path } var _ Filesystem = (*filesystem)(nil) @@ -392,3 +396,10 @@ var _ Filesystem = (*filesystem)(nil) func (f *filesystem) OutputPath() android.Path { return f.output } + +func (f *filesystem) SignedOutputPath() android.Path { + if proptools.Bool(f.properties.Use_avb) { + return f.OutputPath() + } + return nil +} -- cgit v1.2.3-59-g8ed1b