Update: #842 Fix for linking issue with ai_share and added ai_service (fails final linking)

This commit is contained in:
Matt Raykowski 2010-05-13 21:45:50 -05:00
parent 7e4a8206a5
commit bb940c536f
4 changed files with 51 additions and 11 deletions

View file

@ -6,17 +6,17 @@ ADD_SUBDIRECTORY(pd_lib)
ADD_SUBDIRECTORY(frontend_service)
ADD_SUBDIRECTORY(entities_game_service)
ADD_SUBDIRECTORY(ai_service)
# Deprecated, no longer used.
#ADD_SUBDIRECTORY(ai_data_service)
#ags_test
#ai_data_service
#ai_service
#ai_share
#
#backup_service
#dynamic_scenario_service
#entity_view_service
#frontend_service
#gameplay_module_lib
#general_utilities_service
#gpm_service
#input_output_service
@ -26,7 +26,6 @@ ADD_SUBDIRECTORY(entities_game_service)
#mirror_service
#monitor_service
#patchman_service
#pd_lib
#pd_reference_builder
#pd_support_service
#persistant_data_service

View file

@ -0,0 +1,43 @@
FILE(GLOB SRC *.cpp *.h)
LIST(REMOVE_ITEM SRC ${CMAKE_CURRENT_SOURCE_DIR}/ai_entity_id.cpp
${CMAKE_CURRENT_SOURCE_DIR}/ai_entity_id.h
${CMAKE_CURRENT_SOURCE_DIR}/ai_entity_id_inline.h
${CMAKE_CURRENT_SOURCE_DIR}/ai_world_map.cpp
${CMAKE_CURRENT_SOURCE_DIR}/ai_world_map.h
${CMAKE_CURRENT_SOURCE_DIR}/combat_move.cpp
${CMAKE_CURRENT_SOURCE_DIR}/combat_move.h
${CMAKE_CURRENT_SOURCE_DIR}/gpms_interface.cpp
${CMAKE_CURRENT_SOURCE_DIR}/gpms_interface.h
${CMAKE_CURRENT_SOURCE_DIR}/ios_interface.cpp
${CMAKE_CURRENT_SOURCE_DIR}/ios_interface.h
${CMAKE_CURRENT_SOURCE_DIR}/Backup\ 1\ of\ ai_profile_fauna.h
${CMAKE_CURRENT_SOURCE_DIR}/Backup\ 1\ of\ profile.h
${CMAKE_CURRENT_SOURCE_DIR}/Backup\ 1\ of\ stdpch.h)
ADD_EXECUTABLE(ai_service ${SRC})
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/server/src ${LIBXML2_INCLUDE_DIR} ${MYSQL_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} ${NEL_INCLUDE_DIR})
TARGET_LINK_LIBRARIES(ai_service admin_modules
game_share
ai_share
${PLATFORM_LINKFLAGS}
${LIBXML2_LIBRARIES}
${MYSQL_LIBRARIES}
${ZLIB_LIBRARIES}
${NELMISC_LIBRARY}
${NELNET_LIBRARY}
${NELGEORGES_LIBRARY}
${NELLIGO_LIBRARY})
IF(WIN32)
SET_TARGET_PROPERTIES(ai_service PROPERTIES
LINK_FLAGS "/NODEFAULTLIB:libcmt /SUBSYSTEM:WINDOWS"
PROJECT_LABEL "Services: Frontend Service (FS)")
ENDIF(WIN32)
ADD_DEFINITIONS(${LIBXML2_DEFINITIONS})
INSTALL(TARGETS ai_service RUNTIME DESTINATION sbin COMPONENT services)

View file

@ -899,6 +899,8 @@ CAliasTreeOwner *CGroupDesc<FamilyT>::createChild(IAliasCont *cont, CAIAliasDesc
case AITYPES::AITypeBotTemplateMultiLevel:
child = new CBotDesc<FamilyT>(this, aliasTree->getAlias(), aliasTree->getName());
break;
default:
break;
}
if (child)

View file

@ -3,11 +3,7 @@ FILE(GLOB SRC *.cpp *.h)
# Filter out the source files not actually compiled.
#LIST(REMOVE_ITEM SRC ${CMAKE_CURRENT_SOURCE_DIR}/Backup\ 1\ of\ admin_modules.cpp)
IF(WIN32)
ADD_LIBRARY(ai_share STATIC ${SRC})
ELSE(WIN32)
ADD_LIBRARY(ai_share SHARED ${SRC})
ENDIF(WIN32)
ADD_LIBRARY(ai_share STATIC ${SRC})
INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR} ${NEL_INCLUDE_DIR})
TARGET_LINK_LIBRARIES(ai_share ${NELMISC_LIBRARY} ${NELNET_LIBRARY} ${NELGEORGES_LIBRARY} ${NELPACS_LIBRARY})