Add a way to explicitly specify RC toolkit path (#18402)
Closes #18393 Release Notes: - Added a `ZED_RC_TOOLKIT_PATH` env variable so `winresource` crate can fetch the RC executable path correctly on some configurations
This commit is contained in:
parent
707ccb04d2
commit
57ad5778fa
2 changed files with 34 additions and 0 deletions
|
@ -56,6 +56,13 @@ fn main() {
|
|||
println!("cargo:rerun-if-changed={}", icon.display());
|
||||
|
||||
let mut res = winresource::WindowsResource::new();
|
||||
|
||||
// Depending on the security applied to the computer, winresource might fail
|
||||
// fetching the RC path. Therefore, we add a way to explicitly specify the
|
||||
// toolkit path, allowing winresource to use a valid RC path.
|
||||
if let Some(explicit_rc_toolkit_path) = std::env::var("ZED_RC_TOOLKIT_PATH").ok() {
|
||||
res.set_toolkit_path(explicit_rc_toolkit_path.as_str());
|
||||
}
|
||||
res.set_icon(icon.to_str().unwrap());
|
||||
res.set("FileDescription", "Zed");
|
||||
res.set("ProductName", "Zed");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue