ExWeb3 / ex_keccak

Elixir library for computing Keccak SHA3-256 hashes using a NIF built tiny-keccak Rust crate.
Apache License 2.0
25 stars 20 forks source link

this have a error on linux centos! #20

Closed checkblue closed 2 years ago

checkblue commented 2 years ago

[***@xxxx blockscout]# mix deps.compile ex_keccak ==> ex_keccak Compiling 1 file (.ex)

== Compilation error in file lib/ex_keccak.ex == ** (ErlangError) Erlang error: :enoent (elixir 1.12.3) lib/system.ex:1041: System.cmd("cargo", ["metadata", "--format-version=1"], [cd: "native/exkeccak"]) (rustler 0.22.2) lib/rustler/compiler/config.ex:81: Rustler.Compiler.Config.external_resources/2 (rustler 0.22.2) lib/rustler/compiler/config.ex:69: Rustler.Compiler.Config.build/1 (rustler 0.22.2) lib/rustler/compiler.ex:9: Rustler.Compiler.compile_crate/2 lib/ex_keccak.ex:2: (module) could not compile dependency :ex_keccak, "mix compile" failed. You can recompile this dependency with "mix deps.compile ex_keccak", update it with "mix deps.update ex_keccak" or clean it with "mix deps.clean ex_keccak"

I erlang version: Erlang/OTP 23 [erts-11.1.7] [source] [64-bit] [smp:4:4] [ds:4:4:10] [async-threads:1] [hipe] Eshell V11.1.7 (abort with ^G)

Elixir version: Elixir 1.12.3 (compiled with Erlang/OTP 22)

Nickforall commented 2 years ago

You need to have the rust compiler/cargo installed :) This error indicates you don't have it or it is not in your PATH.

tzumby commented 2 years ago

Closing this, I think @Nickforall pretty much answered the question.

Cori1109 commented 1 year ago

Thanks Nickforall.

AkshayImmanent commented 1 year ago

image

We have the same issue rustc and cargo are preinstalled.