Install dependencies for Chronik: Rust and Corrosion
Summary:
- Rust is installed the recommended way via command line (see rustup.rs)
- Corrosion source is downloaded from GitHub, built and installed (see corrosion build instructions https://github.com/corrosion-rs/corrosion#installation)
Test Plan:
On a Linux machine with docker:
- docker run -i -t bitcoinabc/bitcoin-abc-dev
- Run the commands added in this diff -> installs Rust and Corrosion successfully
- source $HOME/.cargo/env
- cargo --version results in version 1.61
- Test against experimental Chronik impl on GitHub: git clone https://github.com/raipay/bitcoin-abc.git && cd bitcoin-abc && git checkout chronik && mkdir build && cd build && cmake .. -GNinja -> Successfully run Corrosion and calls Rust
- ninja -> successfully builds bitcoind
- ./src/bitcoind -regtest -> runs Chronik, shows "Got BlockConnected 0f9188f13cb7b2c71f2a335e3a4fc328bf5beb436012afca590b1a11466e2206" and "Added block 0f9188f13cb7b2c71f2a335e3a4fc328bf5beb436012afca590b1a11466e2206 with 1 txs, height 0" in stdout
Reviewers: Fabien, #bitcoin_abc
Reviewed By: Fabien, #bitcoin_abc
Differential Revision: https://reviews.bitcoinabc.org/D11663