From ab5615143d099a3b8960098d7206eef9042a3a42 Mon Sep 17 00:00:00 2001 From: Randall Barker Date: Thu, 29 Nov 2018 14:39:34 -0800 Subject: [PATCH] Fix zipalign APK issue --- tools/taskcluster/sign_apk.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tools/taskcluster/sign_apk.py b/tools/taskcluster/sign_apk.py index c8c888e3f..b0233b3fe 100644 --- a/tools/taskcluster/sign_apk.py +++ b/tools/taskcluster/sign_apk.py @@ -32,14 +32,9 @@ def main(name, argv): build_output_path = './app/build/outputs/apk' - # Run zipalign - for apk in glob.glob(build_output_path + "/*/*/*-unsigned.apk"): - split = os.path.splitext(apk) - print subprocess.check_output(["zipalign", "-f", "-v", "-p", "4", apk, split[0] + "-aligned" + split[1]]) - # Sign APKs for apk in glob.glob(build_output_path + "/*/*/*-aligned.apk"): - target = apk.replace('-unsigned-', '-signed-') + target = apk.replace('-unsigned', '-signed') if not release: target = target.replace('-release-', '-staging-') print "Signing", apk @@ -51,6 +46,11 @@ def main(name, argv): "-H", "Authorization: " + token, sign_url]) + # Run zipalign + for apk in glob.glob(build_output_path + "/*/*/*-signed.apk"): + split = os.path.splitext(apk) + print subprocess.check_output(["zipalign", "-f", "-v", "-p", "4", apk, split[0] + "-aligned" + split[1]]) + # Create folder for saving build artifacts artifacts_path = './builds' if not os.path.exists(artifacts_path):