Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice

Unity Hub not installing Android SDK correctly?

Discussion in 'Unity Hub' started by cdauphinee, Aug 27, 2019.

  1. Snitem

    Snitem

    Joined:
    May 18, 2016
    Posts:
    4
    No.
     
  2. ahmedaniss

    ahmedaniss

    Joined:
    Sep 18, 2019
    Posts:
    94
    problem fixed here :
     
    Last edited: Feb 17, 2021
  3. myusufakdas2006

    myusufakdas2006

    Joined:
    Jan 29, 2021
    Posts:
    1
    i solved. first i checked the sdk folder. and it was empty. I entered the unity hub and installed it one by one.
     
  4. SwiftwaveX

    SwiftwaveX

    Joined:
    Jan 31, 2021
    Posts:
    2
    Me too! I'm on 2020.2 on windows...
     
  5. Samacvuk

    Samacvuk

    Joined:
    Jan 8, 2017
    Posts:
    30
    Still happening on 2019 LTS
     
  6. JxWolfe

    JxWolfe

    Joined:
    Jan 10, 2017
    Posts:
    2
    Unity Hub 2.4.3 still has an issue. When you set a install folder for your editors the android build settings are not setup correctly (2020.3.11f1 & 2021.1.10). It works fine when the install is Unity/Hub/Editors but attempting to have them on a different hard drive had this issue. (OS: Linux (Mint 19.3))
     
  7. Slip_de_feu

    Slip_de_feu

    Joined:
    Jun 13, 2021
    Posts:
    8
    It works for me.

    If you are facing problems with Unity Hub about installing "Unity 2020.3.11f1 / Unity 2021.1.11f1 and android modules (SDK, NDK, OpenJDK)", here's my solution :

    1) Firstly, I would recommend to install "UnitySetup-Android-Support-for-Editor-2020.3.11f1.exe" to your Unity 2020.3.11f1's path or "UnitySetup-Android-Support-for-Editor-2021.1.11f1.exe" to your Unity 2021.1.11f1's path.
    You'll have a folder named "AndroidPlayer" in your path "{UNITY_PATH}\2020.3.11f1\Editor\Data\PlaybackEngines\" or "{UNITY_PATH}\2021.1.11f1\Editor\Data\PlaybackEngines\".

    2) In your "AndroidPlayer" folder, decompress these 3 7z files : "Android_NDK_19.0.5232133.7z", "OpenJDK_1.8.0_152.7z", "Android_SDK.7z"

    3) Run Unity 2020.3.11f1 / Unity 2021.1.11f1 and go to FILE > Build settings > Platform Android, click on "switch platform"

    4) You can now build your android apps in Unity 2020.3.11f1 / Unity 2021.1.11f1
     
  8. James0oO

    James0oO

    Joined:
    Dec 8, 2014
    Posts:
    10
    Hello,
    I am completely stumped. Whatever I do, android support will just not install via hub.

    I have deleted everything (editor, hub etc) included folders and reinstalled countless times. Whatever version I use its the same thing; hub shows the tick boxes greyed not blue and just says "installed" but at build time nothing.

    All the paths seem correct ( I am installing on a C: drive on a new PC).

    Never had this problem before and now it is perfect and completely broken.

    hub.jpg

    The only odd thing is in editor it says error "You are missing the recommended Android NDK. Install the recommended version using Unity Hub"
    The paths are all correct but the NDK folder is empty.

    Same issue with all Editor versions.

    Any ideas?
     
  9. denissulyagin

    denissulyagin

    Joined:
    Jul 9, 2015
    Posts:
    2
    The problem has been more than a year, and the developers have not solved it. Thus, Unity will never be the best. It is impossible to work with it. Excuse me.
     
    Cascho01, Alex-CG and d1favero like this.
  10. EyeDev44

    EyeDev44

    Joined:
    Apr 8, 2017
    Posts:
    114
    Same appeared.
     
  11. k4mazzy

    k4mazzy

    Joined:
    Jul 7, 2018
    Posts:
    2
    hello there. fix it by setting all pathes to previous version unity editor
     
  12. k4mazzy

    k4mazzy

    Joined:
    Jul 7, 2018
    Posts:
    2
  13. Alex-CG

    Alex-CG

    Joined:
    May 10, 2015
    Posts:
    11
    Two years, no fix, Unity indeed.
     
  14. vaclav_b

    vaclav_b

    Joined:
    Jun 7, 2013
    Posts:
    16
    This issue is still happenning. Same thing on Unity Hub 3 beta.
     
  15. trooper

    trooper

    Joined:
    Aug 21, 2009
    Posts:
    711
    Yeah it sucks. Should allow us to remove and reinstall from that menu.
     
  16. trooper

    trooper

    Joined:
    Aug 21, 2009
    Posts:
    711
    I've found installing just the editor from Unity Hub, after it's done, install JDK, then install SDK/NDK gets rid of the error. Doing it all at once is when it fails for me.
     
  17. UnityJuju

    UnityJuju

    Unity Technologies

    Joined:
    Jun 15, 2021
    Posts:
    188
    Hi folks!
    A new beta went out yesterday! Could you please update your Hub V3 and check if the issue is still happening?
    You can see the full release notes here!
     
  18. Fangh

    Fangh

    Joined:
    Apr 19, 2013
    Posts:
    171
    I'm on Windows and this is still an issue upload_2021-9-30_12-54-49.png
     

    Attached Files:

  19. tnaseem

    tnaseem

    Joined:
    Oct 23, 2009
    Posts:
    149
    This is still an issue for me on Windows 10, Unity Hub 3.0.0-beta-5. It's been happing every time I perform another install. The current install was for Unity 2021.1.23f1.

    I always get this error:

    : Screenshot 2021-10-04 at 10.08.38 PM.png

    I have to hit Ignore to continue, but the PlatformEngines/AndroidPlayer folder has missing folders - No OpenJDK folder and missing folders inside the NDK and SDK folders.

    I always keep the older version, so I can just copy across these missing folders.

    Happens every time and has been happening for the last several months. It did rear its ugly head in Unity Hub 2.x and no amount of uninstalling, deleting app data folders, temp folders, rebooting, standing on one leg makes a difference.
     
  20. nitz

    nitz

    Joined:
    May 4, 2011
    Posts:
    46
    I'm seeing the same issues as tnaseem on Unity Hub 3.0.0-beta-5.

    If I roll back to production and install the editor that way w/Android Build support, it installs and works properly.
     
  21. mhmtemnacr

    mhmtemnacr

    Joined:
    Mar 7, 2013
    Posts:
    15
    Did you manage to fix this error
     
  22. tnaseem

    tnaseem

    Joined:
    Oct 23, 2009
    Posts:
    149
    Not much luck, I'm afraid. Although, this time it did something different.

    2021.1.24f1 is out, so I gave it a shot. I selected all the modules and started the installation - This time it didn't give me any errors and stated that the installation had been completed successfully.

    However, on checking the AndroidPlayer folder, I noticed that this time the OpenJDK folder was still missing. NDK and SDK folders appeared complete though.

    I went back into Unity Hub and did an 'Add Module' for this version, selecting OpenJDK. But each time it would complain that it had failed some validation:

    Clipboard Image.jpg

    So, as before, I just copied over the OpenJDK folder from the old version into this one.
     
    Last edited: Oct 11, 2021
  23. Alex-CG

    Alex-CG

    Joined:
    May 10, 2015
    Posts:
    11
    Yes, no errors during install, but after the process, some errors and this old friend:
    upload_2021-10-13_14-48-18.png
     
  24. UnityJuju

    UnityJuju

    Unity Technologies

    Joined:
    Jun 15, 2021
    Posts:
    188
    I've raised this thread with the Hub team, and this issue will be addressed in a future version.
     
  25. Devil_Inside

    Devil_Inside

    Joined:
    Nov 19, 2012
    Posts:
    1,093
    I had the same issue with Hub beta 5 and Unity 2021.1.x
    What worked for me:
    1. Install just the Unity editor. Wait for it to install.
    2. Add Android Support module. Wait for it to install.
    3. Add SDK & NDK module. Wait for it to install.
    4. Add JDK module.
     
    AnnieN and ExtraCat like this.
  26. Chinoirx

    Chinoirx

    Joined:
    Mar 27, 2020
    Posts:
    7
    I solved it first by installing only the editor, then by installing the android packages one at a time, all with unity hub and the editor started with administrator rights (from the properties)
     
  27. Isaacary

    Isaacary

    Joined:
    Aug 10, 2017
    Posts:
    1
    no it didnt
     
  28. nitz

    nitz

    Joined:
    May 4, 2011
    Posts:
    46
    Gave this a shot with Beta 5 when installing 2020.3.21f1, and it worked for me as well. Seems doing it sequentially like this is an effective workaround.

    That said, it'd be nice if every time I 'Add Module' I didn't fail to notice it was also adding Visual Studio Community and the offline Documentation.
     
    Devil_Inside likes this.
  29. LostInFlux

    LostInFlux

    Joined:
    Oct 5, 2021
    Posts:
    1
    Yeah, the workaround didn't work for me. I tried a lot of different combinations of piecemeal install, but it just never could get to the point where it was happy. It also may have manifested in the inability to build to my phone (when trying to build and run, it was asking where to save, but then telling me that that file name didn't exist and wouldn't build+run). I've given up for now and am exploring different options, but hopefully they'll resolve this super old issue
     
  30. Shadowing

    Shadowing

    Joined:
    Jan 29, 2015
    Posts:
    1,586
    Well damn. This problem started happening to me like in the last month.
    it installs OpenJDK but not android SDK & NDK Tools
    When I unclick it and click it it tries to install it. seems it downloads it but never installs it right I guess.
     
  31. weiping-toh

    weiping-toh

    Joined:
    Sep 8, 2015
    Posts:
    184
    2020.3.19f1 is missing ndk too
     

    Attached Files:

  32. weiping-toh

    weiping-toh

    Joined:
    Sep 8, 2015
    Posts:
    184
    Would it be fine if Unity just expose a list of sdk/ndk versions corresponding to the Unity versions so that if anything goes wrong, people could manually download and install from the android studio archive? Or provide the archive in which the sdk/ndk packages reside in so that we could manually download if needed?
     
  33. Joergenvs88

    Joergenvs88

    Joined:
    Dec 17, 2019
    Posts:
    1
    Still Not fixed and having the same issue....its shocking such a critical thing is overlooked
     
  34. AnnieN

    AnnieN

    Joined:
    Feb 2, 2018
    Posts:
    5
    I installed just Editor first, after it finished added modules SDK, then after it finished again added modules JDK to complete the Android part. Download them all at once was super slow and the files was corrupted somehow.
    My version are Unity Hub 2.4.5 and Editor 2020.3.23.f1
    The internet in my city is super slow and unstable in this Covid timeline, but it works this way (and the SDK is now updated to 30! yeah!).
    (some of the comments above say they succeed this way too)
    Good luck everyone.
     
  35. UnityJuju

    UnityJuju

    Unity Technologies

    Joined:
    Jun 15, 2021
    Posts:
    188
  36. TheFellhuhn

    TheFellhuhn

    Joined:
    Feb 3, 2017
    Posts:
    41
    Had a similar problem. The Hub (3.0.0 and prior versions too) claimed the SDK and NDK were installed while they clearly weren't. Reinstall isn't possible with the hub (missing feature!). What helped was checking the modules.json in the Unity directory and downloading the files manually. How the folders should be named is also written in the modules.json. Works now.
     
  37. dodget3

    dodget3

    Joined:
    May 25, 2018
    Posts:
    3
    Why is it too much to ask that it just work like it's supposed to?
     
  38. LOLinc

    LOLinc

    Joined:
    Nov 18, 2013
    Posts:
    28
    I installed unity 2022.1.8f and modules via UnityHub 3.2.0 and it keeps giving me errors with the JDK too.
    Tried to completely delete the version with modules and installed it again with the same errors.
    Unity Hub really should come with an easy way to remove modules seeing that the automatic module installer ofttimes does not work as intended. It is a dope feature when it does work though.
    upload_2022-7-11_23-43-47.png
     
    ScottAdams likes this.
  39. Bob_the_Hamster

    Bob_the_Hamster

    Joined:
    Nov 16, 2016
    Posts:
    1
    So I ran into this same error message on a fresh install of Unity 2021.3.8f1 on Linux.

    Unity Hub installs the Android SDK, NDK, and OpenJDK into the correct location, but it strips the executable bit from all binaries, which is why the android build fails to work.

    I fixed it with this workaround:
    Code (csharp):
    1. cd ~/Unity/Hub/Editor/2021.3.8f1/Editor/Data/PlaybackEngines/AndroidPlayer
    2. for I in $(find -iname bin) ; do chmod +x "$I"/* ; done
    3. chmod +x SDK/platform-tools/*
    4.  
    That fixed it for me on Linux. I expect the same fix would also work if this happened on Mac, since it needs the executable bits also. (I have no idea about Windows in this situation)
     
unityunity