Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
libntirpc-sys
Low-level bindings for the libntirpc library.
Some documentation for the libary can be found in the Linux man pages rpc(3) and xdr(3). However, the doc has some inconsistency with the library, so we should use the doc as a reference not as a definitive guide.
Its implementation is adapted from the libtirpc-sys library.
Dependencies
The build script clones and compiles libntirpc from source, which requires the following tools and libraries:
| Dependency | Package (Ubuntu) | Purpose |
|---|---|---|
| cmake | cmake |
configure and build libntirpc |
| make | make |
build libntirpc |
| git | git |
clone libntirpc (with submodules) |
| clang | clang |
provide the headers used by bindgen to generate bindings |
| liburcu | liburcu-dev |
userspace RCU library used by libntirpc |
Install them on Ubuntu with:
Examples
The examples directory contains a small "hello world" RPC
client-server pair built directly on the raw bindings. They need the
rpcbind daemon, which is used to register the server's program number and
for the client to look it up:
Make sure it is running (restart it if the server fails to register):
Run the server in one terminal:
It should print hello server: prog=0x30000001 vers=1 on udp and register
with rpcbind (check with rpcinfo -p). Then, in another terminal, call it:
which prints Hello, Alice!. Both arguments are optional (name defaults to
world, host to 127.0.0.1).