diff options
author | Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> | 2017-02-11 22:38:54 +0100 |
---|---|---|
committer | Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> | 2017-02-11 22:38:54 +0100 |
commit | 530288f5a725848bb899636665ea3f14f9398fad (patch) | |
tree | 097879192b3926c5c6503b058d3582d680110bfc /tools/releasetools/ota_from_target_files.py | |
parent | 34b65b9553c9395846ae1bbe186be2667139db79 (diff) | |
parent | fafb7e2a14706f75bd76aca21c1c7d695f938ed3 (diff) | |
download | build-530288f5a725848bb899636665ea3f14f9398fad.zip build-530288f5a725848bb899636665ea3f14f9398fad.tar.gz build-530288f5a725848bb899636665ea3f14f9398fad.tar.bz2 |
Merge branch 'cm-13.0' of https://github.com/LineageOS/android_build into replicant-6.0
Signed-off-by: Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de>
Diffstat (limited to 'tools/releasetools/ota_from_target_files.py')
-rwxr-xr-x | tools/releasetools/ota_from_target_files.py | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/tools/releasetools/ota_from_target_files.py b/tools/releasetools/ota_from_target_files.py index bc40873..66db227 100755 --- a/tools/releasetools/ota_from_target_files.py +++ b/tools/releasetools/ota_from_target_files.py @@ -96,14 +96,6 @@ Usage: ota_from_target_files [flags] input_target_files output_ota_package --backup <boolean> Enable or disable the execution of backuptool.sh. Disabled by default. - - --override_device <device> - Override device-specific asserts. Can be a comma-separated list. - - --override_prop <boolean> - Override build.prop items with custom vendor init. - Enabled when TARGET_UNIFIED_DEVICE is defined in BoardConfig - """ from __future__ import print_function @@ -753,7 +745,7 @@ endif; common.ZipWriteStr(output_zip, "system/build.prop", ""+input_zip.read("SYSTEM/build.prop")) - common.ZipWriteStr(output_zip, "META-INF/org/cyanogenmod/releasekey", + common.ZipWriteStr(output_zip, "META-INF/org/lineageos/releasekey", ""+input_zip.read("META/releasekey.txt")) def WritePolicyConfig(file_name, output_zip): @@ -1629,10 +1621,6 @@ def main(argv): "a float" % (a, o)) elif o in ("--backup",): OPTIONS.backuptool = bool(a.lower() == 'true') - elif o in ("--override_device",): - OPTIONS.override_device = a - elif o in ("--override_prop",): - OPTIONS.override_prop = bool(a.lower() == 'true') else: return False return True @@ -1658,9 +1646,7 @@ def main(argv): "verify", "no_fallback_to_full", "stash_threshold=", - "backup=", - "override_device=", - "override_prop=" + "backup=" ], extra_option_handler=option_handler) if len(args) != 2: @@ -1676,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 |