カテゴリー
Flutter

Flutter DoctorでUnable to find bundled Java version.

developer@Mac-mini ~ % flutter doctor -v
[✓] Flutter (Channel master, 2.4.0-5.0.pre.166, on macOS 11.5.1 20G80
    darwin-x64, locale ja-JP)
    • Flutter version 2.4.0-5.0.pre.166 at /Users/developer/Documents/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 2dc11a85ff (2 weeks ago), 2021-07-22 17:56:03 -0700
    • Engine revision fbbb3b3f7b
    • Dart version 2.14.0 (build 2.14.0-343.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
    • Android SDK at /Users/developer/Library/Android/sdk
    • Platform android-30, build-tools 30.0.3
    • Java binary at: /Applications/Android Studio 4.2
      Preview.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6842174)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 13.0, Build version 13A5201i
    • CocoaPods version 1.10.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio
    • Android Studio at /Applications/Android Studio 4.2 Preview.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6842174)

[!] Android Studio (version 2020.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    ✗ Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[✓] VS Code (version 1.59.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.25.0

[✓] Connected device (2 available)
    • iPhone (mobile) • XXXXXXXX-XXXXXXXXXXXXXXXX • ios            • iOS 14.7.1
      18G82
    • Chrome (web)    • chrome                    • web-javascript • Google
      Chrome 92.0.4515.131
    ! Error: iPhone is busy: Fetching debug symbols for iPhone. Xcode will
      continue when iPhone is finished. (code -10)

! Doctor found issues in 1 category.

Unable to find bundled Java version.

が消えない。

developer@Mac-mini ~ % cd /Applications/Android\ Studio.app/Contents/jre
developer@Mac-mini jre % ln -s ../jre jdk
developer@Mac-mini jre % ln -s "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin" jdk

とすると解消した。

developer@Mac-mini my_app_01 % flutter doctor -v
[✓] Flutter (Channel master, 2.4.0-5.0.pre.166, on macOS 11.5.1 20G80
    darwin-x64, locale ja-JP)
    • Flutter version 2.4.0-5.0.pre.166 at /Users/developer/Documents/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 2dc11a85ff (2 weeks ago), 2021-07-22 17:56:03 -0700
    • Engine revision fbbb3b3f7b
    • Dart version 2.14.0 (build 2.14.0-343.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
    • Android SDK at /Users/developer/Library/Android/sdk
    • Platform android-30, build-tools 30.0.3
    • Java binary at: /Applications/Android
      Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7281165)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 13.0, Build version 13A5201i
    • CocoaPods version 1.10.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio
    • Android Studio at /Applications/Android Studio 4.2 Preview.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6842174)

[✓] Android Studio (version 2020.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7281165)

[✓] VS Code (version 1.59.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.25.0

[✓] Connected device (2 available)
    • iPhone (mobile) • XXXXXXXX-XXXXXXXXXXXXXXXX • ios            • iOS 14.7.1
      18G82
    • Chrome (web)    • chrome                    • web-javascript • Google
      Chrome 92.0.4515.131
    ! Error: iPhone is busy: Fetching debug symbols for iPhone. Xcode will
      continue when iPhone is finished. (code -10)

• No issues found!

No issues found!がやっと出た。