CI: use compile command database for cppcheck
This commit is contained in:
@@ -1,11 +0,0 @@
|
||||
../src/
|
||||
../external/src/
|
||||
../external/src/cryptonote/
|
||||
../external/src/libuv/include/
|
||||
../external/src/cppzmq/
|
||||
../external/src/libzmq/include/
|
||||
../external/src/curl/include
|
||||
../external/src/RandomX/src/
|
||||
../external/src/rapidjson/include
|
||||
../external/src/robin-hood-hashing/src/include
|
||||
../external/src/miniupnp/miniupnpc/include
|
||||
@@ -1,5 +1,5 @@
|
||||
@echo off
|
||||
"..\cppcheck-main\bin\cppcheck.exe" --project=..\build\p2pool.vcxproj --project-configuration="Release|x64" -DSIZE_MAX=UINT64_MAX -DRAPIDJSON_ENDIAN=RAPIDJSON_LITTLEENDIAN -DRAPIDJSON_PARSE_DEFAULT_FLAGS=kParseTrailingCommasFlag -DZMQ_CPP11 -DZMQ_CPP14 --platform=win64 --std=c++14 --enable=all --inconclusive --inline-suppr --template="{file}:{line}:{id}{inconclusive: INCONCLUSIVE} {message}" --includes-file=includes.txt --suppressions-list=suppressions.txt --output-file=errors_full.txt --max-ctu-depth=3
|
||||
"..\cppcheck-main\bin\cppcheck.exe" --project=..\build\p2pool.vcxproj --project-configuration="Release|x64" -DSIZE_MAX=UINT64_MAX -DRAPIDJSON_ENDIAN=RAPIDJSON_LITTLEENDIAN --platform=win64 --std=c++14 --enable=all --inconclusive --inline-suppr --template="{file}:{line}:{id}{inconclusive: INCONCLUSIVE} {message}" --suppressions-list=suppressions.txt --output-file=errors_full.txt --max-ctu-depth=3 --check-level=exhaustive
|
||||
findstr /V /C:"external\src" errors_full.txt > errors_filtered.txt
|
||||
for /f %%i in ("errors_filtered.txt") do set size=%%~zi
|
||||
if %size% gtr 0 (
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
../cppcheck-main/cppcheck -DSIZE_MAX=UINT64_MAX -DRAPIDJSON_ENDIAN=RAPIDJSON_LITTLEENDIAN -DMINIUPNP_STATICLIB -DRAPIDJSON_PARSE_DEFAULT_FLAGS=kParseTrailingCommasFlag -DWITH_RANDOMX -DWITH_UPNP -DZMQ_STATIC -DZMQ_CPP11 -DZMQ_CPP14 --platform=unix64 --std=c++14 --enable=all --inconclusive --inline-suppr --template="{file}:{line}:{id}{inconclusive: INCONCLUSIVE} {message}" --includes-file=includes.txt --suppressions-list=suppressions.txt --output-file=errors_full.txt --max-ctu-depth=3 ../src
|
||||
../cppcheck-main/cppcheck --project=../build/compile_commands.json -DSIZE_MAX=UINT64_MAX -DRAPIDJSON_ENDIAN=RAPIDJSON_LITTLEENDIAN --platform=unix64 --std=c++14 --enable=all --inconclusive --inline-suppr --template="{file}:{line}:{id}{inconclusive: INCONCLUSIVE} {message}" --suppressions-list=suppressions.txt --output-file=errors_full.txt --max-ctu-depth=3 --check-level=exhaustive
|
||||
grep -v 'external' errors_full.txt > errors_filtered.txt
|
||||
if [ -s errors_filtered.txt ]; then
|
||||
cat errors_filtered.txt
|
||||
|
||||
Reference in New Issue
Block a user