summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Antonuk <alan.antonuk@gmail.com>2020-12-23 07:39:14 +0000
committerAlan Antonuk <alan.antonuk@gmail.com>2020-12-24 09:41:41 -0800
commit1ae1b3d2a07b67503538b04f08c9401a00226f22 (patch)
treea39516d12e0e8d575c87873fc08cc2f3590e47f4
parent521a4dbe03f37b4bc1284cf6ad752c5277c8dacd (diff)
downloadrabbitmq-c-1ae1b3d2a07b67503538b04f08c9401a00226f22.tar.gz
ci: add clang static-analyzer gh actions presubmit
-rw-r--r--.github/workflows/ci.yml2
-rwxr-xr-xtravis.sh6
2 files changed, 6 insertions, 2 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 348776e..8912924 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -17,6 +17,8 @@ jobs:
config: asan
- compiler: clang
config: tsan
+ - compiler: clang
+ config: scan-build
steps:
- uses: actions/checkout@v2
diff --git a/travis.sh b/travis.sh
index 6ae5cf0..31b3272 100755
--- a/travis.sh
+++ b/travis.sh
@@ -43,11 +43,13 @@ build_tsan() {
}
build_scan-build() {
+ sudo apt-get install -y clang-tools
mkdir $PWD/_build && cd $PWD/_build
- scan-build-3.9 cmake .. -DCMAKE_BUILD_TYPE=Debug \
+ scan-build cmake .. -DCMAKE_BUILD_TYPE=Debug \
+ -DCMAKE_C_COMPILER=clang \
-DCMAKE_INSTALL_PREFIX=$PWD/../_install \
-DCMAKE_C_FLAGS="-Werror"
- scan-build-3.9 make install
+ scan-build make install
}
if [ "$#" -ne 1 ]; then