From 8d32be55a6bb06f8447bd35a04562bea01405024 Mon Sep 17 00:00:00 2001 From: Danny Lin Date: Sat, 13 Nov 2021 18:46:43 -0800 Subject: [PATCH] make: Add support for vintf manifest files --- src/build/make.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/build/make.ts b/src/build/make.ts index 90a47ea..8db558e 100644 --- a/src/build/make.ts +++ b/src/build/make.ts @@ -13,6 +13,13 @@ const SEPOLICY_PARTITION_VARS: { [part: string]: string } = { odm: 'BOARD_ODM_SEPOLICY_DIRS', } +const VINTF_MANIFEST_PARTITION_VARS: { [part: string]: string } = { + system_ext: 'SYSTEM_EXT_MANIFEST_FILES', + product: 'PRODUCT_MANIFEST_FILES', + vendor: 'DEVICE_MANIFEST_FILE', // no 'S' + odm: 'ODM_MANIFEST_FILES', +} + export interface Symlink { moduleName: string linkPartition: string @@ -41,6 +48,8 @@ export interface ProductMakefile { copyFiles?: Array packages?: Array + vintfManifestPaths?: Map + props?: PartitionProps fingerprint?: string } @@ -162,6 +171,12 @@ export function serializeProductMakefile(mk: ProductMakefile) { addContBlock(blocks, 'PRODUCT_COPY_FILES', mk.copyFiles) addContBlock(blocks, 'PRODUCT_PACKAGES', mk.packages) + if (mk.vintfManifestPaths != undefined) { + for (let [partition, manifestPath] of mk.vintfManifestPaths.entries()) { + blocks.push(`${VINTF_MANIFEST_PARTITION_VARS[partition]} += ${manifestPath}`) + } + } + if (mk.props != undefined) { for (let [partition, props] of mk.props.entries()) { if (props.size == 0) {