解决方法:
defaultConfig {
applicationId "com.xxx"
minSdkVersion 19
targetSdkVersion 24
versionCode 1
versionName "1.0"
jackOptions {
enabled true
}
}
在defaultConfig中添加红色部分即可。