I got an error in the build server when sending an Android build during the dex phase.
Googling a bit I learned that there is a hard limit of 64K functions (including all libs, the heaviest is google play services), or you can use the multiple dex mechanism.
How do I activate this for Codename One?
I understand Codename One uses Ant and as far as I understand this only works for gradle.
FYI this is the workaround, that splits google play services into sub libraries with native android:
http://android-developers.blogspot.com.es/2014/12/google-play-services-and-dex-method.html
I had a very similar issue and corresponded with Codename One's pro support on this. Gradle support was something they just recently announced so its not as documented but should be available in the next update.
You need to add the following build hints to your project:
android.gradle=true
android.multidex=true
I understand that gradle will be the default build once 3.3 rolls around so in the future only the multidex option will be needed.
You don't have to add Google Play Service Library in your codenameone app, just add android.includeGPlayServices=true
to your build hint and it would be included in build server.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With