diff options
-rw-r--r-- | tools/releasetools/edify_generator.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/releasetools/edify_generator.py b/tools/releasetools/edify_generator.py index 61af160..6ebf11d 100644 --- a/tools/releasetools/edify_generator.py +++ b/tools/releasetools/edify_generator.py @@ -168,7 +168,9 @@ class EdifyGenerator(object): self.script.append('package_extract_file("system/bin/otasigcheck.sh", "/tmp/otasigcheck.sh");') self.script.append('package_extract_file("META-INF/org/cyanogenmod/releasekey", "/tmp/releasekey");') self.script.append('set_metadata("/tmp/otasigcheck.sh", "uid", 0, "gid", 0, "mode", 0755);') - self.script.append('run_program("/tmp/otasigcheck.sh") == "0" || abort("Can\'t install this package on top of incompatible data. Please try another package or run a factory reset");') + self.script.append('run_program("/tmp/otasigcheck.sh");') + ## The script changes the key value when it fails, check for "INVALID" + self.script.append('sha1_check(read_file("/tmp/releasekey"),"7241e92725436afc79389d4fc2333a2aa8c20230") && abort("Can\'t install this package on top of incompatible data. Please try another package or run a factory reset");') def ShowProgress(self, frac, dur): """Update the progress bar, advancing it over 'frac' over the next |