module :leex is not available
brianrackle opened this issue · 4 comments
I get this error with floki 0.6.1
=> floki
could not compile dependency :floki, "mix compile" failed. You can recompile this dependency with "mix deps.compile floki", update it with "mix deps.update floki" or clean it with "mix deps.clean floki"
** (UndefinedFunctionError) undefined function: :leex.file/2 (module :leex is not available)
:leex.file('src/floki_selector_lexer.xrl', [scannerfile: 'src/floki_selector_lexer.erl', report: true])
(mix) lib/mix/compilers/erlang.ex:84: anonymous fn/3 in Mix.Compilers.Erlang.compile/3
(elixir) lib/enum.ex:1385: Enum."-reduce/3-lists^foldl/2-0-"/3
(mix) lib/mix/compilers/erlang.ex:83: Mix.Compilers.Erlang.compile/3
(elixir) lib/enum.ex:1043: anonymous fn/3 in Enum.map/2
(elixir) lib/enum.ex:1385: Enum."-reduce/3-lists^foldl/2-0-"/3
(elixir) lib/enum.ex:1043: Enum.map/2
(mix) lib/mix/tasks/compile.all.ex:19: anonymous fn/1 in Mix.Tasks.Compile.All.run/1
nm, I didnt have all of erlang.
I installed erlang from https://www.erlang-solutions.com/downloads/download-erlang-otp
and elixir from https://www.erlang-solutions.com/downloads/download-elixir
and that fixed the problem
Just to complement, I am in Ubuntu and installed Erlang though apt-get. I had to instal other packages such as erlang-dev and erlang-parsetools to be able to compile libs such as Floki, but it did work.
@brianrackle and @akitaonrails Thank you for your report and details!
I added a section to the readme file explaining this.
Thanks, @akitaonrails, solved the problem!