releasetools: Prefer the avbtool specified in target_files.

This allows a consistent logic in using the avbtool which could be
board-specific.

Test: `atest releasetools_test`
Test: Run sign_target_files_apks.py on a target_files.zip.
Change-Id: I8cd93b8e71146985734f85c31f4662f5e2e9534c
This commit is contained in:
Tao Bao
2019-06-26 11:58:22 -07:00
parent c9c1b864ba
commit 1ac886e181
8 changed files with 51 additions and 28 deletions

View File

@@ -324,7 +324,8 @@ def ValidateVerifiedBootImages(input_tmp, info_dict, options):
# avbtool verifies all the images that have descriptors listed in vbmeta.
image = os.path.join(input_tmp, 'IMAGES', 'vbmeta.img')
cmd = ['avbtool', 'verify_image', '--image', image, '--key', key]
cmd = [info_dict['avb_avbtool'], 'verify_image', '--image', image,
'--key', key]
# Append the args for chained partitions if any.
for partition in common.AVB_PARTITIONS + common.AVB_VBMETA_PARTITIONS: