Add icons to windows builds

This commit is contained in:
2024-12-18 20:34:39 -05:00
parent bc84d88b5f
commit 78289193c7
5 changed files with 61 additions and 9 deletions
+10 -2
View File
@@ -1,6 +1,12 @@
use std::path::Path;
use std::{error::Error, path::Path};
fn main() -> Result<(), Box<dyn Error>> {
if std::env::var("CARGO_CFG_TARGET_OS")? == "windows" {
let mut res = winresource::WindowsResource::new();
res.set_icon("assets/lemur.ico");
res.compile()?;
}
fn main() {
println!("cargo::rerun-if-changed=shrooms-vb-core");
cc::Build::new()
.include(Path::new("shrooms-vb-core/core"))
@@ -11,4 +17,6 @@ fn main() {
.define("VB_DIV_GENERIC", None)
.file(Path::new("shrooms-vb-core/core/vb.c"))
.compile("vb");
Ok(())
}