Skip to content

Commit

Permalink
modern-cmake: Support older MSVC CMake which had a bug
Browse files Browse the repository at this point in the history
  • Loading branch information
superdump committed Jun 30, 2020
1 parent 832cef7 commit c2a9df8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
cmake_minimum_required(VERSION 3.1...3.13)
cmake_minimum_required(VERSION 3.1)

if(${CMAKE_VERSION} VERSION_LESS 3.12)
if(${CMAKE_VERSION} VERSION_LESS 3.15)
cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
else()
cmake_policy(VERSION 3.15)
endif()

project(project
Expand Down

0 comments on commit c2a9df8

Please sign in to comment.