From 96380401351379db65cb77dce26851b451dbe40c Mon Sep 17 00:00:00 2001 From: Daniel Hokka Zakrisson Date: Fri, 10 Apr 2009 20:51:27 +0000 Subject: [PATCH] Remove the debootstrap scripts, only causing more harm than good. Update the deboostrap version used. git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2834 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- distrib/breezy/debootstrap.script | 163 --------------------------------- distrib/dapper/debootstrap.script | 170 ---------------------------------- distrib/debian/debootstrap.script | 188 -------------------------------------- distrib/edgy/debootstrap.script | 170 ---------------------------------- distrib/feisty/debootstrap.script | 170 ---------------------------------- distrib/gutsy/debootstrap.script | 171 ---------------------------------- distrib/hoary/debootstrap.script | 179 ------------------------------------ distrib/misc/debootstrap.uri | 2 +- distrib/warty/debootstrap.script | 170 ---------------------------------- 9 files changed, 1 insertion(+), 1382 deletions(-) delete mode 100644 distrib/breezy/debootstrap.script delete mode 100644 distrib/dapper/debootstrap.script delete mode 100644 distrib/debian/debootstrap.script delete mode 100644 distrib/edgy/debootstrap.script delete mode 100644 distrib/feisty/debootstrap.script delete mode 100644 distrib/gutsy/debootstrap.script delete mode 100644 distrib/hoary/debootstrap.script delete mode 100644 distrib/warty/debootstrap.script diff --git a/distrib/breezy/debootstrap.script b/distrib/breezy/debootstrap.script deleted file mode 100644 index 8b55993..0000000 --- a/distrib/breezy/debootstrap.script +++ /dev/null @@ -1,163 +0,0 @@ -default_mirror http://old-releases.ubuntu.com/ubuntu -mirror_style release -download_style apt -finddebs_style from-indices -variants - buildd - -work_out_debs () { - LIBC6=libc6 - if [ "$ARCH" = "alpha" -o "$ARCH" = "ia64" ]; then LIBC6="libc6.1"; fi - - required="$(get_debs Priority: required)" - - if doing_variant -; then - #required="$required $(get_debs Priority: important)" - # ^^ should be getting debconf here somehow maybe - base="$(get_debs Priority: important)" - elif doing_variant buildd; then - # TODO: add Build-Essential: yes extraoverrides - #base="$(get_debs Build-Essential: yes)" - - add () { if [ "$ARCH" = "$1" ]; then eval "$2=\"\$$2 $3\""; fi; } - - base="apt binutils cpio cpp cpp-4.0 dpkg-dev g++ g++-4.0 gcc gcc-4.0 gcc-4.0-base ${LIBC6}-dev libdb4.2 libgdbm3 libstdc++6 libstdc++6-4.0-dev linux-kernel-headers make patch perl perl-modules" - - add ia64 base "libunwind7-dev" - add sparc base "lib64gcc1" - add sparc base "libc6-dev-sparc64" - add sparc base "libc6-sparc64" - fi -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - echo >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - setup_proc - in_target /sbin/ldconfig - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - if doing_variant -; then - x_core_install debconf - fi - - baseprog=0 - bases=$(set -- $required; echo $#) - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | - (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" \ - dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - - smallyes '' | - (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" \ - dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" \ - dpkg --status-fd 8 --force-auto-select --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - info CONFBASE "Configuring the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" \ - dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} diff --git a/distrib/dapper/debootstrap.script b/distrib/dapper/debootstrap.script deleted file mode 100644 index 63e8582..0000000 --- a/distrib/dapper/debootstrap.script +++ /dev/null @@ -1,170 +0,0 @@ -case $ARCH in - amd64|i386|powerpc|sparc) - default_mirror http://archive.ubuntu.com/ubuntu - ;; - *) - default_mirror http://ports.ubuntu.com/ubuntu-ports - ;; -esac -mirror_style release -download_style apt -finddebs_style from-indices -variants - buildd - -work_out_debs () { - LIBC6=libc6 - if [ "$ARCH" = "alpha" -o "$ARCH" = "ia64" ]; then LIBC6="libc6.1"; fi - - required="$(get_debs Priority: required)" - - if doing_variant -; then - #required="$required $(get_debs Priority: important)" - # ^^ should be getting debconf here somehow maybe - base="$(get_debs Priority: important)" - elif doing_variant buildd; then - # TODO: add Build-Essential: yes extraoverrides - #base="$(get_debs Build-Essential: yes)" - - add () { if [ "$ARCH" = "$1" ]; then eval "$2=\"\$$2 $3\""; fi; } - - base="apt binutils cpio cpp cpp-4.0 dpkg-dev g++ g++-4.0 gcc gcc-4.0 ${LIBC6}-dev libgdbm3 libstdc++6 libstdc++6-4.0-dev linux-kernel-headers make patch perl perl-modules" - - add ia64 base "libunwind7-dev" - add sparc base "lib64gcc1" - add sparc base "libc6-dev-sparc64" - add sparc base "libc6-sparc64" - fi -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - : >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - setup_proc - in_target /sbin/ldconfig - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - if doing_variant -; then - x_core_install debconf - fi - - baseprog=0 - bases=$(set -- $required; echo $#) - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | - (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" \ - dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - - smallyes '' | - (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" \ - dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" \ - dpkg --status-fd 8 --force-auto-select --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - info CONFBASE "Configuring the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" \ - dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} diff --git a/distrib/debian/debootstrap.script b/distrib/debian/debootstrap.script deleted file mode 100644 index 480a74d..0000000 --- a/distrib/debian/debootstrap.script +++ /dev/null @@ -1,188 +0,0 @@ -case $ARCH in - amd64|i386) - ;; - *) - # ftp.debian.org only has amd64 and i386 - default_mirror http://ftp.us.debian.org/debian - ;; -esac -mirror_style release -download_style apt -finddebs_style from-indices -variants - buildd fakechroot - -if doing_variant fakechroot; then - test "$FAKECHROOT" = "true" || error 1 FAKECHROOTREQ "This variant requires fakechroot environment to be started" -fi - -work_out_debs () { - LIBC6=libc6 - if [ "$ARCH" = "alpha" -o "$ARCH" = "ia64" ]; then LIBC6="libc6.1"; fi - - required="$(get_debs Priority: required)" - - if doing_variant - || doing_variant fakechroot; then - #required="$required $(get_debs Priority: important)" - # ^^ should be getting debconf here somehow maybe - base="$(get_debs Priority: important)" - elif doing_variant buildd; then - base="$(get_debs Build-Essential: yes)" - fi - - if doing_variant fakechroot; then - # ldd.fake needs binutils - required="$required binutils" - fi -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - echo >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - if [ -x $TARGET/usr/bin/md5sum.textutils -a \! -e $TARGET/usr/bin/md5sum ]; then - cp $TARGET/usr/bin/md5sum.textutils $TARGET/usr/bin/md5sum - fi - - if doing_variant fakechroot; then - setup_devices_fakechroot - else - setup_devices - fi - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - if doing_variant fakechroot; then - setup_proc_fakechroot - else - setup_proc - in_target /sbin/ldconfig - fi - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - if doing_variant fakechroot; then - install_fakechroot_tools - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - if doing_variant -; then - x_core_install debconf - fi - - baseprog=0 - bases=$(set -- $required; echo $#) - - info UNPACKREQ "Unpacking required packages..." - - exec 7>&1 - - smallyes '' | - (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" \ - dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 || echo EXITCODE $?) | - dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - - smallyes '' | - (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" \ - dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 || echo EXITCODE $?) | - dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" \ - dpkg --status-fd 8 --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 || echo EXITCODE $?) | - dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING - - info CONFBASE "Configuring the base system..." - - smallyes '' | - (repeat 5 \ - in_target_failmsg CONF_BASE_FAIL "Failure while configuring base packages." "" \ - dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 || echo EXITCODE $?) | - dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} diff --git a/distrib/edgy/debootstrap.script b/distrib/edgy/debootstrap.script deleted file mode 100644 index 7f656b6..0000000 --- a/distrib/edgy/debootstrap.script +++ /dev/null @@ -1,170 +0,0 @@ -case $ARCH in - amd64|i386|powerpc|sparc) - default_mirror http://archive.ubuntu.com/ubuntu - ;; - *) - default_mirror http://ports.ubuntu.com/ubuntu-ports - ;; -esac -mirror_style release -download_style apt -finddebs_style from-indices -variants - buildd - -work_out_debs () { - LIBC6=libc6 - if [ "$ARCH" = "alpha" -o "$ARCH" = "ia64" ]; then LIBC6="libc6.1"; fi - - required="$(get_debs Priority: required)" - - if doing_variant -; then - #required="$required $(get_debs Priority: important)" - # ^^ should be getting debconf here somehow maybe - base="$(get_debs Priority: important)" - elif doing_variant buildd; then - # TODO: add Build-Essential: yes extraoverrides - #base="$(get_debs Build-Essential: yes)" - - add () { if [ "$ARCH" = "$1" ]; then eval "$2=\"\$$2 $3\""; fi; } - - base="apt binutils cpio cpp cpp-4.1 dpkg-dev g++ g++-4.1 gcc gcc-4.1 ${LIBC6}-dev libdb4.4 libgdbm3 libstdc++6 libstdc++6-4.1-dev linux-libc-dev make patch perl perl-modules" - - add ia64 base "libunwind7-dev" - add sparc base "lib64gcc1" - add sparc base "libc6-dev-sparc64" - add sparc base "libc6-sparc64" - fi -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - : >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - setup_proc - in_target /sbin/ldconfig - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - if doing_variant -; then - x_core_install debconf - fi - - baseprog=0 - bases=$(set -- $required; echo $#) - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | - (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" \ - dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - - smallyes '' | - (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" \ - dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" \ - dpkg --status-fd 8 --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - info CONFBASE "Configuring the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" \ - dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} diff --git a/distrib/feisty/debootstrap.script b/distrib/feisty/debootstrap.script deleted file mode 100644 index 7f656b6..0000000 --- a/distrib/feisty/debootstrap.script +++ /dev/null @@ -1,170 +0,0 @@ -case $ARCH in - amd64|i386|powerpc|sparc) - default_mirror http://archive.ubuntu.com/ubuntu - ;; - *) - default_mirror http://ports.ubuntu.com/ubuntu-ports - ;; -esac -mirror_style release -download_style apt -finddebs_style from-indices -variants - buildd - -work_out_debs () { - LIBC6=libc6 - if [ "$ARCH" = "alpha" -o "$ARCH" = "ia64" ]; then LIBC6="libc6.1"; fi - - required="$(get_debs Priority: required)" - - if doing_variant -; then - #required="$required $(get_debs Priority: important)" - # ^^ should be getting debconf here somehow maybe - base="$(get_debs Priority: important)" - elif doing_variant buildd; then - # TODO: add Build-Essential: yes extraoverrides - #base="$(get_debs Build-Essential: yes)" - - add () { if [ "$ARCH" = "$1" ]; then eval "$2=\"\$$2 $3\""; fi; } - - base="apt binutils cpio cpp cpp-4.1 dpkg-dev g++ g++-4.1 gcc gcc-4.1 ${LIBC6}-dev libdb4.4 libgdbm3 libstdc++6 libstdc++6-4.1-dev linux-libc-dev make patch perl perl-modules" - - add ia64 base "libunwind7-dev" - add sparc base "lib64gcc1" - add sparc base "libc6-dev-sparc64" - add sparc base "libc6-sparc64" - fi -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - : >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - setup_proc - in_target /sbin/ldconfig - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - if doing_variant -; then - x_core_install debconf - fi - - baseprog=0 - bases=$(set -- $required; echo $#) - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | - (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" \ - dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - - smallyes '' | - (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" \ - dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" \ - dpkg --status-fd 8 --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - info CONFBASE "Configuring the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" \ - dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} diff --git a/distrib/gutsy/debootstrap.script b/distrib/gutsy/debootstrap.script deleted file mode 100644 index 87d0f0e..0000000 --- a/distrib/gutsy/debootstrap.script +++ /dev/null @@ -1,171 +0,0 @@ -case $ARCH in - amd64|i386|sparc) - default_mirror http://archive.ubuntu.com/ubuntu - ;; - *) - default_mirror http://ports.ubuntu.com/ubuntu-ports - ;; -esac -mirror_style release -download_style apt -finddebs_style from-indices -variants - buildd - -work_out_debs () { - LIBC6=libc6 - if [ "$ARCH" = "alpha" -o "$ARCH" = "ia64" ]; then LIBC6="libc6.1"; fi - - required="$(get_debs Priority: required)" - - if doing_variant -; then - #required="$required $(get_debs Priority: important)" - # ^^ should be getting debconf here somehow maybe - base="$(get_debs Priority: important)" - elif doing_variant buildd; then - # TODO: add Build-Essential: yes extraoverrides - #base="$(get_debs Build-Essential: yes)" - - add () { if [ "$ARCH" = "$1" ]; then eval "$2=\"\$$2 $3\""; fi; } - - base="apt binutils cpio cpp cpp-4.1 dpkg-dev g++ g++-4.1 gcc gcc-4.1 ${LIBC6}-dev libdb4.4 libgdbm3 libstdc++6 libstdc++6-4.1-dev linux-libc-dev make patch perl perl-modules" - - add hppa base "libgcc4" - add ia64 base "libunwind7-dev" - add sparc base "lib64gcc1" - add sparc base "libc6-dev-sparc64" - add sparc base "libc6-sparc64" - fi -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - : >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - setup_proc - in_target /sbin/ldconfig - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/Etc/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - if doing_variant -; then - x_core_install debconf - fi - - baseprog=0 - bases=$(set -- $required; echo $#) - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | - (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" \ - dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - - smallyes '' | - (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" \ - dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" \ - dpkg --status-fd 8 --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | - dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - info CONFBASE "Configuring the base system..." - - smallyes '' | - (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" \ - dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | - dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} diff --git a/distrib/hoary/debootstrap.script b/distrib/hoary/debootstrap.script deleted file mode 100644 index 5450dc5..0000000 --- a/distrib/hoary/debootstrap.script +++ /dev/null @@ -1,179 +0,0 @@ -default_mirror http://old-releases.ubuntu.com/ubuntu -mirror_style release -download_style apt - -work_out_debs () { - - required="base-files base-passwd bash bsdutils coreutils libacl1 libattr1 debconf debconf-i18n liblocale-gettext-perl libtext-iconv-perl libtext-wrapi18n-perl libtext-charwidth-perl debianutils diff dpkg dselect libblkid1 e2fsprogs e2fslibs libcomerr2 libss2 libuuid1 findutils grep gzip hostname libcap1 libdb1-compat libdb3 libncurses5 libnewt0.51 libpam-modules libpam-runtime libpam0g libpopt0 login makedev mawk mount ncurses-base ncurses-bin passwd perl-base procps python-minimal python2.4-minimal sed slang1a-utf8 lsb-base initscripts sysvinit sysv-rc tar util-linux zlib1g whiptail libgcc1 gcc-3.3-base libstdc++5" - - base="adduser alsa-base alsa-utils apt apt-utils aptitude at base-config bind9-host bsdmainutils bzip2 console-common console-data console-tools cpio cramfsprogs cron dash dhcp3-client dhcp3-common discover1 discover1-data dmsetup dnsutils dosfstools ed eject ethtool evms evms-ncurses fdutils file ftp gettext-base gnupg grepmap groff-base hdparm hotplug ifrename ifupdown info initrd-tools iproute iptables iputils-arping iputils-ping iputils-tracepath jfsutils klogd less libasound2 libbz2-1.0 libconsole libdb4.2 libdevmapper1.00 libdiscover1 libdns16 libevms-2.5 libfribidi0 libgc1 libgcrypt11 libgdbm3 libgnutls11 libgpg-error0 libgpmg1 libidn11 libisc7 libiw27 libldap2 liblockfile1 liblwres1 liblzo1 libmagic1 libncursesw5 libopencdk8 libparted1.6-12 libpcap0.8 libreiserfs0.3-0 libsasl2 libsasl2-modules libsigc++-1.2-5c102 libssl0.9.7 libtasn1-2 libusb-0.1-4 libwrap0 locales logrotate lsb-release lshw lsof lvm-common lvm10 lvm2 mailx man-db manpages mdadm mii-diag mime-support module-init-tools mtr-tiny mutt nano net-tools netbase netcat netkit-inetd ntp ntpdate openssh-client parted pciutils popularity-contest postfix postfix-tls ppp pppconfig pppoeconf psmisc python python2.4 reiser4progs reiserfsprogs reportbug rsync strace sudo sysklogd tcpd tcpdump telnet time ubuntu-base ubuntu-keyring udev usbutils vim vim-common w3m wget wireless-tools xfsprogs" - - without_package () { - echo "$2" | tr ' ' '\n' | grep -v "^$1$" | tr '\n' ' ' - } - subst_package () { - echo "$3" | tr ' ' '\n' | sed "s/^$1$/$2/" | tr '\n' ' ' - } - - LIBC6=libc6 - - case $ARCH in - "i386") - required="$required libc6 libc6-i686" - base="$base dmidecode libelfg0 ltrace memtest86+ libreadline4" - ;; - "powerpc") - required="$required libc6 libreadline4" - base="$base hfsplus hfsutils libelfg0 libhfsp0 ltrace mac-fdisk pmac-fdisk powerpc-utils" - ;; - "amd64") - required="$required libc6" - base="$base dmidecode libelfg0 ltrace memtest86+ libreadline4" - ;; - "ia64") - required="$required libc6.1 libunwind7" - base="$base dmidecode libreadline4" - LIBC6="libc6.1" - ;; - "sparc") - required="$required libc6" - base="$base lib64gcc1 libc6-sparc64 libreadline4" - ;; - *) - # who knows? - ;; - esac -} - -install_debs () { - first_stage_install - second_stage_install -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - echo >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - baseprog=0 - bases=7 - - setup_proc - in_target /sbin/ldconfig - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - x_core_install debconf - - baseprog=0 - bases="$(set -- $required; echo $#)" - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - baseprog=0 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - #on_exit "(in_target_nofail umount /dev/pts) || true" - - smallyes '' | (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" dpkg --status-fd 8 --force-auto-select --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - baseprog=0 - - info CONFBASE "Configuring the base system..." - - mv "$TARGET/usr/sbin/sendmail" "$TARGET/usr/sbin/sendmail.REAL" - ln -s /bin/true "$TARGET/usr/sbin/sendmail" - - smallyes '' | (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - rm -f "$TARGET/usr/sbin/sendmail" - mv "$TARGET/usr/sbin/sendmail.REAL" "$TARGET/usr/sbin/sendmail" - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} - diff --git a/distrib/misc/debootstrap.uri b/distrib/misc/debootstrap.uri index 56aea56..921f84e 100644 --- a/distrib/misc/debootstrap.uri +++ b/distrib/misc/debootstrap.uri @@ -1 +1 @@ -http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.10_all.deb +http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.12_all.deb diff --git a/distrib/warty/debootstrap.script b/distrib/warty/debootstrap.script deleted file mode 100644 index 8771d37..0000000 --- a/distrib/warty/debootstrap.script +++ /dev/null @@ -1,170 +0,0 @@ -default_mirror http://old-releases.ubuntu.com/ubuntu -mirror_style release -download_style apt - -work_out_debs () { - - required="base-files base-passwd bash bsdutils coreutils libacl1 libattr1 debconf debconf-i18n liblocale-gettext-perl libtext-iconv-perl libtext-wrapi18n-perl libtext-charwidth-perl debianutils diff dpkg dselect libblkid1 e2fsprogs e2fslibs libcomerr2 libss2 libuuid1 findutils grep gzip hostname libcap1 libc6 libdb1-compat libdb3 libncurses5 libnewt0.51 libpam-modules libpam-runtime libpam0g libpopt0 login makedev mawk modutils mount ncurses-base ncurses-bin passwd perl-base procps sed slang1a-utf8 lsb-base initscripts sysvinit sysv-rc tar util-linux zlib1g whiptail libgcc1 gcc-3.3-base libstdc++5" - - base="adduser alsa-base alsa-utils apt apt-utils aptitude at base-config bind9-host bsdmainutils bzip2 console-common console-data console-tools cpio cramfsprogs cron dash dbus-1 dhcp3-client dhcp3-common discover1 discover1-data dmsetup dnsutils dosfstools ed eject evms evms-ncurses fdutils file ftp gettext-base gnupg groff-base hdparm hotplug ifrename ifupdown info initrd-tools iproute iptables iputils-arping iputils-ping iputils-tracepath jfsutils klogd less libasound2 libatm1 libbz2-1.0 libconsole libdb4.2 libdevmapper1.00 libdiscover1 libdns16 libevms-2.3 libexpat1 libfribidi0 libgc1 libgcrypt7 libgdbm3 libgnutls10 libgpg-error0 libgpmg1 libidn11 libisc7 libiw27 libldap2 liblockfile1 liblwres1 liblzo1 libmagic1 libncursesw5 libopencdk8 libparted1.6-0 libpcap0.7 libpcap0.8 libreiserfs0.3-0 libsasl2 libsigc++-1.2-5c102 libssl0.9.7 libtasn1-2 libusb-0.1-4 libwrap0 locales logrotate lshw lsof ltrace lvm-common lvm10 lvm2 mailx man-db manpages mdadm mii-diag mime-support module-init-tools mtr-tiny mutt nano net-tools netbase netcat netkit-inetd ntp ntpdate openssh-client parted pciutils popularity-contest postfix postfix-tls ppp pppconfig pppoeconf psmisc python python2.3 reiser4progs reiserfsprogs reportbug rsync strace sudo sysklogd tcpd tcpdump telnet time ubuntu-base udev usbutils vim vim-common w3m wget wireless-tools xfsprogs" - - without_package () { - echo "$2" | tr ' ' '\n' | grep -v "^$1$" | tr '\n' ' ' - } - subst_package () { - echo "$3" | tr ' ' '\n' | sed "s/^$1$/$2/" | tr '\n' ' ' - } - - LIBC6=libc6 - - case $ARCH in - "i386") - required="$required libc6-i686" - base="$base dmidecode memtest86+ libreadline4" - ;; - "powerpc") - required="$required libreadline4" - base="$base hfsplus hfsutils libhfsp0 mac-fdisk pmac-fdisk powerpc-utils" - ;; - "amd64") - base="$base dmidecode libreadline4" - ;; - *) - # who knows? - ;; - esac -} - -install_debs () { - first_stage_install - second_stage_install -} - -first_stage_install () { - extract $required - - mkdir -p "$TARGET/var/lib/dpkg" - : >"$TARGET/var/lib/dpkg/status" - echo >"$TARGET/var/lib/dpkg/available" - - setup_etc - if [ ! -e "$TARGET/etc/fstab" ]; then - echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab" - chown 0.0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab" - fi - - setup_devices - - x_feign_install () { - local pkg="$1" - local deb="$(debfor $pkg)" - local ver="$( - ar -p "$TARGET/$deb" control.tar.gz | zcat | - tar -O -xf - control ./control 2>/dev/null | - sed -ne 's/^Version: *//Ip' | head -n 1 - )" - - mkdir -p "$TARGET/var/lib/dpkg/info" - - echo \ -"Package: $pkg -Version: $ver -Status: install ok installed" >> "$TARGET/var/lib/dpkg/status" - - touch "$TARGET/var/lib/dpkg/info/${pkg}.list" - } - - x_feign_install dpkg -} - -second_stage_install () { - x_core_install () { - smallyes '' | in_target dpkg --force-depends --install $(debfor "$@") - } - - p () { - baseprog="$(($baseprog + ${1:-1}))" - } - - DEBIAN_FRONTEND=noninteractive - DEBCONF_NONINTERACTIVE_SEEN=true - export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN - - setup_proc - in_target /sbin/ldconfig - - baseprog=0 - bases=7 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #1 - info INSTCORE "Installing core packages..." - - p; progress $baseprog $bases INSTCORE "Installing core packages" #2 - ln -sf mawk $TARGET/usr/bin/awk - x_core_install base-files base-passwd - p; progress $baseprog $bases INSTCORE "Installing core packages" #3 - x_core_install dpkg - - if [ ! -e "$TARGET/etc/localtime" ]; then - ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime" - fi - - p; progress $baseprog $bases INSTCORE "Installing core packages" #4 - x_core_install $LIBC6 - - p; progress $baseprog $bases INSTCORE "Installing core packages" #5 - x_core_install perl-base - p; progress $baseprog $bases INSTCORE "Installing core packages" #6 - rm $TARGET/usr/bin/awk - x_core_install mawk - p; progress $baseprog $bases INSTCORE "Installing core packages" #7 - x_core_install debconf - - baseprog=0 - bases="$(set -- $required; echo $#)" - - info UNPACKREQ "Unpacking required packages..." - - smallyes '' | (repeat 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" dpkg --status-fd 8 --force-depends --unpack $(debfor $required) 8>&1 1>&7 | dpkg_progress $baseprog $bases UNPACKREQ "Unpacking required packages" UNPACKING) 7>&1 - - baseprog=0 - - info CONFREQ "Configuring required packages..." - - mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL" - echo \ -"#!/bin/sh -echo -echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon" - chmod 755 "$TARGET/sbin/start-stop-daemon" - - setup_dselect_method apt - #on_exit "(in_target_nofail umount /dev/pts) || true" - - smallyes '' | (in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" dpkg --status-fd 8 --configure --pending --force-configure-any --force-depends 8>&1 1>&7 | dpkg_progress $baseprog $bases CONFREQ "Configuring required packages" CONFIGURING) 7>&1 - - baseprog=0 - bases="$(set -- $base; echo $#)" - - info UNPACKBASE "Unpacking the base system..." - - smallyes '' | (repeat 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" dpkg --status-fd 8 --force-auto-select --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base) 8>&1 1>&7 | dpkg_progress $baseprog $bases UNPACKBASE "Unpacking base system" UNPACKING) 7>&1 - - baseprog=0 - - info CONFBASE "Configuring the base system..." - - mv "$TARGET/usr/sbin/sendmail" "$TARGET/usr/sbin/sendmail.REAL" - ln -s /bin/true "$TARGET/usr/sbin/sendmail" - - smallyes '' | (repeat 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" dpkg --status-fd 8 --force-confold --skip-same-version --configure -a 8>&1 1>&7 | dpkg_progress $baseprog $bases CONFBASE "Configuring base system" CONFIGURING) 7>&1 - - rm -f "$TARGET/usr/sbin/sendmail" - mv "$TARGET/usr/sbin/sendmail.REAL" "$TARGET/usr/sbin/sendmail" - - mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon" - - progress $bases $bases CONFBASE "Configuring base system" - info BASESUCCESS "Base system installed successfully." -} - -- 1.8.1.5