mjason/jieba_ex

Does not compile on Mac M1

Opened this issue · 0 comments

@sforce100 I see that .cargo/config has already specified [target.aarch64-apple-darwin], so I'm not sure why the compilation fails. Any idea?

Compiling jieba v0.1.0 (/Users/jkwchui/Documents/GitHub/ex_cantonese/deps/jieba/native/jieba)
error: linking with `cc` failed: exit status: 1
[...]
= note: Undefined symbols for architecture arm64:
            "_enif_alloc_binary", referenced from:
                rustler::types::string::
[...]
error: could not compile `jieba` due to previous error
== Compilation error in file lib/jieba.ex ==
** (RuntimeError) Rust NIF compile error (rustc exit code 101)
    (rustler 0.22.2) lib/rustler/compiler.ex:36: Rustler.Compiler.compile_crate/2

🌍 Environment

Operating system and version: macOS Ventura 13.2.1
Chip: Apple silicon M1
Elixir version: 1.14.4
Erlang/OTP version: 25
Rust version (rustc --version): rustc 1.68.0