Android builds with Unity 6.3 LTS still feel incomplete when building on Apple silicon, only at least for now!

Although the difference between Unity 6.0 LTS and Unity 6.3 LTS is similar, there is still a lot of issues when building for android with Unity 6.3 LTS! My gradle configuration with ED4MU looks correct to me and android builds still succeed, but the problem with that is that some packages built with the APK are not packaged correctly! The one advantage of Unity 6.3 LTS for that is that image textures now scale correctly! I still get some missing java classes! I believe there is a bit of a conflict between apple silicon running macOS and unity android toolchain system on apple silicon specifically for unity! I do not get that same issue at all when building for flutter android apps on apple silicon!

This build would not be acceptable to deploy to the Google Play store because Google play requires complete builds to deploy to Google Play store! My android build does not behave like in the editor because it misses some optimisations that I applied to my project and the missing java classes are actually necessary for users to enjoy the experience!

Has anybody else also experienced this issue? Explain why only if you want!

I don’t think Google Play accepts APKs anymore does it? I thought it all had to be AABs nowadays…

If you just have build errors, this is my cribsheet:

How to troubleshoot build failures:

Obviously, if there is actionable data, clues or information within any of the errors, fix those problems. Each error entry may have more information than can fit in the console log so select each error and read the expanded view below it.

If that gives you nothing worthwhile (look to Google! You’re never the first one!), then…

First, make a blank project with a single blank scene and prove that it builds successfully.

If the blank project does NOT build, go fix your Unity installation or your other tools, such as Android SDK, NDK, JDK, etc. It may even be necessary to change to a different version of Unity3D. It is generally best to stay with LTS versions of Unity3D.

Until you can build a blank project to the target platform, don’t fiddle with anything else.

Once you can build a blank project, now bisect the problem by bringing over parts of your current project and building it one subsystem at a time, perhaps stubbing things out that might trigger compiler errors.

Most often things that prevent building are misconfigured or incorrectly-installed or incompatible third-party libraries such as Firebase or AdMob or IronSource.

Once you identify the subsystem, go to the documentation for it and make sure you are doing it correctly.

It may also be helpful to work through a tutorial or two for whatever subsystem is making the build fail.

Android build not building:

Circa July 2022 here have been reports of Unity’s installer failing to install the Android Tools.

Here was how I brought up Unity2020.3.41 and the Android SDK 31 on October 30, 2022 (edited on August 23, 2023 to include Android SDK 33…) (and again for SDK34):

And for Android SDK35, my own experiences and success:

After the Unity-CVE incident I installed Unity2022.3.62f2 and also Android SDK36 and … IT JUST WORKED! I did remove all previous Android SDKs before doing that though.

Android Gradle errors and other related stuff:

More Android SDK35 stuff:

Thank you for the advice!
Firebase is compatible with Unity but I used it what Unity expects like including all necessary firebase plugins and i used firebase packages that are compatible with unity sdk! I did the same thing on iOS and it just worked fine without missing functionality! I use the correct sdk, jdk, ndk and gradle versions what unity expects! I used ndk 27c (not with unity’s built in one because this x86_64 version that comes built in is not compatible with arm) and sdk, jdk and gradle come with correct versions required! I build with compile sdk 35 and build tools 35.0.1! I mean i tried with Unity 6.0 LTS earlier and even without firebase it still has missing classes! I am already on the latest versions of Unity which I use is Unity 6.3 LTS! I could believe that blank projects work fine but it is only as your project gets more complex and has more assets, the more missing classes it contains!

I previously used the wrong agp for gradle 8.13 which i previously used agp 8.1.2 and just changed it to agp 8.10.0 and still did not resolve the issue! I believe that is because some parts of the unity engine still require rosetta, especially for android toolchain to work properly but it still contains missing classes!