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

Provide a means to know the freshness state of a set of paths from build.rs #8086

Open
lu-zero opened this issue Apr 8, 2020 · 2 comments
Open
Labels
A-build-scripts Area: build.rs scripts C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` S-needs-design Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.

Comments

@lu-zero
Copy link
Contributor

lu-zero commented Apr 8, 2020

build.rs helpers such as cc-rs and nasm-rs get executed every time and that may slow down rebuilding quite a lot depending on the amount of assembly code a project has.

We already have a mean to tell cargo about foreign files, would be great to query back their state so if they are fresh isn't needed to build them again.

@lu-zero lu-zero added the C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` label Apr 8, 2020
@ehuss ehuss added the A-build-scripts Area: build.rs scripts label Apr 15, 2020
@epage
Copy link
Contributor

epage commented Sep 20, 2023

If I'm understanding this correctly, the request problem is that a cargo detects that a build script needs to be re-run for some reason but the build script fills multiple roles and only part of it needs to be re-evaluated, so how do we do that?

For myself, I feel like providing a way to move away from monolithic build scripts would be a big help. This would also help with #5720 and #12552

@lu-zero
Copy link
Contributor Author

lu-zero commented Sep 20, 2023

The perfect solution would be to have a mean to have a mean to give cargo additional custom Units, then build.rs can be used just to declare them and cargo then can put them in the graph and process them accordingly.

@epage epage added the S-needs-design Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted. label Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-build-scripts Area: build.rs scripts C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` S-needs-design Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.
Projects
None yet
Development

No branches or pull requests

3 participants