aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--build.config3
-rw-r--r--core/deps.mk15
-rw-r--r--core/plugins.mk17
3 files changed, 20 insertions, 15 deletions
diff --git a/build.config b/build.config
index dad175c..44b4710 100644
--- a/build.config
+++ b/build.config
@@ -40,5 +40,8 @@ plugins/xref
plugins/cover
plugins/sfx
+# External plugins.
+core/plugins
+
# Core modules which can use variables from plugins.
core/deps-tools
diff --git a/core/deps.mk b/core/deps.mk
index 3cbcd45..72b75b0 100644
--- a/core/deps.mk
+++ b/core/deps.mk
@@ -591,18 +591,3 @@ ERLANG_MK_RECURSIVE_DOC_DEPS_LIST = $(ERLANG_MK_TMP)/recursive-doc-deps-list.log
ERLANG_MK_RECURSIVE_REL_DEPS_LIST = $(ERLANG_MK_TMP)/recursive-rel-deps-list.log
ERLANG_MK_RECURSIVE_TEST_DEPS_LIST = $(ERLANG_MK_TMP)/recursive-test-deps-list.log
ERLANG_MK_RECURSIVE_SHELL_DEPS_LIST = $(ERLANG_MK_TMP)/recursive-shell-deps-list.log
-
-# External plugins.
-
-DEP_PLUGINS ?=
-
-define core_dep_plugin
--include $(DEPS_DIR)/$(1)
-
-$(DEPS_DIR)/$(1): $(DEPS_DIR)/$(2) ;
-endef
-
-$(foreach p,$(DEP_PLUGINS),\
- $(eval $(if $(findstring /,$p),\
- $(call core_dep_plugin,$p,$(firstword $(subst /, ,$p))),\
- $(call core_dep_plugin,$p/plugins.mk,$p))))
diff --git a/core/plugins.mk b/core/plugins.mk
new file mode 100644
index 0000000..73f2d47
--- /dev/null
+++ b/core/plugins.mk
@@ -0,0 +1,17 @@
+# Copyright (c) 2013-2017, Loïc Hoguin <[email protected]>
+# This file is part of erlang.mk and subject to the terms of the ISC License.
+
+# External plugins.
+
+DEP_PLUGINS ?=
+
+define core_dep_plugin
+-include $(DEPS_DIR)/$(1)
+
+$(DEPS_DIR)/$(1): $(DEPS_DIR)/$(2) ;
+endef
+
+$(foreach p,$(DEP_PLUGINS),\
+ $(eval $(if $(findstring /,$p),\
+ $(call core_dep_plugin,$p,$(firstword $(subst /, ,$p))),\
+ $(call core_dep_plugin,$p/plugins.mk,$p))))