您当前的位置: 首页 >  ar

蓝不蓝编程

暂无认证

  • 3浏览

    0关注

    706博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

编译报错:R8: Static interface methods are only supported starting with Android N (--min-api 24): okhttp3

蓝不蓝编程 发布时间:2019-05-28 15:02:19 ,浏览量:3

报错信息
R8: Static interface methods are only supported starting with Android N (--min-api 24): okhttp3.Request okhttp3.Authenticator.lambda$static$0(okhttp3.Route, okhttp3.Response)

> Task :app:transformClassesAndResourcesWithR8ForRelease FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:transformClassesAndResourcesWithR8ForRelease'.
解决方案

在build.gradle文件的android节点下增加如下compileOptions.

android {
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
}
关注
打赏
1639405877
查看更多评论
立即登录/注册

微信扫码登录

0.0426s