Remove the check performed by cargo2rulesmk.py
whether the external/rust/crates/{name} directories
exist for all dependencies of the current crate.
These directories only exist in the Android tree,
not in the minimal checkout inside the redshell sandbox.
Bug: 281857510
Test: cargo2rulesmk.py on thiserror-impl
Change-Id: I1e5d46b4de3129770ab87ebc5e58563010ae6605
The script uses Python match which was introduced
in Python 3.10. The sandbox only has 3.8, so we need
to remove match so the script can run.
Bug: 281857510
Test: Run in sandbox on bitflags crate
Change-Id: Id03b0e02f8593b551f2aca201fe0ed2659d58d21
Add script that generates rules.mk files from Rust crates.
Based on and inspired by cargo2android.py script to generate
blueprint files for the Android build system.
The script has only been tested on the vendored crates used to
build Trusty (see external/rust/crates) and does not support
the full range of crate types or cargo features.
Bug: 281857510
Change-Id: I1951f75476c36b9a1b794c4a51483f2c7387b1f5