Error:Execution failed for task ':MPChart_libary:javaPreCompileDebug'.
> Annotation processors must be explicitly declared now. The following dependencies on the compile classpath are found to contain annotation processor. Please add them to the annotationProcessor configuration.
- realm-android-0.87.5.jar
Alternatively, set android.defaultConfig.javaCompileOptions.annotationProcessorOptions.includeCompileClasspath = true to continue with previous behavior. Note that this option is deprecated and will be removed in the future.
See https://developer.android.com/r/tools/annotation-processor-error-message.html for more details.
搜索名字“realm-android-0.87.5”构建。 gradle文件的模块“MPChart_libary”:
dependencies {
provided 'io.realm:realm-android:0.87.5'
}
解决方案,添加如下
dependencies {
provided 'io.realm:realm-android:0.87.5'
annotationProcessor 'io.realm:realm-android:0.87.5' //添加这一句
}