Skip to content

fix: support platforms without fspy by gating the fspy crates out - #829

Open
mfechner wants to merge 1 commit into
voidzero-dev:mainfrom
mfechner:freebsd-support-2
Open

mfechner wants to merge 1 commit into
voidzero-dev:mainfrom
mfechner:freebsd-support-2

Conversation

@mfechner

Copy link
Copy Markdown

The fspy file-access tracking family (fspy, fspy_nostd, fspy_shared, fspy_shm, ...) only builds on Windows, macOS, and Linux, so any other platform could not build Vite+ at all: its always-on dependency chain (vt -> vt_server -> vt_client -> vt_ipc_shared -> fspy_ipc_str) pulled in fspy_nostd, which has no backend outside those three OSes.

Instead of porting fspy_nostd or adding no-op backends and per-item cfgs, gate the fspy crates at the crate level and keep the IPC layer portable:

  • fspy_ipc_str no longer depends on fspy_nostd/fspy_nostd_alloc. The two C-string interop methods (from_os_c_str, to_os_c_string_in) move into fspy_shared as free functions built on fspy_shared's own types, so IpcStr stays a cross-platform wire type while fspy_nostd leaves the always-on graph entirely.
  • vt's fspy-only execution code (FspyTracking, the TrackingIncomplete reason, is_ignored, the tracking_incomplete summary field) is now excluded via the existing cfg(fspy) when tracking is not compiled in.
  • On such platforms a task requesting automatic input/output inference reports that tracking is unsupported and must configure input and output manually to be cached (FspyUnsupported), as intended.

Verified on FreeBSD 15: cargo check/clippy/test pass for the product graph (vt_bin, vt, vt_client, vt_server, vt_ipc_shared, fspy_ipc_str) and the vp binary builds and runs.

The fspy file-access tracking family (fspy, fspy_nostd, fspy_shared,
fspy_shm, ...) only builds on Windows, macOS, and Linux, so any other
platform could not build Vite+ at all: its always-on dependency chain
(vt -> vt_server -> vt_client -> vt_ipc_shared -> fspy_ipc_str) pulled
in fspy_nostd, which has no backend outside those three OSes.

Instead of porting fspy_nostd or adding no-op backends and per-item
cfgs, gate the fspy crates at the crate level and keep the IPC layer
portable:

- fspy_ipc_str no longer depends on fspy_nostd/fspy_nostd_alloc. The
  two C-string interop methods (from_os_c_str, to_os_c_string_in) move
  into fspy_shared as free functions built on fspy_shared's own types,
  so IpcStr stays a cross-platform wire type while fspy_nostd leaves
  the always-on graph entirely.
- vt's fspy-only execution code (FspyTracking, the TrackingIncomplete
  reason, is_ignored, the tracking_incomplete summary field) is now
  excluded via the existing cfg(fspy) when tracking is not compiled in.
- On such platforms a task requesting automatic input/output inference
  reports that tracking is unsupported and must configure input and
  output manually to be cached (FspyUnsupported), as intended.

Verified on FreeBSD 15: cargo check/clippy/test pass for the product
graph (vt_bin, vt, vt_client, vt_server, vt_ipc_shared, fspy_ipc_str)
and the vp binary builds and runs.

Co-authored-by: Hermes Agent <noreply@nousresearch.com>
@mfechner mfechner mentioned this pull request Oct 10, 2026

This branch has not been deployed

No deployments
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