[PATCH] D80876: [clang] Default to windows response files when running on windows

Martin Storsjö via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sat Jun 6 11:44:37 PDT 2020


mstorsjo added a comment.

In D80876#2071997 <https://reviews.llvm.org/D80876#2071997>, @sbc100 wrote:

> In D80876#2070233 <https://reviews.llvm.org/D80876#2070233>, @mstorsjo wrote:
>
> > In D80876#2069970 <https://reviews.llvm.org/D80876#2069970>, @sbc100 wrote:
> >
> > > Do you know how gcc handles this case when running on mingw?
> >
> >
> > It uses the gnu/unix quoting style - so that's the case for wanting clang to preserve compatibility with that behaviour.
>
>
> Is there any case where gcc on windows will use the windows quoting style?


Not that I'm aware of, no.

> If the answer is no, and I assume GNU ar is the same, then perhaps the solution is revert https://reviews.llvm.org/D69665 instead and have all the llvm tools except clang-cl default to the GNU style.

Hmm, that might be at least one consistent strategy. For llvm-ar, it'd default to posix quoting, while llvm-lib does use windows style quoting. (It probably doesn't need a full revert, but keeping the rsp-quoting option, just changing the default.)

In one sense, it feels weird to stop doing the native thing in these tools, just for the sake of the mingw usecase - but on the other hand, if there's no other predecent for using windows style quoting with those particular tools, and there is predecent for keeping the posix quoting, I guess it should be fine. That would at least be a path forward without potentially breaking the msys2/mingw ecosystem.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D80876/new/

https://reviews.llvm.org/D80876





More information about the cfe-commits mailing list