Rust bindings for libcwtch-go
Go to file
Dan Ballard c9f5ec2e42 remove use of u8/i8 and use bool in API and c_char in bindings 2023-07-23 14:43:40 -07:00
examples big version update to autobindings 0.0.3; api changes; added some structs, some used, some will be added to API but for now allow more straight forward deserialization 2023-05-07 13:21:14 -05:00
src remove use of u8/i8 and use bool in API and c_char in bindings 2023-07-23 14:43:40 -07:00
.gitignore bump yanked version of block-buffer 2022-04-26 12:19:59 -07:00
Cargo.lock update to autobindings 0.0.5 / ~ cwtchui 1.12 / cwtch 0.20.8 2023-06-26 00:03:04 -07:00
Cargo.toml update to autobindings 0.0.5 / ~ cwtchui 1.12 / cwtch 0.20.8 2023-06-26 00:03:04 -07:00
LICENSE add MIT LICENSE 2021-09-03 20:39:03 -07:00
README.md update to autobindings 0.0.5 / ~ cwtchui 1.12 / cwtch 0.20.8 2023-06-26 00:03:04 -07:00
build.rs update to autobindings 0.0.5 / ~ cwtchui 1.12 / cwtch 0.20.8 2023-06-26 00:03:04 -07:00
libCwtch.h update to autobindings 0.0.5 / ~ cwtchui 1.12 / cwtch 0.20.8 2023-06-26 00:03:04 -07:00

README.md

libCwtch-rs

Rust bindings for libCwtch autobindings

Example echobot in examples/echobot.rs (cargo run --example echobot -- assumes tor is on $PATH)

Building

Updating libCwtch and bingings.rs with Bindgen

libCwtch.so version is specified in build.rs. If updating, also download the corresponding libCwtch.h and delete the 'preamble from import "C"' section as it imports headers required for the C lib to compile but that we don't want to create rust bindings for (like importing stdlib.h). cargo build automatically calls bindgen for us and will regenerate src/cwtchlib_go/bindings.rs if libCwtch.h has changed.

While developing you can use the LCG_DIR environment variable to specify the directory containing a local libCwtch.so library to override the default one.

This is useful in cases where you are adding or updating APIs prior to a release.