From e067c21b0dda2543c01762c1d58818fa36a93bd0 Mon Sep 17 00:00:00 2001 From: berrux_dev Date: Wed, 21 Oct 2026 13:50:10 +0200 Subject: [PATCH] Enable Codification/OHP/PlanEditor/OrgChart plugin groups (G12 225); harden new_docker_build.sh First-build fixes (DDS members, Qt6 transitive WebChannel/PrintSupport drops, logger init, Qt5 guard); script: log_warn, BUILD_WLS default ON, Poppler image+APT, XmlPatterns 6.0 wording --- qt6-after/qt6-migrated-legatus/.envrc | 1 + qt6-after/qt6-migrated-legatus/CMakeLists.txt | 31 +++ .../cod_assign_codification_data_table.cpp | 14 +- .../ParticipantManagement/CMakeLists.txt | 5 +- .../Gui/ParticipantOrgChart/CMakeLists.txt | 3 + .../participant_org_chart.cpp | 33 ++-- .../participant_org_chart.h | 3 +- .../Lts/Plugins/PlanEditor/CMakeLists.txt | 3 + .../Gui/plan_editor_gui_plugin.cpp | 58 +++--- .../Gui/plan_editor_gui_plugin.h | 2 +- .../qt6-migrated-legatus/new_docker_build.sh | 186 +++++++++++++++++- 11 files changed, 278 insertions(+), 61 deletions(-) diff --git a/qt6-after/qt6-migrated-legatus/.envrc b/qt6-after/qt6-migrated-legatus/.envrc index ea7026e9e..ccbc58ca6 100644 --- a/qt6-after/qt6-migrated-legatus/.envrc +++ b/qt6-after/qt6-migrated-legatus/.envrc @@ -1,4 +1,5 @@ # export MIGRATE_PIPELINE_ROOT="/home/torsten/sandbox/qt6-migration-pipeline" export MIGRATE_PIPELINE_ROOT="/home/nkana/repo/qt6-migration-pipeline" +export CLAUDE_CODE_MAX_OUTPUT_TOKENS=16000 export LANG=C.UTF-8 export LC_ALL=C.UTF-8 \ No newline at end of file diff --git a/qt6-after/qt6-migrated-legatus/CMakeLists.txt b/qt6-after/qt6-migrated-legatus/CMakeLists.txt index a9042d043..87bc4a0a3 100755 --- a/qt6-after/qt6-migrated-legatus/CMakeLists.txt +++ b/qt6-after/qt6-migrated-legatus/CMakeLists.txt @@ -360,6 +360,37 @@ if(NOT Qt6_FOUND) message(STATUS "Found Qt6 (minimal): ${Qt6Core_VERSION}") endif() +# Qt6::XmlPatterns (consumed by the MSDL/Saab import libs, gated by +# BUILD_PLUGINS_MSDL / BUILD_PLUGINS_SAAB): the XmlPatterns module (its own +# qtxmlpatterns repo) was removed in Qt 6.0 and never re-introduced, so no Qt 6 +# install carries it. It is NOT part of the component lists above (a missing +# component there would flip Qt6_FOUND off and disable the whole GUI path). +# Find it separately; when absent the two plugins must stay disabled - their +# CMakeLists reference Qt6::XmlPatterns in link libraries and CMake errors at +# generate time for an undefined namespaced target. +if(NOT TARGET Qt6::XmlPatterns) + find_package(Qt6XmlPatterns QUIET) + if(Qt6XmlPatterns_FOUND) + message(STATUS "Found Qt6XmlPatterns") + else() + message(STATUS "Qt6XmlPatterns not found (PpmMSDLGuiPlugin/PpmSAABGuiPlugin require it; keep BUILD_PLUGINS_MSDL/BUILD_PLUGINS_SAAB OFF)") + endif() +endif() + +# Qt6::WebChannel (consumed by PpmOrgChartGuiPlugin's QWebChannel page setup): +# in Qt5 Qt5::WebEngineWidgets transitively linked Qt5::WebChannel (Qt5's +# webengine depended on webchannel), but Qt6 dropped that dependency, so the +# module must be found and linked explicitly. Separate QUIET find - never let +# a missing optional component flip Qt6_FOUND off. +if(NOT TARGET Qt6::WebChannel) + find_package(Qt6 6.2 COMPONENTS WebChannel QUIET) + if(Qt6WebChannel_FOUND) + message(STATUS "Found Qt6WebChannel") + else() + message(STATUS "Qt6WebChannel not found (PpmOrgChartGuiPlugin requires it; keep BUILD_PLUGINS_PARTICIPANT_ORG_CHART OFF)") + endif() +endif() + # Manual Qt6 configuration - create imported targets for available libraries if(NOT TARGET Qt6::Core) find_package(Qt6 6.2 COMPONENTS Core REQUIRED) diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/CodificationManagement/Gui/CodificationData/cod_assign_codification_data_table.cpp b/qt6-after/qt6-migrated-legatus/Lts/Plugins/CodificationManagement/Gui/CodificationData/cod_assign_codification_data_table.cpp index d9e0ad4fe..38eaba6c2 100644 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/CodificationManagement/Gui/CodificationData/cod_assign_codification_data_table.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/CodificationManagement/Gui/CodificationData/cod_assign_codification_data_table.cpp @@ -64,20 +64,20 @@ bool AssignCodificationDataTable::init(const std::shared_ptrpartyLayout->addWidget(new QLabel(partyName, this), i, 0, 1, 1); LtsWidgets::LtsComboBox* cb = new LtsWidgets::LtsComboBox(this); - cb->setProperty(QLatin1String("partyId").data(), party.id()); + cb->setProperty(QLatin1String("partyId").data(), party.id); m_tableVec.append(cb); cb->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Preferred); cb->addItem(QStringLiteral("---"), 0); @@ -88,7 +88,7 @@ bool AssignCodificationDataTable::init(const std::shared_ptrdata(m_model->index(row, CodificationDataOverviewModel::Id), Qt::DisplayRole)); DEBUG_LOG(m_logger) - << "Init Combobox[" << row << "]: PartyId: " << party.id() << " Identifier: " + << "Init Combobox[" << row << "]: PartyId: " << party.id << " Identifier: " << m_model->data(m_model->index(row, CodificationDataOverviewModel::Identifier), Qt::DisplayRole) .toString() << " CodTabId: " @@ -105,7 +105,7 @@ bool AssignCodificationDataTable::init(const std::shared_ptrdata(m_model->index(row, CodificationDataOverviewModel::Id), Qt::DisplayRole).toInt(); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/CMakeLists.txt b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/CMakeLists.txt index ccc9903c6..7af92847b 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/CMakeLists.txt +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/CMakeLists.txt @@ -91,7 +91,10 @@ ADD_INTERFACE_LIBRARY(PpmDataPluginInterface svcPpmCommon ) -IF(Qt5WebEngineWidgets_VERSION VERSION_GREATER 5.7.9) +# Qt6 Migration: legacy guarded on Qt5WebEngineWidgets_VERSION > 5.7.9; the +# Qt6 equivalent is that the Qt6::WebEngineWidgets target exists (consumer +# plugins are additionally gated by BUILD_PLUGINS_PARTICIPANT_ORG_CHART). +IF(TARGET Qt6::WebEngineWidgets) # # Combat Power Gui Plugin Interface # diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/CMakeLists.txt b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/CMakeLists.txt index 6196d3a23..a87fe3829 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/CMakeLists.txt +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/CMakeLists.txt @@ -44,6 +44,9 @@ if(QT6_GUI_AVAILABLE) ${Qt6_Widgets} Qt6::WebEngineCore Qt6::WebEngineWidgets + # Qt6 Migration: Qt5::WebEngineWidgets transitively linked Qt5::WebChannel; + # Qt6 dropped that dependency, so link the module explicitly. + Qt6::WebChannel LtsSession NGLLogger PUBLIC diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.cpp b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.cpp index e98f04287..21bd59f55 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.cpp @@ -2,6 +2,7 @@ #include "participant_org_chart.h" #include "ui_participant_org_chart.h" +#include #include #include @@ -16,9 +17,9 @@ namespace ParticipantManagement inline bool compareState(const StateInformation &a, const StateInformation &b) { - if (a.stateTime() != b.stateTime()) - return a.stateTime() < b.stateTime(); - return a.vulnerabilityState() < b.vulnerabilityState(); + if (a.stateTime != b.stateTime) + return a.stateTime < b.stateTime; + return a.vulnerabilityState < b.vulnerabilityState; } LtsParticipantsOrgChart::LtsParticipantsOrgChart(QWidget *parent) @@ -32,6 +33,7 @@ LtsParticipantsOrgChart::LtsParticipantsOrgChart(QWidget *parent) , m_dtc(nullptr) , m_asbItc(nullptr) , m_ui(new Ui::LtsParticipantsOrgChart) + , m_logger(NGL::NGLLoggerBootstrap::getNGLRootLogger()) { m_ui->setupUi(this); } @@ -137,16 +139,16 @@ void LtsParticipantsOrgChart::loadParty(int partyId) for (const ParticipantManagement::Participant &part : participantMap) { - if (part.isDeleted() || part.partyId() != m_partyId) + if (part.isDeleted || part.partyId != m_partyId) continue; - if (part.superiorId() == 0) + if (part.superiorId == 0) { root = part; break; } } - if (root.inferiorIds().size() == 0) + if (root.inferiorIds.size() == 0) { m_dataSource = preDefThing; m_ui->wevOrgChart->reload(); @@ -166,10 +168,10 @@ void LtsParticipantsOrgChart::loadParty(int partyId) connect(m_participantOrgChart_MimeDataHelper.data(), &ParticipantOrgChart_MimeDataHelper::finished, this, &LtsParticipantsOrgChart::onParticipantOrgChart_MimeDataHelperFinished); - m_participantOrgChart_MimeDataHelper->run(root.id(), + m_participantOrgChart_MimeDataHelper->run(root.id, false, - AdvancedSymbology::roleToRole<>(m_dtc->party(m_partyId).role()), - QColor::fromRgb(QRgb(m_dtc->party(m_partyId).color())), + AdvancedSymbology::roleToRole<>(m_dtc->party(m_partyId).role), + QColor::fromRgb(QRgb(m_dtc->party(m_partyId).color)), m_useSymData); } @@ -231,10 +233,10 @@ bool LtsParticipantsOrgChart::loadTemplate(int templateRootId) connect(m_participantOrgChart_MimeDataHelper.data(), &ParticipantOrgChart_MimeDataHelper::finished, this, &LtsParticipantsOrgChart::onParticipantOrgChart_MimeDataHelperFinished); - m_participantOrgChart_MimeDataHelper->run(root.templateId(), + m_participantOrgChart_MimeDataHelper->run(root.templateId, false, - AdvancedSymbology::roleToRole<>(m_dtc->party(m_partyId).role()), - QColor::fromRgb(QRgb(m_dtc->party(m_partyId).color())), + AdvancedSymbology::roleToRole<>(m_dtc->party(m_partyId).role), + QColor::fromRgb(QRgb(m_dtc->party(m_partyId).color)), false); return true; @@ -258,8 +260,8 @@ void LtsParticipantsOrgChart::updateParticipant(int participantId) helper->run(participantId, true, - AdvancedSymbology::roleToRole<>(m_dtc->party(m_partyId).role()), - QColor::fromRgb(QRgb(m_dtc->party(m_partyId).color())), + AdvancedSymbology::roleToRole<>(m_dtc->party(m_partyId).role), + QColor::fromRgb(QRgb(m_dtc->party(m_partyId).color)), m_useSymData); } @@ -301,8 +303,7 @@ void LtsParticipantsOrgChart::getWholeHierarchy() WebNofitifier::WebNofitifier(QObject *parent) : QObject(parent) , m_currentJsonString(QString()) , m_updateString(QString()) - , m_updateTimer(new QTimer(this)), - m_logger(NGL::NGLLoggerBootstrap::getNGLRootLogger()) { + , m_updateTimer(new QTimer(this)) { connect(m_updateTimer, &QTimer::timeout, this, &WebNofitifier::onTimerTick); } diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.h b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.h index 3dd5f2f0c..94b3e40a4 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.h +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/ParticipantManagement/Gui/ParticipantOrgChart/participant_org_chart.h @@ -97,7 +97,6 @@ signals: private: -NGL::INGLLogger &m_logger; int m_partyId; bool m_useSymData; bool m_isMenuEnabled; @@ -114,6 +113,8 @@ NGL::INGLLogger &m_logger; std::shared_ptr m_dtc; std::shared_ptr m_asbItc; Ui::LtsParticipantsOrgChart *m_ui; + + NGL::INGLLogger &m_logger; }; } diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/CMakeLists.txt b/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/CMakeLists.txt index d9ecbb0a3..3432eb9c2 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/CMakeLists.txt +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/CMakeLists.txt @@ -75,6 +75,9 @@ if(QT6_GUI_AVAILABLE) LtsSessionData NGLLogger Qt6::Xml + # Qt6 Migration: Qt5::WebEngineWidgets transitively linked Qt5::PrintSupport + # (plan_editor.cpp includes ); Qt6 dropped that. + Qt6::PrintSupport ngltranslator PUBLIC diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.cpp b/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.cpp index 730a586c8..2fb0be259 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.cpp @@ -23,7 +23,7 @@ #include -#include +#include #include #include @@ -475,9 +475,9 @@ bool InterfaceImpl::fmsCreatePlan(bool clearGeometryModel) FileManagement::FileContent fc = m_internal->m_flmDtc->fileContent(fileId); - m_internal->m_currentFolderId = fc.folderId(); + m_internal->m_currentFolderId = fc.folderId; m_internal->m_currentFileId = fileId; - m_internal->m_currentNameOfPlan = QString::fromStdString(fc.name()); + m_internal->m_currentNameOfPlan = QString::fromStdString(fc.name); QFileInfo fileInfo(m_internal->m_currentNameOfPlan); m_internal->m_planEditor->setNameOfPlan(fileInfo.baseName()); @@ -511,7 +511,7 @@ bool InterfaceImpl::fmsModifyPlan(int fileId, bool saveAs) } FileManagement::FileContent fileContent = m_internal->m_flmDtc->fileContent(fileId); - bool differentUser = fileContent.operatorId() != LtsSessionData::LtsSessionData::getInstance()->getOperatorId(); + bool differentUser = fileContent.operatorId != LtsSessionData::LtsSessionData::getInstance()->getOperatorId(); if (saveAs || differentUser) { @@ -527,8 +527,8 @@ bool InterfaceImpl::fmsModifyPlan(int fileId, bool saveAs) } - QString nameOfPlan = QString::fromStdString(fileContent.name()); - m_internal->m_currentFolderId = fileContent.folderId(); + QString nameOfPlan = QString::fromStdString(fileContent.name); + m_internal->m_currentFolderId = fileContent.folderId; m_internal->m_currentNameOfPlan = nameOfPlan; m_internal->m_currentFileId = fileId; @@ -592,7 +592,7 @@ void InterfaceImpl::fmsReadPlan() m_internal->m_planEditor->onPlanReset(); FileManagement::FileContent fc = m_internal->m_flmDtc->fileContent(fileId); - QString nameOfPlan = QString::fromStdString(fc.name()); + QString nameOfPlan = QString::fromStdString(fc.name); if (content.size() == 0) { @@ -606,8 +606,8 @@ void InterfaceImpl::fmsReadPlan() m_internal->m_planEditor->setPlan(content); m_internal->m_currentNameOfPlan = nameOfPlan; - m_internal->m_currentFolderId = fc.folderId(); - m_internal->m_currentFileId = fc.id(); + m_internal->m_currentFolderId = fc.folderId; + m_internal->m_currentFileId = fc.id; QFileInfo fileInfo(m_internal->m_currentNameOfPlan); m_internal->m_planEditor->setNameOfPlan(fileInfo.baseName()); @@ -650,7 +650,7 @@ void InterfaceImpl::fmsImportPlan() if (fileId > 0) { FileManagement::FileContent fc = m_internal->m_flmDtc->fileContent(fileId); - QString nameOfPlan = QString::fromStdString(fc.name()); + QString nameOfPlan = QString::fromStdString(fc.name); if (content.size() == 0) { ERROR_LOG(m_logger) << "Error plan [" << nameOfPlan << "] is empty"; @@ -690,7 +690,7 @@ bool InterfaceImpl::fmsWritePlan(bool saveAs) FileManagement::FileContent planFileContent; if (m_internal->m_flmDtc->getFile(FileManagement::FileType::TacticalPlan, m_internal->m_currentFolderId, m_internal->m_currentNameOfPlan, planFileContent)) - m_internal->m_currentFileId = planFileContent.id(); + m_internal->m_currentFileId = planFileContent.id; } if (saveAs || (m_internal->m_currentFileId <= 0)) @@ -726,7 +726,7 @@ void InterfaceImpl::fmsDeletePlan() if (fileId > 0) { FileManagement::FileContent fc = m_internal->m_flmDtc->fileContent(fileId); - QString nameOfPlan = QString::fromStdString(fc.name()); + QString nameOfPlan = QString::fromStdString(fc.name); LtsWidgets::Button doIt = LtsWidgets::LtsMessageDialog::showMessage( m_session->baseLayout() @@ -753,7 +753,7 @@ void InterfaceImpl::fmsDeletePlan() void InterfaceImpl::onPlanContentChanged(const FileManagement::FileContent &data, DataModification modType) { - if (data.fileType() != FileManagement::FileType::TacticalPlan) + if (data.fileType != FileManagement::FileType::TacticalPlan) return; switch (modType) @@ -761,7 +761,7 @@ void InterfaceImpl::onPlanContentChanged(const FileManagement::FileContent &data case DataModification::eModified : break; case DataModification::eRemoved : - if (m_internal->m_currentFileId == data.id()) + if (m_internal->m_currentFileId == data.id) m_internal->m_currentFileId = -1; break; @@ -780,7 +780,7 @@ void InterfaceImpl::onIterateParticipantsSidc() auto gatherUpSidc = [&participantSidcsInUse](const ParticipantManagement::Participant & data) { - const QString &sidcCode = QString::fromStdString(data.symbol()); + const QString &sidcCode = QString::fromStdString(data.symbol); if (AdvancedSymbology::SidcCodec::isEncoded(sidcCode)) { @@ -822,7 +822,7 @@ void InterfaceImpl::readSymbolFavouritesRequest(const QString &favName, QString return; } - int fileId = fileContent.id(); + int fileId = fileContent.id; QByteArray content; if (!m_internal->m_flmGui->loadContent(fileId, content, true)) @@ -929,23 +929,23 @@ void InterfaceImpl::storeSymbolFavouritesRequest(const QString &favName, const Q LtsWidgets::LtsMessageDialog::showMessage(m_session->baseLayout(), msg, m_internal->m_messageBoxTitle); return; } - if (!m_internal->m_flmGui->saveContent(favContent.id(), favXMLContent.toUtf8(), QString())) + if (!m_internal->m_flmGui->saveContent(favContent.id, favXMLContent.toUtf8(), QString())) ERROR_LOG(m_logger) << "Cannot save symbol favourites in library"; } else { - favContent.name(favName.toStdString()); - favContent.isTemplate(false); - favContent.isUsedBy(false); - favContent.usedBy(0); - favContent.folderId(folderId); - favContent.fileStatus(FileManagement::FileStatus::Valid); - favContent.fileCategory(FileManagement::FileCategory::Global); - favContent.fileType(FileManagement::FileType::OperatorFavourite); - favContent.exerciseId(); - favContent.phaseId(); - favContent.lastModified(QDateTime::currentMSecsSinceEpoch()); - favContent.operatorId(LtsSessionData::LtsSessionData::getInstance()->getOperatorId()); + favContent.name = favName.toStdString(); + favContent.isTemplate = false; + favContent.isUsedBy = false; + favContent.usedBy = 0; + favContent.folderId = folderId; + favContent.fileStatus = FileManagement::FileStatus::Valid; + favContent.fileCategory = FileManagement::FileCategory::Global; + favContent.fileType = FileManagement::FileType::OperatorFavourite; + favContent.exerciseId = 0; + favContent.phaseId = 0; + favContent.lastModified = QDateTime::currentMSecsSinceEpoch(); + favContent.operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId(); ERROR_LOG(m_logger) << "New file content = " << favXMLContent; diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.h b/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.h index 14ba88489..b86a5c152 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.h +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/PlanEditor/PlanEditorPlugin/Gui/plan_editor_gui_plugin.h @@ -6,7 +6,7 @@ #include #include #include -#include +#include #include diff --git a/qt6-after/qt6-migrated-legatus/new_docker_build.sh b/qt6-after/qt6-migrated-legatus/new_docker_build.sh index 90e82395b..f0dcd0a1e 100755 --- a/qt6-after/qt6-migrated-legatus/new_docker_build.sh +++ b/qt6-after/qt6-migrated-legatus/new_docker_build.sh @@ -36,7 +36,34 @@ BUILD_ARCGIS: --arcgis / --no-arcgis Enable/disable BUILD_ARCGIS (default: OFF) BUILD_CODIFICATION: - --codification / --no-codification Enable/disable BUILD_CODIFICATION (default: OFF, requires KDReports) + --codification / --no-codification Enable/disable BUILD_CODIFICATION (default: ON, requires KDReports) + +BUILD_WLS: + --wls / --no-wls Enable/disable BUILD_WLS (default: ON; the + GROUP4 targets svcWirelessLocationSystem / + wlsJsonClientTest only exist when it is ON) + +BUILD_FILTERMANAGEMENT: + --filtermanagement / --no-filtermanagement Enable/disable BUILD_FILTERMANAGEMENT (default: ON) + +BUILD_PLUGINS_SERVICEMONITOR: + --servicemonitor / --no-servicemonitor Enable/disable BUILD_PLUGINS_SERVICEMONITOR (default: ON) + +BUILD_WEBENGINE_PLUGINS: + --webengine-plugins / --no-webengine-plugins + Enable/disable the WebEngine-based plugins (PlanEditor, + OnlineHelp, ParticipantOrgChart). PlanEditor links + situationMap, so ON promotes BUILD_ARCGIS to ON. (default: ON) + +BUILD_XMLPATTERNS_PLUGINS: + --xmlpatterns-plugins / --no-xmlpatterns-plugins + Enable/disable the XmlPatterns-based plugins (MSDL, Saab) + when Qt6XmlPatterns is present in the Qt install. Qt + removed the XmlPatterns module in Qt 6.0 ("What's New in + Qt 6.0" / Qt Wiki: removed, not planned to be + re-introduced; no Qt 6 release ships it, no aqt + module), so with a stock Qt 6.10.2 install these + plugins stay disabled (environmental floor). (default: ON) Build groups: --group1 / --no-group1 Enable/disable DDS core libraries build @@ -77,6 +104,11 @@ Environment variable overrides: BUILD_GRANTLEE=ON|OFF BUILD_ARCGIS=ON|OFF BUILD_CODIFICATION=ON|OFF + BUILD_FILTERMANAGEMENT=ON|OFF + BUILD_WLS=ON|OFF + BUILD_PLUGINS_SERVICEMONITOR=ON|OFF + BUILD_WEBENGINE_PLUGINS=ON|OFF + BUILD_XMLPATTERNS_PLUGINS=ON|OFF BUILD_GROUP1=ON|OFF BUILD_GROUP2=ON|OFF BUILD_GROUP3=ON|OFF @@ -107,7 +139,12 @@ Defaults: BUILD_RTI=ON BUILD_GRANTLEE=ON BUILD_ARCGIS=OFF - BUILD_CODIFICATION=OFF + BUILD_CODIFICATION=ON + BUILD_FILTERMANAGEMENT=ON + BUILD_WLS=ON + BUILD_PLUGINS_SERVICEMONITOR=ON + BUILD_WEBENGINE_PLUGINS=ON + BUILD_XMLPATTERNS_PLUGINS=ON BUILD_GROUP1=ON BUILD_GROUP2=ON BUILD_GROUP3=ON @@ -147,6 +184,10 @@ log_info() { printf 'INFO: %s\n' "$*" } +log_warn() { + printf 'WARNING: %s\n' "$*" >&2 +} + log_error() { printf 'ERROR: %s\n' "$*" >&2 } @@ -264,6 +305,12 @@ APT_PACKAGES=( vlc-plugin-base git python3-pip + # Poppler-Qt6 (PDF support): Z/src/nglwidgets detects it via + # pkg_check_modules(POPPLER_QT6 poppler-qt6) - pkg-config must be present for + # the probe to run at all. FlmExplorerGuiPlugin's flm_preview_playback.cpp + # uses Poppler types unconditionally, so a green Group 12 build requires it. + pkg-config + libpoppler-qt6-dev ) # INTERFACE libraries (header-only) are built automatically as dependencies @@ -554,8 +601,8 @@ GROUP4_TARGETS=( svcTabocServer svcTrainingAreaBaseOC serialtest - # Proxies module - WirelessLocationSystem (requires -DBUILD_WLS=ON, e.g. via - # --cmake_build_flags "-DBUILD_WLS=ON") + # Proxies module - WirelessLocationSystem (only exists when BUILD_WLS=ON, + # script default; see the --wls flag) svcWirelessLocationSystem wlsJsonClientTest # Proxies module - Other @@ -607,6 +654,16 @@ RUN pip3 install --break-system-packages --quiet aqtinstall && \ --outputdir ${QT_BASE_DIR} && \ rm -rf /root/.cache/Aqt +# Qt6 XmlPatterns (MSDL/Saab plugins) is intentionally NOT installed: Qt removed +# the XmlPatterns module in Qt 6.0 ("What's New in Qt 6.0" / Qt Wiki: removed and +# not planned to be re-introduced - unlike e.g. Multimedia/WebEngine which +# returned in 6.1/6.2; no Qt 6 release ships it, no aqt module). Mixing an +# out-of-tree libQt6XmlPatterns built against an older Qt with a 6.10 install +# would put two Qt minor versions in one +# process. MSDL/Saab therefore stay disabled with a stock Qt install; to enable +# them, install a Qt-version-matching XmlPatterns (lib + headers + cmake config) +# into ${QT_BASE_DIR}/${QT_VERSION}/${QT_ARCH_DIR} and pass --xmlpatterns-plugins. + # Install KDReports from source (apt package not available in Ubuntu 22.04/26.04) # Try apt install first (will fail), then build from KDAB GitHub mirror RUN apt-get install -y -qq libkdreports-dev 2>/dev/null || \ @@ -670,7 +727,12 @@ BUILD_AAR="${BUILD_AAR:-ON}" BUILD_RTI="${BUILD_RTI:-ON}" BUILD_GRANTLEE="${BUILD_GRANTLEE:-ON}" BUILD_ARCGIS="${BUILD_ARCGIS:-OFF}" -BUILD_CODIFICATION="${BUILD_CODIFICATION:-OFF}" +BUILD_CODIFICATION="${BUILD_CODIFICATION:-ON}" +BUILD_FILTERMANAGEMENT="${BUILD_FILTERMANAGEMENT:-ON}" +BUILD_WLS="${BUILD_WLS:-ON}" +BUILD_PLUGINS_SERVICEMONITOR="${BUILD_PLUGINS_SERVICEMONITOR:-ON}" +BUILD_WEBENGINE_PLUGINS="${BUILD_WEBENGINE_PLUGINS:-ON}" +BUILD_XMLPATTERNS_PLUGINS="${BUILD_XMLPATTERNS_PLUGINS:-ON}" BUILD_GROUP1="${BUILD_GROUP1:-ON}" BUILD_GROUP2="${BUILD_GROUP2:-ON}" BUILD_GROUP3="${BUILD_GROUP3:-ON}" @@ -802,6 +864,36 @@ while [[ $# -gt 0 ]]; do --no-codification) BUILD_CODIFICATION=OFF ;; + --wls) + BUILD_WLS=ON + ;; + --no-wls) + BUILD_WLS=OFF + ;; + --filtermanagement) + BUILD_FILTERMANAGEMENT=ON + ;; + --no-filtermanagement) + BUILD_FILTERMANAGEMENT=OFF + ;; + --servicemonitor) + BUILD_PLUGINS_SERVICEMONITOR=ON + ;; + --no-servicemonitor) + BUILD_PLUGINS_SERVICEMONITOR=OFF + ;; + --webengine-plugins) + BUILD_WEBENGINE_PLUGINS=ON + ;; + --no-webengine-plugins) + BUILD_WEBENGINE_PLUGINS=OFF + ;; + --xmlpatterns-plugins) + BUILD_XMLPATTERNS_PLUGINS=ON + ;; + --no-xmlpatterns-plugins) + BUILD_XMLPATTERNS_PLUGINS=OFF + ;; --no-ctest) RUN_CTEST=OFF ;; @@ -870,6 +962,18 @@ BUILD_RTI="$(normalize_on_off "$BUILD_RTI" "BUILD_RTI")" BUILD_GRANTLEE="$(normalize_on_off "$BUILD_GRANTLEE" "BUILD_GRANTLEE")" BUILD_ARCGIS="$(normalize_on_off "$BUILD_ARCGIS" "BUILD_ARCGIS")" BUILD_CODIFICATION="$(normalize_on_off "$BUILD_CODIFICATION" "BUILD_CODIFICATION")" +BUILD_FILTERMANAGEMENT="$(normalize_on_off "$BUILD_FILTERMANAGEMENT" "BUILD_FILTERMANAGEMENT")" +BUILD_WLS="$(normalize_on_off "$BUILD_WLS" "BUILD_WLS")" +BUILD_PLUGINS_SERVICEMONITOR="$(normalize_on_off "$BUILD_PLUGINS_SERVICEMONITOR" "BUILD_PLUGINS_SERVICEMONITOR")" +BUILD_WEBENGINE_PLUGINS="$(normalize_on_off "$BUILD_WEBENGINE_PLUGINS" "BUILD_WEBENGINE_PLUGINS")" +BUILD_XMLPATTERNS_PLUGINS="$(normalize_on_off "$BUILD_XMLPATTERNS_PLUGINS" "BUILD_XMLPATTERNS_PLUGINS")" + +# PlanEditorGuiPlugin links situationMap (ArcGIS scope), so the WebEngine plugin +# set cannot configure without ArcGIS: promote BUILD_ARCGIS when it is enabled. +if [[ "${BUILD_WEBENGINE_PLUGINS}" == "ON" && "${BUILD_ARCGIS}" == "OFF" ]]; then + log_info "BUILD_WEBENGINE_PLUGINS=ON implies ArcGIS-scope targets (PlanEditorGuiPlugin -> situationMap): promoting BUILD_ARCGIS=ON" + BUILD_ARCGIS=ON +fi BUILD_GROUP1="$(normalize_on_off "$BUILD_GROUP1" "BUILD_GROUP1")" BUILD_GROUP2="$(normalize_on_off "$BUILD_GROUP2" "BUILD_GROUP2")" BUILD_GROUP3="$(normalize_on_off "$BUILD_GROUP3" "BUILD_GROUP3")" @@ -900,7 +1004,7 @@ fi CMAKE_BUILD_FLAGS="${CMAKE_BUILD_FLAGS:-}" # Export variables for Docker container -export BUILD_ALL BUILD_RTI BUILD_GRANTLEE BUILD_ARCGIS BUILD_CODIFICATION BUILD_GROUP1 BUILD_GROUP2 BUILD_GROUP3 BUILD_GROUP4 BUILD_GROUP5 BUILD_GROUP6 BUILD_GROUP7 BUILD_GROUP8 BUILD_GROUP9 BUILD_GROUP10 BUILD_GROUP11 BUILD_VIEWER_ONLY RUN_CTEST TESTS_ONLY INTEGRATION_TEST USE_PREBUILT_IMAGE BUILD_PREBUILT_IMAGE DELETE_PREBUILT_IMAGE DOCKER_IMAGE CMAKE_BUILD_FLAGS +export BUILD_ALL BUILD_RTI BUILD_GRANTLEE BUILD_ARCGIS BUILD_CODIFICATION BUILD_FILTERMANAGEMENT BUILD_WLS BUILD_PLUGINS_SERVICEMONITOR BUILD_WEBENGINE_PLUGINS BUILD_XMLPATTERNS_PLUGINS BUILD_GROUP1 BUILD_GROUP2 BUILD_GROUP3 BUILD_GROUP4 BUILD_GROUP5 BUILD_GROUP6 BUILD_GROUP7 BUILD_GROUP8 BUILD_GROUP9 BUILD_GROUP10 BUILD_GROUP11 BUILD_GROUP12 BUILD_VIEWER_ONLY RUN_CTEST TESTS_ONLY INTEGRATION_TEST USE_PREBUILT_IMAGE BUILD_PREBUILT_IMAGE DELETE_PREBUILT_IMAGE DOCKER_IMAGE CMAKE_BUILD_FLAGS # Group 5: Viewer module targets (conditional on BUILD_ARCGIS) # Note: LtsFileDialog excluded from viewer-only builds due to Group 4 dependencies (svcExmCommon, svcOpmCommon, svcFlmCommon) @@ -1083,6 +1187,23 @@ GROUP11_TARGETS=( # Excluded (environmental floors, not migration regressions): # cesPluginGeoPairing - needs the external Schusstafel.h header (missing) # BldInfoGuiPlugin - links BuildingViewerCommon (dtEntity/OSG SDK absent) +# BdvViewerGuiPlugin - links BuildingViewerCommon (same floor; CMake skips its +# subdirectory when BuildingViewerCommon is not built) +# PpmMSDLGuiPlugin - links Qt6::XmlPatterns; Qt removed the XmlPatterns +# PpmSAABGuiPlugin - module in Qt 6.0 (not re-introduced; no Qt 6 release +# ships it, incl. 6.10.2). With a stock Qt install the +# BUILD_PLUGINS_MSDL/SAAB flags resolve to OFF (see +# resolve_xmlpatterns) +# The Flt*/Smo* targets only exist when BUILD_FILTERMANAGEMENT / +# BUILD_PLUGINS_SERVICEMONITOR are ON (script defaults; see the cmake call). +# With them OFF the five unconditional GUI plugins (EvlEdit, PpmParticipantInfo, +# Pws, SrmReplayManagement, OpmSettings) also fail to link (they need the +# FilterManagement interface libs) - so these defaults are load-bearing. +# The PlanEditorGuiPlugin/OhpOnlineHelpViewerGuiPlugin/PpmOrgChartGuiPlugin +# targets only exist when BUILD_WEBENGINE_PLUGINS=ON (script default; ON also +# promotes BUILD_ARCGIS=ON because PlanEditorGuiPlugin links situationMap), +# and the Cod*/codTopicTypePlugin targets when BUILD_CODIFICATION=ON (script +# default; requires KDReports). GROUP12_TARGETS=( AesAirSupportGuiPlugin AesBcContaminationGuiPlugin @@ -1120,6 +1241,8 @@ GROUP12_TARGETS=( CesParticipantMoveGuiPlugin CesParticipantUASGuiPlugin CmoDataPlugin + CodCodificationDataGuiPlugin + CodDataPlugin DevGuiPlugin EfmDataPlugin EfmSoundAreaGuiPlugin @@ -1137,6 +1260,10 @@ GROUP12_TARGETS=( FlmComboBoxGuiPlugin FlmDataPlugin FlmExplorerGuiPlugin + FltAesGuiPlugin + FltDataPlugin + FltParticipantGuiPlugin + Fltbldg_cmpntGuiPlugin FspGuiPlugin GimDataPlugin GimInfoGuiPlugin @@ -1163,6 +1290,7 @@ GROUP12_TARGETS=( NomEditGuiPlugin ObdBaseDownloaderGuiPlugin ObdDataPlugin + OhpOnlineHelpViewerGuiPlugin OpmComboBoxGuiPlugin OpmDataPlugin OpmEditGuiPlugin @@ -1176,10 +1304,12 @@ GROUP12_TARGETS=( PdmChargeTableGuiPlugin PdmComboBoxGuiPlugin PdmDataPlugin + PlanEditorGuiPlugin PlanOverlaysGuiPlugin PpmComboBoxGuiPlugin PpmDataPlugin PpmOperationalPlaningGuiPlugin + PpmOrgChartGuiPlugin PpmParticipantEditGuiPlugin PpmParticipantInfoGuiPlugin PpmParticipantTemplatesGuiPlugin @@ -1210,6 +1340,10 @@ GROUP12_TARGETS=( ScrScreenRecordingGuiPlugin SitmapGuiPlugin SituationMapScriptFilterGuiPlugin + SmoEquipmentErrorRegistrationGuiPlugin + SmoHgrAndMineSearchGuiPlugin + SmoMonitorsGuiPlugin + SmoSystemMonitorGuiPlugin SrmDataPlugin SrmReplayManagementGuiPlugin SrpDataPlugin @@ -1415,6 +1549,10 @@ log_info() { printf 'INFO: %s\n' "$*" } +log_warn() { + printf 'WARNING: %s\n' "$*" >&2 +} + install_qt6_packages() { log_info "Installing Qt6 packages via aqtinstall" @@ -1518,6 +1656,29 @@ if [[ "${BUILD_ARCGIS}" == "ON" ]]; then fi fi +# The MSDL/Saab plugins link Qt6::XmlPatterns. Qt removed the XmlPatterns +# module in Qt 6.0 ("What's New in Qt 6.0" removal table / Qt Wiki: removed and +# not planned to be re-introduced - unlike Multimedia/WebEngine, which returned +# in 6.1/6.2). No Qt 6 release (incl. 6.10.2) ships it and there is no aqt +# module. An out-of-tree libQt6XmlPatterns built against an older Qt would mix +# two Qt minor versions in one process (ABI risk), so with a stock Qt install +# the plugins are gated OFF. If a Qt-version-matching XmlPatterns (lib + +# headers + Qt6XmlPatterns cmake config) is placed into the Qt prefix, they +# enable automatically. +resolve_xmlpatterns() { + BUILD_XMLPATTERNS_EFFECTIVE="${BUILD_XMLPATTERNS_PLUGINS}" + if [[ "${BUILD_XMLPATTERNS_EFFECTIVE}" == "ON" ]]; then + if ls "${QT_BASE_DIR}/${QT_VERSION}/${QT_ARCH_DIR}/lib/libQt6XmlPatterns.so.6" >/dev/null 2>&1; then + log_info "Qt6XmlPatterns present in the Qt install - MSDL/Saab plugins will be built" + else + log_warn "Qt6XmlPatterns is not present in the Qt install (removed in Qt 6.0, not re-introduced) - keeping BUILD_PLUGINS_MSDL/BUILD_PLUGINS_SAAB OFF (ppm.msdl / ppm.saab stay unbuilt)" + BUILD_XMLPATTERNS_EFFECTIVE=OFF + fi + fi +} + +resolve_xmlpatterns + cd /workspace/qt-migration-legatus/qt6-after/qt6-migrated-legatus rm -rf build4 @@ -1535,6 +1696,14 @@ cmake .. \ -DBUILD_GRANTLEE="${BUILD_GRANTLEE}" \ -DBUILD_ARCGIS="${BUILD_ARCGIS}" \ -DBUILD_CODIFICATION="${BUILD_CODIFICATION}" \ + -DBUILD_FILTERMANAGEMENT="${BUILD_FILTERMANAGEMENT}" \ + -DBUILD_WLS="${BUILD_WLS}" \ + -DBUILD_PLUGINS_SERVICEMONITOR="${BUILD_PLUGINS_SERVICEMONITOR}" \ + -DBUILD_PLUGINS_PLANEDITOR="${BUILD_WEBENGINE_PLUGINS}" \ + -DBUILD_PLUGINS_ONLINEHELP="${BUILD_WEBENGINE_PLUGINS}" \ + -DBUILD_PLUGINS_PARTICIPANT_ORG_CHART="${BUILD_WEBENGINE_PLUGINS}" \ + -DBUILD_PLUGINS_MSDL="${BUILD_XMLPATTERNS_EFFECTIVE}" \ + -DBUILD_PLUGINS_SAAB="${BUILD_XMLPATTERNS_EFFECTIVE}" \ ${CMAKE_BUILD_FLAGS:-} \ -DCMAKE_CXX_STANDARD=17 \ -DCMAKE_BUILD_TYPE=Release \ @@ -1605,6 +1774,11 @@ docker run --rm \ -e BUILD_GRANTLEE \ -e BUILD_ARCGIS \ -e BUILD_CODIFICATION \ + -e BUILD_FILTERMANAGEMENT \ + -e BUILD_WLS \ + -e BUILD_PLUGINS_SERVICEMONITOR \ + -e BUILD_WEBENGINE_PLUGINS \ + -e BUILD_XMLPATTERNS_PLUGINS \ -e BUILD_GROUP1 \ -e BUILD_GROUP2 \ -e BUILD_GROUP3 \