Skip to content

Conversation

@ahoppen
Copy link
Member

@ahoppen ahoppen commented Oct 22, 2024

We were unconditionally passing --rsp-quoting to the linker on Windows. As far as I can tell, there are three different linkers we invoke on Windows:

  • clang.exe: This is what this fix is intended to cover
  • lld-link.exe: Defaults to Windows quoting style in response files and --rsp-quoting=windows is a no-op.
  • link.exe: Does not accept --rsp-quoting=windows

Move --rsp-quoting=windows to the point where we decide to use clang.exe as the linker on Windows and only pass it to clang.exe.

We were unconditionally passing `--rsp-quoting` to the linker on Windows. As far as I can tell, there are three different linkers we invoke on Windows:
- `clang.exe`: This is what this fix is intended to cover
- `lld-link.exe`: Defaults to Windows quoting style in response files and `--rsp-quoting=windows` is a no-op.
- `link.exe`: Does not accept `--rsp-quoting=windows`

Move `--rsp-quoting=windows` to the point where we decide to use `clang.exe` as the linker on Windows and only pass it to `clang.exe`.
@ahoppen
Copy link
Member Author

ahoppen commented Oct 22, 2024

@swift-ci Please test

@ahoppen ahoppen requested a review from artemcm October 23, 2024 16:15
@ahoppen ahoppen merged commit 63cac0b into swiftlang:main Oct 25, 2024
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.

2 participants