mirror of
https://github.com/therealaleph/MasterHttpRelayVPN-RUST.git
synced 2026-05-17 21:24:48 +03:00
ci(release): pin i686-pc-windows-msvc to Rust 1.77.2 for Win7 compat (#323)
* ci(release): pin i686-pc-windows-msvc to Rust 1.77.2 for Win7 compat Fixes #318. Rust 1.78 (May 2024) raised the std MSRV for Windows from Win7 to Win10 by switching std::time to GetSystemTimePreciseAsFileTime, a kernel32 export that doesn't exist on Win7 SP1. Building the i686 binary with stable Rust (currently 1.86+) produces an exe that fails to load on Win7 with "the procedure entry point GetSystemTimePreciseAsFile could not be located in the dynamic link library kernel32.dll" — making the whole reason we ship i686 (legacy Win7 32-bit boxes per #272) moot. Add a per-matrix `rust_toolchain` knob; only i686-pc-windows-msvc uses it, pinning to 1.77.2 (last stable that supports Win7). Other targets remain on @stable and pick up regular Rust updates. dtolnay/rust-toolchain switches from `@stable` to `@master` because the per-tag aliases (`@stable`, `@1.77.2`) can't be selected via a matrix variable — `@master` accepts the toolchain string as input. Cache key gains a toolchain suffix so the 1.77.2 cache doesn't collide with the stable cache for the same target, and a future toolchain bump invalidates only the affected slot. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * ci(release): make i686-pc-windows-msvc continue-on-error Companion to the Rust 1.77.2 pin: if the deps' MSRV ever moves above 1.77, the i686 target will fail to build, but we don't want it to block the rest of the release. Mirror the mipsel-softfloat approach. If/when this triggers, options are dropping i686 entirely or moving to the tier-3 i686-win7-windows-msvc target. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
committed by
GitHub
parent
8bc82d53b2
commit
501d54edec
@@ -79,7 +79,16 @@ jobs:
|
||||
name: mhrv-rs-windows-amd64
|
||||
- target: i686-pc-windows-msvc
|
||||
os: windows-latest
|
||||
name: mhrv-rs-windows-i686
|
||||
name: mhrv-rs-windows-i686
|
||||
# Pin Rust 1.77.2 specifically for this target. Rust 1.78
|
||||
# (May 2024) raised the Windows MSRV from Win7 to Win10 by
|
||||
# switching std::time to GetSystemTimePreciseAsFileTime, a
|
||||
# kernel32 export that doesn't exist on Win7. The whole
|
||||
# reason this target ships is to support legacy Win7 32-bit
|
||||
# boxes (#272), so a stock-stable build defeats the purpose.
|
||||
# 1.77.2 is the last stable that produces a Win7-loadable
|
||||
# binary; other targets stay on @stable. (Fixes #318.)
|
||||
rust_toolchain: "1.77.2"
|
||||
- target: x86_64-unknown-linux-musl
|
||||
os: [self-hosted, linux, x64, mhrv-build]
|
||||
name: mhrv-rs-linux-musl-amd64
|
||||
@@ -103,7 +112,12 @@ jobs:
|
||||
# mipsel-softfloat is best-effort: the Rust tier-3 target occasionally
|
||||
# regresses. Letting it fail keeps the main release going so
|
||||
# desktop/Android users aren't blocked by MT7621 router support.
|
||||
continue-on-error: ${{ matrix.mipsel_softfloat == true }}
|
||||
# i686-pc-windows-msvc is similarly best-effort — pinned to Rust
|
||||
# 1.77.2 for Win7 compat (#318), so a future dep MSRV bump above
|
||||
# 1.77 will fail this one target. Letting it skip keeps the rest
|
||||
# of the release unblocked; we'd then choose between dropping the
|
||||
# target or moving to the tier-3 win7-msvc target with build-std.
|
||||
continue-on-error: ${{ matrix.mipsel_softfloat == true || matrix.target == 'i686-pc-windows-msvc' }}
|
||||
|
||||
steps:
|
||||
# Heal any root-owned leftovers from a previous mipsel docker
|
||||
@@ -141,9 +155,14 @@ jobs:
|
||||
# installed and the standard target triples are pre-added. It
|
||||
# still verifies the target is present and is cheap enough to keep
|
||||
# as a safety net.
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
# Per-matrix-entry toolchain selection. Default is `stable` (latest)
|
||||
# for every target except where `rust_toolchain` is explicitly pinned
|
||||
# — currently just i686-pc-windows-msvc, which needs 1.77.2 to keep
|
||||
# the Win7 binary loadable (Rust 1.78+ raised Windows MSRV to Win10).
|
||||
- uses: dtolnay/rust-toolchain@master
|
||||
if: matrix.mipsel_softfloat != true
|
||||
with:
|
||||
toolchain: ${{ matrix.rust_toolchain || 'stable' }}
|
||||
targets: ${{ matrix.target }}
|
||||
|
||||
# Cache target/ + cargo registry across runs — this is the big
|
||||
@@ -162,7 +181,11 @@ jobs:
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
if: matrix.mipsel_softfloat != true
|
||||
with:
|
||||
key: ${{ matrix.target }}
|
||||
# Include toolchain in the cache key so a pinned-Rust target
|
||||
# (i686-pc-windows-msvc on 1.77.2) doesn't collide with
|
||||
# stable-Rust caches for other targets, and a future toolchain
|
||||
# bump invalidates only the affected slot.
|
||||
key: ${{ matrix.target }}-${{ matrix.rust_toolchain || 'stable' }}
|
||||
cache-bin: "false"
|
||||
|
||||
# eframe needs a few system libs on Linux for window management, keyboard,
|
||||
|
||||
Reference in New Issue
Block a user