Skip to content

CI dependency bug - #3555

Open
Nima-Rahimi-Foroushaani wants to merge 1 commit into
TheSuperHackers:mainfrom
Nima-Rahimi-Foroushaani:main
Open

Nima-Rahimi-Foroushaani wants to merge 1 commit into
TheSuperHackers:mainfrom
Nima-Rahimi-Foroushaani:main

Conversation

@Nima-Rahimi-Foroushaani

Copy link
Copy Markdown

No description provided.

@coderabbitai

coderabbitai Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: b6d464d4-7a8d-44a2-bc2e-ef04032ab19e
📥 Commits

Reviewing files that changed from the base of the PR and between e572d87 and 1ba4981.

📒 Files selected for processing: 2
  • .github/workflows/ci.yml
  • Core/GameEngine/CMakeLists.txt

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

Walkthrough

The CI workflow adds change detection as a dependency of the Generals MD replay-check job. The GameEngine CMake configuration adds compiler-specific forced includes when precompiled headers are disabled.

Changes

CI job dependency

Layer / File(s) Summary
Replay-check job dependencies
.github/workflows/ci.yml
replaycheck-generalsmd now depends on both detect-changes and build-generalsmd-vc6.

Precompiled-header fallback

Layer / File(s) Summary
Forced include fallback
Core/GameEngine/CMakeLists.txt
When precompiled headers are disabled, the configuration force-includes BasePrecomp.h before PreRTS.h. It uses /FI options for MSVC and -include options for other compilers.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Suggested reviewers: helmutbuhler, xezon

Merge Risk: ⚪ Minimal · up to 1ba49

The CI dependency and precompiled-header fallback are ready to merge after normal checks.

Pre-merge checks: Passed 3 · Inconclusive 1

Failed Failed checks: 1 inconclusive

Check name Status Explanation Resolution
Description check Inconclusive No pull request description was provided, so the changes and their purpose are not documented. Add a description that summarizes the CI dependency update and the forced include handling added to Core/GameEngine/CMakeLists.txt.
Passed Passed checks: 3 passed
Check name Status Explanation
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Title check Passed The title accurately describes the CI dependency change, but it does not identify the Docker build fix or the CMake compiler include changes. It is still related to a real part of the pull request.
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@greptile-apps

greptile-apps Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge.

Summary

Adds detect-changes as a direct dependency of replaycheck-generalsmd.

  • GeneralsMD replay checks wait for the change detector and VC6 build.

Reviews (2) · Last reviewed commit: "fix(ci): To access the indirect dependen..." · Reviewed by Greptile

Comment thread Core/GameEngine/CMakeLists.txt Outdated
@@ -1199,6 +1199,23 @@ target_precompile_headers(corei_gameengine_private INTERFACE
Include/Precompiled/PreRTS.h
)

# The Docker/VC6 build disables PCH generation, but engine sources still rely
# on the declarations in PreRTS.h. Keep including it even without a PCH,
# with the compatibility macros and base types included first.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks unexpected. BasePrecomp.h should come through core_libraries

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does indeed. However, the forced inclusion of PreRTS.h comes before the ones of BasePrecomp.h which breaks the compilation.

@Skyaero42

Copy link
Copy Markdown

is this and #3523 related?

@tintinhamans tintinhamans left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tested #3523 rebased onto current main, with one extra trig.h include in ICoord2D.h for Sqrt.

clean Docker/VC6 build of z_generals then passes without this fallback. i'd handle the missing includes in #3523 and keep the CI dependency fix separate.

@stephanmeesters

stephanmeesters commented Oct 19, 2026 •

Copy link
Copy Markdown

Looks like we can get PCH working in the Docker build with a little tweak (/Zm100 in space of /Zm1000):

diff --git a/resources/dockerbuild/entrypoint.sh b/resources/dockerbuild/entrypoint.sh
index 1fe64c12ea..06cff60626 100644
--- a/resources/dockerbuild/entrypoint.sh
+++ b/resources/dockerbuild/entrypoint.sh
@@ -16,10 +16,11 @@ if [ "${FORCE_CMAKE:-}" = "true" ] || [ ! -f  build/docker/build.ninja  ]; then
         -DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY \
         -DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY \
         -DCMAKE_FIND_ROOT_PATH_MODE_PACKAGE=ONLY \
-        -DCMAKE_DISABLE_PRECOMPILE_HEADERS=1 \
+        -DCMAKE_DISABLE_PRECOMPILE_HEADERS=OFF \
+        "-DCMAKE_CXX_FLAGS=/DWIN32 /D_WINDOWS /GX /Zm100" \
         -DCMAKE_C_COMPILER_WORKS=1 \
         -DCMAKE_CXX_COMPILER_WORKS=1 \
-        -B /build/cnc/build/docker
+        -B Z:/build/cnc/build/docker
 fi
 
 cd /build/cnc/build/docker 

@Nima-Rahimi-Foroushaani Nima-Rahimi-Foroushaani changed the title Docker build fix CI dependency bug Oct 19, 2026
@Nima-Rahimi-Foroushaani

Copy link
Copy Markdown
Author

I removed the commit, related to the docker based build problem. I assume it will be handled in #3523.

@tintinhamans

Copy link
Copy Markdown

Looks good. The replay check reads needs.detect-changes.outputs but only had build-generalsmd-vc6 in needs, and GitHub only exposes jobs you list directly. It worked anyway, but this is the right way.

Could you rename it to something like ci: Add detect-changes to replay check needs and add a short description?

@Skyaero42

Copy link
Copy Markdown

Looks like we can get PCH working in the Docker build with a little tweak (/Zm100 in space of /Zm1000):

Apparently it is better not to rely on PCH:
#3523 (comment)

@stephanmeesters

stephanmeesters commented Oct 20, 2026 •

Copy link
Copy Markdown

Looks like we can get PCH working in the Docker build with a little tweak (/Zm100 in space of /Zm1000):

Apparently it is better not to rely on PCH: #3523 (comment)

I think the root cause that PCH was disabled on Docker was that CMake defaulted to a compiler setting that requested a lot of memory unnecessarily (/Zm1000). But having the project not rely on PCH to be able to build is also good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CompileBug Bug at compile time

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants