aboutsummaryrefslogtreecommitdiff
path: root/pbuilder.8
blob: b37813c1f7e44d1cb00cd186b44dc0b6784617ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
.TH "pbuilder" 8 "2001 Aug 25" "Debian" "pbuilder"
.SH NAME
pbuilder \- personal package builder
.SH SYNOPSIS
.BI "pbuilder create [" "options" "]"
.PP
.BI "pbuilder update [" "options" "]"
.PP
.BI "pbuilder build [" "options" "] " ".dsc-file"
.PP
.BI "pbuilder clean"
.PP
.BI "pbuilder login"
.SH DESCRIPTION
Front end program to the 
.B "pbuilder"
suite of programs, used for creating and maintaining chroot environment 
and building Debian package in the chroot environment.
.SH OPTIONS
.TP
.B "create"
Creates a 
.B "base.tgz" 
for the specified distribution.

.TP
.B "update"
Updates the 
.B "base.tgz"
for the specified distribution.
Also, by specifying the 
.B "--distribution"
option, it is possible to switch the distribution.
Specify a dummy distribution value 
even for custom apt config files.

.TP
.B "build"
Builds the package specified by
.I ".dsc-file"
in the chroot environment created using the 
.B "base.tgz"

.TP
.B "clean"
Cleans up the directory specified by the configuration
.B "BUILDPLACE"
and
.B "APTCACHE"
specified in 
.I "/etc/pbuilderrc"

.TP
.B "login"
Logs into the chroot, and cleaned up afterwards.
Any changes you make will not be kept.

.TP
.B "debuild"
Builds a Debian package from the Debian source directory.
There needs to be a 
.I "debian/"
directory in the current directory.

This command is a convenience script, 
and it does not accept most command-line options.
This may change in the future.

.TP
.BI "--basetgz [" "basetgz-location" "]"
Specifies the location of 
.B "base.tgz"

This option will define the default distribution and 
apt-lines when used in
.B "pbuilder update"
and 
.B "pbuilder create"

.TP
.BI "--buildplace [" "location of build" "]"
Specifies the location where building and 
.B "base.tgz"
updating and creation takes place. This is 
a temporary work directory.
.TP
.BI "--buildresult [" "location to put build result" "]"
Specifies the location the build result gets into after building.
The deb files and other files that have resulted from build 
is copied there.
Note that the default value is not the current directory,
or 
.B ".."
but somewhere else entirely. This is to avoid
overwriting already existing deb files with
the newly generated ones.

.TP
.BI "--mirror [" "mirror location" "]"
Specifies the url of Debian mirror to be 
specified in 
.B "sources.list"
inside the chroot.
This option is only valid when distribution is being specified, for 
update and build targets.
The format is something like:
.I "http://http.us.debian.org/debian" 
which should point to your favorite mirror.

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 
.B "file:/somewhere/"
will most probably fail.

.TP
.BI "--nonusmirror [" "mirror location" "]"
The non-US mirror, specified like the 
.B "--mirror"
option
.TP
.BI "--othermirror [" "apt deb line " "|" " other deb lines... " "]"
The lines which is added to the sources.list, delimited with 
.B "|"
Like 
.B "deb http://local/mirror stable main|deb file:/usr/local/mirror ./"

The deb lines here are the ones that will appear at the top of the 
.B sources.list
inside the chroot.

.TP
.BI "--http-proxy [" "proxy" "]"
Specifies the http proxy url. Something like
.B "http://xxx.xxx.xxx.xxx:8080/"
should do. 
.TP
.BI "--distribution [" "distribution" "]"
Specifies the distribution used. Currently the supported values are
.B "sid"
and 
.B "woody".
.TP
.BI "--removepackages [" "packages to remove" "]"
Removes the packages on creating the 
.BI "base.tgz" "."
Use this option to remove potentially dangerous or undesirable
packages, like
.B "lilo"
which nobody will need to have inside a chroot.

Packages should be specified in a space-delimited manner, 
surrounded in double quotations, like 
.B """lilo gcc mawk"""

.TP
.BI "--extrapackages [" "packages to add" "]"
Adds packages specified as an addition to the default,
which is 
.B build-essential
by default.
This is used in 
.B "build"
and 
.B "create"
and 
.B "update"

The packages should be specified as a space-delimited list.

.TP
.BI "--configfile [" "configuration file to load" "]"
Loads the configuration file.


\" START OF hookdir description

.TP
.BI "--hookdir [" "location of user scripts" "]"
Specifies the location where scripts for user intervention during
the create and update process are stored. Currently scripts are
executed at only one point, on exit from the chrooted environment,
just before either a create or a build regenerated the base.tgz
file. The script names must be in the form 
.B "X<digit><digit><whatever-else-you-want>"
much like boot scripts. The scripts must be executable and may
be either binaries or interpreted scripts. If it is a script
in other than Bourne Shell or Perl, it is up to the user to
ensure the interpreter was previously installed in the chrooted
environment. Files ending in ~ or .bak are ignored.

Although it may not seem necessary, 
.B "pbuilder update" 
does not invoke the hooks if 
.B "--hookdir"
is empty, so if you want to avoid running hooks,
run pbuilder with
.B "--hookdir """""

If there is a distribution hook, for example, if 
there was a file 
.B "sid"
inside the hook directory, and the script was creating the 
chroot for
.B "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.

.B "A<digit><digit><whatever-else-you-want>"
is for 
.B build 
target. 
It is executed before build starts, after
unpacking the build system, and unpacking the source.

.B "B<digit><digit><whatever-else-you-want>"
is executed after build system finishes building,
successfully, before copying back the build result.

.B "C<digit><digit><whatever-else-you-want>"
is executed after build fails, before cleanup.

.B "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.



\" End of hookdir description

.TP
.BI "--debemail [" "email-address" "]"

Specifies that dpkg-buildpackage be called with
.B "-m$DEBEMAIL"
instead of default value specified in the environmental
variable, or pbuilderrc

.B "This option is almost obsolete, use --debbuildopts instead"

.TP
.BI "--debbuildopts [" "options" "]"

List of options that are passed on to dpkg-buildpackage. Overrides
any value given in DEBBUILDOPTS as specified in
pbuilderrc.

.TP
.BI "--logfile [" "file to log" "]"
Specifies the logfile to create. 
The messages generated during execution will be written to the file, 
instead of messages coming to the 
standard output.

.TP
.BI "--aptconfdir [" "APT configuration directory to use" "]"
Uses the apt configuration file found in the specified directory 
as the chroot configuration.
.B "/etc/apt"
is one example, so that  the same configuration can be used inside the
chroot.

This option overrides other options, and may cause some inconsistency
problems.

.TP
.BI "--timeout [" "timeout in sleep time" "]"
Time out building after sleeping set time.
Specify something like
.B "--timeout 10h"
in the command line.
Default is no timeout.

.SH "FILES"
.TP
.I "/etc/pbuilderrc"
The system-wide configuration file for pbuilder.
.TP
.I "/usr/share/pbuilder/pbuilderrc"
The default settings for pbuilder, used as fallback for all 
values that is not specified in
.B "/etc/pbuilderrc."
.TP
.I "${HOME}/.pbuilderrc"
The personal configuration file for pbuilder.
.SH BUGS
This program is starting to have too many options already.
.SH AUTHOR
Initial coding, and main maintenance is done by 
Junichi Uekawa <dancer@debian.org>.
User hooks code added by Dale Amon <amon@vnl.com>
.SH "SEE ALSO"
.RI "pdebuild (" 1 "), "
.RI "pbuilderrc (" 5 ") "