-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Add harness field to cargo metadata output #11846
Comments
This part stood out to me. I'm assuming you'll be needing more than just Out of curiosity, are you able to say what this tool is? Also, as an FYI, we have a Zulip stream dedicated to build system integrators](https://rust-lang.zulipchat.com/#narrow/stream/334885-t-cargo.2Fbuild-integration), in case that becomes useful in the future |
It is for nix's build system. Specifially the buildRustCrate build function from nixpkgs and crate2nix. The crate2nix/buildRustCrate currently has limited support for tests, examples, benches, etc. I am working on better support but ran into the fact that It's still very much WIP but I think the only other piece that is missing from the serialization is I hope this made some sense as a quick overview of my needs & what crate2nix & buildRustCrate as they are pretty complicated. Also thanks for the zulipchat link, I did not know about it. |
Thanks for the explanation! |
I'm running into the same issue with |
Problem
For third party rust compilation tools, we would like to follow the behavior of cargo. This requires using
cargo metadata
and its respective crate for parsingCargo.toml
files. However, the harness value is missing from the metadata output. Thus cannot follow the correct behavior for things like[[bench]]
which tend to useharness = false
resulting in--test
. See here.Proposed Solution
Simple add a harness value to the
cargo metadata
output.Notes
No response
The text was updated successfully, but these errors were encountered: