diff --git a/build.rs b/build.rs index cc564fe..6998bc6 100644 --- a/build.rs +++ b/build.rs @@ -1,9 +1,9 @@ -use std::{env, error::Error}; +const META: &str = "resources/assets/manifest.rc"; -fn main() -> Result<(), Box> { - if env::var("CARGO_CFG_TARGET_FAMILY")? == "windows" { - embed_resource::compile("resources/assets/manifest.rc", embed_resource::NONE); +fn main() -> Result<(), Box> { + println!("cargo::rerun-if-changed={META}"); + if std::env::var("CARGO_CFG_TARGET_FAMILY")? == "windows" { + embed_resource::compile(META, embed_resource::NONE); } - Ok(()) }