Update Android readme with specific Rust and NDK versions

This commit is contained in:
thunderbiscuit 2023-06-15 10:57:53 -04:00
parent 77f89afc68
commit fe7e4e21c0
No known key found for this signature in database
GPG Key ID: 88253696EB836462

View File

@ -55,18 +55,22 @@ _Note that Kotlin version `1.6.10` or later is required to build the library._
git clone https://github.com/bitcoindevkit/bdk-ffi git clone https://github.com/bitcoindevkit/bdk-ffi
``` ```
2. Follow the "General" bdk-ffi ["Getting Started (Developer)"] instructions. 2. Follow the "General" bdk-ffi ["Getting Started (Developer)"] instructions.
3. If building on macOS install required intel and m1 jvm targets 3. Install Rust (note that we are currently building using Rust 1.67.0):
```shell
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
rustup default 1.67.0
```
4. Install required targets 4. Install required targets
```sh ```sh
rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi
``` ```
5. Install Android SDK and Build-Tools for API level 30+ 5. Install Android SDK and Build-Tools for API level 30+
6. Setup `$ANDROID_SDK_ROOT` and `$ANDROID_NDK_ROOT` path variables (which are required by the 6. Setup `$ANDROID_SDK_ROOT` and `$ANDROID_NDK_ROOT` path variables (which are required by the
build tool), for example (NDK major version 21 is required): build tool), for example (note that currently, NDK version 21.4.7075529 is required):
```shell ```shell
export ANDROID_SDK_ROOT=~/Android/Sdk export ANDROID_SDK_ROOT=~/Android/Sdk
export ANDROID_NDK_ROOT=$ANDROID_SDK_ROOT/ndk/21.<NDK_VERSION> export ANDROID_NDK_ROOT=$ANDROID_SDK_ROOT/ndk/21.4.7075529
``` ```
7. Build kotlin bindings 7. Build kotlin bindings
```sh ```sh
# build Android library # build Android library