diff options
| author | Takoroka <137927095+Takoroka@users.noreply.github.com> | 2026-10-29 11:06:57 -0400 |
|---|---|---|
| committer | Takoroka <137927095+Takoroka@users.noreply.github.com> | 2026-10-29 11:06:57 -0400 |
| commit | 73cad97d7146c8ad00b4d89170420cdcdbacbd5f (patch) | |
| tree | 7b2030ec9b0ab86dfd3ebcd09247351d8ec5cf92 | |
| parent | 134310b81ece47d3409cd937e4e572a468c55a5f (diff) | |
eden-cli: use the wmain entry point in Release builds
MSVC builds define UNICODE, so SDL's main implementation provides wmain and wWinMain but no main.
The Release-only /ENTRY:mainCRTStartup then failed to link eden-cli.exe (LNK2019: unresolved
external symbol main). RelWithDebInfo and Debug were not affected: they don't set an entry point.
| -rw-r--r-- | src/yuzu_cmd/CMakeLists.txt | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/yuzu_cmd/CMakeLists.txt b/src/yuzu_cmd/CMakeLists.txt index a87b4e5288..ca8db523ee 100644 --- a/src/yuzu_cmd/CMakeLists.txt +++ b/src/yuzu_cmd/CMakeLists.txt @@ -58,7 +58,8 @@ endif() if(WIN32) # compile as a win32 gui application instead of a console application if(MSVC) - set_target_properties(yuzu-cmd PROPERTIES LINK_FLAGS_RELEASE "/SUBSYSTEM:WINDOWS /ENTRY:mainCRTStartup") + # UNICODE is defined, so SDL's entry point is wmain, not main + set_target_properties(yuzu-cmd PROPERTIES LINK_FLAGS_RELEASE "/SUBSYSTEM:WINDOWS /ENTRY:wmainCRTStartup") elseif(MINGW) set_target_properties(yuzu-cmd PROPERTIES LINK_FLAGS_RELEASE "-Wl,--subsystem,windows") endif() |
