summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xtools/releasetools/ota_from_target_files.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/releasetools/ota_from_target_files.py b/tools/releasetools/ota_from_target_files.py
index c2fbb1d..66db227 100755
--- a/tools/releasetools/ota_from_target_files.py
+++ b/tools/releasetools/ota_from_target_files.py
@@ -1653,11 +1653,6 @@ def main(argv):
common.Usage(__doc__)
sys.exit(1)
- if "ota_override_device" in OPTIONS.info_dict:
- OPTIONS.override_device = OPTIONS.info_dict.get("ota_override_device")
- if "ota_override_prop" in OPTIONS.info_dict:
- OPTIONS.override_prop = OPTIONS.info_dict.get("ota_override_prop") == "true"
-
if OPTIONS.extra_script is not None:
OPTIONS.extra_script = open(OPTIONS.extra_script).read()
@@ -1667,6 +1662,11 @@ def main(argv):
OPTIONS.target_tmp = OPTIONS.input_tmp
OPTIONS.info_dict = common.LoadInfoDict(input_zip)
+ if "ota_override_device" in OPTIONS.info_dict:
+ OPTIONS.override_device = OPTIONS.info_dict.get("ota_override_device")
+ if "ota_override_prop" in OPTIONS.info_dict:
+ OPTIONS.override_prop = OPTIONS.info_dict.get("ota_override_prop") == "true"
+
# If this image was originally labelled with SELinux contexts, make sure we
# also apply the labels in our new image. During building, the "file_contexts"
# is in the out/ directory tree, but for repacking from target-files.zip it's