Merge pull request #12760 from AdmiralCurtiss/win-cmake-fix

Fix building with CMake on Windows
This commit is contained in:
Admiral H. Curtiss 2024-05-05 19:40:25 +02:00 committed by GitHub
commit 485bdba98e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 0 deletions

View File

@ -55,6 +55,7 @@ add_library(rcheevos
rcheevos/src/rc_version.c
rcheevos/src/rc_version.h
)
dolphin_disable_warnings(rcheevos)
target_include_directories(rcheevos PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/rcheevos/include")
target_include_directories(rcheevos INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}")

View File

@ -41,6 +41,11 @@ if(APPLE)
)
endif()
if(WIN32)
# needed for adjusting window decorations with DwmSetWindowAttribute
target_link_libraries(dolphin-nogui PRIVATE dwmapi.lib)
endif()
if(MSVC)
# Add precompiled header
target_link_libraries(dolphin-nogui PRIVATE use_pch)