Unable To Find Bundled Java Version With Flutter Doctor, After Updating Android Studio Arctic Fox(2020.3.1) On M1 Apple Silicon
Solution 1:
The answer is already posted here.
For Mac User:
Set Java_Home
path using below article & then after applying this command.
after that type below command in terminal:
cd /Applications/Android\ Studio.app/Contents/jre
ln -s ../jre jdk
ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk
flutter doctor -v
Solution 2:
Here is a little fuller answer for everything I had to do to get Android Studio set up on my M1.
Install Android Studio to the Applications folder
Create a symbolic link to from the
jre
folder to a newjdk
folder. (Due to this bug)
cd /Applications/Android\ Studio.app/Contents/jre
ln -s ../jre jdk
- Set the
JAVA_HOME
environment variable
nano ~/.zshrc
export JAVA_HOME="/Applications/Android Studio.app/Contents/jre/jdk/Contents/Home"
source ~/.zshrc
Install Android SDK Command-line Tools (needed for accepting license)
At this point it should work now (assuming you've also added flutter to your path)
flutter doctor
Solution 3:
I did install a fresh version of JAVA SDK, flutter, Android Studio and run the below command directly on the terminal one by one to fix 'Unable to find bundled Java version. ' issue.
cd /Applications/Android\ Studio.app/Contents/jre
ln -s ../jre jdk
ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk
flutter doctor -v
Now, you should be able to see the error is disappeared in flutter doctor description in terminal.
Solution 4:
This solution is for M1 Mac User
- Find your local Java version by typing
/usr/libexec/java_home -V
. If didn't exist, install the latest ARM Java version here - Set Java_Home path (in my case jdk-17.0.1.jdk) by typing
/usr/libexec/java_home /Library/Java/JavaVirtualMachines/jdk-17.0.1.jdk/Contents/Home
- Type all of these in terminal
cd /Applications/Android\ Studio.app/Contents/jre
ln -s ../jre jdk
ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk
- Finally run
flutter doctor -v
to see all the details changes
Solution 5:
Perhaps the simplest option (MAC):
- Navigate to:
cd /Applications/Android\ Studio.app/Contents/jre
- Create a directory:
mkdir jdk
- Create a soft link:
ln -s Contents jdk/Contents
Post a Comment for "Unable To Find Bundled Java Version With Flutter Doctor, After Updating Android Studio Arctic Fox(2020.3.1) On M1 Apple Silicon"