Skip to content

fix: stop packaging libsqliteJni.so into Android apps - #1353

Closed
mvanhorn wants to merge 1 commit into
react-native-async-storage:mainfrom
mvanhorn:fix/1327-android-16kb-sqlite
Closed

mvanhorn wants to merge 1 commit into
react-native-async-storage:mainfrom
mvanhorn:fix/1327-android-16kb-sqlite

Conversation

@mvanhorn

Copy link
Copy Markdown

Summary

androidx.sqlite.bundled now sits only in appleMain. The Android module excludes androidx.sqlite:sqlite-bundled and androidx.sqlite:sqlite-bundled-android from shared-storage-android, so libsqliteJni.so is left out of the packaged app. A patch changeset records that the unused bundled SQLite JNI library is no longer shipped on Android.

Android apps that include Async Storage are flagged in Play Console as liable to crash on 16 KB page-size devices. The report names base/lib/arm64-v8a/libsqliteJni.so and base/lib/x86_64/libsqliteJni.so as libraries built with an older NDK. shared-storage declared androidx.sqlite.bundled in commonMain, so the Android variant also resolved androidx.sqlite:sqlite-bundled and sqlite-bundled-android, the artifacts that ship libsqliteJni.so. Async Storage’s Android build exposes shared-storage-android as an api dependency, so that native library is packaged into the app. The bundled driver is only required on Apple.

Fixes #1327

Test Plan

Ran yarn run test:lint locally on macOS for the async-storage change; it fails the same way on the base branch, so the failure predates this change (it fails the same way on upstream/main).
yarn run test:lint stopped before linting because the Yarn install state was missing.

androidx.sqlite.bundled now sits only in appleMain. The Android module
excludes androidx.sqlite:sqlite-bundled and
androidx.sqlite:sqlite-bundled-android from shared-storage-android, so
libsqliteJni.so is left out of the packaged app. A patch changeset
records that the unused bundled SQLite JNI library is no longer shipped
on Android.

Fixes react-native-async-storage#1327
@changeset-bot

changeset-bot Bot commented Oct 14, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 0b40cc3

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@react-native-async-storage/async-storage Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@krizzu

krizzu commented Oct 14, 2026

Copy link
Copy Markdown
Member

bundled sqlite is recommended when using room, for consistency across platforms

also: https://issuetracker.google.com/issues/541852839

@krizzu krizzu closed this Oct 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Android] Your app could crash on 16 KB devices

2 participants