cmConfigure.h: Tell windows.h not to define min/max macros

This commit is contained in:
Brad King 2019-08-19 15:39:02 -04:00
parent a0c8405d68
commit 141e307484
2 changed files with 10 additions and 0 deletions

View File

@ -26,4 +26,8 @@
#define CM_FALLTHROUGH cmsys_FALLTHROUGH
#if defined(_WIN32) && !defined(NOMINMAX)
# define NOMINMAX
#endif
#endif

View File

@ -1364,6 +1364,12 @@ cmake_report cmConfigure.h${_tmp} "#define CMAKE_BIN_DIR \"/bootstrap-not-insall
cmake_report cmConfigure.h${_tmp} "#define CMAKE_DATA_DIR \"/bootstrap-not-insalled\""
cmake_report cmConfigure.h${_tmp} "#define CM_FALLTHROUGH"
if ${cmake_system_mingw}; then
cmake_report cmConfigure.h${_tmp} "#if defined(_WIN32) && !defined(NOMINMAX)"
cmake_report cmConfigure.h${_tmp} "# define NOMINMAX"
cmake_report cmConfigure.h${_tmp} "#endif"
fi
# Regenerate configured headers
for h in Configure VersionConfig; do
if "${_diff}" cm${h}.h cm${h}.h${_tmp} > /dev/null 2> /dev/null; then