-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add some Rust library building infrastructure #16833
Conversation
Rebased to track #16274 |
@kaspar030, are you happy with the adjustment? Rerunning tests given the failed one looks like a glitch (being unrelated and not having failed in other recent runs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK.
Please squash! |
Thanks! Squashed.
In removing the "REMOVE ME" commits, I split one of them (the one that
made the rust-gcoap example use other Rust modules) off and kept half of
it as the now most recent commit: With how the rust_riotmodules
developed since those lines were written, it's now best to just use the
riot_rustmodules crate all the time (the usual no-op has no deployment
impact), as to tolerate any Rust-written RIOT modules that might be
activated as they come in (eg. if saul_default gains support for a
board's sensor).
While murdock is working this off, I'll run another round of self-review
whether everything that's in the commits is still in the righ place, and
still makes sense.
|
Updated again to fix some commit wordings, and documentation typos or misreferences. |
Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
It is enabled by saul_default on microbit-v2. Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
Taken and simplified from shell test.
Of all the library crates, this is the only root crate, and responsible for pinning good versions.
Builds and tests passed [edit: I hope the link is right -- I lost the original link, reconstructed the URL, and that was the commit that was tested]. I missed squashing after the latest fixup I mentioned in #16833 (comment) (e4279bd). Squashing that in and skipping builds/tests due to the pre- and post-squash having identical tree hashes. |
Nice! |
Contribution description
Building on #16274 this adds a single module that can encapsulate arbitrarily many Rust-based modules.
It's
heavily WIP, and will be rebased, but the core idea is something that I already want to have discussable:Note that Rust-only modules have little options to be usable, as otherwise they won't be called into:
extern int module_setup(void);
to wherever in the init system they need to be called initially. (Personally I'd discourage that in favor of XFA.)Testing procedure
It's not a full test, but it's a good one:
$ make BOARD=microbit-v2 -C examples/saul all flash term
TBDIt's all a bit rough so far...but these items are still open:
Issues/PRs references
This is based on #16274,
and will be rebased onto that. Only look at the commits not on that other PR, currently it's the last one only.[edit: testing procedure]