Systematic fix for BUILD_RTI conditional compilation: - Lts/Common: Wrap all DDS-dependent libraries in IF(BUILD_RTI) - LtsAppManager, LtsCoordTrans, LtsCoordinate, LtsLogin - LtsMultiMonitor, LtsPluginManager, LtsPrinting - LtsProjectionWorkstation, LtsScriptTimeline, LtsSession - LtsTimelineClassic, LtsUtilsCore, LtsUtilsGui, LtsUtilsGuiDds - Lts/DDS: Add BUILD_RTI guards to Core, DDSConnector, DdsUnitTests, FTC, FTS - Lts/Plugins: Add BUILD_RTI guards to FilterManagement, OperatorManagement, SituationReplayManagement - Lts/Proxies: Add BUILD_RTI guards to Buildings, CombatNetRadio, ComponentMonitor, GuezNasat, TrainingAreaBase, TrainingAreaBaseOC - Lts/Services: Add BUILD_RTI guards to all 30+ service modules - Z/nglwidgets: Add BUILD_RTI guards, fix Poppler Qt6 headers Qt6 compatibility fixes: - LtsCoordTrans: QOverload signal signature, QChar constructor - LtsMultiMonitor: setMargin→setContentsMargins, remove deprecated HighQualityAntialiasing - nglwidgets: Poppler Qt5→Qt6 header migration - Add FindPopplerQt6.cmake for Qt6 Poppler detection Part of Qt5→Qt6 migration with RTI DDS support.
136 lines
2.8 KiB
CMake
Executable File
136 lines
2.8 KiB
CMake
Executable File
#
|
|
# $Id$
|
|
# $HeadURL$
|
|
# $Author$
|
|
#
|
|
|
|
INCLUDE(MacroRTIDDSGen)
|
|
INCLUDE(MacroCodeGenIdl)
|
|
|
|
SET(xml_FILE cod_service.xml)
|
|
|
|
#
|
|
# --- Library svcCodCommon --------------------------------------------------------------------------------
|
|
#
|
|
SET(SRCS_common
|
|
cod_export.h
|
|
logger.cpp
|
|
logger.h
|
|
)
|
|
|
|
# Generate cod_enums.idl / cod.idl
|
|
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
|
# Generate cod_db_impl.cpp/.h, cod_db.h
|
|
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
|
|
|
# Generate *.cpp/*.hpp from idl
|
|
RTIDDSGEN(SRCS_common cod_enums.idl)
|
|
RTIDDSGEN(SRCS_common cod.idl)
|
|
|
|
# Generate cod_dt[s,c]_types.h, cod_ft[s,c]_types.h
|
|
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
|
# generate cod_[d|f]tc.h
|
|
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
|
|
|
NGL_ADD_LIBRARY(AAR SV WS svcCodCommon SHARED ${SRCS_common})
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(svcCodCommon
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
|
)
|
|
IF(BUILD_RTI)
|
|
NGL_TARGET_LINK_LIBRARIES(svcCodCommon
|
|
PRIVATE
|
|
RTI::nddscpp2
|
|
PUBLIC
|
|
Qt6::Core
|
|
ddscore
|
|
ngldb
|
|
NGLLogger
|
|
)
|
|
ENDIF(BUILD_RTI)
|
|
NGL_INSTALL_TARGET(svcCodCommon)
|
|
|
|
#
|
|
# --- Library svcCodClient --------------------------------------------------------------------------------
|
|
#
|
|
SET(SRCS_client
|
|
cod_export.h
|
|
)
|
|
# generate cod_[d|f]tc_impl.[cpp|h]
|
|
CODEGEN_CLIENT_TOPICS_IMPL(SRCS_client ${xml_FILE})
|
|
|
|
NGL_ADD_LIBRARY(AAR SV WS svcCodClient SHARED ${SRCS_client})
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(svcCodClient
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
|
)
|
|
|
|
NGL_TARGET_LINK_LIBRARIES(svcCodClient
|
|
PRIVATE
|
|
RTI::nddscpp2
|
|
ddsconnector
|
|
PUBLIC
|
|
svcCodCommon
|
|
ddsftc
|
|
)
|
|
NGL_INSTALL_TARGET(svcCodClient)
|
|
|
|
#
|
|
# --- Library svcCodServer --------------------------------------------------------------------------------
|
|
#
|
|
SET(SRCS_server
|
|
cod_export.h
|
|
dds_handler.cpp
|
|
dds_handler.h
|
|
initialization.cpp
|
|
initialization.h
|
|
handler_codification_data.cpp
|
|
handler_codification_data.h
|
|
object_codification_data.cpp
|
|
object_codification_data.h
|
|
settings.cpp
|
|
settings.h
|
|
${xml_FILE}
|
|
)
|
|
# generate cod_[d|f]ts.h, cod_[d|f]ts_impl.[cpp|h]
|
|
CODEGEN_SERVER_TOPICS(SRCS_server ${xml_FILE})
|
|
# Generate cod.sql, cod.xml
|
|
CODEGEN_SQL(SRCS_server ${xml_FILE})
|
|
|
|
NGL_ADD_LIBRARY(AAR SV svcCodServer SHARED ${SRCS_server})
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(svcCodServer
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
|
)
|
|
|
|
NGL_TARGET_LINK_LIBRARIES(svcCodServer
|
|
PRIVATE
|
|
RTI::nddscpp2
|
|
ddsconnector
|
|
ddsfts
|
|
PUBLIC
|
|
svcCodCommon
|
|
Qt6::Core
|
|
svcCoreClient
|
|
ddsconnector
|
|
nglsettings
|
|
ngldb
|
|
ProjectConfig
|
|
NGLLogger
|
|
ngltools
|
|
)
|
|
NGL_INSTALL_TARGET(svcCodServer)
|
|
|
|
#
|
|
# --- Topic Type Plugin --------------------------------------------------------------
|
|
#
|
|
CREATE_TOPIC_TYPE_PLUGIN(${xml_FILE})
|
|
|
|
# Uncomment if necessary
|
|
#ADD_SUBDIRECTORY(UnitTests)
|
|
#ADD_SUBDIRECTORY(ModuleTests)
|
|
|