5 ms·
Do you mean C/C++ and Rust interop? Maybe link them together to form the final executable binary? Can you share more experience on how do you do that?
by xjia 10y ago
Do you mean C/C++ and Rust interop? Maybe link them together to form the final executable binary? Can you share more experience on how do you do that?
- bluejekyll 10y agoRust produces standard linkable system libraries. You can produce dynamic libraries or static libraries on all supported platforms. For actual examples of using Rust with other languages through these libraries this site is great: http://jakegoulding.com/rust-ffi-omnibus/ http://jakegoulding.com/rust-ffi-omnibus/
- computerphage 10y agoMore information about platform support can be found here: https://doc.rust-lang.org/book/getting-started.html https://doc.rust-lang.org/book/getting-started.html
- carols10cents 10y agoNot the OP, but I did a talk on an incremental rewrite of a C library to Rust [1]. Rust has good FFI capabilities with C and other languages through that [2]. [1]- https://github.com/carols10cents/rust-out-your-c-talk https://github.com/carols10cents/rust-out-your-c-talk [2] - http://jakegoulding.com/rust-ffi-omnibus/ http://jakegoulding.com/rust-ffi-omnibus/
- rlnunes 10y agolinking a static lib with rust and linking with the final executable. other users posted the links I used :)