Search Unity

Updating project 2019.2 to 2019.4: JDK not found

Discussion in 'Editor & General Support' started by Suduckgames, Jun 10, 2020.

  1. Suduckgames

    Suduckgames

    Joined:
    Nov 28, 2016
    Posts:
    218
    Hi there, I just updated my project from 2019.2 to 2019.4.

    I have been able to build without problem for android on 2019.2

    I have tried to make a build of the game for android but it didn't find the java in the project (Even if I had turned on the "JDK installed with Unity( recommended)" option)

    I have tried to manually select the Java folder but it doesn't find it. I have checked my java version to make sure that is the correct and it is


    Code (CSharp):
    1. java version "1.8.0_221"
    2. Java(TM) SE Runtime Environment (build 1.8.0_221-b11)
    3. Java HotSpot(TM) Client VM (build 25.221-b11, mixed mode)

    Seems like my Unity 2019.4 is having problems recognizing java. It doesn't recognize the installed with Unity or the manually installed

    Is anyone having this problem too? Any solution?


    Edit: When I check the JDK installed with Unity option. The warning says:
    "You are missing the recommended JDK. Install the recommended version using Unity Hub"
    Same happen with the SDK through the SDK is installed according to Unity Hub and I don't see an option to install JDK through Unity hub
     
    I_Love_Misato and JamesB0nd like this.
  2. JamesB0nd

    JamesB0nd

    Joined:
    Apr 13, 2019
    Posts:
    2
    Me too. Same problem.
     
  3. I_Love_Misato

    I_Love_Misato

    Joined:
    Jan 14, 2014
    Posts:
    45
    Me too(( Although, I can check a checkmark to install JDK in Unity Hub, but it is not installed.
    When I go to "Installs" section of Unity Hub, there are two versions of the editor for me: 2019.2, which I installed before, and 2019.4. When I press "Add Modules" for Unity 2019.2, it shows me the following installed modules, it looks allright:

    But when I do the same for Unity 2019.4, it says that OpenJDK is not installed:

    I tryied everything to reinstall it, nothing helps. It looks like a bug somewhere. I thought the LTS version is stable :(
    P.S. When I press "Done", it shows some progress for a while as though it is installing it somewhere, but it makes no effect.
     
  4. Suduckgames

    Suduckgames

    Joined:
    Nov 28, 2016
    Posts:
    218
    In my case, I reinstalled the editor, Added the modules after the installation was done and I tried to compile a new project. That worked for me. I can also recommend to try copy the OpenJDK folder of 2019.2 and paste to 2019.4. I don't know if it works but it is worth to give a try
     
  5. jhocking-bundlar

    jhocking-bundlar

    Joined:
    Nov 12, 2019
    Posts:
    24
    I also had 2019.2 already installed when I added 2019.4, and the jdk wasn't installed. I just manually browsed in Unity preferences to the 2019.2 jdk (on a mac, it's /Applications/Unity/Hub/Editor/2019.2.13f1/PlaybackEngines/AndroidPlayer/Tools/OpenJDK/MacOS) so simple fix but annoying.