Running Android App Produces Java.lang.noclassdeffounderror: Retrofit.restadapter$builder
I am making a photo gallery app using the Flickr API on Android (Using Eclipse and 4.4 SDK). The project is successfully compiled but the app crashes as soon as it launches on Nexu
Solution 1:
I had the same error on Android 4.4 and below. It was something linked with the multiDexEnabling.
Try adding "multiDexEnable true
" inside build.gradle
:
defaultConfig {
minSdkVersion 15
targetSdkVersion 23
versionCode 16
versionName "1.5"
multiDexEnabled true
}
If that doesn't help just add this line
android:name="android.support.multidex.MultiDexApplication"
inside AndroidManifest.xml
as below:
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:name="android.support.multidex.MultiDexApplication">
...
Solution 2:
Place your jars inside the libs folder so that you wont get a runtime NoClassDefFoundError
exception. I think you might have screwed up in this part.
Post a Comment for "Running Android App Produces Java.lang.noclassdeffounderror: Retrofit.restadapter$builder"