]> git.proxmox.com Git - efi-boot-shim.git/blob - Make.coverity
Improve how the dbx hashes are handled
[efi-boot-shim.git] / Make.coverity
1 COV_EMAIL=$(call get-config,coverity.email)
2 COV_TOKEN=$(call get-config,coverity.token)
3 COV_URL=$(call get-config,coverity.url)
4 COV_FILE=$(NAME)-coverity-$(VERSION)-$(COMMIT_ID).tar.bz2
5
6 cov-int : clean-shim-objs
7 make $(DASHJ) Cryptlib/OpenSSL/libopenssl.a Cryptlib/libcryptlib.a
8 cov-build --dir cov-int make $(DASHJ) all
9
10 cov-int-all : clean
11 cov-build --dir cov-int make $(DASHJ) all
12
13 cov-clean :
14 @rm -vf $(NAME)-coverity-*.tar.*
15 @if [[ -d cov-int ]]; then rm -rf cov-int && echo "removed 'cov-int'"; fi
16
17 cov-file : | $(COV_FILE)
18
19 $(COV_FILE) : | cov-int
20 tar caf $@ cov-int
21
22 cov-upload :
23 @if [[ -n "$(COV_URL)" ]] && \
24 [[ -n "$(COV_TOKEN)" ]] && \
25 [[ -n "$(COV_EMAIL)" ]] ; \
26 then \
27 echo curl --form token=$(COV_TOKEN) --form email="$(COV_EMAIL)" --form file=@"$(COV_FILE)" --form version=$(VERSION).1 --form description="$(COMMIT_ID)" "$(COV_URL)" ; \
28 curl --form token=$(COV_TOKEN) --form email="$(COV_EMAIL)" --form file=@"$(COV_FILE)" --form version=$(VERSION).1 --form description="$(COMMIT_ID)" "$(COV_URL)" ; \
29 else \
30 echo Coverity output is in $(COV_FILE) ; \
31 fi
32
33 coverity : | cov-test
34 coverity : cov-int cov-file cov-upload
35
36 coverity-all : | cov-test
37 coverity-all : cov-int-all cov-file cov-upload
38
39 clean : | cov-clean
40
41 COV_BUILD ?= $(shell x=$$(which --skip-alias --skip-functions cov-build 2>/dev/null) ; [ -n "$$x" ] && echo "$$x")
42
43 cov-test : ; $(if $(findstring /,$(COV_BUILD)),,$(error cov-build not found))
44
45 .PHONY : coverity cov-upload cov-clean cov-file cov-test