chiark / gitweb /
bc8d66b123b8da0c1f7f8adc698e05c36336a10d
[developers-reference.git] / developers-reference.sgml
1 <!doctype debiandoc system [
2 <!-- include version information so we don't have to hard code it
3      within the document -->
4 <!entity % versiondata SYSTEM "version.ent"> %versiondata;
5 ]>
6 <debiandoc>
7 <!--
8  TODO:
9   - bugs in upstream versions should be reported upstream!
10   - fill in ftp and www server discussion
11   - porter instructions - - volunteers needed for this x86-centric maintainer!
12   - talk about CVS access
13  -->
14
15   <book>
16
17       <title>Debian Developer's Reference
18       <author>Adam P. Harris, current maintainer <email/aph@debian.org/
19       <author>Christian Schwarz <email/schwarz@debian.org/
20       <author>Ian Jackson <email/ijackson@gnu.ai.mit.edu/
21       <version>version &version;, &date;
22
23       <copyright>
24 Copyright &copy;1998 Adam P. Harris.  Copyright &copy;1997,1998
25 Christian Schwarz.
26         <p>
27 This manual is free software; you may redistribute it and/or modify it
28 under the terms of the GNU General Public License as published by the
29 Free Software Foundation; either version 2, or (at your option) any
30 later version.
31         <p>
32 This is distributed in the hope that it will be useful, but
33 <em>without any warranty</em>; without even the implied warranty of
34 merchantability or fitness for a particular purpose.  See the GNU
35 General Public License for more details.
36         <p>
37 A copy of the GNU General Public License is available as
38 <tt>/usr/doc/copyright/GPL</tt> in the Debian GNU/Linux distribution
39 or on the World Wide Web at <url
40 id="http://www.gnu.org/copyleft/gpl.html" name="the GNU website">.
41 You can also obtain it by writing to the Free Software Foundation,
42 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
43
44     <toc sect>
45
46     <chapt id="scope">Scope of This Document
47       <p>
48 The purpose of this document is to provide an overview of the
49 processes and resources used by Debian developers.
50       <p>
51 The processes discussed within include how to become a maintainer
52 (<ref id="new-maintainer">); how to upload new packages (<ref
53 id="upload">); how and when to do interim releases of other
54 maintainer's packages (<ref id="nmu">); how to move, remove, or orphan
55 packages (<ref id="archive-manip">); and how to handle bug reports
56 (<ref id="bug-handling">).
57       <p>
58 The resources discussed in this reference include the mailing lists
59 and servers (<ref id="servers">); a discussion of the structure of the
60 Debian archive (<ref id="archive">); explanation of the different
61 servers which accept package uploads (<ref id="upload-master">); and a
62 discussion of resources which an help maintainers with the quality of
63 their packages (<ref id="tools">).
64       <p>
65 It should be clear that this reference does not discuss the details of
66 the Debian package or how to generate Debian packages; that is
67 discussed in the <url
68 id="http://www.debian.org/doc/packaging-manuals/packaging.html/"
69 name="Debian Packaging Manual">.  Nor is this reference intended to
70 give details on standards for how Debian software must behave, which
71 is documented in the <url
72 id="http://www.debian.org/doc/debian-policy/" name="Debian Policy
73 Manual">.
74
75
76     <chapt id="new-maintainer">Applying to Become a Maintainer
77         
78       <sect>Getting started
79         <p>
80 So, you've read all the documentation, you understand what everything
81 in the <prgn/hello/ example package is for, and you're about to
82 Debianize your favourite piece of software.  How do you actually
83 become a Debian developer so that your work can be incorporated into
84 the Project?
85         <p>
86 Firstly, subscribe to <email/debian-devel@lists.debian.org/ if you
87 haven't already.  Send the word <tt/subscribe/ in the <em/Subject/ of
88 a mail to <email/debian-devel-REQUEST@lists.debian.org/.  In case of
89 problems, contact the list administrator at
90 <email/listmaster@lists.debian.org/.  More information on available
91 mailing lists can be found in <ref id="mailing-lists">.
92         <p>
93 You should subscribe and lurk for a bit before doing any coding, and
94 you should post about your intentions to work on something to avoid
95 duplicated effort.
96         <p>
97 Another good list to subscribe to is
98 <email/debian-mentors@lists.debian.org/.  See <ref id="mentors"> for
99 details.  The IRC channel <tt/#debian/ on the Linux People IRC network 
100 (i.e., <tt/irc.debian.org/) can also be helpful.
101
102
103       <sect>Registering as a Debian developer
104         <p>
105 Before you decide to register with the Debian Project, you will need
106 to read the <url id="http://www.debian.org/social_contract"
107 name="Debian Social Contract">.  Registering as a developer means that
108 you agree with and pledge to uphold the Debian Social Contract; it is
109 very important that maintainers are in accord with the essential ideas
110 behind Debian GNU/Linux.  Reading the <url
111 id="http://www.gnu.org/gnu/manifesto.html" name="GNU Manifesto"> would
112 also be a good idea.
113         <p>
114 The process of registering as a developer is a process of verifying
115 your identity and intentions.  As the number of people working on
116 Debian GNU/Linux has grown to over 400 people and our systems are used
117 in several very important places we have to be careful about being
118 compromised.  Therefore, we need to verify new maintainers before we
119 can give them accounts on our servers and letting them upload
120 packages.
121         <p>
122 Registration requires that the following information be sent to
123 <email/new-maintainer@debian.org/ as part of the registration
124 application:
125 <list>
126             <item>
127 Your name.
128             <item>
129 Your preferred login name on <tt/master/ (seven characters or
130 less<footnote>Can anyone clarify for me why logins on <tt>master</tt>
131 cannot be eight characters?</footnote> ), as well as the email address
132 at which you'd prefer to be subscribed to
133 <email/debian-private@lists.debian.org/ (typically this will be either
134 your primary mail address or your new <tt>debian.org</tt> address).
135             <item>
136 A phone number where we can call you.
137             <item>
138 A statement of intention, that is, what package(s) you intend to work
139 on, which Debian port you will be assisting, or how you intend to
140 contribute to Debian.
141             <item>
142 A statement that you have read and agree to uphold the <url
143 id="http://www.debian.org/social_contract" name="Debian Social
144 Contract">.
145             <item>
146 Some mechanism by which we can verify your real-life identity. For
147 example, any of the following mechanisms would suffice:
148 <list>
149                   <item>
150 A PGP key signed by any well-known signature, such as:
151 <list>
152                   <item>
153 Any current Debian developer you have met <em/in real life/.
154                   <item>
155 Any formal certification service (such as Verisign, etc.) that
156 verifies your identity.  A certification that verifies your email
157 address, and not you identity, is not sufficient.
158                       </list>
159                   <item>
160 Alternatively, you may identify yourself with a scanned (or physically
161 mailed) copy of any formal documents certifying your identity (such as
162 a birth certificate, national ID card, U.S. Driver's License, etc.).
163 If emailed, please sign the mail with your PGP key.
164                 </list>
165           </list>
166 If you do not have a PGP key yet, generate one. Every developer needs
167 a PGP key in order to sign and verify package uploads. You should read
168 the PGP manual, since it has much important information which is
169 critical to its security.  Many more security failures are due to
170 human error than to software failure or high-powered spy techniques.
171         <p>
172 Your PGP key must be at least 1024 bits long.  There is no reason to
173 use a smaller key, and doing so would be much less secure.  Your key
174 must be signed with at least your own user ID.  This prevents user ID
175 tampering.  You can do it by executing `<tt>pgp -ks
176 <var/your_userid/</tt>'.
177         <p>
178 If your PGP key isn't on public PGP key servers such as
179 <tt>pgp.net</tt>, please read the documentation available locally
180 <tt>/usr/doc/pgp/keyserv.doc</tt>.  That document contains
181 instructions on how to put your key on the public keyservers.
182         <p>
183 Due to export restrictions by the United States government some Debian
184 packages, including PGP, have been moved to an ftp site outside of the
185 United States. You can find the current locations of those packages on
186 <ftpsite/ftp.debian.org/ or <ftpsite/ftp.us.debian.org/ in the
187 <ftppath>/pub/debian/README.non-US</ftppath> file.
188         <p>
189 Some countries restrict the use of cryptographic software by their
190 citizens.  This need not impede one's activities as a Debian package
191 maintainer however, as it may be perfectly legal to use cryptographic
192 products for authenication, rather than encryption purposes (as is
193 the case in France).  The Debian Project does not require the use of
194 cryptography <em/qua/ cryptography in any manner.  If you live in a
195 country where use of cryptography even for authentication is forbidden
196 then please contact us so we can make special arrangements.
197         <p>
198 Once you have all your information ready, and your public key is
199 available on public key servers, send a message to
200 <email/new-maintainer@debian.org/ to register as an offical Debian
201 developer so that you will be able to upload your packages.  This
202 message must all the information discussed above.  The message must
203 also contain your PGP or RSA public key (extracted using <tt>pgp
204 -kxa</tt> in the case of PGP; note that <tt/gpg/ integration is
205 underway) for the database of keys which is distributed from
206 <ftpsite/ftp.debian.org/ in
207 <ftppath>/pub/debian/doc/debian-keyring.tar.gz</ftppath>, or the
208 <prgn>debian-keyring</prgn> package).  Please be sure to sign your
209 request message with your chosen PGP or RSA key.
210         <p>
211 Once this information is received and processed, you should be
212 contacted with information about your new Debian maintainer account.
213 If you don't hear anything within 7-14 days, please re-send your
214 original message--the new-maintainer volunteers are typically
215 overworked, and mistakes do occasionally happen.
216
217
218       <sect id="mentors">Debian Mentors
219         <p>
220 There is a mailing list called <email/debian-mentors@lists.debian.org/
221 which has been set up for novice maintainers who seek help with
222 initial packaging and other developer-related issues.  Every new
223 developer is invited to subscribe to that list (see <ref
224 id="mailing-lists"> for details).
225         <p>
226 Those who prefer one-on-one help (e.g., via private emails) should
227 also post to that list and an experienced developer will volunteer to
228 help.
229
230
231     <chapt id="servers">Mailing Lists and Servers
232
233       <sect id="mailing-lists">Mailing lists
234         <p>
235 The mailing list server is at <tt/lists.debian.org/.  Mail
236 <tt/debian-<var/foo/-REQUEST@lists.debian.org/, where
237 <tt/debian-<var/foo// is the name of the list, with the word
238 <tt/subscribe/ in the <em/Subject/ to subscribe or <tt/unsubscribe/ to
239 unsubscribe.  More detailed instructions on how to subscribe and
240 unsubscribe to the mailing lists can be found at <url
241 id="http://www.debian.org/MailingLists/subscribe">, <url
242 id="ftp://ftp.debian.org/debian/doc/mailing-lists.txt"> or locally in
243 <tt>/usr/doc/debian/mailing-lists.txt</tt> if you have the
244 <prgn>doc-debian</prgn> package installed.
245         <p>
246 When replying to messages on the mailing list, please do not send
247 a carbon copy (<tt/CC/--this does not mean `courtesy copy') to
248 the original poster unless they explicitly request that this be
249 done.  Anyone who posts to a mailing list should read it to see the
250 responses.
251         <p>
252 In addition, all messages should usually only be sent to one of the
253 following mailing lists: <email/debian-devel@lists.debian.org/,
254 <email/debian-policy@lists.debian.org/,
255 <email/debian-user@lists.debian.org/,
256 <email/debian-announce@lists.debian.org/, or
257 <email/debian-devel-announce@lists.debian.org/.  Additional mailing
258 lists are available for special purposes; see <url
259 id="http://www.debian.org/MailingLists/subscribe">.  Cross-posting
260 (sending the same message to multiple lists) is discouraged.
261         <p>
262 <email/debian-private@lists.debian.org/ is a special mailing lists for
263 private discussions amongst Debian developers.  It is meant to be used
264 for posts which for whatever reason should not be published
265 publically.  As such, it is a low volume list, and users are urged not
266 to use <email/debian-private@lists.debian.org/ unless it is really
267 necessary.  Moreover, do <em/not/ forward email from that list to
268 anyone.
269         <p>
270 As ever on the net, please trim down the quoting of articles you're
271 replying to.  In general, please adhere to the usual conventions for
272 posting messages.
273         <p>
274 Online archives of mailing lists are available at <url
275 id="http://www.debian.org/Lists-Archives/">.
276
277
278       <sect>The master server
279         <p>
280 The master server, <tt/master.debian.org/, holds the cannonical copy
281 of the Debian archive (excluding the non-U.S. packages).  Generally,
282 package uploads go to this server; cf. <ref id="upload">.  All Debian
283 developers have accounts on this machine.
284
285       <sect>The FTP servers
286         <p>
287
288       <sect>The WWW servers
289         <p>
290
291
292     <chapt id="archive">The Debian Archive
293
294       <sect>Overview
295         <p>
296 The Debian GNU/Linux distribution consists of a lot of Debian packages
297 (<tt/.deb/'s, currently more than 1500) and a few additional files
298 (documentation, installation disk images, etc.).
299         <p>
300 Here is an example directory tree of a complete Debian distribution:
301 <example>
302 main/
303 main/binary-all/
304 main/binary-all/admin/
305 main/binary-all/base/
306 main/binary-all/comm/
307 main/binary-all/devel/
308      ...
309 main/binary-i386/
310 main/binary-i386/admin/
311 main/binary-i386/base/
312      ...
313 main/binary-m86k
314 main/binary-m86k/admin/
315 main/binary-m86k/base/
316      ...
317 main/source/
318 main/source/admin/
319 main/source/base/
320      ...
321 main/disks-i386/
322 main/disks-m68k/
323      ...
324
325 contrib/
326 contrib/binary-all/
327 contrib/binary-i386/
328 contrib/binary-m86k/
329      ...
330 contrib/source/
331
332 non-free/
333 non-free/binary-all/
334 non-free/binary-i386/
335 non-free/binary-m86k/
336          ...
337 non-free/source/
338 </example>
339         <p>
340 As you can see, the top-level directory of the distribution contains
341 three directories, namely <em>main</>, <em>contrib</>, and
342 <em>non-free</>. These directories are called <em>sections</>.
343         <p>
344 In each section, there is a directory with the source packages
345 (source), a directory for each supported architecture (binary-i386,
346 binary-m86k, etc.), and a directory for architecture independent
347 packages (binary-all).
348         <p>
349 The <em/main/ section contains additional directories which holds the
350 disk images and some essential pieces of documentation required for
351 installing the Debian distribution on a specific architecture
352 (disks-i386, disks-m68k, etc.).
353         <p>
354 The <em/binary/ and <em/source/ directories are divided further into
355 <em/subsections/.
356
357
358       <sect>Sections
359         <p>
360 The <em>main</em> section is what makes up the <em>official Debian
361 GNU/Linux distribution</>. This is because the packages in the other
362 two sections do not fully comply with all our guidelines.  As such,
363 they are not officially part of Debian.
364         <p>
365 For example, every package in the main section must fully comply
366 with the <url id="http://www.debian.org/social_contract#guidelines"
367 name="Debian Free Software Guidelines"> (DFSG) and with all other
368 policy requirements as described in the <url
369 id="http://www.debian.org/doc/debian-policy/" name="Debian Policy
370 Manual">. (The DFSG is our definition of ``free software.'' Check out
371 the Debian Policy Manual for details.)
372         <p>
373 The packages which do not apply to the DFSG are placed in the
374 <em/non-free/ section. These packages are not considered as part of
375 the Debian distribution, though we support their use, and we provide
376 infrastructure (such as our bug-tracking system and mailing lists) for
377 non-free software packages.
378         <p>
379 Packages in the <em/contrib/ section have to apply to the DFSG, but
380 fail other requirements.  For instance, they might depend on non-free
381 packages.
382         <p>
383 (The <url id="http://www.debian.org/doc/debian-policy/" name="Debian
384 Policy Manual"> contains a more exact definition of the three
385 sections. The above discussion is just an introduction.)
386         <p>
387 The separation of the three sections at the top-level of the archive
388 is important for all people who want to distribute Debian, either via
389 FTP servers on the Internet or on CD-ROMs: by distributing only the
390 <em/main/ and <em/contrib/ sections, one can avoid any legal risks.
391 Some packages in the <em/non-free/ section do not allow commercial
392 distribution, for example.
393         <p>
394 On the other hand, a CD-ROM vendor could easily check the individual
395 package licenses of the packages in <em/non-free/ and include as many
396 on the CD-ROMs as he's allowed. (Since this varies greatly from vendor
397 to vendor, this job can't be done by the Debian developers.)
398
399
400       <sect>Architectures
401         <p>
402 In the first days, the Linux kernel was only available for the Intel
403 i386 (or greater) platforms, and so was Debian. But when Linux became
404 more and more popular, the kernel was ported to other architectures,
405 too.
406         <p>
407 The Linux 2.0 kernel supports Intel, DEC Alphas, SUN Sparcs, M68000
408 (a.k.a. m68k) machines (like Atari and Amiga), MIPS, and PowerPC
409 (a.k.a. ppc).
410         <p>
411 Debian GNU/Linux 1.3 is only available for Intel platforms.  Debian
412 2.0 supports Intel and m68k architectures.  The next version of Debian
413 is likely to also support Alpha, PPC, and Sparc architectures, if not
414 more.
415
416
417       <sect>Subsections
418         <p>
419 The sections <em/main/, <em/contrib/, and <em/non-free/ are split into
420 <em/subsections/ to simplify the installation process and the
421 maintainance of the archive.  Subections are not formally defined,
422 excepting perhaps for the "base" subsection.  Subsections exist simply
423 to simpilfy the organization and browsing of available packages.
424 Please check the current Debian distribution to see which sections are
425 available.
426
427
428
429       <sect>Packages
430         <p>
431 There are two types of Debian packages, namely <em/source/ and
432 <em/binary/ packages.
433         <p>
434 Source packages consist of either two or three files: a <tt/.dsc/
435 file, and either one <tt/.tar.gz/ file or an <tt/.orig.tar.gz/ and a
436 <tt/.diff.gz/ file.
437         <p>
438 If a package is developed specially for Debian and is not distributed
439 outside of Debian, there is just one <tt/.tar.gz/ file which contains
440 the sources of the program.
441         <p>
442 If a package is distributed elsewhere too, the <tt/.orig.tar.gz/ file
443 stores the so-called <em/upstream source code/, that is the source
444 code that's distributed from the <em/upstream maintainer/ (often the
445 author of the software). In this case, the <tt/.diff.gz/ contains the
446 changes made by the Debian maintainer.
447         <p>
448 The <tt/.dsc/ lists all the files in the source package together with
449 checksums (md5sums) and some additional info about the package
450 (maintainer, version, etc.).
451
452
453       <sect>Distribution directories
454         <p>
455 If you have a look at the Debian FTP server or one of its mirrors,
456 you'll discover that there is one additional directory level on top of
457 the directory tree, as described in the previous chapter. These
458 directories are the <em/distribution directories/.  All distributions
459 are contained in the <tt/dists/ directory in the top-level of the
460 Debian archive (the symlinks from the top-level directory to the
461 distributions themselves is for backwards compatability and
462 deprecated).
463
464         <sect1>Stable, unstable, and sometimes frozen
465         <p>
466 There is always a distribution called <em/stable/ (residing in
467 <tt>dists/stable</tt>) and one called <em/unstable/ (residing in
468 <tt>dists/unstable</tt>. This reflects the development process of the
469 Debian project.
470         <p>
471 The ``development'' is done in the <em/unstable/ distribution (that's
472 why this distribution is sometimes called the <em/development
473 distribution/). Every Debian developer can update his or her packages in
474 this distribution at any time. Thus, the contents of this distribution
475 change from day to day and since no special effort is done to test
476 this distribution it's sometimes ``unstable.''
477         <p>
478 After a period of development, the <em/unstable/ distribution is
479 copied in a new distribution directory, called <em/frozen/. When that
480 occurs, no changes are allowed to the frozen distribution except bug
481 fixes; that's why it's called ``frozen.''  After another month or a
482 little longer, the <em/frozen/ distribution is renamed to <em/stable/,
483 overriding the old <em/stable/ distribution, which is removed at that
484 time.
485         <p>
486 This development cycle is based on the assumption that the
487 <em/unstable/ distribution becomes <em/stable/ after passing a period
488 of testing as <em/frozen/. Unfortunately, even once a distribution is
489 considered stable, a few bugs inevitably remain--that's why the stable
490 distribution is updated every now and then. However, these updates are
491 tested very carefully and have to be introduced into the archive
492 individually to reduce the risk of introducing new bugs.  You can find
493 proposed additions to <em/stable/ in the <tt/proposed-updates/
494 directory.  Those packages in <tt/proposed-updates/ that pass muster
495 are periodically moved as a batch into the stable distribution and the
496 revision level of the stable distribution is incremented (e.g., `1.3'
497 becomes `1.3r1', `2.0r2' becomes `2.0r3', and so forth).
498         <p>
499 Note that development is continued during the ``freeze'' period, since
500 a new <em/unstable/ distribution is be created when the older
501 <em/unstable/ is moved to <em/frozen/.
502         <p>
503 In summary, there is always a <em/stable/ and an <em/unstable/
504 distribution available, and the <em/frozen/ distribution shows up for
505 a month or so from time to time.
506
507
508         <sect1>Experimental
509           <p>
510 The <em/experimental/ distribution is a specialty distribution.  It is
511 not a full distribution in the same sense that 'stable' and 'unstable'
512 are.  Instead, it is meant to be a temporary staging area for highly
513 experimental software where there's a good chance that the software
514 could break your system.  Users who download and install packages from
515 <em/experimental/ are expected to have been duly warned.  In short,
516 all bets are off for the <em/experimental/ distribution.
517           <p>
518 Developers should be very selective in the use of the
519 <em/experimental/ distribution.  Even if a package is highly unstable,
520 it could well still go into <em/unstable/; just state a few warnings
521 in the description.  However, if there is a chance that the software
522 could do grave damage to a system, it might be better to put it into
523 <em/experimental/.
524           <p>
525 For instance, an experimental encrypted filesystem should probably go
526 into experimental.  A new, beta, version of some software which uses
527 completely different configuration might go into experimental at the
528 maintainer's discretion.  New software which isn't likely to damage
529 your system can go into <em/unstable/.
530
531
532       <sect id="codenames">Release code names
533         <p>
534 Every released Debian distribution has a <em/code name/: Debian 1.1 is
535 called <em/buzz/; Debian 1.2, <em/rex/; Debian 1.3, <em/bo/; Debian
536 2.0, <em/hamm/; Debian 2.1, <em/slink/.  There is also a
537 "pseudo-distribution", called <em/sid/, which is contains packages for
538 architectures which are not yet officially supported or released by
539 Debian.  These architectures are planned to be integrated into the
540 mainstream distribution at some future date.
541         <p>
542 Since the Debian has an open development model (i.e., everyone can
543 participate and follow the development) even the ``development
544 versions'' (unstable) are distributed via the Internet on the Debian
545 FTP server. This FTP server is mirrored by lots of other
546 systems. Thus, if we'd call the directory which contains the
547 development version simply `unstable', then we would have to rename it
548 to `stable' when the version is released, which would cause all FTP
549 mirrors to re-get the whole distribution (which is already very
550 large!).
551         <p>
552 On the other hand, if we would call the distribution directories
553 <em>Debian-x.y</em> from the beginning, people would think that Debian
554 release <em>x.y</> is available. (This happened in the past, where a
555 CD-ROM vendor built a Debian 1.0 CD-ROM based on a pre-1.0 development
556 version. That's the reason why the first official Debian release was
557 1.1, and not 1.0.)
558         <p>
559 Thus, the names of the distribution directories in the archive should
560 stay the same during the development period and after the release but
561 there may be symbolic links, which can be changed.
562         <p>
563 That's why the distribution directories use the <em/code names/ and
564 there are symbolic links <em/stable/, <em/unstable/, <em/frozen/,
565 etc., which point to the appriopriate release directories.
566
567
568     <chapt id="upload">Package uploads
569
570       <sect>Announcing new packages
571         <p>
572 If you want to create a new package for the Debian distribution, you
573 should first check the <url
574 id="http://www.debian.org/doc/prospective-packages.html"
575 name="Work-Needing and Prospective Packages (WNPP)"> page.  Checking
576 the WNPP ensures that no one is already working on packaging that
577 software, and that effort is not duplicated. Assuming no one else is
578 already working on your prospective package, you must then send a
579 short email to <email/debian-devel@lists.debian.org/ describing your
580 plan to create a new package.  You should set the subject of the email
581 to "intent to package <var/foobar/", substituting the name of the new
582 package for <var/foobar/.
583         <p>
584 There are a number of reasons why we ask maintainers to follow these
585 steps.
586           <list compact>
587             <item>
588 It helps the (potentially new) maintainer to tap into the experience
589 of people on the list, and lets them know if any one else is working
590 on it already.
591
592             <item>
593 It lets other people thinking about working on the package know that
594 there already is a volunteer, and efforts may be shared.  The "intent
595 to package" message to <email/debian-devel@lists.debian.org/ will be
596 picked up the the WNPP maintainer, and your intention will be
597 published in subsequent versions of the WNPP document.
598
599             <item>
600 It lets the rest of the maintainers know more about the package than
601 the one line description and the changelog entry "Initial version"
602 that generally gets posted to <tt/debian-devel-changes/ by default.
603
604             <item>
605 It is helpful to the people who live off unstable (and form our first
606 line of testers); we should encourage these people.
607
608             <item>
609 The announcements give maintainers and other interested parties a
610 better feel of what is going on, and what is new, in the project.
611
612
613             <item>
614 We should not dismiss anybody who installs from unstable and helps us
615 debug our packages as "fools, fools, you installed from unstable; you
616 deserve what you get"--we derive a certain benefit from the alpha
617 testers.
618
619           </list>
620
621
622       <sect id="uploading">Uploading a package
623
624         <sect1>Generating the changes file
625           <p>
626 When a package is uploaded to the Debian FTP archive, it must be
627 accompanied by a <tt/.changes/ file which gives directions for its
628 handling.  This is usually generated by <prgn/dpkg-genchanges/.
629           <p>
630 This file is a control file with the following fields:
631 <list compact>
632               <item><tt/Format/
633               <item><tt/Date/
634               <item><tt/Source/
635               <item><tt/Binary/
636               <item><tt/Architecture/
637               <item><tt/Version/
638               <item><tt/Distribution/
639               <item><tt/Urgency/
640               <item><tt/Maintainer/
641               <item><tt/Description/
642               <item><tt/Changes/
643               <item><tt/Files/
644             </list>
645           <p>
646 All of them are mandatory for a Debian upload.  See the list of
647 control fields in the <url
648 id="http://www.debian.org/doc/packaging-manuals/packaging.html/"
649 name="Debian Packaging Manual"> for the contents of these fields.
650           <p>
651 Notably, the <tt/Distribution/ field, which originates from the
652 <tt>debian/changelog</tt> file, should indicate which distribution the
653 package is intended for.  There are four possible values for this
654 field: <em/stable/, <em/unstable/, <em/frozen/, or <em/experimental/;
655 these values can also be combined.  For instance, if you have a
656 crucial security fix release of a package, and the package has not
657 diverged between the <em/stable/ and <em/unstable/ distributions, then
658 you might put <tt/stable unstable/ in the <tt>debian/changelog</tt>'s
659 distribution field.  Or, if Debian has been frozen, and you want to
660 get a bug-fix release into <em/frozen/, you would set the distribution
661 to <tt/frozen unstable/.  Note that setting the distribution to
662 <tt/stable/ means that the pacakge will be placed into the
663 <tt>proposed-updates</tt> directory of the Debian archive for further
664 testing, before it is actually included in <em/stable/.  Also note
665 that it never makes sense to combine the <em/experimental/
666 distribution with anything else.
667
668           <p>
669 The first time a version is uploaded which corresponds to a particular
670 upstream version the original source tar file should be uploaded and
671 included in the <tt/.changes/ file; subsequent times the very same tar
672 file should be used to build the new diffs and <tt/.dsc/ files, and it
673 need not then be uploaded.
674           <p>
675 By default <prgn/dpkg-genchanges/ and <prgn/dpkg-buildpackage/ will
676 include the original source tar file if and only if the Debian
677 revision part of the source version number is <tt/0/ or <tt/1/,
678 indicating a new upstream version.  This behaviour may be modified by
679 using <tt/-sa/ to always include it or <tt/-sd/ to always leave it
680 out.
681           <p>
682 If no original source is included in the upload then the original
683 source tar-file used by <prgn/dpkg-source/ when constructing the
684 <tt/.dsc/ file and diff to be uploaded <em/must/ be byte-for-byte
685 identical with the one already in the archive.  If there is some
686 reason why this is not the case then the new version of the original
687 source should be uploaded, possibly by using the <tt/-sa/ flag.
688
689
690         <sect1 id="upload-checking">Checking the package prior to upload
691           <p>
692 Before you upload your package, you should do basic testing on it.
693 Make sure you try the following activities (you'll need to have an
694 older version of the Debian package around).
695 <list>
696               <item> install the package and make sure the software
697               works, or upgrade the package from an older version to
698               your new version if a Debian package for it already
699               exists
700
701               <item> downgrade the package to the previous version
702               (if one exists) -- this tests the <tt/postrm/ and
703               <tt/prerm/ scripts
704
705               <item> remove the package
706
707               <item> run <prgn/lintian/ over the package.  You can run
708               <prgn/lintian/ as follows: <tt>lintian -v
709               <var>package-NN</var>.changes</tt>. This will check the
710               source package as well as the binary package.  If you
711               don't understand the output that <prgn/lintian/
712               generates, try adding the <tt/-i/ switch, which will
713               cause <prgn/lintian/ to output a very verbose
714               description of the problem.
715
716             </list>
717
718
719         <sect1 id="upload-master">Transferring the files to master
720           <p>
721 To upload a package, you need a personal account on
722 <ftpsite>master.debian.org</ftpsite>.  All maintainers should already
723 have this account.  You can use either <prgn/ssh/ or <prgn/ftp/ to
724 transfer the files.  In either case, the files need to be placed into
725 <ftppath>/home/Debian/ftp/private/project/Incoming</ftppath>.  (You
726 cannot upload to Incoming on master using anonymous FTP -- you must use
727 your username and password.)
728           <p>
729 <em/Note:/ Do not upload packages containing software that is
730 export-controlled by the United States government to <tt/master/.
731 This includes almost all cryptographic software, and even software
732 that contains "hooks" to cryptographic software, such as electronic
733 mail readers that support PGP encryption and authentication.  Uploads
734 of such software should go to <tt/non-us/ (see below).  If you are
735 not sure whether U.S. export controls apply to your package, post a
736 message to <email/debian-devel@lists.debian.org/ and ask.
737           <p>
738 You may also find the Debian package <prgn/dupload/ useful when
739 uploading packages.  This handy program is distributed with defaults
740 for uploading via <prgn/ftp/ to <tt/master/, <tt/chiark/, and
741 <tt/erlangen/.  It can also be configured to use <prgn/ssh/.  See
742 <manref name="dupload" section="1"> and <manref name="dupload"
743 section="5"> for more information.
744
745
746         <sect1>Uploads via Chiark
747           <p>
748 If you have a slow network connection to <tt/master/, there are two
749 alternatives: You can upload files to Incoming via a cron-driven
750 upload queue in Europe on <tt/chiark/. For details connect to
751 <ftpsite>ftp.chiark.greenend.org.uk</ftpsite> using anonymous FTP and
752 read
753 <ftppath>/pub/debian/private/project/README.how-to-upload</ftppath>.
754           <p>
755 The program <tt/dupload/ supports uploads to chiark, please refer to
756 the documentation that comes with the program for details.
757
758
759         <sect1>Uploads via Erlangen
760           <p>
761 Another cron-driven upload queue is available in Germany: just upload
762 the files via anonymous FTP to <url
763 id="ftp://ftp.uni-erlangen.de/pub/Linux/debian/UploadQueue">.
764           <p>
765 The upload must be a complete Debian upload, as you would put it into
766 master's <tt/Incoming/, i.e., a <tt/.changes/ files along with the
767 other files mentioned in the <tt/.changes/. The queue daemon also
768 checks that the <tt/.changes/ is correctly PGP-signed by a Debian
769 developer, so that no bogus files can find their way to master via the
770 queue. Please also make sure that the <tt/Maintainer:/ field in the
771 <tt/.changes/ contains <em/your/ e-mail address. The address found
772 there is used for all replies, just as on master.
773           <p>
774 There's no need to move your files into a second directory after the
775 upload as on chiark. And, in any case, you should get some mail reply
776 from the queue daemon what happened to your upload. Hopefully it
777 should have been moved to master, but in case of errors you're
778 notified, too.
779           <p>
780 The program <prgn/dupload/ supports uploads to erlangen, please refer
781 to the documentation that comes with the program for details.
782
783
784         <sect1>Uploading to the non-us server
785           <p>
786 To upload a package to the <em/non-us/ server you just have to
787 transfer the files via anonymous ftp to <url
788 id="ftp://non-us.debian.org/pub/debian-non-US/Incoming">.  Note, that
789 the <tt>.changes</tt> file must have a valid PGP signature from one of
790 the keys of the developers keyring.
791
792
793       <sect>Announcing package uploads
794         <p>
795 When a package is uploaded an announcement should be posted to one of
796 the debian-changes lists. The announcement should give the (source)
797 package name and version number, and a very short summary of the
798 changes, in the <em/Subject/ field, and should contain the PGP-signed
799 <tt/.changes/ file.  Some additional explanatory text may be added
800 before the start of the <tt/.changes/ file.
801         <p>
802 If a package is released with the <tt/Distribution:/ set to
803 <tt/stable/, the announcement is sent to
804 <email/debian-changes@lists.debian.org/.
805         <p>
806 If a package is released with <tt/Distribution:/ set to <tt/unstable/,
807 <tt/experimental/, or <tt/frozen/ (when present), the announcement
808 should be posted to <email/debian-devel-changes@lists.debian.org/
809 instead.
810         <p>
811 On occassion, it is necessary to upload a package to both the <tt/stable/
812 and <tt/unstable/ distributions; this is done by putting both distributions
813 in the <tt/Distribution:/ line.  In such a case the upload announcement
814 should go to both of the above mailing lists.
815         <p>
816 The <prgn/dupload/ program is clever enough to determine for itself
817 where the announcement should go, and will automatically mail the
818 announcement.  See <ref id="dupload">.
819
820       <sect>Notification that a new package has been installed
821         <p>
822 The Debian archive maintainers are responsible for handling package
823 uploads.  For the most part, uploads are automatically handled on a
824 daily basis by an archive maintenance tool called <prgn/dinstall/.
825 Specifically, updates to existing packages to the `unstable'
826 distribution are handled automatically. In other cases, notably new
827 packages, placing the uploaded package into the distribution is
828 handled manually. When uploads are handled manually, the change to the
829 archive may take up to a week to occur (please be patient).
830         <p>
831 In any case, you will receive notification indicating that the package
832 has been uploaded via email.  Please examine this notification
833 carefully.  Sometimes the "override" file which the archive
834 maintainers use to indicate where packages go, is incorrect or
835 out-of-sync with your control file.  In these cases, you should either
836 correct your control file or file a bug against <tt/ftp.debian.org/
837 using the BTS.
838
839       <sect id="nmu">Interim releases
840         <p>
841 Under certain circumstances it is necessary for someone other than the
842 usual package maintainer to make a release of a package.  For example,
843 a porter for another architecture may have to make some small changes
844 to the source package and does not wish to wait with uploading their
845 release until the main maintainer has incorporated the patch, or a
846 serious security problem or bug may have come to light requiring
847 immediate attention.
848         <p>
849 When a security bug is detected a fixed package should be uploaded as
850 soon as possible. In this case, the Debian Security Managers should
851 get in contact with the package maintainer to make sure a fixed
852 package is uploaded within a reasonable time (less than 48 hours). If
853 the package maintainer cannot provide a fixed package fast enough or
854 if he/she cannot be reached in time, the Security Manager may upload a
855 fixed package.
856         <p>
857 When someone other than the usual maintainer releases a package they
858 should add a new component to the <var/debian-revision/ component of
859 the version number--that is, the portion after the (last) hyphen.
860 This extra component will start at <tt/1/.  This is to avoid
861 `stealing' one of the usual maintainer's version numbers, possibly
862 disrupting their work.  If there is no <var/debian-revision/ component
863 in the version number then one should be created, starting at <tt/1/.
864         <p>
865 If it is absolutely necessary for someone other than the usual
866 maintainer to make a release based on a new upstream version then the
867 person making the release should start with the <var/debian-revision/
868 value <tt/0.1/.  The usual maintainer of a package should start their
869 <var/debian-revision/ numbering at <tt/1/.
870         <p>
871 Maintainers other than the usual package maintainer should make as few
872 changes to the package as possible, and they should always send a
873 unified context diff (<tt/diff -u/) detailing their changes to the bug
874 tracking system properly flagged with the correct package so that the
875 usual maintainer is kept aware of the situation.
876         <p>
877 If the non-maintainer upload (as known as an "NMU") fixes some
878 existing bugs, the bug reports should not be closed.  Technically,
879 only the official package maintainer or the original bug submitter are
880 allowed to close bugs. However, the person making the non-maintainer
881 release should send a short message to the bug tracking system to all
882 the fixed bugs explaining that they have been fixed.  Using
883 <email/control@bugs.debian.org/, the party doing the NMU should also
884 set the severity of the bugs fixed in the NMU to "fixed".  This
885 ensures that everyone knows that the bug was fixed in an NMU; however
886 the bug is left open until the changes in the NMU are incorporated
887 "officially" into the package by the offical package maintainer.
888         <p>
889 The normal maintainer should do at least one of the following:
890           <list compact>
891             <item>
892 apply the diff,
893             <item>
894 read the diff and decide on each part of it themselves, or
895             <item>
896 if the maintainer decides not to apply the patch but to release a new
897 version, read the description of the changes to the next upstream
898 version and ensure that they fix each problem that was fixed in the
899 non-maintainer release.
900           </list>
901         <p>
902 In addition, the normal maintainer should <em/always/ include an entry
903 in the changelog file documenting the non-maintainer upload.
904
905
906       <sect>Maintainer changes
907         <p>
908 Periodically, a listing of packages in need of new maintainers will be
909 sent to <email/debian-devel@lists.debian.org</email> list. This list
910 is also available at in the Work-Needing and Prospective Packages
911 document (WNPP), <url
912 id="ftp://ftp.debian.org/debian/doc/package-developer/prospective-packages.html">
913 and at <url id="http://www.debian.org/doc/prospective-packages.html">.
914 If you wish to take over maintenance of any of the packages listed in
915 the WNPP, or if you can no longer maintain a packages you have, or you
916 simply want to know if any one is working on a new package, send a
917 message to <email/wnpp@debian.org/.
918
919         <p>
920 If you take over an old package, you probably want to be listed as the
921 package's official maintainer in the bug system. This will happen
922 automatically once you upload a new version with an updated
923 <tt/Maintainer:/ field. If you do not expect to upload a new version
924 for a while, send an email to <email/override-change@debian.org/ so
925 that bug reports will go to you.
926
927
928     <chapt id="archive-manip">Moving, Removing, Renaming, and Orphaning Packages
929       <p>
930 Some archive manipulation operation are not automated in the Debian
931 upload process.  This chapter gives guidelines in what to do in these
932 cases.
933
934       <sect>Moving packages
935         <p>
936 Sometimes a package will change either its section or its subsection.
937 For instance, a package from the `non-free' section might be GPL'd in
938 a later version; in this case you should consider moving it to `main'
939 or `contrib' (see the <url
940 id="http://www.debian.org/doc/debian-policy/" name="Debian Policy
941 Manual"> for guidelines).
942         <p>
943 In this case, it is sufficient to edit the package control information
944 normally and re-upload the package (see the <url
945 id="http://www.debian.org/doc/packaging-manuals/packaging.html/"
946 name="Debian Packaging Manual"> for
947 details).  Carefully examine the installation log sent to you when the
948 package is installed into the archive.  If for some reason the old
949 location of the package remains, file a bug against
950 <prgn/ftp.debian.org/ asking that the old location be removed.  Give
951 details on what you did, since it might be a <prgn/dinstall/ bug.
952
953
954       <sect>Removing packages
955         <p>
956 If for some reason you want to completely remove a package (say, if it
957 is an old compatability library which is not longer required), you
958 need to file a bug against <prgn/ftp.debian.org/ asking that the
959 package be removed.  Make sure you indicate which distribution the
960 package should be removed from.
961         <p>
962 If in doubt concerning whether a package is disposable, email
963 <email/debian-devel@lists.debian.org/ asking for opinions.
964
965
966       <sect>Replacing or renaming packages
967         <p>
968 Sometimes you made a mistake naming the package and you need to rename
969 it.  In this case, you need to follow a two-step process.  First, set
970 your <tt>debian/control</tt> file to replace and conflict with the
971 obsolete name of the package (see the <url
972 id="http://www.debian.org/doc/packaging-manuals/packaging.html/"
973 name="Debian Packaging Manual"> for details).  Once you've uploaded
974 that package, and the package has moved into the archive, file a bug
975 against <prgn/ftp.debian.org/ asking to remove the package with the
976 obsolete name.
977
978
979       <sect>Orphaning a package
980         <p>
981 If you can no longer maintain a package, then you should set the
982 package maintainer to <tt>Debian QA
983 &lt;debian-qa@lists.debian.org&gt;</tt> and email
984 <email/wnpp@debian.org/ indicating that the package is now orphaned.
985 If the package is especially crucial to Debian, you should instead
986 email <email/debian-devel@lists.debian.org/ asking for a new
987 maintainer.
988
989
990     <chapt id="bug-handling">Handling Bug Reports
991
992       <sect>Monitoring bugs
993         <p>
994 If you want to be a good maintainer, you should periodically check the
995 <url id="http://www.debian.org/Bugs/" name="Debian bug tracking system
996 (BTS)"> for your packages.  The BTS contains all the open bugs against 
997 your packages.
998         <p>
999 Maintainers interact with the BTS via email addresses at
1000 <tt/bugs.debian.org/.  Documentation on available commands can be
1001 found at <url id="http://www.debian.org/Bugs/">, or, if you have
1002 installed the <prgn/debian-doc/ package, you can look at the local
1003 files <tt>/usr/doc/debian/bug-*</tt>.
1004         <p>
1005 Often as a package maintainer, you find bugs in other packages or else
1006 have bugs reported to your packages which need to be reassigned.  The
1007 BTS instructions can tell you how to do this.  Make sure the bug is
1008 not already filed against a package.  Try to do a good job reporting a
1009 bug and redirecting it to the proper location.  For extra credit, you
1010 can go through other packages, merging bugs which are reported more
1011 than once, or setting bug severities to "fixed" when they have already
1012 been fixed.  Note that when you are neither the bug submitter nor the
1013 package maintainer, you are not empowered to actually close the bug
1014 (unless you secure permission from the maintainer).
1015
1016
1017       <sect>When bugs are closed by new uploads
1018         <p>
1019 If you fix a bug in your packages, it is your responsibility as the
1020 package maintainer to close the bug when it has been fixed.  However,
1021 you should not close the bug until the package which fixes the bug has
1022 been accepted into the Debian archive.  Therefore, once you get
1023 notification that your updated package has been installed into the
1024 archive, you can and should close the bug in the BTS.
1025         <p>
1026 Again, see the BTS documentation for details on how to do this.
1027 Often, it's sufficient to mail the <tt/.changes file to
1028 <email/<var/XXX/-done@bugs.debian.org/, where <var/XXX/ is your bug
1029 number.
1030
1031       <sect id="lintian-reports">Lintian reports
1032         <p>
1033 You should periodically get the new <prgn/lintian/ from `unstable' and
1034 check over all your packages.  Alternatively you can check for your
1035 maintainer email address at the <url
1036 id="http://www.debian.org/lintian/" name="online lintian report">.
1037 That report, which is updated automatically, contains <prgn/lintian/
1038 reports against the latest version of the distribution (usually from
1039 'unstable') using the latest <prgn/lintian/.
1040
1041
1042       <sect>Reporting lots of bugs at once
1043         <p>
1044 If you report more then 10 bugs on the same topic at once, it is
1045 recommended that you send a message to
1046 <email/debian-devel@lists.debian.org/ describing your intention before
1047 submitting the report. This will allow other developers to verify
1048 that the bug is a real problem. In addition, it will help prevent
1049 a situation in which several maintainers start filing the same bug
1050 report simultaneously.
1051         <p>
1052 Note that when sending lots of bugs on the same subject, you should
1053 send the bug report to <email/maintonly@bugs.debian.org/ so that the
1054 bug report is not forwarded to the bug distribution mailing list.
1055
1056
1057     <chapt id="tools">Whirlwind Tour of Debian Maintainer Tools
1058       <p>
1059 This section contains a rough overview of the tools available to
1060 maintainers.  These tools are meant to help convenience developers and 
1061 free their time for critical tasks.  
1062       <p>
1063 Some people prefer to use high-level package maintenance tools and
1064 some do not.  Debian is officially agnostic on this issue, other than
1065 making the attempt to accomodate the reasonable wishes of developers.
1066 Therefore, this section is not meant to stipulate to anyone which
1067 tools they should use or how they should go about with their duties of
1068 maintainership.  Nor is it meant to endorse any particular tool to the
1069 exclusion of a competing tool.
1070       <p>
1071 Most of the descriptions of these packages come from the actual
1072 package descriptions themselves.
1073
1074       <sect id="dpkg-dev">
1075         <heading><prgn>dpkg-dev</prgn>
1076         <p>
1077 <prgn>dpkg-dev</prgn> contains the tools (including
1078 <prgn/dpkg-source/) required to unpack, build and upload Debian source
1079 packages.  These utilities contain the fundamental, low-level
1080 functionality required to create and manipulated packages; as such,
1081 they are required for any Debian maintainer.
1082
1083       <sect id="lintian">
1084         <heading><prgn>lintian</prgn>
1085         <p>
1086 <prgn>Lintian</prgn> dissects Debian packages and reports bugs and
1087 policy violations. It contains automated checks for many aspects of
1088 Debian policy as well as some checks for common errors.  The use of
1089 <prgn>lintian</prgn> has already been discussed in <ref
1090 id="upload-checking"> and <ref id="lintian-reports">.
1091
1092       <sect id="debhelper">
1093         <heading><prgn>debhelper</prgn>
1094         <p>
1095 <prgn>debhelper</prgn> is a collection of programs that can be used in
1096 <tt>debian/rules</tt> to automate common tasks related to building
1097 binary Debian packages. Programs are included to install various files
1098 into your package, compress files, fix file permissions, integrate
1099 your package with the Debian menu system.
1100         <p>
1101 Unlike <prgn>debmake</prgn>, <prgn>debhelper</prgn> is broken into
1102 several small, granular commands which act in a consistent manner.  As
1103 such, it allows a greater granularity of control than
1104 <prgn>debmake</prgn>.
1105
1106       <sect id="debmake">
1107         <heading><prgn>debmake</prgn>
1108         <p>
1109 <prgn>debmake</prgn>, a pre-cursor to <prgn>debhelper</prgn>, is a
1110 less granular <tt>debian/rules</tt> assistant. It includes two main
1111 programs: <prgn>deb-make</prgn>, which can be used to help a
1112 maintainer convert a regular (non-Debian) source archive into a Debian
1113 source package; and <prgn>debstd</prgn>, which incorporates in one big
1114 shot the same sort of automated functions that one finds in
1115 <prgn>debhelper</prgn>.
1116
1117       <sect id="cvs-buildpackage">
1118         <heading><prgn>cvs-buildpackage</prgn>
1119         <p>
1120 <prgn>cvs-buildpackage</prgn> provides the capability to inject or
1121 import Debian source packages into a CVS repository, build a Debian
1122 package from the CVS repository, and helps in integrating upstream
1123 changes into the repository.
1124         <p>
1125 These utilities provide an infrastructure to facilitate the use of CVS
1126 by Debian maintainers. This allows one to keep separate CVS branches
1127 of a package for <em/stable/, <em/unstable/, and possibly
1128 <em/experimental/ distributions, along with the other benefits of a
1129 version control system.
1130
1131       <sect id="dupload">
1132         <heading><prgn>dupload</prgn>
1133         <p>
1134 <prgn>dupload</prgn> is a package and a script to automagically upload
1135 Debian packages to the Debian archive, to log the upload, and to send
1136 mail about the upload of a package.  You can configure it for new
1137 upload locations or methods.
1138
1139   </book>
1140 </debiandoc>
1141
1142 <!-- Keep this comment at the end of the file
1143 Local variables:
1144 mode: sgml
1145 sgml-omittag:t
1146 sgml-shorttag:t
1147 sgml-minimize-attributes:nil
1148 sgml-always-quote-attributes:t
1149 sgml-indent-step:2
1150 sgml-indent-data:nil
1151 sgml-parent-document:nil
1152 sgml-exposed-tags:nil
1153 sgml-local-catalogs:nil
1154 sgml-local-ecat-files:nil
1155 End:
1156 -->