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

Collect garbage when generating Wasm files #601

Closed
blaxill opened this issue Feb 12, 2020 · 2 comments
Closed

Collect garbage when generating Wasm files #601

blaxill opened this issue Feb 12, 2020 · 2 comments

Comments

@blaxill
Copy link
Contributor

blaxill commented Feb 12, 2020

It appears calling cargo build with a custom target directory is generating a lot of garbage. Either collect the garbage or use the default directory and parse the location from cargo.

@tiziano88
Copy link
Collaborator

If the goal of #578 was to make it easier to determine the location of the artifacts, and make sure they are up-to-date, I think it could be achieved without having to rebuild everything and using a separate temp folder. For instance, it may rebuild things in-place (if necessary), and then have some logic to figure out the current target directory. Would this help?

@blaxill
Copy link
Contributor Author

blaxill commented Feb 13, 2020

Rebuilding in place is fine, the default target path depends on the location of the workspace. We could

  • Use out-dir instead of target-dir to a temp dir, then clean up after the test (this should reuse intermediate build artefacts)
  • Parse the cargo json blob to get the default target directory for the current workspace.

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

No branches or pull requests

2 participants