#decompression #libbz2

sys bzip2-sys

Bindings to libbzip2 for bzip2 compression and decompression exposed as Reader/Writer streams

15 releases

Uses old Rust 2015

0.1.13+1.0.8 Feb 28, 2025
0.1.11+1.0.8 Jun 9, 2021
0.1.10+1.0.8 Feb 1, 2021
0.1.9+1.0.8 May 27, 2020
0.0.1 Nov 13, 2014

#357 in Compression

Download history 1156394/week @ 2025-08-10 1068830/week @ 2025-08-17 1025717/week @ 2025-08-24 1067942/week @ 2025-08-31 1046795/week @ 2025-09-07 1066227/week @ 2025-09-14 1146366/week @ 2025-09-21 1072553/week @ 2025-09-28 1074101/week @ 2025-10-05 1037194/week @ 2025-10-12 1027585/week @ 2025-10-19 1107314/week @ 2025-10-26 1140973/week @ 2025-11-02 1086291/week @ 2025-11-09 1117783/week @ 2025-11-16 922941/week @ 2025-11-23

4,332,985 downloads per month
Used in 2,501 crates (16 directly)

MIT/Apache

635KB
6K SLoC

C 5.5K SLoC // 0.2% comments XSL 283 SLoC // 0.1% comments Rust 107 SLoC // 0.0% comments Shell 74 SLoC // 0.3% comments Perl 39 SLoC // 0.4% comments

bzip2

Documentation

A streaming bzip2 compression/decompression library for rust.

Features

bzip2-sys

Attempt to use the system libbz2. When libbz2 is not available, built from source. A from-source build requires a functional C toolchain for your target, and may not work for all targets (in particular webassembly).

bzip2 = { version = "0.5.1", default-features = false, features = ["bzip2-sys"] }

static

Always build libbz2 from C source, and statically link it. This flag is only meaningful when bzip2-sys is used, and has no effect when the default libbz2-rs-sys is used as the bzip2 implementation.

License

This project is licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this repository by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies