Can no longer get Unity to Build for android

I am having a major issue on my main machine after upgrading. I can no longer get Unity to build for android apps. I know the SDK and file paths are correct. I even replaced the tools folder in the Android SDK section as suggested after the upgrade. I am at a loss now and about to start using another editor all together.

2 Likes

From the screenshot it looks like you’re using JDK 9. My suggestion is to try and set Unity to use JDK 8 and see if that works.

2 Likes

I switched back to 8 and now get the following error:


1 Like

I think I found the solution:




1 Like

I did get Unity working again for Android. I will say that 2017.# is absolute garbage. If your upgraded version can’t do the fundamentals, then don’t release it. Do you guys even test build functionality before releasing?

Anyways, I installed 5.6.3f1 with JDK 8. I found an old download of Android studio I had from 2016. I copied that over to my new systems and installed it. I had installed the new versions and replaced the Tools folder. That no longer works. I had to do the install of the old version from 2016.

With that setup, Unity is stable, so far…

With JDK 8 and even with the old version of Android, in 2017.# I was getting an error about the gradle or it was telling me there was a Keystore error. 2017.# is, again, garbage. I now have a lot of rebuilding of my projects to do now.

On a positive note, I did download Unreal 4 and started going through the scripting processes, and it seems rather nice. I need to get these next couple projects out with Unity, but I am seriously thinking about moving the rest of our content over to Unreal.

1 Like

I also double checked and keystore with gradle works as well.

If Q&A were capable of finding every single problem before release there wouldn’t need to be a public beta. Unfortunately it’s completely normal for errors to only exist on a relatively few computers because there are limitless combinations of hardware and software. For that matter the solutions are going to be very similar.

I’m downloading the necessary files to see if I can’t replicate the problem on my end and see what my solution would be.

By the way a quick search of the Unreal 4 forums reveals a similar problem for some people there too.

These are build errors. They would have found them if they just hit the build button.

Build errors are dependent on certain criteria. Some people are able to meet that criteria by simply downgrading their JDK installation. If a mere downgrade is able to handle it for some people then it stands to reason the people who already had the correct JDK may have never seen the bug.

Are you telling me that it reasons, that the development team used downgraded components to test an upgraded component?

Just because there is a JDK 9 doesn’t mean JDK 8 is no longer current. Oracle is continuing to release new updates for it with the latest release happening the very same day as the latest release of JDK 9. It’s not a downgrade when everyone is still using it. JDK 9 is brand new and unproven.

This isn’t the only situation where a problem occurs due to JDK 9. There have been others and at least one of them is waiting on a solution by Google.

https://discussions.unity.com/t/679322

By the way, be prepared for disappointment if you like using the latest releases, UE4 uses JDK 8 too. :stuck_out_tongue:

https://docs.unrealengine.com/latest/INT/Platforms/Android/GettingStarted/1/index.html

Please show me any successful Android build with 2017. I haven’t seen one, with any combination of jdk and sdk

Unity 2017.3f3. JDK 8 Update 151. Android Studio 3.0.1 with Android API 27.

https://www.dropbox.com/s/zc654y8da8m08ln/ItJustWorks.zip?dl=0

3337712--260477--BuildSuccessful.jpg

hey there,
i would like to support Thalv with his claims.
i also experience many issues with this. and only after 2 days of work, i understand its not my fault…

i also have downgraded to jdk 8, android studio 3.0.1, unity 2017.3f3, api tools installed 27.
but unity seems to not finding my android sdk folder.

can anyone help with this or should i reinstall 5.6 for a while?

Ryiah , can you explain how did you install the software in order for this to work?

1 Like

did Nvidia CodeWorks really worked for you?

this is what i get

android sdk location:

jdk location:

@shacharoz please PM me, i will help you out

1 Like