[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#445157: debootstrap - hardcoded value of TARGET in second-stage prevents creation of a foreign chroot



On Tue, 16 Oct 2007 14:36:04 -0200
Otavio Salvador <otavio@debian.org> wrote:

> >> Could you update the manpage? So we can commit it.
> >
> > Is the lack of a manpage update going to block the bug?
> 
> I don't indent to commit it before someone does it or I find the time
> to do that myself. If we start to accept those changes without
> properly documenting them we'll end with a bunch of undocumented
> options and personally I think we all wouldn't like to see it
> happening ;-)

Come to think of it, --second-stage isn't in the current debootstrap
--help message at all, only the man page.

> > I would normally use doclifter if this was a package that I was
> > maintaining - storing the XML in the package source and using
> > docbook-xsl to update it prior to building the package to prevent a
> > build dependency. However, using doclifter means that the diff to the
> > original manpage is quite large and is not limited to the new text, it
> > can also change (for the better usually) the appearance of certain
> > parts of the manpage (headers generally).
> 
> Personally I do not object for a more "readable" source format for
> manpage and I doubt someone else will do too so if you can provide the
> patch for it, I'd commit it without problem :-)

OK. I've done the doclifter thing and updated the XML, generated a new
manpage and compared it with the old. I'm assuming you don't want the
build-dependency on docbook-xsl so I've included a patch to create a
README that documents how to use xsltproc to generate the manpage.
(Note that the man page *diff* is larger than the entire XML file!)

> Please, try to provide the patch and I'll try to handle it as soon as
> possible.

Four patches attached.

debootstrap.diff - the actual change to close this bug.

README.diff - create a small README that doesn't have to be packaged
with the binaries, only included in the source.

debootstrap.8.xml.diff - creates the XML, generated from doclifter and
including changes to cover the new option related to this bug.

debootstrap.8.diff - probably unnecessary but demonstrates the level of
changes incurred through doclifter that made it impossible to submit
those as a patch to the man page itself. You probably don't want to
apply that.

There shouldn't be any need to change the contents of debian/* as
neither of the new files need to be part of the debootstrap
installation, only the source.

I'm not sure how you create the source for debootstrap - presumably
some form of RCS-dependent foo-buildpackage. I'm assuming that any file
present in RCS will be included in the debootstrap_1.0.4.tar.gz so that
is where I would expect to find README and debootstrap.8.xml in case of
future changes.

Please review the manpage changes - I think it makes for a slightly
better manpage due to the whitespace and bold improvements. YMMV.

HTH.

-- 


Neil Williams
=============
http://www.data-freedom.org/
http://www.nosoftwarepatents.com/
http://www.linux.codehelp.co.uk/

--- debootstrap.old/debootstrap 
+++ debootstrap-1.0.3/debootstrap 
@@ -87,7 +87,10 @@
 
       --unpack-tarball T     acquire .debs from a tarball instead of http
       --make-tarball T       download .debs and create a tarball (tgz format)
-
+      --second-stage-target DIR
+                             Run second stage in a subdirectory instead of root
+                               (can be used to create a foreign chroot)
+                               (requires --second-stage)
       --boot-floppies        used for internal purposes by boot-floppies
       --debian-installer     used for internal purposes by debian-installer
 EOF
@@ -142,6 +145,18 @@
         SECOND_STAGE_ONLY=true
 	shift
 	;;
+    --second-stage-target)
+       if [ "$SECOND_STAGE_ONLY" = "true" ] ; then
+          if [ -n "$2" ] ; then
+            CHROOTDIR="$2"
+            shift 2
+          else
+            error 1 NEEDARG "option requires an argument: %s" "$1"
+          fi
+        else
+            error 1 NEEDARG "%s only applies in the second stage" "$1"
+        fi
+      ;;
       --print-debs)
         WHAT_TO_DO="finddebs printdebs kill_target"
         shift
@@ -242,7 +257,11 @@
     VARIANT=$(cat $DEBOOTSTRAP_DIR/variant)
     SUPPORTED_VARIANTS="$VARIANT"
   fi
-  TARGET=/
+  if [ "$CHROOTDIR" = "" ]; then
+    TARGET=/
+  else
+    TARGET=$CHROOTDIR
+  fi
   SCRIPT=$DEBOOTSTRAP_DIR/suite-script
 else
   if [ "$1" = "" -o "$2" = "" ]; then
--- /dev/null	2007-10-02 23:46:34.736041737 +0100
+++ debootstrap-1.0.3/README	2007-10-16 18:08:07.000000000 +0100
@@ -0,0 +1,9 @@
+				DEBOOTSTRAP MAN PAGE GENERATION
+				===============================
+
+The man page has been converted to XML with doclifter.
+After editing the XML, generate the manpage with:
+
+xsltproc --nonet http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl debootstrap.8.xml
+
+(Requires docbook-xsl).
--- /dev/null	2007-10-02 23:46:34.736041737 +0100
+++ debootstrap-1.0.3/debootstrap.8.xml	2007-10-16 18:11:02.000000000 +0100
@@ -0,0 +1,262 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
+                   "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd";>
+<!-- lifted from troff+man by doclifter -->
+<refentry id='debootstrap8'>
+<refentryinfo><date>2001-04-27</date></refentryinfo>
+<refmeta>
+<refentrytitle>DEBOOTSTRAP</refentrytitle>
+<manvolnum>8</manvolnum>
+<refmiscinfo class='date'>2001-04-27</refmiscinfo>
+<refmiscinfo class='source'>Debian Project</refmiscinfo>
+<refmiscinfo class='manual'>Debian GNU/Linux manual</refmiscinfo>
+</refmeta>
+<refnamediv id='name'>
+<refname>debootstrap</refname>
+<refpurpose>Bootstrap a basic Debian system</refpurpose>
+</refnamediv>
+<!-- body begins here -->
+<refsynopsisdiv id='synopsis'>
+<cmdsynopsis>
+  <command>debootstrap</command>
+    <arg choice='opt' rep='repeat'><replaceable>OPTION</replaceable></arg>
+    <arg choice='plain'><replaceable>SUITE</replaceable></arg>
+    <arg choice='plain'><replaceable>TARGET</replaceable></arg>
+    <arg choice='opt'><arg choice='plain'><replaceable>MIRROR</replaceable></arg><arg choice='opt'><replaceable>SCRIPT</replaceable></arg></arg>
+</cmdsynopsis>
+<cmdsynopsis>
+  <command>debootstrap</command>
+    <arg choice='opt' rep='repeat'><replaceable>OPTION</replaceable></arg>
+    <arg choice='plain'>--second-stage </arg>
+</cmdsynopsis>
+</refsynopsisdiv>
+
+
+<refsect1 id='description'><title>DESCRIPTION</title>
+<para><command>debootstrap</command>
+bootstraps a basic Debian system of
+<emphasis remap='I'>SUITE</emphasis>
+(eg, sarge, etch, lenny, sid) into
+<emphasis remap='I'>TARGET</emphasis>
+from
+<emphasis remap='I'>MIRROR</emphasis>
+by running
+<emphasis remap='I'>SCRIPT</emphasis>.
+<emphasis remap='I'>MIRROR</emphasis>
+can be an http:// URL or a file:/// URL. Notice that file:/ URLs are
+translated to file:/// (correct scheme as described in RFC1738 for local filenames),
+and file:// will <emphasis remap='B'>not</emphasis> work.</para>
+
+<para><emphasis remap='B'>Debootstrap</emphasis> can be used to install Debian in a system without using an
+installation disk but can also be used to run a different Debian flavor in a <emphasis remap='B'>chroot</emphasis>
+environment. This way you can create a full (minimal) Debian installation which
+can be used for testing purposes (see the <emphasis remap='B'>EXAMPLES</emphasis> section).
+If you are looking for a chroot system to build packages please take a look at
+<emphasis remap='B'>pbuilder</emphasis>.</para>
+</refsect1>
+
+<refsect1 id='options'><title>OPTIONS</title>
+<variablelist remap='IP'>
+  <varlistentry>
+  <term><option>--arch ARCH</option></term>
+  <listitem>
+<para>Set the target architecture (use if dpkg isn't installed). See also --foreign.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--include=alpha,beta</option></term>
+  <listitem>
+<para>Comma separated list of packages which will be added to download and extract
+lists.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--exclude=alpha,beta</option></term>
+  <listitem>
+<para>Comma separated list of packages which will be removed from download and
+extract lists. WARNING: you can and probably will exclude essential packages, be
+careful using this option.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--components=alpha,beta</option></term>
+  <listitem>
+<para>Use packages from the listed components of the archive.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--no-resolve-deps</option></term>
+  <listitem>
+<para>By default, debootstrap will attempt to automatically resolve any missing
+dependencies, warning if any are found. Note that this is not a complete
+dependency resolve in the sense of dpkg or apt, and that it is far better
+to specify the entire base system than rely on this option. With this
+option set, this behaviour is disabled.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--variant=buildd|fakechroot</option></term>
+  <listitem>
+<para>Name of the bootstrap script variant to use.  Currently, the variant
+supported are buildd, which installs the build-essential packages into
+<emphasis remap='I'>TARGET</emphasis>
+and fakechroot, which installs the packages without root privileges.
+The default, with no <option>--variant=X</option> argument, is to create a base
+Debian installation in
+<emphasis remap='I'>TARGET</emphasis>.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--keyring=KEYRING</option></term>
+  <listitem>
+<para>Download signatures for retrieved Release files and check them against
+<emphasis remap='I'>KEYRING</emphasis>.
+By default, Release file signatures are not checked.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--verbose</option></term>
+  <listitem>
+<para>Produce more info about downloading.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--print-debs</option></term>
+  <listitem>
+<para>Print the packages to be installed, and exit. Note that a TARGET directory
+must be specified so debootstrap can download Packages files to determine
+which packages should be installed, and to resolve dependencies. The TARGET
+directory will be deleted unless --keep-debootstrap-dir is specified.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--download-only</option></term>
+  <listitem>
+<para>Download packages, but don't perform installation</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--foreign</option></term>
+  <listitem>
+<para>Do the initial unpack phase of bootstrapping only, for example if the
+target architecture does not match the host architecture. A copy of
+debootstrap sufficient for completing the bootstrap process will be
+installed as /debootstrap/debootstrap in the target filesystem.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--second-stage</option></term>
+  <listitem>
+<para>Complete the bootstrapping process. Other arguments are generally not
+needed.</para>
+
+  </listitem>
+  </varlistentry>
+
+  <varlistentry>
+  <term><option>--second-stage-target</option><replaceable> DIR</replaceable></term>
+  <listitem>
+  <para>Usually, <filename>debootstrap</filename> <option>--second-stage</option>
+  is intended to install the Debian system onto a new device as the new
+  filesystem. <option>--second-stage-target</option> provides a method to
+  test such an installation in a chroot on the device (which should already be
+  running some form of GNU/Linux capable of using such a chroot). Note that the
+  <emphasis role="bold">suite script will need modification</emphasis> in
+  most (all?) cases to ensure that commands are executed within the
+  chroot.
+  </para>
+  </listitem>
+  </varlistentry>
+
+  <varlistentry>
+  <term><option>--keep-debootstrap-dir</option></term>
+  <listitem>
+<para>Don't delete the /debootstrap directory in the target after completing the
+installation.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--unpack-tarball FILE</option></term>
+  <listitem>
+<para>Acquire .debs from tarball FILE instead of downloading via http</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--make-tarball FILE</option></term>
+  <listitem>
+<para>Instead of bootstrapping, make a tarball (written to FILE) of the downloaded
+packages.
+The resulting tarball may be passed to a later
+<option>--unpack-tarball</option>.</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--boot-floppies</option></term>
+  <listitem>
+<para>Used for internal purposes by boot-floppies</para>
+
+  </listitem>
+  </varlistentry>
+  <varlistentry>
+  <term><option>--debian-installer</option></term>
+  <listitem>
+<para>Used for internal purposes by the debian-installer</para>
+
+  </listitem>
+  </varlistentry>
+</variablelist>
+</refsect1>
+
+<refsect1 id='example'><title>EXAMPLE</title>
+
+
+<para>To setup a <emphasis remap='I'>sarge</emphasis> system:</para>
+
+<para># debootstrap sarge ./sarge-chroot <ulink url='http://ftp.debian.org/debian'>http://ftp.debian.org/debian</ulink></para>
+
+<para># debootstrap sarge ./sarge-chroot file:///PATH_TO_LOCAL_MIRROR/debian</para>
+
+<para>Full process to create a complete Debian installation of <emphasis remap='I'>sid</emphasis> (unstable):</para>
+
+<programlisting> main # cd / ; mkdir /sid-root
+ main # debootstrap sid /sid-root <ulink url='http://ftp.debian.org/debian/'>http://ftp.debian.org/debian/</ulink>
+[ ... watch it download the whole system ]
+ main # echo "proc /sid-root/proc proc none 0 0" &gt;&gt; /etc/fstab
+ main # mount proc /sid-root/proc -t proc
+ main # cp /etc/hosts /sid-root/etc/hosts
+ main # chroot /sid-root /bin/bash
+ chroot # dselect
+[ you may use aptitude, install mc and vim ... ]
+ main # echo "8:23:respawn:/usr/sbin/chroot /sid-root " \
+      "/sbin/getty 38400 tty8"  &gt;&gt; /etc/inittab
+[ define a login tty that will use this system ]
+ main # init q
+[ reload init ]
+</programlisting>
+
+<para>Note that you will generally need a recent version of debootstrap to
+do this; the version currently in stable will generally have stopped
+working due to changes to unstable shortly after the last release.</para>
+</refsect1>
+
+<refsect1 id='author'><title>AUTHOR</title>
+<para><command>debootstrap</command>
+was written by Anthony Towns &lt;ajt@debian.org&gt;.
+This manpage was written by Matt Kraai &lt;kraai@debian.org&gt;.</para>
+</refsect1>
+</refentry>
+
--- debootstrap.old/debootstrap.8 
+++ debootstrap-1.0.3/debootstrap.8 
@@ -1,147 +1,187 @@
-.TH DEBOOTSTRAP 8 2001-04-27 "Debian Project" "Debian GNU/Linux manual"
-.SH NAME
-debootstrap \- Bootstrap a basic Debian system
-.SH SYNOPSIS
-.B debootstrap
-.RB [ OPTION\&.\&.\&. ]
-.I SUITE TARGET
-.RI [ MIRROR
-.RI [ SCRIPT ]]
-
-.B debootstrap
-.RB [ OPTION\&.\&.\&. ]
-\-\-second\-stage
-.SH DESCRIPTION
-.B debootstrap
+.\"     Title: DEBOOTSTRAP
+.\"    Author: 
+.\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
+.\"      Date: 2001-04-27
+.\"    Manual: Debian GNU/Linux manual
+.\"    Source: Debian Project
+.\"
+.TH "DEBOOTSTRAP" "8" "2001\-04\-27" "Debian Project" "Debian GNU/Linux manual"
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
+.SH "NAME"
+debootstrap - Bootstrap a basic Debian system
+.SH "SYNOPSIS"
+.HP 12
+\fBdebootstrap\fR [\fIOPTION\fR...] \fISUITE\fR \fITARGET\fR [\fIMIRROR\fR\ [\fISCRIPT\fR]]
+.HP 12
+\fBdebootstrap\fR [\fIOPTION\fR...] \-\-second\-stage
+.SH "DESCRIPTION"
+.PP
+\fBdebootstrap\fR
 bootstraps a basic Debian system of
-.I SUITE
+\fISUITE\fR
 (eg, sarge, etch, lenny, sid) into
-.I TARGET
+\fITARGET\fR
 from
-.I MIRROR
+\fIMIRROR\fR
 by running
-.IR SCRIPT .
-.I MIRROR
-can be an http:// URL or a file:/// URL. Notice that file:/ URLs are
-translated to file:/// (correct scheme as described in RFC1738 for local filenames),
-and file:// will \fBnot\fR work.
+\fISCRIPT\fR\.
+\fIMIRROR\fR
+can be an http:// URL or a file:/// URL\. Notice that file:/ URLs are translated to file:/// (correct scheme as described in RFC1738 for local filenames), and file:// will
+\fBnot\fR
+work\.
 .PP
-\fBDebootstrap\fR can be used to install Debian in a system without using an
-installation disk but can also be used to run a different Debian flavor in a \fBchroot\fR
-environment. This way you can create a full (minimal) Debian installation which
-can be used for testing purposes (see the \fBEXAMPLES\fR section). 
-If you are looking for a chroot system to build packages please take a look at 
-\fBpbuilder\fR.
+\fBDebootstrap\fR
+can be used to install Debian in a system without using an installation disk but can also be used to run a different Debian flavor in a
+\fBchroot\fR
+environment\. This way you can create a full (minimal) Debian installation which can be used for testing purposes (see the
+\fBEXAMPLES\fR
+section)\. If you are looking for a chroot system to build packages please take a look at
+\fBpbuilder\fR\.
 .SH "OPTIONS"
 .PP
-.IP "\fB\-\-arch ARCH\fP"
-Set the target architecture (use if dpkg isn't installed). See also \-\-foreign.
-.IP
-.IP "\fB\-\-include=alpha,beta\fP"
-Comma separated list of packages which will be added to download and extract
-lists.
-.IP
-.IP "\fB\-\-exclude=alpha,beta\fP"
-Comma separated list of packages which will be removed from download and
-extract lists. WARNING: you can and probably will exclude essential packages, be
-careful using this option.
-.IP
-.IP "\fB\-\-components=alpha,beta\fP"
-Use packages from the listed components of the archive.
-.IP
-.IP "\fB\-\-no\-resolve\-deps\fP"
-By default, debootstrap will attempt to automatically resolve any missing
-dependencies, warning if any are found. Note that this is not a complete
-dependency resolve in the sense of dpkg or apt, and that it is far better
-to specify the entire base system than rely on this option. With this
-option set, this behaviour is disabled.
-.IP
-.IP "\fB\-\-variant=buildd|fakechroot\fP"
-Name of the bootstrap script variant to use.  Currently, the variant
-supported are buildd, which installs the build-essential packages into
-.IR TARGET
-and fakechroot, which installs the packages without root privileges.
-The default, with no \fB\-\-variant=X\fP argument, is to create a base
-Debian installation in
-.IR TARGET .
-.IP
-.IP "\fB\-\-keyring=KEYRING\fP"
+\fB\-\-arch ARCH\fR
+.RS 4
+Set the target architecture (use if dpkg isn\'t installed)\. See also \-\-foreign\.
+.RE
+.PP
+\fB\-\-include=alpha,beta\fR
+.RS 4
+Comma separated list of packages which will be added to download and extract lists\.
+.RE
+.PP
+\fB\-\-exclude=alpha,beta\fR
+.RS 4
+Comma separated list of packages which will be removed from download and extract lists\. WARNING: you can and probably will exclude essential packages, be careful using this option\.
+.RE
+.PP
+\fB\-\-components=alpha,beta\fR
+.RS 4
+Use packages from the listed components of the archive\.
+.RE
+.PP
+\fB\-\-no\-resolve\-deps\fR
+.RS 4
+By default, debootstrap will attempt to automatically resolve any missing dependencies, warning if any are found\. Note that this is not a complete dependency resolve in the sense of dpkg or apt, and that it is far better to specify the entire base system than rely on this option\. With this option set, this behaviour is disabled\.
+.RE
+.PP
+\fB\-\-variant=buildd|fakechroot\fR
+.RS 4
+Name of the bootstrap script variant to use\. Currently, the variant supported are buildd, which installs the build\-essential packages into
+\fITARGET\fR
+and fakechroot, which installs the packages without root privileges\. The default, with no
+\fB\-\-variant=X\fR
+argument, is to create a base Debian installation in
+\fITARGET\fR\.
+.RE
+.PP
+\fB\-\-keyring=KEYRING\fR
+.RS 4
 Download signatures for retrieved Release files and check them against
-.IR KEYRING .
-By default, Release file signatures are not checked.
-.IP
-.IP "\fB\-\-verbose\fP"
-Produce more info about downloading.
-.IP
-.IP "\fB\-\-print\-debs\fP"
-Print the packages to be installed, and exit. Note that a TARGET directory
-must be specified so debootstrap can download Packages files to determine
-which packages should be installed, and to resolve dependencies. The TARGET
-directory will be deleted unless \-\-keep\-debootstrap\-dir is specified.
-.IP
-.IP "\fB\-\-download\-only\fP"
-Download packages, but don't perform installation
-.IP
-.IP "\fB\-\-foreign\fP"
-Do the initial unpack phase of bootstrapping only, for example if the
-target architecture does not match the host architecture. A copy of
-debootstrap sufficient for completing the bootstrap process will be
-installed as /debootstrap/debootstrap in the target filesystem.
-.IP
-.IP "\fB\-\-second\-stage\fP"
-Complete the bootstrapping process. Other arguments are generally not
-needed.
-.IP
-.IP "\fB\-\-keep\-debootstrap\-dir\fP"
-Don't delete the /debootstrap directory in the target after completing the
-installation.
-.IP
-.IP "\fB\-\-unpack\-tarball FILE\fP"
-Acquire .debs from tarball FILE instead of downloading via http
-.IP
-.IP "\fB\-\-make\-tarball FILE\fP"
-Instead of bootstrapping, make a tarball (written to FILE) of the downloaded
-packages.
-The resulting tarball may be passed to a later
-.BR \-\-unpack\-tarball .
-.IP
-.IP "\fB\-\-boot\-floppies\fP"
-Used for internal purposes by boot-floppies
-.IP
-.IP "\fB\-\-debian\-installer\fP"
-Used for internal purposes by the debian-installer
-.IP 
+\fIKEYRING\fR\. By default, Release file signatures are not checked\.
+.RE
+.PP
+\fB\-\-verbose\fR
+.RS 4
+Produce more info about downloading\.
+.RE
+.PP
+\fB\-\-print\-debs\fR
+.RS 4
+Print the packages to be installed, and exit\. Note that a TARGET directory must be specified so debootstrap can download Packages files to determine which packages should be installed, and to resolve dependencies\. The TARGET directory will be deleted unless \-\-keep\-debootstrap\-dir is specified\.
+.RE
+.PP
+\fB\-\-download\-only\fR
+.RS 4
+Download packages, but don\'t perform installation
+.RE
+.PP
+\fB\-\-foreign\fR
+.RS 4
+Do the initial unpack phase of bootstrapping only, for example if the target architecture does not match the host architecture\. A copy of debootstrap sufficient for completing the bootstrap process will be installed as /debootstrap/debootstrap in the target filesystem\.
+.RE
+.PP
+\fB\-\-second\-stage\fR
+.RS 4
+Complete the bootstrapping process\. Other arguments are generally not needed\.
+.RE
+.PP
+\fB\-\-second\-stage\-target\fR\fI DIR\fR
+.RS 4
+Usually,
+\fIdebootstrap\fR
+\fB\-\-second\-stage\fR
+is intended to install the Debian system onto a new device as the new filesystem\.
+\fB\-\-second\-stage\-target\fR
+provides a method to test such an installation in a chroot on the device (which should already be running some form of GNU/Linux capable of using such a chroot)\. Note that the
+\fBsuite script will need modification\fR
+in most (all?) cases to ensure that commands are executed within the chroot\.
+.RE
+.PP
+\fB\-\-keep\-debootstrap\-dir\fR
+.RS 4
+Don\'t delete the /debootstrap directory in the target after completing the installation\.
+.RE
+.PP
+\fB\-\-unpack\-tarball FILE\fR
+.RS 4
+Acquire \.debs from tarball FILE instead of downloading via http
+.RE
+.PP
+\fB\-\-make\-tarball FILE\fR
+.RS 4
+Instead of bootstrapping, make a tarball (written to FILE) of the downloaded packages\. The resulting tarball may be passed to a later
+\fB\-\-unpack\-tarball\fR\.
+.RE
+.PP
+\fB\-\-boot\-floppies\fR
+.RS 4
+Used for internal purposes by boot\-floppies
+.RE
+.PP
+\fB\-\-debian\-installer\fR
+.RS 4
+Used for internal purposes by the debian\-installer
+.RE
 .SH "EXAMPLE"
-.
-.PP 
-To setup a \fIsarge\fR system:
-.PP 
-# debootstrap sarge ./sarge-chroot http://ftp.debian.org/debian
 .PP
-# debootstrap sarge ./sarge-chroot file:///PATH_TO_LOCAL_MIRROR/debian
+To setup a
+\fIsarge\fR
+system:
 .PP
-Full process to create a complete Debian installation of \fIsid\fR (unstable):
+# debootstrap sarge \./sarge\-chroot
+\fIhttp://ftp\.debian\.org/debian\fR
 .PP
-     main # cd / ; mkdir /sid-root
-     main # debootstrap sid /sid-root http://ftp.debian.org/debian/
-     [ ... watch it download the whole system ]
-     main # echo "proc /sid-root/proc proc none 0 0" >> /etc/fstab
-     main # mount proc /sid-root/proc -t proc
-     main # cp /etc/hosts /sid-root/etc/hosts
-     main # chroot /sid-root /bin/bash
-     chroot # dselect  
-     [ you may use aptitude, install mc and vim ... ]
-      main # echo "8:23:respawn:/usr/sbin/chroot /sid-root " \\
-             "/sbin/getty 38400 tty8"  >> /etc/inittab
-     [ define a login tty that will use this system ]
-      main # init q    
-     [ reload init ]
+# debootstrap sarge \./sarge\-chroot file:///PATH_TO_LOCAL_MIRROR/debian
 .PP
-Note that you will generally need a recent version of debootstrap to
-do this; the version currently in stable will generally have stopped
-working due to changes to unstable shortly after the last release.
-.SH AUTHOR
-.B debootstrap
-was written by Anthony Towns <ajt@debian.org>.
-This manpage was written by Matt Kraai <kraai@debian.org>.
+Full process to create a complete Debian installation of
+\fIsid\fR
+(unstable):
+.sp
+.RS 4
+.nf
+ main # cd / ; mkdir /sid\-root
+ main # debootstrap sid /sid\-root \fIhttp://ftp\.debian\.org/debian/\fR
+[ \.\.\. watch it download the whole system ]
+ main # echo "proc /sid\-root/proc proc none 0 0" >> /etc/fstab
+ main # mount proc /sid\-root/proc \-t proc
+ main # cp /etc/hosts /sid\-root/etc/hosts
+ main # chroot /sid\-root /bin/bash
+ chroot # dselect
+[ you may use aptitude, install mc and vim \.\.\. ]
+ main # echo "8:23:respawn:/usr/sbin/chroot /sid\-root " \e
+      "/sbin/getty 38400 tty8"  >> /etc/inittab
+[ define a login tty that will use this system ]
+ main # init q
+[ reload init ]
+.fi
+.RE
+.PP
+Note that you will generally need a recent version of debootstrap to do this; the version currently in stable will generally have stopped working due to changes to unstable shortly after the last release\.
+.SH "AUTHOR"
+.PP
+\fBdebootstrap\fR
+was written by Anthony Towns <ajt@debian\.org>\. This manpage was written by Matt Kraai <kraai@debian\.org>\.
 

Attachment: pgpsRNatnUYtA.pgp
Description: PGP signature


Reply to: