windows: Always set NOMINMAX to remove min/max macros
Reviewed-by: Francisco Jerez <currojerez@riseup.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7680>
This commit is contained in:
@@ -988,6 +988,7 @@ elif host_machine.system() == 'windows'
|
|||||||
'-D_SCL_SECURE_NO_DEPRECATE',
|
'-D_SCL_SECURE_NO_DEPRECATE',
|
||||||
'-D_ALLOW_KEYWORD_MACROS',
|
'-D_ALLOW_KEYWORD_MACROS',
|
||||||
'-D_HAS_EXCEPTIONS=0', # Tell C++ STL to not use exceptions
|
'-D_HAS_EXCEPTIONS=0', # Tell C++ STL to not use exceptions
|
||||||
|
'-DNOMINMAX',
|
||||||
]
|
]
|
||||||
else
|
else
|
||||||
pre_args += ['-D__MSVCRT_VERSION__=0x0700']
|
pre_args += ['-D__MSVCRT_VERSION__=0x0700']
|
||||||
|
@@ -39,7 +39,9 @@
|
|||||||
#undef NOMINMAX
|
#undef NOMINMAX
|
||||||
#define UNICODE
|
#define UNICODE
|
||||||
#else
|
#else
|
||||||
|
#undef UNICODE
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
#define UNICODE
|
||||||
#endif
|
#endif
|
||||||
#include <intrin.h>
|
#include <intrin.h>
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
|
Reference in New Issue
Block a user