mirror of
https://github.com/OpenMW/openmw.git
synced 2026-01-24 18:00:53 +00:00
Ensure Win32 character set definitions are consistent
Qt 6 made it so anything that linked with it had the defines that put the Win32 API into UTF-16 mode. That means that components (which we reuse the PCH for in multiple targets now) had incompatible defines, and the PCHs wouldn't work. Before CMP0204, CMake wouldn't set these defines at all except with the Visual Studio generators, so this wasn't causing any problems that caused a compile error when I tested a Ninja-based build.
This commit is contained in:
parent
24d07da29c
commit
4ea6374a9e
1 changed files with 7 additions and 0 deletions
|
|
@ -408,6 +408,13 @@ if (WIN32)
|
|||
-DNOMB # name conflict with MWGui::MessageBox
|
||||
-DNOGDI # name conflict with osgAnimation::MorphGeometry::RELATIVE
|
||||
)
|
||||
|
||||
# Put Win32 API into UTF-16 mode
|
||||
# We really don't care, but targets linking with Qt 6 (not 5 and earlier) inherit this, and mixing and matching stops us reusing precompiled headers
|
||||
add_compile_definitions(
|
||||
_UNICODE
|
||||
UNICODE
|
||||
)
|
||||
endif()
|
||||
|
||||
if(OPENMW_USE_SYSTEM_BULLET)
|
||||
|
|
|
|||
Loading…
Reference in a new issue