]> git.sesse.net Git - bcachefs-tools-debian/commit
remove library from bcachefs-tools Rust package
authorThomas Bertschinger <tahbertschinger@gmail.com>
Tue, 16 Jan 2024 06:41:01 +0000 (23:41 -0700)
committerKent Overstreet <kent.overstreet@linux.dev>
Tue, 16 Jan 2024 06:46:58 +0000 (01:46 -0500)
commitfb35dbfdc5a9446fbb856dae5542b23963e28b89
tree7f8cac8d202534b8da6a3da464c1671ab0f9e033
parent0a284fc4ffcbb46f0a4b921415ef12a9c75fa05c
remove library from bcachefs-tools Rust package

When bcachefs was a C program that had some functions implemented in
Rust, it was necessary to make a static library containing the Rust
functions available for the C program to link.

Now that bcachefs is a Rust program, that library is no longer needed.
Instead, the Rust executable links in libbachefs.a.

This patch updates the crate structure to reflect that. The command
functions are moved into their own module.

There could be a need to create a "libbachefs-tools" library in the
future that exposes an API for bcachefs functionality to other
userspace programs. That will be a different, external API as opposed to
the previous library functions which were an internal API for the
bcachefs tool itself.

Signed-off-by: Thomas Bertschinger <tahbertschinger@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
rust-src/Cargo.toml
rust-src/src/bcachefs.rs
rust-src/src/commands/cmd_completions.rs [moved from rust-src/src/cmd_completions.rs with 100% similarity]
rust-src/src/commands/cmd_list.rs [moved from rust-src/src/cmd_list.rs with 100% similarity]
rust-src/src/commands/cmd_mount.rs [moved from rust-src/src/cmd_mount.rs with 100% similarity]
rust-src/src/commands/logger.rs [moved from rust-src/src/logger.rs with 100% similarity]
rust-src/src/commands/mod.rs [moved from rust-src/src/lib.rs with 72% similarity]