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
130
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
180
Putting Your APKs on Diet
brijeshmasrani
0
58
What's new in Android N
brijeshmasrani
1
220
Other Decks in Technology
See All in Technology
広告の効果検証を題材にした因果推論の精度検証について
zozotech
PRO
0
190
Amazon Bedrock Knowledge Basesチャンキング解説!
aoinoguchi
0
150
Frontier Agents (Kiro autonomous agent / AWS Security Agent / AWS DevOps Agent) の紹介
msysh
3
180
コスト削減から「セキュリティと利便性」を担うプラットフォームへ
sansantech
PRO
3
1.5k
Webhook best practices for rock solid and resilient deployments
glaforge
1
290
SRE Enabling戦記 - 急成長する組織にSREを浸透させる戦いの歴史
markie1009
0
120
Amazon S3 Vectorsを使って資格勉強用AIエージェントを構築してみた
usanchuu
3
450
予期せぬコストの急増を障害のように扱う――「コスト版ポストモーテム」の導入とその後の改善
muziyoshiz
1
1.9k
超初心者からでも大丈夫!オープンソース半導体の楽しみ方〜今こそ!オレオレチップをつくろう〜
keropiyo
0
110
Kiro IDEのドキュメントを全部読んだので地味だけどちょっと嬉しい機能を紹介する
khmoryz
0
200
SREチームをどう作り、どう育てるか ― Findy横断SREのマネジメント
rvirus0817
0
290
What happened to RubyGems and what can we learn?
mikemcquaid
0
300
Featured
See All Featured
[SF Ruby Conf 2025] Rails X
palkan
1
760
Six Lessons from altMBA
skipperchong
29
4.1k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
640
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
359
30k
Music & Morning Musume
bryan
47
7.1k
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
590
What's in a price? How to price your products and services
michaelherold
247
13k
The Spectacular Lies of Maps
axbom
PRO
1
520
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
730
Crafting Experiences
bethany
1
49
Become a Pro
speakerdeck
PRO
31
5.8k
Paper Plane (Part 1)
katiecoart
PRO
0
4.3k
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