I'm sorry but I'm new to Elixir. while building phoenix application, mix deps.get
failed with an error.
% mix deps.get
Could not find Hex, which is needed to build dependency :phoenix
Shall I install Hex? [Yn] y
** (MatchError) no match of right hand side value: {:error, {:ssl, {'no such file or directory', 'ssl.app'}}}
(mix) lib/mix/utils.ex:409: Mix.Utils.read_httpc/1
(mix) lib/mix/utils.ex:354: Mix.Utils.read_path/2
(mix) lib/mix/local.ex:107: Mix.Local.read_path!/2
(mix) lib/mix/local.ex:86: Mix.Local.find_matching_versions_from_signed_csv!/2
(mix) lib/mix/tasks/local.hex.ex:23: Mix.Tasks.Local.Hex.run/1
(mix) lib/mix/dep/loader.ex:140: Mix.Dep.Loader.with_scm_and_app/4
(mix) lib/mix/dep/loader.ex:98: Mix.Dep.Loader.to_dep/3
(elixir) lib/enum.ex:1043: anonymous fn/3 in Enum.map/2
%
erlang and elixir has been installed via kerl and asdf. and my installation log is here http://otiai10.hatenablog.com/entry/2016/02/03/154953
envirionment
What is happening and what should I do?
In case you arent using kerl
and you already did brew install openssl
, they added ERLANG_OPENSSL_PATH
option to asdf so you can do
asdf plugin-update erlang
ERLANG_OPENSSL_PATH="/usr/local/opt/openssl" asdf install erlang 21.1
As @biletskyy answered, it was missing of SSL on Erlang installed via kerl, unlike via brew.
If you want to build Erlang with ssl via kerl, you should pass KERL_CONFIGURE_OPTIONS
like below
KERL_CONFIGURE_OPTIONS="--with-ssl=/usr/local/opt/openssl" kerl build 18.0 18.0-foo
Then install Elixir via asdf. The mix command would work well.
Thanks to @biletskyy
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With