pbuilder create [options]
pbuilder update [options]
pbuilder build [options] .dsc-file
pbuilder clean
pbuilder login [options]
pbuilder execute [options] -- script [script options]
pbuilder dumpconfig
pbuilder debuild [options]
Front end program to the pbuilder suite of programs, used for creating and maintaining chroot environment and building Debian package in the chroot environment.
create
update
up
u
For example, to switch the distribution of an existing base.tgz to sid, specify the --distribution sid --override-config options to update.
build
b
clean
login
l
execute
e
The file specified in the command-line argument will be copied into the chroot, and invoked.
The remaining arguments are passed on to the script.
dumpconfig
debuild
Same as pdebuild --use-pdebuild-internal
The command is followed by options of the form --option name which will modify the semantics as explained below. They are applied from left-to-right, and when there are conflicting options, the rightmost options will have effect.
This option will define the default distribution and apt-lines when used in pbuilder update and pbuilder create
A subdirectory of that directory using the current PID of the process is used.
This option can optionally be omitted, and left blank, in which case, this part is skipped.
Note that these URLs specified to pbuilder will be used from within the chroot, and specifying file:/somewhere/ will most probably fail.
The deb lines here are the ones that will appear at the top of the sources.list inside the chroot. Be sure to follow the syntax rules of sources.list(5). These lines appear at the beginning of the constructed sources file, so this is the place to list your local mirror sites; apt will then use them in preference to the ones listed in --mirror .
--distribution , --components , --mirror , --othermirror options are only valid when --override-config option is specified in update target, or when pbuilder create is being called.
Although it may not seem necessary, pbuilder --update does not invoke the hooks if --hookdir is empty, so if you want to avoid running hooks, run pbuilder with --hookdir ""
If there is a distribution hook, for example, if there was a file sid inside the hook directory, and the script was creating the chroot for sid distribution, pbuilder will call debootstrap with that as the 4th parameter in the chroot creation process. This allows for use of custom debootstrap hook script.
A<digit><digit><whatever-else-you-want> is for build target. It is executed before build starts; after unpacking the build system, and unpacking the source, and satisfying the build-dependency.
B<digit><digit><whatever-else-you-want> is executed after build system finishes building, successfully, before copying back the build result.
C<digit><digit><whatever-else-you-want> is executed after build failure, before cleanup.
D<digit><digit><whatever-else-you-want> is executed before unpacking the source inside the chroot, after setting up the chroot environment. Create $TMP, and $TMPDIR if necessary.
This is called before build-dependency is satisfied. Also useful for calling apt-get update
E<digit><digit><whatever-else-you-want>
is executed after pbuilder update
and pbuilder create finishes apt-get work with the chroot, before
umounting kernel file systems (/proc) and creating the tarball from the
chroot.
F<digit><digit><whatever-else-you-want> is executed just before user logs in, or program starts executing, after chroot is created in login or execute target.
G<digit><digit><whatever-else-you-want> is executed just after debootstrap finishes, and configuration is loaded, and pbuilder starts mounting /proc and invoking apt-get install in create target.
H<digit><digit><whatever-else-you-want> is executed just after unpacking the chroot, mounting proc and any bind mount specified in BINDMOUNTS. It's executed for every target that requires the unpacked chroot. It's useful if you want to dynamically change the chroot guts before anything starts using it.
I<digit><digit><whatever-else-you-want> is executed after build system finishes building, successfully, after copying back the build results.
In your hook the following environment variables are available:
List of options that are passed on to dpkg-buildpackage. Multiple flags are additive and are appended to the value of DEBBUILDOPTS as specified in pbuilderrc. To clear the list of options, pass the empty string, e.g. --debbuildopts "".
Multiple options are delimited with spaces, like --debbuildopts "-j100 -E"
Specify to build only architecture specific targets instead of all targets. This instructs pbuilder to respect only Build-Depends, Build-Depends-Arch, Build-Conflicts, Build-Conflicts-Arch source relationships, and calls dpkg-buildpackage with -B.
Setting --debbuildopts after this option will re-set some parts of the effects.
Use this option rather than using --debbuildopts -B.
Specify to build only architecture independent targets instead of all targets. This instructs pbuilder to respect only Build-Depends, Build-Depends-Indep, Build-Conflicts, Build-Conflicts-Indep source relationships, and calls dpkg-buildpackage with -A.
Setting --debbuildopts after this option will re-set some parts of the effect.
Use this option rather than using --debbuildopts -A.
Specify multiple options through multiple instance of this option, for example:
--debootstrapopts --arch=arm --debootstrapopts --variant=buildd
Keyrings are copied into /etc/apt/trusted.gpg.d in the chroot. APT supports it since version 0.7.25.1, firstly available in the Debian release codenamed "squeeze" (released on 2011). For older chroots, use a G hook to run apt-key manually.
Show a brief help message.
Some options are more involved to pbuilder internal than others. The following options are available.
Packages should be specified in a space-delimited manner, surrounded in double quotations, like "lilo gcc mawk"
The packages should be specified as a space-delimited list, or by specifying --extrapackages multiple times.
Specifies that dpkg-buildpackage be called with -mmaintainer-name <email-address> instead of default value specified in the environment variable, or pbuilderrc
This option is almost obsolete, use --debbuildopts instead
The file extension is specified by PKGNAME_LOGFILE_EXTENSION in pbuilderrc
This option overrides other options, and may cause some inconsistency problems.
Useful when experimenting with chroots, or trying to create chroots outside control of pbuilder.
If set to "pigz", compression and decompression is
gzip compatible but will use all available CPUs.
If set to "cat", there will be no compression at all (so
compression/decompression will be a lot faster but takes much more space
on the disk).
For preserving the build place for create and update targets, see debug option.
As with --no-targz, suppresses appending pbuilder's process ID to the --buildplace.
This is useful if you want to attempt to build a large number of packages successively, but you expect that many of them cannot have their build dependencies satisfied.
It will clean up the build place on failure, or after a successful build.
Turn on Debug mode of pbuilder, to be verbose about errors, and try to avoid cleanup processing when error happens in update and create targets.
Add extra file to be copied to BUILDDIR inside the build environment.
available in build and login and execute targets.
Note that ${HOME} is usually /root (if you are running pbuilder through sudo).
# pbuilder create
Distribution is sid.
Building the build environment
-> running debootstrap
/usr/sbin/debootstrap
I: Retrieving Release
I: Retrieving Packages
I: Validating Packages
.
.
# pbuilder update
W: /home/dancer/.pbuilderrc does not exist
Building the build Environment
-> extracting base tarball [/var/cache/pbuilder/base.tgz]
.
.
# pbuilder build dsh_*.dsc
I: using fakeroot in build.
Current time: Sat Jan 20 12:03:34 JST 2007
pbuilder-time-stamp: 1169262214
Building the build Environment
-> extracting base tarball [/home/dancer/DEBIAN/pbuilder/pbuilder/testsuite/tmp.FeeAX18779/testimage]
-> creating local configuration
.
.
This program is starting to have too many options already.
Initial coding, and main maintenance is done by Junichi Uekawa <dancer@debian.org>. User hooks code added by Dale Amon <amon@vnl.com>
The homepage is available at https://pbuilder.alioth.debian.org
/usr/share/doc/pbuilder/pbuilder-doc.html, pdebuild(1), pbuilderrc(5)