Establish a bridge using the cxx crate. The definition is in chronik-ffi/src/ffi.rs, see https://cxx.rs/extern-rust.html and https://cxx.rs/extern-c++.html.
On the C++ side, we expose log_println, which prints a string using LogPrintf. In the future we can add more parameters (like file/line no) and use LogInstance().LogPrintStr.
On the Rust side, we expose setup_bridge, which uses log_println to print a message.
cxx generates the files in a fixed location, and we update the CMake list file to add the generated headers and C++ source files.
Corrosion builds chronik-ffi-static, which we add to the chronik target.
We set the Rust_CARGO_TARGET triplet for Corrosion for known targets, see https://doc.rust-lang.org/nightly/rustc/platform-support.html. All the platform targets from cmake/platforms are supported, except OSX, which has a known issue with the cxx dependency.
Depends on D11862.