ceremonyclient/channel/generate.sh
2024-10-12 11:55:17 -07:00

15 lines
439 B
Bash
Executable File

#!/bin/bash
set -euxo pipefail
ROOT_DIR="${ROOT_DIR:-$( cd "$(dirname "$(realpath "$( dirname "${BASH_SOURCE[0]}" )")")" >/dev/null 2>&1 && pwd )}"
RUST_CHANNEL_PACKAGE="$ROOT_DIR/crates/channel"
BINDINGS_DIR="$ROOT_DIR/channel"
# Build the Rust Channel package in release mode
cargo build -p channel --release
# Generate Go bindings
pushd "$RUST_CHANNEL_PACKAGE" > /dev/null
uniffi-bindgen-go src/lib.udl -o "$BINDINGS_DIR"/generated