Message ID | a7fcca12e0f567efd29314172ccf1ad4cd279bf7.1689759351.git.falcon@tinylab.org |
---|---|
State | New |
Headers | show |
Series | selftests/nolibc: add minimal kernel config support - part1 | expand |
On Wed, Jul 19, 2023 at 09:22:37PM +0800, Zhangjin Wu wrote: > The default DEFCONFIG_<ARCH> may not always work for all architectures, > let's allow users to tune some kernel config options with 'menuconfig'. > > This is important when porting nolibc to a new architecture, it also > allows to speed up nolibc 'run' target testing via manually disabling > tons of unnecessary kernel config options. > > Signed-off-by: Zhangjin Wu <falcon@tinylab.org> > --- > tools/testing/selftests/nolibc/Makefile | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selftests/nolibc/Makefile > index 058e7be070ea..06954b4b3885 100644 > --- a/tools/testing/selftests/nolibc/Makefile > +++ b/tools/testing/selftests/nolibc/Makefile > @@ -202,6 +202,9 @@ KERNEL_IMAGE = $(objtree)/$(IMAGE) > defconfig: > $(Q)$(MAKE_KERNEL) mrproper $(DEFCONFIG) prepare > > +menuconfig: > + $(Q)$(MAKE_KERNEL) menuconfig What is the real benefit of this compared to just running the standard "make menuconfig" ? We should avoid adding makefile targets that do not bring value on top of that the top-level makefile does, because it will make the useful ones much harder to spot, and will tend to encourage users to use only that makefile during the tests, which is a bad practice since many targets will always be missing or work differently. It's important in my opinion that we strictly stick to what is useful to operate the tests themselves and this one doesn't make me feel like it qualifies as such. Willy
diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selftests/nolibc/Makefile index 058e7be070ea..06954b4b3885 100644 --- a/tools/testing/selftests/nolibc/Makefile +++ b/tools/testing/selftests/nolibc/Makefile @@ -202,6 +202,9 @@ KERNEL_IMAGE = $(objtree)/$(IMAGE) defconfig: $(Q)$(MAKE_KERNEL) mrproper $(DEFCONFIG) prepare +menuconfig: + $(Q)$(MAKE_KERNEL) menuconfig + extconfig: $(Q)$(srctree)/scripts/kconfig/merge_config.sh -O "$(objtree)" -m "$(KERNEL_CONFIG)" $(foreach c,$(EXTCONFIG),$(wildcard $(CURDIR)/configs/$c)) $(Q)$(MAKE_KERNEL) KCONFIG_ALLCONFIG="$(KERNEL_CONFIG)" allnoconfig
The default DEFCONFIG_<ARCH> may not always work for all architectures, let's allow users to tune some kernel config options with 'menuconfig'. This is important when porting nolibc to a new architecture, it also allows to speed up nolibc 'run' target testing via manually disabling tons of unnecessary kernel config options. Signed-off-by: Zhangjin Wu <falcon@tinylab.org> --- tools/testing/selftests/nolibc/Makefile | 3 +++ 1 file changed, 3 insertions(+)