File: Make.scan-build

package info (click to toggle)
efivar 37-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 1,320 kB
  • sloc: ansic: 10,423; makefile: 229; asm: 31
file content (21 lines) | stat: -rw-r--r-- 591 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
SCAN_BUILD ?= $(shell x=$$(which --skip-alias --skip-functions scan-build 2>/dev/null) ; [ -n "$$x" ] && echo 1)
ifeq ($(SCAN_BUILD),)
	SCAN_BUILD_ERROR = $(error scan-build not found)
endif

scan-test : ; $(SCAN_BUILD_ERROR)

scan-clean : clean
	@if [[ -d scan-results ]]; then rm -rf scan-results && echo "removed 'scan-results'"; fi

scan-build : | scan-test
scan-build : clean
	scan-build -o scan-results make $(DASHJ) CC=clang all

scan-build-all : | scan-test
scan-build-all : clean
	scan-build -o scan-results make $(DASHJ) CC=clang all

.PHONY : scan-build scan-clean

# vim:ft=make