Remove the ffi-headers feature

Rely on a separate cbindgen instance instead, which is less self-contained but more practical.
This commit is contained in:
Oliver Hamlet
2024-04-30 23:29:31 +01:00
parent adeac2317c
commit c508533d4b
5 changed files with 14 additions and 191 deletions
+1 -10
View File
@@ -27,16 +27,7 @@ To build the Rust and C FFI libraries, run:
cargo build --release --package loot-condition-interpreter-ffi
```
To generate a C++ header file as part of the build, instead run:
```
cargo build --release --package loot-condition-interpreter-ffi --all-features
```
This will create a file at `ffi/include/loot_condition_interpreter.h`.
However, this involves building [cbindgen](https://github.com/eqrion/cbindgen)
as a dependency, which is relatively slow. If you have cbindgen installed
separately, it's faster to generate the headers using its CLI:
Use [cbindgen](https://github.com/eqrion/cbindgen) to generate a C++ header file:
```
cbindgen ffi/ -o ffi/include/loot_condition_interpreter.h