Closed ilslv closed 2 years ago
Set `tonic_build::Builder::emit_rerun_if_changed(false)` (#86)
- avoid constant rebuilding of every crate that depends on `medea-control-api-proto`
@ilslv I don't see the problem with cargo:rerun_if_changed
. Actually, it should be quite useful - whenever .proto
sources are changed, to automatically regenerate the code. But the question is: why it procs every time rather than whenever .proto
files are changed?
As @ilslv has pointed out in private conversation:
We have our own cargo:rerun_if_changed
being set, while tonic-build
adds additional cargo:rerun_if_changed
with too wide scope, which is the cause of the invalidation.
Synopsis
Since
tonic-build 0.8
it automatically addscargo:rerun_if_changed
. This leads to constant rebuilding of every crate that depends onmedea-control-api-proto
Checklist
Draft:
prefixk::
labels appliedDraft:
prefix is removed