90 releases (20 breaking)
0.20.3 | Nov 27, 2024 |
---|---|
0.19.2 | Oct 9, 2024 |
0.16.1 | May 22, 2024 |
0.15.41 | Feb 29, 2024 |
0.3.0 | Nov 18, 2021 |
#28 in No standard library
440 downloads per month
Used in 6 crates
(via c-gull)
570KB
16K
SLoC
Contains (static library, 1KB) empty/riscv64/libxnet.a, (static library, 1KB) empty/aarch64/libc.a, (static library, 1KB) empty/aarch64/libcrypt.a, (static library, 1KB) empty/aarch64/libdl.a, (static library, 1KB) empty/aarch64/libgcc.a, (static library, 1KB) empty/aarch64/libgcc_s.a and 54 more.
c-scape is a layer underneath c-gull. It provides a subset of libc features,
containing only features that don't require Rust's std
to implement. This
allows it to be used by std
itself.
This is currently highly experimental, incomplete, and some things aren't optimized. And it depends on Nightly Rust.
c-scape's two modes
Similar to c-gull, c-scape has "take-charge" and "coexist-with-libc" modes. One of these must be enabled.
In "take-charge" mode, c-scape takes charge of the process, handling program
startup (via Origin) providing malloc
(via c-scape), and other things. This
requires some additional setup; see the c-scape-example example crate for
more details.
In "coexist-with-libc" mode, c-scape can be used as a drop-in (partial) libc replacement. To use it, just change your typical libc dependency in Cargo.toml to this:
libc = { version = "<c-scape version>", package = "c-scape", features = ["coexist-with-libc"] }
Dependencies
~11–20MB
~368K SLoC