Fix Mac support (install to user)

This commit is contained in:
Disyer
2026-03-17 19:40:27 +02:00
parent 6dc1f86ee3
commit 650a9ba802
3 changed files with 25 additions and 5 deletions
@@ -88,7 +88,10 @@ pub fn install(
return Ok(());
}
let archive_bytes: &[u8] = include_bytes!("../cleanflash.7z");
#[cfg(target_os = "linux")]
let archive_bytes: &[u8] = include_bytes!("../cleanflash-linux.7z");
#[cfg(target_os = "macos")]
let archive_bytes: &[u8] = include_bytes!("../cleanflash-macos.7z");
if archive_bytes.is_empty() {
return Ok(());
@@ -399,7 +399,7 @@ pub fn install(
// The 7z archive is embedded in the binary via include_bytes!.
// For the port, we expect it at a known resource path; if not present,
// this is a no-op placeholder.
let archive_bytes: &[u8] = include_bytes!("../cleanflash.7z");
let archive_bytes: &[u8] = include_bytes!("../cleanflash-win.7z");
if archive_bytes.is_empty() {
// Nothing to extract; still apply the rest of the steps.