Reworks CMake wiring for Qt6 codegen include order
Adds missing toolchain packages and include dirs so generated headers resolve.
This commit is contained in:
25 files changed
+388
-84
No files matched your search
@@ -6,14 +6,14 @@
|
||||
|
||||
# Make ${Qt6_Gui} optional
|
||||
if(QT6_GUI_AVAILABLE AND TARGET Qt6::Gui)
|
||||
set(Qt6_Gui ${Qt6_Gui})
|
||||
set(Qt6_Gui Qt6::Gui)
|
||||
else()
|
||||
set(Qt6_Gui "")
|
||||
endif()
|
||||
|
||||
# Make ${Qt6_Widgets} optional
|
||||
if(QT6_GUI_AVAILABLE AND TARGET Qt6::Widgets)
|
||||
set(Qt6_Widgets ${Qt6_Widgets})
|
||||
set(Qt6_Widgets Qt6::Widgets)
|
||||
else()
|
||||
set(Qt6_Widgets "")
|
||||
endif()
|
||||
@@ -70,12 +70,10 @@ LIST(APPEND SRCS_common ${in_file_sql} ${out_file_sql})
|
||||
# Generate aes_enums.idl / aes.idl / aes_enums.cpp/aes_enums.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
# Stub enum header for tests when BUILD_RTI=ON but no IDL
|
||||
IF(NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/aes_enums.idl")
|
||||
CONFIGURE_FILE("${CMAKE_SOURCE_DIR}/include/AreaEffectSimulation/aes_enums.hpp.stub"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/aes_enums.hpp"
|
||||
COPYONLY)
|
||||
ENDIF()
|
||||
# The former stub copy for aes_enums.hpp ran unconditionally here: its
|
||||
# IF(NOT EXISTS) guard checked the source dir, but CODEGEN_IDL_SVC writes
|
||||
# aes_enums.idl into the build dir, so the stub always overwrote the
|
||||
# rtiddsgen-generated header on re-configure. Removed for the ON build.
|
||||
ENDIF()
|
||||
# Generate aes_db_structs.cpp/.h
|
||||
CODEGEN_DATABASE_STRUCTS(SRCS_common ${xml_FILE})
|
||||
|
||||
@@ -26,6 +26,10 @@ ENDIF()
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy asm_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/AssetManagement/asm_enums.hpp.stub
|
||||
@@ -34,6 +38,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate *.cpp/*.hpp from idl
|
||||
RTIDDSGEN(SRCS_common asm_enums.idl)
|
||||
RTIDDSGEN(SRCS_common asm.idl)
|
||||
|
||||
@@ -122,12 +122,17 @@ SET_SOURCE_FILES_PROPERTIES(list_response_collector.cpp PROPERTIES SKIP_UNITY_BU
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/AudioVideoManagement/avm_enums.hpp.stub
|
||||
${CMAKE_BINARY_DIR}/Lts/Services/AudioVideoManagement/avm_enums.hpp
|
||||
COPYONLY
|
||||
)
|
||||
ENDIF()
|
||||
# Generate avm_db.h, avm_db_impl.cpp/.h
|
||||
CODEGEN_DATABASE_SQL(SRCS_common ${xml_FILE})
|
||||
|
||||
@@ -136,6 +141,10 @@ IF(BUILD_RTI)
|
||||
RTIDDSGEN(SRCS_common avm_enums.idl)
|
||||
RTIDDSGEN(SRCS_common avm.idl)
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy avm_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/AudioVideoManagement/avm_enums.hpp.stub
|
||||
@@ -144,6 +153,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate avm_dt[s,c]_types.h, avm_ft[s,c]_types.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
@@ -152,6 +162,10 @@ ENDIF()
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy avm_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/AudioVideoManagement/avm_enums.hpp.stub
|
||||
@@ -160,6 +174,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate avm_db_structs.cpp/.h
|
||||
CODEGEN_DATABASE_STRUCTS(SRCS_common ${xml_FILE})
|
||||
|
||||
|
||||
@@ -4,9 +4,15 @@
|
||||
# $Author$
|
||||
#
|
||||
|
||||
# Make ${Qt6_WebSockets} optional
|
||||
if(QT6_GUI_AVAILABLE AND TARGET Qt6::WebSockets)
|
||||
set(Qt6_WebSockets ${Qt6_WebSockets})
|
||||
# Link the real WebSockets module whenever the websocket code path is
|
||||
# compiled: QT6_WEBSOCKETS_AVAILABLE (root CMakeLists) and the manual
|
||||
# Qt6::WebSockets import are set when the real module was found. The old
|
||||
# QT6_GUI_AVAILABLE condition never holds in this environment (Qt6
|
||||
# discovery takes the minimal path) and the Qt6_WebSockets variable was
|
||||
# never defined, so the websocket code compiled without the module on the
|
||||
# link line and failed only at link time.
|
||||
if(QT6_WEBSOCKETS_REAL_FOUND OR Qt6WebSockets_FOUND)
|
||||
set(Qt6_WebSockets Qt6::WebSockets)
|
||||
else()
|
||||
set(Qt6_WebSockets "")
|
||||
endif()
|
||||
@@ -30,6 +36,10 @@ SET(SRCS_common
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/ExerciseEventManagement/eem_enums.hpp.stub
|
||||
@@ -37,6 +47,7 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
# Generate eem_db_structs.cpp/.h
|
||||
CODEGEN_DATABASE_STRUCTS(SRCS_common ${xml_FILE})
|
||||
# Generate eem_db_impl.cpp/.h
|
||||
@@ -47,6 +58,10 @@ IF(BUILD_RTI)
|
||||
RTIDDSGEN(SRCS_common eem_enums.idl)
|
||||
RTIDDSGEN(SRCS_common eem.idl)
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy eem_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/ExerciseEventManagement/eem_enums.hpp.stub
|
||||
@@ -55,6 +70,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate eem_dt[s,c]_types.h, eem_ft[s,c]_types.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
|
||||
@@ -18,6 +18,10 @@ SET(SRCS_common
|
||||
logger.h
|
||||
)
|
||||
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy stub file to build directory (fallback when IDL files don't exist)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/ExerciseManagement/exm_enums.hpp.stub
|
||||
@@ -25,6 +29,7 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
IF(BUILD_RTI)
|
||||
# Generate exm_enums.idl / exm.idl
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
@@ -37,12 +42,6 @@ IF(BUILD_RTI)
|
||||
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
# generate exm_[d|f]tc.h
|
||||
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
||||
ELSE()
|
||||
# BUILD_RTI=OFF: Use manual stub headers from include/
|
||||
LIST(APPEND SRCS_common
|
||||
${CMAKE_SOURCE_DIR}/include/ExerciseManagement/exm_db.h
|
||||
${CMAKE_SOURCE_DIR}/include/ExerciseManagement/exm_enums.hpp
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
NGL_ADD_LIBRARY(AAR SV WS HLA svcExmCommon SHARED ${SRCS_common})
|
||||
|
||||
@@ -158,6 +158,11 @@ NGL_TARGET_LINK_LIBRARIES(svcFilterManagement
|
||||
LtsCommandLineParser
|
||||
svcCoreClient
|
||||
svcFltServer
|
||||
# main_handler.cpp includes <DDS/DDSConnector/dds_connector.h>; the
|
||||
# ddsconnector link in svcFltClient/svcFltServer is PRIVATE and does not
|
||||
# propagate its exported include dirs (with ddsconnector_export.h) to
|
||||
# this executable's own TUs.
|
||||
$<IF:$<TARGET_EXISTS:ddsconnector>,ddsconnector,>
|
||||
)
|
||||
|
||||
NGL_INSTALL_TARGET(svcFilterManagement)
|
||||
|
||||
+21
-17
@@ -7,7 +7,7 @@
|
||||
|
||||
# Make ${Qt6_Gui} optional
|
||||
if(QT6_GUI_AVAILABLE AND TARGET Qt6::Gui)
|
||||
set(Qt6_Gui ${Qt6_Gui})
|
||||
set(Qt6_Gui Qt6::Gui)
|
||||
else()
|
||||
set(Qt6_Gui "")
|
||||
endif()
|
||||
@@ -32,6 +32,10 @@ SET(SRCS_common
|
||||
# Generate ism_enums.idl / ism.idl
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/InfrastructureManagement/ism_enums.hpp.stub
|
||||
@@ -39,10 +43,15 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
ENDIF()
|
||||
ENDIF()
|
||||
# Generate ism_db_impl.cpp/.h, ism_db.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy ism_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/InfrastructureManagement/ism_enums.hpp.stub
|
||||
@@ -51,11 +60,16 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate *.cpp/*.hpp from idl
|
||||
IF(BUILD_RTI)
|
||||
RTIDDSGEN(SRCS_common ism_enums.idl)
|
||||
RTIDDSGEN(SRCS_common ism.idl)
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy ism_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/InfrastructureManagement/ism_enums.hpp.stub
|
||||
@@ -64,21 +78,17 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate ism_dt[s,c]_types.h, ism_ft[s,c]_types.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# Generate ism_[d|f]tc.h
|
||||
# The former BUILD_GRANTLEE=OFF fallback copied handwritten ism_dtc.h /
|
||||
# ism_ftc.h onto the CODEGEN_CLIENT_TOPICS_IFC output paths; those fake
|
||||
# generated files were removed (the qt5 legacy has no such source files).
|
||||
IF(BUILD_GRANTLEE)
|
||||
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
||||
ELSEIF(BUILD_RTI)
|
||||
# Use pre-generated files when BUILD_GRANTLEE=OFF
|
||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/ism_dtc.h ${CMAKE_CURRENT_BINARY_DIR}/ism_dtc.h COPYONLY)
|
||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/ism_ftc.h ${CMAKE_CURRENT_BINARY_DIR}/ism_ftc.h COPYONLY)
|
||||
LIST(APPEND SRCS_common
|
||||
${CMAKE_CURRENT_BINARY_DIR}/ism_dtc.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/ism_ftc.h
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
NGL_ADD_LIBRARY(AAR SV WS HLA svcIsmCommon SHARED ${SRCS_common})
|
||||
@@ -111,16 +121,10 @@ SET(SRCS_client
|
||||
parse_building_xml.h
|
||||
)
|
||||
# generate ism_[d|f]tc_impl.[cpp|h]
|
||||
# ism_dtc_impl_custom.cpp/.h are real service sources (as in the qt5 legacy);
|
||||
# the BUILD_GRANTLEE=OFF copy of them onto codegen output paths was removed.
|
||||
IF(BUILD_GRANTLEE)
|
||||
CODEGEN_CLIENT_TOPICS_IMPL(SRCS_client ${xml_FILE})
|
||||
ELSEIF(BUILD_RTI)
|
||||
# Use pre-generated files when BUILD_GRANTLEE=OFF
|
||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/ism_dtc_impl_custom.cpp ${CMAKE_CURRENT_BINARY_DIR}/ism_dtc_impl_custom.cpp COPYONLY)
|
||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/ism_dtc_impl_custom.h ${CMAKE_CURRENT_BINARY_DIR}/ism_dtc_impl_custom.h COPYONLY)
|
||||
LIST(APPEND SRCS_client
|
||||
${CMAKE_CURRENT_BINARY_DIR}/ism_dtc_impl_custom.cpp
|
||||
${CMAKE_CURRENT_BINARY_DIR}/ism_dtc_impl_custom.h
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
NGL_ADD_LIBRARY(AAR SV WS HLA svcIsmClient SHARED ${SRCS_client})
|
||||
|
||||
@@ -22,6 +22,10 @@ SET(SRCS_common
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/NotificationManagement/nom_enums.hpp.stub
|
||||
@@ -29,10 +33,15 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
# Generate nom_db_impl.cpp/.h, nom_db.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy nom_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/NotificationManagement/nom_enums.hpp.stub
|
||||
@@ -41,6 +50,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate *.cpp/*.hpp from idl
|
||||
RTIDDSGEN(SRCS_common nom_enums.idl)
|
||||
RTIDDSGEN(SRCS_common nom.idl)
|
||||
|
||||
@@ -18,6 +18,10 @@ SET(SRCS_common
|
||||
logger.h
|
||||
)
|
||||
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy stub file to build directory (fallback when IDL files don't exist)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/OperatorManagement/opm_enums.hpp.stub
|
||||
@@ -25,6 +29,7 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
IF(BUILD_RTI)
|
||||
# Generate opm_enums.idl / opm.idl
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
@@ -37,12 +42,6 @@ IF(BUILD_RTI)
|
||||
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
# generate opm_[d|f]tc.h
|
||||
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
||||
ELSE()
|
||||
# BUILD_RTI=OFF: Use manual stub headers from include/
|
||||
LIST(APPEND SRCS_common
|
||||
${CMAKE_SOURCE_DIR}/include/OperatorManagement/opm_db.h
|
||||
${CMAKE_SOURCE_DIR}/include/OperatorManagement/opm_enums.hpp
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
NGL_ADD_LIBRARY(AAR SV WS svcOpmCommon SHARED ${SRCS_common})
|
||||
|
||||
@@ -11,9 +11,15 @@ else()
|
||||
set(Qt6_Gui "")
|
||||
endif()
|
||||
|
||||
# Make ${Qt6_WebSockets} optional
|
||||
if(QT6_GUI_AVAILABLE AND TARGET Qt6::WebSockets)
|
||||
set(Qt6_WebSockets ${Qt6_WebSockets})
|
||||
# Link the real WebSockets module whenever the websocket code path is
|
||||
# compiled: QT6_WEBSOCKETS_AVAILABLE (root CMakeLists) and the manual
|
||||
# Qt6::WebSockets import are set when the real module was found. The old
|
||||
# QT6_GUI_AVAILABLE condition never holds in this environment (Qt6
|
||||
# discovery takes the minimal path) and the Qt6_WebSockets variable was
|
||||
# never defined, so the websocket code compiled without the module on the
|
||||
# link line and failed only at link time.
|
||||
if(QT6_WEBSOCKETS_REAL_FOUND OR Qt6WebSockets_FOUND)
|
||||
set(Qt6_WebSockets Qt6::WebSockets)
|
||||
else()
|
||||
set(Qt6_WebSockets "")
|
||||
endif()
|
||||
@@ -44,6 +50,10 @@ IF(BUILD_RTI)
|
||||
RTIDDSGEN(SRCS_common ppm_enums.idl)
|
||||
RTIDDSGEN(SRCS_common ppm.idl)
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/ParticipantManagement/ppm_enums.hpp.stub
|
||||
@@ -51,6 +61,7 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
# Generate ppm_db_structs.cpp/.h
|
||||
CODEGEN_DATABASE_STRUCTS(SRCS_common ${xml_FILE})
|
||||
# Generate ppm_db.cpp, ppm_db_impl.cpp/.h
|
||||
|
||||
@@ -20,35 +20,14 @@ SET(SRCS_common
|
||||
logger.h
|
||||
)
|
||||
|
||||
# Copy pdm_types.h to build directory
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/../../../include/ProjectDataManagement/pdm_types.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/pdm_types.h
|
||||
COPYONLY
|
||||
)
|
||||
# pdm_types.h was a migration-scaffolding stub with no qt5 counterpart and
|
||||
# no consumer; the stub in include/ was removed and the copy with it.
|
||||
|
||||
# Copy pdm_translation.h to build directory
|
||||
# Only when BUILD_GRANTLEE=OFF (stub header). With BUILD_GRANTLEE=ON the
|
||||
# codegen writes the real pdm_translation.h to the same build-dir path
|
||||
# (see "Generating ... pdm_translation.h" in CODEGEN_IDL_SVC); copying the
|
||||
# stub here would overwrite the generated file on every cmake re-configure
|
||||
# and break incremental builds. Same guard pattern as pdm_enums.hpp below.
|
||||
IF(NOT BUILD_GRANTLEE)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/../../../include/ProjectDataManagement/pdm_translation.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/pdm_translation.h
|
||||
COPYONLY
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
# Copy pdm_enums.hpp to build directory (when BUILD_RTI=OFF)
|
||||
IF(NOT BUILD_RTI)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/../../../include/ProjectDataManagement/pdm_enums.hpp
|
||||
${CMAKE_CURRENT_BINARY_DIR}/pdm_enums.hpp
|
||||
COPYONLY
|
||||
)
|
||||
ENDIF()
|
||||
# pdm_translation.h and pdm_enums.hpp stub copies (OFF-variant fallbacks whose
|
||||
# include/ sources were removed together with the other shadowing stubs):
|
||||
# with BUILD_GRANTLEE=ON and BUILD_RTI=ON the codegen writes the real files to
|
||||
# these build-dir paths, so the copies are gone rather than kept for forbidden
|
||||
# OFF variants.
|
||||
|
||||
# Add current binary dir to include path for generated headers
|
||||
NGL_TARGET_INCLUDE_DIRECTORIES(${PDM_COMMON_TARGET}
|
||||
|
||||
@@ -20,6 +20,10 @@ SET(SRCS_common
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/ReportManagement/rep_enums.hpp.stub
|
||||
@@ -27,10 +31,15 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
# Generate rep_db_impl.cpp/.h, rep_db.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy rep_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/ReportManagement/rep_enums.hpp.stub
|
||||
@@ -39,6 +48,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate *.cpp/*.hpp from idl
|
||||
RTIDDSGEN(SRCS_common rep_enums.idl)
|
||||
RTIDDSGEN(SRCS_common rep.idl)
|
||||
|
||||
@@ -22,6 +22,10 @@ SET(SRCS_common
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_IDL_SVC(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Stub file for compilation (fallback when no IDL exists)
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/SituationReplay/srp_enums.hpp.stub
|
||||
@@ -29,10 +33,15 @@ CONFIGURE_FILE(
|
||||
COPYONLY
|
||||
)
|
||||
|
||||
ENDIF()
|
||||
# Generate srp_db_impl.cpp/.h, srp_db.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_DATABASE(SRCS_common ${xml_FILE})
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy srp_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/SituationReplay/srp_enums.hpp.stub
|
||||
@@ -41,11 +50,16 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate *.cpp/*.hpp from idl
|
||||
IF(BUILD_RTI)
|
||||
RTIDDSGEN(SRCS_common srp_enums.idl)
|
||||
RTIDDSGEN(SRCS_common srp.idl)
|
||||
ENDIF()
|
||||
# The enums stub copy below would overwrite the rtiddsgen-generated
|
||||
# <svc>_enums.hpp (RTIDDSGEN on <svc>_enums.idl writes the same build-dir
|
||||
# path) on every cmake re-configure. Only keep it for BUILD_RTI=OFF.
|
||||
IF(NOT BUILD_RTI)
|
||||
# Copy srp_enums.hpp.stub to build directory for compilation
|
||||
CONFIGURE_FILE(
|
||||
${CMAKE_SOURCE_DIR}/include/SituationReplay/srp_enums.hpp.stub
|
||||
@@ -54,6 +68,7 @@ CONFIGURE_FILE(
|
||||
)
|
||||
|
||||
|
||||
ENDIF()
|
||||
# Generate srp_dt[s,c]_types.h, srp_ft[s,c]_types.h
|
||||
IF(BUILD_RTI)
|
||||
CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
|
||||
Reference in new issue
Block a user