Commit Graph

2 Commits

Author SHA1 Message Date
Martin Storsjö ead7c3cdc3 [clang] [MinGW] Add an implicit .exe suffix even when crosscompiling
GCC 8 changed behaviour wrt this, and made it consistent for cross
compilation cases. While it's a change, it's a more sensible behaviour
going forward.

Differential Revision: https://reviews.llvm.org/D88005
2020-09-21 23:42:59 +03:00
Martin Storsjö ee0a3b5c77 [MinGW] Implicitly add .exe suffix if not provided
GCC implicitly adds an .exe suffix if it is given an output file name,
but the file name doesn't contain a suffix, and there are certain
users of GCC that rely on this behaviour (and run into issues when
trying to use Clang instead of GCC). And MSVC's cl.exe also does the
same (but not link.exe).

However, GCC only does this when actually running on windows, not when
operating as a cross compiler.

As GCC doesn't have this behaviour when cross compiling, we definitely
shouldn't introduce the behaviour in such cases (as it would break
at least as many cases as this fixes).

Differential Revision: https://reviews.llvm.org/D71400
2019-12-17 10:08:39 +02:00