diff options
author | Jean-Sébastien Pédron <[email protected]> | 2019-06-25 14:18:43 +0200 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2019-06-28 14:17:12 +0200 |
commit | 2b7e434f7327b7fdda72950e27f8fc0a27de2547 (patch) | |
tree | 036973281d96547c12c614f791d99f446dfba86a /core/deps.mk | |
parent | 5e8c5fa7a0e009b7d73b26937ea23f3b685a3f2f (diff) | |
download | erlang.mk-2b7e434f7327b7fdda72950e27f8fc0a27de2547.tar.gz erlang.mk-2b7e434f7327b7fdda72950e27f8fc0a27de2547.tar.bz2 erlang.mk-2b7e434f7327b7fdda72950e27f8fc0a27de2547.zip |
Accept a list of deps to forcibly rebuild in `$(FORCE_REBUILD)`
... in addition to the `$(force_rebuild_dep)` function.
It's easier for the common use case than specify a function.
Diffstat (limited to 'core/deps.mk')
-rw-r--r-- | core/deps.mk | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/core/deps.mk b/core/deps.mk index 4146cc0..8c5543a 100644 --- a/core/deps.mk +++ b/core/deps.mk @@ -120,6 +120,25 @@ ifeq ($(IS_APP)$(IS_DEP),) $(verbose) rm -f $(ERLANG_MK_TMP)/apps.log $(ERLANG_MK_TMP)/deps.log endif +# Erlang.mk does not rebuild dependencies after they were compiled +# once. If a developer is working on the top-level project and some +# dependencies at the same time, he may want to change this behavior. +# There are two solutions: +# 1. Set `FULL=1` so that all dependencies are visited and +# recursively recompiled if necessary. +# 2. Set `FORCE_REBUILD=` to the specific list of dependencies that +# should be recompiled (instead of the whole set). + +FORCE_REBUILD ?= + +ifeq ($(origin FULL),undefined) +ifneq ($(strip $(force_rebuild_dep)$(FORCE_REBUILD)),) +define force_rebuild_dep +echo "$(FORCE_REBUILD)" | grep -qw "$$(basename "$1")" +endef +endif +endif + ifneq ($(SKIP_DEPS),) deps:: else |