Commit 7c16959
authored
feat(prost-build): emit
Inform `cargo` about the files and env vars used by `prost-build`. Then `cargo` can better determine when to rebuild a project.
- Emit `rerun-if-changed` for each proto file specified
- Emit `rerun-if-changed` for each include directory specified
- Emit `rerun-if-changed` if `file_descriptor_set_path` is set
- Emit `rerun-if-env-changed` for `PROTOC` and `PROTOC_INCLUDE`
https://doc.rust-lang.org/cargo/reference/build-scripts.html#rerun-if-changed
BREAKING CHANGE: Previously `cargo` assumed it had to rerun `build.rs` if any files in the project changed. `prost-build` will now emit `rerun` commands, which means only the explicitly marked files cause a rerun. If your `build.rs` is dependent on any other file paths than those given to `prost-build`, then your `build.rs` needs to emit `rerun` commands as well.rerun commands (tokio-rs#1140)1 parent d505b18 commit 7c16959
1 file changed
+5
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
911 | 911 | | |
912 | 912 | | |
913 | 913 | | |
| 914 | + | |
914 | 915 | | |
915 | 916 | | |
916 | 917 | | |
| |||
932 | 933 | | |
933 | 934 | | |
934 | 935 | | |
| 936 | + | |
935 | 937 | | |
936 | 938 | | |
937 | 939 | | |
| |||
953 | 955 | | |
954 | 956 | | |
955 | 957 | | |
| 958 | + | |
956 | 959 | | |
957 | 960 | | |
958 | 961 | | |
| |||
1023 | 1026 | | |
1024 | 1027 | | |
1025 | 1028 | | |
1026 | | - | |
1027 | | - | |
1028 | | - | |
1029 | | - | |
1030 | | - | |
1031 | | - | |
1032 | 1029 | | |
1033 | 1030 | | |
1034 | 1031 | | |
| |||
1249 | 1246 | | |
1250 | 1247 | | |
1251 | 1248 | | |
| 1249 | + | |
1252 | 1250 | | |
1253 | 1251 | | |
1254 | 1252 | | |
1255 | 1253 | | |
1256 | 1254 | | |
1257 | 1255 | | |
1258 | 1256 | | |
| 1257 | + | |
1259 | 1258 | | |
1260 | 1259 | | |
1261 | 1260 | | |
| |||
0 commit comments