Skip to content

Conversation

@jmartinesp
Copy link
Contributor

@jmartinesp jmartinesp commented Feb 2, 2026

Changes:

  • Adds a new dist profile that can be used by the bindings to generate library versions with optimised binary size. This was specially a pain point for Android: with this config and some debug symbol stripping, the library size is now 50-70MB smaller per architecture, resulting in very significant file size reduction for universal APKs, which have 4 archs.
  • Also create new reldev profile for FFI bindings consumers that allows having way smaller binaries while still being able to have proper backtraces: reldbg is great for iOS because it allows inline debugging using LLDB in Xcode, but it produces enormous binaries (last I checked was 1.25GB), while for Android we can't use that properly and we'd only be interested in having symbolicated backtraces, which this profile achieves with binaries an order of magnitude smaller.

I'm aware reldev is quite easy to mistake wirh reldbg, so I'm open to finding a better name for it 😅 .

  • Public API changes documented in changelogs (optional)

Signed-off-by:

@codspeed-hq
Copy link

codspeed-hq bot commented Feb 2, 2026

Merging this PR will not alter performance

✅ 50 untouched benchmarks


Comparing misc/customise-release-profile (a127ed6) with main (40c6c33)

Open in CodSpeed

This is intended for reducing the binary size of the SDK distributed in Android/iOS bindings.

Its optimization level is 'binary size', it contains LTO optimizations and by default removes part of the debug info - the rest can be removed later if needed.
This makes it possible to link a Sentry trace to the debug symbols so it can be symbolicated
@jmartinesp jmartinesp force-pushed the misc/customise-release-profile branch from 79ab3d0 to fe67c20 Compare February 3, 2026 13:02
@jmartinesp jmartinesp changed the title refactor: Remove debuginfo for reldbg and release profiles ci: Add a dist profile with optimised binary size Feb 3, 2026
@codecov
Copy link

codecov bot commented Feb 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.84%. Comparing base (40c6c33) to head (a127ed6).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6101      +/-   ##
==========================================
- Coverage   89.84%   89.84%   -0.01%     
==========================================
  Files         363      363              
  Lines      100638   100638              
  Branches   100638   100638              
==========================================
- Hits        90420    90418       -2     
- Misses       6690     6692       +2     
  Partials     3528     3528              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

It allows having way smaller binaries while still being able to have proper backtraces: `reldbg` is great for iOS because it allows inline debugging using LLDB in Xcode, but it produces enormous binaries, while for Android we can't use that properly and we'd only be interested in having symbolicated backtraces, which this profile achieves with binaries an order of magnitude smaller.
@jmartinesp jmartinesp marked this pull request as ready for review February 3, 2026 19:05
@jmartinesp jmartinesp requested a review from a team as a code owner February 3, 2026 19:05
@jmartinesp jmartinesp requested review from Hywan and removed request for a team February 3, 2026 19:05
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.

2 participants