mirror of
https://gitlab.com/apparmor/apparmor.git
synced 2025-03-04 16:35:02 +01:00
profiles/Makefile: local target does not depend on parser
The "local" make target does not depend on the parser having been
built. Create a separate "test-dependencies" target and have the tests
that need them depend on that and the "local" target, when validating
the profile set against the apparmor tools.
Fixes: c8b6d8b393
Bug: https://gitlab.com/apparmor/apparmor/-/issues/98
Signed-off-by: Steve Beattie <steve.beattie@canonical.com>
Acked-by: John Johansen <john.johansen@canonical.com>
MR: https://gitlab.com/apparmor/apparmor/-/merge_requests/586
This commit is contained in:
parent
6016f931eb
commit
88517e9768
1 changed files with 5 additions and 3 deletions
|
@ -52,6 +52,8 @@ endif
|
|||
# $(PWD) is wrong when using "make -C profiles" - explicitely set it here to get the right value
|
||||
PWD=$(shell pwd)
|
||||
|
||||
.PHONY: test-dependencies
|
||||
test-dependencies: __parser
|
||||
|
||||
.PHONY: __parser
|
||||
__parser:
|
||||
|
@ -64,7 +66,7 @@ ifndef USE_SYSTEM
|
|||
fi
|
||||
endif
|
||||
|
||||
local: __parser
|
||||
local:
|
||||
for profile in ${TOPLEVEL_PROFILES}; do \
|
||||
fn=$$(basename $$profile); \
|
||||
echo "# Site-specific additions and overrides for '$$fn'" > ${PROFILES_SOURCE}/local/$$fn; \
|
||||
|
@ -108,7 +110,7 @@ CHECK_ABSTRACTIONS=$(shell find ${ABSTRACTIONS_SOURCE} -type f -print)
|
|||
check: check-parser check-logprof
|
||||
|
||||
.PHONY: check-parser
|
||||
check-parser: local
|
||||
check-parser: test-dependencies local
|
||||
@echo "*** Checking profiles from ${PROFILES_SOURCE} and ${EXTRAS_SOURCE} against apparmor_parser"
|
||||
$(Q)for profile in ${CHECK_PROFILES} ; do \
|
||||
[ -n "${VERBOSE}" ] && echo "Testing $${profile}" ; \
|
||||
|
@ -124,6 +126,6 @@ check-parser: local
|
|||
done
|
||||
|
||||
.PHONY: check-logprof
|
||||
check-logprof: local
|
||||
check-logprof: test-dependencies local
|
||||
@echo "*** Checking profiles from ${PROFILES_SOURCE} against logprof"
|
||||
$(Q)${LOGPROF} -d ${PROFILES_SOURCE} -f /dev/null || exit 1
|
||||
|
|
Loading…
Add table
Reference in a new issue