繁体   English   中英

Flutter apk 在 android 设备中不起作用

[英]Flutter apk doesn't work in android device

我尝试为我的 flutter 应用程序生成 apk 文件,我在flutter clean命令之后使用flutter build apk --release命令。 请注意,使用flutter build apk --release命令后,我收到此错误:

Note: C:\src\flutter\.pub-cache\hosted\pub.dartlang.org\android_intent-0.3.7+3\android\src\main\java\io\flutter\plugins\androidintent\MethodCallHandlerImpl.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: C:\src\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher-5.4.5\android\src\main\java\io\flutter\plugins\urllauncher\WebViewActivity.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

之后,我从这个路径获得了 apk 文件: C:\project_path\build\app\outputs\apk\release ,但是当我尝试从手机安装这个 apk 时,我app not installed

在此处输入图像描述

注意:我尝试过不止一种设备具有不同的 android 版本。

请帮我解决我的问题。

似乎是警告,而不是错误,因此应该生成 apk。

无论如何,您是否检查了硬件架构?

例如,尝试为您的智能手机指定架构:

flutter 构建 apk --target-platform android-arm64

flutter 构建 apk --target-platform android-arm (<-- arm 32 位)

ETC...

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM