cppcheck skips most files in lib/
Adding --enable=information
and gives the following warning for most of our files in lib/
:
noValidConfiguration:lib/algorithms/cert_types.c:0,information,This file is not analyzed. Cppcheck failed to extract a valid configuration. Use -v for more details.
Adding -v prints a lot stuff, mainly saying that cppcheck has a problem with gl/c-ctype.h
.
The tested configurations have these preprocessor errors:\012HAVE_CONFIG_H=1 : [gl/c-ctype.h:78] #error "Only ASCII and EBCDIC are supported"
Setting # define C_CTYPE_ASCII 1
hard-coded in gl/c-ctype.h
(removing the #if check) seems to work out. Though cppcheck is extremely slow...
BTW, in gitlab-ci.yml
the cppcheck option -Ilib/include
should be -Ilib/includes
.