mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 00:20:18 +01:00
Added define to fix issue with compatibility with latest Windows SDK (#85408)
Fixes #83820. Pull Request resolved: https://github.com/pytorch/pytorch/pull/85408 Approved by: https://github.com/ezyang
This commit is contained in:
parent
f24d174fff
commit
409efebab8
|
|
@ -92,6 +92,10 @@ endif()
|
|||
if(MSVC)
|
||||
# skip unwanted includes from windows.h
|
||||
add_definitions(-DWIN32_LEAN_AND_MEAN)
|
||||
|
||||
# Windows SDK broke compatibility since version 25131, but introduced this define for backward compatibility.
|
||||
add_definitions(-D_UCRT_LEGACY_INFINITY)
|
||||
|
||||
foreach(flag_var
|
||||
CMAKE_C_FLAGS CMAKE_C_FLAGS_RELEASE CMAKE_C_FLAGS_MINSIZEREL
|
||||
CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_RELEASE CMAKE_CXX_FLAGS_MINSIZEREL)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user