From 9e1bf39a3dc5e9b967a8c898f3889e470ba9ae5c Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 17:21:58 +0200 Subject: Adding upstream version 1.0.128+nmu2+deb12u1. Signed-off-by: Daniel Baumann --- Makefile | 18 + README | 66 ++ TODO | 9 + debootstrap | 871 +++++++++++++++++++ debootstrap.8 | 206 +++++ functions | 2043 ++++++++++++++++++++++++++++++++++++++++++++ scripts/aequorea | 202 +++++ scripts/amber | 226 +++++ scripts/artful | 1 + scripts/ascii | 1 + scripts/bartholomea | 1 + scripts/beowulf | 1 + scripts/bionic | 1 + scripts/bookworm | 1 + scripts/breezy | 164 ++++ scripts/bullseye | 1 + scripts/buster | 1 + scripts/byzantium | 1 + scripts/ceres | 1 + scripts/chromodoris | 1 + scripts/cosmic | 1 + scripts/crimson | 1 + scripts/dapper | 169 ++++ scripts/dasyatis | 1 + scripts/debian-common | 243 ++++++ scripts/disco | 1 + scripts/edgy | 188 ++++ scripts/eoan | 1 + scripts/etch | 18 + scripts/etch-m68k | 1 + scripts/feisty | 190 ++++ scripts/focal | 1 + scripts/groovy | 1 + scripts/gutsy | 327 +++++++ scripts/hardy | 1 + scripts/hirsute | 1 + scripts/hoary | 179 ++++ scripts/hoary.buildd | 159 ++++ scripts/impish | 1 + scripts/intrepid | 1 + scripts/jammy | 1 + scripts/jaunty | 1 + scripts/jessie | 1 + scripts/jessie-kfreebsd | 1 + scripts/kali | 17 + scripts/kali-dev | 1 + scripts/kali-last-snapshot | 1 + scripts/kali-rolling | 1 + scripts/karmic | 1 + scripts/kinetic | 1 + scripts/lenny | 1 + scripts/lucid | 1 + scripts/maverick | 1 + scripts/natty | 1 + scripts/oldoldstable | 1 + scripts/oldstable | 1 + scripts/oneiric | 1 + scripts/potato | 106 +++ scripts/precise | 1 + scripts/quantal | 1 + scripts/raring | 1 + scripts/sarge | 220 +++++ scripts/sarge.buildd | 166 ++++ scripts/sarge.fakechroot | 171 ++++ scripts/saucy | 1 + scripts/sid | 16 + scripts/squeeze | 1 + scripts/stable | 1 + scripts/stretch | 1 + scripts/testing | 1 + scripts/trixie | 1 + scripts/trusty | 1 + scripts/unstable | 1 + scripts/utopic | 1 + scripts/vivid | 1 + scripts/warty | 166 ++++ scripts/warty.buildd | 159 ++++ scripts/wheezy | 1 + scripts/wily | 1 + scripts/woody | 205 +++++ scripts/woody.buildd | 168 ++++ scripts/xenial | 1 + scripts/yakkety | 1 + scripts/zesty | 1 + 84 files changed, 6729 insertions(+) create mode 100644 Makefile create mode 100644 README create mode 100644 TODO create mode 100755 debootstrap create mode 100644 debootstrap.8 create mode 100644 functions create mode 100644 scripts/aequorea create mode 100644 scripts/amber create mode 120000 scripts/artful create mode 120000 scripts/ascii create mode 120000 scripts/bartholomea create mode 120000 scripts/beowulf create mode 120000 scripts/bionic create mode 120000 scripts/bookworm create mode 100644 scripts/breezy create mode 120000 scripts/bullseye create mode 120000 scripts/buster create mode 120000 scripts/byzantium create mode 120000 scripts/ceres create mode 120000 scripts/chromodoris create mode 120000 scripts/cosmic create mode 120000 scripts/crimson create mode 100644 scripts/dapper create mode 120000 scripts/dasyatis create mode 100644 scripts/debian-common create mode 120000 scripts/disco create mode 100644 scripts/edgy create mode 120000 scripts/eoan create mode 100644 scripts/etch create mode 120000 scripts/etch-m68k create mode 100644 scripts/feisty create mode 120000 scripts/focal create mode 120000 scripts/groovy create mode 100644 scripts/gutsy create mode 120000 scripts/hardy create mode 120000 scripts/hirsute create mode 100644 scripts/hoary create mode 100644 scripts/hoary.buildd create mode 120000 scripts/impish create mode 120000 scripts/intrepid create mode 120000 scripts/jammy create mode 120000 scripts/jaunty create mode 120000 scripts/jessie create mode 120000 scripts/jessie-kfreebsd create mode 100644 scripts/kali create mode 120000 scripts/kali-dev create mode 120000 scripts/kali-last-snapshot create mode 120000 scripts/kali-rolling create mode 120000 scripts/karmic create mode 120000 scripts/kinetic create mode 120000 scripts/lenny create mode 120000 scripts/lucid create mode 120000 scripts/maverick create mode 120000 scripts/natty create mode 120000 scripts/oldoldstable create mode 120000 scripts/oldstable create mode 120000 scripts/oneiric create mode 100644 scripts/potato create mode 120000 scripts/precise create mode 120000 scripts/quantal create mode 120000 scripts/raring create mode 100644 scripts/sarge create mode 100644 scripts/sarge.buildd create mode 100644 scripts/sarge.fakechroot create mode 120000 scripts/saucy create mode 100644 scripts/sid create mode 120000 scripts/squeeze create mode 120000 scripts/stable create mode 120000 scripts/stretch create mode 120000 scripts/testing create mode 120000 scripts/trixie create mode 120000 scripts/trusty create mode 120000 scripts/unstable create mode 120000 scripts/utopic create mode 120000 scripts/vivid create mode 100644 scripts/warty create mode 100644 scripts/warty.buildd create mode 120000 scripts/wheezy create mode 120000 scripts/wily create mode 100644 scripts/woody create mode 100644 scripts/woody.buildd create mode 120000 scripts/xenial create mode 120000 scripts/yakkety create mode 120000 scripts/zesty diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..8516803 --- /dev/null +++ b/Makefile @@ -0,0 +1,18 @@ +# avoid dpkg-dev dependency; fish out the version with sed +VERSION := $(shell sed 's/.*(\(.*\)).*/\1/; q' debian/changelog) + +all: + +clean: + +DSDIR=$(DESTDIR)/usr/share/debootstrap +install: + mkdir -p $(DSDIR)/scripts + mkdir -p $(DESTDIR)/usr/sbin + + cp -a scripts/* $(DSDIR)/scripts/ + install -o root -g root -m 0644 functions $(DSDIR)/ + + sed 's/@VERSION@/$(VERSION)/g' debootstrap >$(DESTDIR)/usr/sbin/debootstrap + chown root:root $(DESTDIR)/usr/sbin/debootstrap + chmod 0755 $(DESTDIR)/usr/sbin/debootstrap diff --git a/README b/README new file mode 100644 index 0000000..430142c --- /dev/null +++ b/README @@ -0,0 +1,66 @@ +README for debootstrap +====================== + +See the manpage for (some) documentation. + +Running debootstrap from source +------------------------------- + +You can run debootstrap from its source tree without installing it. This +can be useful if you want a quick way to make a Debian chroot on another +system, or if you are testing modifications to debootstrap. + +First, get the source. + +* Either by using git + git clone https://salsa.debian.org/installer-team/debootstrap.git + +* Or by visiting + and downloading the tar.gz file + +Then in the debootstrap source directory: + + export DEBOOTSTRAP_DIR=`pwd` + sudo ./debootstrap stable my-stable-dir + +If you are running a multi-stage boot strap (for example for a QEMU +rootfs) you don't even need root: + + export DEBOOTSTRAP_DIR=`pwd` + fakeroot ./debootstrap --foreign --arch=armhf testing my-testing-dir http://deb.debian.org/debian + +Of course you will need to execute the second stage as root to finish the bootstrap: + + (on foreign hardware) + /debootstrap/debootstrap --second-stage + + +Future +------ + + * Cross-strap support - so you can bootstrap a filesystem to the + point where it will successfully boot, and finish installing itself + without having to be running the target architecture or OS yourself. + This means you should be able to run + + debootstrap --arch powerpc sarge ./sarge-ppc-chroot ... + + on an i386 system, boot a powerpc box with sarge-ppc-chroot as its + root files system, and have it "work". The cross-hurd package does + something similar, and should be replaced by this feature. + + * There should be some (better) way of telling debootstrap what "base" + packages you want to install -- this varies between making a chroot, + doing an install, and doing a buildd. Also, some installs want + different base packages (to setup networking, or kernels, eg) + + +NMUing +------ + +If there's a problem with debootstrap that you need fixed, feel free to do +an NMU to fix it. Usual rules: try not to break anything, and mail the +patch to the BTS. Don't worry about asking first though. + +However, note that debootstrap is now team maintained. Anyone in d-i can do +a release without the bother of a NMU. diff --git a/TODO b/TODO new file mode 100644 index 0000000..3a86214 --- /dev/null +++ b/TODO @@ -0,0 +1,9 @@ + +Features: + ++ second stage via chroot debootstrap/debootstrap + ++ debootstrap/deb file to record deb destinations/information + + -- configuration file + -- versus command line + -- support for sources (vs mirrors) + -- faux-pinning for packages diff --git a/debootstrap b/debootstrap new file mode 100755 index 0000000..996c620 --- /dev/null +++ b/debootstrap @@ -0,0 +1,871 @@ +#!/bin/sh +set -e + +VERSION='@VERSION@' + +unset TMP TEMP TMPDIR || true + +# might not be exported if we're running from init=/bin/sh or similar +export PATH + +########################################################################### + +if [ -z "$DEBOOTSTRAP_DIR" ]; then + if [ -x /debootstrap/debootstrap ]; then + DEBOOTSTRAP_DIR=/debootstrap + else + DEBOOTSTRAP_DIR=/usr/share/debootstrap + fi +fi + +. "$DEBOOTSTRAP_DIR/functions" +exec 4>&1 + +LANG=C +EXTRA_SUITES="" +USE_COMPONENTS=main +KEYRING="" +DISABLE_KEYRING="" +FORCE_KEYRING="" +VARIANT="" +MERGED_USR="" +ARCH="" +HOST_ARCH="" +HOST_OS="" +KEEP_DEBOOTSTRAP_DIR="" +USE_DEBIANINSTALLER_INTERACTION="" +SECOND_STAGE_ONLY="" +CHROOTDIR="" +MAKE_TARBALL="" +EXTRACTOR_OVERRIDE="" +UNPACK_TARBALL="" +ADDITIONAL="" +EXCLUDE="" +EXCLUDE_DEPENDENCY="" +VERBOSE="" +CERTIFICATE="" +CHECKCERTIF="" +PRIVATEKEY="" +CACHE_DIR="" +INRELEASE_PATH="" + +DEF_MIRROR="http://deb.debian.org/debian" +DEF_HTTPS_MIRROR="https://deb.debian.org/debian" + +# set $CONTAINER +detect_container + +export LANG USE_COMPONENTS +umask 022 + +########################################################################### + +## phases: +## finddebs dldebs printdebs save_variables first_stage second_stage + +RESOLVE_DEPS=true + +WHAT_TO_DO="finddebs dldebs save_variables first_stage second_stage" +am_doing_phase () { + # usage: if am_doing_phase finddebs; then ...; fi + local x; + for x in "$@"; do + if echo " $WHAT_TO_DO " | grep -q " $x "; then return 0; fi + done + return 1 +} + +########################################################################### + +usage_err() +{ + info USAGE1 "usage: [OPTION]... [ [