I went through the guide to add:
我浏览了一下指南,补充道:
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
defaultConfig {
jackOptions {
enabled true
}
}
To my android section of my module's build.gradle file. I also set the gradle plugin version to 2.2.0-alpha1 and even tried gradle wrapper 2.13.
到我模块构建的android部分。gradle文件。我还将gradle插件版本设置为2.2.0-alpha1,甚至尝试过gradle包装2.13。
When I try to compile, I get:
当我试图编译时,我得到:
Error(105, 0): Gradle DSL method not found: jackOptions()
I also tried commenting out jackOptions and using "useJack true", which compiled and created an APK, but I had no classes.dex file.
我还尝试过注释jackOptions并使用“useJack true”,它编译并创建了一个APK,但是我没有class .dex文件。
Why am I getting this error about jackOptions? What am I missing here?
为什么会有这个关于jackOptions的错误?我错过了什么?
2 个解决方案
#1
1
You should usebuildToolsVersion "24.0.0 rc3"
and before this you must install it.
您应该使用buildToolsVersion“24.0.0 rc3”,在此之前必须安装它。
#2
0
May be the buildToolsVersion must > 23. Try it.
可能是buildToolsVersion必须> 23。试一试。
#1
1
You should usebuildToolsVersion "24.0.0 rc3"
and before this you must install it.
您应该使用buildToolsVersion“24.0.0 rc3”,在此之前必须安装它。
#2
0
May be the buildToolsVersion must > 23. Try it.
可能是buildToolsVersion必须> 23。试一试。