Mar*_*vin 13 android android-layout android-studio butterknife jack-compiler
我刚开始一个非常简单的项目,并尝试使用ButterKnife和Jack编译器,但似乎它们并不能很好地应对.
Gradle插件版本:2.2.0-alpha5
在我的模块build.gradle中我添加了:
compile 'com.jakewharton:butterknife:8.2.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.2.1'
Run Code Online (Sandbox Code Playgroud)
并且错误消息是:
Error:Execution failed for task ':app:transformJackWithJackForDebug'.
java.lang.AssertionError: java.lang.IllegalArgumentException
Run Code Online (Sandbox Code Playgroud)
我错过了什么,或者只是他们不兼容?
最近发布了8.3.0版,支持Jack.
compile 'com.jakewharton:butterknife:8.3.0'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.3.0'
Run Code Online (Sandbox Code Playgroud)
apply plugin: 'android-apt'尝试在您的应用程序 gradle 中删除。
正如自述文件中所说:
注意:如果您使用版本 2.2.0 或更高版本的新 Jack 编译器,则不需要“android-apt”插件,并且可以在声明编译器依赖项时将 apt 替换为annotationProcessor。
| 归档时间: |
|
| 查看次数: |
1566 次 |
| 最近记录: |