mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-24 16:23:40 +01:00
Define base64url dependency only when using rebar2 and Erlang<24
base64url is not called directly in ejabberd code since e227940
,
it is only required by p1_acme and erlang-jose 1.11.1
erlang-jose 1.11.1 defines base64url dependency as an hex package,
and rebar2 is not able to download it.
For that reason, when compiling ejabberd with rebar2,
we provide a rebar2-friendly base64url dependency definition.
That way when jose is downloaded, that dependency is already available.
This commit is contained in:
parent
e973360aa7
commit
9c8ae96f25
2
.github/workflows/runtime.yml
vendored
2
.github/workflows/runtime.yml
vendored
@ -193,7 +193,7 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
sed -i "s|^modules:|modules:\n 'ModPresenceDemo': {}|g" ejabberd.yml.example
|
sed -i "s|^modules:|modules:\n 'ModPresenceDemo': {}|g" ejabberd.yml.example
|
||||||
cat ejabberd.yml.example
|
cat ejabberd.yml.example
|
||||||
sed -i 's|^{deps, \(.*\)|{deps, \1\n {decimal, ".*", {git, "https://github.com/ericmj/decimal", {branch, "main"}}}, |g' rebar.config
|
sed -i 's|^{deps, \[\(.*\)|{deps, [{decimal, ".*", {git, "https://github.com/ericmj/decimal", {branch, "main"}}},\n \1|g' rebar.config
|
||||||
cat rebar.config
|
cat rebar.config
|
||||||
|
|
||||||
- name: Compile
|
- name: Compile
|
||||||
|
5
mix.exs
5
mix.exs
@ -44,7 +44,7 @@ defmodule Ejabberd.MixProject do
|
|||||||
def application do
|
def application do
|
||||||
[mod: {:ejabberd_app, []},
|
[mod: {:ejabberd_app, []},
|
||||||
applications: [:idna, :inets, :kernel, :sasl, :ssl, :stdlib, :mix,
|
applications: [:idna, :inets, :kernel, :sasl, :ssl, :stdlib, :mix,
|
||||||
:base64url, :fast_tls, :fast_xml, :fast_yaml, :jiffy, :jose,
|
:fast_tls, :fast_xml, :fast_yaml, :jiffy, :jose,
|
||||||
:p1_utils, :stringprep, :syntax_tools, :yconf]
|
:p1_utils, :stringprep, :syntax_tools, :yconf]
|
||||||
++ cond_apps(),
|
++ cond_apps(),
|
||||||
included_applications: [:mnesia, :os_mon,
|
included_applications: [:mnesia, :os_mon,
|
||||||
@ -129,8 +129,7 @@ defmodule Ejabberd.MixProject do
|
|||||||
end
|
end
|
||||||
|
|
||||||
defp deps do
|
defp deps do
|
||||||
[{:base64url, "~> 1.0"},
|
[{:cache_tab, "~> 1.0"},
|
||||||
{:cache_tab, "~> 1.0"},
|
|
||||||
{:dialyxir, "~> 1.2", only: [:test], runtime: false},
|
{:dialyxir, "~> 1.2", only: [:test], runtime: false},
|
||||||
{:eimp, "~> 1.0"},
|
{:eimp, "~> 1.0"},
|
||||||
{:ex_doc, "~> 0.31", only: [:dev, :edoc], runtime: false},
|
{:ex_doc, "~> 0.31", only: [:dev, :edoc], runtime: false},
|
||||||
|
@ -22,7 +22,10 @@
|
|||||||
%%% Dependencies
|
%%% Dependencies
|
||||||
%%%
|
%%%
|
||||||
|
|
||||||
{deps, [{base64url, ".*", {git, "https://github.com/dvv/base64url", {tag, "1.0.1"}}},
|
{deps, [{if_not_rebar3,
|
||||||
|
{if_version_below, "24",
|
||||||
|
{base64url, ".*", {git, "https://github.com/dvv/base64url", {tag, "1.0.1"}}}
|
||||||
|
}},
|
||||||
{cache_tab, ".*", {git, "https://github.com/processone/cache_tab", {tag, "1.0.30"}}},
|
{cache_tab, ".*", {git, "https://github.com/processone/cache_tab", {tag, "1.0.30"}}},
|
||||||
{eimp, ".*", {git, "https://github.com/processone/eimp", {tag, "1.0.22"}}},
|
{eimp, ".*", {git, "https://github.com/processone/eimp", {tag, "1.0.22"}}},
|
||||||
{if_var_true, pam,
|
{if_var_true, pam,
|
||||||
|
Loading…
Reference in New Issue
Block a user