c-kernel: avoid unnecessary rebuilds due to `__pycache__` directories
Previously, we would rebuild the kernel if any file in the `seL4` repository changed since previous `cmake` setup. Since the kernel build after the `cmake` setup generates `__pycache__` directories in the `seL4` tree, this would cause some unnecessary rebuilds. This commit explicitly excludes `__pycache__` directories from the set of files considered to be dependencies of the kernel build. Signed-off-by: Matthew Brecknell <Matthew.Brecknell@data61.csiro.au>
This commit is contained in:
parent
18c9f361ab
commit
d8364c952d
|
@ -66,7 +66,11 @@ ifndef ISABELLE_PROCESS
|
|||
export ISABELLE_PROCESS:=${ISABELLE_HOME}/bin/isabelle-process
|
||||
endif
|
||||
|
||||
KERNEL_DEPS := $(shell find ${SOURCE_ROOT} -type f)
|
||||
# __pycache__ directories are the only in-tree products of the kernel build.
|
||||
# But since they are generated after the cmake setup, they would cause unnecessary
|
||||
# kernel rebuilds if we treated them as dependencies of the kernel build.
|
||||
# We avoid this by excluding __pycache__ directories from the kernel dependencies.
|
||||
KERNEL_DEPS := $(shell find ${SOURCE_ROOT} -name __pycache__ -prune -o -type f -print)
|
||||
|
||||
# Top level rule for rebuilding kernel_all.c_pp
|
||||
${KERNEL_BUILD_ROOT}/kernel_all.c_pp: ${KERNEL_BUILD_ROOT}/.cmake_done
|
||||
|
|
Loading…
Reference in New Issue