summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README3
-rw-r--r--man/lsinitcpio.1.txt2
-rw-r--r--man/mkinitcpio.8.txt7
-rw-r--r--man/mkinitcpio.conf.5.txt2
-rwxr-xr-xmkinitcpio12
5 files changed, 21 insertions, 5 deletions
diff --git a/README b/README
index 7e549e0..701027b 100644
--- a/README
+++ b/README
@@ -1,7 +1,8 @@
The corresponding files are licensed under the GNU General Public License, version 2
as per the included LICENSE file.
- Copyright (C) 2006-2013, Thomas Bächler <thomas@archlinux.org>
+ Copyright (C) 2006-2019, Thomas Bächler <thomas@archlinux.org>
Aaron Griffin <aaronmgriffin@gmail.com>
Tobias Powalowski <tpowa@archlinux.org>
Dave Reisner <dreisner@archlinux.org>
+ Giancarlo Razzolini <grazzolini@archlinux.org>
diff --git a/man/lsinitcpio.1.txt b/man/lsinitcpio.1.txt
index 98bd756..4f25da0 100644
--- a/man/lsinitcpio.1.txt
+++ b/man/lsinitcpio.1.txt
@@ -65,4 +65,4 @@ lsinitcpio was created by Dave Reisner <dreisner@archlinux.org>
Copyright
---------
-Copyright (c) Arch Linux 2011-2012
+Copyright (c) Arch Linux 2011-2019
diff --git a/man/mkinitcpio.8.txt b/man/mkinitcpio.8.txt
index 6a9b59e..a69cf20 100644
--- a/man/mkinitcpio.8.txt
+++ b/man/mkinitcpio.8.txt
@@ -36,11 +36,14 @@ Options
Set 'directory' as the location where the initramfs is built. This might be
useful to generate a shutdown ramfs in '/run/initramfs'.
+*-D, \--hookdir* 'directory'::
+ Set 'directory' as the location where hooks will be searched for when
+ generating the image.
+
*-g, \--generate* 'filename'::
Generate a CPIO image as 'filename'. Default: no; this means nothing will be
written to the filesystem unless this option is specified.
-
*-H, \--hookhelp* 'hookname'::
Output help for hookname 'hookname'.
@@ -364,4 +367,4 @@ mkinitcpio is created and maintained by the Arch Linux Developer community.
Copyright
---------
-Copyright (c) Arch Linux 2006-2012
+Copyright (c) Arch Linux 2006-2019
diff --git a/man/mkinitcpio.conf.5.txt b/man/mkinitcpio.conf.5.txt
index d272852..9c8d000 100644
--- a/man/mkinitcpio.conf.5.txt
+++ b/man/mkinitcpio.conf.5.txt
@@ -79,4 +79,4 @@ mkinitcpio is created and maintained by the Arch Linux Developer community.
Copyright
---------
-Copyright (c) Arch Linux 2006-2012
+Copyright (c) Arch Linux 2006-2019
diff --git a/mkinitcpio b/mkinitcpio
index ed808f0..06c5673 100755
--- a/mkinitcpio
+++ b/mkinitcpio
@@ -14,6 +14,7 @@ _f_functions=functions
_f_config=mkinitcpio.conf
_d_hooks="$PWD/hooks:/usr/lib/initcpio/hooks:/lib/initcpio/hooks"
_d_install="$PWD/install:/usr/lib/initcpio/install:/lib/initcpio/install"
+_d_flag_{hooks,install}=
_d_firmware=({/usr,}/lib/firmware/updates {/usr,}/lib/firmware)
_d_presets=mkinitcpio.d
@@ -56,6 +57,7 @@ usage: ${0##*/} [options]
-s, --save Save build directory. (default: no)
-d, --generatedir <dir> Write generated image into <dir>
-t, --builddir <dir> Use DIR as the temporary build directory
+ -D, --hookdir <dir> Specify where to look for hooks.
-V, --version Display version information and exit
-v, --verbose Verbose output (default: no)
-z, --compress <program> Use an alternate compressor on the image
@@ -406,6 +408,11 @@ while :; do
shift
_optmoduleroot=$1
;;
+ -D|--hookdir)
+ shift
+ _d_flag_hooks+="$1/hooks:"
+ _d_flag_install+="$1/install:"
+ ;;
--)
shift
break 2
@@ -418,6 +425,11 @@ if [[ -t 1 ]] && (( _optcolor )); then
try_enable_color
fi
+if [[ -n $_d_flag_hooks && -n $_d_flag_install ]]; then
+ _d_hooks=${_d_flag_hooks%:}
+ _d_install=${_d_flag_install%:}
+fi
+
# insist that /proc and /dev be mounted (important for chroots)
# NOTE: avoid using mountpoint for this -- look for the paths that we actually
# use in mkinitcpio. Avoids issues like FS#26344.