1MK-ORIGTARGZ(1)                                                MK-ORIGTARGZ(1)
2
3
4

NAME

6       mk-origtargz - rename upstream tarball, optionally changing the
7       compression and removing unwanted files
8

SYNOPSIS

10       mk-origtargz [options] foo-1.0.tar.gz
11       mk-origtargz --help
12

DESCRIPTION

14       mk-origtargz renames the given file to match what is expected by dpkg-
15       buildpackage, based on the source package name and version in
16       debian/changelog. It can convert zip to tar, optionally change the
17       compression scheme and remove files according to Files-Excluded and
18       Files-Excluded-component in debian/copyright. The resulting file is
19       placed in debian/../... (In debian/copyright, the Files-Excluded and
20       Files-Excluded-component stanzas are a part of the first paragraph and
21       there is a blank line before the following paragraphs which contain
22       Files and other stanzas.  See uscan(1) "COPYRIGHT FILE EXAMPLE".)
23
24       The archive type for zip is detected by "file --dereference --brief
25       --mime-type" command.  So any zip type archives such as jar are treated
26       in the same way.  The xpi archive is detected by its extension and is
27       handled properly using the xpi-unpack command.
28
29       If the package name is given via the --package option, no information
30       is read from debian/, and the result file is placed in the current
31       directory.
32
33       mk-origtargz is commonly called via uscan, which first obtains the
34       upstream tarball.
35

OPTIONS

37   Metadata options
38       The following options extend or replace information taken from debian/.
39
40       --package package
41           Use package as the name of the Debian source package, and do not
42           require or use a debian/ directory. This option can only be used
43           together with --version.
44
45           The default is to use the package name of the first entry in
46           debian/changelog.
47
48       -v, --version version
49           Use version as the version of the package. This needs to be the
50           upstream version portion of a full Debian version, i.e. no Debian
51           revision, no epoch.
52
53           The default is to use the upstream portion of the version of the
54           first entry in debian/changelog.
55
56       --exclude-file glob
57           Remove files matching the given glob from the tarball, as if it was
58           listed in Files-Excluded.
59
60       --copyright-file filename
61           Remove files matching the patterns found in filename, which should
62           have the format of a Debian copyright file (Format:
63           https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
64           to be precise). Errors parsing that file are silently ignored,
65           exactly as is the case with debian/copyright.
66
67           Unmatched patterns will emit a warning so the user can verify
68           whether it is correct.  If there are multiple patterns which match
69           a file, only the last one will count as being matched.
70
71           Both the --exclude-file and --copyright-file options amend the list
72           of patterns found in debian/copyright. If you do not want to read
73           that file, you will have to use --package.
74
75       --signature signature-mode
76           Set signature-mode:
77
78           0 for no signature
79           1 for normal detached signature
80           2 for signature on decompressed
81           3 for self signature
82       --signature-file signature-file
83           Use signature-file as the signature file corresponding to the
84           Debian source package to create a dpkg-source (post-stretch)
85           compatible signature file.  (optional)
86
87   Action options
88       These options specify what exactly mk-origtargz should do. The options
89       --copy, --rename and --symlink are mutually exclusive.
90
91       --symlink
92           Make the resulting file a symlink to the given original file. (This
93           is the default behaviour.)
94
95           If the file has to be modified (because it is a zip, or xpi file,
96           because of --repack or Files-Excluded), this option behaves like
97           --copy.
98
99       --copy
100           Make the resulting file a copy of the original file (unless it has
101           to be modified, of course).
102
103       --rename
104           Rename the original file.
105
106           If the file has to be modified (because it is a zip, or xpi file,
107           because of --repack or Files-Excluded), this implies that the
108           original file is deleted afterwards.
109
110       --repack
111           If the given file is not compressed using the desired format (see
112           --compression), recompress it.
113
114       -S, --repack-suffix suffix
115           If the file has to be modified, because of Files-Excluded, append
116           suffix to the upstream version.
117
118       --force-repack
119           Recompress even if file is compressed using the desired format and
120           no files were deleted.
121
122       -c, --component componentname
123           Use <componentname> as the component name for the secondary
124           upstream tarball.  Set componentname as the component name.  This
125           is used only for the secondary upstream tarball of the Debian
126           source package.  Then packagename_version.orig-componentname.tar.gz
127           is created.
128
129       --compression [ gzip | bzip2 | lzma | xz | default ]
130           The default method is xz. When mk-origtargz is launched in a debian
131           source repository which format is "1.0" or undefined, the method
132           switches to gzip.
133
134       -C, --directory directory
135           Put the resulting file in the given directory.
136
137       --unzipopt options
138           Add the extra options to use with the unzip command such as -a,
139           -aa, and -b.
140

SEE ALSO

142       uscan(1), uupdate(1)
143

AUTHOR

145       mk-origtargz and this manpage have been written by Joachim Breitner
146       <nomeata@debian.org>.
147
148
149
150Debian Utilities                  2020-07-27                   MK-ORIGTARGZ(1)
Impressum