Skip to content

Commit 15c392d

Browse files
Flamefireevpobr
authored andcommitted
Update minimum CMake version
With the release of CMake 4 CMake < 3.5 is no longer supported and at least 3.10 is deprecated. Update to 3.16 as the minimum and remove some of the workarounds and policies.
1 parent 4858fb0 commit 15c392d

File tree

1 file changed

+1
-21
lines changed

1 file changed

+1
-21
lines changed

CMakeLists.txt

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,4 @@
1-
cmake_minimum_required(VERSION 3.1..3.18)
2-
3-
# Policies
4-
5-
# Include file check macros honor CMAKE_REQUIRED_LIBRARIES, CMake >= 3.12
6-
if(POLICY CMP0075)
7-
cmake_policy(SET CMP0075 NEW)
8-
endif()
9-
10-
# MSVC runtime library flags are selected by an abstraction, CMake >= 3.15
11-
# This policy still need to be set even with cmake_minimum_required() command above.
12-
if(POLICY CMP0091)
13-
cmake_policy(SET CMP0091 NEW)
14-
endif()
1+
cmake_minimum_required(VERSION 3.16..3.20)
152

163
project(libsamplerate VERSION 0.2.2 LANGUAGES C)
174

@@ -140,11 +127,4 @@ endif()
140127

141128
# Packaging support
142129

143-
# See https://cmake.org/cmake/help/v3.12/release/3.12.html#cpack
144-
if(CMAKE_VERSION VERSION_LESS 3.12)
145-
set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR})
146-
set(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR})
147-
set(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH})
148-
endif()
149-
150130
include(CPack)

0 commit comments

Comments
 (0)