From: Michael Prokop Date: Thu, 28 Aug 2008 13:23:31 +0000 (+0200) Subject: Install devices using our own device tarball X-Git-Tag: 0.18~13 X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=commitdiff_plain;h=e0eb3be4c48c2cc0e7bc02ce738b162d3266c42c Install devices using our own device tarball --- diff --git a/debian/changelog b/debian/changelog index 36157e6..ebc7343 100644 --- a/debian/changelog +++ b/debian/changelog @@ -20,8 +20,10 @@ grml-debootstrap (0.18) unstable; urgency=low * Copy system's /etc/hosts to the target system. * Move stages to /var/cache/grml-debootstrap (thanks for the idea, gebi). + * Install devices using our own device tarball instead of running + MAKEDEV (which is just an ungly fork bomb). - -- Michael Prokop Thu, 28 Aug 2008 15:06:48 +0200 + -- Michael Prokop Thu, 28 Aug 2008 15:22:57 +0200 grml-debootstrap (0.17) unstable; urgency=low diff --git a/debian/rules b/debian/rules index d45ae13..991320c 100755 --- a/debian/rules +++ b/debian/rules @@ -31,6 +31,7 @@ install: build # Add here commands to install the package into debian/grml-debootstrap. install -m 644 config debian/grml-debootstrap/etc/debootstrap/ + install -m 644 devices.tar.gz debian/grml-debootstrap/etc/debootstrap/ install -m 644 locale.gen debian/grml-debootstrap/etc/debootstrap/ install -m 644 packages debian/grml-debootstrap/etc/debootstrap/ install -m 755 chroot-script debian/grml-debootstrap/etc/debootstrap/ diff --git a/devices.tar.gz b/devices.tar.gz new file mode 100644 index 0000000..07dd1cf Binary files /dev/null and b/devices.tar.gz differ diff --git a/grml-debootstrap b/grml-debootstrap index 0611494..8488ad8 100755 --- a/grml-debootstrap +++ b/grml-debootstrap @@ -671,10 +671,10 @@ preparechroot() { # make sure we have our files for later use via chroot-script cp /etc/debootstrap/config $MNTPOINT/etc/debootstrap/ # make sure we adjust the configuration variables accordingly: - sed -i "s/RELEASE=.*/RELEASE='${RELEASE}'/" $MNTPOINT/etc/debootstrap/config - sed -i "s/TARGET=.*/TARGET='${TARGET}'/" $MNTPOINT/etc/debootstrap/config - sed -i "s/GRUB=.*/GRUB='${GRUB}'/" $MNTPOINT/etc/debootstrap/config - sed -i "s/GROOT=.*/GROOT='${GROOT}'/" $MNTPOINT/etc/debootstrap/config + sed -i "s/RELEASE=.*/RELEASE=\"${RELEASE}\"/" $MNTPOINT/etc/debootstrap/config + sed -i "s/TARGET=.*/TARGET=\"${TARGET}\"/" $MNTPOINT/etc/debootstrap/config + sed -i "s/GRUB=.*/GRUB=\"${GRUB}\"/" $MNTPOINT/etc/debootstrap/config + sed -i "s/GROOT=.*/GROOT=\"${GROOT}\"/" $MNTPOINT/etc/debootstrap/config cp /etc/debootstrap/packages $MNTPOINT/etc/debootstrap/packages cp $CHROOT_VARIABLES $MNTPOINT/etc/debootstrap/variables # do NOT use $CHROOT_VARIABLES inside chroot! @@ -693,6 +693,9 @@ preparechroot() { # setup default locales [ -n "$LOCALES" ] && cp /etc/debootstrap/locale.gen $MNTPOINT/etc/locale.gen + # MAKEDEV is just a forking bomb crap, let's do it on our own instead :) + ( cd $MNTPOINT/dev && tar jxf /etc/debootstrap/devices.tar.gz ) + # copy any existing existing files to chroot [ -d /etc/debootstrap/boot ] && cp -a /etc/debootstrap/boot/* $MNTPOINT/boot/ [ -d /etc/debootstrap/etc ] && cp -a /etc/debootstrap/etc/* $MNTPOINT/etc/