uber-apk-signer icon indicating copy to clipboard operation
uber-apk-signer copied to clipboard

External zipalign conflicts W/ embedded zipalign | 64bit + 32bit Linux

Open Morsmalleo opened this issue 9 months ago • 3 comments

G'day @patrickfav, sorry to bother you mate, but I've been coming across this issue for a while now, and I've only just managed to figure why the problem was arising today.

a problem I've noticed is that when the user installs zipalign from the Command Line using package management tools such as apt or pacman, the external zipalign package in the users PATH, and the embed zipalign version that comes with Uber APK Signer, seems to conflict with each other, resulting in the error below

Error: Command failed: java -jar "/home/kali/AhMyth/AhMyth-Server/app/app/Factory/sign.jar" -a "/home/kali/AhMyth/Output/Ahmyth.apk"
Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true
could not execute zipalign
Run with '--debug' parameter to get additional information.

removing the zipalign package installed from the Command Line allows the signer to run it's embedded version of zipalign which fixes the problem, However if a path to a zipalign executable is not explicitly specified, then it should use the package version installed via the Command Line if it's available (which it should since it's automatically added to the users PATH variable at installation time), otherwise it should fall back to the embedded version if the PATH check for zipalign returns null according to the screenshot below (correct me if I'm wrong).

However both the external zipalign package and the embedded zipalign conflict with each other regardless of the external version being declared in the PATH variable

IMG_20230909_155257

The Uber APK Signer version I'm utilising is v1.2.1

Edit

Just tested the same scenario with a 32bit Kali Linux VM and the same problem happened for some reason, external zipalign conflicts with embedded zipalign unless external package is removed.

Morsmalleo avatar Sep 09 '23 09:09 Morsmalleo