mavlink / rust-mavlink

MAVLink library for Rust.
https://mavlink.github.io/rust-mavlink/mavlink/
Apache License 2.0
158 stars 79 forks source link

Restructure project to enable custom mavlink bindings generation #223

Closed GrahamDennis closed 9 months ago

GrahamDennis commented 9 months ago

The goal of this PR is to enable generating Rust MAVLink bindings from custom MAVLink dialects in new crates. This is done by splitting the project into three crates:

mavlink-bindgen can be used to create MAVLink bindings for Rust, and this is used from build.rs in the mavlink crate to create bindings from the standard MAVLink dialects in https://github.com/mavlink/mavlink.

The mavlink crate is intended to remain API-compatible with the previous structure.

GrahamDennis commented 9 months ago

This now passes all checks in my fork, so is ready for review @patrickelectric . The biggest change here is refactoring the crate into 3 crates in a single cargo workspace (which I think is required to supporting custom dialects). I'm happy to discuss alternative approaches or structures of a cargo workspace. Thanks!

patrickelectric commented 9 months ago

That looks awesome, thanks @GrahamDennis. I'll review asap.

booo commented 9 months ago

This change broke two links in the main README to the examples.