Expand description
This crate is used to collect build info for consumption by the build-info
crate.
// Calling `build_info_build::build_script` collects all data and makes it available to `build_info::build_info!`
// and `build_info::format!` in the main program.
build_info_build::build_script();
§Features
The build-info-build
crate has the following features:
git
(enabled by default): Enables git support. A git repository will only be detected if this feature is available.
Re-exports§
pub use build_info_common::semver;
Structs§
- Build
Info - Information about the current build
- Build
Script Options - Type to store any (optional) options for the build script.
- Compiler
Info rustc
version and configuration- Crate
Info - Information about the current crate (i.e., the crate for which build information has been generated)
- GitInfo
- Information about a git repository
Enums§
- Compiler
Channel rustc
distribution channel (some compiler features are only available on specific channels)- Dependency
Depth - Depth of dependencies to collect
- Optimization
Level - The various possible optimization levels
- Version
Control - Support for different version control systems
Functions§
- build_
script - Call this function in your
build.rs
script to generate the data consumed by thebuild_info
crate. Additional customization options are available by manipulating the return type. The actual work is performed once the return type is dropped.