[PATCH] D74599: llvm: Set WINVER to 0x601 (Windows 7) for MinGW

Adrian McCarthy via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 19 08:33:06 PST 2020


amccarth added a comment.

Come to think of it, if you're setting `WINVER`, I believe you should also set `_WIN32_WINNT`.

https://docs.microsoft.com/en-us/cpp/porting/modifying-winver-and-win32-winnt?view=vs-2019

As is, this patch works, because WINVER affects the platform SDK, which is all you need for CompareStringOrdinal.  If I recall correctly, _WIN32_WINNT affects some of the language run-time libraries (some of which the SDK headers may depend on).  So while it's not strictly necessary to define _WIN32_WINNT to ensure this particular function is declared, it would be a good precaution against WINVER and _WIN32_WINNT from being set incompatibly.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D74599





More information about the llvm-commits mailing list