4199
|
1 #!/bin/bash
|
|
2
|
|
3 set -ex
|
|
4
|
|
5 CPPCHECK=cppcheck
|
|
6
|
|
7 if [ $# -ge 1 ]; then
|
|
8 CPPCHECK=$1
|
|
9 fi
|
|
10
|
|
11 ${CPPCHECK} --enable=all --quiet --std=c++11 \
|
|
12 -DBOOST_HAS_DATE_TIME=1 \
|
|
13 -DBOOST_HAS_FILESYSTEM_V3=1 \
|
|
14 -DBOOST_HAS_REGEX=1 \
|
|
15 -DCIVETWEB_HAS_DISABLE_KEEP_ALIVE=1 \
|
|
16 -DDCMTK_VERSION_NUMBER=365 \
|
|
17 -DMONGOOSE_USE_CALLBACKS=1 \
|
|
18 -DORTHANC_BUILDING_FRAMEWORK_LIBRARY=0 \
|
|
19 -DORTHANC_BUILDING_SERVER_LIBRARY=1 \
|
|
20 -DORTHANC_BUILD_UNIT_TESTS=1 \
|
|
21 -DORTHANC_ENABLE_BASE64=1 \
|
|
22 -DORTHANC_ENABLE_CIVETWEB=1 \
|
|
23 -DORTHANC_ENABLE_CURL=1 \
|
|
24 -DORTHANC_ENABLE_DCMTK=1 \
|
|
25 -DORTHANC_ENABLE_DCMTK_JPEG=1 \
|
|
26 -DORTHANC_ENABLE_DCMTK_JPEG_LOSSLESS=1 \
|
|
27 -DORTHANC_ENABLE_DCMTK_NETWORKING=1 \
|
|
28 -DORTHANC_ENABLE_DCMTK_TRANSCODING=1 \
|
|
29 -DORTHANC_ENABLE_JPEG=1 \
|
|
30 -DORTHANC_ENABLE_LOCALE=1 \
|
|
31 -DORTHANC_ENABLE_LOGGING=1 \
|
|
32 -DORTHANC_ENABLE_LOGGING_STDIO=1 \
|
|
33 -DORTHANC_ENABLE_LUA=1 \
|
|
34 -DORTHANC_ENABLE_MD5=1 \
|
|
35 -DORTHANC_ENABLE_MONGOOSE=0 \
|
|
36 -DORTHANC_ENABLE_PKCS11=1 \
|
|
37 -DORTHANC_ENABLE_PLUGINS=1 \
|
|
38 -DORTHANC_ENABLE_PNG=1 \
|
|
39 -DORTHANC_ENABLE_PUGIXML=1 \
|
|
40 -DORTHANC_ENABLE_SQLITE=1 \
|
|
41 -DORTHANC_ENABLE_SSL=1 \
|
|
42 -DORTHANC_ENABLE_ZLIB=1 \
|
|
43 -DORTHANC_SANDBOXED=0 \
|
|
44 -DORTHANC_SQLITE_VERSION=3027001 \
|
|
45 -DORTHANC_UNIT_TESTS_LINK_FRAMEWORK=1 \
|
|
46 -DPUGIXML_VERSION=150 \
|
|
47 -DUNIT_TESTS_WITH_HTTP_CONNEXIONS=1 \
|
|
48 -D__BYTE_ORDER=__LITTLE_ENDIAN \
|
|
49 -D__GNUC__ \
|
|
50 -D__cplusplus=201103 \
|
|
51 -D__linux__ \
|
|
52 -UNDEBUG \
|
|
53 \
|
|
54 ../../OrthancFramework/Sources \
|
|
55 ../../OrthancFramework/UnitTestsSources \
|
|
56 ../../OrthancServer/Plugins/Engine \
|
|
57 ../../OrthancServer/Plugins/Include \
|
|
58 ../../OrthancServer/Sources \
|
|
59 ../../OrthancServer/UnitTestsSources \
|
|
60 \
|
|
61 2>&1 | grep -vE '\[unusedFunction\]$|^\^$|^$|function .* is never used'
|