btrfsutil_sys/lib.rs
1//! # btrfsutil-sys
2//!
3//! [](https://travis-ci.com/cezarmathe/btrfsutil-sys)
4//! [](https://crates.io/crates/btrfsutil-sys)
5//! [](https://docs.rs/btrfsutil-sys)
6//! [](https://github.com/kdave/btrfs-progs/blob/471b4cf7e3a46222531a895f90228ea164b1b857/libbtrfsutil/btrfsutil.h#L28-L30)
7//!
8//! Raw bindings to [libbtrfsutil](https://github.com/kdave/btrfs-progs/tree/master/libbtrfsutil).
9//!
10//! ## Building
11//!
12//! This library links to `libbtrfsutil`, a shared library provided by installing [btrfs-progs](https://github.com/kdave/btrfs-progs) on most Linux systems.
13//!
14//! - Arch Linux: `# pacman -S btrfs-progs`
15//! - Ubuntu: `# apt install libbtrfsutil1` (available since [eoan](https://releases.ubuntu.com/19.10/))
16//!
17//! ## Usage
18//!
19//! Add this to your `Cargo.toml`:
20//!
21//! ```toml
22//! [dependencies]
23//! btrfsutil-sys = "1.2.1"
24//! ```
25//!
26//! For further details, please refer to the [documentation](https://docs.rs/btrfsutil-sys).
27//!
28//! Also, please keep in mind that many of the operations this library can perform may require elevated
29//! privileges(CAP_SYSTEM_ADMIN).
30//!
31//! ## License
32//!
33//! MIT
34
35#![allow(non_upper_case_globals)]
36#![allow(non_camel_case_types)]
37#![allow(non_snake_case)]
38
39include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
40
41/// Id of the root subvolume in a Btrfs filesystem.
42pub const BTRFS_FS_TREE_OBJECTID: u64 = 5;