am e05628cc: fix signing user builds

Merge commit 'e05628cc8df4ec4b69befa9652d81eb81f0ab008' into eclair

* commit 'e05628cc8df4ec4b69befa9652d81eb81f0ab008':
  fix signing user builds
This commit is contained in:
Doug Zongker
2009-08-20 18:18:29 -07:00
committed by Android Git Automerger
2 changed files with 8 additions and 3 deletions

View File

@@ -145,7 +145,7 @@ def UnzipTemp(filename):
tmp = tempfile.mkdtemp(prefix="targetfiles-")
OPTIONS.tempfiles.append(tmp)
p = Run(["unzip", "-q", filename, "-d", tmp], stdout=subprocess.PIPE)
p = Run(["unzip", "-o", "-q", filename, "-d", tmp], stdout=subprocess.PIPE)
p.communicate()
if p.returncode != 0:
raise ExternalError("failed to unzip input target-files \"%s\"" %

View File

@@ -268,8 +268,13 @@ def ReplaceOtaKeys(input_tf_zip, output_tf_zip):
k = m.group(1)
mapped_keys.append(OPTIONS.key_map.get(k, k) + ".x509.pem")
print "using:\n ", "\n ".join(mapped_keys)
print "for OTA package verification"
if mapped_keys:
print "using:\n ", "\n ".join(mapped_keys)
print "for OTA package verification"
else:
mapped_keys.append(
OPTIONS.key_map["build/target/product/security/testkey"] + ".x509.pem")
print "META/otakeys.txt has no keys; using", mapped_keys[0]
# recovery uses a version of the key that has been slightly
# predigested (by DumpPublicKey.java) and put in res/keys.