Not sure if you're asking for help on building with ant, but... I have an ANT build script which references external jar files (Flurry and my own external jar) and uses proguard for obfuscation, plus deals with incompatibilities between the Sun JDK and java generics.
I'll agree it IS a real pain to get working, but having an ANT script is ultimately a better solution IMO. If you look at the default build script you should see a comment like this: "This is macro that enable passing variable list of external jar files to ApkBuilder... Example of use:" Just look for the "extra-jars" tag. In my build script it looks like this: <extra-jars> <jarfile path="libs/FlurryAgent.jar" /> <jarfile path="libs/ro-core.jar" /> </extra-jars> ro-core.jar is my own jar while FlurryAgent.jar is well.. Flurry. If your eclipse project is referencing other eclipse projects, then just create a small ANT script to build jar files for these other projects. If your other projects are actually Android Library projects, then I think you may have some problems as I don't believe the ANT approach will work with Library Projects. Some useful references: http://developer.android.com/guide/developing/other-ide.html http://www.androidengineer.com/2010/07/optimizing-obfuscating-and-shrinking.html And with proguard just make sure you add the relevant "-keep" statements to the config. I found I had to explicitly reference inner classes, particularly for Resources but this is probably just my knowledge of Proguard which is lacking. So my proguard config has things like: -keep public class com.carboncrystal.ro.R$drawable {<fields>;} -keep public class com.carboncrystal.ro.R$layout {<fields>;} I'm sure there's probably a way to auto-include inner classes in a proguard "keep" declaration, but I couldn't find it. Also if you are using any native code (which I am) that calls back to java (which I do), then you need to make sure you "keep" any Java class/method/field names which are called from native code otherwise all your JNI bindings will barf. Like I said, it's a pain to setup but once it's working I think it's much better. On Sep 23, 2:28 am, Craigo <craig...@gmail.com> wrote: > Please update the Eclipse "Export Android Application" feature to take > the location of Proguard and do the obfuscated build. > > The instructions > postedhttp://android-developers.blogspot.com/2010/09/proguard-android-and-l... > only work if your application is very basic (mine didn't work as it > references other projects in the build path). > > Thanks! :-) -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en