From 728aaccbbb4fc48c54ea795c7da75f8c5faf37c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Camilla=20L=C3=B6wy?= Date: Tue, 20 Apr 2021 15:37:48 +0200 Subject: [PATCH] Win32: Always define UNICODE and _UNICODE (cherry picked from commit 9a3a8bc26799f9a57f62ab7980537a48090c89e7) --- src/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 7f434baf..6fbf7f69 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -132,7 +132,7 @@ elseif (CMAKE_C_COMPILER_ID STREQUAL "GNU" OR endif() if (_GLFW_WIN32) - target_compile_definitions(glfw PRIVATE _UNICODE) + target_compile_definitions(glfw PRIVATE UNICODE _UNICODE) endif() # HACK: When building on MinGW, WINVER and UNICODE need to be defined before @@ -140,7 +140,7 @@ endif() # win32_platform.h. We define them here until a saner solution can be found # NOTE: MinGW-w64 and Visual C++ do /not/ need this hack. if (MINGW) - target_compile_definitions(glfw PRIVATE UNICODE WINVER=0x0501) + target_compile_definitions(glfw PRIVATE WINVER=0x0501) endif() if (BUILD_SHARED_LIBS)