Search Issue Tracker
By Design
Votes
0
Found in
2023.2.0a6
Issue ID
UUM-27042
Regression
No
Gradle throws errors when attempting to build APK with 2GB or larger assets
Reproduction steps:
1. Open the attached "BugRepro" project
2. Open the "Assets/Scenes/SampleScene.unity" scene
3. Click File > Build Settings... > Build
Expected results: The project is successfully built
Actual results: The project building proccess stops with the "CommandInvokationFailure: Gradle build failed. " error
Reproduced with: 2020.3.46f1, 2021.3.21f1, 2022.2.12f1, 2023.1.0b9, 2023.2.0a7
Reproduced on: Windows 11 Pro 22H2
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crashes in the wild on Vulkan in CreateDepthSurfaceImpl
- Position and rotation of a GameObject with Rigidbody reset when it is enabled and moved in the same Update call and the frame rate is low
- “Ignoring depth surface store action as it is memoryless” warnings thrown when Capturing new Snapshot while in Play Mode
- Certain textures are not loaded when using the "Load texture data on demand" feature
- [Android][OpenGL] The 2DLight is disproportionately bright on some Android devices when OpenGLES3 is used
Resolution Note:
The "BugRepro" from Google drive has no chance to build, while users provided project builds fine, but I have removed the magic leap packages to build it.
Android .apk file is a zip file and it doesn't support Zip64 extension (https://en.wikipedia.org/wiki/ZIP_(file_format)#ZIP64), so it is limited to 4GB total and each file that's put into it is also limited to 4GB before compression.
If a failure encountered withing these limits, it's best to create an simple project using Android Studio and put asset files to it's asset directory. If that makes it fail to build, the issue is with Gradle or Android Gradle plugin. Given that Play store doesn't allow multi-gigabyte size files to be uploaded, not a big surprise the tools don't support it either.