Skip to content
Snippets Groups Projects
Commit 234c4037 authored by Florian Schmaus's avatar Florian Schmaus
Browse files

Merge branch 'static-analysis-with-emper-io' into 'master'

[Makefile][CI] Add static-analysis Make target, and gitlab-ci stage

See merge request !81
parents a4b8af46 69eff936
No related branches found
No related tags found
1 merge request!81[Makefile][CI] Add static-analysis Make target, and gitlab-ci stage
Pipeline #57321 passed
......@@ -21,6 +21,13 @@ before_script:
$tool --version
done
variables:
BUILDDTYPE: debugoptmized
CC: gcc
CXX: g++
EXTRA_NINJA_ARGS: -v
EMPER_IO: "false"
stages:
- smoke-test
- test
......@@ -29,12 +36,11 @@ smoke-test:
stage: smoke-test
script: make smoke-test
variables:
BUILDDTYPE: debugoptmized
CC: gcc
CXX: g++
EXTRA_NINJA_ARGS: -v
EMPER_IO: "false"
static-analysis-with-emper-io:
stage: smoke-test
script: make static-analysis
variables:
EMPER_IO: "true"
.test:
stage: test
......
......@@ -30,21 +30,22 @@ debug:
rm -f build
$(MAKE) build BUILDTYPE=$@
SMOKE_TEST_NINJA_TARGETS += iwyu
STATIC_ANALYSIS_NINJA_TARGETS += iwyu
# Meson >= 0.52 will automatically generate a clang-tidy target if a
# .clang-tidy file is found.
# Source version check: https://stackoverflow.com/a/3732456/194894
ifeq ($(shell [ $(MESON_MINOR_VERSION) -ge 52 ] && echo true), true)
SMOKE_TEST_NINJA_TARGETS += clang-tidy
STATIC_ANALYSIS_NINJA_TARGETS += clang-tidy
else
$(warning old mesion version $(MESON_VERSION) detected, meson >= 0.52 required for clang-tidy)
endif
smoke-test: all check-format check-license doc
cd build && meson test --suite smoke
$(NINJA) -C build $(SMOKE_TEST_NINJA_TARGETS)
static-analysis: all
$(NINJA) -C build $(STATIC_ANALYSIS_NINJA_TARGETS)
smoke-test: all check-format check-license doc static-analysis
cd build && meson test --suite smoke
TEST_NINJA_TARGETS += test
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment