i wanna ask about : how to zipalign apk app without eclipse or coding because i have an apk file i make with non eclipse ..but when i upload to google play it say : You uploaded an APK that is not zip aligned. You will need to run a zip align tool on your APK and upload it again. i try some apps to zipalign the apk without coding but it doesn't work for me...
Asked
Active
Viewed 1,568 times
-3
-
1Possible duplicate of [How to zip Align APK file in android?](http://stackoverflow.com/questions/23333724/how-to-zip-align-apk-file-in-android) – FlyingPumba Feb 25 '16 at 18:53
-
But this for eclipse I need a way without coding – muha1999a Feb 26 '16 at 03:27
-
You don't have to code. You need to use the `zipalign` tool provided in the Android SDK. – FlyingPumba Feb 26 '16 at 13:34
-
where can i find it please help still new to java – muha1999a Feb 27 '16 at 06:44
1 Answers
1
I'm assuming you are working on a Linux based environment, like Ubuntu.
You can find the zipaling
tool in the path android-sdk/build-tools/{higher version you can find}/zipalign
, where android-sdk
is the folder where you have the Android SDK. For example: android-sdk/build-tools/23.0.2/zipalign
And then, to use it:
android-sdk/build-tools/23.0.2/zipalign 4 infile.apk outfile.apk
Where infile.apk
is your unaligned apk file, and outfile.apk
is the aligned output of the tool

FlyingPumba
- 1,015
- 2
- 15
- 37
-
FATAL: [SignApksBuilder] zipalign failed: exit code 1 ERROR: zipalign failed on APK /var/lib/jenkins/workspace/PP_androidBuild/PatientPortal/platforms/android/build/outputs/apk/android-debug.apk: exit code 1 Finished: FAILURE – Ashish Karpe Sep 08 '17 at 14:08
-
manually its working but failing under jenkins builds as shown above – Ashish Karpe Sep 08 '17 at 14:10
-
jenkins@ip-172-31-22-20:~$ /opt/android-sdk-linux/build-tools/23.0.1/zipalign -f -p 4 /var/lib/jenkins/workspace/PP_androidBuild/PatientPortal/platforms/android/build/outputs/apk/android-debug.apk /var/lib/jenkins/workspace/PP_androidBuild/SignApksBuilder-out/zipalign/aligned-android-debug-6100835664895780913.apk – Ashish Karpe Sep 08 '17 at 14:11
-
jenkins@ip-172-31-22-20:~$ ls -lthr /var/lib/jenkins/workspace/PP_androidBuild/SignApksBuilder-out/zipalign/aligned-android-debug-6100835664895780913.apk -rw-r--r-- 1 jenkins jenkins 5.9M Sep 8 14:09 /var/lib/jenkins/workspace/PP_androidBuild/SignApksBuilder-out/zipalign/aligned-android-debug-6100835664895780913.apk – Ashish Karpe Sep 08 '17 at 14:11