Fix for bug 83276 and add udevsend binary to initramfs for newer udevs

git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/genkernel/trunk@310 67a159dc-881f-0410-a524-ba9dfbe2cb84
cleanup-cruft
Eric Edgar 20 years ago
parent 4adea0cde7
commit 3e065b5f52

@ -729,6 +729,11 @@ compile_udev() {
then then
strip udevstart || gen_die 'Failed to strip the udevstart binary!' strip udevstart || gen_die 'Failed to strip the udevstart binary!'
fi fi
if [ -e udevsend ]
then
strip udevsend || gen_die 'Failed to strip the udevsend binary!'
fi
print_info 1 ' >> Installing...' print_info 1 ' >> Installing...'
install -d "${TEMP}/udev/etc/udev" "${TEMP}/udev/sbin" "${TEMP}/udev/etc/udev/scripts" "${TEMP}/udev/etc/udev/rules.d" "${TEMP}/udev/etc/udev/permissions.d" || install -d "${TEMP}/udev/etc/udev" "${TEMP}/udev/sbin" "${TEMP}/udev/etc/udev/scripts" "${TEMP}/udev/etc/udev/rules.d" "${TEMP}/udev/etc/udev/permissions.d" ||
@ -741,6 +746,12 @@ compile_udev() {
install -m 0755 udevstart "${TEMP}/udev/sbin" || install -m 0755 udevstart "${TEMP}/udev/sbin" ||
gen_die 'Could not install udevstart binary!' gen_die 'Could not install udevstart binary!'
fi fi
if [ -e udevsend ]
then
install -m 0755 udevsend "${TEMP}/udev/sbin" ||
gen_die 'Could not install udevsend binary!'
fi
install -m 0644 etc/udev/udev.conf "${TEMP}/udev/etc/udev" || install -m 0644 etc/udev/udev.conf "${TEMP}/udev/etc/udev" ||
gen_die 'Could not install udev configuration!' gen_die 'Could not install udev configuration!'

@ -100,7 +100,16 @@ create_base_initrd_sys() {
if [ "${UDEV}" -eq '1' ] if [ "${UDEV}" -eq '1' ]
then then
/bin/tar -jxpf "${UDEV_BINCACHE}" -C "${TEMP}/initrd-temp" || gen_die 'Could not extract udev binary cache!' /bin/tar -jxpf "${UDEV_BINCACHE}" -C "${TEMP}/initrd-temp" || gen_die 'Could not extract udev binary cache!'
ln -sf "./udev" "${TEMP}/initrd-temp/bin/udevstart" || gen_die 'Could not symlink udev -> udevstart!' if [ ! -e "${TEMP}/initrd-temp/bin/udevstart" ]
then
ln -sf "./udev" "${TEMP}/initrd-temp/bin/udevstart" || gen_die 'Could not symlink udev -> udevstart!'
fi
if [ ! -e "${TEMP}/initrd-temp/bin/udevsend" ]
then
ln -sf "./udev" "${TEMP}/initrd-temp/bin/udevsend" || gen_die 'Could not symlink udev -> udevsend!'
fi
fi fi
#unionfs modules #unionfs modules

@ -210,6 +210,7 @@ runUdev() {
mount -t tmpfs -o size=100k udev /dev mount -t tmpfs -o size=100k udev /dev
mkdir /dev/pts mkdir /dev/pts
mkdir /dev/shm mkdir /dev/shm
echo /sbin/udevsend > /proc/sys/kernel/hotplug
/sbin/udevstart /sbin/udevstart
ln -snf /proc/self/fd /dev/fd ln -snf /proc/self/fd /dev/fd
ln -snf /proc/self/fd/0 /dev/stdin ln -snf /proc/self/fd/0 /dev/stdin

@ -38,6 +38,12 @@ then
then then
ln -s /sbin/udev /sbin/udevstart ln -s /sbin/udev /sbin/udevstart
fi fi
if [ ! -e /sbin/udevsend ]
then
ln -s /sbin/udev /sbin/udevsend
fi
fi fi
if [ -e /bin/lvm ] if [ -e /bin/lvm ]

Loading…
Cancel
Save