Closed abdes closed 6 years ago
Be careful of this one. I tried to work it in the past. When I removed the quotes to comply with policy it broke Windows builds with spaces in the path. It was the event that caused me to remove Cmake from the official sources.
The fix I propose is not to remove the quotes.
if (NOT ${CMAKE_VERSION} VERSION_LESS "3.1.0")
cmake_policy(SET CMP0054 NEW)
endif ()
Testing it right now on windows with VS 2017 and cmake 3.11.2 ...
Build passed - No warnings and MSVC flags were correctly set.
These warnings are because we set the minimum required version of cmake to 2.8.12 while on the build environment we may be using a much more recent version.