Search Unity

  1. Unity 2020.1 has been released.
    Dismiss Notice
  2. We are looking for feedback on the experimental Unity Safe Mode which is aiming to help you resolve compilation errors faster during project startup.
    Dismiss Notice
  3. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Build Target Android is not supported, switch to Windows or Exit Unity?

Discussion in 'Editor & General Support' started by SanjayBhambhu, Feb 6, 2019.

  1. SanjayBhambhu

    SanjayBhambhu

    Joined:
    Aug 22, 2012
    Posts:
    13
    I am working on a game for android, and I have the Android module downloaded and setup and was doing test builds every day, but ever since 2018.3.* updates, every next day when I open my project in unity I am presented with a small window with this line "Build Target Android is not supported, switch to Windows Standalone or Exit Unity?", and there are two buttons on the bottom "Switch Target" and "Exit Unity".
    • Even If I press "Exit Unity", the build target is set to Windows Standalone the next time I open my project.
    • If I press "Exit Unity", and install and android module and open my project again the build target is set to Windows Standalone for my project.
    • If I open the project as it is, I see these type of options,
    aaa.PNG

    Notice that it says no android module selected, though there is option to "Switch Platform" there.
    In this case if I press the "Switch Platform" button I am stuck in this screen.

    sss.PNG

    If I install the Android module, I am able to work on my project correctly, for the day, but the next day again I have to face this.

    Please help as installing android module and changing the build target to Android everyday is very much time consuming.

    Thank You
     
    arufolo, melogsy and ina like this.
  2. dominykasm

    dominykasm

    Unity Technologies

    Joined:
    May 27, 2018
    Posts:
    68
  3. newtype1124

    newtype1124

    Joined:
    Feb 19, 2019
    Posts:
    1
    I have the same problem. Work hard unity. This is really stressful
     
    Ianaa likes this.
  4. SanjayBhambhu

    SanjayBhambhu

    Joined:
    Aug 22, 2012
    Posts:
    13
    Updated to 2018.3.6f1, to still see the same "Switch Target" window, and now it is taking me hours to switch to Windows platform, just so I can switch to Android platform again.
     
    Last edited: Jun 21, 2019
  5. Aseemy

    Aseemy

    Joined:
    Aug 22, 2015
    Posts:
    153
    I faced the same issue on Unity 2018.3.6f1 today. It was showing that both IOS and Android modules not installed. Reinstalled the Android module (did not install IOS again) and restarted the project, and both IOS and Android modules now available again.

    Same thing happened to me but it didnt spend hours to switch platform as i have enabled the Cache Server. please read about it here. Very helpful for mobile devs who have to switch platforms frequently.
     
  6. harryblack

    harryblack

    Joined:
    Dec 26, 2016
    Posts:
    7
    I have been getting this for sometime now. I install Android module every time and it seems to work fine and then in a few days again, it shows up.
    It is happening right now after 3-4 days of working normally.
    It seems as if the android module gets uninstalled on its own or somehow becomes undetectable by unity. Is there a way to correct this?
     
    arufolo and Rdev like this.
  7. harryblack

    harryblack

    Joined:
    Dec 26, 2016
    Posts:
    7
    After I repeatedly tried to get into Unity by exitting it, it got me through and in build settings I am seeing android module intact but in console I see this error


    IndexOutOfRangeException: Index was outside the bounds of the array.
    UnityEditor.Android.AndroidBuildWindowExtension.GetBuildPlayerWindow () (at <e1c3953b4cf040ddb1400046b1c34897>:0)
    UnityEditor.Android.AndroidBuildWindowExtension.RepaintTargetList () (at <e1c3953b4cf040ddb1400046b1c34897>:0)
    UnityEditor.EditorApplication.Internal_CallUpdateFunctions () (at C:/buildslave/unity/build/Editor/Mono/EditorApplication.cs:200)
     
  8. woosungwon

    woosungwon

    Joined:
    Oct 8, 2018
    Posts:
    1
    This issue appears to occur when you install a 2018.3.x or earlier version and update it multiple times to a higher version.

    It also occurs at 2018.3.8f1.
    This problem occurs 100% after rebooting Windows.

    I installed the same version on both my laptop and desktop.
    The problem only occurs on the desktop.

    Uninstalling and reinstalling Unity at this time and installing the Android support module will not fix the problem.

    When you run Unity, first open a blank project, change the project to Android, then open the wrok project and open it normally. It is a way to shorten the time.

    I hope this issue will be resolved soon.
     
    ShoutTree likes this.
  9. sarebots2

    sarebots2

    Joined:
    Jul 4, 2016
    Posts:
    27
    I'm facing the same problem, every time I restart Unity, it can't detect android module. I have to reinstall the android module by running "UnitySetup-Android-Support-for-Editor-2018.3.8f1.exe" or switch to standalone, open project, switch back to android (Even then the build option is greyed out in build settings, but the build and run option from file menu works, make sure the unity icon is next to android in build settings)
     
  10. alap18

    alap18

    Joined:
    Oct 31, 2014
    Posts:
    1
    This worked for me: opening a blank project, switching to Android and then opening up my work project.
     
    Sompol_Rznet likes this.
  11. Jianyong_Luo_2014

    Jianyong_Luo_2014

    Joined:
    Nov 29, 2014
    Posts:
    1
    anyone has final solution on this? This occurs with unity 2018.3.8.
     
  12. charlesntt

    charlesntt

    Joined:
    Jul 28, 2017
    Posts:
    1
    Is the same for me, updated Unity, 2018.3.8 e it continues. The modules already instaled. I need to open in standalone e close the project, after this I re-open e switch platform works, but is tedius do the same thing all the time.
     
  13. ekaralar

    ekaralar

    Joined:
    Jan 13, 2015
    Posts:
    13
    Having the same problem with 2018.3.8 for IOS.
    Any solution Unity?
     
    melogsy likes this.
  14. tjPark

    tjPark

    Joined:
    Mar 19, 2015
    Posts:
    5
    Before you select your project,
    select "Learn" Tab, then back to "Project" tab and select your project.
    This solved me the problem. (osx Mojave, 2018.3.6f1)
     
    TuDT, Brastik, Tapin and 9 others like this.
  15. MohamedEssam2008

    MohamedEssam2008

    Joined:
    Sep 8, 2017
    Posts:
    1
    same here Unity_2018.3.7f1
     
  16. Qasim337

    Qasim337

    Joined:
    Oct 16, 2015
    Posts:
    1
    This happened with Unity 2018.3.5, I updated to Unity 2018.3.8, but after few days, happening again.


    If I close the error window, create a new project and open the old project from File menu, it works fine without having to reinstall plugin and switch platform
     
  17. Its4u

    Its4u

    Joined:
    Oct 11, 2013
    Posts:
    14
    This works for me. Thanks

    This issue still happens in Unity 2018.3.9
     
  18. nikescar

    nikescar

    Joined:
    Nov 16, 2011
    Posts:
    109
    This has been happening to me on every version of 2018.3. The difference for me is it only happens after a Unity crash.
     
    arufolo and ina like this.
  19. pikychu

    pikychu

    Joined:
    Sep 18, 2014
    Posts:
    2
    unity 2018.3.10f1 same here
     
  20. tmongy

    tmongy

    Joined:
    May 9, 2014
    Posts:
    1
    Thanks that worked!
     
  21. dchakrabarty

    dchakrabarty

    Joined:
    Mar 1, 2019
    Posts:
    2
    After upgrading Mac to Mojave 14.10.4, the same happened with me. I did the same thing after reading your post and strangely it worked!
     
    ina and Waynecai123 like this.
  22. ina

    ina

    Joined:
    Nov 15, 2010
    Posts:
    889
    This solved it for me for the iOS module for Mojave
     
  23. trooper

    trooper

    Joined:
    Aug 21, 2009
    Posts:
    684
    I'm speechless, worked on Windows 10.
     
  24. FrancoD

    FrancoD

    Joined:
    May 31, 2016
    Posts:
    6
    Thx,Works for me !
     
  25. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,654
    Have you set the path to the Android SDK under Preferences/External Tools? I suspect everyone here has, but had to ask.
     
  26. Aseemy

    Aseemy

    Joined:
    Aug 22, 2015
    Posts:
    153
    Yes, I have. Cant say for others but they probably have as it used to work but stops later.
     
  27. KaOzz

    KaOzz

    Joined:
    Oct 15, 2012
    Posts:
    39
    That worked for me! Thanks.
     
  28. tnluan

    tnluan

    Joined:
    Feb 17, 2017
    Posts:
    1
    Thanks, you saved me!
     
  29. akshayg6590

    akshayg6590

    Joined:
    Apr 28, 2019
    Posts:
    1
    This worked!!
     
  30. unity_moN7x4zmQZyK8w

    unity_moN7x4zmQZyK8w

    Joined:
    Nov 7, 2018
    Posts:
    1
    hi
    If you work without Android studio , you must install Android sdk & Jdk And from the section Edit>Preferences>External>tools Manually install in Unity.
    better is install Android Studio then you can take output of unity
     
  31. TerrenceRao

    TerrenceRao

    Joined:
    Jun 19, 2015
    Posts:
    5
    Same Problem in (Osx mojave ,unity 2018.3.14f1)
    And This solved me the problem. Thanks
     
  32. pujanparikh2209

    pujanparikh2209

    Joined:
    Jun 1, 2019
    Posts:
    1
    god. works 100%
     
  33. artanist

    artanist

    Joined:
    Oct 28, 2014
    Posts:
    15
    I use 2018.4.1 and the problem is still there. Didn't try the workaround, but thanks in advance !
     
  34. peter171

    peter171

    Joined:
    Mar 19, 2019
    Posts:
    1
    2018.4.2f1 same here
     
  35. unnamed7

    unnamed7

    Joined:
    Feb 18, 2016
    Posts:
    3
    This worked for Win10!
     
  36. popyoung

    popyoung

    Joined:
    Apr 3, 2018
    Posts:
    1
    I reset the path to the Android SDK under Preferences/External Tools and problem fixed
     
  37. JonPQ

    JonPQ

    Joined:
    Aug 10, 2016
    Posts:
    82
    I have this problem also with Unity hub 2019.1.9 pro license...
    installed 2019 with droid and iOS support checked. (I also already have android studio installed and previous version of unity 5.6.3p3 installed without Hub) I opened opened project once (selecting Android mode in hub before opening) that worked, but it showed "free" hud, not Pro unity dark Hud, so clicked on "Manage License"... logged in. went back to unity. unity crashed... So I re-launched 2019 from hub. hub now insists I am not licensed to load it in Android mode... even though I am. and already logged in, and It still shows I have droid and ios build support installed.
    If I do as it says, and switch/load in PC standalone mode, now I cannot change to Android mode in settings. I cannot edit any SDK/JDK info as the slots are missing from build settings.
    The "learn" tab trick above does not work.
    restart doesn't work.
    deleting Library folder doesn't work

    any other ideas please ? thanks
    Should I just dump Hub and do a manual install and setup ?

    follow up...
    following day, everything just worked. Assuming unity was having license server issues yesterday.
     
    Last edited: Jul 23, 2019
  38. paranoidAndroid

    paranoidAndroid

    Joined:
    Feb 4, 2013
    Posts:
    3
    Im also getting this on 2018.4.3f1, For some reason it says no android target found, then switches to Standalone, takes around 2 hours to import then I have to switch it back to Android then wait another 2 hours.

    Its a serious issue that really halts development.

    I tried using the cache system, but this always errors out and I have to reimport everything again anyway.. it takes longer as it tries to use the cache before failing.

    Be nice to see things like this fixed before new shiny features are created.
     
  39. Sompol_Rznet

    Sompol_Rznet

    Joined:
    Sep 14, 2018
    Posts:
    20
  40. Keisanwanko

    Keisanwanko

    Joined:
    Jul 19, 2018
    Posts:
    1
    Same thing happened on me. I'm using Win10 and Unity 2018 4.4f1 (64-bit), LTS version.
    Enabling local cache server from Edit > Preferences seems like settling this problem .. as for now ..
     
    Sompol_Rznet likes this.
  41. Sompol_Rznet

    Sompol_Rznet

    Joined:
    Sep 14, 2018
    Posts:
    20
    Another workaround is.

    I just found that when we working and had both Unity and Visual-Studio (2017 for me) running in the same time. If we always close the VS before Unity. This issue would never happen again.
     
  42. miksol31

    miksol31

    Joined:
    Jan 10, 2011
    Posts:
    2
    2018.4.11f1 LTS same here !
     
  43. TJClifton_StickSports

    TJClifton_StickSports

    Joined:
    Aug 20, 2018
    Posts:
    6
    I believe that I have a good repro for this issue. I have noticed that this happens every time after I have been forced to force kill Unity via the Windows Task Manager because Unity has stopped responding. Once it happens there seems to be no way around it other than selecting to switch target and then switching back to android and going through the lengthy process of reimporting assets. All subsequent launches seem to work fine until Unity is force terminated again.

    I really try to avoid force terminating Unity unless I don't have a choice, which is probably good advice anyway for any program. Sometimes you just don't have a choice though (for example Unity frustratingly displayed a blocking popup below my taskbar so couldn't do anything without force quitting the app).

    Nevertheless this issue did not use to be the case on older versions of Unity so I would hope it is something they can resolve.

    Running on Unity 2018.4.4f1/Windows 10
     
  44. igmhero

    igmhero

    Joined:
    Nov 1, 2019
    Posts:
    1
    I used personal version Unity2019. And i same face issue. But I solved
    1. Run Unity Hub
    2. License Management
    3. License Return
    4. New License Activity
    5. Choose Personal
    6. Enjoy
     
    Evst likes this.
  45. charlie128

    charlie128

    Joined:
    May 20, 2017
    Posts:
    1
    It really work,unbelievable....
     
  46. yasir_ksk

    yasir_ksk

    Joined:
    Sep 4, 2019
    Posts:
    1
    Thanks dude. worked :)
     
  47. BryanGrossman99999

    BryanGrossman99999

    Joined:
    Feb 20, 2015
    Posts:
    1
    Just had this happen to me and tjPark solution worked perfectly. THANK YOU!
     
  48. janethorne

    janethorne

    Joined:
    Dec 2, 2015
    Posts:
    10
    This solved my problem. How did you get that bro? Thank you so much
     
    Sompol_Rznet likes this.
  49. Plains

    Plains

    Joined:
    Jun 8, 2015
    Posts:
    1
    Problem still exists in 2018.4.5f1, restarted Unity and it loaded project.
     
  50. tikiwolf

    tikiwolf

    Joined:
    Feb 3, 2020
    Posts:
    1
    I am new to this program, but this 1 year bug/issue, with barely a peep from Unitry, makes me want to try Unreal or Godat that perhaps will export a build.
     
    Ianaa likes this.
unityunity