#build-environment #constant #no-alloc

no-std build-context

Make build environment/target information available as constants in normal libraries and binaries

5 releases

0.1.4 Feb 27, 2026
0.1.3 Sep 13, 2024
0.1.2 Apr 13, 2024
0.1.1 May 5, 2023
0.1.0 May 1, 2023

#9 in #build-environment

Download history 4030/week @ 2026-03-09 2226/week @ 2026-03-16 2922/week @ 2026-03-23 2009/week @ 2026-03-30 1959/week @ 2026-04-06 2692/week @ 2026-04-13 3162/week @ 2026-04-20 2588/week @ 2026-04-27 995/week @ 2026-05-04 1121/week @ 2026-05-11 991/week @ 2026-05-18 2259/week @ 2026-05-25 3112/week @ 2026-06-01

7,605 downloads per month
Used in 10 crates (8 directly)

Apache-2.0 OR MIT

13KB
71 lines

build-context

crates.io docs.rs license msrv github actions

Make build environment/target information available as constants in normal libraries and binaries.

This is intended primarily for use in tests and its helpers. When used in libraries or binaries, be careful not to depend on constants that depend on the host build environment.

Some constants duplicate those provided in std::env::consts.

License

Licensed under either of Apache License, Version 2.0 or MIT license at your option.

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

No runtime deps