From 9a9491318d4a0469e4c97b28879ab34391c39095 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 23 Sep 2007 10:04:40 +0200 Subject: Adding live-package 0.99.21-1. --- ChangeLog | 12 ++++++ HISTORY | 16 +++++++ debian/changelog | 6 +++ debian/control | 2 +- debian/cron.daily | 30 ++++++------- debian/default | 2 +- debian/docs | 1 + src/hooks/mini | 9 ++++ src/lists/mini | 4 ++ src/main.sh | 2 +- src/scripts/02defaults.sh | 5 ++- src/scripts/11bootstrap.sh | 7 +++- src/scripts/13chroot.sh | 30 ++++++++++++- src/scripts/21image.sh | 22 ++-------- src/scripts/22iso.sh | 34 +++++++++++++-- src/scripts/23net.sh | 30 +++++++++++++ src/scripts/24.usb.sh | 102 +++++++++++++++++++++++++++++++++++++-------- templates/syslinux/f4.txt | 4 +- templates/syslinux/f8.txt | 2 +- templates/syslinux/f9.txt | 2 +- 20 files changed, 256 insertions(+), 66 deletions(-) create mode 100644 HISTORY create mode 100644 src/hooks/mini create mode 100644 src/lists/mini diff --git a/ChangeLog b/ChangeLog index 60b651f..958fc85 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,18 @@ +2007-02-12 Daniel Baumann + + * Added some code as suggested by Alex Owen to + check if the depends (syslinux, memtest etc.) are intentionally + installed in the chroot, and hence, don't remove them. + * Moved some depends into the chroot. + +2007-02-11 Daniel Baumann + + * Added mini flavour. + 2007-02-10 Daniel Baumann * Added legacy code for genisoimage. + * Uploaded 0.99.20. 2007-02-09 Daniel Baumann diff --git a/HISTORY b/HISTORY new file mode 100644 index 0000000..5690ea4 --- /dev/null +++ b/HISTORY @@ -0,0 +1,16 @@ +Milestones of Debian Live +------------------------- + +2006-02-14: Initial idea +http://blog.daniel-baumann.ch/2006/02/14#20060214_debian-live-initiative + +2006-03-16: First CD images available +http://lists.alioth.debian.org/pipermail/debian-live-devel/2006-March/000048.html + +2006-06-02: First netboot images available + +2007-02-05: Image autobuilder in place +http://lists.alioth.debian.org/pipermail/debian-live-devel/2007-February/000764.html + +2007-02-10: First USB images available +http://lists.alioth.debian.org/pipermail/debian-live-devel/2007-February/000790.html diff --git a/debian/changelog b/debian/changelog index 883565e..76c54a7 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +live-package (0.99.21-1) unstable; urgency=low + + * New upstream release. + + -- Daniel Baumann Mon, 12 Feb 2007 15:06:00 +0100 + live-package (0.99.20-1) unstable; urgency=low * New upstream release: diff --git a/debian/control b/debian/control index c96be77..0832ca8 100644 --- a/debian/control +++ b/debian/control @@ -8,7 +8,7 @@ Standards-Version: 3.7.2 Package: live-package Architecture: all -Depends: cdebootstrap, dosfstools, genext2fs, genisoimage | mkisofs, squashfs-tools, syslinux, mtools, parted +Depends: cdebootstrap, genext2fs, genisoimage | mkisofs, squashfs-tools Provides: make-live Description: utility to build Debian Live systems make-live is a utility to build Debian Live systems. It takes a Debian mirror diff --git a/debian/cron.daily b/debian/cron.daily index 4948dfc..26bae00 100644 --- a/debian/cron.daily +++ b/debian/cron.daily @@ -38,7 +38,7 @@ for AUTOBUILD_DISTRIBUTION in ${AUTOBUILD_DISTRIBUTIONS} do for AUTOBUILD_FLAVOUR in ${AUTOBUILD_FLAVOURS} do - if [ ! -f "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-iso-log.txt ] + if [ ! -f "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-iso-log.txt ] then # Generating images mkdir debian-live @@ -48,22 +48,22 @@ do if [ -f debian-live/binary.iso ] && [ -f debian-live/source.iso ] then # Moving logs - mkdir -p "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log - mv debian-live/log.txt "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-iso-log.txt - mv debian-live/packages.txt "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-iso-packages.txt + mkdir -p "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log + mv debian-live/log.txt "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-iso-log.txt + mv debian-live/packages.txt "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-iso-packages.txt # Moving images - mkdir -p "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE} - mv debian-live/binary.iso "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE}/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}.iso + mkdir -p "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE} + mv debian-live/binary.iso "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE}/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}.iso - mkdir -p "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/source - mv debian-live/source.iso "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/source/debian-live-${AUTOBUILD_DISTRIBUTION}-source-${AUTOBUILD_FLAVOUR}.iso + mkdir -p "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/source + mv debian-live/source.iso "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/source/debian-live-${AUTOBUILD_DISTRIBUTION}-source-${AUTOBUILD_FLAVOUR}.iso fi # Cleanup rm -rf debian-live - if [ ! -f "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-usb-log.txt ] + if [ ! -f "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-usb-log.txt ] then # Generating images mkdir debian-live @@ -73,13 +73,13 @@ do if [ -f debian-live/binary.img ] then # Moving logs - mkdir -p "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log - mv debian-live/log.txt "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-usb-log.txt - mv debian-live/packages.txt "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-usb-packages.txt + mkdir -p "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log + mv debian-live/log.txt "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-usb-log.txt + mv debian-live/packages.txt "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/log/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}_${AUTOBUILD_DATE}-usb-packages.txt # Moving images - mkdir -p "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE} - mv debian-live/binary.img "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE}/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}.img + mkdir -p "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE} + mv debian-live/binary.img "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/${AUTOBUILD_ARCHITECTURE}/debian-live-${AUTOBUILD_DISTRIBUTION}-${AUTOBUILD_ARCHITECTURE}-${AUTOBUILD_FLAVOUR}.img fi # Cleanup @@ -92,7 +92,7 @@ umount -f "${AUTOBUILD_DIRECTORY}"/debian-live/chroot/proc > /dev/null 2>&1 rm -rf "${AUTOBUILD_DIRECTORY}" # MD5SUMS -for DIRECTORY in "${AUTOBUILD_SERVER}"/daily-release/${AUTOBUILD_DATE}/* +for DIRECTORY in "${AUTOBUILD_SERVER}"/daily-builds/${AUTOBUILD_DATE}/* do cd "${DIRECTORY}" md5sum * > MD5SUMS diff --git a/debian/default b/debian/default index 523fce9..a829c3f 100644 --- a/debian/default +++ b/debian/default @@ -3,7 +3,7 @@ AUTOBUILD="false" AUTOBUILD_DISTRIBUTIONS="etch sid" -AUTOBUILD_FLAVOURS="minimal standard kde-desktop gnome-desktop xfce-desktop" +AUTOBUILD_FLAVOURS="standard kde-desktop gnome-desktop xfce-desktop" AUTOBUILD_OPTIONS="--with-source" AUTOBUILD_DIRECTORY="/srv/tmp/make-live" diff --git a/debian/docs b/debian/docs index 7d96d4e..2b0402c 100644 --- a/debian/docs +++ b/debian/docs @@ -1,2 +1,3 @@ AUTHORS +HISTORY TODO diff --git a/src/hooks/mini b/src/hooks/mini new file mode 100644 index 0000000..16df392 --- /dev/null +++ b/src/hooks/mini @@ -0,0 +1,9 @@ +# /usr/share/make-live/hooks/minimal - hook list for make-live(8) + +# Remove unused packages +apt-get remove --purge --yes apt-utils libdb4.4 + +# Remove unused files +rm -rf /usr/share/doc +rm -rf /usr/share/locale +rm -rf /usr/share/man diff --git a/src/lists/mini b/src/lists/mini new file mode 100644 index 0000000..434bde0 --- /dev/null +++ b/src/lists/mini @@ -0,0 +1,4 @@ +# /usr/share/make-live/lists/mini - package list for make-live(1) + +# Minimal +eject file sudo vim-tiny diff --git a/src/main.sh b/src/main.sh index 31c5b65..50b84e6 100755 --- a/src/main.sh +++ b/src/main.sh @@ -28,7 +28,7 @@ set -e BASE=${LIVE_BASE:-"/usr/share/make-live"} CONFIG="/etc/make-live.conf" PROGRAM="`basename ${0}`" -VERSION="0.99.20" +VERSION="0.99.21" CODENAME_OLDSTABLE="woody" CODENAME_STABLE="sarge" diff --git a/src/scripts/02defaults.sh b/src/scripts/02defaults.sh index 924ad65..e0590f4 100644 --- a/src/scripts/02defaults.sh +++ b/src/scripts/02defaults.sh @@ -188,6 +188,9 @@ Defaults () if [ "${LIVE_FLAVOUR}" = "minimal" ] then LIVE_PACKAGE_LIST="${BASE}/lists/minimal" + elif [ "${LIVE_FLAVOUR}" = "mini" ] + then + LIVE_PACKAGE_LISTS="${BASE}/lists/mini" else LIVE_PACKAGE_LIST="${BASE}/lists/standard" fi @@ -257,7 +260,7 @@ Defaults () fi # Set package indices - if [ -z "${LIVE_GENERIC_INDICES}" ] && [ "${LIVE_FLAVOUR}" != "minimal" ] + if [ -z "${LIVE_GENERIC_INDICES}" ] && [ "${LIVE_FLAVOUR}" != "minimal" ] && [ "${LIVE_FLAVOUR}" != "mini" ] then LIVE_GENERIC_INDICES="yes" fi diff --git a/src/scripts/11bootstrap.sh b/src/scripts/11bootstrap.sh index 224ac19..bc3a2ab 100644 --- a/src/scripts/11bootstrap.sh +++ b/src/scripts/11bootstrap.sh @@ -24,7 +24,12 @@ Bootstrap () fi # Bootstrap system - cdebootstrap --arch="${LIVE_ARCHITECTURE}" --flavour="${LIVE_FLAVOUR}" ${SUITE_CONFIG} "${LIVE_DISTRIBUTION}" "${LIVE_CHROOT}" "${LIVE_MIRROR}" + if [ "${LIVE_FLAVOUR}" = "mini" ] + then + cdebootstrap --arch="${LIVE_ARCHITECTURE}" --flavour=minimal ${SUITE_CONFIG} "${LIVE_DISTRIBUTION}" "${LIVE_CHROOT}" "${LIVE_MIRROR}" + else + cdebootstrap --arch="${LIVE_ARCHITECTURE}" --flavour="${LIVE_FLAVOUR}" ${SUITE_CONFIG} "${LIVE_DISTRIBUTION}" "${LIVE_CHROOT}" "${LIVE_MIRROR}" + fi # Remove unused packages Chroot_exec "dpkg -P cdebootstrap-helper-diverts" diff --git a/src/scripts/13chroot.sh b/src/scripts/13chroot.sh index 5a5298e..9403448 100644 --- a/src/scripts/13chroot.sh +++ b/src/scripts/13chroot.sh @@ -50,7 +50,7 @@ EOF if [ "${LIVE_DISTRIBUTION}" = "unstable" ] || [ "${LIVE_DISTRIBUTION}" = "${CODENAME_UNSTABLE}" ] || \ [ "${LIVE_DISTRIBUTION}" = "testing" ] || [ "${LIVE_DISTRIBUTION}" = "${CODENAME_TESTING}" ] then - if [ "${LIVE_FLAVOUR}" != "minimal" ] + if [ "${LIVE_FLAVOUR}" != "minimal" ] || [ "${LIVE_FLAVOUR}" != "mini" ] then Chroot_exec "apt-get install --yes --force-yes ${LIVE_REPOSITORY_KEYRING}" @@ -229,7 +229,7 @@ EOF rm -rf "${LIVE_CHROOT}"/var/cache/apt mkdir -p "${LIVE_CHROOT}"/var/cache/apt/archives/partial - if [ "${LIVE_FLAVOUR}" = "minimal" ] + if [ "${LIVE_FLAVOUR}" = "minimal" ] || [ "${LIVE_FLAVOUR}" = "mini" ] then rm -rf "${LIVE_CHROOT}"/var/lib/apt/lists/* rm -f "${LIVE_CHROOT}"/var/lib/dpkg/available-old @@ -257,4 +257,30 @@ EOF # Touching stage file touch "${LIVE_ROOT}"/.stage/chroot fi + + # Check depends + if [ "`grep dosfstools ${LIVE_ROOT}/packages.txt`" ] + then + KEEP_DOSFSTOOLS="true" + fi + + if [ "`grep memtest86+ ${LIVE_ROOT}/packages.txt`" ] + then + KEEP_MEMTEST86="true" + fi + + if [ "`grep mtools ${LIVE_ROOT}/packages.txt`" ] + then + KEEP_MTOOLS="true" + fi + + if [ "`grep parted ${LIVE_ROOT}/packages.txt`" ] + then + KEEP_PARTED="true" + fi + + if [ "`grep syslinux ${LIVE_ROOT}/packages.txt`" ] + then + KEEP_SYSLINUX="true" + fi } diff --git a/src/scripts/21image.sh b/src/scripts/21image.sh index 934bc70..9fc4fe2 100644 --- a/src/scripts/21image.sh +++ b/src/scripts/21image.sh @@ -166,10 +166,6 @@ Syslinux () { if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] then - # Install syslinux - Patch_network apply - Chroot_exec "aptitude install --assume-yes syslinux" - case "${1}" in iso) # Copy syslinux @@ -223,10 +219,6 @@ Syslinux () sed -i -e "s/LIVE_VERSION/${VERSION}/" "${LIVE_ROOT}"/tftpboot/pxelinux.cfg/f10.txt ;; esac - - # Remove syslinux - Chroot_exec "aptitude purge --assume-yes syslinux" - Patch_network deapply fi } @@ -238,7 +230,7 @@ Linuximage () case "${1}" in iso) # Copy linux-image - if [ "${LIVE_FLAVOUR}" = "minimal" ] + if [ "${LIVE_FLAVOUR}" = "minimal" ] || [ "${LIVE_FLAVOUR}" = "mini" ] then mv "${LIVE_CHROOT}"/boot/vmlinuz* "${LIVE_ROOT}"/binary/isolinux/vmlinuz mv "${LIVE_CHROOT}"/boot/initrd.img* "${LIVE_ROOT}"/binary/isolinux/initrd.gz @@ -251,7 +243,7 @@ Linuximage () net) # Copy linux-image - if [ "${LIVE_FLAVOUR}" = "minimal" ] + if [ "${LIVE_FLAVOUR}" = "minimal" ] || [ "${LIVE_FLAVOUR}" = "mini" ] then mv "${LIVE_ROOT}"/chroot/boot/vmlinuz* "${LIVE_ROOT}"/tftpboot/vmlinuz mv "${LIVE_ROOT}"/chroot/boot/initrd.img* "${LIVE_ROOT}"/tftpboot/initrd.gz @@ -267,10 +259,6 @@ Memtest () { if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] then - # Install memtest - Patch_network apply - Chroot_exec "aptitude install --assume-yes memtest86+" - case "$1" in iso) # Copy memtest @@ -282,10 +270,6 @@ Memtest () cp "${LIVE_ROOT}"/chroot/boot/memtest86+.bin "${LIVE_ROOT}"/tftpboot/memtest ;; esac - - # Remove memtest - Chroot_exec "aptitude purge --assume-yes memtest86+" - Patch_network deapply fi } @@ -306,7 +290,7 @@ Md5sum () mv "${LIVE_ROOT}"/md5sum.txt "${LIVE_ROOT}"/binary } -Mkisofs () +Genisoimage () { case "${1}" in binary) diff --git a/src/scripts/22iso.sh b/src/scripts/22iso.sh index 6f60a5f..c99b774 100644 --- a/src/scripts/22iso.sh +++ b/src/scripts/22iso.sh @@ -66,6 +66,20 @@ Iso () # Switching package indices to custom Indices custom + # Install depends + if [ -z "${KEEP_MEMTEST86}" ] + then + if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] + then + Chroot_exec "aptitude install --assume-yes memtest86+" + fi + fi + + if [ -z "${KEEP_SYSLINUX}" ] + then + Chroot_exec "aptitude install --assume-yes syslinux" + fi + # Installing syslinux Syslinux iso @@ -75,6 +89,20 @@ Iso () # Installing memtest Memtest iso + # Remove depends + if [ -z "${KEEP_MEMTEST86}" ] + then + if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] + then + Chroot_exec "aptitude purge --assume-yes memtest86+" + fi + fi + + if [ -z "${KEEP_SYSLINUX}" ] + then + Chroot_exec "aptitude purge --assume-yes syslinux" + fi + # Deconfigure network Patch_network deapply @@ -83,7 +111,7 @@ Iso () Patch_chroot deapply # Installing templates - if [ "${LIVE_FLAVOUR}" != "minimal" ] + if [ "${LIVE_FLAVOUR}" != "minimal" ] || [ "${LIVE_FLAVOUR}" != "mini" ] then cp -r "${LIVE_TEMPLATES}"/iso/* "${LIVE_ROOT}"/binary cp -r "${LIVE_TEMPLATES}"/common/* "${LIVE_ROOT}"/binary @@ -93,7 +121,7 @@ Iso () Md5sum # Creating image - Mkisofs binary + Genisoimage binary # Touching stage file touch "${LIVE_ROOT}"/.stage/image_binary @@ -119,7 +147,7 @@ Iso () Patch_chroot deapply # Creating image - Mkisofs source + Genisoimage source # Touching stage file touch "${LIVE_ROOT}"/.stage/image_source diff --git a/src/scripts/23net.sh b/src/scripts/23net.sh index f9c2089..ef837f4 100644 --- a/src/scripts/23net.sh +++ b/src/scripts/23net.sh @@ -93,6 +93,22 @@ EOF # Switching package indices to custom Indices custom + # Install depends + if [ -z "${KEEP_MEMTEST86}" ] + then + if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] + then + Patch_network apply + Chroot_exec "aptitude install --assume-yes memtest86+" + fi + fi + + if [ -z "${KEEP_SYSLINUX}" ] + then + Patch_network apply + Chroot_exec "aptitude install --assume-yes syslinux" + fi + # Installing syslinux Syslinux net @@ -102,6 +118,20 @@ EOF # Installing memtest Memtest net + # Remove depends + if [ -z "${KEEP_SYSLINUX}" ] + then + if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] + then + Chroot_exec "aptitude purge --assume-yes syslinux" + fi + fi + + if [ -z "${KEEP_SYSLINUX}" ] + then + Chroot_exec "aptitude purge --assume-yes syslinux" + fi + # Deconfigure network Patch_network deapply diff --git a/src/scripts/24.usb.sh b/src/scripts/24.usb.sh index cc51fda..200ca35 100644 --- a/src/scripts/24.usb.sh +++ b/src/scripts/24.usb.sh @@ -20,6 +20,7 @@ Usb () # Configure network Patch_network apply + # Manifest mkdir -p "${LIVE_ROOT}"/binary/casper for MANIFEST in "${LIVE_ROOT}"/filesystem.manifest* do @@ -50,6 +51,9 @@ Usb () # Generating rootfs image Genrootfs + # Mount proc + mount proc-live -t proc "${LIVE_CHROOT}"/proc + # Configure chroot Patch_chroot apply Patch_runlevel apply @@ -66,6 +70,35 @@ Usb () # Switching package indices to custom Indices custom + # Install depends + if [ -z "${KEEP_DOSFSTOOLS}" ] + then + Chroot_exec "aptitude install --assume-yes dosfstools" + fi + + if [ -z "${KEEP_MEMTEST86}" ] + then + if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] + then + Chroot_exec "aptitude install --assume-yes memtest86+" + fi + fi + + if [ -z "${KEEP_MTOOLS}" ] + then + Chroot_exec "aptitude install --assume-yes mtools" + fi + + if [ -z "${KEEP_PARTED}" ] + then + Chroot_exec "aptitude install --assume-yes parted" + fi + + if [ -z "${KEEP_SYSLINUX}" ] + then + Chroot_exec "aptitude install --assume-yes syslinux" + fi + # Installing syslinux Syslinux iso @@ -75,51 +108,84 @@ Usb () # Installing memtest Memtest iso - # Deconfigure network - Patch_network deapply - - # Deconfigure chroot - Patch_runlevel deapply - Patch_chroot deapply - # Calculating md5sums Md5sum # Creating image + + # USB hacks mv "${LIVE_ROOT}"/binary/isolinux/isolinux.cfg "${LIVE_ROOT}"/binary/syslinux.cfg mv "${LIVE_ROOT}"/binary/isolinux/isolinux.bin "${LIVE_ROOT}"/binary/syslinux.bin mv "${LIVE_ROOT}"/binary/isolinux/* "${LIVE_ROOT}"/binary + rmdir "${LIVE_ROOT}"/binary/isolinux/ # Everything which comes here needs to be cleaned up, - # especially all the parted/syslinux stuff should be done - # from within the chroot, not on the host system, will do that later. - DU_DIM="`du -ms ${LIVE_ROOT}/binary | cut -f1`" REAL_DIM="`expr ${DU_DIM} + ${DU_DIM} / 20`" # Just 5% more to be sure, need something more sophistcated here... dd if=/dev/zero of="${LIVE_ROOT}"/binary.img bs=1024k count=${REAL_DIM} echo "!!! The following error/warning messages can be ignored !!!" losetup_p "${LIVE_ROOT}"/binary.img 0 - parted -s ${FREELO} mklabel msdos set +e - parted -s ${FREELO} mkpartfs primary fat16 0.0 100% - parted -s ${FREELO} set 1 boot on - parted -s ${FREELO} set 1 lba off + Chroot_exec "parted -s ${FREELO} mklabel msdos" + Chroot_exec "parted -s ${FREELO} mkpartfs primary fat16 0.0 100%" + Chroot_exec "parted -s ${FREELO} set 1 boot on" + Chroot_exec "parted -s ${FREELO} set 1 lba off" set -e - cat /usr/lib/syslinux/mbr.bin > ${FREELO} + cat "${LIVE_CHROOT}"/usr/lib/syslinux/mbr.bin > ${FREELO} losetup -d ${FREELO} - echo "!!! The above error/warning messages can be ignored !!!" losetup_p "${LIVE_ROOT}"/binary.img 1 - mkfs.msdos -n DEBIAN_LIVE ${FREELO} + Chroot_exec "mkfs.msdos -n DEBIAN_LIVE ${FREELO}" mkdir "${LIVE_ROOT}"/binary.tmp mount ${FREELO} "${LIVE_ROOT}"/binary.tmp cp -r "${LIVE_ROOT}"/binary/* "${LIVE_ROOT}"/binary.tmp umount "${LIVE_ROOT}"/binary.tmp rmdir "${LIVE_ROOT}"/binary.tmp - syslinux ${FREELO} + Chroot_exec "syslinux ${FREELO}" losetup -d ${FREELO} + echo "!!! The above error/warning messages can be ignored !!!" + + # Remove depends + if [ -z "${KEEP_DOSFSTOOLS}" ] + then + Chroot_exec "aptitude purge --assume-yes dosfstools" + fi + + if [ -z "${KEEP_MEMTEST86}" ] + then + if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ] + then + Chroot_exec "aptitude purge --assume-yes memtest86+" + fi + fi + + if [ -z "${KEEP_MTOOLS}" ] + then + Chroot_exec "aptitude purge --assume-yes mtools" + fi + + if [ -z "${KEEP_PARTED}" ] + then + Chroot_exec "aptitude purge --assume-yes parted" + fi + + if [ -z "${KEEP_SYSLINUX}" ] + then + Chroot_exec "aptitude purge --assume-yes syslinux" + fi + + # Deconfigure network + Patch_network deapply + + # Deconfigure chroot + Patch_runlevel deapply + Patch_chroot deapply + + # Unmount proc + umount "${LIVE_CHROOT}"/proc + # Touching stage file touch "${LIVE_ROOT}"/.stage/image_binary fi diff --git a/templates/syslinux/f4.txt b/templates/syslinux/f4.txt index e0c780c..24198cb 100644 --- a/templates/syslinux/f4.txt +++ b/templates/syslinux/f4.txt @@ -1,12 +1,11 @@  0fSPECIAL BOOT PARAMETERS - VARIOUS HARDWARE07 09F407 -You can use the following boot parameters at the 0fboot:07 prompt, +You can use the following boot parameters at the 0fboot:07 prompt, in combination with the boot method (see <09F307>). 0f OPTION PARAMETER TO SPECIFY07 Check media for defects 0fintegrity-check07 Set a static ip (no dhcp) 0fip=if,add,netm,gatew07 -Set a static ip (no dhcp) 0fip=if,add,netm,gatew07 Set a default locale 0flocale=07 Suppress some debug informations 0fquiet07 Show internal filesystems 0fshowmounts07 @@ -20,4 +19,5 @@ For example: + Press F1control and F then 1 for the help index, or ENTER to diff --git a/templates/syslinux/f8.txt b/templates/syslinux/f8.txt index 164163e..0e41de0 100644 --- a/templates/syslinux/f8.txt +++ b/templates/syslinux/f8.txt @@ -9,7 +9,7 @@ and the next user who comes up with the same problem will profit from your experience! See the mailinglist and wiki for more information; both -are available at the Debian Live web site, 0fhttp://live.debian.net/07 +are available at the Debian Live web site, 0fhttp://debian-live.alioth.debian.org/07 diff --git a/templates/syslinux/f9.txt b/templates/syslinux/f9.txt index edf1671..e1344a0 100644 --- a/templates/syslinux/f9.txt +++ b/templates/syslinux/f9.txt @@ -1,7 +1,7 @@  0fABOUT THE DEBIAN LIVE PROJECT07 09F907 For information about the Debian Live project, see our web site: -0fhttp://live.debian.net/07 +0fhttp://debian-live.alioth.debian.org/07 For copyright information, press <09F1007>. -- cgit v1.0