I'm trying to test a Android release build to make sure nothing unexpected occurs. While trying to build with ant from the command line:
/usr/local/bin/ant release
...
BUILD FAILED
.../android-sdk/tools/ant/build.xml:653: The following error occurred while executing this line:
.../android-sdk/tools/ant/build.xml:698: null returned: 1
When I look at build.xml:698
, the issue is with the Proguard file below.
<aapt executable="${aapt}"
command="package"
verbose="${verbose}"
manifest="${out.manifest.abs.file}"
originalManifestPackage="${project.app.package}"
androidjar="${project.target.android.jar}"
rfolder="${gen.absolute.dir}"
nonConstantId="${android.library}"
libraryResFolderPathRefid="project.library.res.folder.path"
libraryPackagesRefid="project.library.packages"
libraryRFileRefid="project.library.bin.r.file.path"
ignoreAssets="${aapt.ignore.assets}"
binFolder="${out.absolute.dir}"
proguardFile="${out.absolute.dir}/proguard.txt">
<res path="${out.res.absolute.dir}" />
<res path="${resource.absolute.dir}" />
</aapt>
My project had a proguard-project.txt
. After renaming to proguard.txt
, the problem persists.
I'm happy to omit the Proguard step since I don't use it.
How do I resolve this issue?
In case it matters:
$ /usr/local/bin/ant -v
Apache Ant(TM) version 1.9.4 compiled on April 29 2014
I needed to upgrade ant due to an error, but I don't recall what the error was. I seem to recall it had something to do with Java 7 or Java 8.