Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Fix Windows builds from non-ASCII checkout paths (#64947)
Prohect263fb111771c
diff --git a/crates/windows_resources/src/windows_resources.rs b/crates/windows_resources/src/windows_resources.rsindex fee3e7368bd..3cc5e5ef7ac 100644--- a/crates/windows_resources/src/windows_resources.rs+++ b/crates/windows_resources/src/windows_resources.rs@@ -73,8 +73,14 @@ pub fn compile(manifest: bool) -> Result<(), Box<dyn std::error::Error>> {version_parts.next().unwrap_or(0),);+ // The resource paths can contain non-ASCII characters (e.g. when the+ // repository lives under a path with such characters). Rust Strings are+ // encoded using UTF-8, but rc.exe decodes the .rc file using the ANSI code+ // page by default, which mangles those paths and makes it fail to find the+ // referenced files, so specify UTF-8 decoding.let rc_content = format!(- r#"1 ICON "{icon_escaped}"+ r#"#pragma code_page(65001)+1 ICON "{icon_escaped}"{manifest_line}1 VERSIONINFO