Linking to C library with Rust FFI #481
Replies: 4 comments 2 replies
-
I think it should be |
Beta Was this translation helpful? Give feedback.
-
Maybe just having |
Beta Was this translation helpful? Give feedback.
-
Update: it appears the issue is from |
Beta Was this translation helpful? Give feedback.
-
Thanks for providing the example repo I was able to get it to compile and run by defining CC and AR like this
(Windows in cmd.exe syntax shown) It looks like while the target is Seems like this is not unexpected since their README talks about defining these env-variables here: https://github.com/rust-lang/cc-rs#external-configuration-via-environment-variables |
Beta Was this translation helpful? Give feedback.
-
I'm trying to use a C library with a Rust wrapper rust-secp256k1. I downloaded the C library and built it with a target of
--host=xtensa-esp32
. I then added the library to my.cargo/config.toml
linker flags:However, when building I get an error that says
Should I be linking that library differently?
Source code for project
Beta Was this translation helpful? Give feedback.
All reactions