makefile: add rule to run implements tool

Right now the tool doesn't do much checking but it does check what is
implemented, so we call the rule 'check-implements'. All current
sub-packages are checked. Use IMPLEMENTS_OPTS to pass additional cli
options to the tool.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
This commit is contained in:
John Mulligan 2020-05-06 11:20:09 -04:00 committed by John Mulligan
parent 2d188de3f3
commit b450208827
1 changed files with 5 additions and 1 deletions

View File

@ -6,6 +6,7 @@ VOLUME_FLAGS :=
CEPH_VERSION := nautilus
RESULTS_DIR :=
CHECK_GOFMT_FLAGS := -e -s -l
IMPLEMENTS_OPTS :=
SELINUX := $(shell getenforce 2>/dev/null)
ifeq ($(SELINUX),Enforcing)
@ -74,6 +75,9 @@ test-bins: test-binaries
implements:
go build -o implements ./contrib/implements
check-implements: implements
./implements $(IMPLEMENTS_OPTS) ./cephfs ./rados ./rbd
# force_go_build is phony and builds nothing, can be used for forcing
# go toolchain commands to always run
.PHONY: build fmt test test-docker check test-binaries test-bins force_go_build
.PHONY: build fmt test test-docker check test-binaries test-bins force_go_build check-implements