Why is my app 5 MB larger in the App Store?

The downloaded zip file is 19.5 MB, but Apple reports it as 24.5 MB in the App Store - too large to be downloaded over the air. Is Apple adding a 5 MB wrapper? Is decompression and re-compression less efficient? Using 815K megabytes?

+4
source share
2 answers

From Apple:

When your application is approved Apple sells on the App Store, it is encrypted for DRM purposes and re-compressed. When encryption is added, the size of the compressed file will increase. The exact size increase will vary from application to application, however the size increase can be large when the binary contains many continuous zeros. We cannot guarantee the size of your file after encryption is added.

+12
source

Download the app from the App Store using iTunes. You should get .ipa in ~/Music/iTunes/Mobile Applications , which (hopefully) roughly matches what you get from the App Store. Check its size. You can additionally use something like unzip -Z myapp.zip to check the compressed size of individual files (.ipa is just .zip).

If, as in FreeAsInBeer, your executable compressed size increases the load, then maybe you should try to fix it (5 MB is a lot of code). Compiling with -Os can be useful.

Also note that .ipa will have additional information, namely iTunesArtwork (from the App Store app icon to 512x512) and iTunesMetadata.plist (which has things like the App Store category) and some FairPlay data. I'm not sure which ones are being sent to the device.

Finally, Apple can use M = 10 6 instead of 2 20 - 19.5 x times 2 20 ≈ 20.4 x times 10 6 . IIRC was one of the changes to Snow Leopard.

+2
source

Source: https://habr.com/ru/post/1343220/


All Articles