You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add docs for multiple native lib architectures insight (#15569)
## DESCRIBE YOUR PR
Adds documentation for the new Android multiple native library
architecture splits insight.
## IS YOUR CHANGE URGENT?
Help us prioritize incoming PRs by letting us know when the change needs
to go live.
- [ ] Urgent deadline (GA date, etc.): <!-- ENTER DATE HERE -->
- [ ] Other deadline: <!-- ENTER DATE HERE -->
- [X] None: Not urgent, can wait up to 1 week+
## PRE-MERGE CHECKLIST
*Make sure you've checked the following before merging your changes:*
- [ ] Checked Vercel preview for correctness, including links
- [ ] PR was reviewed and approved by any necessary SMEs (subject matter
experts)
- [ ] PR was reviewed and approved by a member of the [Sentry docs
team](https://github.com/orgs/getsentry/teams/docs)
Resolves EME-644
Copy file name to clipboardExpand all lines: docs/platforms/android/size-analysis/insights.mdx
+24Lines changed: 24 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,6 +18,7 @@ Below are a list of available insights for Android builds, followed by more deta
18
18
|[WebP Optimization](#webp-optimization)| Tests PNG/JPEG bitmaps to see if lossless WebP would shrink them. |
19
19
|[Large Audio](#large-audio)| Surfaces hefty audio tracks that could be recompressed or trimmed. |
20
20
|[Hermes Debug Info (RN Only)](#hermes-debug-info-rn-only)| Points to bundled Hermes bytecode still carrying debugger metadata. |
21
+
|[Multiple Native Library Architectures](#multiple-native-library-architectures)| Detects when multiple native library architectures are packaged in an APK. |
21
22
22
23
### Duplicate Files
23
24
@@ -106,3 +107,26 @@ You can tweak the bitrate (`b:a`) to balance quality vs. size. Higher bitrates (
106
107
**What it is**: Detects Hermes bytecode bundles that still contain debug info sections.
107
108
108
109
**How to fix**: Build the React Native bundle in release mode (`react-native bundle --dev false` or the Gradle release task) so Hermes strips debug sections before packaging.
110
+
111
+
### Multiple Native Library Architectures
112
+
113
+
**What it is**: Detects when multiple native libraries are packaged in an APK supporting different architectures. End user devices will only use one architecture (usually arm64_v8a), so most can be removed.
114
+
115
+
**How to fix**: Upload an AAB to the Play Store (Google will automatically pass the architecture the end user needs). We also recommend you upload an AAB for size analysis.
116
+
117
+
If you ship an APK, the `split {}` block can be used to output split APKs manually. If configured to skip ABI splits, Android will package all native library architectures into the main split.
118
+
119
+
Ensure your split Gradle dls config has the `isEnabled = true` field set for the `abi {}` block.
120
+
121
+
```kotlin
122
+
android {
123
+
splits {
124
+
..
125
+
126
+
abi {
127
+
isEnabled.set(true)
128
+
}
129
+
}
130
+
}
131
+
```
132
+
More information about the ABI configuration for manual APK splits can be found in the [Android developer documentation](https://developer.android.com/studio/build/configure-apk-splits#configure-abi-split).
0 commit comments