having a hard time getting the whole article to load (weird js errors?), but I got to the point where they had a Hello World app clocking in at 900kB. that is just awful. sure, some people get free data access and have big storage, but almost 1MB per app when there is a common runtime with a huge set of libraries?
I removed the Haskell code and the app was 771KB. Android Studio’s Hello World application bundles 250 images and 131 XML files.
A base of 150KB for the Haskell runtime and base functions is not awful. I expect people won’t be choosing Haskell for writing Hello World applications, but instead for writing large applications where the cost of the runtime size will be amortised.
having a hard time getting the whole article to load (weird js errors?), but I got to the point where they had a Hello World app clocking in at 900kB. that is just awful. sure, some people get free data access and have big storage, but almost 1MB per app when there is a common runtime with a huge set of libraries?
I removed the Haskell code and the app was 771KB. Android Studio’s Hello World application bundles 250 images and 131 XML files.
A base of 150KB for the Haskell runtime and base functions is not awful. I expect people won’t be choosing Haskell for writing Hello World applications, but instead for writing large applications where the cost of the runtime size will be amortised.
So it turns out that the biggest contributor to the 771KB was Android’s appcompat library, which made up about 600KB of it!
I made some changes and got the Haskell application down to 209KB in total:
https://github.com/puffnfresh/eta-android/commit/41b4fce1f63f1896ef0496a52857fbcf28f298ef
Can that 770KB base be stripped down, or is that approximately a floor for Android app size?
Yes, I don’t use almost any of the 250 images in my Hello World application. They can be deleted.
But I haven’t done more than 5 minutes of Android development, so I don’t know the tools. A quick search will be a better resource than I am: https://developer.android.com/topic/performance/reduce-apk-size.html