blob: 81a043e4a5610c8858bac9224e282ff66131f9d0 [file] [log] [blame]
#!/bin/bash
# NOTE:
# This script is only used when you want to generate bindings yourself.
# The generated bindings will overwrite grpc-sys/bindings/*
if [ "$ARCH" == "" ]; then
ARCH=`uname -p`
fi
export UPDATE_BIND=1
cargo build -p grpcio-sys --target ${ARCH}-unknown-linux-gnu
rustfmt grpc-sys/bindings/*
if [ "$(uname -s)" == "Linux" ]; then
sed -i '/^pub type .*= ::std::os::raw::.*/d' grpc-sys/bindings/*
fi