KeytoolException, PackagerException, SigningException {
checkNotNull(androidResPkgLocation, "androidResPkgLocation cannot be null.");
checkNotNull(classesDexLocation, "classesDexLocation cannot be null.");
checkNotNull(outApkLocation, "outApkLocation cannot be null.");
CertificateInfo certificateInfo = null;
if (signingConfig != null && signingConfig.isSigningReady()) {
certificateInfo = KeystoreHelper.getCertificateInfo(signingConfig);
if (certificateInfo == null) {
throw new SigningException("Failed to read key from keystore");
}