From 4586a0ffea7e6fbb270a8282345ae436d77ec459 Mon Sep 17 00:00:00 2001 From: Xiphoseer Date: Wed, 3 Jan 2024 23:08:32 +0100 Subject: [PATCH] fix: dCommon --- CMakeLists.txt | 4 ---- dDatabase/CDClientDatabase/CMakeLists.txt | 6 +++++- dDatabase/GameDatabase/CMakeLists.txt | 6 +++++- dGame/dInventory/CMakeLists.txt | 1 + dGame/dPropertyBehaviors/CMakeLists.txt | 1 + dPhysics/CMakeLists.txt | 6 +++++- 6 files changed, 17 insertions(+), 7 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6fbe4a00..5463f8a3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -212,10 +212,6 @@ add_subdirectory(thirdparty) # Create our list of include directories set(INCLUDED_DIRECTORIES - "dCommon" - "dCommon/dClient" - "dCommon/dEnums" - "dChatFilter" "dPhysics" diff --git a/dDatabase/CDClientDatabase/CMakeLists.txt b/dDatabase/CDClientDatabase/CMakeLists.txt index f83bd6a4..13d59ffb 100644 --- a/dDatabase/CDClientDatabase/CMakeLists.txt +++ b/dDatabase/CDClientDatabase/CMakeLists.txt @@ -10,7 +10,11 @@ foreach(file ${DDATABASE_CDCLIENTDATABASE_CDCLIENTTABLES_SOURCES}) endforeach() add_library(dDatabaseCDClient STATIC ${DDATABASE_CDCLIENTDATABASE_SOURCES}) -target_include_directories(dDatabaseCDClient PUBLIC "." "CDClientTables") +target_include_directories(dDatabaseCDClient PUBLIC "." + "CDClientTables" + "${PROJECT_SOURCE_DIR}/dCommon" + "${PROJECT_SOURCE_DIR}/dCommon/dEnums" +) target_link_libraries(dDatabaseCDClient PRIVATE sqlite3) if (${CDCLIENT_CACHE_ALL}) diff --git a/dDatabase/GameDatabase/CMakeLists.txt b/dDatabase/GameDatabase/CMakeLists.txt index c9897e2e..8805b267 100644 --- a/dDatabase/GameDatabase/CMakeLists.txt +++ b/dDatabase/GameDatabase/CMakeLists.txt @@ -9,7 +9,11 @@ foreach(file ${DDATABSE_DATABSES_MYSQL_SOURCES}) endforeach() add_library(dDatabaseGame STATIC ${DDATABASE_GAMEDATABASE_SOURCES}) -target_include_directories(dDatabaseGame PUBLIC "." "ITables" PRIVATE "MySQL") +target_include_directories(dDatabaseGame PUBLIC "." + "ITables" PRIVATE "MySQL" + "${PROJECT_SOURCE_DIR}/dCommon" + "${PROJECT_SOURCE_DIR}/dCommon/dEnums" +) target_link_libraries(dDatabaseGame PUBLIC mariadbConnCpp INTERFACE dCommon) diff --git a/dGame/dInventory/CMakeLists.txt b/dGame/dInventory/CMakeLists.txt index c4bcc11e..605c6df0 100644 --- a/dGame/dInventory/CMakeLists.txt +++ b/dGame/dInventory/CMakeLists.txt @@ -9,6 +9,7 @@ add_library(dInventory STATIC ${DGAME_DINVENTORY_SOURCES}) target_include_directories(dInventory PUBLIC "." "${PROJECT_SOURCE_DIR}/dGame/dUtilities" # Item.h uses Preconditions.h PRIVATE + "${PROJECT_SOURCE_DIR}/dCommon/dClient" # Item.cpp uses AssetManager "${PROJECT_SOURCE_DIR}/dGame/dGameMessages" # direct "${PROJECT_SOURCE_DIR}/dGame/dComponents" # direct InventoryComponent.h "${PROJECT_SOURCE_DIR}/dGame/dBehaviors" # via InventoryComponent.h diff --git a/dGame/dPropertyBehaviors/CMakeLists.txt b/dGame/dPropertyBehaviors/CMakeLists.txt index 42fe7449..201f5ae8 100644 --- a/dGame/dPropertyBehaviors/CMakeLists.txt +++ b/dGame/dPropertyBehaviors/CMakeLists.txt @@ -16,6 +16,7 @@ add_library(dPropertyBehaviors STATIC ${DGAME_DPROPERTYBEHAVIORS_SOURCES}) target_link_libraries(dPropertyBehaviors PRIVATE dDatabaseCDClient) target_include_directories(dPropertyBehaviors PUBLIC "." "ControlBehaviorMessages" PRIVATE + "${PROJECT_SOURCE_DIR}/dCommon/dClient" # ControlBehaviors.cpp uses AssetManager "${PROJECT_SOURCE_DIR}/dGame/dGameMessages" # GameMessages.h "${PROJECT_SOURCE_DIR}/dGame/dComponents" # ModelComponent.h ) diff --git a/dPhysics/CMakeLists.txt b/dPhysics/CMakeLists.txt index 340e4c3c..65588b4b 100644 --- a/dPhysics/CMakeLists.txt +++ b/dPhysics/CMakeLists.txt @@ -7,6 +7,10 @@ set(DPHYSICS_SOURCES "dpCollisionChecks.cpp" "dpWorld.cpp") add_library(dPhysics STATIC ${DPHYSICS_SOURCES}) +target_include_directories(dPhysics PUBLIC "." + "${PROJECT_SOURCE_DIR}/dCommon" + "${PROJECT_SOURCE_DIR}/dCommon/dEnums" +) target_link_libraries(dPhysics PUBLIC Recast Detour - INTERFACE dNavigation) + INTERFACE dNavigation dCommon)