chiark / gitweb /
awful debugging hacking
[dpkg] / man / dpkg-split.man
1 .\" dpkg manual page - dpkg-split(1)
2 .\"
3 .\" Copyright © 1995-1996 Ian Jackson <ijackson@chiark.greenend.org.uk>
4 .\" Copyright © 2011 Guillem Jover <guillem@debian.org>
5 .\"
6 .\" This is free software; you can redistribute it and/or modify
7 .\" it under the terms of the GNU General Public License as published by
8 .\" the Free Software Foundation; either version 2 of the License, or
9 .\" (at your option) any later version.
10 .\"
11 .\" This is distributed in the hope that it will be useful,
12 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
13 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 .\" GNU General Public License for more details.
15 .\"
16 .\" You should have received a copy of the GNU General Public License
17 .\" along with this program.  If not, see <https://www.gnu.org/licenses/>.
18 .
19 .TH dpkg\-split 1 "%RELEASE_DATE%" "%VERSION%" "dpkg suite"
20 .nh
21 .SH NAME
22 dpkg\-split \- Debian package archive split/join tool
23 .
24 .SH SYNOPSIS
25 .B dpkg\-split
26 .RI [ option "...] " command
27 .
28 .SH DESCRIPTION
29 .B dpkg\-split
30 splits Debian binary package files into smaller parts and reassembles
31 them again, to support the storage of large package files on small
32 media such as floppy disks.
33
34 It can be operated manually using the
35 .BR \-\-split ", " \-\-join " and " \-\-info
36 options.
37
38 It also has an automatic mode, invoked using the
39 .B \-\-auto
40 option, where it maintains a queue of parts seen but not yet
41 reassembled and reassembles a package file when it has seen all of its
42 parts. The
43 .BR \-\-listq " and " \-\-discard
44 options allow the management of the queue.
45
46 All splitting, joining and queueing operations produce informative
47 messages on standard output; these may safely be ignored.
48 .
49 .SH COMMANDS
50 .TP
51 .BR \-s ", " \-\-split " \fIcomplete-archive\fP [\fIprefix\fP]"
52 Splits a single Debian binary package into several parts.
53
54 The parts are named
55 .IB prefix . N of M .deb
56 where
57 .I N
58 is the part number, starting at 1, and
59 .I M
60 is the total number of parts (both in decimal).
61
62 If no
63 .I prefix
64 is supplied then the
65 .I complete-archive
66 filename is taken, including directory, with any trailing
67 .B .deb
68 removed.
69 .TP
70 .BR \-j ", " \-\-join " \fIpart\fP..."
71 Joins the parts of a package file together, reassembling the original
72 file as it was before it was split.
73
74 The part files given as arguments must be all the parts of exactly the
75 same original binary file. Each part must occur exactly once in the
76 argument list, though the parts to not need to be listed in order.
77
78 The parts must of course all have been generated with the same part
79 size specified at split time, which means that they must usually have
80 been generated by the same invocation of
81 .BR "dpkg\-split \-\-split" .
82
83 The parts' filenames are not significant for the reassembly process.
84
85 By default the output file is called
86 .IB package _ version _ arch .deb\fR.
87
88 .TP
89 .BR \-I ", " \-\-info " \fIpart\fP..."
90 Prints information, in a human-readable format, about the part file(s)
91 specified. Arguments which are not binary package parts produce a
92 message saying so instead (but still on standard output).
93 .TP
94 .BR \-a ", " "\-\-auto \-o" " \fIcomplete-output part\fP"
95 Automatically queue parts and reassemble a package if possible.
96
97 The
98 .I part
99 specified is examined, and compared with other parts of the same
100 package (if any) in the queue of packages file parts.
101
102 If all parts of the package file of which
103 .I part
104 is a part are available then the package is reassembled and written to
105 .I complete-output
106 (which should not usually already exist, though this is not an
107 error).
108
109 If not then the
110 .I part
111 is copied into the queue and
112 .I complete-output
113 is not created.
114
115 If
116 .I part
117 is not a split binary package part then
118 .B dpkg\-split
119 will exit with status \fB1\fP; if some other trouble occurs then it will
120 exit with status \fB2\fP.
121
122 The
123 .BR \-\-output " or " \-o
124 option must be supplied when using
125 .BR \-\-auto .
126 (If this were not mandatory the calling program would not know what
127 output file to expect.)
128 .TP
129 .BR \-l ", " \-\-listq
130 Lists the contents of the queue of packages to be reassembled.
131
132 For each package file of which parts are in the queue the output gives
133 the name of the package, the parts in the queue, and the total number
134 of bytes stored in the queue.
135 .TP
136 .BR \-d ", " \-\-discard " [\fIpackage\fP...]"
137 This discards parts from the queue of those waiting for the remaining
138 parts of their packages.
139
140 If no
141 .I package
142 is specified then the queue is cleared completely; if any are
143 specified then only parts of the relevant package(s) are deleted.
144 .TP
145 .BR \-? ", " \-\-help
146 Show the usage message and exit.
147 .TP
148 .BR \-\-version
149 Show the version and exit.
150 .
151 .SH OPTIONS
152 .TP
153 .BI \-\-depotdir " directory"
154 Specifies an alternative directory for the queue of parts awaiting
155 automatic reassembly. The default is
156 .BR %ADMINDIR% .
157 .TP
158 .BR \-S ", " \-\-partsize " \fIkibibytes\fP"
159 Specifies the maximum part size when splitting, in kibibytes (1024
160 bytes). The default is 450 KiB.
161 .TP
162 .BR \-o ", " \-\-output " \fIcomplete-output\fP"
163 Specifies the output file name for a reassembly.
164
165 This overrides the default for a manual reassembly
166 .RB ( \-\-join )
167 and is mandatory for an automatic queue-or-reassemble
168 .RB ( \-\-auto ).
169 .TP
170 .BR \-Q ", " \-\-npquiet
171 When doing automatic queue-or-reassembly
172 .B dpkg\-split
173 usually prints a message if it is given a
174 .I part
175 that is not a binary package part. This option suppresses this
176 message, to allow programs such as
177 .B dpkg
178 to cope with both split and unsplit packages without producing
179 spurious messages.
180 .TP
181 .BR \-\-msdos
182 Forces the output filenames generated by
183 .B \-\-split
184 to be msdos-compatible.
185
186 This mangles the prefix - either the default derived from the input
187 filename or the one supplied as an argument: alphanumerics are
188 lowercased, plus signs are replaced by
189 .BR x 's
190 and all other characters are discarded.
191
192 The result is then truncated as much as is necessary, and filenames of
193 the form
194 .IB "prefixN" of M .deb
195 are generated.
196 .
197 .SH EXIT STATUS
198 .TP
199 .B 0
200 The requested split, merge, or other command succeeded.
201 .B \-\-info
202 commands count as successful even if the files are not binary package
203 parts.
204 .TP
205 .B 1
206 Only occurs with
207 .B \-\-auto
208 and indicates that the
209 .I part
210 file was not a binary package part.
211 .TP
212 .B 2
213 Fatal or unrecoverable error due to invalid command-line usage,
214 a file that looked like a package part file but was corrupted, or
215 interactions with the system, such as accesses to the database,
216 memory allocations, etc.
217 .
218 .SH ENVIRONMENT
219 .TP
220 .B SOURCE_DATE_EPOCH
221 If set, it will be used as the timestamp (as seconds since the epoch) in
222 the \fBdeb\-split\fP(5)'s \fBar\fP(5) container.
223 .
224 .SH FILES
225 .TP
226 .I %ADMINDIR%/parts
227 The default queue directory for part files awaiting automatic
228 reassembly.
229
230 The filenames used in this directory are in a format internal to
231 .B dpkg\-split
232 and are unlikely to be useful to other programs, and in any case the
233 filename format should not be relied upon.
234 .
235 .SH BUGS
236 Full details of the packages in the queue are impossible to get
237 without digging into the queue directory yourself.
238
239 There is no easy way to test whether a file that may be a binary
240 package part is one.
241 .
242 .SH SEE ALSO
243 .BR deb (5),
244 .BR deb\-control (5),
245 .BR dpkg\-deb (1),
246 .BR dpkg (1).