# Copyright 1999-2008 Gentoo Foundation; 2008 Chris Gianelloni, Andrew Gaffney
# Distributed under the GPL v2
+ 13 Dec 2008; Andrew Gaffney <agaffney@gentoo.org> gen_initramfs.sh:
+ Create /sbin directory in append_luks for bug #250330
+
13 Dec 2008; Andrew Gaffney <agaffney@gentoo.org> netboot/linuxrc.x:
Disable creation of most standard devices nodes, since we're running mdev
then
rm -r "${TEMP}/initramfs-luks-temp/"
fi
- mkdir -p "${TEMP}/initramfs-luks-temp/lib/luks"
+
+ mkdir -p "${TEMP}/initramfs-luks-temp/lib/luks/"
+ mkdir -p "${TEMP}/initramfs-luks-temp/sbin"
cd "${TEMP}/initramfs-luks-temp"
+
if isTrue ${LUKS}
then
if is_static /bin/cryptsetup
then
print_info 1 "Including LUKS support"
- rm -f ${TEMP}/initramfs-luks-temp/sbin/cryptsetup
cp /bin/cryptsetup ${TEMP}/initramfs-luks-temp/sbin/cryptsetup
chmod +x "${TEMP}/initramfs-luks-temp/sbin/cryptsetup"
elif is_static /sbin/cryptsetup
then
print_info 1 "Including LUKS support"
- rm -f ${TEMP}/initramfs-luks-temp/sbin/cryptsetup
cp /sbin/cryptsetup ${TEMP}/initramfs-luks-temp/sbin/cryptsetup
- chmod +x "${TEMP}/initramfs-luks-temp/sbin/cryptsetup"
-
+ chmod +x "${TEMP}/initramfs-luks-temp/sbin/cryptsetup"
else
print_info 1 "LUKS support requires static cryptsetup at /bin/cryptsetup or /sbin/cryptsetup"
print_info 1 "Not including LUKS support"
fi
fi
+
find . -print | cpio ${CPIO_ARGS} --append -F "${CPIO}" \
|| gen_die "appending cryptsetup to cpio"
+
cd "${TEMP}"
rm -r "${TEMP}/initramfs-luks-temp/"
}