2023-06-15 13:53:06 -04:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
|
|
|
set -euo pipefail
|
|
|
|
python3 --version
|
2024-04-01 15:03:57 -04:00
|
|
|
pip install -r requirements.txt
|
2023-06-15 13:53:06 -04:00
|
|
|
|
|
|
|
echo "Generating bdk.py..."
|
|
|
|
cd ../bdk-ffi/
|
|
|
|
cargo run --bin uniffi-bindgen generate src/bdk.udl --language python --out-dir ../bdk-python/src/bdkpython/ --no-format
|
|
|
|
|
|
|
|
echo "Generating native binaries..."
|
2023-11-09 16:17:03 -06:00
|
|
|
rustup default 1.73.0
|
2023-06-15 13:53:06 -04:00
|
|
|
rustup target add aarch64-apple-darwin
|
|
|
|
cargo build --profile release-smaller --target aarch64-apple-darwin
|
|
|
|
|
|
|
|
echo "Copying libraries libbdkffi.dylib..."
|
2023-10-17 12:33:35 -04:00
|
|
|
cp ./target/aarch64-apple-darwin/release-smaller/libbdkffi.dylib ../bdk-python/src/bdkpython/libbdkffi.dylib
|
2023-06-15 13:53:06 -04:00
|
|
|
|
|
|
|
echo "All done!"
|