dpkg (1.18.25) stretch; urgency=medium
[dpkg] / man / dpkg-scanpackages.man
CommitLineData
1479465f
GJ
1.\" dpkg manual page - dpkg-scanpackages(1)
2.\"
3.\" Copyright © 1996 Michael Shields <shields@crosslink.net>
4.\" Copyright © 2006 Frank Lichtenheld <djpig@debian.org>
5.\" Copyright © 2007, 2009, 2011-2014 Guillem Jover <guillem@debian.org>
6.\" Copyright © 2009 Raphaël Hertzog <hertzog@debian.org>
7.\"
8.\" This is free software; you can redistribute it and/or modify
9.\" it under the terms of the GNU General Public License as published by
10.\" the Free Software Foundation; either version 2 of the License, or
11.\" (at your option) any later version.
12.\"
13.\" This is distributed in the hope that it will be useful,
14.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
15.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16.\" GNU General Public License for more details.
17.\"
18.\" You should have received a copy of the GNU General Public License
19.\" along with this program. If not, see <https://www.gnu.org/licenses/>.
20.
21.TH dpkg\-scanpackages 1 "%RELEASE_DATE%" "%VERSION%" "dpkg suite"
22.nh
23.SH NAME
24dpkg\-scanpackages \- create Packages index files
25.
26.SH SYNOPSIS
27.B dpkg\-scanpackages
28.RI [ option "...] " binary-path
29.RI [ override-file
30.RI [ path-prefix ]]
31.B >
32.I Packages
33.
34.SH DESCRIPTION
35.B dpkg\-scanpackages
36sorts through a tree of Debian binary packages and creates a Packages
37file, used by
38.BR apt (8),
39.BR dselect (1),
40etc, to tell the user what packages are available for installation. These
41Packages files are the same as those found on Debian archive sites
42and CD-ROMs. You might use
43.B dpkg\-scanpackages
44yourself if making a directory of local packages to install on a cluster
45of machines.
46.PP
47.B Note:
48If you want to access the generated Packages file with
49.B apt
50you will probably need to compress the file with
51.BR xz (1)
52(generating a Packages.xz file),
53.BR bzip2 (1)
54(generating a Packages.bz2 file) or
55.BR gzip (1)
56(generating a Packages.gz file). apt ignores uncompressed Packages
57files except on local access (i.e.
58.B file://
59sources).
60.PP
61.I binary-path
62is the name of the tree of the binary packages to process (for example,
63.BR contrib/binary\-i386 ).
64It is best to make this relative to the root of the Debian archive,
65because every Filename field in the new Packages file will start with
66this string.
67.PP
68.I override-file
69is the name of a file to read which contains information about how the
70package fits into the distribution (the file can be compressed
71since dpkg 1.15.5); see
72.BR deb\-override (5).
73.PP
74.I path-prefix
75is an optional string to be prepended to the Filename fields.
76.PP
77If more than one version of a package is found only the newest one
78is included in the output. If they have the same version and only
79differ in architecture only the first one found is used.
80.
81.SH OPTIONS
82.TP
83.BR \-t ", " \-\-type " \fItype\fP"
84Scan for *.\fItype\fP packages, instead of *.deb.
85.TP
86.BR \-e ", " \-\-extra\-override " \fIfile\fP"
87Scan \fIfile\fP to find supplementary overrides (the file can be
88compressed since dpkg 1.15.5).
89See
90.BR deb\-extra\-override (5)
91for more information on its format.
92.TP
93.BR \-a ", " \-\-arch " \fIarch\fP"
94Use a pattern consisting of \fI*_all.deb\fP and \fI*_arch.deb\fP instead of
95scanning for all debs.
96.TP
97.BR \-h ", " \-\-hash " \fIhash-list\fP"
98Only generate file hashes for the comma-specified list specified
99(since dpkg 1.17.14).
100The default is to generate all currently supported hashes.
101Supported values: \fBmd5\fP, \fBsha1\fP, \fBsha256\fP.
102.TP
103.BR \-m ", " \-\-multiversion
104Include all found packages in the output.
105.TP
106.BR \-M ", " \-\-medium " \fIid-string\fP"
107Add an \fBX\-Medium\fP field containing the value \fIid-string\fP
108(since dpkg 1.15.5).
109This field is required if you want to generate \fBPackages.cd\fP files
110for use by the multicd access method of dselect.
111.TP
112.BR \-? ", " \-\-help
113Show the usage message and exit.
114.TP
115.BR \-\-version
116Show the version and exit.
117.
118.SH DIAGNOSTICS
119.B dpkg\-scanpackages
120outputs the usual self-explanatory errors. It also warns about packages
121that are in the wrong subdirectory, are duplicated, have a Filename
122field in their control file, are missing from the override file, or have
123maintainer substitutions which do not take effect.
124.
125.SH SEE ALSO
126.ad l
127.BR dpkg (1),
128.BR dselect (1),
129.BR deb\-override (5),
130.BR deb\-extra\-override (5),
131.BR dpkg\-scansources (1).