Friday, March 04, 2011

Android Ant Build Problem WIth Proguard and Latest SDK

Just like many Android developers, I had a working Ant build that included obfuscation using Proguard. When I upgraded to the latest SDK and tools (to include Android 2.3 and higher) my Ant build no longer worked. Instead I got this error:
add-proguard-release.xml:37: Expecting class path separator ':' before '{' in argument number 1
After adding a few echo Ant tasks before the offending error, I found that the value for external.libs.dir was not being set so it was still ${external.libs.dir} when used as part of another path (a classpath actually). My project didn't need any external libs so I simply commented it out of the add-proguard.release-xml. I hope this helps other Android developers!

0 Comments:

Post a Comment

<< Home