From fe5c42fb818acf9ad6ca6589ea182dfbfbaa5427 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Tue, 29 Sep 2015 15:03:34 +0200 Subject: Add support for APPS_DIR This changes adds Rebar-like "apps/" functionality. From this commit onward, Erlang.mk supports 4 types of repositories: - Repo with an Erlang app at root level + deps/ - Repo with an Erlang app at root level + apps/ deps/ - Repo with no app at root level + deps/ - Repo with no app at root level + apps/ deps/ Example usage: - make new-app in=webchat - make new t=gen_server n=my_chat in=webchat - make Replace new-app with new-lib to create an OTP library instead of an OTP application. --- core/erlc.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/erlc.mk') diff --git a/core/erlc.mk b/core/erlc.mk index fbba7ae..7ca24bb 100644 --- a/core/erlc.mk +++ b/core/erlc.mk @@ -60,7 +60,7 @@ define app_file $(if $(IS_DEP),{id$(comma)$(space)"$(1)"}$(comma)) {modules, [$(call comma_list,$(2))]}, {registered, []}, - {applications, [$(call comma_list,kernel stdlib $(OTP_DEPS) $(DEPS))]} + {applications, [$(call comma_list,kernel stdlib $(OTP_DEPS) $(LOCAL_DEPS) $(DEPS))]} ]}. endef else @@ -71,7 +71,7 @@ define app_file $(if $(IS_DEP),{id$(comma)$(space)"$(1)"}$(comma)) {modules, [$(call comma_list,$(2))]}, {registered, [$(call comma_list,$(PROJECT)_sup $(PROJECT_REGISTERED))]}, - {applications, [$(call comma_list,kernel stdlib $(OTP_DEPS) $(DEPS))]}, + {applications, [$(call comma_list,kernel stdlib $(OTP_DEPS) $(LOCAL_DEPS) $(DEPS))]}, {mod, {$(PROJECT)_app, []}} ]}. endef -- cgit v1.2.3