Crate build

source · []
Expand description

Convenience wrappers for cargo buildscript input/output.

Example

build::rerun_if_changed("build.rs"); // only rerun for buildscript changes
build::rustc_cfg("has_buildrs"); // set #[cfg(has_buildrs)]
dbg!(build::cargo()); // path to the cargo executable
dbg!(build::cargo_manifest_dir()); // the directory of the build manifest

Re-exports

pub use crate::input::*;
pub use crate::output::*;

Modules

Inputs to the build script, in the form of environment variables.

Outputs from the build script, in the form of cargo: printed lines.