Skip to content

Commit

Permalink
Use Luerl 1.0 for Erlang 20, 1.1.1 for 21-26, and temporary fork for 27
Browse files Browse the repository at this point in the history
The Luerl 1.1.0 and 1.1.1 hex packages contain garbage files that
break compilation with Erlang 20.
  • Loading branch information
badlop committed Feb 21, 2024
1 parent 2b85101 commit 9bb4db1
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 5 deletions.
5 changes: 4 additions & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,10 @@ defmodule Ejabberd.MixProject do
{config(:sip), {:esip, "~> 1.0"}},
{config(:zlib), {:ezlib, "~> 1.0"}},
{if_version_below(~c"22", true), {:lager, "~> 3.9.1"}},
{config(:lua), {:luerl, "~> 1.0"}},
{config(:lua) and if_version_below(~c"27", true),
{:luerl, "~> 1.1.1"}},
{config(:lua) and if_version_above(~c"26", true),
{:luerl, git: "https://github.com/processone/luerl", branch: "otp27"}},
{config(:mysql), {:p1_mysql, ">= 1.0.23" }},
{config(:pgsql), {:p1_pgsql, "~> 1.1"}},
{config(:sqlite), {:sqlite3, "~> 1.1"}},
Expand Down
22 changes: 18 additions & 4 deletions rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,28 @@
{if_version_below, "22",
{lager, ".*", {git, "https://github.com/erlang-lager/lager", {tag, "3.9.1"}}}
},
%% Lua, rebar, OTP 20: 1.0 git tag
{if_var_true, lua,
{if_not_rebar3,
{luerl, ".*", {git, "https://github.com/rvirding/luerl", {tag, "1.0"}}}
}},
{if_version_below, "21",
{luerl, ".*", {git, "https://github.com/rvirding/luerl", {tag, "1.0"}}}
}}},
%% Lua, rebar3, OTP 20: 1.0.0 hex package
{if_var_true, lua,
{if_rebar3,
{luerl, ".*", {git, "https://github.com/rvirding/luerl", {tag, "1.0.0"}}}
}},
{if_version_below, "21",
{luerl, ".*", {git, "https://github.com/rvirding/luerl", {tag, "1.0.0"}}}
}}},
%% Lua, any rebar, OTP 21-26: 1.1.1 git tag / 1.1.1 hex package
{if_var_true, lua,
{if_version_above, "20", {if_version_below, "27",
{luerl, ".*", {git, "https://github.com/rvirding/luerl", {tag, "1.1.1"}}}
}}},
%% Lua, any rebar, OTP 27: temporary otp27 branch from fork
{if_var_true, lua,
{if_version_above, "26",
{luerl, ".*", {git, "https://github.com/processone/luerl", {branch, "otp27"}}}
}},
{mqtree, ".*", {git, "https://github.com/processone/mqtree", {tag, "1.0.15"}}},
{p1_acme, ".*", {git, "https://github.com/processone/p1_acme", {tag, "1.0.22"}}},
{if_var_true, mysql,
Expand Down

0 comments on commit 9bb4db1

Please sign in to comment.