Commit 3d6dee7a authored by Bamvor Jian Zhang's avatar Bamvor Jian Zhang Committed by Shuah Khan

Makefile: add kselftest-merge

Add kselftest-merge to enable the dependencies of kernel config
for all the kselftest testcases. User should call it after create
the kernel configuration(.config), eg:

$ make kselftest-merge
Signed-off-by: default avatarBamvor Jian Zhang <>
Signed-off-by: default avatarShuah Khan <>
parent 8c749ce9
......@@ -1087,6 +1087,14 @@ kselftest:
$(Q)$(MAKE) -C tools/testing/selftests clean
PHONY += kselftest-merge
$(if $(wildcard $(objtree)/.config),, $(error No .config exists, config your kernel first!))
$(Q)$(CONFIG_SHELL) $(srctree)/scripts/kconfig/ \
-m $(objtree)/.config \
+$(Q)$(MAKE) -f $(srctree)/Makefile olddefconfig
# ---------------------------------------------------------------------------
# Modules
......@@ -1295,6 +1303,8 @@ help:
@echo ' Build, install, and boot kernel before'
@echo ' running kselftest on it'
@echo ' kselftest-clean - Remove all generated kselftest files'
@echo ' kselftest-merge - Merge all the config dependencies of kselftest to existed'
@echo ' .config.'
@echo ''
@echo 'Kernel packaging:'
@$(MAKE) $(build)=$(package-dir) help
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment