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
26
votes
5 answers

AndroidX MultiDex not found

I'm creating a new android project and decided to use the new AndroidX replacement for the support libraries, docs for which can be found here: https://developer.android.com/jetpack/androidx/migrate. I followed the steps to the letter and after…
Thomas Cook
  • 4,371
  • 2
  • 25
  • 42
25
votes
4 answers

gradle - Android Studio build too slow multidex application

When I add to my project the multidex:true, and make an Application class that extends from the MultiDexApplication, my project build time passed from 20 sec to around 90 sec.How to do some faster?
25
votes
4 answers

MultiDexApplication not recognized

Trying to use MultiDexApplication in my app, but the class is not recognized when I try to extend my application activity with it. Here is my build.gradle file: apply plugin: 'com.android.application' android { compileSdkVersion 21 …
JMRboosties
  • 15,500
  • 20
  • 76
  • 116
24
votes
5 answers

Program type already present: com.android.vending.billing.IInAppBillingService

Problem occurs only on release build or on generate signed apk, when I build debug - no such problem. Problem arrived right after upgrade AS to version 3.1 Program type already present:…
Stepan Maksymov
  • 2,618
  • 19
  • 31
24
votes
3 answers

NoClassDefFoundError below SDK 21

I just experienced an awkward bug in my App. On my Nexus 5/7, running android 5.0.1/5.0.2, everything works just fine. However if i try running the exact same code on a device with an earlier version (tested 4.4.4 and 4.3) I get the following…
user2700475
  • 827
  • 2
  • 7
  • 16
22
votes
7 answers

Speed up gradle build in multidex application

My application has a bunch of librarys that are essential that is why I was forced to use multidex support library and it works nicely. But where the problem shows is in the gradle buid speed. It takes on average 2minutes to build and when I am…
20
votes
2 answers

Impact of using Multidex on app performance, stability, compatibility...?

The next version of my app has roughly 70K methods. Knowing the exact implications of using Multidex (which usually means using the Multidex support library to support API<21) is important to me to make this decision: Should I put a lot of effort…
Sébastien
  • 13,831
  • 10
  • 55
  • 70
20
votes
1 answer

Android Espresso not working with Multidex gives "No tests found"

My Espresso tests were running until I had to support multidex. My build.gradle, I have minSdkVersion 14 targetSdkVersion 23 multiDexEnabled = true testInstrumentationRunner "com.android.test.runner.MultiDexTestRunner" androidTestCompile…
Sayooj Valsan
  • 536
  • 5
  • 16
19
votes
4 answers

Can I enable multidex in Android debug build only?

Dears, I read in many blog posts that multidex apps startup is slower than normal apps. My app uses a lot of libraries that exceed 64k methods so I use multidex. But when I use proguard in release build, the final apk becomes less than 64k…
Hisham Bakr
  • 559
  • 4
  • 13
19
votes
2 answers

App crashes on start caused by NPE in android.content.Context.getString

We have a really weird crash, which points to the system classes. It appears on application start. Fatal Exception: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.myapp.android/com.myapp.android.main.BaseMainActivity}: …
Veaceslav Gaidarji
  • 4,261
  • 3
  • 38
  • 61
19
votes
1 answer

DexIndexOverflowException: Cannot merge new index 65772 into a non-jumbo instruction!: Jumbo Mode? and/or Multi-Dex? What is behind the scene?

I have tried to set jumboMode in gradle for my project, it seems able to solve the following DexIndexOverflowException: com.android.dex.DexException: Cannot merge new index 65536 into a non-jumbo instruction! DexIndexOverflowException: Cannot merge…
18
votes
3 answers

Multiple dex files define Landroid/support/design/widget/CoordinatorLayout$LayoutParams

I'm getting Multiple dex files define error in my project. I'm using these two tags in build.gradle as well dexOptions { preDexLibraries = false } defaultConfig { multiDexEnabled true } but still getting this error. Information:Gradle…
Nisar Ahmad
  • 1,987
  • 3
  • 13
  • 30
18
votes
2 answers

Android takes more time on application start up during first time launch

In my project, I have used libraries which require multidex support. Based on the research I did, I came to know that it causes delay during app start up. I have enabled multidex feature in gradle. defaultConfig { multiDexEnabled true } I used to…
17
votes
2 answers

java.lang.ClassNotFoundException : dalvik.system.BaseDexClassLoader.findClass

I'm continuously getting this error report in my Google Play developer console. It look like MultiDex error. java.lang.RuntimeException: at android.app.LoadedApk.makeApplication(LoadedApk.java:516) at…
17
votes
3 answers

Cannot Resolve import android.support.multidex.MultiDex after change to newest Multidex

I want to use multidex in my application, At First I used depedencies : 'com.google.android:multidex:0.1', but after compile this error appeared : Error:Execution failed for task ':packageAllDebugClassesForMultiDex'. java.util.zip.ZipException:…
Redturbo
  • 1,563
  • 8
  • 22
  • 34
1
2
3
47 48