Flutter打包安卓提示请使用 -Xlint:deprecation 重新编译请使用 -Xlint:unchecked 重新编译

Posted 早起的年轻人

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Flutter打包安卓提示请使用 -Xlint:deprecation 重新编译请使用 -Xlint:unchecked 重新编译相关的知识,希望对你有一定的参考价值。


引用过时的API出现这样的提示,可以在Flutter andoird 目录下的 build.gradle中添加配置如下:

    gradle.projectsEvaluated 
        tasks.withType(JavaCompile) 
            options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
        
    

然后再次运行或者打包就会有相应的具体提示

以上是关于Flutter打包安卓提示请使用 -Xlint:deprecation 重新编译请使用 -Xlint:unchecked 重新编译的主要内容,如果未能解决你的问题,请参考以下文章

Flutter安卓客户端打包

Flutter mac上打包安卓APK遇到的坑

干货: 在 Flutter 项目下安卓 flavor 打包配置实践 | 开发者说·DTalk

干货: 在 Flutter 项目下安卓 flavor 打包配置实践 | 开发者说·DTalk

Jenkins打包安卓时提示没同意constraintLayout的license的解决方法

flutter-android打包