diff options
author | Thomas Weißschuh <linux@weissschuh.net> | 2025-01-23 08:37:41 +0100 |
---|---|---|
committer | Thomas Weißschuh <linux@weissschuh.net> | 2025-02-03 21:02:16 +0100 |
commit | c1f4a7a84037249d086a4114c0c4332a260e9091 (patch) | |
tree | 920219a33f975765f11330a4bcb081da18ed0201 | |
parent | d7d271ec30dd02bb9c695233e7fc04a6c728f467 (diff) |
selftests/nolibc: always keep test kernel configuration up to date
Avoid using a stale test kernel configuration by always synchronizing
it to the current source tree.
kbuild is smart enough to avoid spurious rebuilds.
Shuffle the code around a bit to keep all the commands with side-effects
together.
Acked-by: Willy Tarreau <w@1wt.eu>
Link: https://lore.kernel.org/r/20250123-nolibc-config-v2-5-5701c35995d6@weissschuh.net
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
-rwxr-xr-x | tools/testing/selftests/nolibc/run-tests.sh | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/testing/selftests/nolibc/run-tests.sh b/tools/testing/selftests/nolibc/run-tests.sh index 9c5160c53881..bc4e92b4f1b9 100755 --- a/tools/testing/selftests/nolibc/run-tests.sh +++ b/tools/testing/selftests/nolibc/run-tests.sh @@ -157,10 +157,6 @@ test_arch() { fi MAKE=(make -j"${nproc}" XARCH="${arch}" CROSS_COMPILE="${cross_compile}" LLVM="${llvm}" O="${build_dir}") - mkdir -p "$build_dir" - if [ "$test_mode" = "system" ] && [ ! -f "${build_dir}/.config" ]; then - swallow_output "${MAKE[@]}" defconfig - fi case "$test_mode" in 'system') test_target=run @@ -173,6 +169,9 @@ test_arch() { exit 1 esac printf '%-15s' "$arch:" + + mkdir -p "$build_dir" + swallow_output "${MAKE[@]}" defconfig swallow_output "${MAKE[@]}" CFLAGS_EXTRA="$CFLAGS_EXTRA" "$test_target" V=1 cp run.out run.out."${arch}" "${MAKE[@]}" report | grep passed |