Questions tagged [android-multidex]

Multidex is an Android technology that splits the classes of an Application (and its dependencies) into multiple dex files. (Dex being the format of the classes for the Dalvik/ART VM). Multidex is a workaround the 65 k maximal methods count inside a dex file.

Multidex is an Android technology that splits the classes of an Application (and its dependencies) into multiple dex files. (Dex being the format of the classes for the Dalvik/ART VM). Multidex is a workaround the 65k maximal methods count inside a dex file.

Package Summary

Features

Note that multidex is built-in in Art (Android SDK 5, Lollipop) and is also part of the support libraries

720 questions
6
votes
7 answers

Android Studio: Why am i getting multi dex error on brand new Google Maps API project?

I'm relatively new to Android programming and I am trying to create a Google Maps project. I used the template option in Android Studio, and I added the key for the API. I haven't added any of my own code and left the template code as is because I…
shong
  • 121
  • 1
  • 9
6
votes
1 answer

Using MultiDexApplication causes applicationContext to become null

I have switched my application to a MultiDexApplication by following the instructions in this link - https://developer.android.com/studio/build/multidex.html. The application now installs correctly, BUT my application context is null. Have any of…
Lunchbox
  • 1,538
  • 2
  • 16
  • 42
6
votes
1 answer

VM with version 1.6.0 does not have multidex support : Unable to find application Mono.Android.Platform.ApiLevel_23 or Xamarin.Android.Platform

I had created a small app. When I try running the app on genymotion emulator it gives a Pop-up "Unfortunately My App has stopped" Application Output : Forwarding debugger port 8834 Detecting existing process [MultiDex] VM with version 1.6.0 does…
Yksh
  • 3,276
  • 10
  • 56
  • 101
6
votes
2 answers

What is the good strategy when dealing with Proguard, MultiDex, Testing and Product Flavors?

I have an app that reference ~ 100K methods, with min Sdk = 16 Here is 2 option for assembling: Proguard shrink this bunch of methods to only 44K methods Use Multi Dex Now I have some common use cases: Run and debug on emulator and devices It…
Anthony
  • 3,989
  • 2
  • 30
  • 52
6
votes
2 answers

How to find out how many methods are added with a library in Android Studio/Gradle

What is the easiest way to find out how many methods do we add to our method count when we add a new library as a dependency in Android Studio project's gradle file, for example: compile 'com.github.jkwiecien:EasyImage:1.2.1'
Kaloyan Roussev
  • 14,515
  • 21
  • 98
  • 180
6
votes
2 answers

java.lang.NoClassDefFoundError: com.google.android.gms.common.internal.zzd

Using Maps api v2 and it works perfectly with 4.4 , 5.0, 5.1, 5.1.1 , 6 but app crashes when I try 4.2.2. I've been doing lots of research but nothing seems to work. Here's the complete log. FATAL EXCEPTION: main …
6
votes
2 answers

Shrink Debug Multi Dex Component; Cannot Read dir/allclasses.jar

I am developing an application which enabling Multidex in order to avoid 65k limit. I want to add an external library in Jar type (i.e. iPay Jar SDK). I've Synchronized the Gradle and succeed but I failed to run the project. The error message shown…
Izzuddiin
  • 265
  • 2
  • 12
6
votes
2 answers

java.lang.LinkageError: MainActivity

I use productFlavours in my app. I'm also using multi dex. defaultConfig { multiDexEnabled true minSdkVersion 17 targetSdkVersion 22 ... } productFlavors { prodFlavor1{...} prodFlavor2{...} …
AlexAndro
  • 1,918
  • 2
  • 27
  • 53
6
votes
1 answer

Error: Execution failed for task ':app:shrinkReleaseMultiDexComponents'

I'm trying to generate an APK for publication in Google store, but I get the following error: Error:Execution failed for task ':app:shrinkReleaseMultiDexComponents'. java.io.IOException: The output…
viana
  • 495
  • 4
  • 18
  • 42
6
votes
3 answers

Instrumentation test fail randomly with multidexing enabled

In my android app I have multidexing enabled. The app runs fine on emulators. I am using robotium for testing the app. But when I execute instrumentation test cases, sometimes the test passes, but mostly they also fail after system reboot. There is…
6
votes
1 answer

VerifyError in multidex app when injecting dependency with Dagger

A sample app for library has ~67k methods. It has multidex enabled to overcome the 65k method limit. Unfortunately with multidex enabled the app crashes on VerifyError when trying to inject EndpointAdapter in main activity. This issue doesn't occur…
tomrozb
  • 25,773
  • 31
  • 101
  • 122
6
votes
4 answers

java.util.zip.ZipException: duplicate entry: android/support/v4/accessibilityservice/AccessibilityServiceInfoCompatJellyBeanMr2.class

I am integrating my project into another app in android studio but it shows the below error, I am googling the issue but no use. Error:Execution failed for task ':app:packageAllDebugClassesForMultiDex'. > java.util.zip.ZipException: duplicate entry:…
Ashok
  • 637
  • 2
  • 11
  • 24
6
votes
3 answers

Execution failed for task ':packageAllDebugClassesForMultiDex'

I am try to use the new android multidex support for a project. I have some problem with this exception: Error:Execution failed for task ':shineV3:packageAllDebugClassesForMultiDex'. java.util.zip.ZipException: duplicate entry:…
Deepak Jangir
  • 580
  • 5
  • 13
6
votes
1 answer

android multidex implementation

I am having this error . Error:Execution failed for task ':myApp:createDebugMainDexClassList'. com.android.ide.common.internal.LoggedErrorException: Failed to run command: java -Xmx1024M -cp \android-sdk\build-tools\19.1.0\lib\dx.jar…
M.Baraka
  • 725
  • 1
  • 10
  • 24
6
votes
1 answer

Multidex with Android 2.3 (API 9)

can anyone tell me if multi dex is supported in android 2.3? I've searched around but i can't find information for this. My project have the same configuration like this one: https://github.com/mustafa01ali/MultiDexTest The project builds without…
Zasuk
  • 750
  • 1
  • 7
  • 14