Support MSVC linker response files for long and Unicode input paths
- Dominant language
- Rust
- Stars
- 53
- Forks
- 16
- Avg merge
- 4h 22m
- Merged PRs (30d)
- 46
Description
Part of #611. Difficulty: **medium**. Audit baseline: master `3950416e` (2026-09-12).
## Current evidence
[src/cli.rs](https://github.com/wavefnd/Wave/blob/3950416efc55cbc5ae7d54535e5a4e8699394ff0/src/cli.rs#L2320) sends the entire MSVC argument vector directly to ProcessCommand. The backend path in [llvm/src/backend.rs](https://github.com/wavefnd/Wave/blob/3950416efc55cbc5ae7d54535e5a4e8699394ff0/llvm/src/backend.rs#L230) also invokes a command directly; no Wave-owned response-file transport is present in these paths.
## Scope
Add a shared response-file path when MSVC link commands exceed a conservative Windows command-length budget, preserving the exact logical argument order. Follow the selected link.exe/lld-link encoding and quoting rules, including spaces, non-ASCII paths, quotes and trailing backslashes. Coordinate temporary output rewriting before serializing the final arguments.
## Completion criteria
Unit tests exercise argument round-tripping and lifecycle cleanup, and native integration tests link many object paths from a Unicode directory with spaces using each supported linker. Nonzero exits preserve diagnostics and previous outputs. Dry-run exposes a useful logical plan. Response files are removed on success/failure after the child exits. No command shell is introduced.
## Dependencies and boundaries
#498; applies to #613 and #621; independent of ABI implementation.
References: [MSVC linker response files](https://learn.microsoft.com/en-us/cpp/build/reference/at-specify-a-linker-response-file)
Contributor guide
Research direction
Start with the direct ProcessCommand invocations in src/cli.rs around line 2320 and llvm/src/backend.rs around line 230, then review the MSVC linker response-file reference and dependencies #498, #613, and #621. Define tests for argument round-tripping, cleanup, diagnostics, dry-run output, and native linking with Unicode paths, spaces, and many objects. Done means both link paths preserve logical arguments without a shell and remove temporary response files after success or failure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- compilers, operating-systems
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100