fix(relinker): support non-ASCII input paths on Windows #2751
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2751"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by aplatogg on 2026-10-10T12:51:32Z.
What
Fixes #2692. On Windows the relinker could not convert a game whose path contains characters outside the local ANSI code page.
Root cause chain:
argvtomainas ANSI code page bytes (main.cpp)std::filesystem::paththrough the same code page (implicit conversion at theGuestModuleBuilder::Buildcall,FileReader/FileWriter,WindowsPePatchericon path)Fix:
wmainvia-municode, arguments encoded once to UTF-8 (main.cpp)Io::NativePath/Io::Utf8Path(core/relinker/io) convert between the UTF-8 strings the relinker passes around and nativestd::filesystem::pathvalues at the filesystem boundaries (FileReader,FileWriter,main.cppcall sites)--autorunon Windows launches the output throughCreateProcessWinstead ofstd::system, so it inherits no code page limitationTested
Windows (WinLibs GCC 15.2.0 ucrt, the toolchain from BUILD.md), relinker-only build:
ctest: 94/94 passed, including the newinput_nonasciitest (converts fixtures from a directory namedигрыwith sources namedпроба.elf,ゲーム.elf,próba m².elf,--windows+--registry, asserts exit 0 and theMZoutput)python3 tools/check_conventions.py --base origin/main: all conventions checks passedCannot open fileChecklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-10T12:51:41Z.
Thank you for your interest in the project! We are sorry, but we cannot accept more PRs while we work through the existing backlog. This PR has been automatically closed and labeled "intake paused". This is not a judgment of the quality of your changes.
Pull request closed