25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-20 16:15:59 +01:00

Rebar3: Compile explicitly our Elixir files when --enable-elixir

This commit is contained in:
Badlop 2023-12-20 15:29:33 +01:00
parent e1f14aca9b
commit ff783d15e8
2 changed files with 3 additions and 0 deletions

View File

@ -124,6 +124,7 @@ else
ifeq ($(REBAR_ENABLE_ELIXIR),true) ifeq ($(REBAR_ENABLE_ELIXIR),true)
ELIXIR_LIBDIR_RAW=$(shell elixir -e "IO.puts(:filename.dirname(:code.lib_dir(:elixir)))" -e ":erlang.halt") ELIXIR_LIBDIR_RAW=$(shell elixir -e "IO.puts(:filename.dirname(:code.lib_dir(:elixir)))" -e ":erlang.halt")
ELIXIR_LIBDIR=":$(ELIXIR_LIBDIR_RAW)" ELIXIR_LIBDIR=":$(ELIXIR_LIBDIR_RAW)"
EXPLICIT_ELIXIR_COMPILE=MIX_ENV=default mix compile.elixir
endif endif
ifeq "$(REBAR_VER)" "3" ifeq "$(REBAR_VER)" "3"
SKIPDEPS= SKIPDEPS=
@ -179,6 +180,7 @@ $(DEPSDIR)/.built: $(DEPSDIR)/.got
src: $(DEPSDIR)/.built src: $(DEPSDIR)/.built
$(REBAR) $(SKIPDEPS) compile $(REBAR) $(SKIPDEPS) compile
$(EXPLICIT_ELIXIR_COMPILE)
update: update:
rm -rf $(DEPSDIR)/.got rm -rf $(DEPSDIR)/.got

View File

@ -240,6 +240,7 @@
{mkdir, "conf"}, {mkdir, "conf"},
{copy, "rel/files/erl", "erts-\{\{erts_vsn\}\}/bin/erl"}, {copy, "rel/files/erl", "erts-\{\{erts_vsn\}\}/bin/erl"},
{template, "ejabberdctl.template", "bin/ejabberdctl"}, {template, "ejabberdctl.template", "bin/ejabberdctl"},
{copy, "_build/default/lib/ejabberd/ebin/Elixir.*", "lib/ejabberd-{{release_version}}/ebin/"},
{copy, "inetrc", "conf/inetrc"}, {copy, "inetrc", "conf/inetrc"},
{copy, "tools/captcha*.sh", "lib/ejabberd-\{\{release_version\}\}/priv/bin/"}, {copy, "tools/captcha*.sh", "lib/ejabberd-\{\{release_version\}\}/priv/bin/"},
{copy, "rel/files/install_upgrade.escript", "bin/install_upgrade.escript"}]} {copy, "rel/files/install_upgrade.escript", "bin/install_upgrade.escript"}]}