fips icon indicating copy to clipboard operation
fips copied to clipboard

Rust support?

Open kkimdev opened this issue 8 years ago • 2 comments

I'm trying to generate Oryol Rust binding and code in Rust. What would be the most proper way to integrate Rust compilation (Cargo)?

kkimdev avatar May 23 '17 23:05 kkimdev

External build systems aren't really supported right now, you may be able to workaround with a custom verb that will prepare the rust library and trick fips to use the generated output or a fips-generator.

In any case, this is how one would integrate Rust in a CMake project: https://stackoverflow.com/questions/31162438/how-can-i-build-rust-code-with-a-c-qt-cmake-project

There are other issues related to external build systems #140 and #124. I believe that a simple support to CMake ExternalProject could be done in a simple way and integrating Rust can be easy without adding too much code (as rustup and cargo will do the heavy part).

fungos avatar May 24 '17 00:05 fungos

I learned about CMake Rust Language Support recently, and tried to wrap a simple-to-use module fips-rust around it.

Right now, it only allows to add a Cargo project as a static library, so that it can be conveniently linked with fips_libs() and called from C/C++ code.

I did not try yet to link other fips libraries to a Rust project. That's probably the difficult part.

code-disaster avatar Dec 15 '18 10:12 code-disaster