... | ... | @@ -54,7 +54,7 @@ After you attach the debugger, it should catch the crash and you can inspect the |
|
|
|
|
|
### Swapping components within the app
|
|
|
|
|
|
Often injecting and/or swapping certain components/dependencies/libraries within the app is useful. For example, you may want to build a `debug` variant apk [locally](https://gitlab.torproject.org/tpo/applications/tor-browser/-/wikis/Hacking/Hacking#building-android-tor-browser) but the bug/crash only manifests in a `build `libxul.so` produced in `tor-browser-build`.
|
|
|
Often injecting and/or swapping certain components/dependencies/libraries within the app is useful. For example, you may want to build a `debug` variant apk [locally](https://gitlab.torproject.org/tpo/applications/tor-browser/-/wikis/Hacking#building-android-tor-browser) but the bug/crash only manifests in a `build `libxul.so` produced in `tor-browser-build`.
|
|
|
|
|
|
How do?
|
|
|
|
... | ... | @@ -82,7 +82,7 @@ $ zip app/build/outputs/apk/debug/app-armeabi-v7a-debug.apk lib/armeabi-v7a/libx |
|
|
$ cp app/build/outputs/apk/debug/app-armeabi-v7a-debug.apk ./app-armeabi-v7a-debug.apk && zip -qr app-armeabi-v7a-debug.apk assets/ && ~/.mozbuild/android-sdk-linux/build-tools/31.0.0/zipalign -vp 4 app-armeabi-v7a-debug.apk app-armeabi-v7a-debug-unsigned.apk && ~/.mozbuild/android-sdk-linux/build-tools/31.0.0/apksigner sign --verbose --min-sdk-version 17 --ks /home/android/tor-browser-build/projects/tor-browser/android-qa.keystore --out app-armeabi-v7a-debug-qa.apk --in app-armeabi-v7a-debug-unsigned.apk --ks-key-alias androidqakey --key-pass pass:android --ks-pass pass:android
|
|
|
```
|
|
|
|
|
|
(This assumes following the steps in [Building Android Tor Browser](https://gitlab.torproject.org/tpo/applications/tor-browser/-/wikis/Hacking/Hacking#building-android-tor-browser).)
|
|
|
(This assumes following the steps in [Building Android Tor Browser](https://gitlab.torproject.org/tpo/applications/tor-browser/-/wikis/Hacking#building-android-tor-browser).)
|
|
|
|
|
|
Alternatively, you can modify the build process(es) within `tor-browser-build`.
|
|
|
|
... | ... | |