Merge "Fix prebuilt boot image hermetic build" into main am: 5f4a51ef66
Original change: https://android-review.googlesource.com/c/platform/build/+/2813275 Change-Id: I6a4f9567d37089af660d49b2c5b24a148a89fb6e Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -1908,8 +1908,11 @@ def _SignBootableImage(image_path, prebuilt_name, partition_name,
|
|||||||
for filename in ["kernel", "ramdisk", "vendor_ramdisk00"]:
|
for filename in ["kernel", "ramdisk", "vendor_ramdisk00"]:
|
||||||
path = os.path.join(tmpdir, filename)
|
path = os.path.join(tmpdir, filename)
|
||||||
if os.path.exists(path) and os.path.getsize(path):
|
if os.path.exists(path) and os.path.getsize(path):
|
||||||
|
print("Using {} as salt for avb footer of {}".format(
|
||||||
|
filename, partition_name))
|
||||||
with open(path, "rb") as fp:
|
with open(path, "rb") as fp:
|
||||||
salt = sha256(fp.read()).hexdigest()
|
salt = sha256(fp.read()).hexdigest()
|
||||||
|
break
|
||||||
AppendAVBSigningArgs(cmd, partition_name, salt)
|
AppendAVBSigningArgs(cmd, partition_name, salt)
|
||||||
args = info_dict.get("avb_" + partition_name + "_add_hash_footer_args")
|
args = info_dict.get("avb_" + partition_name + "_add_hash_footer_args")
|
||||||
if args and args.strip():
|
if args and args.strip():
|
||||||
|
Reference in New Issue
Block a user