summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/buildtests.sh12
1 files changed, 9 insertions, 3 deletions
diff --git a/scripts/buildtests.sh b/scripts/buildtests.sh
index f6690a6d..0338dbe0 100755
--- a/scripts/buildtests.sh
+++ b/scripts/buildtests.sh
@@ -85,7 +85,12 @@ CHECK_WARNINGS() {
then
echo "EXITING. $w warnings encountered"
echo
- cat $1 | grep "$2" | grep -v "$3" | sort | uniq
+ if ( test -z "$3")
+ then
+ cat $1 | grep "$2" | grep -v "$3" | sort | uniq
+ else
+ cat $1 | grep "$2" | sort | uniq
+ fi
exit 1
fi
}
@@ -109,7 +114,8 @@ CPPCHECK_WARNINGS() {
# print warnings find in the clang-tidy output
# $1 = file with the clang-tidy output
TIDY_WARNINGS() {
- whitelist='\(Value[[:space:]]descriptions\|unused[[:space:]]declarations\|g-ir-scanner:\|clang.*argument[[:space:]]unused[[:space:]]during[[:space:]]compilation\|modernize-\|cppcoreguidelines-pro-type-const-cast\|cppcoreguidelines-pro-type-reinterpret-cast\|cppcoreguidelines-owning-memory\|fuchsia.*\|hicpp-use-auto\|hicpp-no-malloc\|hicpp-use-nullptr\|hicpp-exception-baseclass\|hicpp-vararg\|cppcoreguidelines-pro-type-vararg\|cppcoreguidelines-pro-bounds-pointer-arithmetic\|google-build-using-namespace\|llvm-include-order\|hicpp-use-equals-default\|cppcoreguidelines-no-malloc\|g_type_class_add_private.*is[[:space:]]deprecated\)'
+ #whitelist='\(Value[[:space:]]descriptions\|unused[[:space:]]declarations\|g-ir-scanner:\|clang.*argument[[:space:]]unused[[:space:]]during[[:space:]]compilation\|modernize-\|cppcoreguidelines-pro-type-const-cast\|cppcoreguidelines-pro-type-vararg\|cppcoreguidelines-pro-type-reinterpret-cast\|cppcoreguidelines-owning-memory\|fuchsia.*\|hicpp-use-auto\|hicpp-no-malloc\|hicpp-use-nullptr\|hicpp-exception-baseclass\|hicpp-vararg\|cppcoreguidelines-pro-type-vararg\|cppcoreguidelines-pro-bounds-pointer-arithmetic\|google-build-using-namespace\|llvm-include-order\|hicpp-use-equals-default\|cppcoreguidelines-no-malloc\|g_type_class_add_private.*is[[:space:]]deprecated\)'
+ whitelist='\(no[[:space:]]link[[:space:]]for:\|Value[[:space:]]descriptions\|unused[[:space:]]declarations\|G_ADD_PRIVATE\|g_type_class_add_private.*is[[:space:]]deprecated\|g-ir-scanner:\|clang.*argument[[:space:]]unused[[:space:]]during[[:space:]]compilation\)'
CHECK_WARNINGS $1 "warning:" "$whitelist"
}
@@ -378,7 +384,7 @@ CLANGTIDY() {
echo "===== START CLANG-TIDY: $1 ====="
cd $TOP
SET_CLANG
- CONFIGURE "$1-tidy" "$2 -DCMAKE_CXX_CLANG_TIDY=clang-tidy;-checks=*"
+ CONFIGURE "$1-tidy" "$2 -DCMAKE_CXX_CLANG_TIDY=clang-tidy"
cmake --build . 2>&1 | tee make-tidy.out || exit 1
TIDY_WARNINGS make-tidy.out
CLEAN