[PR #6818] [MERGED] Native mod builds: no space in the Windows build folder #7112

Closed
opened 2026-11-03 06:34:08 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/6818
Author: @ludovic111
Created: 11/2/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: fix/windres-space-path


📝 Commits (1)

  • 4ed4269 Native mod builds: no space in the Windows build folder

📊 Changes

2 files changed (+25 additions, -6 deletions)

View changed files

📝 crates/horizon-client/build.rs (+9 -1)
📝 launcher/src/backend.rs (+16 -5)

📄 Description

🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself.

Reported in #horizon-support: on Windows, building a native mod in the launcher (0.2.36) fails when the user name has a space:

ccl.exe: fatal error: v\: No such file or directory
ccl.exe: fatal error: mailwas\AppData\Roaming\horizon-launcher\native\stage\crates\horizon-client: No such file or directory
windres: preprocessing failed.
thread 'main' panicked at crates\horizon-client\build.rs:27:13:
embedding Windows resources: Could not compile resource file

MinGW's windres hands its include folders to the preprocessor unquoted, so C:\Users\First Last\AppData\… splits at the space.

Changes

  • launcher (backend.rs): new tool_safe = ASCII and, on Windows, no space. build_dir uses it, so a path with a space goes to the ProgramData build folder (horizon-launcher-<hash>). That's the folder the launcher already uses for non-ASCII user names (#5189, #6009). A test covers the rule.
  • horizon-client build.rs: outside CI, a failed resource compile prints a cargo warning and the build continues without the icon. This lets players whose launcher is older than this fix build from the next game source. In CI, where release builds are made (CI is set by GitHub Actions), it still panics, so a release can't ship without its icon.

Not tested on a Windows machine: none is available to the agent. The launcher job's Windows test runs the new assertion.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/6818 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 11/2/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/windres-space-path` --- ### 📝 Commits (1) - [`4ed4269`](https://github.com/horizon-rust/horizon/commit/4ed42694bcfe94d8761e545456d29e9491db2086) Native mod builds: no space in the Windows build folder ### 📊 Changes **2 files changed** (+25 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/build.rs` (+9 -1) 📝 `launcher/src/backend.rs` (+16 -5) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. Reported in #horizon-support: on Windows, building a native mod in the launcher (0.2.36) fails when the user name has a space: ``` ccl.exe: fatal error: v\: No such file or directory ccl.exe: fatal error: mailwas\AppData\Roaming\horizon-launcher\native\stage\crates\horizon-client: No such file or directory windres: preprocessing failed. thread 'main' panicked at crates\horizon-client\build.rs:27:13: embedding Windows resources: Could not compile resource file ``` MinGW's `windres` hands its include folders to the preprocessor unquoted, so `C:\Users\First Last\AppData\…` splits at the space. **Changes** - **launcher (`backend.rs`):** new `tool_safe` = ASCII and, on Windows, no space. `build_dir` uses it, so a path with a space goes to the ProgramData build folder (`horizon-launcher-<hash>`). That's the folder the launcher already uses for non-ASCII user names (#5189, #6009). A test covers the rule. - **horizon-client `build.rs`:** outside CI, a failed resource compile prints a cargo warning and the build continues without the icon. This lets players whose launcher is older than this fix build from the next game source. In CI, where release builds are made (`CI` is set by GitHub Actions), it still panics, so a release can't ship without its icon. Not tested on a Windows machine: none is available to the agent. The launcher job's Windows test runs the new assertion. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 06:34:08 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#7112
No description provided.