[arch-commits] Commit in udev/trunk (udev.install)

Tom Gundersen tomegun at archlinux.org
Mon Sep 12 12:36:41 UTC 2011


    Date: Monday, September 12, 2011 @ 08:36:41
  Author: tomegun
Revision: 137915

install: remove post-install

Here's to the world's shortest grace-period!

This commit removes the creation of /dev/{console,null,zero} as it is not needed
in our standard install, is unlikely to work where it is needed, is easy to add manually
and will not break any existing installations.

Please just use an automounted devtmpfs unless you are using an initrd.

Modified:
  udev/trunk/udev.install

--------------+
 udev.install |   28 ----------------------------
 1 file changed, 28 deletions(-)

Modified: udev.install
===================================================================
--- udev.install	2011-09-12 12:32:42 UTC (rev 137914)
+++ udev.install	2011-09-12 12:36:41 UTC (rev 137915)
@@ -46,31 +46,3 @@
     echo "---------------"
   fi
 }
-
-post_install() {
-
-  # We add the basic nodes (/dev/{console,null,zero}) to the rootfs, so they will be
-  # available, even when booting without an initrd, and without automounted devtmpfs.
-  # Relying on this functionality is ill adviced, but we will support it for now.
-
-  # The Archlinux installer bind-mounts /dev to /mnt/dev, thus making the real /dev invisible
-  ROOTDIR=""
-  [ "$(stat -c %D /)" != "$(stat -c %D /dev)" ] && ROOTDIR=$(mktemp -d /tmp/udevinstall.XXXXXX)
-  [ -n "${ROOTDIR}" ] && mount --bind / ${ROOTDIR}
-  if [ ! -c ${ROOTDIR}/dev/console ]; then
-    rm -f ${ROOTDIR}/dev/console
-    mknod -m600 ${ROOTDIR}/dev/console c 5 1
-  fi
-  if [ ! -c ${ROOTDIR}/dev/null ]; then
-    rm -f ${ROOTDIR}/dev/null
-    mknod -m644 ${ROOTDIR}/dev/null c 1 3
-  fi
-  if [ ! -c ${ROOTDIR}/dev/zero ]; then
-    rm -f ${ROOTDIR}/dev/zero
-    mknod -m644 ${ROOTDIR}/dev/zero c 1 5
-  fi
-  if [ -n "${ROOTDIR}" ]; then
-    umount ${ROOTDIR}
-    rmdir ${ROOTDIR}
-  fi
-}




More information about the arch-commits mailing list