Commit 33e3627
android: strip Go binary via -s -w in gomobile bind
The Android gomobile target was the only ldflags site in the Makefile
not passing -s -w. Every other Go build (line 195, 219, 321, 329) does.
Confirmed via go-size-analyzer that libgojni.so retains gopclntab /
moduledata in the current build despite the NDK linker stripping the
ELF symbol table. Adding -s -w to ANDROID_GOMOBILE_LDFLAGS should
recover ~10-30 MB on the 82 MB libgojni.so for arm64.
This is on top of the arm32 drop + ML Kit unbundle + jniLibs excludes
in the prior commits on this branch — combined we expect APK size
to land somewhere in the ~40-45 MB range from the 93 MB baseline.
Follow-ups still on the table (separate PRs):
1. with_tailscale sing-box tag: pulls in sagernet/tailscale (10K
string occurrences in the binary, single largest contributor).
Client never invokes the tailscale outbound — Headscale plumbing
is server-side bandit fleet only.
2. lantern-water/downloader's magnet:? URL branch pulls in
anacrolix/torrent + btree + dht. Split behind a build tag in
lantern-water (off by default); we only use HTTPS retrieval.
3. with_clash_api / with_acme / with_dhcp: review each — likely
server-side or unused on the client.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 26765ac commit 33e3627
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
120 | 120 | | |
121 | 121 | | |
122 | 122 | | |
123 | | - | |
| 123 | + | |
124 | 124 | | |
125 | 125 | | |
126 | 126 | | |
| |||
0 commit comments