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

vello_shaders causes recompilation #569

Closed
waywardmonkeys opened this issue May 6, 2024 · 1 comment · Fixed by #570
Closed

vello_shaders causes recompilation #569

waywardmonkeys opened this issue May 6, 2024 · 1 comment · Fixed by #570

Comments

@waywardmonkeys
Copy link
Contributor

Now that we use vello_shaders, it causes rebuilds on every run of cargo build / cargo run / etc.

This is due to crates/shaders/build.rs unconditionally writing out the new shader file:

std::fs::write(dest_path, &buf).unwrap();

This needs to only write it if it has changed.

cc: @armansito

@waywardmonkeys waywardmonkeys added this to the Vello 0.2 release milestone May 7, 2024
@waywardmonkeys
Copy link
Contributor Author

The issue is much easier than that. PR coming momentarily.

waywardmonkeys added a commit to waywardmonkeys/vello that referenced this issue May 7, 2024
The dependency on the `shader` directory was incorrect (wrong
path), so cargo was rebuilding this library on every invocation
of `cargo build`.

Also moved it earlier just to separate it out from the code that
did the build and writing of the generated `shaders.rs` file.

Fixes linebender#569.
github-merge-queue bot pushed a commit that referenced this issue May 7, 2024
The dependency on the `shader` directory was incorrect (wrong path), so
cargo was rebuilding this library on every invocation of `cargo build`.

Also moved it earlier just to separate it out from the code that did the
build and writing of the generated `shaders.rs` file.

Fixes #569.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant