// the find
eclipse-zenoh/zenoh-c
C API for Zenoh
C bindings for the Zenoh pub/sub/query protocol, which targets low-latency data distribution across constrained devices, robots, and edge nodes. The actual protocol implementation is in Rust; this repo exposes it via a C API generated by cbindgen, making Zenoh accessible from C, C++, and anything that can link against a C library. Target audience is ROS2/robotics people and embedded systems developers who need something faster and leaner than MQTT or DDS.
The opaque-type generation infrastructure is genuinely well-engineered — a separate build-resources crate computes correct sizes at compile time so the C structs are neither too small nor ABI-unstable. Cross-compilation toolchain files cover all the platforms you'd care about in robotics (aarch64 Linux, armv7, MUSL static). The shared-memory path is a real zero-copy implementation backed by POSIX SHM, not a marketing claim. Test coverage is thorough for a C binding: double-drop tests, null-drop tests, alignment tests, and leak checks with valgrind.
The build requires a full Rust toolchain, which is a non-trivial ask for a C project — any team not already using Rust has to pull in cargo, rustup, and a pinned nightly for some features. The 'unstable API' flag is load-bearing for several features (shared memory, advanced pub/sub) but what exactly is unstable and what the stability guarantees are isn't clearly documented beyond a cmake flag name. 136 stars is low for something positioned as a DDS replacement in the ROS2 ecosystem, suggesting adoption is still niche. The generated header split across zenoh.h, zenoh_commons.h, zenoh_concrete.h, and zenoh_macros.h is confusing to navigate without the docs open.