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

autogen: Convert from build script to runnable binary #173

Merged
merged 2 commits into from
Nov 25, 2020

Conversation

MarijnS95
Copy link
Collaborator

@MarijnS95 MarijnS95 commented Nov 20, 2020

According to the autogen README rspirv-autogen is used to "automatically update files in anther crates". This use seems long-gone as none of the top-level projects depend on rspirv-autogen: regeneration does not happen at build-time anymore.

However, when loading this project in an IDE that scans and checks all workspaces the build script is invoked resulting in slow startup times and accidental regeneration, which is particularly inconvenient when SPIRV-Headers so happens to be checked out on a different commit.

With this PR the recommended way to regenerate is:

you@your-pc:~/rspirv $ cargo r -p rspirv-autogen
     Running `target/debug/rspirv-autogen`

In addition regeneration happens in the CI now as well, to capture any accidental mismatches between the generator, submodule checkout and submitted code.

(Edit: no, I don't like ```console either.)

According to the autogen README rspirv-autogen is used to "automatically
update files in anther crates". This use seems long-gone as none of the
top-level projects depend on `rspirv-autogen`: regeneration does not
happen at build-time anymore.

However, when loading this project in an IDE that scans and `check`s all
workspaces the build script _is_ invoked resulting in slow startup
times and accidental regeneration, which is particularly inconvenient
when SPIRV-Headers so happens to be checked out on a different commit.
@Jasper-Bekkers
Copy link
Collaborator

Jasper-Bekkers commented Nov 25, 2020

I think this is a change for the better 👍

@Jasper-Bekkers Jasper-Bekkers merged commit 3ba1ff4 into gfx-rs:master Nov 25, 2020
@MarijnS95 MarijnS95 deleted the autogen-binary branch November 25, 2020 09:56
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 this pull request may close these issues.

2 participants