Skip to content

fix(desktop): make Windows release compile cleanly#1029

Merged
wpfleger96 merged 3 commits into
mainfrom
duncan/windows-release-compile-fix
Jun 13, 2026
Merged

fix(desktop): make Windows release compile cleanly#1029
wpfleger96 merged 3 commits into
mainfrom
duncan/windows-release-compile-fix

Conversation

@wpfleger96

Copy link
Copy Markdown
Collaborator

The v0.3.20 release workflow's Windows job fails to compile two desktop source files that contain platform-conditional code never validated on Windows. PR CI builds the desktop app for macOS and Linux only, so these errors surface only at release time — which is why every prior Windows release stopped at the same point.

desktop/src-tauri/src/migration.rs

sync_shared_agent_data (the dev-only worktree-sync helper) called std::os::unix::fs::symlink unconditionally at three sites. std::os::unix does not exist on Windows. This adds a #[cfg]-selected symlink helper — std::os::unix::fs::symlink on unix, a no-op Ok(()) on non-unix — and routes the three sites through it. This matches the convention already used by copy_dir_all in the same file. Worktree sync only runs when BUZZ_SHARE_IDENTITY=1, a dev-only env var no release user sets, so the non-unix no-op path is unreachable in production.

desktop/src-tauri/src/commands/media.rs

fd_real_path cast a file handle with as isize, but windows-sys 0.61 changed HANDLE to *mut core::ffi::c_void. The cast now targets the matching pointer type.

macOS and Linux builds are unaffected — the #[cfg(unix)] branch is byte-identical to the previous behavior.

Verification

cargo check (native, unix) passes clean. Local cargo check --target x86_64-pc-windows-msvc from macOS does not reach typechecking: the aws-lc-sys build script fails to compile its C sources against windows.h (no MSVC headers on the host) — a *-sys toolchain gap unrelated to this change. The Windows release CI job is the authoritative gate.

npub1mn7jgtj4w2pd0g0zeuhxsa6jy6p0rewxz4kujt98my82ahfmp72sxjexk7 and others added 3 commits June 12, 2026 23:18
The release workflow's Windows job failed to compile two source files
containing platform-conditional code never validated on Windows: PR CI
builds the desktop app for macOS/Linux only, so these surfaced only at
release time.

migration.rs called std::os::unix::fs::symlink unconditionally in the
dev-only worktree-sync helper; gate it behind a #[cfg]-selected symlink
helper (no-op on non-unix), matching the existing copy_dir_all
convention. media.rs cast a file handle to isize, but windows-sys 0.61
changed HANDLE to *mut c_void; cast to the matching type.

Co-authored-by: Will Pfleger <pfleger.will@gmail.com>
Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
…ared setup

The arm64 'release' job created the GitHub release objects and computed the
version string, so the other three platform jobs were chained behind it via
needs: release. That serialized four independent builds and coupled them to
arm64 codesign — a branch dispatch could never reach the Windows job because
arm64's OIDC AssumeRole is denied on non-release refs, skipping everything
downstream.

Extract a no-OIDC 'setup' job that determines the version and creates both
the versioned and rolling releases up front. All four platform jobs now
depend only on setup and run concurrently; setup is the sole release creator,
the platform jobs are pure uploaders, removing the create race the
concurrency change would otherwise expose. Rolling-release uploads and the
latest.json assembly are gated on tag pushes so a branch dispatch can
validate compiles without clobbering the live auto-update channel.

Co-authored-by: Will Pfleger <pfleger.will@gmail.com>
Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
After the source-level Windows compile fixes, the release build reached the
link stage and failed with LNK1181: cannot open input file 'sqlite3.lib'.
rusqlite was declared without the bundled feature, so libsqlite3-sys tried
to link a system sqlite3.lib that windows-latest does not provide.

Enable rusqlite's bundled feature to compile and statically link SQLite from
vendored source, removing the system-library dependency on all platforms.

Co-authored-by: Will Pfleger <pfleger.will@gmail.com>
Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
@wpfleger96 wpfleger96 merged commit 5c2f46e into main Jun 13, 2026
23 checks passed
@wpfleger96 wpfleger96 deleted the duncan/windows-release-compile-fix branch June 13, 2026 17:28
tlongwell-block pushed a commit that referenced this pull request Jun 13, 2026
* origin/main: (33 commits)
  fix(desktop): make Windows release compile cleanly (#1029)
  Add production Docker Compose bundle (#985)
  feat(profile): show active turn badges on agent profile panel and popover (#1026)
  chore(release): release version 0.3.20 (#1027)
  fix(release): resolve Windows sidecar path and Linux AppImage updater format (#1024)
  chore(release): release version 0.3.19 (#1014)
  fix(release): ignore prerelease tags in changelog generation (#1021)
  fix: repair main build after cross-PR merge skew (#1020)
  feat(agents): show per-turn duration and prune dead turns within ~25s of host crash (#1017)
  fix(release): replace hermit with native tool setup on Windows job (#1018)
  feat(acp): surface error-class outcomes to the activity feed only, never the channel (#1010)
  fix(desktop): migrate Sprout workspace storage (#1016)
  feat(auth): force token refresh on rejected token (401/403), never the browser (#1015)
  fix(release): mark prerelease versions so they do not become latest (#1013)
  feat(acp): implement systemPrompt with protocol version gating (#981)
  fix(release): update repository name check from block/sprout to block/buzz (#1012)
  feat(release): all-OS desktop builds + universal auto-update manifest (#1011)
  Add relay disconnect UX: friendly errors, reconnect, cached identity (#1004)
  feat(agents): add active turn indicators to Agents Menu (#1005)
  ci: add fork guards to docker, release, and auto-tag workflows (#1007)
  ...

Co-authored-by: npub1t2tgm7d8f995uqvmnm8h88sg3wnpp9a5xysjf6dg3tjmgt3ltulqdp8ehr <5a968df9a7494b4e019b9ecf739e088ba61097b4312124e9a88ae5b42e3f5f3e@sprout-oss.stage.blox.sqprod.co>
Signed-off-by: npub1t2tgm7d8f995uqvmnm8h88sg3wnpp9a5xysjf6dg3tjmgt3ltulqdp8ehr <5a968df9a7494b4e019b9ecf739e088ba61097b4312124e9a88ae5b42e3f5f3e@sprout-oss.stage.blox.sqprod.co>
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