#bindings #ffi #libblkid

sys rsblkid-sys

Raw FFI bindings to the util-linux/libblkid C library

4 releases

0.2.2 Oct 11, 2024
0.2.1 Oct 9, 2024
0.2.0 Oct 9, 2024
0.1.1 Oct 1, 2024
0.1.0 Sep 30, 2024

#736 in Operating systems

Download history 267/week @ 2024-09-27 255/week @ 2024-10-04 227/week @ 2024-10-11

749 downloads per month
Used in rsblkid

Apache-2.0 OR MIT

12KB
101 lines

rsblkid-sys

Crates.io License Crates.io MSRV


Raw Rust FFI bindings to the util-linux/libblkid C library.


Supported library version

This crate requires libblkid version 2.39.2 or later.

Build dependencies

To build this crate, install the following packages in addition to the Rust toolchain.

  • util-linux: to generate Rust bindings from libblkid's header files.
  • libclang: to satisfy the dependency of bindgen on libclang.
  • pkg-config: to detect system libraries.

NixOS

Temporarily install the required packages with:

nix-shell -p util-linux.dev libclang.lib pkg-config

or permanently with:

nix-env -iA nixos.util-linux.dev nixos.libclang.lib nixos.pkg-config

Alpine Linux

As root, issue the following command:

apk add util-linux-dev clang-libclang pkgconfig

Ubuntu

sudo apt-get install libblkid-dev libclang-dev pkg-config

License

Copyright (c) 2023 Nick Piaddo

SPDX-License-Identifier: Apache-2.0 OR MIT

Dependencies

~0–2MB
~40K SLoC