[PM-27583] Add icon to chromium import helper (#17126)
Adds an icon to the windows binary. --------- Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>pull/17152/head
parent
9d2b2d1894
commit
4c1eba2086
@ -0,0 +1,40 @@
|
||||
[package]
|
||||
name = "bitwarden_chromium_import_helper"
|
||||
version.workspace = true
|
||||
license.workspace = true
|
||||
edition.workspace = true
|
||||
publish.workspace = true
|
||||
|
||||
[dependencies]
|
||||
|
||||
[target.'cfg(target_os = "windows")'.dependencies]
|
||||
chromium_importer = { path = "../chromium_importer" }
|
||||
clap = { version = "=4.5.40", features = ["derive"] }
|
||||
scopeguard = { workspace = true }
|
||||
sysinfo = { workspace = true }
|
||||
verifysign = "=0.2.4"
|
||||
windows = { workspace = true, features = [
|
||||
"Wdk_System_SystemServices",
|
||||
"Win32_Security_Cryptography",
|
||||
"Win32_Security",
|
||||
"Win32_Storage_FileSystem",
|
||||
"Win32_System_IO",
|
||||
"Win32_System_Memory",
|
||||
"Win32_System_Pipes",
|
||||
"Win32_System_ProcessStatus",
|
||||
"Win32_System_Services",
|
||||
"Win32_System_Threading",
|
||||
"Win32_UI_Shell",
|
||||
"Win32_UI_WindowsAndMessaging",
|
||||
] }
|
||||
anyhow = { workspace = true }
|
||||
base64 = { workspace = true }
|
||||
tokio = { workspace = true, features = ["full"] }
|
||||
tracing = { workspace = true }
|
||||
tracing-subscriber = { workspace = true }
|
||||
|
||||
[build-dependencies]
|
||||
embed-resource = "=3.0.6"
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
@ -0,0 +1,9 @@
|
||||
fn main() {
|
||||
if std::env::var("CARGO_CFG_TARGET_OS").expect("to be set by cargo") == "windows" {
|
||||
println!("cargo:rerun-if-changed=resources.rc");
|
||||
|
||||
embed_resource::compile("resources.rc", embed_resource::NONE)
|
||||
.manifest_optional()
|
||||
.expect("to compile resources");
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
1 ICON "../../resources/icon.ico"
|
||||
@ -0,0 +1,13 @@
|
||||
#[cfg(target_os = "windows")]
|
||||
mod windows;
|
||||
|
||||
#[cfg(target_os = "windows")]
|
||||
#[tokio::main]
|
||||
async fn main() {
|
||||
windows::main().await;
|
||||
}
|
||||
|
||||
#[cfg(not(target_os = "windows"))]
|
||||
fn main() {
|
||||
// Empty
|
||||
}
|
||||
Loading…
Reference in new issue