Skip to content

fix: Return all intersecting ABIs instead of just one#11

Merged
MatrixDev merged 1 commit intoMatrixDev:mainfrom
xz-dev:gradle8-abi-fix
Nov 19, 2025
Merged

fix: Return all intersecting ABIs instead of just one#11
MatrixDev merged 1 commit intoMatrixDev:mainfrom
xz-dev:gradle8-abi-fix

Conversation

@xz-dev
Copy link
Copy Markdown
Contributor

@xz-dev xz-dev commented Nov 19, 2025

The original logic had a critical bug: even when multiple ABIs were in the intersection, it would only return a single ABI based on priority (arm64 > x86_64 > first). This caused APKs to only contain one architecture's native libraries, leading to 'library not found' errors on other architectures.

Changes:

  • Return all intersecting ABIs instead of selecting one
  • Add disableAbiOptimization option for full control
  • Properly pass extension parameter to resolveAbiList

This maintains IDE optimization (only build what's needed for deployment) while ensuring all necessary architectures are built.

Fixes: #3

The original logic had a critical bug: even when multiple ABIs were in
the intersection, it would only return a single ABI based on priority
(arm64 > x86_64 > first). This caused APKs to only contain one
architecture's native libraries, leading to 'library not found' errors
on other architectures.

Changes:
- Return all intersecting ABIs instead of selecting one
- Add disableAbiOptimization option for full control
- Properly pass extension parameter to resolveAbiList

This maintains IDE optimization (only build what's needed for deployment)
while ensuring all necessary architectures are built.

Fixes: #3
Copy link
Copy Markdown
Owner

@MatrixDev MatrixDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good.

@MatrixDev MatrixDev merged commit 788dbe1 into MatrixDev:main Nov 19, 2025
@MatrixDev
Copy link
Copy Markdown
Owner

@xz-dev, thank you for your contributions. these changes were very good.

Both of your pull requests have been included in the 0.5.0 release.

@xz-dev xz-dev deleted the gradle8-abi-fix branch November 20, 2025 00:59
rodroidmods pushed a commit to rodroidmods/GradleAndroidRustPlugin that referenced this pull request Jan 8, 2026
The original logic had a critical bug: even when multiple ABIs were in
the intersection, it would only return a single ABI based on priority
(arm64 > x86_64 > first). This caused APKs to only contain one
architecture's native libraries, leading to 'library not found' errors
on other architectures.

Changes:
- Return all intersecting ABIs instead of selecting one
- Add disableAbiOptimization option for full control
- Properly pass extension parameter to resolveAbiList

This maintains IDE optimization (only build what's needed for deployment)
while ensuring all necessary architectures are built.

Fixes: MatrixDev#3
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.

filter out x86_64 so will fail Run for x86_64 emulator

2 participants