You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Android Studio运行Flutter应用时无法找到x86模拟器如何解决?

回答

Hey there, I’ve dealt with this exact quirky issue before—let me walk you through the fixes that got it working for me:

1. Fix the Emulator Path in Environment Variables

The root cause here is usually that Flutter can’t locate the emulator binary when launched from Android Studio, even though your terminal can find it just fine. Here’s how to fix it:

  • Open your shell config file (.bash_profile, .zshrc, or .bashrc depending on which shell you use) in a text editor.
  • Add this line to the file:
    export PATH="$PATH:/Users/$USER/Library/Android/sdk/emulator"
    
  • Save the file, then run source ~/.bash_profile (or the path to your specific config file) to apply changes right away.
  • Restart Android Studio, and Flutter should now pick up the emulator correctly.

2. Verify Android Studio’s SDK Configuration

Double-check that Android Studio is using the same SDK location as your terminal:

  • Go to Android Studio > Preferences > Appearance & Behavior > System Settings > Android SDK
  • Confirm the SDK Location is set to /Users/$USER/Library/Android/sdk (the same path you use in your terminal command)
  • If it was pointing to a different location, update it and restart the IDE.

3. Update Flutter and Plugins

Your Flutter version (0.3.2 beta) is pretty outdated—newer stable versions have fixed tons of Android Studio integration bugs:

  • Run these commands in your terminal to switch to stable channel and upgrade:
    flutter channel stable
    flutter upgrade
    
  • Also, update the Flutter and Dart plugins in Android Studio: Go to Preferences > Plugins, search for Flutter/Dart, install any available updates, then restart the IDE.

4. Confirm Flutter SDK Path in Android Studio

Make sure Android Studio has the correct path to your Flutter SDK:

  • Go to Android Studio > Preferences > Languages & Frameworks > Flutter
  • Check that the Flutter SDK path is accurate. If not, browse to your Flutter installation directory and select it.
  • You can also click the Flutter doctor button here to re-run diagnostics and catch any hidden issues.

One of these steps should get your emulator launching from Flutter projects in Android Studio again. Let me know if you hit any roadblocks!


内容的提问来源于stack exchange,提问作者XY6

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.28 03:55:22