From e7256f68409bbb5171f90521b90da8b2530febc2 Mon Sep 17 00:00:00 2001 From: Adam Conrad Date: Wed, 11 Jun 2008 13:46:06 -0600 Subject: [PATCH] * Employ hideous hack to ensure that when we're building against updates/proposed, we only get one version of kernel headers. * Move the cleanup() call to the end of the script, so we still have proc mounted for coreutils when update-initramfs is run. * Mount dev/pts immediately after debootstrap, as dpkg has begun whining pretty loudly (and occasionally exiting) if it's gone. --- debian/changelog | 11 +++++++++++ livecd.sh | 27 ++++++++++++++++++++++++++- 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 26461435..05465ea8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,14 @@ +livecd-rootfs (0.60) intrepid; urgency=low + + * Employ hideous hack to ensure that when we're building against + updates/proposed, we only get one version of kernel headers. + * Move the cleanup() call to the end of the script, so we still + have proc mounted for coreutils when update-initramfs is run. + * Mount dev/pts immediately after debootstrap, as dpkg has begun + whining pretty loudly (and occasionally exiting) if it's gone. + + -- Adam Conrad Tue, 10 Jun 2008 17:20:10 -0600 + livecd-rootfs (0.59) intrepid; urgency=low [ Colin Watson ] diff --git a/livecd.sh b/livecd.sh index ab71237b..72eb56c3 100755 --- a/livecd.sh +++ b/livecd.sh @@ -234,6 +234,10 @@ Flags: seen dpkg -l livecd-rootfs || true # get our version # in the log. debootstrap --components=$(echo $COMP | sed 's/ /,/g') --arch $TARGETARCH $STE $ROOT $MIRROR + # Recent dpkg has started complaining pretty loudly if dev/pts isn't + # mounted, so let's get it mounted immediately after debootstrap: + mount -t devpts devpts-${STE}-${FSS}-livefs ${ROOT}dev/pts + # Just make a few things go away, which lets us skip a few other things. DIVERTS="usr/sbin/mkinitrd usr/sbin/invoke-rc.d" for file in $DIVERTS; do @@ -313,6 +317,24 @@ link_in_boot = $link_in_boot chroot $ROOT apt-get update chroot $ROOT apt-get -y --purge dist-upgrade livecd.${FSS}.manifest-headers + chroot ${ROOT} dpkg -l linux-headers-\* | grep ^i | awk '{print $2}' \ + > livecd.${FSS}.manifest-headers-full + HEADERPACKAGES=`cat livecd.${FSS}.manifest-headers-full` + HEADERMETA="" + for i in `comm -3 livecd.${FSS}.manifest-headers livecd.${FSS}.manifest-headers-full`; do + HEADERMETA="$HEADERMETA $i" + done + rm -f livecd.${FSS}.manifest-headers livecd.${FSS}.manifest-headers-full + chroot ${ROOT} apt-get -y --purge remove $HEADERPACKAGES livecd.${FSS}.manifest-desktop chroot $ROOT apt-get -y install $LIVELIST ${ROOT}etc/apt/sources.list deb ${USERMIRROR} $STE ${COMP} deb-src ${SRCMIRROR} $STE ${COMP} @@ -436,6 +457,10 @@ deb-src ${USERMIRROR} ${STE}-updates ${COMP} perl -i -nle 'print unless /^Package: language-(pack|support)/ .. /^$/;' \ ${ROOT}/var/lib/apt/extended_states + # And run the cleanup function dead last, to umount /proc after nothing + # else needs to be run in the chroot (umounting it earlier breaks rm): + cleanup + livefs_squash() { squashsort="http://people.ubuntu.com/~tfheen/livesort/${FSS}.list.${TARGETARCH}"