1deb(5) Debian deb(5)
2
3
4
6 deb - Debian binary package format
7
9 filename.deb
10
12 The .deb format is the Debian binary package file format. It is under‐
13 stood by dpkg 0.93.76 and later, and is generated by default by all
14 versions of dpkg since 1.2.0 and all i386/ELF versions since 1.1.1elf.
15
16 The format described here is used since Debian 0.93; details of the old
17 format are described in deb-old(5).
18
20 The file is an ar archive with a magic value of !<arch>. The file
21 names might contain a trailing slash.
22
23 The tar archives currently allowed are, the old-style (v7) format, the
24 pre-POSIX ustar format, a subset of the GNU format (only the new style
25 long pathnames and long linknames, supported since dpkg 1.4.1.17), and
26 the POSIX ustar format (long names supported since dpkg 1.15.0).
27 Unrecognized tar typeflags are considered an error.
28
29 The first member is named debian-binary and contains a series of lines,
30 separated by newlines. Currently only one line is present, the format
31 version number, 2.0 at the time this manual page was written. Programs
32 which read new-format archives should be prepared for the minor number
33 to be increased and new lines to be present, and should ignore these if
34 this is the case.
35
36 If the major number has changed, an incompatible change has been made
37 and the program should stop. If it has not, then the program should be
38 able to safely continue, unless it encounters an unexpected member in
39 the archive (except at the end), as described below.
40
41 The second required member is named control.tar.gz. It is a gzipped
42 tar archive containing the package control information, as a series of
43 plain files, of which the file control is mandatory and contains the
44 core control information. The control tarball may optionally contain an
45 entry for `.', the current directory.
46
47 The third, last required member is named data.tar. It contains the
48 filesystem as a tar archive, either not compressed (supported since
49 dpkg 1.10.24), or compressed with gzip (with .gz extension), bzip2
50 (with .bz2 extension, supported since dpkg 1.10.24) or lzma (with .lzma
51 extension, supported since dpkg 1.13.25).
52
53 These members must occur in this exact order. Current implementations
54 should ignore any additional members after data.tar. Further members
55 may be defined in the future, and (if possible) will be placed after
56 these three. Any additional members that may need to be inserted before
57 data.tar and which should be safely ignored by older programs, will
58 have names starting with an underscore, `_'.
59
60 Those new members which won't be able to be safely ignored will be
61 inserted before data.tar with names starting with something other than
62 underscores, or will (more likely) cause the major version number to be
63 increased.
64
66 deb-old(5), dpkg-deb(1), deb-control(5).
67
68
69
70Debian Project 2009-02-27 deb(5)