Loading tools/releasetools/edify_generator.py +11 −5 Original line number Diff line number Diff line Loading @@ -83,6 +83,12 @@ class EdifyGenerator(object): raise ValueError("must specify an OEM property") if not value: raise ValueError("must specify the OEM value") if common.OPTIONS.oem_no_mount: cmd = ('getprop("{name}") == "{value}" || ' 'abort("This package expects the value \\"{value}\\" for ' '\\"{name}\\"; this has value \\"" + ' 'getprop("{name}") + "\\".");').format(name=name, value=value) else: cmd = ('file_getprop("/oem/oem.prop", "{name}") == "{value}" || ' 'abort("This package expects the value \\"{value}\\" for ' '\\"{name}\\" on the OEM partition; this has value \\"" + ' Loading tools/releasetools/ota_from_target_files.py +16 −3 Original line number Diff line number Diff line Loading @@ -54,6 +54,12 @@ Usage: ota_from_target_files [flags] input_target_files output_ota_package Use the file to specify the expected OEM-specific properties on the OEM partition of the intended device. --oem_no_mount For devices with OEM-specific properties but without an OEM partition, do not mount the OEM partition in the updater-script. This should be very rarely used, since it's expected to have a dedicated OEM partition for OEM-specific properties. Only meaningful when -o is specified. -w (--wipe_user_data) Generate an OTA package that will wipe the user data partition when installed. Loading Loading @@ -144,6 +150,7 @@ OPTIONS.no_signing = False OPTIONS.block_based = False OPTIONS.updater_binary = None OPTIONS.oem_source = None OPTIONS.oem_no_mount = False OPTIONS.fallback_to_full = True OPTIONS.full_radio = False OPTIONS.full_bootloader = False Loading Loading @@ -526,6 +533,7 @@ def WriteFullOTAPackage(input_zip, output_zip): if oem_props is not None and len(oem_props) > 0: if OPTIONS.oem_source is None: raise common.ExternalError("OEM source required for this build") if not OPTIONS.oem_no_mount: script.Mount("/oem", recovery_mount_options) oem_dict = common.LoadDictionaryFromLines( open(OPTIONS.oem_source).readlines()) Loading Loading @@ -777,6 +785,7 @@ def WriteBlockIncrementalOTAPackage(target_zip, source_zip, output_zip): if oem_props is not None and len(oem_props) > 0: if OPTIONS.oem_source is None: raise common.ExternalError("OEM source required for this build") if not OPTIONS.oem_no_mount: script.Mount("/oem", recovery_mount_options) oem_dict = common.LoadDictionaryFromLines( open(OPTIONS.oem_source).readlines()) Loading Loading @@ -1062,6 +1071,7 @@ def WriteVerifyPackage(input_zip, output_zip): if oem_props is not None and len(oem_props) > 0: if OPTIONS.oem_source is None: raise common.ExternalError("OEM source required for this build") if not OPTIONS.oem_no_mount: script.Mount("/oem", recovery_mount_options) oem_dict = common.LoadDictionaryFromLines( open(OPTIONS.oem_source).readlines()) Loading Loading @@ -1821,6 +1831,8 @@ def main(argv): OPTIONS.wipe_user_data = True elif o in ("-o", "--oem_settings"): OPTIONS.oem_source = a elif o == "--oem_no_mount": OPTIONS.oem_no_mount = True elif o in ("-e", "--extra_script"): OPTIONS.extra_script = a elif o in ("-a", "--aslr_mode"): Loading Loading @@ -1879,6 +1891,7 @@ def main(argv): "block", "binary=", "oem_settings=", "oem_no_mount", "verify", "no_fallback_to_full", "stash_threshold=", Loading Loading
tools/releasetools/edify_generator.py +11 −5 Original line number Diff line number Diff line Loading @@ -83,6 +83,12 @@ class EdifyGenerator(object): raise ValueError("must specify an OEM property") if not value: raise ValueError("must specify the OEM value") if common.OPTIONS.oem_no_mount: cmd = ('getprop("{name}") == "{value}" || ' 'abort("This package expects the value \\"{value}\\" for ' '\\"{name}\\"; this has value \\"" + ' 'getprop("{name}") + "\\".");').format(name=name, value=value) else: cmd = ('file_getprop("/oem/oem.prop", "{name}") == "{value}" || ' 'abort("This package expects the value \\"{value}\\" for ' '\\"{name}\\" on the OEM partition; this has value \\"" + ' Loading
tools/releasetools/ota_from_target_files.py +16 −3 Original line number Diff line number Diff line Loading @@ -54,6 +54,12 @@ Usage: ota_from_target_files [flags] input_target_files output_ota_package Use the file to specify the expected OEM-specific properties on the OEM partition of the intended device. --oem_no_mount For devices with OEM-specific properties but without an OEM partition, do not mount the OEM partition in the updater-script. This should be very rarely used, since it's expected to have a dedicated OEM partition for OEM-specific properties. Only meaningful when -o is specified. -w (--wipe_user_data) Generate an OTA package that will wipe the user data partition when installed. Loading Loading @@ -144,6 +150,7 @@ OPTIONS.no_signing = False OPTIONS.block_based = False OPTIONS.updater_binary = None OPTIONS.oem_source = None OPTIONS.oem_no_mount = False OPTIONS.fallback_to_full = True OPTIONS.full_radio = False OPTIONS.full_bootloader = False Loading Loading @@ -526,6 +533,7 @@ def WriteFullOTAPackage(input_zip, output_zip): if oem_props is not None and len(oem_props) > 0: if OPTIONS.oem_source is None: raise common.ExternalError("OEM source required for this build") if not OPTIONS.oem_no_mount: script.Mount("/oem", recovery_mount_options) oem_dict = common.LoadDictionaryFromLines( open(OPTIONS.oem_source).readlines()) Loading Loading @@ -777,6 +785,7 @@ def WriteBlockIncrementalOTAPackage(target_zip, source_zip, output_zip): if oem_props is not None and len(oem_props) > 0: if OPTIONS.oem_source is None: raise common.ExternalError("OEM source required for this build") if not OPTIONS.oem_no_mount: script.Mount("/oem", recovery_mount_options) oem_dict = common.LoadDictionaryFromLines( open(OPTIONS.oem_source).readlines()) Loading Loading @@ -1062,6 +1071,7 @@ def WriteVerifyPackage(input_zip, output_zip): if oem_props is not None and len(oem_props) > 0: if OPTIONS.oem_source is None: raise common.ExternalError("OEM source required for this build") if not OPTIONS.oem_no_mount: script.Mount("/oem", recovery_mount_options) oem_dict = common.LoadDictionaryFromLines( open(OPTIONS.oem_source).readlines()) Loading Loading @@ -1821,6 +1831,8 @@ def main(argv): OPTIONS.wipe_user_data = True elif o in ("-o", "--oem_settings"): OPTIONS.oem_source = a elif o == "--oem_no_mount": OPTIONS.oem_no_mount = True elif o in ("-e", "--extra_script"): OPTIONS.extra_script = a elif o in ("-a", "--aslr_mode"): Loading Loading @@ -1879,6 +1891,7 @@ def main(argv): "block", "binary=", "oem_settings=", "oem_no_mount", "verify", "no_fallback_to_full", "stash_threshold=", Loading