-
Notifications
You must be signed in to change notification settings - Fork 776
Closed
Description
When bindgen is used in build.rs, no cargo:rerun-if-changed lines are emitted that'd cause the build process to be rerun if any source file changed.
On projects where the C source and crates using the -sys crate are actively being developed, this leads to confusing error situations, and users that rm -rf target out of frustration.
I suggest adding an option to generate rerun-if-changed lines for all included files. If there is a danger to lead to long checking times due to lots of system libraries in practice, adding a filter function on the emitted header files could be an option. (That's inspired by gcc's distinction between -MD and MMD, where the latter ignores system header files).