Skip to content

Commit 07dc704

Browse files
authored
build: avoid spurious rebuilds of external deps. (envoyproxy#2558)
Fixes envoyproxy#2552. Signed-off-by: Harvey Tuch <[email protected]>
1 parent a34eeca commit 07dc704

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ci/build_container/Makefile

+2-1
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,9 @@ build-recipe = cd "$(THIRDPARTY_SRC)" && \
5656
FORCE:
5757

5858
# Capture $(ENV_STR) deps to retrigger build when they change.
59+
.PRECIOUS: $(THIRDPARTY_DEPS)/%.dep.env
5960
$(THIRDPARTY_DEPS)/%.dep.env: FORCE
60-
@[ "$(cat $@)" != "$(ENV_STR)" ] && echo "$(ENV_STR)" > $@
61+
@[ "$$(cat $@)" != "$(ENV_STR)" ] && echo "$(ENV_STR)" > $@ || echo "No need to rebuild $@"
6162

6263
$(THIRDPARTY_DEPS)/%.dep: $(RECIPES)/%.sh $(THIRDPARTY_DEPS)/%.dep.env
6364
@+$(call build-recipe,)

0 commit comments

Comments
 (0)