bumped Cppcheck to 2.12.1

- build Cppcheck with matchcompiler for improved performance
- build Cppcheck with Boost for improved ValueFlow performance
This commit is contained in:
firewave 2023-09-09 19:50:16 +02:00
parent f687174af1
commit 8c214280d3
3 changed files with 9 additions and 4 deletions

View File

@ -165,7 +165,7 @@ jobs:
CC: gcc
# This is required to use a version of cppcheck other than that
# supplied with the operating system
CPPCHECK_VER: "2.11"
CPPCHECK_VER: "2.12.1"
CPPCHECK_REPO: https://github.com/danmar/cppcheck.git
steps:
# Set steps.os.outputs.image to the specific OS (e.g. 'ubuntu20')

View File

@ -123,17 +123,20 @@ fi
cd "$workdir"
make_args="MATCHCOMPILER=yes FILESDIR=$FILESDIR PREFIX=$FILESDIR"
case "$CPPCHECK_VER" in
1.*)
# CFGDIR is needed for cppcheck before 1.86
make_args="FILESDIR=$FILESDIR PREFIX=$FILESDIR CFGDIR=$FILESDIR"
make_args="$make_args CFGDIR=$FILESDIR"
;;
2.8 | 2.9 | 2.1*)
# Cppcheck 2.8 removed the dependency on z3
make_args="FILESDIR=$FILESDIR PREFIX=$FILESDIR"
# Cppcheck 2.8 added optional support for utilizing Boost
make_args="$make_args CPPFLAGS=-DHAVE_BOOST"
;;
2.*)
make_args="FILESDIR=$FILESDIR PREFIX=$FILESDIR USE_Z3=yes"
make_args="$make_args USE_Z3=yes"
# Check that the Z3 development files appear to be installed
# before trying to create z3_version.h. Otherwise we may
# mislead the user as to what needs to be done.

View File

@ -24,6 +24,8 @@ case "$CPPCHECK_VER" in
;;
2.8 | 2.9 | 2.1*)
# Cppcheck 2.8 removed the dependency on z3
# Cppcheck 2.8 added optional support for utilizing Boost
PACKAGES="$PACKAGES libboost-container-dev"
;;
2.*)
PACKAGES="$PACKAGES libz3-dev z3"