1 stable release

1.0.0 Jun 18, 2024

#1393 in Network programming

Download history 231/week @ 2024-06-13 1055/week @ 2024-06-20 1264/week @ 2024-06-27 985/week @ 2024-07-04 971/week @ 2024-07-11 1772/week @ 2024-07-18 3990/week @ 2024-07-25 2158/week @ 2024-08-01 3574/week @ 2024-08-08 4238/week @ 2024-08-15 4428/week @ 2024-08-22 3654/week @ 2024-08-29

16,553 downloads per month

MIT/Apache

145KB
3K SLoC

Maybenot FFI

This crate contains C FFI bindings for Maybenot, which let's you use Maybenot as a static library for languages other than Rust. Headers are found at maybenot-ffi/maybenot.h and are auto-generated when compiling using make.

Building

You need to have rust installed. cbindgen is also required: cargo install --force cbindgen Then just run make to build a static library at maybenot-ffi/libmaybenot.a.

Arguments to make:

  • CARGO override the cargo command
  • TARGET override target architecture; cross-compile.
  • PROFILE override the cargo profile, valid options are release and debug.
  • DESTINATION change the directory where the output artifacts will be places.

Example:

make TARGET=x86_64-unknown-linux-gnu PROFILE=debug

In order to link the resulting library to your program, you'll need to explicitly link some additional dependencies in addition to -lmaybenot. Run the following command to get an up-to-date list of the required flags for your platform:

RUSTFLAGS="--print native-static-libs" cargo build

Dependencies

~9–18MB
~311K SLoC