230 lines
5.3 KiB
CMake
Executable File
230 lines
5.3 KiB
CMake
Executable File
# $Id$
|
|
# $HeadURL$
|
|
# $Author$
|
|
|
|
INCLUDE(MacroRTIDDSGen)
|
|
INCLUDE(MacroCodeGenIdl)
|
|
|
|
SET(xml_FILE rep_service.xml)
|
|
|
|
#
|
|
# --- Library svcRepCommon --------------------------------------------------------------------------------
|
|
#
|
|
SET(SRCS_common
|
|
rep_export.h
|
|
logger.cpp
|
|
logger.h
|
|
)
|
|
|
|
# Generate rep_enums.idl / rep.idl
|
|
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
|
# Generate rep_db_impl.cpp/.h, rep_db.h
|
|
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
|
|
|
# Generate *.cpp/*.hpp from idl
|
|
RTIDDSGEN(SRCS_common rep_enums.idl)
|
|
RTIDDSGEN(SRCS_common rep.idl)
|
|
|
|
# Generate rep_dt[s,c]_types.h, rep_ft[s,c]_types.h
|
|
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
|
# generate rep_[d|f]tc.h
|
|
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
|
|
|
NGL_ADD_LIBRARY(AAR SV WS svcRepCommon SHARED ${SRCS_common})
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(svcRepCommon
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
|
)
|
|
NGL_TARGET_LINK_LIBRARIES(svcRepCommon
|
|
PRIVATE
|
|
RTI::nddscpp2
|
|
PUBLIC
|
|
Qt5::Core
|
|
ddscore
|
|
NGLLogger
|
|
ngldb
|
|
svcPdmCommon
|
|
LtsUtilsCoreHeaderOnly
|
|
)
|
|
NGL_INSTALL_TARGET(svcRepCommon)
|
|
|
|
#
|
|
# --- Library svcRepClient --------------------------------------------------------------------------------
|
|
#
|
|
SET(SRCS_client
|
|
rep_export.h
|
|
)
|
|
# generate rep_[d|f]tc_impl.[cpp|h]
|
|
CODEGEN_CLIENT_TOPICS_IMPL(SRCS_client ${xml_FILE})
|
|
|
|
NGL_ADD_LIBRARY(AAR SV WS svcRepClient SHARED ${SRCS_client})
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(svcRepClient
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
|
)
|
|
|
|
NGL_TARGET_LINK_LIBRARIES(svcRepClient
|
|
PRIVATE
|
|
RTI::nddscpp2
|
|
ddsconnector
|
|
PUBLIC
|
|
svcRepCommon
|
|
ddsftc
|
|
)
|
|
NGL_INSTALL_TARGET(svcRepClient)
|
|
|
|
#
|
|
# --- Library svcRepServer --------------------------------------------------------------------------------
|
|
#
|
|
SET(SRCS_server
|
|
rep_export.h
|
|
)
|
|
# generate rep_[d|f]ts.h, rep_[d|f]ts_impl.[cpp|h]
|
|
CODEGEN_SERVER_TOPICS(SRCS_server ${xml_FILE})
|
|
|
|
NGL_ADD_LIBRARY(AAR SV svcRepServer SHARED ${SRCS_server})
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(svcRepServer
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
|
)
|
|
|
|
NGL_TARGET_LINK_LIBRARIES(svcRepServer
|
|
PRIVATE
|
|
RTI::nddscpp2
|
|
ddsconnector
|
|
ddsfts
|
|
PUBLIC
|
|
svcRepCommon
|
|
ngldb
|
|
)
|
|
NGL_INSTALL_TARGET(svcRepServer)
|
|
|
|
#
|
|
# --- Topic Type Plugin --------------------------------------------------------------
|
|
#
|
|
CREATE_TOPIC_TYPE_PLUGIN(${xml_FILE})
|
|
|
|
|
|
#
|
|
# --- Shared Executable parts for svcReportAnalyzer and svcReportGenerator ---------
|
|
#
|
|
# Generate rep.sql, rep.xml
|
|
CODEGEN_SQL(SHARED_SRCS_exe ${xml_FILE})
|
|
NGL_ADD_LIBRARY(AAR SV svcRepCommonExecutable STATIC ${SHARED_SRCS_exe})
|
|
NGL_TARGET_LINK_LIBRARIES(svcRepCommonExecutable
|
|
PUBLIC
|
|
Qt5::Core
|
|
Qt5::Sql
|
|
svcRepCommon
|
|
)
|
|
|
|
#
|
|
# --- Executable svcReportAnalyzer (sREA) -------------------------------------------------
|
|
#
|
|
SET(ANALYZER_SRCS_exe
|
|
Analyzer/main.cpp
|
|
settings.cpp
|
|
settings.h
|
|
dds_handler.cpp
|
|
dds_handler.h
|
|
Analyzer/handler_dynamic_participant_data.cpp
|
|
Analyzer/handler_dynamic_participant_data.h
|
|
Analyzer/main_handler.cpp
|
|
Analyzer/main_handler.h
|
|
${xml_FILE}
|
|
)
|
|
|
|
NGL_ADD_SVC_ICON(ANALYZER_SRCS_exe)
|
|
NGL_ADD_EXECUTABLE(AAR SV svcReportAnalyzer ${ANALYZER_SRCS_exe})
|
|
NGL_TARGET_LINK_LIBRARIES(svcReportAnalyzer
|
|
Qt5::Core
|
|
svcRepCommonExecutable
|
|
svcRepCommon
|
|
svcRepServer
|
|
svcPpmClient
|
|
svcAesClient
|
|
svcGimClient
|
|
svcCoreClient
|
|
svcPdmClient
|
|
svcBldClient
|
|
ddsconnector
|
|
nglsettings
|
|
ProjectConfig
|
|
LtsCommandLineParser
|
|
NGLLogger
|
|
nglcoreapplication
|
|
ngltools
|
|
LtsCoordTrans
|
|
)
|
|
NGL_INSTALL_TARGET(svcReportAnalyzer)
|
|
NGL_INSTALL(AAR SV FILES log4cxx_rep.props DESTINATION bin)
|
|
NGL_ADD_TARGET_LINK(svcReportAnalyzer sREA)
|
|
|
|
#
|
|
# --- Executable svcReportGenerator (sREG) -------------------------------------------------
|
|
#
|
|
SET(GENERATOR_SRCS_exe
|
|
settings.cpp
|
|
settings.h
|
|
dds_handler.cpp
|
|
dds_handler.h
|
|
Generator/handler_charge_administration.cpp
|
|
Generator/handler_report_air_support.cpp
|
|
Generator/handler_report_building_damage.cpp
|
|
Generator/handler_report_charge_resupply.cpp
|
|
Generator/handler_report_data.cpp
|
|
Generator/handler_report_data.h
|
|
Generator/handler_report_firings.cpp
|
|
Generator/handler_report_get_data.cpp
|
|
Generator/handler_report_get_data.h
|
|
Generator/handler_report_maintenance.cpp
|
|
Generator/handler_report_mine_area.cpp
|
|
Generator/handler_report_nbc.cpp
|
|
Generator/handler_report_participant_distance.cpp
|
|
Generator/handler_report_unit_power.cpp
|
|
Generator/handler_sanitation_material.cpp
|
|
Generator/handler_medevac_nine_liner.cpp
|
|
Generator/handler_report_treatment.cpp
|
|
Generator/handler_report_treatment_timeline.cpp
|
|
Generator/main.cpp
|
|
Generator/main_handler.cpp
|
|
Generator/main_handler.h
|
|
Generator/object_report_info.cpp
|
|
Generator/object_report_info.h
|
|
${xml_FILE}
|
|
)
|
|
|
|
NGL_ADD_SVC_ICON(GENERATOR_SRCS_exe)
|
|
NGL_ADD_EXECUTABLE(AAR SV svcReportGenerator ${GENERATOR_SRCS_exe})
|
|
NGL_TARGET_LINK_LIBRARIES(svcReportGenerator
|
|
Qt5::Core
|
|
nglcoreapplication
|
|
ngltools
|
|
nglsettings
|
|
NGLLogger
|
|
ddsconnector
|
|
svcCoreClient
|
|
svcRepCommonExecutable
|
|
svcRepCommon
|
|
svcRepServer
|
|
svcPreServer
|
|
svcBldCommon
|
|
svcAesClient
|
|
svcPpmClient
|
|
ProjectConfig
|
|
LtsCommandLineParser
|
|
LtsCoordTrans
|
|
LtsUtilsCoreHeaderOnly
|
|
)
|
|
NGL_INSTALL_TARGET(svcReportGenerator)
|
|
NGL_ADD_TARGET_LINK(svcReportGenerator sREG)
|
|
|
|
|
|
# Uncomment if necessary
|
|
#ADD_SUBDIRECTORY(UnitTests)
|
|
ADD_SUBDIRECTORY(ModuleTests)
|
|
|