pub enum Env {
Gnu,
Musl,
Bionic,
Uclibc,
Msvc,
None,
}Expand description
The C library a triple’s environment component names.
On most systems the operating system settles the library — Apple has
libSystem, the BSDs each have their own — and this is Env::None. Linux
is the exception: -gnu, -musl and -android are three libraries with
three sets of layouts behind the same system macros, and a header that laid
a mtx_t out for the wrong one would corrupt memory. So the environment is
kept, and TargetModel::macros turns the two this crate models into
__cinrs_glibc__ and __cinrs_musl__ for the bundled headers to branch on.
Variants§
Gnu
The GNU C Library, -gnu*: gnu, gnueabihf, gnux32, gnullvm.
Musl
musl, -musl*.
Bionic
Android’s bionic, which a triple names -android or -androideabi.
Uclibc
uClibc, -uclibc*.
Msvc
The Microsoft runtime, -msvc.
None
The triple says nothing, because the system has only one C library (Apple, the BSDs, WASI) or because there is none at all.