Skip to content

build: pin CMake 4.4.5 in build-windows CI + FATAL_ERROR on unknown import-std CMake version - #1855

Merged
caomengxuan666 merged 1 commit into
mainfrom
fix/cmake-4.4.5-pin-import-std-fatal
Nov 22, 2026
Merged

caomengxuan666 merged 1 commit into
mainfrom
fix/cmake-4.4.5-pin-import-std-fatal

Conversation

@caomengxuan666

Copy link
Copy Markdown
Member

根因

WinuxCmd v1.2.2 tag run 45010126362 四个 build-windows job 全红于 LNK1181(std.compat.ixx.obj 打不开),release job 被 skipped、资产为零。队长诊断卷宗(winuxcmd-lnk1181-diagnosis-2026-11-22)定谳:

  • 不是仓内回归:cmake/enable_import_std.cmake / cmake/import_std.cmake 在窗口内零改动;根 CMakeLists 方言块双 ref 逐字同。
  • runner 镜像 windows-2025 滚动把 CMake 4.4.4 → 4.5.0(连同 VS 18.11→18.12、MSVC 19.51→19.52)。本仓 import std 接线建立在 CMake ≤4.4 的实验模型上:按版本查 UUID 表(表止于 4_4)、设 CMAKE_CXX_MODULE_STD,根 CMakeLists 读 CMAKE_CXX_COMPILER_IMPORT_STD。
  • CMake 4.5 已整体拆除该模型(import std 转正,UUID 门与上述变量均移除)。脚本在 4.5.0 上查表落空、警告后 return,构建图半配置——BMI 边在、std.compat.ixx.obj 的编译边缺席——链接时 LNK1181。
  • 证据:run 44696552427 同 commit A/B 实锤(失败腿 CMake 4.5.0、成功腿 4.4.5);本签名 2026-11-20 首现、11-21 起四腿全红(镜像分批滚动毕);tag run attempt 2 重跑同签名,偶发排除。

本 PR 做什么(诊断 §5 的 B+C)

  • B(最快恢复):.github/workflows/build-winuxcmd.yml 的 build-windows job 在 Configure CMake 之前新增一步,从 Kitware 官方发布安装 CMake 4.4.5 并 prepend PATH(job 内后续步骤、含 PGO 的两次 configure,共用同一 PATH,一处生效)。4.4.5 是镜像上实测过的末代好组合(run 44234935370 全绿、44696552427 成功腿)。
  • C(必做硬化):cmake/enable_import_std.cmake 未知版本分支由 message(WARNING …) + return() 改为 message(FATAL_ERROR …)——杜绝半配置状态一路走到链接才死;今后镜像再滚版本,configure 当场红、信息明确。

按 CMake 4.5 模型适配(诊断 §5 的 A 方案)是治本后续,不在本 PR。注意:不存在可补的「4.5 UUID」——4.5 已没有这个门,编造值无效。

删除节

本 PR 不删除任何代码。内容为:CI 版本钉(workflow 新增一步)+ 一行级硬化(cmake 脚本一处 message 级别与 return 的替换)。产品代码零改动;合入后新 main 头相对 v1.2.2 原 tag 头(c922c29c)的 compare 应仅这两个构建面文件。

验证口径

本 PR 的 CI 中 build-windows 四腿(x64/arm64 × default/full)必须全绿,修复才算成立。

Refs: v1.2.2 点火续行(owner 2026-11-22 拍板处置 (b):删 release+tag、修复后在新头重打 v1.2.2)。

…port std CMake version

CMake 4.5 removed the experimental import std model this repo wires
against; on the rolled windows-2025 image (CMake 4.5.0) the configure
half-configures and all four build-windows legs fail at link time with
LNK1181 on std.compat.ixx.obj (v1.2.2 tag run 45010126362).

