Prompt file imported from houyuwen/PlatNexus (
.github/prompts/platnexus-cmake-review.prompt.md). Copyright stays with the author.
Review CMake organization for the selected files or folders.
Use these sources as authoritative:
- ../copilot-instructions.md
- ../instructions/platnexus-cmake-organization.instructions.md
- ../instructions/platnexus-directory-decoupling.instructions.md
- ../instructions/platnexus-development.instructions.md
- ../docs/cmake.rst
Do not restate or relax those rules. Apply them directly.
Mandatory first step:
- Read
../docs/cmake.rstfully before evaluating or proposing CMake changes.
Review focus
- root-vs-module responsibility split
- target-oriented CMake usage vs global side effects
- helper-function extraction opportunities
- conditional routing complexity and readability
- generated source/include attachment scope
Output format
Return sections in this order:
- Scope checked
- Organization verdict
- High-risk findings (build fragility / hidden global coupling)
- Medium-risk findings (readability / maintainability drift)
- Low-risk findings (style consistency)
- Minimal-change refactor plan
- Optional helper-function extraction plan (Zephyr-inspired)