Is Android 14 supported as a build target in Unity 2020 and 2021 ?
I have tried building an empty project in Unity 2020.3.30f1 and Unity 2021.3.32f1 targeting Android API level 34. Both builds can be installed on an Android 14 device, but crash immediately when opened. There are no errors or stacktrace logged, only "D Unity : CommandLine: ".
The same project in Unity 2022.3.13f1 does run without issue.
In each test used the unity-provided Android SDK+NDK and OpenJDK.
Is there a way of making this work in Unity 2020 ? For context, our game is currently using version 2020.3.30f1, and upgrading to a more recent version of the editor is a significant amount of work for our team as we have developed a number of tools and dependencies that would need to be updated.
Unity has bugs with SDK 34 even though frustratingly there isnât a clear document somewhere telling us what SDKs are compatible with Unity or not.
Since Unity is dragging their feet with matters like this one, expect Unity to work âokay-ishâ with SDK 34 after Google makes it a requirement, not before.
?
Quoting:
âAll cases of broadcast receivers being registered within Unity code have been fixed or handled
If anyone is still able to reproduce in a project without any third-party libraries or plugins, we will be able to investigate furtherâ
Please can someone more skilled than me in Android gruesome details tell me what I should do?
The link in the issue tracker send me to code that doesnât make any sense to me. Where should I write this? I use some plugins, do I have to unpack them? No clue.
Did you try updating Unity to one of the versions it was fixed âFixed in 2021.3.33f1, 2022.3.13f1, 2023.1.20f1, 2023.3.0a11â, and see if that fixes the crash?
Not yet, I read this forum post: https://discussions.unity.com/t/937436
And Iâm very afraid to update because I use Google Play with their plugin and I fear creating problems for the hundreds of users who already have it.
Moreover a few users commented on the bug fix like this: âStill happening on 2021.3.33f1â
I wondered also if this change means every plugin provider should update its plugins and what to do for discontinued ones.
In https://issuetracker.unity3d.com/issues/android-targetapi-34-crash-on-launch case, the issue with broadcast receivers was fixed in Unity core, if any plugins out there had bad broadcast receiver code on their end, then those plugins need to fix that on their end. It all depends on from where the issue originates.
If thatâs the case, most likely itâs a different issue, a bug report would be required. But our QA tested projects against API level 34, and it worked fine.
Saying itâs the same issue without any logs, gives too much room for guessing.
I installed version 2021.3.33f1, I had a problem updating the SDK to 34, I had to copy the files to another repository, after managing to generate the file to publish on the play store the error persisted, Android 14 closes every time I open the game and asks to clear cache.
I donât know what else to do, I did everything I could, if anyone finds a solution please post it, it will help a lot of people.
Hey folks, please send reproduction projects so we can investigate any issues.
Weâve updated Unity versions in the last months (from 2021+) as Tomas states above to make them compatible with API 34. Third-party plugins may need to do some work on their end as well.
Targeting API 33 is a temporary solution.
If you are targetting the Google Play Store, usually Google requires that new & updated apps target the latest API by August of next year since the API release. This means that API 34 will very likely be required to submit updates post-August 2024. Last year an extension was granted to November 2023. Google has not yet announced this yearâs deadlines.
Execution failed for task â:launcher:bundleReleaseResourcesâ.
A failure occurred while executing com.android.build.gradle.internal.res.Aapt2ProcessResourcesRunnable
AAPT2 aapt2-4.2.1-7147631-windows Daemon #0: Unexpected error during link, attempting to stop daemon.
This should not happen under normal circumstances, please file an issue if it does.