aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Pipping <sebastian@pipping.org>2012-09-24 00:30:12 +0200
committerSebastian Pipping <sebastian@pipping.org>2012-09-24 00:30:15 +0200
commitc9a61ce2c722eec0a6d511914304186ddefb91fd (patch)
tree9b0fdc68bda9bbc44a61b74e62c2b3e973dac49b
parentdocs: Fix mail body generation hint (diff)
downloadgenkernel-c9a61ce2c722eec0a6d511914304186ddefb91fd.tar.gz
genkernel-c9a61ce2c722eec0a6d511914304186ddefb91fd.tar.bz2
genkernel-c9a61ce2c722eec0a6d511914304186ddefb91fd.zip
Append e2fsck and mke2fs to initramfs
Original patch by Rick Farina
-rw-r--r--ChangeLog3
-rwxr-xr-xgen_initramfs.sh18
2 files changed, 21 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index e7728f53..47a81ea2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,6 +5,9 @@
# Distributed under the GPL v2
# $Id$
+ 23 Sep 2012; Sebastian Pipping <sping@gentoo.org> gen_initramfs.sh:
+ Append e2fsck and mke2fs to initramfs. Original patch by Rick Farina
+
10 Sep 2012; Sebastian Pipping <sping@gentoo.org> genkernel:
Bump version to 3.4.42
diff --git a/gen_initramfs.sh b/gen_initramfs.sh
index ac90830d..ee21d2f9 100755
--- a/gen_initramfs.sh
+++ b/gen_initramfs.sh
@@ -127,6 +127,23 @@ append_busybox() {
rm -rf "${TEMP}/initramfs-busybox-temp" > /dev/null
}
+append_e2fstools(){
+ if [ -d "${TEMP}"/initramfs-e2fsprogs-temp ]
+ then
+ rm -r "${TEMP}"/initramfs-e2fsprogs-temp
+ fi
+
+ cd "${TEMP}" \
+ || gen_die "cd '${TEMP}' failed"
+ mkdir -p initramfs-e2fsprogs-temp
+ copy_binaries "${TEMP}"/initramfs-e2fsprogs-temp/ /sbin/{e2fsck,mke2fs}
+
+ cd "${TEMP}"/initramfs-e2fsprogs-temp \
+ || gen_die "cd '${TEMP}/initramfs-e2fsprogs-temp' failed"
+ find . -print | cpio ${CPIO_ARGS} --append -F "${CPIO}"
+ rm -rf "${TEMP}"/initramfs-e2fsprogs-temp > /dev/null
+}
+
append_blkid(){
if [ -d "${TEMP}/initramfs-blkid-temp" ]
then
@@ -741,6 +758,7 @@ create_initramfs() {
append_data 'base_layout'
append_data 'auxilary' "${BUSYBOX}"
append_data 'busybox' "${BUSYBOX}"
+ append_data 'e2fstools'
append_data 'lvm' "${LVM}"
append_data 'dmraid' "${DMRAID}"
append_data 'iscsi' "${ISCSI}"