From: Daan De Meyer Date: Fri, 15 Mar 2024 16:13:45 +0000 (+0100) Subject: Fix kernel module glob X-Git-Tag: v23~89 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac5815b8c04497a4feaa19cfb0e2c176b21e1c4e;p=thirdparty%2Fmkosi.git Fix kernel module glob When dkms modules are installed there will be .ko modules in directories other than "kernel" so make sure we only look for modules in the "kernel" directory. --- diff --git a/mkosi/kmod.py b/mkosi/kmod.py index 1c958d3d5..ffbe30249 100644 --- a/mkosi/kmod.py +++ b/mkosi/kmod.py @@ -25,7 +25,7 @@ def filter_kernel_modules( host: bool, ) -> list[Path]: modulesd = root / "usr/lib/modules" / kver - modules = {m for m in modulesd.rglob("*.ko*")} + modules = set((modulesd / "kernel").rglob("*.ko*")) if host: include = [*include, *loaded_modules()]