I have this in a Cargo.toml
rdkafka = { version = "0.29.0", features = [ "ssl", "cmake-build"] }
I tried to compile to x86_64-unknown-linux-musl
using 2 options. Both failed.
cargo build --target x86_64-unknown-linux-musl --release
OUTPUT:
linking with cc failed: exit status: 1
rdkafka_ssl.c:(.text.rd_kafka_ssl_ctx_term+0x2b): undefined reference to `ENGINE_free'
collect2: error: ld returned 1 exit status
cross build --target=x86_64-unknown-linux-musl --release
OUTPUT:
rdkafka_ssl.c:(.text.rd_kafka_ssl_ctx_term+0x2b): undefined reference to `ENGINE_free'
collect2: error: ld returned 1 exit status
They both give the same error.
Does anyone know how to fix this? Or can someone try this on their machine.. I'd really appreciate it.
I expected the build to pass.
POST
I have added github repo and recreated the issue. It uses Dockerfile
https://github.com/0xDjole/rust-rdkafka-musl
To test just docker build -t muslkafka .
Here is the screenshot of the issue