diff --git a/prompts/strict-lts-services-s-migration.prompt.md b/prompts/strict-lts-services-s-migration.prompt.md index cc2097bbd..cea510ace 100644 --- a/prompts/strict-lts-services-s-migration.prompt.md +++ b/prompts/strict-lts-services-s-migration.prompt.md @@ -86,6 +86,7 @@ Allowed minimal outside-scope changes include only: - central CMake helper fixes required by these services - shared interface/header include path fixes required by these services - RTI/codegen/KTextTemplate integration fixes required by these services +- forward declaration files under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations when required for optional builds such as BUILD_RTI=OFF - test infrastructure changes required by the new tests for these services - validation container changes required to run the new tests - Jenkins CI changes required to discover and run the new tests @@ -445,6 +446,22 @@ Prefer output paths under: unless the repository clearly requires another build-tree path. +# Forward Declaration Rules for Optional Builds + +If forward declarations are required for optional builds, for example BUILD_RTI=OFF, they must be placed under: + +- ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations + +Rules: + +- do not place forward declaration headers ad hoc in service source directories unless the repository already has a stricter established pattern for that exact service +- do not create forward declarations as substitutes for real generated outputs in BUILD_RTI=ON +- do not use forward declarations to fake successful RTI/codegen validation +- forward declarations may only model the minimal type declarations needed for non-RTI or optional-codegen compilation +- forward declaration files must be clearly wired through CMake include paths for the affected BUILD_RTI=OFF targets +- BUILD_RTI=ON must still use real generated outputs from the build tree when those outputs are required +- report every added or changed forward declaration file in the final report + If required generated files cannot be produced by the real generator flow: - do not fabricate them @@ -549,6 +566,7 @@ For BUILD_RTI=OFF, verify: - optional RTI codegen parts are cleanly disabled or not consumed - no stale generated RTI artifacts are required - new non-RTI tests run successfully through CTest +- forward declarations required for BUILD_RTI=OFF are provided only through ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations # Procedure @@ -566,6 +584,7 @@ Check: - presence of ./prompts/combined-migration-subfolder-rti-compact.prompt.md - presence of the listed source service directories - presence or absence of corresponding Qt6 target service directories +- presence of ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations Do not overwrite local changes. @@ -611,6 +630,7 @@ For each listed service, identify: - removed-module references - LogViewer interactions - RoutingServiceNG pattern dependencies +- required forward declarations for optional builds such as BUILD_RTI=OFF Decide whether each dependency: @@ -620,6 +640,7 @@ Decide whether each dependency: - is outside scope but required - is stale and should be removed - belongs to a removed module and must not be restored +- must be represented by a minimal forward declaration for BUILD_RTI=OFF under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations If a dependency is outside scope but required to build, test, or validate a listed service, apply the smallest directly related fix only. @@ -635,6 +656,7 @@ For each listed service: - update target_sources only with real source files or real generated build-tree outputs - update target_link_libraries to Qt6 targets and valid project targets - update target_include_directories to include build-tree generated output dirs where required +- add or update BUILD_RTI=OFF forward declarations only under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations when required - preserve service/plugin metadata - preserve install rules if valid - remove stale references to missing or removed files only if they are truly stale @@ -673,6 +695,7 @@ For every generated dependency involved in the listed services: - verify generated headers are included through build-tree include directories - verify compilation depends on generation - verify incremental rebuild triggers when input/template changes +- verify BUILD_RTI=OFF forward declarations, if needed, are located under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations and do not replace real BUILD_RTI=ON generated outputs If generation cannot run: @@ -702,6 +725,7 @@ Search the Qt6 tree after changes for: - references to removed modules - duplicate IDL input lists - stale generated output directories +- misplaced forward declarations outside ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations # Validation Requirements @@ -713,6 +737,7 @@ Before final validation: - ensure required generators run during the build if needed - validate inside Docker - run CTest as part of validation +- verify optional-build forward declarations are loaded from ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations when required At minimum, run from: @@ -781,11 +806,13 @@ The task is successful only if: - generated outputs, if involved, are consumed from the build tree - no generated .idl, .h, or .cpp files are committed to source - no stub/dummy/mock/placeholder generated files are created +- optional-build forwarddeclarations, if needed, are placed under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations +- forward declarations are not used as fake replacements for real BUILD_RTI=ON generated outputs - previous .IDL warning fixes do not regress - modules removed by 92ad7d468 remain removed - LogViewer reinsert from 1fa789767 remains preserved - RoutingServiceNG migration rules and patterns are not violated -- BUILD_RTI=OFF does not reuire RTI or an RTI license +- BUILD_RTI=OFF does not require RTI or an RTI license - BUILD_RTI=ON is reported successful only if real RTI/codegen execution, fresh generated outputs, and relevant tests are proven # If Blocked @@ -797,7 +824,7 @@ Report exactly: - failing command - key error output - affected service -- whether the issue is project, path, merge, CMake, Qt API, codegen, Docker, RTI/license, test, CTest, Jenkins CI, or environment related +- whether the issue is project, path, merge, CMake, Qt API, codegen, Docker, RTI/license, test, CTest, Jenkins CI, forward declaration, or environment related - what was fixed safely - what remains blocked - whether BUILD_RTI=OFF was validated @@ -810,6 +837,7 @@ Report exactly: - whether CTest integration succeeded - whether validation-container test execution succeeded - whether Jenkins CI discovery/execution support succeeded +- whether required forward declarations were added under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations - exact reason if three tests per C++ change were not feasible # Final Report @@ -832,6 +860,7 @@ Report: - root causes fixed - files changed - C++ files changed +- forward declaration files changed under ./qt-migration-legatus/qt6-after/qt6-migrated-legatus/forward-declarations - number of unit tests added per C++ change - test files changed - CTest registration changes