Skip to content

Add reproducible Windows shim build + CI verification - #154

Closed
bigfootjon wants to merge 2 commits into
mainfrom
verify-windows-shim
Closed

Add reproducible Windows shim build + CI verification#154
bigfootjon wants to merge 2 commits into
mainfrom
verify-windows-shim

Conversation

@bigfootjon

Copy link
Copy Markdown
Contributor

Make the Windows shim build byte-for-byte reproducible and add a CI job that rebuilds it and fails if the checked-in binaries are stale.

  • release.py now links with the toolchain-bundled rust-lld (no MSVC "Rich" header) and passes /Brepro for content-hashed timestamps, so the output depends only on the pinned toolchain. It also accepts an optional target triple so CI can build one architecture per native runner.
  • Pin rust-toolchain.toml to a dated nightly so the reproducible output is stable over time.
  • Add the verify-windows-shim workflow: builds x86_64 on windows-latest and aarch64 on windows-11-arm, uploads each rebuilt .exe as an artifact, then fails on git diff if the committed binary differs. The artifact-before- check ordering lets contributors without a Windows machine download the correct binaries from the run and commit them.
  • Update windows_shim/README.md and website/docs/windows.md accordingly.

Note: the checked-in .exe files still need to be regenerated (via CI artifacts or py release.py) to match the new reproducible build.

Make the Windows shim build byte-for-byte reproducible and add a CI job
that rebuilds it and fails if the checked-in binaries are stale.

- release.py now links with the toolchain-bundled rust-lld (no MSVC "Rich"
  header) and passes /Brepro for content-hashed timestamps, so the output
  depends only on the pinned toolchain. It also accepts an optional target
  triple so CI can build one architecture per native runner.
- Pin rust-toolchain.toml to a dated nightly so the reproducible output is
  stable over time.
- Add the verify-windows-shim workflow: builds x86_64 on windows-latest and
  aarch64 on windows-11-arm, uploads each rebuilt .exe as an artifact, then
  fails on `git diff` if the committed binary differs. The artifact-before-
  check ordering lets contributors without a Windows machine download the
  correct binaries from the run and commit them.
- Update windows_shim/README.md and website/docs/windows.md accordingly.

Note: the checked-in .exe files still need to be regenerated (via CI
artifacts or `py release.py`) to match the new reproducible build.
@meta-cla meta-cla Bot added the cla signed label Jul 30, 2026
@meta-codesync

meta-codesync Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

This pull request has been imported. If you are a Meta employee, you can view this in D114251821. (Because this pull request was imported automatically, there will not be any future comments.)

@meta-codesync

meta-codesync Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

@bigfootjon merged this pull request in ba6b861.

@meta-codesync meta-codesync Bot added the Merged label Jul 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant