lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <c1142457987895ebc2e3f378c7b30494f45ca48e.1687706332.git.falcon@tinylab.org>
Date:   Mon, 26 Jun 2023 00:41:23 +0800
From:   Zhangjin Wu <falcon@...ylab.org>
To:     thomas@...ch.de, w@....eu
Cc:     falcon@...ylab.org, arnd@...db.de, linux-kernel@...r.kernel.org,
        linux-kselftest@...r.kernel.org
Subject: [PATCH v1 20/22] selftests/nolibc: add run-tiny and run-default

These two targets allow to do config and run together.

- run-tiny: do tinyconfig, extconfig and then run.
- run-default: do defconfig, extconfig and then run.

Signed-off-by: Zhangjin Wu <falcon@...ylab.org>
---
 tools/testing/selftests/nolibc/Makefile | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selftests/nolibc/Makefile
index a847a2264fed..3e7e51bd7082 100644
--- a/tools/testing/selftests/nolibc/Makefile
+++ b/tools/testing/selftests/nolibc/Makefile
@@ -156,6 +156,14 @@ REPORT  ?= awk '/\[OK\][\r]*$$/{p++} /\[FAIL\][\r]*$$/{f++;print} /\[SKIPPED\][\
 		END{ printf("%d test(s) passed, %d skipped, %d failed.\n", p, s, f); \
 		printf("See all results in %s\n", ARGV[1]); }'
 
+# allow run with a config target together: run-tiny = tinyconfig + run; run-default = defconfig + run
+ifeq (run-tiny, $(MAKECMDGOALS))
+AUTOCONFIG ?= tinyconfig
+endif
+ifeq (run-default, $(MAKECMDGOALS))
+AUTOCONFIG ?= defconfig
+endif
+
 # allow switch nolibc headers include method: 1 for sysroot, 0 for nolibc.h
 SYSROOT ?= 1
 
@@ -228,7 +236,7 @@ tinyconfig:
 menuconfig:
 	$(Q)$(MAKE) -C $(srctree) ARCH=$(KARCH) CC=$(CC) CROSS_COMPILE=$(CROSS_COMPILE) menuconfig
 
-extconfig:
+extconfig: $(AUTOCONFIG)
 	$(Q)$(srctree)/scripts/config --file $(srctree)/.config $(EXTCONFIG)
 	$(Q)$(MAKE) -C $(srctree) ARCH=$(KARCH) CC=$(CC) CROSS_COMPILE=$(CROSS_COMPILE) KCONFIG_ALLCONFIG=$(srctree)/.config allnoconfig
 
@@ -240,6 +248,8 @@ run: kernel
 	$(Q)qemu-system-$(QEMU_ARCH) -display none -no-reboot -kernel "$(srctree)/$(IMAGE)" -serial stdio $(QEMU_ARGS) $(LOG_OUTPUT)
 	$(Q)$(REPORT) $(CURDIR)/run.out
 
+run-tiny run-default: run
+
 # re-run the tests from an existing kernel
 rerun:
 	$(Q)qemu-system-$(QEMU_ARCH) -display none -no-reboot -kernel "$(srctree)/$(IMAGE)" -serial stdio $(QEMU_ARGS) $(LOG_OUTPUT)
-- 
2.25.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