From 9effa3d68f49ea71c8e5207f2498015fd52bdb5e Mon Sep 17 00:00:00 2001 From: Matt Raykowski Date: Tue, 8 Jun 2010 10:06:58 -0500 Subject: [PATCH] Chanegd: #842 Added more server services and tools to the build. --- code/ryzom/server/src/CMakeLists.txt | 19 +++++----- .../server/src/gpm_service/CMakeLists.txt | 24 +++++++++++++ .../src/input_output_service/CMakeLists.txt | 35 +++++++++++++++++++ .../src/patchman_service/CMakeLists.txt | 31 ++++++++++++++++ .../deployment_configuration_synchroniser.h | 2 +- .../src/patchman_service/file_receiver.h | 2 +- .../src/patchman_service/file_repository.h | 2 +- .../patchman_service/mysql_wrapper_stub.cpp | 2 +- .../src/patchman_service/repository.cpp | 7 ++-- .../server/src/patchman_service/repository.h | 2 +- code/ryzom/tools/CMakeLists.txt | 3 +- code/ryzom/tools/assoc_mem/CMakeLists.txt | 2 +- code/ryzom/tools/server/CMakeLists.txt | 11 ++++++ .../tools/server/ai_build_wmap/CMakeLists.txt | 17 +++++++++ .../ai_build_wmap/build_proximity_maps.cpp | 3 +- 15 files changed, 143 insertions(+), 19 deletions(-) create mode 100644 code/ryzom/server/src/gpm_service/CMakeLists.txt create mode 100644 code/ryzom/server/src/input_output_service/CMakeLists.txt create mode 100644 code/ryzom/server/src/patchman_service/CMakeLists.txt create mode 100644 code/ryzom/tools/server/CMakeLists.txt create mode 100644 code/ryzom/tools/server/ai_build_wmap/CMakeLists.txt diff --git a/code/ryzom/server/src/CMakeLists.txt b/code/ryzom/server/src/CMakeLists.txt index c338d5875..3e3ef3c5b 100644 --- a/code/ryzom/server/src/CMakeLists.txt +++ b/code/ryzom/server/src/CMakeLists.txt @@ -1,29 +1,30 @@ +# Supporting modules and libraries. ADD_SUBDIRECTORY(admin_modules) ADD_SUBDIRECTORY(server_share) ADD_SUBDIRECTORY(ai_share) ADD_SUBDIRECTORY(gameplay_module_lib) ADD_SUBDIRECTORY(pd_lib) -ADD_SUBDIRECTORY(frontend_service) -ADD_SUBDIRECTORY(entities_game_service) +# Ryzom Services ADD_SUBDIRECTORY(ai_service) ADD_SUBDIRECTORY(backup_service) ADD_SUBDIRECTORY(dynamic_scenario_service) +ADD_SUBDIRECTORY(entities_game_service) +ADD_SUBDIRECTORY(frontend_service) +ADD_SUBDIRECTORY(gpm_service) +ADD_SUBDIRECTORY(input_output_service) + # Deprecated, no longer used. +#ADD_SUBDIRECTORY(ags_test) #ADD_SUBDIRECTORY(ai_data_service) #ADD_SUBDIRECTORY(entity_view_service) #ADD_SUBDIRECTORY(general_utilities_service) +#ADD_SUBDIRECTORY(patchman_service) -#ags_test -# -# -# - -# #gpm_service -#input_output_service +# #log_analyser_service #logger_service #mail_forum_service diff --git a/code/ryzom/server/src/gpm_service/CMakeLists.txt b/code/ryzom/server/src/gpm_service/CMakeLists.txt new file mode 100644 index 000000000..80ed486bc --- /dev/null +++ b/code/ryzom/server/src/gpm_service/CMakeLists.txt @@ -0,0 +1,24 @@ +FILE(GLOB SRC *.cpp *.h) + +ADD_EXECUTABLE(gpm_service ${SRC}) + +INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/server/src ${LIBXML2_INCLUDE_DIR} ${MYSQL_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} ${NEL_INCLUDE_DIR}) +TARGET_LINK_LIBRARIES(gpm_service admin_modules + game_share + server_share + ${PLATFORM_LINKFLAGS} + ${LIBXML2_LIBRARIES} + ${NELMISC_LIBRARY} + ${NELNET_LIBRARY} + ${NELPACS_LIBRARY} + ${NELGEORGES_LIBRARY} + ${NELLIGO_LIBRARY}) +IF(WIN32) + SET_TARGET_PROPERTIES(gpm_service PROPERTIES + LINK_FLAGS "/NODEFAULTLIB:libcmt /SUBSYSTEM:WINDOWS" + PROJECT_LABEL "Services: Global Position Manager Service (GPMS)") +ENDIF(WIN32) +ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) + +INSTALL(TARGETS gpm_service RUNTIME DESTINATION sbin COMPONENT services) + diff --git a/code/ryzom/server/src/input_output_service/CMakeLists.txt b/code/ryzom/server/src/input_output_service/CMakeLists.txt new file mode 100644 index 000000000..ae87eedb1 --- /dev/null +++ b/code/ryzom/server/src/input_output_service/CMakeLists.txt @@ -0,0 +1,35 @@ +FILE(GLOB SRC *.cpp *.h) + +LIST(REMOVE_ITEM SRC ${CMAKE_CURRENT_SOURCE_DIR}/bot_chat_manager.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/bot_chat_manager.h + ${CMAKE_CURRENT_SOURCE_DIR}/ios_chat_log.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/ios_chat_log.h + ${CMAKE_CURRENT_SOURCE_DIR}/ios_chat_log_inline.h + ${CMAKE_CURRENT_SOURCE_DIR}/ios_pd.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/ios_pd.h + ${CMAKE_CURRENT_SOURCE_DIR}/ios_pd_inline.h) + +ADD_EXECUTABLE(ios_service ${SRC}) + +INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/server/src ${LIBXML2_INCLUDE_DIR} ${MYSQL_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} ${NEL_INCLUDE_DIR}) +TARGET_LINK_LIBRARIES(ios_service admin_modules + pd_lib + game_share + server_share + ${PLATFORM_LINKFLAGS} + ${LIBXML2_LIBRARIES} + ${NELMISC_LIBRARY} + ${NELNET_LIBRARY} + ${NELPACS_LIBRARY} + ${NELGEORGES_LIBRARY} + ${NELLIGO_LIBRARY}) +IF(WIN32) + SET_TARGET_PROPERTIES(ios_service PROPERTIES + LINK_FLAGS "/NODEFAULTLIB:libcmt /SUBSYSTEM:WINDOWS" + PROJECT_LABEL "Services: Input Ouput Service (IOS)") +ENDIF(WIN32) +ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) + +INSTALL(TARGETS ios_service RUNTIME DESTINATION sbin COMPONENT services) + + diff --git a/code/ryzom/server/src/patchman_service/CMakeLists.txt b/code/ryzom/server/src/patchman_service/CMakeLists.txt new file mode 100644 index 000000000..aeffe1b6c --- /dev/null +++ b/code/ryzom/server/src/patchman_service/CMakeLists.txt @@ -0,0 +1,31 @@ +FILE(GLOB SRC *.cpp *.h) + +LIST(REMOVE_ITEM SRC ${CMAKE_CURRENT_SOURCE_DIR}/Backup\ 1\ of\ file_repository.h + ${CMAKE_CURRENT_SOURCE_DIR}/rr_module_itf.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/rr_module_itf.h) + +ADD_EXECUTABLE(patchman_service ${SRC}) + +INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/server/src ${LIBXML2_INCLUDE_DIR} ${MYSQL_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} ${NEL_INCLUDE_DIR}) +TARGET_LINK_LIBRARIES(patchman_service admin_modules + game_share + server_share + ${PLATFORM_LINKFLAGS} + ${LIBXML2_LIBRARIES} + ${MYSQL_LIBRARIES} + ${ZLIB_LIBRARIES} + ${NELMISC_LIBRARY} + ${NELNET_LIBRARY} + ${NELPACS_LIBRARY} + ${NELGEORGES_LIBRARY} + ${NELLIGO_LIBRARY}) +IF(WIN32) + SET_TARGET_PROPERTIES(patchman_service PROPERTIES + LINK_FLAGS "/NODEFAULTLIB:libcmt /SUBSYSTEM:WINDOWS" + PROJECT_LABEL "Services: Patch Manager (PMS)") +ENDIF(WIN32) +ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) + +INSTALL(TARGETS patchman_service RUNTIME DESTINATION sbin COMPONENT services) + + diff --git a/code/ryzom/server/src/patchman_service/deployment_configuration_synchroniser.h b/code/ryzom/server/src/patchman_service/deployment_configuration_synchroniser.h index e5b4c8603..2ab136413 100644 --- a/code/ryzom/server/src/patchman_service/deployment_configuration_synchroniser.h +++ b/code/ryzom/server/src/patchman_service/deployment_configuration_synchroniser.h @@ -23,7 +23,7 @@ //----------------------------------------------------------------------------- // game share -#include "game_share/deployment_configuration.h" +//#include "game_share/deployment_configuration.h" // local #include "module_admin_itf.h" diff --git a/code/ryzom/server/src/patchman_service/file_receiver.h b/code/ryzom/server/src/patchman_service/file_receiver.h index 7e006e3d2..b58180dac 100644 --- a/code/ryzom/server/src/patchman_service/file_receiver.h +++ b/code/ryzom/server/src/patchman_service/file_receiver.h @@ -23,7 +23,7 @@ //----------------------------------------------------------------------------- // game share -#include "game_share/deployment_configuration.h" +//#include "game_share/deployment_configuration.h" // local #include "module_admin_itf.h" diff --git a/code/ryzom/server/src/patchman_service/file_repository.h b/code/ryzom/server/src/patchman_service/file_repository.h index edd26fe69..daebd896d 100644 --- a/code/ryzom/server/src/patchman_service/file_repository.h +++ b/code/ryzom/server/src/patchman_service/file_repository.h @@ -45,7 +45,7 @@ #include "nel/net/module_builder_parts.h" // game share -#include "game_share/deployment_configuration.h" +//#include "game_share/deployment_configuration.h" // local #include "module_admin_itf.h" diff --git a/code/ryzom/server/src/patchman_service/mysql_wrapper_stub.cpp b/code/ryzom/server/src/patchman_service/mysql_wrapper_stub.cpp index 942f7f6cf..43b7df9bc 100644 --- a/code/ryzom/server/src/patchman_service/mysql_wrapper_stub.cpp +++ b/code/ryzom/server/src/patchman_service/mysql_wrapper_stub.cpp @@ -14,5 +14,5 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . -#include "game_share/mysql_wrapper.cpp" +#include "server_share/mysql_wrapper.cpp" diff --git a/code/ryzom/server/src/patchman_service/repository.cpp b/code/ryzom/server/src/patchman_service/repository.cpp index f89e17995..b71c11ef2 100644 --- a/code/ryzom/server/src/patchman_service/repository.cpp +++ b/code/ryzom/server/src/patchman_service/repository.cpp @@ -36,11 +36,14 @@ using namespace std; using namespace NLMISC; - //------------------------------------------------------------------------------------------------- // constants & utilities //------------------------------------------------------------------------------------------------- +// From spa_server_patch_applier.cpp +extern void writeVersionFile(const NLMISC::CSString& fileName, uint32 version); +extern uint32 readVersionFile(const NLMISC::CSString& fileName); + NLMISC::CSString getRepositoryIndexFileName(const NLMISC::CSString& repositoryName) { return "repository_"+repositoryName+".idx"; @@ -380,7 +383,7 @@ CRepository::const_iterator CRepository::end() const return _Files.end(); } -void CRepository::fillShortList(TFileInfoVector &files) const +void CRepository::fillShortList(PATCHMAN::TFileInfoVector &files) const { // start by clearing out any previous contents in the files vector files.clear(); diff --git a/code/ryzom/server/src/patchman_service/repository.h b/code/ryzom/server/src/patchman_service/repository.h index 314f52768..ed8949c52 100644 --- a/code/ryzom/server/src/patchman_service/repository.h +++ b/code/ryzom/server/src/patchman_service/repository.h @@ -110,7 +110,7 @@ public: iterator end(); const_iterator end() const; - void fillShortList(TFileInfoVector &files) const; + void fillShortList(PATCHMAN::TFileInfoVector &files) const; private: diff --git a/code/ryzom/tools/CMakeLists.txt b/code/ryzom/tools/CMakeLists.txt index aa418f7fd..695c59518 100644 --- a/code/ryzom/tools/CMakeLists.txt +++ b/code/ryzom/tools/CMakeLists.txt @@ -11,11 +11,12 @@ ADD_SUBDIRECTORY(pdr_util) ADD_SUBDIRECTORY(stats_scan) ADD_SUBDIRECTORY(sheets_packer) +ADD_SUBDIRECTORY(server) + # Old stuff that doesn't compile anymore. #ADD_SUBDIRECTORY(occ2huff) #ADD_SUBDIRECTORY(phrase_generator) #ADD_SUBDIRECTORY(sheet_random_generator) -#- this relies on something in the client # Not building these #xml_packer - this is in NeL tools. diff --git a/code/ryzom/tools/assoc_mem/CMakeLists.txt b/code/ryzom/tools/assoc_mem/CMakeLists.txt index d1f9ad3a3..2593f848f 100644 --- a/code/ryzom/tools/assoc_mem/CMakeLists.txt +++ b/code/ryzom/tools/assoc_mem/CMakeLists.txt @@ -6,7 +6,7 @@ LIST(REMOVE_ITEM SRC ADD_EXECUTABLE(assoc_mem ${SRC}) -INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR} ${NELMISC_INCLUDE_DIRS}) +INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR} ${NEL_INCLUDE_DIR}) TARGET_LINK_LIBRARIES(assoc_mem ${PLATFORM_LINKFLAGS} ${LIBXML2_LIBRARIES} ${NELMISC_LIBRARY}) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) diff --git a/code/ryzom/tools/server/CMakeLists.txt b/code/ryzom/tools/server/CMakeLists.txt new file mode 100644 index 000000000..7244c865a --- /dev/null +++ b/code/ryzom/tools/server/CMakeLists.txt @@ -0,0 +1,11 @@ +# Deprecated, no longer used +#ADD_SUBDIRECTORY(ai_build_wmap) + +# Not done yet. +#admin +#brick_param_extractor +#build_spell_sheet +#build_world_packed_col +#CMakeLists.txt +#sql +#www diff --git a/code/ryzom/tools/server/ai_build_wmap/CMakeLists.txt b/code/ryzom/tools/server/ai_build_wmap/CMakeLists.txt new file mode 100644 index 000000000..5ac473f79 --- /dev/null +++ b/code/ryzom/tools/server/ai_build_wmap/CMakeLists.txt @@ -0,0 +1,17 @@ +FILE(GLOB SRC *.cpp *.h) + +ADD_EXECUTABLE(ai_build_wmap ${SRC}) + +INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/server/src + ${CMAKE_SOURCE_DIR}/common/src + ${LIBXML2_INCLUDE_DIR} + ${NEL_INCLUDE_DIR}) +TARGET_LINK_LIBRARIES(ai_build_wmap game_share + server_share + ai_share + ${PLATFORM_LINKFLAGS} + ${LIBXML2_LIBRARIES} + ${NELMISC_LIBRARY}) +ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) + +INSTALL(TARGETS ai_build_wmap RUNTIME DESTINATION bin COMPONENT tools) diff --git a/code/ryzom/tools/server/ai_build_wmap/build_proximity_maps.cpp b/code/ryzom/tools/server/ai_build_wmap/build_proximity_maps.cpp index 76eaa8c2e..2d5b13716 100644 --- a/code/ryzom/tools/server/ai_build_wmap/build_proximity_maps.cpp +++ b/code/ryzom/tools/server/ai_build_wmap/build_proximity_maps.cpp @@ -24,9 +24,10 @@ #include "nel/misc/command.h" #include "nel/misc/path.h" #include "nel/misc/sstring.h" +#include "nel/misc/file.h" // Game share -#include "game_share/bmp4image.h" +#include "server_share/bmp4image.h" // AI share #include "ai_share/world_map.h"