简体   繁体   English

如何减少我的应用程序的ipa大小

[英]How to decrease ipa size of my App

I am currently working on app there is lot of images. 我目前在app上工作有很多图像。 all images size is near about 130mb. 所有图像大小约为130mb。 While i am creating build then getting 150mb size of ipa. 当我创建构建然后获得150mb大小的ipa。

So my question is . 所以我的问题是。 What should i do for make less then 50mb ipa size.Is there any way to reduce my ipa size. 我该怎么做才能减少50mb以下的ipa尺寸。有什么方法可以减少我的ipa尺寸。

Hope anyone will help me. 希望有人能帮助我。

You can consider app thinning but this would only work on new ios 9 devices. 您可以考虑应用稀疏,但这只适用于新的ios 9设备。 Other ways is to download these images as and when required from the server and don't include everything in the bundle. 其他方法是在需要时从服务器下载这些图像,并且不包括捆绑中的所有内容。

https://developer.apple.com/library/tvos/documentation/IDEs/Conceptual/AppDistributionGuide/AppThinning/AppThinning.html https://developer.apple.com/library/tvos/documentation/IDEs/Conceptual/AppDistributionGuide/AppThinning/AppThinning.html

Refer https://developer.apple.com/library/ios/qa/qa1795/_index.html 请参阅https://developer.apple.com/library/ios/qa/qa1795/_index.html

Mostly check your assets and architectures you are supporting with. 主要检查您支持的资产和架构。 Also if your application is targeting iOS 8 and higher, you can remove 1x images from assets. 此外,如果您的应用程序的目标是iOS 8及更高版本,则可以从资产中删除1x图像。 Also, replace your launch images with launch storyboard xib file. 此外,使用启动故事板xib文件替换启动映像。

If you are iOS8+ go to your architectures, change it from "Standard (armv7s, arm64)" to "other" and just use arm64. 如果您是iOS8 +转到您的架构,请将其从“标准(armv7s,arm64)”更改为“其他”并使用arm64。

Every device from iPhone5s and beyond supports arm64. iPhone5及更高版本的每台设备都支持arm64。

So you'll just be missing out on iPhone4, iphone5(/c), iPad4 users, etc. For us this was less than 2% of our total users and was worth it because.... removing the armv7s arch from our app decreased the app size by 20MB when we exported it to ITC. 因此,你只会错过iPhone4,iphone5(/ c),iPad4用户等。对于我们来说,这不到我们总用户的2%并且值得,因为......从我们的应用程序中删除了armv7s拱门我们将应用程序大小导出到ITC时减少了20MB It just optimizes solely on arm64 now. 它现在只是在arm64上进行优化。

This allowed our other 98% of users to be able to download updates (or the app itself) without a Wifi connection which increased our total installs and well made up for the lost 2% of out-dated users. 这使我们其他98%的用户能够在没有Wifi连接的情况下下载更新(或应用程序本身),从而增加了我们的总安装量,并且为失去的2%的过时用户做好了准备。


For reference here is a compatibility chart: 这里有一个兼容性图表供参考: 在此输入图像描述

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM