Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Controlling APK Size When Using Native Library
Search
Brijesh Masrani
July 02, 2017
Technology
0
96
Controlling APK Size When Using Native Library
Brijesh Masrani
July 02, 2017
Tweet
Share
More Decks by Brijesh Masrani
See All by Brijesh Masrani
Let's Stream that Video - an ExoPlayer Starters Guide
brijeshmasrani
0
130
Putting Your APKs on Diet
brijeshmasrani
0
52
What's new in Android N
brijeshmasrani
1
210
Other Decks in Technology
See All in Technology
Azure犬駆動開発の記録/GlobalAzureFukuoka2024_20240420
nina01
1
210
Kernel MemoryでAzure OpenAI Serviceとお手軽データソース連携
mitsuzono
1
250
反実仮想機械学習とは何か
usaito
PRO
11
4.6k
地理空間データ可視化・解析・活用ソリューション Pacific Spatial Solutions (PSS)
pacificspatialsolutions
0
280
本当のAWS基礎
toru_kubota
0
520
LayerXにおけるLLMプロダクト開発の今までとこれから
layerx
PRO
1
300
DevOpsメトリクスとアウトカムの接続にトライ!開発プロセスを通して計測できるメトリクスの活用方法
ham0215
2
240
Compose Compiler Metricsを使った実践的なコードレビュー
tomorrowkey
1
220
レガシーをぶっ壊せ。AEONで始めるDevRelの話 / Qiita Night 2024-2-22
aeonpeople
3
1.3k
LLM開発・活用の舞台裏@2024.04.25
yushin_n
1
270
Azureの基本的な権限管理の勉強会
yhana
0
490
On Your Data を超えていく!
hirotomotaguchi
2
690
Featured
See All Featured
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
21
1.6k
Art, The Web, and Tiny UX
lynnandtonic
289
19k
Web Components: a chance to create the future
zenorocha
305
41k
A Tale of Four Properties
chriscoyier
151
22k
Writing Fast Ruby
sferik
621
60k
The Invisible Side of Design
smashingmag
294
49k
Teambox: Starting and Learning
jrom
128
8.4k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
125
32k
What's new in Ruby 2.0
geeforr
337
31k
The World Runs on Bad Software
bkeepers
PRO
61
6.7k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
6
1.5k
A Modern Web Designer's Workflow
chriscoyier
689
190k
Transcript
Controlling APK Size When Using Native Library
I am Brijesh Masrani @
Outline • What are the major components in APK? •
APK Splitting • What is ABI and how it works? • Understanding ABI in detail • Problems with ABI split • Solving Issues with abiFilters
What are the major components in APK? • Class files
• Resources • Manifest file • Native libraries
APK Splitting Density and Application Binary Interface (ABI)
Application Binary Interface • The ABI defines, with great precision,
how an application’s machine code is supposed to interact with the system at runtime. • You must specify an ABI for each CPU architecture you want your app to work with. • mips, mips64, X86, X86–64, arm64-v8a, armeabi, armeabi-v7a
Analysis of the APK file
APK details after adding Realm
None
Realm distribution for different CPU architecture
Realm adds .so file for 5 CPU architectures mips, X86,
X86–64, armeabi-v7a, and arm64-v8a this increases the apk size by 4.8 MB; remaining ~130KB is increased in dex size.
ABI split
None
Multiple APK files generated after enabling split
None
Amazing right! We went from 74KB to 5MB and came
back to 1.3 MB. But But But….
NDK abiFilters
APK with “armeabi-v7a” and “x86” libs
TL;DR — Detail about CPU Architecture
Google Maps with ABI filters
None
Thank You You can find me at @brijeshmasrani