--- udev-089-r2.ebuild.orig 2006-04-04 22:21:05.000000000 +0200 +++ udev-089-r2.ebuild 2006-04-06 11:29:13.000000000 +0200 @@ -155,23 +155,6 @@ newdoc extras/volume_id/README README_volume_id - # Create some nodes that we know we need. - # set the time/date so we can see in /dev which ones we copied over - # in the udev-start.sh script - mkdir ${D}/lib/udev/devices - - mknod ${D}/lib/udev/devices/null c 1 3 - chmod 666 ${D}/lib/udev/devices/null - touch -t 200010220101 ${D}/lib/udev/devices/null - - mknod ${D}/lib/udev/devices/zero c 1 5 - chmod 666 ${D}/lib/udev/devices/zero - touch -t 200010220101 ${D}/lib/udev/devices/zero - - mknod ${D}/lib/udev/devices/console c 5 1 - chmod 600 ${D}/lib/udev/devices/console - chown root:tty ${D}/lib/udev/devices/console - touch -t 200010220101 ${D}/lib/udev/devices/console } pkg_preinst() { @@ -192,6 +175,38 @@ then rm -f ${ROOT}/etc/hotplug.d/default/05-wait_for_sysfs.hotplug fi + + # is there a stale coldplug initscript? (CONFIG_PROTECT leaves it behind) + coldplug_stale="" + if [ -f "${ROOT}/etc/init.d/coldplug" ] + then + coldplug_stale="1" + fi + + # Create some nodes that we know we need. + # set the time/date so we can see in /dev which ones we copied over + # in the udev-start.sh script + mkdir -p ${ROOT}/lib/udev/devices + + if [ ! -e ${ROOT}/lib/udev/devices/null ] ; then + mknod ${ROOT}/lib/udev/devices/null c 1 3 + fi + chmod 666 ${ROOT}/lib/udev/devices/null + touch -t 200010220101 ${ROOT}/lib/udev/devices/null + + if [ ! -e ${ROOT}/lib/udev/devices/zero ] ; then + mknod ${ROOT}/lib/udev/devices/zero c 1 5 + fi + chmod 666 ${ROOT}/lib/udev/devices/zero + touch -t 200010220101 ${ROOT}/lib/udev/devices/zero + + if [ ! -e ${ROOT}/lib/udev/devices/console ] ; then + mknod ${ROOT}/lib/udev/devices/console c 5 1 + fi + chmod 600 ${ROOT}/lib/udev/devices/console + chown root:tty ${ROOT}/lib/udev/devices/console + touch -t 200010220101 ${ROOT}/lib/udev/devices/console + } pkg_postinst() { @@ -244,6 +259,15 @@ ewarn fi + if [[ ${coldplug_stale} == "1" ]] ; then + ewarn "A stale coldplug init script found. You should run:" + ewarn + ewarn " rc-update del coldplug" + ewarn " rm -f /etc/init.d/coldplug" + ewarn + ewarn "udev now provides its own coldplug functionality." + fi + einfo einfo "For more information on udev on Gentoo, writing udev rules, and" einfo " fixing known issues visit:"