zoukankan      html  css  js  c++  java
  • Error:Annotation processors must be explicitly declared now.

    环境

    Android Studio 3.0
    Gradle 3.0.0 
    gradle 4.1
    

    Error

       Error:Execution failed for task ':app:javaPreCompileAnzhiDebug'.
        > 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.
        - butterknife-7.0.1.jar (com.jakewharton:butterknife:7.0.1)
        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.
    

    解决

    javaCompileOptions {
            // 显式声明支持注解
            annotationProcessorOptions {
                includeCompileClasspath false
            }
    }
  • 相关阅读:
    CodeForces 242E二维线段树
    树形DP
    014 国际化
    013 属性文件
    012 BeanPostProcessor
    011 aware
    010 依赖注入
    009 IOC--初始化和销毁
    008 IOC--Bean的作用域
    007 IOC---Resource
  • 原文地址:https://www.cnblogs.com/lifan1998/p/9220931.html
Copyright © 2011-2022 走看看