bazel: Windows resource compiler from the toolchain, not PATH #4039
All Vouch review confidence checks passed
Residual risk 0.28 = Change Risk (0.52) × (1 − Review Confidence (0.47)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.52 · 650 lines diff across 8 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.388
Shallow Review Depth
shallow_review_depth
0.344
Real PR Conversation Timeline
1 comments
"Review active on #4039"
general
weight: 0.35
Alexandr-Solovev
Summary
dev/bazel/toolchains/rc_toolchain.bzl: therc_toolchainrule andRC_TOOLCHAIN_TYPE. The Windows toolchain repository registers onerc_toolchain_winper LLVM and MSVC template, next to the cc toolchain. Linux registers none, andcc_dynamic_libdeclares the type optional.cc_toolchain_win.bzl:_find_resource_compilerfinds the tool withfind_tool(mandatory = False); the tool is an input of the tool identity on the LLVM path.cc.bzl: thecmd.execall is gone; the env is the toolchain's compile env, as the archive merge incc/link.bzl.TODO.mdandAGENTS.md: the remaininguse_default_shell_envsite isrelease.bzl's copy.Evidence
python3 dev/bazel/tests/check_starlark_policy.py .onbazel-hermetic-fixesreportsOK (2 allowed site(s)).After: the same command on this branch reports
OK (1 allowed site(s)).bazel test //dev/bazel/tests:all: 19 of 19 pass.bazel test --config=host //cpp/oneapi/dal/algo/pca:tests: 7 of 7 pass. The.bzlloads on Linux, soconfig_common.toolchain_typeand the optional type resolve there.CI (WindowsBazel)on27bbdbe31, passed) compileddll.rcandonedal_dll.rcin its release step, withrc.exegetting the same env as now (no SystemRoot or TEMP passthrough):Build completed successfully, 6732 total actions.Merge Danger
Door: two-way. The change is revertable and writes no persisted format.
The rc tool is now resolved from the configure-time PATH and passed as an absolute path, the same way as the archiver. A target with
rc_filefails at analysis when no resource compiler is found.Blast Radius: Windows builds of DLLs that link a version resource.
Ramifications:
rc.exeorllvm-rcneeds one of them, the Windows CI shows it and the fix is one more variable in the action env.cmd.exe, sorc_definesand include paths with spaces or cmd metacharacters are no longer re-parsed.llvm-rcis looked up in theclang-cltoolchain directory and then on PATH, as the other LLVM tools are; with neither, a target withrc_filefails at analysis.INCLUDEat configure time fails at analysis for a target withrc_file, instead of rc.exe failing onwindows.h.🤖 Generated with Claude Code
---
<details>
<summary>Checklist:</summary>
Completeness and readability
dev/bazel/TODO.md,dev/bazel/AGENTS.md)origin/mainf0b5f38d6; no conflicts. Re-checked againstorigin/mainb63dcd536: merges clean.)Testing
bazel test //dev/bazel/tests:allon head 98fd425ac: 19 of 19 pass, exit 0, run for this update. Windows: the AzureCI (WindowsBazel)run on this head, build 66416, passed, withCI (WindowsMakeVC)in the same build.)pull_requestby theirif:; AzureCI (WindowsBazel)is green.)rc_toolchainrule and the resource action are reached only through a Windows cc toolchain._compile_windows_resourceruns after_init_cc_ruleresolves the cc toolchain, and Linux registers no Windows cc toolchain, so an analysis test on Linux cannot reach the resource tool choice or the empty-INCLUDE failure. The Windows build above covers that path.)Performance
</details>