Troubleshooting "Unable to Find Bundled Java Version" Error in Flutter
When running the "flutter doctor" command on Android Studio version 3.0, some users encounter the error "Unable to find bundled Java version." This issue may arise despite having the latest Java version (1.8.0_131-b11) installed on Windows 10.
Solution for Mac:
For JetBrains Runtime "Android Studio Electric Eel":
Execute the following commands:
cd /Applications/Android\ Studio.app/Contents/jbr ln -s ../jbr jdk ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk
For Other Versions:
Execute the following commands:
cd /Applications/Android\ Studio.app/Contents/jre ln -s ../jre jdk ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk
For Mac Users with JetBrains Toolbox:
Replace "username" with your macOS username and run the following commands:
cd /Users/username/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/203.7583922/Android Studio.app/Contents/jre ln -s ../jre jdk ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk flutter doctor -v
If the issue persists, try the following workaround:
cd /Applications/Android\ Studio.app/Contents ln -s jbr jre
By following these steps, you can resolve the "Unable to find bundled Java version" error in Flutter and continue with your development.
The above is the detailed content of How to Fix the \'Unable to Find Bundled Java Version\' Error in Flutter?. For more information, please follow other related articles on the PHP Chinese website!