-
Notifications
You must be signed in to change notification settings - Fork 67
Description
hi folks,
playing with building wasm components and it seems the current approach requires one to run cargo component bindings
to generate a src/bindings.rs
file, which then has to be committed into the repository for whatever component (and re-committed on any changes).
a more common/rusty way to do this that avoids generated files being included in the source tree would be to invoke the binding generation from build.rs
then import the generated bindings (like bindgen
does).
have you considered supporting this approach? i see adding build.rs
support was discussed in #362 but not actioned. it seems like generating the bindings from build.rs
should be straightforward, then cargo component
would need to pick up a flag or something to say that it shouldn't generate bindings itself.
cheers,
ryan