Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 687da3b0 authored by Tao Bao's avatar Tao Bao
Browse files

releasetools: Fix the path to the OTA keys in recovery image.

The recovery image will be packed under BOOT/RAMDISK only if
system_root_image and recovery_as_boot both are true (e.g. non-A/B
devices launched since P).

Bug: 113191245
Test: Run sign_target_files_apks.py on a target_files file that uses
      system-as-root but not recovery-as-boot.
Change-Id: I262a268055c6b5078d21694b5094a1c393d0d37c
parent 22f28aa1
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -597,8 +597,8 @@ def ReplaceOtaKeys(input_tf_zip, output_tf_zip, misc_info):
  if p.returncode != 0:
    raise common.ExternalError("failed to run dumpkeys")

  # system_root_image puts the recovery keys at BOOT/RAMDISK.
  if misc_info.get("system_root_image") == "true":
  if (misc_info.get("system_root_image") == "true" and
      misc_info.get("recovery_as_boot") == "true"):
    recovery_keys_location = "BOOT/RAMDISK/res/keys"
  else:
    recovery_keys_location = "RECOVERY/RAMDISK/res/keys"