From: Frantisek Sumsal Date: Sun, 8 Aug 2021 11:18:18 +0000 (+0200) Subject: test: attempt to install only kernel modules for each subsystem X-Git-Tag: v250-rc1~870 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=84817bfdb39cf7bf27992ac8f10fc7937b00664d;p=thirdparty%2Fsystemd.git test: attempt to install only kernel modules for each subsystem When `linux-headers` is installed on Arch Linux, it stores the module source tree in the kernel module directory, which is then picked up by `find` and we get a lot of harmless but annoying errors: ``` ... modprobe: FATAL: Module Kconfig.iosched not found in directory /lib/modules/5.13.7-arch1-1 modprobe: FATAL: Module Kconfig not found in directory /lib/modules/5.13.7-arch1-1 modprobe: FATAL: Module Kconfig not found in directory /lib/modules/5.13.7-arch1-1 modprobe: FATAL: Module dm-mpath.h not found in directory /lib/modules/5.13.7-arch1-1 modprobe: FATAL: Module dm-bio-prison-v2.h not found in directory /lib/modules/5.13.7-arch1-1 modprobe: FATAL: Module raid0.h not found in directory /lib/modules/5.13.7-arch1-1 ... ``` Let's fix this by trying to install only kernel modules (*.ko files with an optional compression). --- diff --git a/test/test-functions b/test/test-functions index 410b1699bf6..c049d4b64a5 100644 --- a/test/test-functions +++ b/test/test-functions @@ -2343,7 +2343,7 @@ instmods() { else ( [[ "$mpargs" ]] && echo "$mpargs" - find "$mod_dir" -path "*/${mod#=}/*" -type f -printf '%f\n' + find "$mod_dir" -path "*/${mod#=}/*" -name "*.ko*" -type f -printf '%f\n' ) | instmods fi ;;