This diff introduces CMake file with functions to integrate Rust library code into CMake project using Corrosion and CXX.
Inspired by the https://github.com/trondhe/rusty_cmake but with the following modifications:
- Windows-related code was removed.
- Automatically detect Rust target architecture using `detect_cargo_target_architecture` function.
The purposes of functions:
- `detect_cargo_target_architecture`: Detecting the current Cargo architecture by invoking `rustc` command.
- `_get_stem_name_of_path`: Get the last part of the provided Rust library sources path to use it as a library name.
- `add_library_rust`: Running corrosion and integrating CXX headers and bindings.
Related Linear task: [[ https://linear.app/comm/issue/ENG-1438/consider-using-cxx-instead-of-unsafe-in-rust | ENG-1438 ]]