opensmtpd-filter-dkimout/build.rs
2023-04-09 17:21:17 +02:00

17 lines
394 B
Rust

use std::env;
const VARLIBDIR_NAME: &str = "VARLIBDIR";
const VARLIBDIR_VALUE_DEFAULT: &str = "/var/lib/";
fn main() {
// trigger recompilation when a new migration is added
println!("cargo:rerun-if-changed=migrations");
// set the VARLIBDIR env variable
if env::var(VARLIBDIR_NAME).is_err() {
println!(
"cargo:rustc-env={}={}",
VARLIBDIR_NAME, VARLIBDIR_VALUE_DEFAULT
);
}
}