From 790cf47060e2ba4914062f86a74e44e348fe1493 Mon Sep 17 00:00:00 2001 From: Clayton Craft Date: Fri, 24 Feb 2023 09:01:43 -0800 Subject: [PATCH] cmd/mkinitfs: allow installing modules in the initramfs-extra archive (MR 32) fixes: https://gitlab.com/postmarketOS/postmarketos-mkinitfs/-/issues/20 --- cmd/mkinitfs/main.go | 2 ++ doc/mkinitfs.1.scd | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/cmd/mkinitfs/main.go b/cmd/mkinitfs/main.go index 039cd2f..8988cb4 100644 --- a/cmd/mkinitfs/main.go +++ b/cmd/mkinitfs/main.go @@ -111,6 +111,8 @@ func main() { hookfiles.New("/etc/mkinitfs/files-extra"), hookscripts.New("/usr/share/mkinitfs/hooks-extra"), hookscripts.New("/etc/mkinitfs/hooks-extra"), + modules.New([]string{}, "/usr/share/mkinitfs/modules-extra"), + modules.New([]string{}, "/etc/mkinitfs/modules-extra"), osksdl.New(devinfo.MesaDriver), }); err != nil { log.Println(err) diff --git a/doc/mkinitfs.1.scd b/doc/mkinitfs.1.scd index 5f5bb29..912c1b8 100644 --- a/doc/mkinitfs.1.scd +++ b/doc/mkinitfs.1.scd @@ -97,11 +97,11 @@ create/manage. mkinitfs reads configuration from */usr/share/mkinitfs* first, an under */hooks-extra* for the initramfs-extra. ## /usr/share/mkinitfs/modules, /etc/mkinitfs/modules +## /usr/share/mkinitfs/modules-extra, /etc/mkinitfs/modules-extra Files with the *.modules* extention in these directories are lists of - kernel modules to include in the initramfs. No modules are placed in - the initramfs-extra archive. Individual modules and directories can be - listed in the files here. Globbing is also supported. + kernel modules to include in the initramfs. Individual modules and + directories can be listed in the files here. Globbing is also supported. Modules are installed in the initramfs archive under the same path they exist on the system where mkinitfs is executed.