As a Rust driver crate developer, I would like to perform below steps during my crate installation/download when used by any other Rust program:
I know this is possible in Node or Python or R but not sure if this is possible in Rust.
You can use Build script to achieve that (but it is not what you should do, please see note below).
The script will be compiled and executed before cargo start building your library.
IMPORTANT NOTE
Most of Rust users doesn't expect that kind of behavior from build script. There may be dozen of problems with the approach. Just few of them from the top of my head:
I believe it's better to upload all binaries you need as a part of the crate. You can use include_bytes! for that.