-
Notifications
You must be signed in to change notification settings - Fork 21
Generate ctru-sys as part of the build system #47
Comments
Actually, I didn’t see it was already generated, my request then is to make it automated as part of the build system, or at least documenting how to update it. |
IIRC we opted for generating them only when needed to stay in sync with a specific libctru release. I have a script for citro3d-sys to generate bindings, which I will probably port over for libctru-sys. It might even make sense to use some sort of Rust task runner like |
It was exactly for citro3d that I wanted to use this. :) |
citro3d is a bit of a pain to port to safe Rust, but I intended to at least release a sys crate |
Here you go: https://github.com/rust3ds/citro3d-sys I didn't manage to verify that the crate still builds properly because ctru-rs doesn't build for me right now and I have no time to figure out why. |
For the record, this is the build script I used to generate ctru-sys locally last time I updated it: https://github.com/FenrirWolf/ctru-rs/blob/bindgen/ctru-sys/build.rs We definitely could generate the bindings at build-time by default instead of checking them in manually, but the trade-off there is that running bindgen increases compile times and adds a dependency on clang. |
…ad-file-contents Add support for reading files to file-explorer
Have a look at rust-bindgen, it can create -sys crates automatically from headers, which will alleviate a good part of your work.
The text was updated successfully, but these errors were encountered: