0

When i am trying to compile my code i am getting this error always
"Conversion to Dalvik format failed: Unable to execute dex: method ID not in [0, 0xffff]: 65536", but i don't know what is this error actually i am not able to generate my APK.

In my project i have used around 4 library project.

  1. Facebook SDK
  2. Google play services
  3. Chat Library
  4. Amazon AWS S3 Bucket jar

So please kindly go through my post and suggest me some valuable suggestion.

1 Answers1

0

In Android Per Application only 65536 references are allowed.

Your are using so many Sdks which increases method references.

In Android Studio You can use individual library from google play service such as

compile 'com.google.android.gms:play-services:7.5.0'

with these lines:

compile 'com.google.android.gms:play-services-maps:7.5.0'
compile 'com.google.android.gms:play-services-ads:7.5.0'
compile 'com.google.android.gms:play-services-analytics:7.5.0'
compile 'com.google.android.gms:play-services-location:7.5.0'

complete list is available here https://developers.google.com/android/guides/setup

Some APIs do not have a separate library; include them by including the base library

Dharmaraj
  • 1,256
  • 13
  • 12