Xcode 8.3 makes exceptionally large (.ipa) file for Unity IOS Build?

和自甴很熟 提交于 2019-12-21 23:18:54

问题


We have successfully launched our Unity Game in Android, where it is finally making final .apk file of size 28mb. When we exported our product's build to Xcode 8.3 and started making archive for uploading to iTunes Store, it surprisingly responded with a final (.ipa) file of very huge size, that is 160mb.

We tried alternatively after removing the unwanted assets and the made another .ipa file which had a minute effect and reduced the size to 159.4mb.

We are also developers of IOS and WatchKit apps, we know that Xcode is not an ideal tool, and has bugs like encapsulating the original size, but we never experienced such an issue before, as our apps compressed size never went this much high. Average size for our products compressed size has always remained 30-40mb, even the biggest of them.

This game is a 2D game with no such high resolution media, that really could be responsible for such hillarious size. Here we have the report for unity build for IOS:

Secondly, we have this report for the .ipa file made in Xcode.

And finally also the plist with the report of exporting Xcode's .ipa file.


回答1:


There are 3 reasons for this:

1.) Xcode 8.3.0 has a bug that creates larger builds. In our case it was 15% bigger then usual. This has been fixed by Apple in Xcode 8.3.1 and later and Apple now rejects uploading builds created with Xcode 8.3.0.

2.) The size of App Store Builds is bigger than then what the user will download on it device, since it contains all the bitcode variants for each architecture (armv7, armv7s, 64bit) or target device.

Additionally there is a difference between the downloaded compressed file size and the app installation size. Which you can examine after the upload in iTunes Connect under the app > "Activity" Tab and then "All Builds".

In our case the AppStore IPA was 181MB big. The compressed file size 69MB and the installation size 87MB. This ratio between compressed file size and install size, might vary depending how good the compression works on your assets. I had also an case of compressed file size 618MB and installation size of 1.37 GB.

3.) Android does not unzip its APK on installation but read/streams data directly from it without extracting it fully on the filesystem. (see also my answer here on a similar issue)



来源:https://stackoverflow.com/questions/44323860/xcode-8-3-makes-exceptionally-large-ipa-file-for-unity-ios-build

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!