fix(windows): compile memset_shim to real .o via get_compiler() #121

Merged
sarman merged 1 commits from fix/cargo-config-sodium into beta 2026-06-19 20:42:29 +00:00

1 Commits

Author SHA1 Message Date
Shaun Arman
d0a985a53b fix(windows): compile memset_shim to real .o via get_compiler() to fix MinGW link
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m46s
Test / frontend-typecheck (pull_request) Successful in 1m58s
PR Review Automation / review (pull_request) Successful in 4m5s
Test / rust-fmt-check (pull_request) Successful in 13m11s
Test / rust-clippy (pull_request) Successful in 14m23s
Test / rust-tests (pull_request) Successful in 15m56s
compile("memset_shim") produces libmemset_shim.a, not memset_shim.o, so the
previous cargo:rustc-link-arg pointed at a file that never exists. Switching to
get_compiler().to_command() compiles memset_s_shim.c directly to a .o file at
a known OUT_DIR path and passes it as a positional linker arg. A positional .o
is always included unconditionally, which also resolves the archive-extraction
ordering issue where -l flags only pull symbols that are already undefined at
that point in the link command.
2026-06-19 15:21:58 -05:00