简体   繁体   中英

Unity exception JDK not found

today I tried to install unity (2020.1.4f1) with the Unity Hub.

I have selected the following modules:

  • Android Build Support (Android SDK & NDK Tools | OpenJDK)
  • iOS Build Support
  • Universal Windows Platform Build Support
  • WebGL Build Support
  • Windows Build Support (IL2CPP)
  • Documentation

The installation is successfully completed. But after I want to build an Android App (.apk) an error ouccurs. The error from unity descripes that the JDK module is missing.

I tried to install the JDK manually from oracle. Firstly I tried the newest JDK (jdk-8u261-windows-x64.exe) but this does not solve the problem. Secondly I tried an older JDK version (jdk-8u251-windows-x64.exe) but even this one does not solve the problem.

I had set the Java envrionment variable manually, but wihtout success.

I installed Android Studio, but without success.

I hope there is someone who can help me to solve this problem.

I have solved this problem with the following solution.

  1. I have run the Unity Hub with administrator rights.
  2. I selected the system partition (in my case the C: drive) as installation directory (previously I had used the documents directory for installation)

I believe there was an approval problem with the installation process.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM