Skip to content

Commit

Permalink
Makefile: make unstripped libtailscale and debug symbols
Browse files Browse the repository at this point in the history
- Added Makefile targets to build an unstripped version of the libtailscale AAR.
- Extracted the native .so (libgojni.so) from the unstripped AAR.
- Generated a debug symbols file (libgojni.so.debug) using llvm-objcopy with --only-keep-debug.
- Stripped the native library (libgojni.so.stripped) with --strip-debug and repackaged the final AAR.

This allows the build chain to produce a stripped AAR for the app and a separate debug symbols file that can be uploaded to Google Play for crash deobfuscation.

Signed-off-by: kari-ts <[email protected]>
Updates tailscale/tailscale#15210
  • Loading branch information
kari-ts committed Mar 6, 2025
1 parent 6a3342e commit 72ac58c
Show file tree
Hide file tree
Showing 3 changed files with 164 additions and 79 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,15 @@ jobs:
- name: Clean
run: make clean

- name: make find-strip-tool
run: make find-strip-tool

# - name: make build-unstripped-aar
# run: make build-unstripped-aar

# - name: make print-aar-contents
# run: make print-aar-contents

- name: Build APKs
run: make tailscale-debug.apk

Expand Down
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,13 @@ tailscale.jks
.vscode
.idea

# Native libraries
*.stripped
*.unstripped

# Debug symbols
*.debug

libtailscale.aar
libtailscale-sources.jar
.DS_Store
Expand Down
Loading

0 comments on commit 72ac58c

Please sign in to comment.