aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Sébastien Pédron <[email protected]>2015-10-22 11:20:41 +0200
committerJean-Sébastien Pédron <[email protected]>2015-10-22 14:58:12 +0200
commit383f25459190bde9d3979bba788ea1dad8114f78 (patch)
treee4077ad08b8a2a03aa3d1216975efb47badc0c09
parent312f9c646ed83f6bf5bccc237e7903f2705a8c08 (diff)
downloaderlang.mk-383f25459190bde9d3979bba788ea1dad8114f78.tar.gz
erlang.mk-383f25459190bde9d3979bba788ea1dad8114f78.tar.bz2
erlang.mk-383f25459190bde9d3979bba788ea1dad8114f78.zip
Return argument as a last resort in $(dep_name)
Therefore, if neither $(dep_something) nor $(pkg_something_name) is defined, $(dep_name) will return the name specified in the various dependencies lists. This fixes `core-app-pt-erlc-opts` and `core-deps-fetch-fail-unknown` because now, the dependency is not "forgotten" anymore. Before, the dependency directory was missing from $(ALL_DEPS_DIRS) because $(dep_name) returned nothing.
-rw-r--r--core/deps.mk2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/deps.mk b/core/deps.mk
index cc5a34f..76f54d7 100644
--- a/core/deps.mk
+++ b/core/deps.mk
@@ -21,7 +21,7 @@ export DEPS_DIR
REBAR_DEPS_DIR = $(DEPS_DIR)
export REBAR_DEPS_DIR
-dep_name = $(if $(dep_$(1)),$(1),$(pkg_$(1)_name))
+dep_name = $(if $(dep_$(1)),$(1),$(if $(pkg_$(1)_name),$(pkg_$(1)_name),$(1)))
dep_repo = $(patsubst git://github.com/%,https://github.com/%, \
$(if $(dep_$(1)),$(word 2,$(dep_$(1))),$(pkg_$(1)_repo)))
dep_commit = $(if $(dep_$(1)_commit),$(dep_$(1)_commit),$(if $(dep_$(1)),$(word 3,$(dep_$(1))),$(pkg_$(1)_commit)))