Allow a build script (build.rs) in a virtual manifest Cargo.toml
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 15.5k
- Forks
- 3k
- Avg merge
- 23h 30m
- Merged PRs (30d)
- 51
Description
Describe the problem you are trying to solve
I have a package with several crates and "virtual" Cargo.toml (virtual manifest). I would like to execute some code before building this package or any containing crate. Currently it isn't allowed to have build.rs in the virtual manifest.
Describe the solution you'd like
Allow the build field to appear in the virtual manifest.
Notes
As a workaround I have created an empty crate with build.rs and made all other crates depend on it.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the rejection of a build field in a workspace's virtual Cargo.toml, then trace the manifest validation and build-script handling involved. Done means a virtual manifest can declare build.rs and the requested pre-build behavior works for the package and containing crate without requiring an empty helper crate.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100