utils: split linting with PYFLAKES into a separate target.

This a step towards addressing the linting of the utils causing
problems in a build vs dev environment. See
  https://gitlab.com/apparmor/apparmor/-/issues/121

Split off linting with PYFLAKES into its own target as a step towards
making the running of the lint checks as a configuration option.

https://gitlab.com/apparmor/apparmor/-/merge_requests/662
Signed-off-by: John Johansen <john.johansen@canonical.com>
Acked-by: Christian Boltz <apparmor@cboltz.de>
This commit is contained in:
John Johansen 2020-10-20 21:38:02 -07:00
parent 38c611ed31
commit 43eb54d13c

View file

@ -87,12 +87,17 @@ check_severity_db: /usr/include/linux/capability.h severity.db
test "$$RC" -eq 0
# check_pod_files is defined in common/Make.rules
.PHONY: check
.SILENT: check
check: check_severity_db check_pod_files
.PHONY: check_lint
.SILENT: check_lint
check_lint:
for i in ${PYTOOLS} apparmor test/*.py; do \
echo Checking $$i; \
$(PYFLAKES) $$i || exit 1; \
done
# check_pod_files is defined in common/Make.rules
.PHONY: check
.SILENT: check
check: check_severity_db check_pod_files check_lint
$(MAKE) -C test check
$(MAKE) -C vim check