fix apksig.jar version and groupId Taken from android_plugin_for_gradle.gradle. Google doesn't seem to bump this version, it can be checked against their binaries using: . for f in $ANDROID_SDK_ROOT/build-tools/*/apksigner; do printf "%s " $(basename $(dirname $f)) $f version done . While we are at it, remove jcenter as a source, since Debian packages cannot use anything from there.
hard-code apksigner.jar path This script tries to find where the JAR is. It is unnecessary in Debian since this package always installs it in the exact same path.
remove Conscrypt Conscrypt is Android's TLS stack. It is not packaged for Debian and is only needed for a specific feature that is rarely used. Someone is welcome to package Conscrypt to get this working.
remove protobuf dependency Removed protobuf dependency version since Debian's version is higher than the version listed as a dependency here. Protobuf is only needed to make v4 signatures. Anyone is welcome to get this working. APK v4 Signatures are really only relevant to Google Play. F-Droid does not use them at all.