Skip to content
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

cargo component build always produces a bindings.rs file #314

Closed
yoshuawuyts opened this issue Jun 28, 2024 · 1 comment · Fixed by #318
Closed

cargo component build always produces a bindings.rs file #314

yoshuawuyts opened this issue Jun 28, 2024 · 1 comment · Fixed by #318

Comments

@yoshuawuyts
Copy link
Member

I've been working on a number of projects which just directly pull the wasi crate, but don't do anything with a local wit/ directory. This produces a src/bindings.rs file, despite not actually ever being used. This can be a little confusing for people trying to read the code, because there is currently always an unused but important-sounding file sitting in the project hierarchy.

Can we make generating this file conditional on, say, whether there is a local wit/ directory present?

@iawia002
Copy link
Contributor

iawia002 commented Jul 4, 2024

I also encountered the same problem. If I did not have wit files, cargo component still generated the bindings for me, and its content actually made no sense. I'll submit a PR for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants