ipa file size issue in Xamarin iOS

前端 未结 1 1929
一生所求
一生所求 2021-01-25 01:00

Yesterday i have created IPA file and it was showing estimated app store size is 100 mb and today i also tried to create IPA but its showing estimated app store size is 525 mb.<

相关标签:
1条回答
  • 2021-01-25 01:26

    Xamarin app sizes are slightly bigger than Objective-C apps as the Mono framework is part of the app bundle.

    The architectures you build for will also increase the app size as a binary will be created for each one - I suggest that you only build for ARMv7 and ARM64, omitting ARMv7s unless you need to utilise the specific optimisations provided with that architecture.

    You can potentially reduce the app size by setting the linker options to link all assemblies in your release configuration. Note that setting the linker to none, as stated in your question, will be detrimental to your app size.

    https://developer.xamarin.com/guides/ios/advanced_topics/linker/#Link_all_assemblies

    Each nuget package added to your project will also increase the size of your app. However, with the use of the linker, the impact of this will depend on how much of the package you are actually using. Anything unused will be stripped out during the linking process.

    You can also reduce your app size by looking at what other assets you have included in your app, such as images, and see if you can save space by making them smaller or increasing compression.

    As a final note, after you upload your app to iTunes Connect, the App Store adds it's own encryption to your app which can significantly increase the overall size. As encryption obfuscates patterns, the resulting compressed app will be larger. The impact varies from app to app. Moving data, such as long strings, or tables, out of code and into external files will make the final download smaller, because those files will be compressed more efficiently.

    0 讨论(0)
提交回复
热议问题