I have an existing Android Project that uses the following libs:
- AutoValue
- Dagger2
- RxJava
- Retrolambda
I am trying to add Kotlin Support so that I can slowly migrate the project over to Kotlin. Here is what I have done.
- Added Kotlin dependency.
Converted one of the classes over to Kt class and moved over to
src/main/kotlin/..package..
Added kotlin in source set. sourceSets { main.java.srcDirs += 'src/main/kotlin' }
When I do a clean build and deploy the app, I get NoClassDefFoundError exception. However, If I deploy again it works just fine. Any suggestions? I do not have any annotation in the class I converted so I did not apply
kapt
plugin.
Note: I am using latest kotlin 1.0.4. Also I have instant run disabled.