B: install CMake 4.4.5 (Kitware zip) and prepend PATH before Configure
in the build-windows job. C: enable_import_std.cmake unknown-version
branch now fails the configure instead of warning and returning.
@caomengxuan666
caomengxuan666 merged commit 453c3b7 into main Nov 22, 2026
28 of 32 checks passed
caomengxuan666 added a commit that referenced this pull request Nov 22, 2026
…jobs (#1857)

* ci: pin CMake 4.4.5 in GNU master differential and benchmark Windows jobs

#1855 pinned CMake 4.4.5 only in build-windows. The GNU master
differential (compare, baseline) and the speed-matrix benchmark build
on the same windows-2025 image with CMake 4.5.0 and have been red at
'Build native Windows Release' on every main push since the image roll.
Apply the same pin step before each Windows build.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* ci(diag): surface build log tail as an annotation in compare (temporary)

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* ci(diag): narrow build annotation to errors (temporary)

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* build(rust2): link synchronization.lib for the rust2 staticlib

The GNU master differential jobs build with the windows-2025 image's
default Rust toolchain (no RUST2_TOOLCHAIN pin), whose std binds
WaitOnAddress/WakeByAddressSingle/WakeByAddressAll; the link failed
with LNK2001 __imp_WakeByAddressSingle / LNK1120. Add synchronization
to the imported target's interface libs. Drop the temporary build-log
annotation diagnostic.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* ci(ctest-gate): name the still-failing tests in the error annotation

Job logs are not always reachable (log downloads redirect to blob
storage); the check-run annotation is. List the tests that still fail
after the serial retry so a red ctest leg is diagnosable from the API.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

---------

Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
caomengxuan666 added a commit that referenced this pull request Nov 23, 2026
Trial unpin (run 45226913688) proved the wiring adaptation correct and
the blocker upstream: on the image's CMake 4.5.0 the configure took the
native path and generated the full graph, but the synthesized std
targets carry only BMI edges -- the std.compat.ixx.obj compile edge is
missing while link lines still reference it, reproducing the #1855
LNK1181 signature verbatim on all four legs. That edge is synthesized
by CMake from the MSVC modules metadata; the repo wiring no longer
participates. Restore the pins (reason updated in build-winuxcmd.yml)
until a CMake/MSVC roll fixes the graph. The dead -D flags restored
with them keep the pinned combination byte-identical to the proven
green main; their removal rides with the eventual unpin.

Refs #1865
caomengxuan666 added a commit that referenced this pull request Nov 23, 2026
…I CMake (#1867)

* build(cmake): adapt import std wiring to the CMake 4.5 model, unpin CI CMake

CMake 4.5 graduated import std: no UUID gate, CMAKE_CXX_MODULE_STD is
inert, CMAKE_CXX_COMPILER_IMPORT_STD is gone. enable_import_std.cmake
now returns early on >= 4.5 (native model); the 3.30-4.4 experimental
UUID path and its FATAL_ERROR hardening are unchanged. The root
CMakeLists CXX26 dialect arm no longer decides levels from the removed
variable. All four #1855 CMake 4.4.5 pin steps (build-winuxcmd,
benchmark-speed-matrix, gnu-master-differential x2) and the dead
-DCMAKE_CXX_MODULE_STD / -DCMAKE_EXPERIMENTAL_CXX_MODULE_STD flags are
removed; CI now uses the windows-2025 image's CMake 4.5.

Refs #1865

* build(ci): restore the CMake 4.4.5 pins -- 4.5.0 graph defect confirmed

Trial unpin (run 45226913688) proved the wiring adaptation correct and
the blocker upstream: on the image's CMake 4.5.0 the configure took the
native path and generated the full graph, but the synthesized std
targets carry only BMI edges -- the std.compat.ixx.obj compile edge is
missing while link lines still reference it, reproducing the #1855
LNK1181 signature verbatim on all four legs. That edge is synthesized
by CMake from the MSVC modules metadata; the repo wiring no longer
participates. Restore the pins (reason updated in build-winuxcmd.yml)
until a CMake/MSVC roll fixes the graph. The dead -D flags restored
with them keep the pinned combination byte-identical to the proven
green main; their removal rides with the eventual unpin.

Refs #1865

---------

Co-authored-by: caomengxuan666 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant