Edit HACKING: cppcheck v1.58
This commit is contained in:
parent
9632f3ef35
commit
f152aaffa3
1 changed files with 25 additions and 16 deletions
17
HACKING
17
HACKING
|
@ -23,6 +23,7 @@ Here are some directions to get you started:
|
|||
2.1 When using autotools
|
||||
$ autoreconf -Wall -vis
|
||||
2.2 When compiling
|
||||
2.2.1 Using extra flags:
|
||||
$ export CFLAGS="-Wall -g -O2 -Wextra -pipe -funsigned-char -fstrict-aliasing \
|
||||
-Wchar-subscripts -Wundef -Wshadow -Wcast-align -Wwrite-strings -Wunused \
|
||||
-Wuninitialized -Wpointer-arith -Wredundant-decls -Winline -Wformat \
|
||||
|
@ -32,13 +33,21 @@ Here are some directions to get you started:
|
|||
$ ./configure
|
||||
$ make clean
|
||||
$ make
|
||||
You can chase even more issues by using clang:
|
||||
2.2.2 Using clang:
|
||||
$ scan-build ./configure
|
||||
$ make clean
|
||||
$ scan-build make
|
||||
And by using cppcheck:
|
||||
$ cppcheck --quiet --enable=all --std=c99 --std=posix \
|
||||
-I include -I libnfc -I libnfc/buses .
|
||||
2.2.3 Using cppcheck (v1.58 or higher):
|
||||
$ cppcheck --quiet \
|
||||
-I include -I libnfc -I libnfc/buses -I libnfc/chips -I libnfc/drivers \
|
||||
--check-config .
|
||||
$ cppcheck --quiet --enable=all --std=posix --std=c99 \
|
||||
-I include -I libnfc -I libnfc/buses -I libnfc/chips -I libnfc/drivers \
|
||||
-DLOG -D__linux__ \
|
||||
-DDRIVER_PN53X_USB_ENABLED -DDRIVER_ACR122_PCSC_ENABLED \
|
||||
-DDRIVER_ACR122_USB_ENABLED -DDRIVER_ACR122S_ENABLED \
|
||||
-DDRIVER_PN532_UART_ENABLED -DDRIVER_ARYGON_ENABLED \
|
||||
--force .
|
||||
2.3 When Debianizing
|
||||
$ lintian --info --display-info --display-experimental *deb
|
||||
or (shorter version)
|
||||
|
|
Loading…
Reference in a new issue