-
Notifications
You must be signed in to change notification settings - Fork 233
Description
We are developing a library called Zenohex using Rustler. We are deeply grateful for providing such an excellent package as Rustler!!
https://github.com/biyooon-ex/zenohex
While using the latest version, Rustler v0.37.1, I noticed that a library file rustls_platform_verifier.so that seemed unnecessary was being generated (copied) into the native/priv/. The only file required should be zenohex_nif.so.
I confirmed that rustls_platform_verifier.so was not generated in the previous v0.36.2 version. I guess that something changed due to recent code modifications in compiler.ex.
rustler-0.36.2...rustler-0.37.1#diff-aea852ba0a1ff20d4a5eab3df8c59e3fc4e91560f8a0e07d131e1ca2ca600127
I am continuing the investigation, but I have not yet found the exact cause and solution. So I decided to create this issue to share our situation at first.
environment
- macOS and Linux (occurred in both)
- Elixir 1.18.4-otp-27
- Erlang/OTP 27.3.4.2
- Rust 1.89.0
- Rustler 0.37.1
- Rustler_precompiled 0.8.3
How to reproduce
$ git clone https://github.com/biyooon-ex/zenohex
$ cd zenohex
$ mix deps.get && mix compile
<skip>
==> rustler_precompiled
Compiling 4 files (.ex)
Generated rustler_precompiled app
==> zenohex
Compiling 22 files (.ex)
Compiling crate zenohex_nif in release mode (native/zenohex_nif)
Copying /<workdir>/zenohex/native/zenohex_nif/target/release/deps/librustls_platform_verifier-7a7678b64ab91b26.dylib to priv/native/rustls_platform_verifier.so
Copying /<workdir>/zenohex/native/zenohex_nif/target/release/libzenohex_nif.dylib to priv/native/zenohex_nif.so
Generated zenohex app
$ ls priv/native
rustls_platform_verifier.so* zenohex_nif.so*