-
Type:
Bug
-
Resolution: Works as Designed
-
Priority:
Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: None
What happened?
My previous Flutter app takes about 63 MB in apk release build.
After import Realm, the apk file size become 131 MB, which is double from before.
By unpack the release package. It turns out that Realm include binary files for all the target platform.
By default, flutter only build for android-arm, android-arm64 and android-x64. But realm also include android-x86 binary files. Which takes 18.6MB extra space.
Here is another example , which only target android-arm64 when build:
So please make realm package follow the flutter --target-platform, this will save a lot of space for release build apks.
Thank you.
Repro steps
- Use any Flutter project which import realm.
- Build android apk, use -
target-platformor -split-per-abi. - Unpack the generate apks. Check the realm binary files inside apk.
Version
3.19.5
What Atlas Services are you using?
Local Database only
What type of application is this?
Flutter Application
Client OS and version
macOS 13.6
Code snippets
No response
Stacktrace of the exception/crash you're getting
No response
Relevant log output
No response