gpt4 book ai didi

Flutter Hello world 应用无法在 Android Emulator x86_64 上启动

转载 作者:IT王子 更新时间:2023-10-29 06:33:33 25 4
gpt4 key购买 nike

我目前正在研究 Xamarin Forms,并想尝试 Flutter。
我用 Android Studio 创建了一个 Flutter 项目。但是我无法运行它。
我在 Android 模拟器上收到此错误在为 x86 64 构建的 Android SDK 上启动应用程序时出错。

flutter doctor 看起来不错。一些示例应用程序(例如 Flutter Gallery)可以运行,但有些则不能。

平台是 Windows 10 64 位。安卓工作室 3.2.1

错误信息是:

Launching lib\main.dart on Android SDK built for x86 64 in debug mode...
Initializing gradle...
Resolving dependencies...
Gradle task 'assembleDebug'...
Built build\app\outputs\apk\debug\app-debug.apk.
Installing build\app\outputs\apk\app.apk...
Error: ADB exited with exit code 1
adb: failed to install
C:\Users\xxx\source\flutter\flutter_app\build\app\outputs\apk\app.apk:
Error launching application on Android SDK built for x86 64.

C:\flutter>flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, v1.0.0, on Microsoft Windows [Version 10.0.17134.472], locale zh-TW)
[√] Android toolchain - develop for Android devices (Android SDK 28.0.3)
[√] Android Studio (version 3.2)
[√] IntelliJ IDEA Community Edition (version 2018.3)
[!] VS Code, 64-bit edition (version 1.30.1)
[!] Connected device
! No devices available

! Doctor found issues in 2 categories.

最佳答案

从这些行可以看出:

X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.

您缺少用于 flutter 和 dart 的插件。

转到:

File -> Settings -> Plugins

并安装 Flutter

enter image description here

然后检查是否也安装了 dart enter image description here

关于Flutter Hello world 应用无法在 Android Emulator x86_64 上启动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54000414/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com