Skip to content

Commit eeb07b6

Browse files
committed
fixed #14491 - bumped minimum CMake version to 3.16
1 parent 214021a commit eeb07b6

File tree

4 files changed

+8
-11
lines changed

4 files changed

+8
-11
lines changed

.github/workflows/CI-unixish.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ jobs:
2121
runs-on: ubuntu-22.04
2222

2323
env:
24-
CMAKE_VERSION: 3.13
25-
CMAKE_VERSION_FULL: 3.13.5
24+
CMAKE_VERSION: 3.16
25+
CMAKE_VERSION_FULL: 3.16.9
2626

2727
steps:
2828
- uses: actions/checkout@v4

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
cmake_minimum_required(VERSION 3.13)
1+
cmake_minimum_required(VERSION 3.16)
22
project(Cppcheck VERSION 2.18.99 LANGUAGES CXX)
33

44
include(cmake/options.cmake)

cmake/options.cmake

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -113,14 +113,10 @@ option(ENABLE_CSA_ALPHA "Enable Clang Static Analyzer alpha checkers for run
113113
# TODO: disable by default like make build?
114114
option(FILESDIR "Hard-coded directory for files to load from" OFF)
115115

116-
if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.16")
117-
set(CMAKE_DISABLE_PRECOMPILE_HEADERS Off CACHE BOOL "Disable precompiled headers")
118-
# need to disable the prologue or it will be treated like a system header and not emit any warnings
119-
# see https://gitlab.kitware.com/cmake/cmake/-/issues/21219
120-
set(CMAKE_PCH_PROLOGUE "")
121-
else()
122-
set(CMAKE_DISABLE_PRECOMPILE_HEADERS On CACHE BOOL "Disable precompiled headers")
123-
endif()
116+
set(CMAKE_DISABLE_PRECOMPILE_HEADERS Off CACHE BOOL "Disable precompiled headers")
117+
# need to disable the prologue or it will be treated like a system header and not emit any warnings
118+
# see https://gitlab.kitware.com/cmake/cmake/-/issues/21219
119+
set(CMAKE_PCH_PROLOGUE "")
124120

125121
set(CMAKE_INCLUDE_DIRS_CONFIGCMAKE ${CMAKE_INSTALL_PREFIX}/include CACHE PATH "Output directory for headers")
126122
set(CMAKE_LIB_DIRS_CONFIGCMAKE ${CMAKE_INSTALL_PREFIX}/lib CACHE PATH "Output directory for libraries")

releasenotes.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,5 @@ Infrastructure & dependencies:
2222

2323
Other:
2424
- The built-in "win*" and "unix*" platforms will now default to signed char type instead of unknown signedness. If you require unsigned chars please specify "--funsigned-char"
25+
- bumped minimum required CMake version to 3.16
2526
-

0 commit comments

Comments
 (0)