Skip to content

Commit c9371de

Browse files
gruenichjbeder
authored andcommitted
[cmake] Require minimum CMake version 3.5
Soon CMake 4.0 will be released. It requires that projects set a minimum required CMake version of 3.5. There is a workaround with an additional flag, but it would is better to increase the minimum required version.
1 parent 28f93bd commit c9371de

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# 3.5 is actually available almost everywhere, but this a good minimum.
2-
# 3.14 as the upper policy limit avoids CMake deprecation warnings.
3-
cmake_minimum_required(VERSION 3.4...3.14)
1+
# 3.5 is actually available almost everywhere.
2+
# 3.30 as the upper policy limit avoids CMake deprecation warnings.
3+
cmake_minimum_required(VERSION 3.5...3.30)
44

55
# enable MSVC_RUNTIME_LIBRARY target property
66
# see https://cmake.org/cmake/help/latest/policy/CMP0091.html

test/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ find_package(Threads REQUIRED)
33
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
44
set(BUILD_MOCK ON CACHE BOOL "" FORCE)
55
set(INSTALL_GTEST OFF CACHE BOOL "" FORCE)
6-
set(CMAKE_POLICY_DEFAULT_CMP0048 NEW)
76

87
if(YAML_USE_SYSTEM_GTEST)
98
find_package(GTest)

0 commit comments

Comments
 (0)