diff options
Diffstat (limited to 'src/common/CMakeLists.txt')
-rw-r--r-- | src/common/CMakeLists.txt | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index 328cc4faad..22c7d5fd76 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -16,8 +16,21 @@ CollectSourceFiles( # Exclude ${CMAKE_CURRENT_SOURCE_DIR}/Debugging ${CMAKE_CURRENT_SOURCE_DIR}/Platform + ${CMAKE_CURRENT_SOURCE_DIR}/Collision + ${CMAKE_CURRENT_SOURCE_DIR}/Navigation ${CMAKE_CURRENT_SOURCE_DIR}/PrecompiledHeaders) +if (BUILD_APPLICATION_WORLDSERVER OR BUILD_TOOLS_MAPS) + unset(PRIVATE_SOURCES) + CollectSourceFiles( + ${CMAKE_CURRENT_SOURCE_DIR} + PRIVATE_SOURCES + # Exclude + ${CMAKE_CURRENT_SOURCE_DIR}/Debugging + ${CMAKE_CURRENT_SOURCE_DIR}/Platform + ${CMAKE_CURRENT_SOURCE_DIR}/PrecompiledHeaders) +endif() + # Manually set sources for Debugging directory as we don't want to include WheatyExceptionReport in common project # It needs to be included both in authserver and worldserver for the static global variable to be properly initialized # and to handle crash logs on windows @@ -55,8 +68,6 @@ target_link_libraries(common PUBLIC boost argon2 - g3dlib - Detour sfmt utf8cpp openssl @@ -65,6 +76,13 @@ target_link_libraries(common stdfs fmt) +if (BUILD_APPLICATION_WORLDSERVER OR BUILD_TOOLS_MAPS) + target_link_libraries(common + PUBLIC + g3dlib + Detour) +endif() + set_target_properties(common PROPERTIES FOLDER |