chiark / gitweb /
Japanese: update
[developers-reference.git] / po4a / ja / best-pkging-practices.po
1 # Debian Developer's Reference (Japanese)
2 # Hideki Yamane (Debian-JP) <henrich@debian.or.jp>, 2008-2010.
3 #
4 msgid ""
5 msgstr ""
6 "Project-Id-Version: developers-reference 3.4.4\n"
7 "POT-Creation-Date: 2010-01-04 00:20+0100\n"
8 "PO-Revision-Date: 2010-01-13 02:27+0900\n"
9 "Last-Translator: Hideki Yamane (Debian-JP) <henrich@debian.or.jp>\n"
10 "Language-Team: Debian JP Project <debian-doc@debian.or.jp>\n"
11 "MIME-Version: 1.0\n"
12 "Content-Type: text/plain; charset=UTF-8\n"
13 "Content-Transfer-Encoding: 8bit\n"
14
15 # type: Content of: <chapter><title>
16 #. type: Content of: <chapter><title>
17 #: best-pkging-practices.dbk:7
18 msgid "Best Packaging Practices"
19 msgstr "パッケージ化のベストプラクティス"
20
21 # type: Content of: <chapter><para>
22 #. type: Content of: <chapter><para>
23 #: best-pkging-practices.dbk:9
24 #, fuzzy
25 msgid ""
26 "Debian's quality is largely due to the <ulink url=\"&url-debian-policy;"
27 "\">Debian Policy</ulink>, which defines explicit baseline requirements which "
28 "all Debian packages must fulfill.  Yet there is also a shared history of "
29 "experience which goes beyond the Debian Policy, an accumulation of years of "
30 "experience in packaging.  Many very talented people have created great "
31 "tools, tools which help you, the Debian maintainer, create and maintain "
32 "excellent packages."
33 msgstr ""
34 "Debian の品質は、全ての Debian パッケージが満たす必要がある基本的要求を明示的"
35 "に規定している <ulink url=\"&url-debian-policy;\">Debian Policy</ulink> に大"
36 "きく依存しています。"
37
38 # type: Content of: <chapter><para>
39 #. type: Content of: <chapter><para>
40 #: best-pkging-practices.dbk:18
41 msgid ""
42 "This chapter provides some best practices for Debian developers.  All "
43 "recommendations are merely that, and are not requirements or policy.  These "
44 "are just some subjective hints, advice and pointers collected from Debian "
45 "developers.  Feel free to pick and choose whatever works best for you."
46 msgstr ""
47
48 # type: Content of: <chapter><section><title>
49 #. type: Content of: <chapter><section><title>
50 #: best-pkging-practices.dbk:24
51 msgid "Best practices for <filename>debian/rules</filename>"
52 msgstr "<filename>debian/rules</filename> についてのベストプラクティス"
53
54 # type: Content of: <chapter><section><para>
55 #. type: Content of: <chapter><section><para>
56 #: best-pkging-practices.dbk:26
57 msgid ""
58 "The following recommendations apply to the <filename>debian/rules</filename> "
59 "file.  Since <filename>debian/rules</filename> controls the build process "
60 "and selects the files which go into the package (directly or indirectly), "
61 "it's usually the file maintainers spend the most time on."
62 msgstr ""
63
64 # type: Content of: <chapter><section><section><title>
65 #. type: Content of: <chapter><section><section><title>
66 #: best-pkging-practices.dbk:32
67 msgid "Helper scripts"
68 msgstr "補助スクリプト"
69
70 # type: Content of: <chapter><section><section><para>
71 #. type: Content of: <chapter><section><section><para>
72 #: best-pkging-practices.dbk:34
73 msgid ""
74 "The rationale for using helper scripts in <filename>debian/rules</filename> "
75 "is that they let maintainers use and share common logic among many "
76 "packages.  Take for instance the question of installing menu entries: you "
77 "need to put the file into <filename>/usr/share/menu</filename> (or "
78 "<filename>/usr/lib/menu</filename> for executable binary menufiles, if this "
79 "is needed), and add commands to the maintainer scripts to register and "
80 "unregister the menu entries.  Since this is a very common thing for packages "
81 "to do, why should each maintainer rewrite all this on their own, sometimes "
82 "with bugs? Also, supposing the menu directory changed, every package would "
83 "have to be changed."
84 msgstr ""
85
86 # type: Content of: <chapter><section><section><para>
87 #. type: Content of: <chapter><section><section><para>
88 #: best-pkging-practices.dbk:45
89 msgid ""
90 "Helper scripts take care of these issues.  Assuming you comply with the "
91 "conventions expected by the helper script, the helper takes care of all the "
92 "details.  Changes in policy can be made in the helper script; then packages "
93 "just need to be rebuilt with the new version of the helper and no other "
94 "changes."
95 msgstr ""
96
97 # type: Content of: <chapter><section><section><para>
98 #. type: Content of: <chapter><section><section><para>
99 #: best-pkging-practices.dbk:52
100 msgid ""
101 "<xref linkend=\"tools\"/> contains a couple of different helpers.  The most "
102 "common and best (in our opinion) helper system is <systemitem role=\"package"
103 "\">debhelper</systemitem>.  Previous helper systems, such as <systemitem "
104 "role=\"package\">debmake</systemitem>, were monolithic: you couldn't pick "
105 "and choose which part of the helper you found useful, but had to use the "
106 "helper to do everything.  <systemitem role=\"package\">debhelper</"
107 "systemitem>, however, is a number of separate little <command>dh_*</command> "
108 "programs.  For instance, <command>dh_installman</command> installs and "
109 "compresses man pages, <command>dh_installmenu</command> installs menu files, "
110 "and so on.  Thus, it offers enough flexibility to be able to use the little "
111 "helper scripts, where useful, in conjunction with hand-crafted commands in "
112 "<filename>debian/rules</filename>."
113 msgstr ""
114
115 # type: Content of: <chapter><section><section><para>
116 #. type: Content of: <chapter><section><section><para>
117 #: best-pkging-practices.dbk:66
118 msgid ""
119 "You can get started with <systemitem role=\"package\">debhelper</systemitem> "
120 "by reading <citerefentry> <refentrytitle>debhelper</refentrytitle> "
121 "<manvolnum>1</manvolnum> </citerefentry>, and looking at the examples that "
122 "come with the package.  <command>dh_make</command>, from the <systemitem "
123 "role=\"package\">dh-make</systemitem> package (see <xref linkend=\"dh-make\"/"
124 "> ), can be used to convert a vanilla source package to a <systemitem role="
125 "\"package\">debhelper</systemitem>ized package.  This shortcut, though, "
126 "should not convince you that you do not need to bother understanding the "
127 "individual <command>dh_*</command> helpers.  If you are going to use a "
128 "helper, you do need to take the time to learn to use that helper, to learn "
129 "its expectations and behavior."
130 msgstr ""
131
132 # type: Content of: <chapter><section><section><para>
133 #. type: Content of: <chapter><section><section><para>
134 #: best-pkging-practices.dbk:79
135 msgid ""
136 "Some people feel that vanilla <filename>debian/rules</filename> files are "
137 "better, since you don't have to learn the intricacies of any helper system.  "
138 "This decision is completely up to you.  Use what works for you.  Many "
139 "examples of vanilla <filename>debian/rules</filename> files are available at "
140 "<ulink url=\"&url-rules-files;\"></ulink>."
141 msgstr ""
142
143 # type: Content of: <chapter><section><section><title>
144 #. type: Content of: <chapter><section><section><title>
145 #: best-pkging-practices.dbk:88
146 msgid "Separating your patches into multiple files"
147 msgstr ""
148
149 # type: Content of: <chapter><section><section><para>
150 #. type: Content of: <chapter><section><section><para>
151 #: best-pkging-practices.dbk:90
152 msgid ""
153 "Big, complex packages may have many bugs that you need to deal with.  If you "
154 "correct a number of bugs directly in the source, and you're not careful, it "
155 "can get hard to differentiate the various patches that you applied.  It can "
156 "get quite messy when you have to update the package to a new upstream "
157 "version which integrates some of the fixes (but not all).  You can't take "
158 "the total set of diffs (e.g., from <filename>.diff.gz</filename>) and work "
159 "out which patch sets to back out as a unit as bugs are fixed upstream."
160 msgstr ""
161
162 #. type: Content of: <chapter><section><section><para>
163 #: best-pkging-practices.dbk:99
164 msgid ""
165 "Fortunately, with the source format “3.0 (quilt)” it is now possible to keep "
166 "patches separate without having to modify <filename>debian/rules</filename> "
167 "to setup a patch system. Patches are stored in <filename>debian/patches/</"
168 "filename> and when the source package is unpacked patches listed in "
169 "<filename>debian/patches/series</filename> are automatically applied.  As "
170 "the name implies, patches can be managed with <command>quilt</command>."
171 msgstr ""
172
173 #. type: Content of: <chapter><section><section><para>
174 #: best-pkging-practices.dbk:107
175 msgid ""
176 "When using the older source “1.0”, it's also possible to separate patches "
177 "but a dedicated patch system must be used: the patch files are shipped "
178 "within the Debian patch file (<filename>.diff.gz</filename>), usually within "
179 "the <filename>debian/</filename> directory. The only difference is that they "
180 "aren't applied immediately by <command>dpkg-source</command>, but by the "
181 "<literal>build</literal> rule of <filename>debian/rules</filename>, through "
182 "a dependency on the <literal>patch</literal> rule.  Conversely, they are "
183 "reverted in the <literal>clean</literal> rule, through a dependency on the "
184 "<literal>unpatch</literal> rule."
185 msgstr ""
186
187 #. type: Content of: <chapter><section><section><para>
188 #: best-pkging-practices.dbk:119
189 msgid ""
190 "<command>quilt</command> is the recommended tool for this.  It does all of "
191 "the above, and also allows to manage patch series.  See the <systemitem role="
192 "\"package\">quilt</systemitem> package for more information."
193 msgstr ""
194
195 #. type: Content of: <chapter><section><section><para>
196 #: best-pkging-practices.dbk:125
197 msgid ""
198 "There are other tools to manage patches, like <command>dpatch</command>, and "
199 "the patch system integrated with <systemitem role=\"package\">cdbs</"
200 "systemitem>."
201 msgstr ""
202
203 # type: Content of: <chapter><section><section><title>
204 #. type: Content of: <chapter><section><section><title>
205 #: best-pkging-practices.dbk:132
206 msgid "Multiple binary packages"
207 msgstr ""
208
209 # type: Content of: <chapter><section><section><para>
210 #. type: Content of: <chapter><section><section><para>
211 #: best-pkging-practices.dbk:134
212 msgid ""
213 "A single source package will often build several binary packages, either to "
214 "provide several flavors of the same software (e.g., the <systemitem role="
215 "\"package\">vim</systemitem> source package) or to make several small "
216 "packages instead of a big one (e.g., so the user can install only the subset "
217 "needed, and thus save some disk space)."
218 msgstr ""
219
220 # type: Content of: <chapter><section><section><para>
221 #. type: Content of: <chapter><section><section><para>
222 #: best-pkging-practices.dbk:141
223 msgid ""
224 "The second case can be easily managed in <filename>debian/rules</filename>.  "
225 "You just need to move the appropriate files from the build directory into "
226 "the package's temporary trees.  You can do this using <command>install</"
227 "command> or <command>dh_install</command> from <systemitem role=\"package"
228 "\">debhelper</systemitem>.  Be sure to check the different permutations of "
229 "the various packages, ensuring that you have the inter-package dependencies "
230 "set right in <filename>debian/control</filename>."
231 msgstr ""
232
233 # type: Content of: <chapter><section><section><para>
234 #. type: Content of: <chapter><section><section><para>
235 #: best-pkging-practices.dbk:150
236 msgid ""
237 "The first case is a bit more difficult since it involves multiple recompiles "
238 "of the same software but with different configuration options.  The "
239 "<systemitem role=\"package\">vim</systemitem> source package is an example "
240 "of how to manage this using an hand-crafted <filename>debian/rules</"
241 "filename> file."
242 msgstr ""
243
244 # type: Content of: <chapter><section><title>
245 #. type: Content of: <chapter><section><title>
246 #: best-pkging-practices.dbk:162
247 msgid "Best practices for <filename>debian/control</filename>"
248 msgstr ""
249
250 # type: Content of: <chapter><section><para>
251 #. type: Content of: <chapter><section><para>
252 #: best-pkging-practices.dbk:164
253 msgid ""
254 "The following practices are relevant to the <filename>debian/control</"
255 "filename> file.  They supplement the <ulink url=\"&url-debian-policy;ch-"
256 "binary.html#s-descriptions\">Policy on package descriptions</ulink>."
257 msgstr ""
258
259 # type: Content of: <chapter><section><para>
260 #. type: Content of: <chapter><section><para>
261 #: best-pkging-practices.dbk:170
262 msgid ""
263 "The description of the package, as defined by the corresponding field in the "
264 "<filename>control</filename> file, contains both the package synopsis and "
265 "the long description for the package.  <xref linkend=\"bpp-desc-basics\"/> "
266 "describes common guidelines for both parts of the package description.  "
267 "Following that, <xref linkend=\"bpp-pkg-synopsis\"/> provides guidelines "
268 "specific to the synopsis, and <xref linkend=\"bpp-pkg-desc\"/> contains "
269 "guidelines specific to the description."
270 msgstr ""
271
272 # type: Content of: <chapter><section><section><title>
273 #. type: Content of: <chapter><section><section><title>
274 #: best-pkging-practices.dbk:179
275 msgid "General guidelines for package descriptions"
276 msgstr ""
277
278 # type: Content of: <chapter><section><section><para>
279 #. type: Content of: <chapter><section><section><para>
280 #: best-pkging-practices.dbk:181
281 msgid ""
282 "The package description should be written for the average likely user, the "
283 "average person who will use and benefit from the package.  For instance, "
284 "development packages are for developers, and can be technical in their "
285 "language.  More general-purpose applications, such as editors, should be "
286 "written for a less technical user."
287 msgstr ""
288
289 # type: Content of: <chapter><section><section><para>
290 #. type: Content of: <chapter><section><section><para>
291 #: best-pkging-practices.dbk:188
292 msgid ""
293 "Our review of package descriptions lead us to conclude that most package "
294 "descriptions are technical, that is, are not written to make sense for non-"
295 "technical users.  Unless your package really is only for technical users, "
296 "this is a problem."
297 msgstr ""
298
299 # type: Content of: <chapter><section><section><para>
300 #. type: Content of: <chapter><section><section><para>
301 #: best-pkging-practices.dbk:194
302 msgid ""
303 "How do you write for non-technical users? Avoid jargon.  Avoid referring to "
304 "other applications or frameworks that the user might not be familiar with — "
305 "GNOME or KDE is fine, since users are probably familiar with these terms, "
306 "but GTK+ is probably not.  Try not to assume any knowledge at all.  If you "
307 "must use technical terms, introduce them."
308 msgstr ""
309
310 # type: Content of: <chapter><section><section><para>
311 #. type: Content of: <chapter><section><section><para>
312 #: best-pkging-practices.dbk:201
313 msgid ""
314 "Be objective.  Package descriptions are not the place for advocating your "
315 "package, no matter how much you love it.  Remember that the reader may not "
316 "care about the same things you care about."
317 msgstr ""
318
319 # type: Content of: <chapter><section><section><para>
320 #. type: Content of: <chapter><section><section><para>
321 #: best-pkging-practices.dbk:206
322 msgid ""
323 "References to the names of any other software packages, protocol names, "
324 "standards, or specifications should use their canonical forms, if one "
325 "exists.  For example, use X Window System, X11, or X; not X Windows, X-"
326 "Windows, or X Window.  Use GTK+, not GTK or gtk.  Use GNOME, not Gnome.  Use "
327 "PostScript, not Postscript or postscript."
328 msgstr ""
329
330 # type: Content of: <chapter><section><section><para>
331 #. type: Content of: <chapter><section><section><para>
332 #: best-pkging-practices.dbk:213
333 msgid ""
334 "If you are having problems writing your description, you may wish to send it "
335 "along to &email-debian-l10n-english; and request feedback."
336 msgstr ""
337
338 # type: Content of: <chapter><section><section><title>
339 #. type: Content of: <chapter><section><section><title>
340 #: best-pkging-practices.dbk:219
341 msgid "The package synopsis, or short description"
342 msgstr ""
343
344 #. type: Content of: <chapter><section><section><para>
345 #: best-pkging-practices.dbk:221
346 msgid ""
347 "Policy says the synopsis line (the short description) must be concise, not "
348 "repeating the package name, but also informative."
349 msgstr ""
350
351 #. type: Content of: <chapter><section><section><para>
352 #: best-pkging-practices.dbk:225
353 msgid ""
354 "The synopsis functions as a phrase describing the package, not a complete "
355 "sentence, so sentential punctuation is inappropriate: it does not need extra "
356 "capital letters or a final period (full stop). It should also omit any "
357 "initial indefinite or definite article - \"a\", \"an\", or \"the\". Thus for "
358 "instance:"
359 msgstr ""
360
361 #. type: Content of: <chapter><section><section><screen>
362 #: best-pkging-practices.dbk:231
363 #, no-wrap
364 msgid ""
365 "Package: libeg0\n"
366 "Description: exemplification support library\n"
367 msgstr ""
368
369 #. type: Content of: <chapter><section><section><para>
370 #: best-pkging-practices.dbk:235
371 msgid ""
372 "Technically this is a noun phrase minus articles, as opposed to a verb "
373 "phrase.  A good heuristic is that it should be possible to substitute the "
374 "package name and synopsis into this formula:"
375 msgstr ""
376
377 #. type: Content of: <chapter><section><section><para>
378 #: best-pkging-practices.dbk:240
379 msgid ""
380 "The package <replaceable>name</replaceable> provides {a,an,the,some} "
381 "<replaceable>synopsis</replaceable>."
382 msgstr ""
383
384 #. type: Content of: <chapter><section><section><para>
385 #: best-pkging-practices.dbk:244
386 msgid ""
387 "Sets of related packages may use an alternative scheme that divides the "
388 "synopsis into two parts, the first a description of the whole suite and the "
389 "second a summary of the package's role within it:"
390 msgstr ""
391
392 #. type: Content of: <chapter><section><section><screen>
393 #: best-pkging-practices.dbk:249
394 #, no-wrap
395 msgid ""
396 "Package: eg-tools\n"
397 "Description: simple exemplification system (utilities)\n"
398 "\t\t\t              \n"
399 "Package: eg-doc\n"
400 "Description: simple exemplification system - documentation\n"
401 msgstr ""
402
403 #. type: Content of: <chapter><section><section><para>
404 #: best-pkging-practices.dbk:256
405 msgid ""
406 "These synopses follow a modified formula. Where a package "
407 "\"<replaceable>name</replaceable>\" has a synopsis \"<replaceable>suite</"
408 "replaceable> (<replaceable>role</replaceable>)\" or \"<replaceable>suite</"
409 "replaceable> - <replaceable>role</replaceable>\", the elements should be "
410 "phrased so that they fit into the formula:"
411 msgstr ""
412
413 #. type: Content of: <chapter><section><section><para>
414 #: best-pkging-practices.dbk:263
415 msgid ""
416 "The package <replaceable>name</replaceable> provides {a,an,the} "
417 "<replaceable>role</replaceable> for the <replaceable>suite</replaceable>."
418 msgstr ""
419
420 # type: Content of: <chapter><section><section><title>
421 #. type: Content of: <chapter><section><section><title>
422 #: best-pkging-practices.dbk:269
423 msgid "The long description"
424 msgstr ""
425
426 # type: Content of: <chapter><section><section><para>
427 #. type: Content of: <chapter><section><section><para>
428 #: best-pkging-practices.dbk:271
429 msgid ""
430 "The long description is the primary information available to the user about "
431 "a package before they install it.  It should provide all the information "
432 "needed to let the user decide whether to install the package.  Assume that "
433 "the user has already read the package synopsis."
434 msgstr ""
435
436 # type: Content of: <chapter><section><section><para>
437 #. type: Content of: <chapter><section><section><para>
438 #: best-pkging-practices.dbk:277
439 msgid "The long description should consist of full and complete sentences."
440 msgstr ""
441
442 # type: Content of: <chapter><section><section><para>
443 #. type: Content of: <chapter><section><section><para>
444 #: best-pkging-practices.dbk:280
445 msgid ""
446 "The first paragraph of the long description should answer the following "
447 "questions: what does the package do? what task does it help the user "
448 "accomplish? It is important to describe this in a non-technical way, unless "
449 "of course the audience for the package is necessarily technical."
450 msgstr ""
451
452 # type: Content of: <chapter><section><section><para>
453 #. type: Content of: <chapter><section><section><para>
454 #: best-pkging-practices.dbk:286
455 msgid ""
456 "The following paragraphs should answer the following questions: Why do I as "
457 "a user need this package? What other features does the package have? What "
458 "outstanding features and deficiencies are there compared to other packages "
459 "(e.g., if you need X, use Y instead)? Is this package related to other "
460 "packages in some way that is not handled by the package manager (e.g., this "
461 "is the client for the foo server)?"
462 msgstr ""
463
464 # type: Content of: <chapter><section><section><para>
465 #. type: Content of: <chapter><section><section><para>
466 #: best-pkging-practices.dbk:294
467 msgid ""
468 "Be careful to avoid spelling and grammar mistakes.  Ensure that you spell-"
469 "check it.  Both <command>ispell</command> and <command>aspell</command> have "
470 "special modes for checking <filename>debian/control</filename> files:"
471 msgstr ""
472
473 #. type: Content of: <chapter><section><section><screen>
474 #: best-pkging-practices.dbk:299
475 #, no-wrap
476 msgid "ispell -d american -g debian/control\n"
477 msgstr ""
478
479 #. type: Content of: <chapter><section><section><screen>
480 #: best-pkging-practices.dbk:302
481 #, no-wrap
482 msgid "aspell -d en -D -c debian/control\n"
483 msgstr ""
484
485 # type: Content of: <chapter><section><section><para>
486 #. type: Content of: <chapter><section><section><para>
487 #: best-pkging-practices.dbk:305
488 msgid ""
489 "Users usually expect these questions to be answered in the package "
490 "description:"
491 msgstr ""
492
493 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
494 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
495 #: best-pkging-practices.dbk:310
496 msgid ""
497 "What does the package do? If it is an add-on to another package, then the "
498 "short description of the package we are an add-on to should be put in here."
499 msgstr ""
500
501 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
502 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
503 #: best-pkging-practices.dbk:316
504 msgid ""
505 "Why should I want this package? This is related to the above, but not the "
506 "same (this is a mail user agent; this is cool, fast, interfaces with PGP and "
507 "LDAP and IMAP, has features X, Y, and Z)."
508 msgstr ""
509
510 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
511 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
512 #: best-pkging-practices.dbk:323
513 msgid ""
514 "If this package should not be installed directly, but is pulled in by "
515 "another package, this should be mentioned."
516 msgstr ""
517
518 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
519 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
520 #: best-pkging-practices.dbk:329
521 msgid ""
522 "If the package is <literal>experimental</literal>, or there are other "
523 "reasons it should not be used, if there are other packages that should be "
524 "used instead, it should be here as well."
525 msgstr ""
526
527 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
528 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
529 #: best-pkging-practices.dbk:336
530 msgid ""
531 "How is this package different from the competition? Is it a better "
532 "implementation? more features? different features? Why should I choose this "
533 "package."
534 msgstr ""
535
536 # type: Content of: <chapter><section><section><title>
537 #. type: Content of: <chapter><section><section><title>
538 #: best-pkging-practices.dbk:349
539 msgid "Upstream home page"
540 msgstr ""
541
542 # type: Content of: <chapter><section><section><para>
543 #. type: Content of: <chapter><section><section><para>
544 #: best-pkging-practices.dbk:351
545 msgid ""
546 "We recommend that you add the URL for the package's home page in the "
547 "<literal>Homepage</literal> field of the <literal>Source</literal> section "
548 "in <filename>debian/control</filename>.  Adding this information in the "
549 "package description itself is considered deprecated."
550 msgstr ""
551
552 # type: Content of: <chapter><section><section><title>
553 #. type: Content of: <chapter><section><section><title>
554 #: best-pkging-practices.dbk:359
555 msgid "Version Control System location"
556 msgstr ""
557
558 # type: Content of: <chapter><section><section><para>
559 #. type: Content of: <chapter><section><section><para>
560 #: best-pkging-practices.dbk:361
561 msgid ""
562 "There are additional fields for the location of the Version Control System "
563 "in <filename>debian/control</filename>."
564 msgstr ""
565
566 # type: Content of: <chapter><section><section><section><title>
567 #. type: Content of: <chapter><section><section><section><title>
568 #: best-pkging-practices.dbk:365
569 msgid "Vcs-Browser"
570 msgstr "Vcs-Browser"
571
572 # type: Content of: <chapter><section><section><section><para>
573 #. type: Content of: <chapter><section><section><section><para>
574 #: best-pkging-practices.dbk:367
575 msgid ""
576 "Value of this field should be a <literal>http://</literal> URL pointing to a "
577 "web-browsable copy of the Version Control System repository used to maintain "
578 "the given package, if available."
579 msgstr ""
580
581 # type: Content of: <chapter><section><section><section><para>
582 #. type: Content of: <chapter><section><section><section><para>
583 #: best-pkging-practices.dbk:372
584 msgid ""
585 "The information is meant to be useful for the final user, willing to browse "
586 "the latest work done on the package (e.g.  when looking for the patch fixing "
587 "a bug tagged as <literal>pending</literal> in the bug tracking system)."
588 msgstr ""
589
590 # type: Content of: <chapter><section><section><section><title>
591 #. type: Content of: <chapter><section><section><section><title>
592 #: best-pkging-practices.dbk:379
593 msgid "Vcs-*"
594 msgstr "Vcs-*"
595
596 # type: Content of: <chapter><section><section><section><para>
597 #. type: Content of: <chapter><section><section><section><para>
598 #: best-pkging-practices.dbk:381
599 msgid ""
600 "Value of this field should be a string identifying unequivocally the "
601 "location of the Version Control System repository used to maintain the given "
602 "package, if available.  <literal>*</literal> identify the Version Control "
603 "System; currently the following systems are supported by the package "
604 "tracking system: <literal>arch</literal>, <literal>bzr</literal> (Bazaar), "
605 "<literal>cvs</literal>, <literal>darcs</literal>, <literal>git</literal>, "
606 "<literal>hg</literal> (Mercurial), <literal>mtn</literal> (Monotone), "
607 "<literal>svn</literal> (Subversion).  It is allowed to specify different VCS "
608 "fields for the same package: they will all be shown in the PTS web interface."
609 msgstr ""
610
611 # type: Content of: <chapter><section><section><section><para>
612 #. type: Content of: <chapter><section><section><section><para>
613 #: best-pkging-practices.dbk:392
614 msgid ""
615 "The information is meant to be useful for a user knowledgeable in the given "
616 "Version Control System and willing to build the current version of a package "
617 "from the VCS sources.  Other uses of this information might include "
618 "automatic building of the latest VCS version of the given package.  To this "
619 "end the location pointed to by the field should better be version agnostic "
620 "and point to the main branch (for VCSs supporting such a concept).  Also, "
621 "the location pointed to should be accessible to the final user; fulfilling "
622 "this requirement might imply pointing to an anonymous access of the "
623 "repository instead of pointing to an SSH-accessible version of the same."
624 msgstr ""
625
626 # type: Content of: <chapter><section><section><section><para>
627 #. type: Content of: <chapter><section><section><section><para>
628 #: best-pkging-practices.dbk:403
629 msgid ""
630 "In the following example, an instance of the field for a Subversion "
631 "repository of the <systemitem role=\"package\">vim</systemitem> package is "
632 "shown.  Note how the URL is in the <literal>svn://</literal> scheme (instead "
633 "of <literal>svn+ssh://</literal>) and how it points to the <filename>trunk/</"
634 "filename> branch.  The use of the <literal>Vcs-Browser</literal> and "
635 "<literal>Homepage</literal> fields described above is also shown."
636 msgstr ""
637
638 # type: Content of: <chapter><section><section><section><screen>
639 #. type: Content of: <chapter><section><section><section><screen>
640 #: best-pkging-practices.dbk:412
641 #, fuzzy, no-wrap
642 msgid ""
643 "  Source: vim\n"
644 "  Section: editors\n"
645 "  Priority: optional\n"
646 "  &lt;snip&gt;\n"
647 "  Vcs-Svn: svn://svn.debian.org/svn/pkg-vim/trunk/packages/vim\n"
648 "  Vcs-Browser: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim\n"
649 "  Homepage: http://www.vim.org\n"
650 msgstr ""
651 "\n"
652 "  Source: vim\n"
653 "  Section: editors\n"
654 "  Priority: optional\n"
655 "  &lt;snip&gt;\n"
656 "  Vcs-Svn: svn://svn.debian.org/svn/pkg-vim/trunk/packages/vim\n"
657 "  Vcs-Browser: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim\n"
658 "  Homepage: http://www.vim.org\n"
659
660 # type: Content of: <chapter><section><title>
661 #. type: Content of: <chapter><section><title>
662 #: best-pkging-practices.dbk:427
663 msgid "Best practices for <filename>debian/changelog</filename>"
664 msgstr ""
665
666 # type: Content of: <chapter><section><para>
667 #. type: Content of: <chapter><section><para>
668 #: best-pkging-practices.dbk:429
669 msgid ""
670 "The following practices supplement the <ulink url=\"&url-debian-policy;ch-"
671 "docs.html#s-changelogs\">Policy on changelog files</ulink>."
672 msgstr ""
673
674 # type: Content of: <chapter><section><section><title>
675 #. type: Content of: <chapter><section><section><title>
676 #: best-pkging-practices.dbk:434
677 msgid "Writing useful changelog entries"
678 msgstr ""
679
680 # type: Content of: <chapter><section><section><para>
681 #. type: Content of: <chapter><section><section><para>
682 #: best-pkging-practices.dbk:436
683 msgid ""
684 "The changelog entry for a package revision documents changes in that "
685 "revision, and only them.  Concentrate on describing significant and user-"
686 "visible changes that were made since the last version."
687 msgstr ""
688
689 # type: Content of: <chapter><section><section><para>
690 #. type: Content of: <chapter><section><section><para>
691 #: best-pkging-practices.dbk:441
692 msgid ""
693 "Focus on <emphasis>what</emphasis> was changed — who, how and when are "
694 "usually less important.  Having said that, remember to politely attribute "
695 "people who have provided notable help in making the package (e.g., those who "
696 "have sent in patches)."
697 msgstr ""
698
699 # type: Content of: <chapter><section><section><para>
700 #. type: Content of: <chapter><section><section><para>
701 #: best-pkging-practices.dbk:447
702 msgid ""
703 "There's no need to elaborate the trivial and obvious changes.  You can also "
704 "aggregate several changes in one entry.  On the other hand, don't be overly "
705 "terse if you have undertaken a major change.  Be especially clear if there "
706 "are changes that affect the behaviour of the program.  For further "
707 "explanations, use the <filename>README.Debian</filename> file."
708 msgstr ""
709
710 # type: Content of: <chapter><section><section><para>
711 #. type: Content of: <chapter><section><section><para>
712 #: best-pkging-practices.dbk:454
713 msgid ""
714 "Use common English so that the majority of readers can comprehend it.  Avoid "
715 "abbreviations, tech-speak and jargon when explaining changes that close "
716 "bugs, especially for bugs filed by users that did not strike you as "
717 "particularly technically savvy.  Be polite, don't swear."
718 msgstr ""
719
720 # type: Content of: <chapter><section><section><para>
721 #. type: Content of: <chapter><section><section><para>
722 #: best-pkging-practices.dbk:460
723 msgid ""
724 "It is sometimes desirable to prefix changelog entries with the names of the "
725 "files that were changed.  However, there's no need to explicitly list each "
726 "and every last one of the changed files, especially if the change was small "
727 "or repetitive.  You may use wildcards."
728 msgstr ""
729
730 # type: Content of: <chapter><section><section><para>
731 #. type: Content of: <chapter><section><section><para>
732 #: best-pkging-practices.dbk:466
733 msgid ""
734 "When referring to bugs, don't assume anything.  Say what the problem was, "
735 "how it was fixed, and append the closes: #nnnnn string.  See <xref linkend="
736 "\"upload-bugfix\"/> for more information."
737 msgstr ""
738
739 # type: Content of: <chapter><section><section><title>
740 #. type: Content of: <chapter><section><section><title>
741 #: best-pkging-practices.dbk:473
742 msgid "Common misconceptions about changelog entries"
743 msgstr ""
744
745 # type: Content of: <chapter><section><section><para>
746 #. type: Content of: <chapter><section><section><para>
747 #: best-pkging-practices.dbk:475
748 msgid ""
749 "The changelog entries should <emphasis role=\"strong\">not</emphasis> "
750 "document generic packaging issues (Hey, if you're looking for foo.conf, it's "
751 "in /etc/blah/.), since administrators and users are supposed to be at least "
752 "remotely acquainted with how such things are generally arranged on Debian "
753 "systems.  Do, however, mention if you change the location of a configuration "
754 "file."
755 msgstr ""
756
757 # type: Content of: <chapter><section><section><para>
758 #. type: Content of: <chapter><section><section><para>
759 #: best-pkging-practices.dbk:483
760 msgid ""
761 "The only bugs closed with a changelog entry should be those that are "
762 "actually fixed in the same package revision.  Closing unrelated bugs in the "
763 "changelog is bad practice.  See <xref linkend=\"upload-bugfix\"/> ."
764 msgstr ""
765
766 # type: Content of: <chapter><section><section><para>
767 #. type: Content of: <chapter><section><section><para>
768 #: best-pkging-practices.dbk:488
769 msgid ""
770 "The changelog entries should <emphasis role=\"strong\">not</emphasis> be "
771 "used for random discussion with bug reporters (I don't see segfaults when "
772 "starting foo with option bar; send in more info), general statements on "
773 "life, the universe and everything (sorry this upload took me so long, but I "
774 "caught the flu), or pleas for help (the bug list on this package is huge, "
775 "please lend me a hand).  Such things usually won't be noticed by their "
776 "target audience, but may annoy people who wish to read information about "
777 "actual changes in the package.  See <xref linkend=\"bug-answering\"/> for "
778 "more information on how to use the bug tracking system."
779 msgstr ""
780
781 # type: Content of: <chapter><section><section><para>
782 #. type: Content of: <chapter><section><section><para>
783 #: best-pkging-practices.dbk:499
784 msgid ""
785 "It is an old tradition to acknowledge bugs fixed in non-maintainer uploads "
786 "in the first changelog entry of the proper maintainer upload.  As we have "
787 "version tracking now, it is enough to keep the NMUed changelog entries and "
788 "just mention this fact in your own changelog entry."
789 msgstr ""
790
791 # type: Content of: <chapter><section><section><title>
792 #. type: Content of: <chapter><section><section><title>
793 #: best-pkging-practices.dbk:507
794 msgid "Common errors in changelog entries"
795 msgstr ""
796
797 # type: Content of: <chapter><section><section><para>
798 #. type: Content of: <chapter><section><section><para>
799 #: best-pkging-practices.dbk:509
800 msgid ""
801 "The following examples demonstrate some common errors or examples of bad "
802 "style in changelog entries."
803 msgstr ""
804
805 # type: Content of: <chapter><section><section><screen>
806 #. type: Content of: <chapter><section><section><screen>
807 #: best-pkging-practices.dbk:513
808 #, fuzzy, no-wrap
809 msgid "  * Fixed all outstanding bugs.\n"
810 msgstr ""
811 "\n"
812 "  * Fixed all outstanding bugs.\n"
813
814 # type: Content of: <chapter><section><section><para>
815 #. type: Content of: <chapter><section><section><para>
816 #: best-pkging-practices.dbk:516
817 msgid "This doesn't tell readers anything too useful, obviously."
818 msgstr ""
819
820 # type: Content of: <chapter><section><section><screen>
821 #. type: Content of: <chapter><section><section><screen>
822 #: best-pkging-practices.dbk:519
823 #, fuzzy, no-wrap
824 msgid "  * Applied patch from Jane Random.\n"
825 msgstr ""
826 "\n"
827 "  * Applied patch from Jane Random.\n"
828
829 # type: Content of: <chapter><section><section><para>
830 #. type: Content of: <chapter><section><section><para>
831 #: best-pkging-practices.dbk:522
832 msgid "What was the patch about?"
833 msgstr ""
834
835 # type: Content of: <chapter><section><section><screen>
836 #. type: Content of: <chapter><section><section><screen>
837 #: best-pkging-practices.dbk:525
838 #, fuzzy, no-wrap
839 msgid "  * Late night install target overhaul.\n"
840 msgstr ""
841 "\n"
842 "  * Late night install target overhaul.\n"
843
844 # type: Content of: <chapter><section><section><para>
845 #. type: Content of: <chapter><section><section><para>
846 #: best-pkging-practices.dbk:528
847 msgid ""
848 "Overhaul which accomplished what? Is the mention of late night supposed to "
849 "remind us that we shouldn't trust that code?"
850 msgstr ""
851
852 # type: Content of: <chapter><section><section><screen>
853 #. type: Content of: <chapter><section><section><screen>
854 #: best-pkging-practices.dbk:532
855 #, fuzzy, no-wrap
856 msgid "  * Fix vsync FU w/ ancient CRTs.\n"
857 msgstr ""
858 "\n"
859 "  * Fix vsync FU w/ ancient CRTs.\n"
860
861 # type: Content of: <chapter><section><section><para>
862 #. type: Content of: <chapter><section><section><para>
863 #: best-pkging-practices.dbk:535
864 msgid ""
865 "Too many acronyms, and it's not overly clear what the, uh, fsckup (oops, a "
866 "curse word!) was actually about, or how it was fixed."
867 msgstr ""
868
869 # type: Content of: <chapter><section><section><screen>
870 #. type: Content of: <chapter><section><section><screen>
871 #: best-pkging-practices.dbk:539
872 #, fuzzy, no-wrap
873 msgid "  * This is not a bug, closes: #nnnnnn.\n"
874 msgstr ""
875 "\n"
876 "  * This is not a bug, closes: #nnnnnn.\n"
877
878 # type: Content of: <chapter><section><section><para>
879 #. type: Content of: <chapter><section><section><para>
880 #: best-pkging-practices.dbk:542
881 msgid ""
882 "First of all, there's absolutely no need to upload the package to convey "
883 "this information; instead, use the bug tracking system.  Secondly, there's "
884 "no explanation as to why the report is not a bug."
885 msgstr ""
886
887 # type: Content of: <chapter><section><section><screen>
888 #. type: Content of: <chapter><section><section><screen>
889 #: best-pkging-practices.dbk:547
890 #, fuzzy, no-wrap
891 msgid "  * Has been fixed for ages, but I forgot to close; closes: #54321.\n"
892 msgstr ""
893 "\n"
894 "  * Has been fixed for ages, but I forgot to close; closes: #54321.\n"
895
896 # type: Content of: <chapter><section><section><para>
897 #. type: Content of: <chapter><section><section><para>
898 #: best-pkging-practices.dbk:550
899 msgid ""
900 "If for some reason you didn't mention the bug number in a previous changelog "
901 "entry, there's no problem, just close the bug normally in the BTS.  There's "
902 "no need to touch the changelog file, presuming the description of the fix is "
903 "already in (this applies to the fixes by the upstream authors/maintainers as "
904 "well, you don't have to track bugs that they fixed ages ago in your "
905 "changelog)."
906 msgstr ""
907
908 # type: Content of: <chapter><section><section><screen>
909 #. type: Content of: <chapter><section><section><screen>
910 #: best-pkging-practices.dbk:557
911 #, fuzzy, no-wrap
912 msgid "  * Closes: #12345, #12346, #15432\n"
913 msgstr ""
914 "\n"
915 "  * Closes: #12345, #12346, #15432\n"
916
917 # type: Content of: <chapter><section><section><para>
918 #. type: Content of: <chapter><section><section><para>
919 #: best-pkging-practices.dbk:560
920 msgid ""
921 "Where's the description? If you can't think of a descriptive message, start "
922 "by inserting the title of each different bug."
923 msgstr ""
924
925 # type: Content of: <chapter><section><section><title>
926 #. type: Content of: <chapter><section><section><title>
927 #: best-pkging-practices.dbk:566
928 msgid "Supplementing changelogs with NEWS.Debian files"
929 msgstr ""
930
931 # type: Content of: <chapter><section><section><para>
932 #. type: Content of: <chapter><section><section><para>
933 #: best-pkging-practices.dbk:568
934 msgid ""
935 "Important news about changes in a package can also be put in <filename> NEWS."
936 "Debian</filename> files.  The news will be displayed by tools like apt-"
937 "listchanges, before all the rest of the changelogs.  This is the preferred "
938 "means to let the user know about significant changes in a package.  It is "
939 "better than using debconf notes since it is less annoying and the user can "
940 "go back and refer to the <filename> NEWS.Debian</filename> file after the "
941 "install.  And it's better than listing major changes in <filename>README."
942 "Debian</filename>, since the user can easily miss such notes."
943 msgstr ""
944
945 # type: Content of: <chapter><section><section><para>
946 #. type: Content of: <chapter><section><section><para>
947 #: best-pkging-practices.dbk:579
948 msgid ""
949 "The file format is the same as a debian changelog file, but leave off the "
950 "asterisks and describe each news item with a full paragraph when necessary "
951 "rather than the more concise summaries that would go in a changelog.  It's a "
952 "good idea to run your file through <literal>dpkg-parsechangelog</literal> to "
953 "check its formatting as it will not be automatically checked during build as "
954 "the changelog is.  Here is an example of a real <filename>NEWS.Debian </"
955 "filename> file:"
956 msgstr ""
957
958 # type: Content of: <chapter><section><section><screen>
959 #. type: Content of: <chapter><section><section><screen>
960 #: best-pkging-practices.dbk:588
961 #, fuzzy, no-wrap
962 msgid ""
963 "cron (3.0pl1-74) unstable; urgency=low\n"
964 "\n"
965 "    The checksecurity script is no longer included with the cron package:\n"
966 "    it now has its own package, checksecurity. If you liked the\n"
967 "    functionality provided with that script, please install the new\n"
968 "    package.\n"
969 "\n"
970 " -- Steve Greenland &lt;stevegr@debian.org&gt;  Sat,  6 Sep 2003 17:15:03 -0500\n"
971 msgstr ""
972 "\n"
973 "cron (3.0pl1-74) unstable; urgency=low\n"
974 "\n"
975 "    The checksecurity script is no longer included with the cron package:\n"
976 "    it now has its own package, checksecurity. If you liked the\n"
977 "    functionality provided with that script, please install the new\n"
978 "    package.\n"
979 "\n"
980 " -- Steve Greenland &lt;stevegr@debian.org&gt;  Sat,  6 Sep 2003 17:15:03 -0500\n"
981
982 # type: Content of: <chapter><section><section><para>
983 #. type: Content of: <chapter><section><section><para>
984 #: best-pkging-practices.dbk:598
985 msgid ""
986 "The <filename>NEWS.Debian</filename> file is installed as <filename> /usr/"
987 "share/doc/<replaceable>package</replaceable>/NEWS.Debian.gz</filename>.  It "
988 "is compressed, and always has that name even in Debian native packages.  If "
989 "you use <literal>debhelper</literal>, <literal>dh_installchangelogs </"
990 "literal> will install <filename>debian/NEWS</filename> files for you."
991 msgstr ""
992
993 # type: Content of: <chapter><section><section><para>
994 #. type: Content of: <chapter><section><section><para>
995 #: best-pkging-practices.dbk:605
996 msgid ""
997 "Unlike changelog files, you need not update <filename>NEWS.Debian</filename> "
998 "files with every release.  Only update them if you have something "
999 "particularly newsworthy that user should know about.  If you have no news at "
1000 "all, there's no need to ship a <filename>NEWS.Debian</filename> file in your "
1001 "package.  No news is good news!"
1002 msgstr ""
1003
1004 # type: Content of: <chapter><section><title>
1005 #. type: Content of: <chapter><section><title>
1006 #: best-pkging-practices.dbk:627
1007 msgid "Best practices for maintainer scripts"
1008 msgstr ""
1009
1010 # type: Content of: <chapter><section><para>
1011 #. type: Content of: <chapter><section><para>
1012 #: best-pkging-practices.dbk:629
1013 msgid ""
1014 "Maintainer scripts include the files <filename>debian/postinst</filename>, "
1015 "<filename>debian/preinst</filename>, <filename>debian/prerm</filename> and "
1016 "<filename>debian/postrm</filename>.  These scripts take care of any package "
1017 "installation or deinstallation setup which isn't handled merely by the "
1018 "creation or removal of files and directories.  The following instructions "
1019 "supplement the <ulink url=\"&url-debian-policy;\">Debian Policy</ulink>."
1020 msgstr ""
1021
1022 # type: Content of: <chapter><section><para>
1023 #. type: Content of: <chapter><section><para>
1024 #: best-pkging-practices.dbk:637
1025 msgid ""
1026 "Maintainer scripts must be idempotent.  That means that you need to make "
1027 "sure nothing bad will happen if the script is called twice where it would "
1028 "usually be called once."
1029 msgstr ""
1030
1031 # type: Content of: <chapter><section><para>
1032 #. type: Content of: <chapter><section><para>
1033 #: best-pkging-practices.dbk:642
1034 msgid ""
1035 "Standard input and output may be redirected (e.g.  into pipes) for logging "
1036 "purposes, so don't rely on them being a tty."
1037 msgstr ""
1038
1039 # type: Content of: <chapter><section><para>
1040 #. type: Content of: <chapter><section><para>
1041 #: best-pkging-practices.dbk:646
1042 msgid ""
1043 "All prompting or interactive configuration should be kept to a minimum.  "
1044 "When it is necessary, you should use the <systemitem role=\"package"
1045 "\">debconf</systemitem> package for the interface.  Remember that prompting "
1046 "in any case can only be in the <literal>configure</literal> stage of the "
1047 "<filename>postinst</filename> script."
1048 msgstr ""
1049
1050 # type: Content of: <chapter><section><para>
1051 #. type: Content of: <chapter><section><para>
1052 #: best-pkging-practices.dbk:653
1053 msgid ""
1054 "Keep the maintainer scripts as simple as possible.  We suggest you use pure "
1055 "POSIX shell scripts.  Remember, if you do need any bash features, the "
1056 "maintainer script must have a bash shebang line.  POSIX shell or Bash are "
1057 "preferred to Perl, since they enable <systemitem role=\"package\">debhelper</"
1058 "systemitem> to easily add bits to the scripts."
1059 msgstr ""
1060
1061 # type: Content of: <chapter><section><para>
1062 #. type: Content of: <chapter><section><para>
1063 #: best-pkging-practices.dbk:660
1064 msgid ""
1065 "If you change your maintainer scripts, be sure to test package removal, "
1066 "double installation, and purging.  Be sure that a purged package is "
1067 "completely gone, that is, it must remove any files created, directly or "
1068 "indirectly, in any maintainer script."
1069 msgstr ""
1070
1071 # type: Content of: <chapter><section><para>
1072 #. type: Content of: <chapter><section><para>
1073 #: best-pkging-practices.dbk:666
1074 msgid ""
1075 "If you need to check for the existence of a command, you should use "
1076 "something like"
1077 msgstr ""
1078
1079 # type: Content of: <chapter><section><programlisting>
1080 #. type: Content of: <chapter><section><programlisting>
1081 #: best-pkging-practices.dbk:669
1082 #, no-wrap
1083 msgid "if [ -x /usr/sbin/install-docs ]; then ..."
1084 msgstr "if [ -x /usr/sbin/install-docs ]; then ..."
1085
1086 # type: Content of: <chapter><section><para>
1087 #. type: Content of: <chapter><section><para>
1088 #: best-pkging-practices.dbk:671
1089 msgid ""
1090 "If you don't wish to hard-code the path of a command in your maintainer "
1091 "script, the following POSIX-compliant shell function may help:"
1092 msgstr ""
1093
1094 # type: Content of: <chapter><section><para>
1095 #. type: Content of: <chapter><section><para>
1096 #: best-pkging-practices.dbk:676
1097 msgid ""
1098 "You can use this function to search <literal>$PATH</literal> for a command "
1099 "name, passed as an argument.  It returns true (zero) if the command was "
1100 "found, and false if not.  This is really the most portable way, since "
1101 "<literal>command -v</literal>, <command>type</command>, and <command>which</"
1102 "command> are not POSIX."
1103 msgstr ""
1104
1105 # type: Content of: <chapter><section><para>
1106 #. type: Content of: <chapter><section><para>
1107 #: best-pkging-practices.dbk:683
1108 msgid ""
1109 "While <command>which</command> is an acceptable alternative, since it is "
1110 "from the required <systemitem role=\"package\">debianutils</systemitem> "
1111 "package, it's not on the root partition.  That is, it's in <filename>/usr/"
1112 "bin</filename> rather than <filename>/bin</filename>, so one can't use it in "
1113 "scripts which are run before the <filename>/usr</filename> partition is "
1114 "mounted.  Most scripts won't have this problem, though."
1115 msgstr ""
1116
1117 # type: Content of: <chapter><section><title>
1118 #. type: Content of: <chapter><section><title>
1119 #: best-pkging-practices.dbk:693
1120 msgid ""
1121 "Configuration management with <systemitem role=\"package\">debconf</"
1122 "systemitem>"
1123 msgstr ""
1124
1125 # type: Content of: <chapter><section><para>
1126 #. type: Content of: <chapter><section><para>
1127 #: best-pkging-practices.dbk:695
1128 msgid ""
1129 "<systemitem role=\"package\">Debconf</systemitem> is a configuration "
1130 "management system which can be used by all the various packaging scripts "
1131 "(<filename>postinst</filename> mainly) to request feedback from the user "
1132 "concerning how to configure the package.  Direct user interactions must now "
1133 "be avoided in favor of <systemitem role=\"package\">debconf</systemitem> "
1134 "interaction.  This will enable non-interactive installations in the future."
1135 msgstr ""
1136
1137 # type: Content of: <chapter><section><para>
1138 #. type: Content of: <chapter><section><para>
1139 #: best-pkging-practices.dbk:703
1140 msgid ""
1141 "Debconf is a great tool but it is often poorly used.  Many common mistakes "
1142 "are listed in the <citerefentry> <refentrytitle>debconf-devel</"
1143 "refentrytitle> <manvolnum>7</manvolnum> </citerefentry> man page.  It is "
1144 "something that you must read if you decide to use debconf.  Also, we "
1145 "document some best practices here."
1146 msgstr ""
1147
1148 # type: Content of: <chapter><section><para>
1149 #. type: Content of: <chapter><section><para>
1150 #: best-pkging-practices.dbk:710
1151 msgid ""
1152 "These guidelines include some writing style and typography recommendations, "
1153 "general considerations about debconf usage as well as more specific "
1154 "recommendations for some parts of the distribution (the installation system "
1155 "for instance)."
1156 msgstr ""
1157
1158 # type: Content of: <chapter><section><section><title>
1159 #. type: Content of: <chapter><section><section><title>
1160 #: best-pkging-practices.dbk:716
1161 msgid "Do not abuse debconf"
1162 msgstr ""
1163
1164 # type: Content of: <chapter><section><section><para>
1165 #. type: Content of: <chapter><section><section><para>
1166 #: best-pkging-practices.dbk:718
1167 msgid ""
1168 "Since debconf appeared in Debian, it has been widely abused and several "
1169 "criticisms received by the Debian distribution come from debconf abuse with "
1170 "the need of answering a wide bunch of questions before getting any little "
1171 "thing installed."
1172 msgstr ""
1173
1174 # type: Content of: <chapter><section><section><para>
1175 #. type: Content of: <chapter><section><section><para>
1176 #: best-pkging-practices.dbk:724
1177 msgid ""
1178 "Keep usage notes to what they belong: the NEWS.Debian, or README.Debian "
1179 "file.  Only use notes for important notes which may directly affect the "
1180 "package usability.  Remember that notes will always block the install until "
1181 "confirmed or bother the user by email."
1182 msgstr ""
1183
1184 # type: Content of: <chapter><section><section><para>
1185 #. type: Content of: <chapter><section><section><para>
1186 #: best-pkging-practices.dbk:730
1187 msgid ""
1188 "Carefully choose the questions priorities in maintainer scripts.  See "
1189 "<citerefentry> <refentrytitle>debconf-devel</refentrytitle> <manvolnum>7</"
1190 "manvolnum> </citerefentry> for details about priorities.  Most questions "
1191 "should use medium and low priorities."
1192 msgstr ""
1193
1194 # type: Content of: <chapter><section><section><title>
1195 #. type: Content of: <chapter><section><section><title>
1196 #: best-pkging-practices.dbk:738
1197 msgid "General recommendations for authors and translators"
1198 msgstr ""
1199
1200 # type: Content of: <chapter><section><section><section><title>
1201 #. type: Content of: <chapter><section><section><section><title>
1202 #: best-pkging-practices.dbk:740
1203 msgid "Write correct English"
1204 msgstr ""
1205
1206 # type: Content of: <chapter><section><section><section><para>
1207 #. type: Content of: <chapter><section><section><section><para>
1208 #: best-pkging-practices.dbk:742
1209 msgid ""
1210 "Most Debian package maintainers are not native English speakers.  So, "
1211 "writing properly phrased templates may not be easy for them."
1212 msgstr ""
1213
1214 # type: Content of: <chapter><section><section><section><para>
1215 #. type: Content of: <chapter><section><section><section><para>
1216 #: best-pkging-practices.dbk:746
1217 msgid ""
1218 "Please use (and abuse) &email-debian-l10n-english; mailing list.  Have your "
1219 "templates proofread."
1220 msgstr ""
1221
1222 # type: Content of: <chapter><section><section><section><para>
1223 #. type: Content of: <chapter><section><section><section><para>
1224 #: best-pkging-practices.dbk:750
1225 msgid ""
1226 "Badly written templates give a poor image of your package, of your work...or "
1227 "even of Debian itself."
1228 msgstr ""
1229
1230 # type: Content of: <chapter><section><section><section><para>
1231 #. type: Content of: <chapter><section><section><section><para>
1232 #: best-pkging-practices.dbk:754
1233 msgid ""
1234 "Avoid technical jargon as much as possible.  If some terms sound common to "
1235 "you, they may be impossible to understand for others.  If you cannot avoid "
1236 "them, try to explain them (use the extended description).  When doing so, "
1237 "try to balance between verbosity and simplicity."
1238 msgstr ""
1239
1240 # type: Content of: <chapter><section><section><section><title>
1241 #. type: Content of: <chapter><section><section><section><title>
1242 #: best-pkging-practices.dbk:762
1243 msgid "Be kind to translators"
1244 msgstr ""
1245
1246 # type: Content of: <chapter><section><section><section><para>
1247 #. type: Content of: <chapter><section><section><section><para>
1248 #: best-pkging-practices.dbk:764
1249 msgid ""
1250 "Debconf templates may be translated.  Debconf, along with its sister package "
1251 "<command>po-debconf</command> offers a simple framework for getting "
1252 "templates translated by translation teams or even individuals."
1253 msgstr ""
1254
1255 # type: Content of: <chapter><section><section><section><para>
1256 #. type: Content of: <chapter><section><section><section><para>
1257 #: best-pkging-practices.dbk:769
1258 msgid ""
1259 "Please use gettext-based templates.  Install <systemitem role=\"package\">po-"
1260 "debconf</systemitem> on your development system and read its documentation "
1261 "(<literal>man po-debconf</literal> is a good start)."
1262 msgstr ""
1263
1264 #. type: Content of: <chapter><section><section><section><para>
1265 #: best-pkging-practices.dbk:774
1266 msgid ""
1267 "Avoid changing templates too often.  Changing templates text induces more "
1268 "work to translators which will get their translation fuzzied.  A fuzzy "
1269 "translation is a string for which the original changed since it was "
1270 "translated, therefore requiring some update by a translator to be usable.  "
1271 "When changes are small enough, the original translation is kept in PO files "
1272 "but marked as <literal>fuzzy</literal>."
1273 msgstr ""
1274
1275 #. type: Content of: <chapter><section><section><section><para>
1276 #: best-pkging-practices.dbk:782
1277 msgid ""
1278 "If you plan to do changes to your original templates, please use the "
1279 "notification system provided with the <systemitem role=\"package\">po-"
1280 "debconf</systemitem> package, namely the <command> podebconf-report-po</"
1281 "command>, to contact translators.  Most active translators are very "
1282 "responsive and getting their work included along with your modified "
1283 "templates will save you additional uploads.  If you use gettext-based "
1284 "templates, the translator's name and e-mail addresses are mentioned in the "
1285 "PO files headers and will be used by <command> podebconf-report-po</command>."
1286 msgstr ""
1287
1288 #. type: Content of: <chapter><section><section><section><para>
1289 #: best-pkging-practices.dbk:794
1290 msgid "A recommended use of that utility is:"
1291 msgstr ""
1292
1293 #. type: Content of: <chapter><section><section><section><programlisting>
1294 #: best-pkging-practices.dbk:796
1295 #, no-wrap
1296 msgid "cd debian/po &amp;&amp; podebconf-report-po --languageteam --withtranslators --call --deadline=\"+10 days\""
1297 msgstr ""
1298
1299 #. type: Content of: <chapter><section><section><section><para>
1300 #: best-pkging-practices.dbk:798
1301 msgid ""
1302 "This command will first synchronize the PO and POT files in debian/po with "
1303 "the templates files listed in <filename>debian/po/POTFILES.in</filename>.  "
1304 "Then, it will send a call for translation updates to the language team "
1305 "(mentioned in the <literal>Language-Team</literal> field of each PO file)  "
1306 "as well as the last translator (mentioned in <literal>Last-translator</"
1307 "literal>). Finally, it will also send a call for new translations, in the "
1308 "&email-debian-i18n; mailing list."
1309 msgstr ""
1310
1311 #. type: Content of: <chapter><section><section><section><para>
1312 #: best-pkging-practices.dbk:807
1313 msgid ""
1314 "Giving a deadline to translators is always appreciated, so that they can "
1315 "organize their work. Please remember that some translation teams have a "
1316 "formalized translate/review process and a delay lower than 10 days is "
1317 "considered as unreasonable. A shorter delay puts too much pressure on "
1318 "translation teams and should be kept for very minor changes."
1319 msgstr ""
1320
1321 # type: Content of: <chapter><section><section><section><para>
1322 #. type: Content of: <chapter><section><section><section><para>
1323 #: best-pkging-practices.dbk:814
1324 msgid ""
1325 "If in doubt, you may also contact the translation team for a given language "
1326 "(debian-l10n-xxxxx@&lists-host;), or the &email-debian-i18n; mailing list."
1327 msgstr ""
1328
1329 # type: Content of: <chapter><section><section><section><title>
1330 #. type: Content of: <chapter><section><section><section><title>
1331 #: best-pkging-practices.dbk:821
1332 msgid "Unfuzzy complete translations when correcting typos and spelling"
1333 msgstr ""
1334
1335 #. type: Content of: <chapter><section><section><section><para>
1336 #: best-pkging-practices.dbk:823
1337 msgid ""
1338 "When the text of a debconf template is corrected and you are <emphasis role="
1339 "\"strong\">sure</emphasis> that the change does <emphasis role=\"strong"
1340 "\">not</emphasis> affect translations, please be kind to translators and "
1341 "<emphasis>unfuzzy</emphasis> their translations."
1342 msgstr ""
1343
1344 # type: Content of: <chapter><section><section><section><para>
1345 #. type: Content of: <chapter><section><section><section><para>
1346 #: best-pkging-practices.dbk:829
1347 msgid ""
1348 "If you don't do so, the whole template will not be translated as long as a "
1349 "translator will send you an update."
1350 msgstr ""
1351
1352 #. type: Content of: <chapter><section><section><section><para>
1353 #: best-pkging-practices.dbk:833
1354 msgid ""
1355 "To <emphasis>unfuzzy</emphasis> translations, you can use two methods. The "
1356 "first method does <emphasis>preventive</emphasis> search and replace actions "
1357 "in the PO files. The latter uses <command>gettext</command> utilities to "
1358 "<emphasis>unfuzzy</emphasis> strings."
1359 msgstr ""
1360
1361 #. type: Content of: <chapter><section><section><section><para>
1362 #: best-pkging-practices.dbk:839
1363 msgid "<emphasis>Preventive unfuzzy</emphasis> method:"
1364 msgstr ""
1365
1366 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1367 #: best-pkging-practices.dbk:844
1368 msgid ""
1369 "Try finding a complete translation file <emphasis role=\"strong\"> before</"
1370 "emphasis> the change:"
1371 msgstr ""
1372
1373 # type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1374 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1375 #: best-pkging-practices.dbk:847 best-pkging-practices.dbk:917
1376 #, no-wrap
1377 msgid ""
1378 "for i in debian/po/*po; do echo -n $i: ; msgfmt -o /dev/null\n"
1379 "--statistics $i; done"
1380 msgstr ""
1381
1382 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1383 #: best-pkging-practices.dbk:850
1384 msgid ""
1385 "The file only showing <emphasis>translated</emphasis> items will be used as "
1386 "the reference file. If there is none (which should not happen if you take "
1387 "care to properly interact with translators), you should use the file with "
1388 "the most translated strings."
1389 msgstr ""
1390
1391 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1392 #: best-pkging-practices.dbk:858
1393 msgid ""
1394 "Identify the needed change. In this example, let's assume the change is "
1395 "about fixing a typo in the word <literal>typo</literal> which was "
1396 "inadvertently written as <literal>tpyo</literal>. Therefore, the change is "
1397 "<command>s/tpyo/typo</command>."
1398 msgstr ""
1399
1400 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1401 #: best-pkging-practices.dbk:866
1402 msgid ""
1403 "Check that this change is only applied to the place where you really intend "
1404 "to make it and <emphasis role=\"strong\">not</emphasis> in any other place "
1405 "where the original string is appropriate. This specifically applies to "
1406 "change in punctuation, for instance."
1407 msgstr ""
1408
1409 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1410 #: best-pkging-practices.dbk:874
1411 msgid ""
1412 "Modify all PO files by using <command>sed</command>. The use of that command "
1413 "is recommended over any text editor to guarantee that the files encoding "
1414 "will not be broken by the edit action."
1415 msgstr ""
1416
1417 # type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1418 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1419 #: best-pkging-practices.dbk:879
1420 #, fuzzy, no-wrap
1421 msgid ""
1422 "cd debian/po\n"
1423 "for i in *.po; do sed -i 's/tpyo/typo/g' $i; done\n"
1424 msgstr ""
1425 "\n"
1426 "cd debian/po\n"
1427 "for i in *.po; do sed -i 's/tpyo/typo/g' $i; done\n"
1428
1429 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1430 #: best-pkging-practices.dbk:885
1431 msgid "Change the debconf template file to fix the typo."
1432 msgstr ""
1433
1434 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1435 #: best-pkging-practices.dbk:890
1436 msgid "Run <command>debconf-updatepo</command>"
1437 msgstr ""
1438
1439 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1440 #: best-pkging-practices.dbk:895
1441 msgid ""
1442 "Check the <filename>foo.po</filename> reference file. Its statistics should "
1443 "not be changed:"
1444 msgstr ""
1445
1446 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1447 #: best-pkging-practices.dbk:899
1448 #, no-wrap
1449 msgid "msgfmt -o /dev/null --statistics debian/po/foo.po\n"
1450 msgstr ""
1451
1452 #. type: Content of: <chapter><section><section><section><para>
1453 #: best-pkging-practices.dbk:908
1454 msgid "Gettext utilities method:"
1455 msgstr ""
1456
1457 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1458 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1459 #: best-pkging-practices.dbk:913
1460 msgid ""
1461 "Put all incomplete PO files out of the way.  You can check the completeness "
1462 "by using (needs the <systemitem role=\"package\">gettext</systemitem> "
1463 "package installed):"
1464 msgstr ""
1465
1466 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1467 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1468 #: best-pkging-practices.dbk:922
1469 msgid ""
1470 "move all files which report either fuzzy strings to a temporary place.  "
1471 "Files which report no fuzzy strings (only translated and untranslated) will "
1472 "be kept in place."
1473 msgstr ""
1474
1475 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1476 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1477 #: best-pkging-practices.dbk:929
1478 msgid ""
1479 "now <emphasis role=\"strong\">and now only</emphasis>, modify the template "
1480 "for the typos and check again that translation are not impacted (typos, "
1481 "spelling errors, sometimes typographical corrections are usually OK)"
1482 msgstr ""
1483
1484 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1485 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1486 #: best-pkging-practices.dbk:936
1487 msgid ""
1488 "run <command>debconf-updatepo</command>.  This will fuzzy all strings you "
1489 "modified in translations.  You can see this by running the above again"
1490 msgstr ""
1491
1492 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1493 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1494 #: best-pkging-practices.dbk:942
1495 msgid "use the following command:"
1496 msgstr ""
1497
1498 # type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1499 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><programlisting>
1500 #: best-pkging-practices.dbk:944
1501 #, no-wrap
1502 msgid "for i in debian/po/*po; do msgattrib --output-file=$i --clear-fuzzy $i; done"
1503 msgstr ""
1504
1505 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1506 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1507 #: best-pkging-practices.dbk:948
1508 msgid ""
1509 "move back to debian/po the files which showed fuzzy strings in the first step"
1510 msgstr ""
1511
1512 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1513 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
1514 #: best-pkging-practices.dbk:953
1515 msgid "run <command>debconf-updatepo</command> again"
1516 msgstr ""
1517
1518 # type: Content of: <chapter><section><section><section><title>
1519 #. type: Content of: <chapter><section><section><section><title>
1520 #: best-pkging-practices.dbk:960
1521 msgid "Do not make assumptions about interfaces"
1522 msgstr ""
1523
1524 #. type: Content of: <chapter><section><section><section><para>
1525 #: best-pkging-practices.dbk:962
1526 msgid ""
1527 "Templates text should not make reference to widgets belonging to some "
1528 "debconf interfaces.  Sentences like <emphasis>If you answer Yes...</"
1529 "emphasis> have no meaning for users of graphical interfaces which use "
1530 "checkboxes for boolean questions."
1531 msgstr ""
1532
1533 # type: Content of: <chapter><section><section><section><para>
1534 #. type: Content of: <chapter><section><section><section><para>
1535 #: best-pkging-practices.dbk:967
1536 msgid ""
1537 "String templates should also avoid mentioning the default values in their "
1538 "description.  First, because this is redundant with the values seen by the "
1539 "users.  Also, because these default values may be different from the "
1540 "maintainer choices (for instance, when the debconf database was preseeded)."
1541 msgstr ""
1542
1543 # type: Content of: <chapter><section><section><section><para>
1544 #. type: Content of: <chapter><section><section><section><para>
1545 #: best-pkging-practices.dbk:973
1546 msgid ""
1547 "More generally speaking, try to avoid referring to user actions.  Just give "
1548 "facts."
1549 msgstr ""
1550
1551 # type: Content of: <chapter><section><section><section><title>
1552 #. type: Content of: <chapter><section><section><section><title>
1553 #: best-pkging-practices.dbk:979
1554 msgid "Do not use first person"
1555 msgstr ""
1556
1557 #. type: Content of: <chapter><section><section><section><para>
1558 #: best-pkging-practices.dbk:981
1559 msgid ""
1560 "You should avoid the use of first person (<emphasis>I will do this...</"
1561 "emphasis> or <emphasis>We recommend...</emphasis>).  The computer is not a "
1562 "person and the Debconf templates do not speak for the Debian developers.  "
1563 "You should use neutral construction.  Those of you who already wrote "
1564 "scientific publications, just write your templates like you would write a "
1565 "scientific paper.  However, try using active voice if still possible, like "
1566 "<emphasis>Enable this if ...</emphasis> instead of <emphasis>This can be "
1567 "enabled if...</emphasis>."
1568 msgstr ""
1569
1570 # type: Content of: <chapter><section><section><section><title>
1571 #. type: Content of: <chapter><section><section><section><title>
1572 #: best-pkging-practices.dbk:991
1573 msgid "Be gender neutral"
1574 msgstr ""
1575
1576 # type: Content of: <chapter><section><section><section><para>
1577 #. type: Content of: <chapter><section><section><section><para>
1578 #: best-pkging-practices.dbk:993
1579 msgid ""
1580 "The world is made of men and women.  Please use gender-neutral constructions "
1581 "in your writing."
1582 msgstr ""
1583
1584 # type: Content of: <chapter><section><section><title>
1585 #. type: Content of: <chapter><section><section><title>
1586 #: best-pkging-practices.dbk:1001
1587 msgid "Templates fields definition"
1588 msgstr ""
1589
1590 # type: Content of: <chapter><section><section><para>
1591 #. type: Content of: <chapter><section><section><para>
1592 #: best-pkging-practices.dbk:1003
1593 msgid ""
1594 "This part gives some information which is mostly taken from the "
1595 "<citerefentry> <refentrytitle>debconf-devel</refentrytitle> <manvolnum>7</"
1596 "manvolnum> </citerefentry> manual page."
1597 msgstr ""
1598
1599 # type: Content of: <chapter><section><section><section><title>
1600 #. type: Content of: <chapter><section><section><section><title>
1601 #: best-pkging-practices.dbk:1008
1602 msgid "Type"
1603 msgstr ""
1604
1605 # type: Content of: <chapter><section><section><section><section><title>
1606 #. type: Content of: <chapter><section><section><section><section><title>
1607 #: best-pkging-practices.dbk:1010
1608 msgid "string:"
1609 msgstr ""
1610
1611 # type: Content of: <chapter><section><section><section><section><para>
1612 #. type: Content of: <chapter><section><section><section><section><para>
1613 #: best-pkging-practices.dbk:1012
1614 msgid ""
1615 "Results in a free-form input field that the user can type any string into."
1616 msgstr ""
1617
1618 # type: Content of: <chapter><section><section><section><section><title>
1619 #. type: Content of: <chapter><section><section><section><section><title>
1620 #: best-pkging-practices.dbk:1017
1621 msgid "password:"
1622 msgstr ""
1623
1624 # type: Content of: <chapter><section><section><section><section><para>
1625 #. type: Content of: <chapter><section><section><section><section><para>
1626 #: best-pkging-practices.dbk:1019
1627 msgid ""
1628 "Prompts the user for a password.  Use this with caution; be aware that the "
1629 "password the user enters will be written to debconf's database.  You should "
1630 "probably clean that value out of the database as soon as is possible."
1631 msgstr ""
1632
1633 # type: Content of: <chapter><section><section><section><section><title>
1634 #. type: Content of: <chapter><section><section><section><section><title>
1635 #: best-pkging-practices.dbk:1026
1636 msgid "boolean:"
1637 msgstr ""
1638
1639 # type: Content of: <chapter><section><section><section><section><para>
1640 #. type: Content of: <chapter><section><section><section><section><para>
1641 #: best-pkging-practices.dbk:1028
1642 msgid ""
1643 "A true/false choice.  Remember: true/false, <emphasis role=\"strong\">not "
1644 "yes/no</emphasis>..."
1645 msgstr ""
1646
1647 # type: Content of: <chapter><section><section><section><section><title>
1648 #. type: Content of: <chapter><section><section><section><section><title>
1649 #: best-pkging-practices.dbk:1034
1650 msgid "select:"
1651 msgstr ""
1652
1653 #. type: Content of: <chapter><section><section><section><section><para>
1654 #: best-pkging-practices.dbk:1036
1655 msgid ""
1656 "A choice between one of a number of values.  The choices must be specified "
1657 "in a field named 'Choices'.  Separate the possible values with commas and "
1658 "spaces, like this: <literal>Choices: yes, no, maybe</literal>."
1659 msgstr ""
1660
1661 #. type: Content of: <chapter><section><section><section><section><para>
1662 #: best-pkging-practices.dbk:1041
1663 msgid ""
1664 "If choices are translatable strings, the 'Choices' field may be marked as "
1665 "translatable by using <literal>__Choices</literal>. The double underscore "
1666 "will split out each choice in a separate string."
1667 msgstr ""
1668
1669 #. type: Content of: <chapter><section><section><section><section><para>
1670 #: best-pkging-practices.dbk:1046
1671 msgid ""
1672 "The <command>po-debconf</command> system also offers interesting "
1673 "possibilities to only mark <emphasis role=\"strong\">some</emphasis> choices "
1674 "as translatable.  Example:"
1675 msgstr ""
1676
1677 #. type: Content of: <chapter><section><section><section><section><programlisting>
1678 #: best-pkging-practices.dbk:1051
1679 #, no-wrap
1680 msgid ""
1681 "Template: foo/bar\n"
1682 "Type: Select\n"
1683 "#flag:translate:3\n"
1684 "__Choices: PAL, SECAM, Other\n"
1685 "_Description: TV standard:\n"
1686 " Please choose the TV standard used in your country.\n"
1687 msgstr ""
1688
1689 #. type: Content of: <chapter><section><section><section><section><para>
1690 #: best-pkging-practices.dbk:1059
1691 msgid ""
1692 "In that example, only the 'Other' string is translatable while others are "
1693 "acronyms that should not be translated. The above allows only 'Other' to be "
1694 "included in PO and POT files."
1695 msgstr ""
1696
1697 #. type: Content of: <chapter><section><section><section><section><para>
1698 #: best-pkging-practices.dbk:1064
1699 msgid ""
1700 "The debconf templates flag system offers many such possibilities. The "
1701 "<citerefentry> <refentrytitle>po-debconf</refentrytitle> <manvolnum>7</"
1702 "manvolnum> </citerefentry> manual page lists all these possibilities."
1703 msgstr ""
1704
1705 # type: Content of: <chapter><section><section><section><section><title>
1706 #. type: Content of: <chapter><section><section><section><section><title>
1707 #: best-pkging-practices.dbk:1072
1708 msgid "multiselect:"
1709 msgstr ""
1710
1711 # type: Content of: <chapter><section><section><section><section><para>
1712 #. type: Content of: <chapter><section><section><section><section><para>
1713 #: best-pkging-practices.dbk:1074
1714 msgid ""
1715 "Like the select data type, except the user can choose any number of items "
1716 "from the choices list (or chose none of them)."
1717 msgstr ""
1718
1719 # type: Content of: <chapter><section><section><section><section><title>
1720 #. type: Content of: <chapter><section><section><section><section><title>
1721 #: best-pkging-practices.dbk:1080
1722 msgid "note:"
1723 msgstr ""
1724
1725 # type: Content of: <chapter><section><section><section><section><para>
1726 #. type: Content of: <chapter><section><section><section><section><para>
1727 #: best-pkging-practices.dbk:1082
1728 msgid ""
1729 "Rather than being a question per se, this datatype indicates a note that can "
1730 "be displayed to the user.  It should be used only for important notes that "
1731 "the user really should see, since debconf will go to great pains to make "
1732 "sure the user sees it; halting the install for them to press a key, and even "
1733 "mailing the note to them in some cases."
1734 msgstr ""
1735
1736 # type: Content of: <chapter><section><section><section><section><title>
1737 #. type: Content of: <chapter><section><section><section><section><title>
1738 #: best-pkging-practices.dbk:1091
1739 msgid "text:"
1740 msgstr ""
1741
1742 # type: Content of: <chapter><section><section><section><section><para>
1743 #. type: Content of: <chapter><section><section><section><section><para>
1744 #: best-pkging-practices.dbk:1093
1745 msgid "This type is now considered obsolete: don't use it."
1746 msgstr ""
1747
1748 # type: Content of: <chapter><section><section><section><section><title>
1749 #. type: Content of: <chapter><section><section><section><section><title>
1750 #: best-pkging-practices.dbk:1098
1751 msgid "error:"
1752 msgstr ""
1753
1754 # type: Content of: <chapter><section><section><section><section><para>
1755 #. type: Content of: <chapter><section><section><section><section><para>
1756 #: best-pkging-practices.dbk:1100
1757 msgid ""
1758 "This type is designed to handle error messages.  It is mostly similar to the "
1759 "note type.  Frontends may present it differently (for instance, the dialog "
1760 "frontend of cdebconf draws a red screen instead of the usual blue one)."
1761 msgstr ""
1762
1763 # type: Content of: <chapter><section><section><section><section><para>
1764 #. type: Content of: <chapter><section><section><section><section><para>
1765 #: best-pkging-practices.dbk:1105
1766 msgid ""
1767 "It is recommended to use this type for any message that needs user attention "
1768 "for a correction of any kind."
1769 msgstr ""
1770
1771 # type: Content of: <chapter><section><section><section><title>
1772 #. type: Content of: <chapter><section><section><section><title>
1773 #: best-pkging-practices.dbk:1113
1774 msgid "Description: short and extended description"
1775 msgstr ""
1776
1777 # type: Content of: <chapter><section><section><section><para>
1778 #. type: Content of: <chapter><section><section><section><para>
1779 #: best-pkging-practices.dbk:1115
1780 msgid ""
1781 "Template descriptions have two parts: short and extended.  The short "
1782 "description is in the Description: line of the template."
1783 msgstr ""
1784
1785 # type: Content of: <chapter><section><section><section><para>
1786 #. type: Content of: <chapter><section><section><section><para>
1787 #: best-pkging-practices.dbk:1119
1788 msgid ""
1789 "The short description should be kept short (50 characters or so) so that it "
1790 "may be accomodated by most debconf interfaces.  Keeping it short also helps "
1791 "translators, as usually translations tend to end up being longer than the "
1792 "original."
1793 msgstr ""
1794
1795 # type: Content of: <chapter><section><section><section><para>
1796 #. type: Content of: <chapter><section><section><section><para>
1797 #: best-pkging-practices.dbk:1125
1798 msgid ""
1799 "The short description should be able to stand on its own.  Some interfaces "
1800 "do not show the long description by default, or only if the user explicitely "
1801 "asks for it or even do not show it at all.  Avoid things like What do you "
1802 "want to do?"
1803 msgstr ""
1804
1805 # type: Content of: <chapter><section><section><section><para>
1806 #. type: Content of: <chapter><section><section><section><para>
1807 #: best-pkging-practices.dbk:1131
1808 msgid ""
1809 "The short description does not necessarily have to be a full sentence.  This "
1810 "is part of the keep it short and efficient recommendation."
1811 msgstr ""
1812
1813 # type: Content of: <chapter><section><section><section><para>
1814 #. type: Content of: <chapter><section><section><section><para>
1815 #: best-pkging-practices.dbk:1135
1816 msgid ""
1817 "The extended description should not repeat the short description word for "
1818 "word.  If you can't think up a long description, then first, think some "
1819 "more.  Post to debian-devel.  Ask for help.  Take a writing class! That "
1820 "extended description is important.  If after all that you still can't come "
1821 "up with anything, leave it blank."
1822 msgstr ""
1823
1824 # type: Content of: <chapter><section><section><section><para>
1825 #. type: Content of: <chapter><section><section><section><para>
1826 #: best-pkging-practices.dbk:1142
1827 msgid ""
1828 "The extended description should use complete sentences.  Paragraphs should "
1829 "be kept short for improved readability.  Do not mix two ideas in the same "
1830 "paragraph but rather use another paragraph."
1831 msgstr ""
1832
1833 # type: Content of: <chapter><section><section><section><para>
1834 #. type: Content of: <chapter><section><section><section><para>
1835 #: best-pkging-practices.dbk:1147
1836 msgid ""
1837 "Don't be too verbose.  User tend to ignore too long screens.  20 lines are "
1838 "by experience a border you shouldn't cross, because that means that in the "
1839 "classical dialog interface, people will need to scroll, and lot of people "
1840 "just don't do that."
1841 msgstr ""
1842
1843 # type: Content of: <chapter><section><section><section><para>
1844 #. type: Content of: <chapter><section><section><section><para>
1845 #: best-pkging-practices.dbk:1153
1846 msgid ""
1847 "The extended description should <emphasis role=\"strong\">never</emphasis> "
1848 "include a question."
1849 msgstr ""
1850
1851 # type: Content of: <chapter><section><section><section><para>
1852 #. type: Content of: <chapter><section><section><section><para>
1853 #: best-pkging-practices.dbk:1157
1854 msgid ""
1855 "For specific rules depending on templates type (string, boolean, etc.), "
1856 "please read below."
1857 msgstr ""
1858
1859 # type: Content of: <chapter><section><section><section><title>
1860 #. type: Content of: <chapter><section><section><section><title>
1861 #: best-pkging-practices.dbk:1163
1862 msgid "Choices"
1863 msgstr ""
1864
1865 # type: Content of: <chapter><section><section><section><para>
1866 #. type: Content of: <chapter><section><section><section><para>
1867 #: best-pkging-practices.dbk:1165
1868 msgid ""
1869 "This field should be used for Select and Multiselect types.  It contains the "
1870 "possible choices which will be presented to users.  These choices should be "
1871 "separated by commas."
1872 msgstr ""
1873
1874 # type: Content of: <chapter><section><section><section><title>
1875 #. type: Content of: <chapter><section><section><section><title>
1876 #: best-pkging-practices.dbk:1172
1877 msgid "Default"
1878 msgstr ""
1879
1880 # type: Content of: <chapter><section><section><section><para>
1881 #. type: Content of: <chapter><section><section><section><para>
1882 #: best-pkging-practices.dbk:1174
1883 msgid ""
1884 "This field is optional.  It contains the default answer for string, select "
1885 "and multiselect templates.  For multiselect templates, it may contain a "
1886 "comma-separated list of choices."
1887 msgstr ""
1888
1889 # type: Content of: <chapter><section><section><title>
1890 #. type: Content of: <chapter><section><section><title>
1891 #: best-pkging-practices.dbk:1183
1892 msgid "Templates fields specific style guide"
1893 msgstr ""
1894
1895 # type: Content of: <chapter><section><section><section><title>
1896 #. type: Content of: <chapter><section><section><section><title>
1897 #: best-pkging-practices.dbk:1185
1898 msgid "Type field"
1899 msgstr ""
1900
1901 # type: Content of: <chapter><section><section><section><para>
1902 #. type: Content of: <chapter><section><section><section><para>
1903 #: best-pkging-practices.dbk:1187
1904 msgid ""
1905 "No specific indication except: use the appropriate type by referring to the "
1906 "previous section."
1907 msgstr ""
1908
1909 # type: Content of: <chapter><section><section><section><title>
1910 #. type: Content of: <chapter><section><section><section><title>
1911 #: best-pkging-practices.dbk:1193
1912 msgid "Description field"
1913 msgstr ""
1914
1915 # type: Content of: <chapter><section><section><section><para>
1916 #. type: Content of: <chapter><section><section><section><para>
1917 #: best-pkging-practices.dbk:1195
1918 msgid ""
1919 "Below are specific instructions for properly writing the Description (short "
1920 "and extended) depending on the template type."
1921 msgstr ""
1922
1923 # type: Content of: <chapter><section><section><section><section><title>
1924 #. type: Content of: <chapter><section><section><section><section><title>
1925 #: best-pkging-practices.dbk:1199
1926 msgid "String/password templates"
1927 msgstr ""
1928
1929 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1930 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1931 #: best-pkging-practices.dbk:1203
1932 msgid ""
1933 "The short description is a prompt and <emphasis role=\"strong\">not</"
1934 "emphasis> a title.  Avoid question style prompts (IP Address?) in favour of "
1935 "opened prompts (IP address:).  The use of colons is recommended."
1936 msgstr ""
1937
1938 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1939 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1940 #: best-pkging-practices.dbk:1210
1941 msgid ""
1942 "The extended description is a complement to the short description.  In the "
1943 "extended part, explain what is being asked, rather than ask the same "
1944 "question again using longer words.  Use complete sentences.  Terse writing "
1945 "style is strongly discouraged."
1946 msgstr ""
1947
1948 # type: Content of: <chapter><section><section><section><section><title>
1949 #. type: Content of: <chapter><section><section><section><section><title>
1950 #: best-pkging-practices.dbk:1220
1951 msgid "Boolean templates"
1952 msgstr ""
1953
1954 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1955 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1956 #: best-pkging-practices.dbk:1224
1957 msgid ""
1958 "The short description should be phrased in the form of a question which "
1959 "should be kept short and should generally end with a question mark.  Terse "
1960 "writing style is permitted and even encouraged if the question is rather "
1961 "long (remember that translations are often longer than original versions)"
1962 msgstr ""
1963
1964 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1965 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1966 #: best-pkging-practices.dbk:1232
1967 msgid ""
1968 "Again, please avoid referring to specific interface widgets.  A common "
1969 "mistake for such templates is if you answer Yes-type constructions."
1970 msgstr ""
1971
1972 # type: Content of: <chapter><section><section><section><section><title>
1973 #. type: Content of: <chapter><section><section><section><section><title>
1974 #: best-pkging-practices.dbk:1240
1975 msgid "Select/Multiselect"
1976 msgstr ""
1977
1978 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1979 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1980 #: best-pkging-practices.dbk:1244
1981 msgid ""
1982 "The short description is a prompt and <emphasis role=\"strong\">not</"
1983 "emphasis> a title.  Do <emphasis role=\"strong\">not</emphasis> use useless "
1984 "Please choose...  constructions.  Users are clever enough to figure out they "
1985 "have to choose something...:)"
1986 msgstr ""
1987
1988 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1989 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
1990 #: best-pkging-practices.dbk:1252
1991 msgid ""
1992 "The extended description will complete the short description.  It may refer "
1993 "to the available choices.  It may also mention that the user may choose more "
1994 "than one of the available choices, if the template is a multiselect one "
1995 "(although the interface often makes this clear)."
1996 msgstr ""
1997
1998 # type: Content of: <chapter><section><section><section><section><title>
1999 #. type: Content of: <chapter><section><section><section><section><title>
2000 #: best-pkging-practices.dbk:1262
2001 msgid "Notes"
2002 msgstr ""
2003
2004 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
2005 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
2006 #: best-pkging-practices.dbk:1266
2007 msgid "The short description should be considered to be a *title*."
2008 msgstr ""
2009
2010 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
2011 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
2012 #: best-pkging-practices.dbk:1271
2013 msgid ""
2014 "The extended description is what will be displayed as a more detailed "
2015 "explanation of the note.  Phrases, no terse writing style."
2016 msgstr ""
2017
2018 # type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
2019 #. type: Content of: <chapter><section><section><section><section><itemizedlist><listitem><para>
2020 #: best-pkging-practices.dbk:1277
2021 msgid ""
2022 "<emphasis role=\"strong\">Do not abuse debconf.</emphasis> Notes are the "
2023 "most common way to abuse debconf.  As written in debconf-devel manual page: "
2024 "it's best to use them only for warning about very serious problems.  The "
2025 "NEWS.Debian or README.Debian files are the appropriate location for a lot of "
2026 "notes.  If, by reading this, you consider converting your Note type "
2027 "templates to entries in NEWS/Debian or README.Debian, plus consider keeping "
2028 "existing translations for the future."
2029 msgstr ""
2030
2031 # type: Content of: <chapter><section><section><section><title>
2032 #. type: Content of: <chapter><section><section><section><title>
2033 #: best-pkging-practices.dbk:1292
2034 msgid "Choices field"
2035 msgstr ""
2036
2037 # type: Content of: <chapter><section><section><section><para>
2038 #. type: Content of: <chapter><section><section><section><para>
2039 #: best-pkging-practices.dbk:1294
2040 msgid ""
2041 "If the Choices are likely to change often, please consider using the "
2042 "__Choices trick.  This will split each individual choice into a single "
2043 "string, which will considerably help translators for doing their work."
2044 msgstr ""
2045
2046 # type: Content of: <chapter><section><section><section><title>
2047 #. type: Content of: <chapter><section><section><section><title>
2048 #: best-pkging-practices.dbk:1301 best-pkging-practices.dbk:1339
2049 msgid "Default field"
2050 msgstr ""
2051
2052 # type: Content of: <chapter><section><section><section><para>
2053 #. type: Content of: <chapter><section><section><section><para>
2054 #: best-pkging-practices.dbk:1303
2055 msgid ""
2056 "If the default value, for a select template, is likely to vary depending on "
2057 "the user language (for instance, if the choice is a language choice), please "
2058 "use the _DefaultChoice trick."
2059 msgstr ""
2060
2061 #. type: Content of: <chapter><section><section><section><para>
2062 #: best-pkging-practices.dbk:1308
2063 msgid ""
2064 "This special field allow translators to put the most appropriate choice "
2065 "according to their own language.  It will become the default choice when "
2066 "their language is used while your own mentioned Default Choice will be used "
2067 "when using English."
2068 msgstr ""
2069
2070 # type: Content of: <chapter><section><section><section><para>
2071 #. type: Content of: <chapter><section><section><section><para>
2072 #: best-pkging-practices.dbk:1314
2073 msgid "Example, taken from the geneweb package templates:"
2074 msgstr ""
2075
2076 #. type: Content of: <chapter><section><section><section><screen>
2077 #: best-pkging-practices.dbk:1317
2078 #, no-wrap
2079 msgid ""
2080 "Template: geneweb/lang\n"
2081 "Type: select\n"
2082 "__Choices: Afrikaans (af), Bulgarian (bg), Catalan (ca), Chinese (zh), Czech (cs), Danish (da), Dutch (nl), English (en), Esperanto (eo), Estonian (et), Finnish (fi), French (fr), German (de), Hebrew (he), Icelandic (is), Italian (it), Latvian (lv), Norwegian (no), Polish (pl), Portuguese (pt), Romanian (ro), Russian (ru), Spanish (es), Swedish (sv)\n"
2083 "# This is the default choice. Translators may put their own language here\n"
2084 "# instead of the default.\n"
2085 "# WARNING : you MUST use the ENGLISH FORM of your language\n"
2086 "# For instance, the french translator will need to put French (fr) here.\n"
2087 "_DefaultChoice: English (en)[ translators, please see comment in PO files]\n"
2088 "_Description: Geneweb default language:\n"
2089 msgstr ""
2090
2091 # type: Content of: <chapter><section><section><section><para>
2092 #. type: Content of: <chapter><section><section><section><para>
2093 #: best-pkging-practices.dbk:1328
2094 msgid ""
2095 "Note the use of brackets which allow internal comments in debconf fields.  "
2096 "Also note the use of comments which will show up in files the translators "
2097 "will work with."
2098 msgstr ""
2099
2100 # type: Content of: <chapter><section><section><section><para>
2101 #. type: Content of: <chapter><section><section><section><para>
2102 #: best-pkging-practices.dbk:1333
2103 msgid ""
2104 "The comments are needed as the DefaultChoice trick is a bit confusing: the "
2105 "translators may put their own choice"
2106 msgstr ""
2107
2108 # type: Content of: <chapter><section><section><section><para>
2109 #. type: Content of: <chapter><section><section><section><para>
2110 #: best-pkging-practices.dbk:1341
2111 msgid ""
2112 "Do NOT use empty default field.  If you don't want to use default values, do "
2113 "not use Default at all."
2114 msgstr ""
2115
2116 # type: Content of: <chapter><section><section><section><para>
2117 #. type: Content of: <chapter><section><section><section><para>
2118 #: best-pkging-practices.dbk:1345
2119 msgid ""
2120 "If you use po-debconf (and you <emphasis role=\"strong\">should</emphasis>, "
2121 "see 2.2), consider making this field translatable, if you think it may be "
2122 "translated."
2123 msgstr ""
2124
2125 # type: Content of: <chapter><section><section><section><para>
2126 #. type: Content of: <chapter><section><section><section><para>
2127 #: best-pkging-practices.dbk:1350
2128 msgid ""
2129 "If the default value may vary depending on language/country (for instance "
2130 "the default value for a language choice), consider using the special "
2131 "_DefaultChoice type documented in <citerefentry> <refentrytitle>po-debconf</"
2132 "refentrytitle> <manvolnum>7</manvolnum> </citerefentry>)."
2133 msgstr ""
2134
2135 # type: Content of: <chapter><section><title>
2136 #. type: Content of: <chapter><section><title>
2137 #: best-pkging-practices.dbk:1362
2138 msgid "Internationalization"
2139 msgstr ""
2140
2141 # type: Content of: <chapter><section><section><title>
2142 #. type: Content of: <chapter><section><section><title>
2143 #: best-pkging-practices.dbk:1364
2144 msgid "Handling debconf translations"
2145 msgstr ""
2146
2147 # type: Content of: <chapter><section><section><para>
2148 #. type: Content of: <chapter><section><section><para>
2149 #: best-pkging-practices.dbk:1366
2150 msgid ""
2151 "Like porters, translators have a difficult task.  They work on many packages "
2152 "and must collaborate with many different maintainers.  Moreover, most of the "
2153 "time, they are not native English speakers, so you may need to be "
2154 "particularly patient with them."
2155 msgstr ""
2156
2157 # type: Content of: <chapter><section><section><para>
2158 #. type: Content of: <chapter><section><section><para>
2159 #: best-pkging-practices.dbk:1372
2160 msgid ""
2161 "The goal of <systemitem role=\"package\">debconf</systemitem> was to make "
2162 "packages configuration easier for maintainers and for users.  Originally, "
2163 "translation of debconf templates was handled with <command>debconf-"
2164 "mergetemplate</command>.  However, that technique is now deprecated; the "
2165 "best way to accomplish <systemitem role=\"package\">debconf</systemitem> "
2166 "internationalization is by using the <systemitem role=\"package\">po-"
2167 "debconf</systemitem> package.  This method is easier both for maintainer and "
2168 "translators; transition scripts are provided."
2169 msgstr ""
2170
2171 # type: Content of: <chapter><section><section><para>
2172 #. type: Content of: <chapter><section><section><para>
2173 #: best-pkging-practices.dbk:1382
2174 msgid ""
2175 "Using <systemitem role=\"package\">po-debconf</systemitem>, the translation "
2176 "is stored in <filename>po</filename> files (drawing from <command>gettext</"
2177 "command> translation techniques).  Special template files contain the "
2178 "original messages and mark which fields are translatable.  When you change "
2179 "the value of a translatable field, by calling <command>debconf-updatepo</"
2180 "command>, the translation is marked as needing attention from the "
2181 "translators.  Then, at build time, the <command>dh_installdebconf</command> "
2182 "program takes care of all the needed magic to add the template along with "
2183 "the up-to-date translations into the binary packages.  Refer to the "
2184 "<citerefentry> <refentrytitle>po-debconf</refentrytitle> <manvolnum>7</"
2185 "manvolnum> </citerefentry> manual page for details."
2186 msgstr ""
2187
2188 # type: Content of: <chapter><section><section><title>
2189 #. type: Content of: <chapter><section><section><title>
2190 #: best-pkging-practices.dbk:1398
2191 msgid "Internationalized documentation"
2192 msgstr ""
2193
2194 # type: Content of: <chapter><section><section><para>
2195 #. type: Content of: <chapter><section><section><para>
2196 #: best-pkging-practices.dbk:1400
2197 msgid ""
2198 "Internationalizing documentation is crucial for users, but a lot of labor.  "
2199 "There's no way to eliminate all that work, but you can make things easier "
2200 "for translators."
2201 msgstr ""
2202
2203 # type: Content of: <chapter><section><section><para>
2204 #. type: Content of: <chapter><section><section><para>
2205 #: best-pkging-practices.dbk:1405
2206 msgid ""
2207 "If you maintain documentation of any size, its easier for translators if "
2208 "they have access to a source control system.  That lets translators see the "
2209 "differences between two versions of the documentation, so, for instance, "
2210 "they can see what needs to be retranslated.  It is recommended that the "
2211 "translated documentation maintain a note about what source control revision "
2212 "the translation is based on.  An interesting system is provided by <ulink "
2213 "url=\"&url-i18n-doc-check;\">doc-check</ulink> in the <systemitem role="
2214 "\"package\">boot-floppies</systemitem> package, which shows an overview of "
2215 "the translation status for any given language, using structured comments for "
2216 "the current revision of the file to be translated and, for a translated "
2217 "file, the revision of the original file the translation is based on.  You "
2218 "might wish to adapt and provide that in your CVS area."
2219 msgstr ""
2220
2221 # type: Content of: <chapter><section><section><para>
2222 #. type: Content of: <chapter><section><section><para>
2223 #: best-pkging-practices.dbk:1419
2224 msgid ""
2225 "If you maintain XML or SGML documentation, we suggest that you isolate any "
2226 "language-independent information and define those as entities in a separate "
2227 "file which is included by all the different translations.  This makes it "
2228 "much easier, for instance, to keep URLs up to date across multiple files."
2229 msgstr ""
2230
2231 # type: Content of: <chapter><section><title>
2232 #. type: Content of: <chapter><section><title>
2233 #: best-pkging-practices.dbk:1429
2234 msgid "Common packaging situations"
2235 msgstr ""
2236
2237 # type: Content of: <chapter><section><section><title>
2238 #. type: Content of: <chapter><section><section><title>
2239 #: best-pkging-practices.dbk:1440
2240 msgid "Packages using <command>autoconf</command>/<command>automake</command>"
2241 msgstr ""
2242
2243 # type: Content of: <chapter><section><section><para>
2244 #. type: Content of: <chapter><section><section><para>
2245 #: best-pkging-practices.dbk:1442
2246 msgid ""
2247 "Keeping <command>autoconf</command>'s <filename>config.sub</filename> and "
2248 "<filename>config.guess</filename> files up to date is critical for porters, "
2249 "especially on more volatile architectures.  Some very good packaging "
2250 "practices for any package using <command>autoconf</command> and/or "
2251 "<command>automake</command> have been synthesized in &file-bpp-autotools; "
2252 "from the <systemitem role=\"package\">autotools-dev</systemitem> package.  "
2253 "You're strongly encouraged to read this file and to follow the given "
2254 "recommendations."
2255 msgstr ""
2256
2257 # type: Content of: <chapter><section><section><title>
2258 #. type: Content of: <chapter><section><section><title>
2259 #: best-pkging-practices.dbk:1454
2260 msgid "Libraries"
2261 msgstr ""
2262
2263 # type: Content of: <chapter><section><section><para>
2264 #. type: Content of: <chapter><section><section><para>
2265 #: best-pkging-practices.dbk:1456
2266 msgid ""
2267 "Libraries are always difficult to package for various reasons.  The policy "
2268 "imposes many constraints to ease their maintenance and to make sure upgrades "
2269 "are as simple as possible when a new upstream version comes out.  Breakage "
2270 "in a library can result in dozens of dependent packages breaking."
2271 msgstr ""
2272
2273 # type: Content of: <chapter><section><section><para>
2274 #. type: Content of: <chapter><section><section><para>
2275 #: best-pkging-practices.dbk:1462
2276 msgid ""
2277 "Good practices for library packaging have been grouped in <ulink url=\"&url-"
2278 "libpkg-guide;\">the library packaging guide</ulink>."
2279 msgstr ""
2280
2281 # type: Content of: <chapter><section><section><title>
2282 #. type: Content of: <chapter><section><section><title>
2283 #: best-pkging-practices.dbk:1469
2284 msgid "Documentation"
2285 msgstr ""
2286
2287 # type: Content of: <chapter><section><section><para>
2288 #. type: Content of: <chapter><section><section><para>
2289 #: best-pkging-practices.dbk:1471
2290 msgid ""
2291 "Be sure to follow the <ulink url=\"&url-debian-policy;ch-docs.html\">Policy "
2292 "on documentation</ulink>."
2293 msgstr ""
2294
2295 # type: Content of: <chapter><section><section><para>
2296 #. type: Content of: <chapter><section><section><para>
2297 #: best-pkging-practices.dbk:1476
2298 msgid ""
2299 "If your package contains documentation built from XML or SGML, we recommend "
2300 "you not ship the XML or SGML source in the binary package(s).  If users want "
2301 "the source of the documentation, they should retrieve the source package."
2302 msgstr ""
2303
2304 # type: Content of: <chapter><section><section><para>
2305 #. type: Content of: <chapter><section><section><para>
2306 #: best-pkging-practices.dbk:1481
2307 msgid ""
2308 "Policy specifies that documentation should be shipped in HTML format.  We "
2309 "also recommend shipping documentation in PDF and plain text format if "
2310 "convenient and if output of reasonable quality is possible.  However, it is "
2311 "generally not appropriate to ship plain text versions of documentation whose "
2312 "source format is HTML."
2313 msgstr ""
2314
2315 # type: Content of: <chapter><section><section><para>
2316 #. type: Content of: <chapter><section><section><para>
2317 #: best-pkging-practices.dbk:1488
2318 msgid ""
2319 "Major shipped manuals should register themselves with <systemitem role="
2320 "\"package\">doc-base</systemitem> on installation.  See the <systemitem role="
2321 "\"package\">doc-base</systemitem> package documentation for more information."
2322 msgstr ""
2323
2324 #. type: Content of: <chapter><section><section><para>
2325 #: best-pkging-practices.dbk:1494
2326 msgid ""
2327 "Debian policy (section 12.1) directs that manual pages should accompany "
2328 "every program, utility, and function, and suggests them for other objects "
2329 "like configuration files. If the work you are packaging does not have such "
2330 "manual pages, consider writing them for inclusion in your package, and "
2331 "submitting them upstream."
2332 msgstr ""
2333
2334 #. type: Content of: <chapter><section><section><para>
2335 #: best-pkging-practices.dbk:1501
2336 msgid ""
2337 "The manpages do not need to be written directly in the troff format.  "
2338 "Popular source formats are Docbook, POD and reST, which can be converted "
2339 "using <command>xsltproc</command>, <command>pod2man</command> and "
2340 "<command>rst2man</command> respectively. To a lesser extent, the <command> "
2341 "help2man</command>program can also be used to write a stub."
2342 msgstr ""
2343
2344 # type: Content of: <chapter><section><section><title>
2345 #. type: Content of: <chapter><section><section><title>
2346 #: best-pkging-practices.dbk:1510
2347 msgid "Specific types of packages"
2348 msgstr ""
2349
2350 # type: Content of: <chapter><section><section><para>
2351 #. type: Content of: <chapter><section><section><para>
2352 #: best-pkging-practices.dbk:1512
2353 msgid ""
2354 "Several specific types of packages have special sub-policies and "
2355 "corresponding packaging rules and practices:"
2356 msgstr ""
2357
2358 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2359 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2360 #: best-pkging-practices.dbk:1518
2361 msgid ""
2362 "Perl related packages have a <ulink url=\"&url-perl-policy;\">Perl policy</"
2363 "ulink>, some examples of packages following that policy are <systemitem role="
2364 "\"package\">libdbd-pg-perl</systemitem> (binary perl module) or <systemitem "
2365 "role=\"package\">libmldbm-perl</systemitem> (arch independent perl module)."
2366 msgstr ""
2367
2368 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2369 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2370 #: best-pkging-practices.dbk:1527
2371 msgid ""
2372 "Python related packages have their python policy; see &file-python-policy; "
2373 "in the <systemitem role=\"package\">python</systemitem> package."
2374 msgstr ""
2375
2376 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2377 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2378 #: best-pkging-practices.dbk:1534
2379 msgid ""
2380 "Emacs related packages have the <ulink url=\"&url-emacs-policy;\">emacs "
2381 "policy</ulink>."
2382 msgstr ""
2383
2384 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2385 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2386 #: best-pkging-practices.dbk:1541
2387 msgid ""
2388 "Java related packages have their <ulink url=\"&url-java-policy;\">java "
2389 "policy</ulink>."
2390 msgstr ""
2391
2392 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2393 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2394 #: best-pkging-practices.dbk:1548
2395 msgid ""
2396 "Ocaml related packages have their own policy, found in &file-ocaml-policy; "
2397 "from the <systemitem role=\"package\">ocaml</systemitem> package.  A good "
2398 "example is the <systemitem role=\"package\">camlzip</systemitem> source "
2399 "package."
2400 msgstr ""
2401
2402 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2403 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2404 #: best-pkging-practices.dbk:1556
2405 msgid ""
2406 "Packages providing XML or SGML DTDs should conform to the recommendations "
2407 "found in the <systemitem role=\"package\">sgml-base-doc</systemitem> package."
2408 msgstr ""
2409
2410 # type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2411 #. type: Content of: <chapter><section><section><itemizedlist><listitem><para>
2412 #: best-pkging-practices.dbk:1562
2413 msgid ""
2414 "Lisp packages should register themselves with <systemitem role=\"package"
2415 "\">common-lisp-controller</systemitem>, about which see &file-lisp-"
2416 "controller;."
2417 msgstr ""
2418
2419 # type: Content of: <chapter><section><section><title>
2420 #. type: Content of: <chapter><section><section><title>
2421 #: best-pkging-practices.dbk:1592
2422 msgid "Architecture-independent data"
2423 msgstr "アーキテクチャ非依存のデータ"
2424
2425 # type: Content of: <chapter><section><section><para>
2426 #. type: Content of: <chapter><section><section><para>
2427 #: best-pkging-practices.dbk:1594
2428 msgid ""
2429 "It is not uncommon to have a large amount of architecture-independent data "
2430 "packaged with a program.  For example, audio files, a collection of icons, "
2431 "wallpaper patterns, or other graphic files.  If the size of this data is "
2432 "negligible compared to the size of the rest of the package, it's probably "
2433 "best to keep it all in a single package."
2434 msgstr ""
2435
2436 # type: Content of: <chapter><section><section><para>
2437 #. type: Content of: <chapter><section><section><para>
2438 #: best-pkging-practices.dbk:1601
2439 msgid ""
2440 "However, if the size of the data is considerable, consider splitting it out "
2441 "into a separate, architecture-independent package (_all.deb).  By doing "
2442 "this, you avoid needless duplication of the same data into eleven or more ."
2443 "debs, one per each architecture.  While this adds some extra overhead into "
2444 "the <filename>Packages</filename> files, it saves a lot of disk space on "
2445 "Debian mirrors.  Separating out architecture-independent data also reduces "
2446 "processing time of <command>lintian</command> (see <xref linkend=\"tools-lint"
2447 "\"/> ) when run over the entire Debian archive."
2448 msgstr ""
2449
2450 # type: Content of: <chapter><section><section><title>
2451 #. type: Content of: <chapter><section><section><title>
2452 #: best-pkging-practices.dbk:1613
2453 msgid "Needing a certain locale during build"
2454 msgstr ""
2455
2456 # type: Content of: <chapter><section><section><para>
2457 #. type: Content of: <chapter><section><section><para>
2458 #: best-pkging-practices.dbk:1615
2459 msgid ""
2460 "If you need a certain locale during build, you can create a temporary file "
2461 "via this trick:"
2462 msgstr ""
2463
2464 # type: Content of: <chapter><section><section><para>
2465 #. type: Content of: <chapter><section><section><para>
2466 #: best-pkging-practices.dbk:1619
2467 msgid ""
2468 "If you set <varname>LOCPATH</varname> to the equivalent of <filename>/usr/"
2469 "lib/locale</filename>, and <varname>LC_ALL</varname> to the name of the "
2470 "locale you generate, you should get what you want without being root.  "
2471 "Something like this:"
2472 msgstr ""
2473
2474 # type: Content of: <chapter><section><section><screen>
2475 #. type: Content of: <chapter><section><section><screen>
2476 #: best-pkging-practices.dbk:1624
2477 #, fuzzy, no-wrap
2478 msgid ""
2479 "LOCALE_PATH=debian/tmpdir/usr/lib/locale\n"
2480 "LOCALE_NAME=en_IN\n"
2481 "LOCALE_CHARSET=UTF-8\n"
2482 "\n"
2483 "mkdir -p $LOCALE_PATH\n"
2484 "localedef -i $LOCALE_NAME.$LOCALE_CHARSET -f $LOCALE_CHARSET $LOCALE_PATH/$LOCALE_NAME.$LOCALE_CHARSET\n"
2485 "\n"
2486 "# Using the locale\n"
2487 "LOCPATH=$LOCALE_PATH LC_ALL=$LOCALE_NAME.$LOCALE_CHARSET date\n"
2488 msgstr ""
2489 "\n"
2490 "LOCALE_PATH=debian/tmpdir/usr/lib/locale\n"
2491 "LOCALE_NAME=en_IN\n"
2492 "LOCALE_CHARSET=UTF-8\n"
2493 "\n"
2494 "mkdir -p $LOCALE_PATH\n"
2495 "localedef -i $LOCALE_NAME.$LOCALE_CHARSET -f $LOCALE_CHARSET $LOCALE_PATH/$LOCALE_NAME.$LOCALE_CHARSET\n"
2496 "\n"
2497 "# locale を使う\n"
2498 "LOCPATH=$LOCALE_PATH LC_ALL=$LOCALE_NAME.$LOCALE_CHARSET date\n"
2499
2500 # type: Content of: <chapter><section><section><title>
2501 #. type: Content of: <chapter><section><section><title>
2502 #: best-pkging-practices.dbk:1637
2503 msgid "Make transition packages deborphan compliant"
2504 msgstr ""
2505
2506 # type: Content of: <chapter><section><section><para>
2507 #. type: Content of: <chapter><section><section><para>
2508 #: best-pkging-practices.dbk:1639
2509 msgid ""
2510 "Deborphan is a program for helping users to detect which packages can safely "
2511 "be removed from the system, i.e.  the ones that have no packages depending "
2512 "on them.  The default operation is to search only within the libs and "
2513 "oldlibs sections, to hunt down unused libraries.  But when passed the right "
2514 "argument, it tries to catch other useless packages."
2515 msgstr ""
2516
2517 # type: Content of: <chapter><section><section><para>
2518 #. type: Content of: <chapter><section><section><para>
2519 #: best-pkging-practices.dbk:1646
2520 msgid ""
2521 "For example, with <literal>--guess-dummy</literal>, <command>deborphan</"
2522 "command> tries to search all transitional packages which were needed for "
2523 "upgrade but which can now safely be removed.  For that, it looks for the "
2524 "string dummy or transitional in their short description."
2525 msgstr ""
2526
2527 # type: Content of: <chapter><section><section><para>
2528 #. type: Content of: <chapter><section><section><para>
2529 #: best-pkging-practices.dbk:1653
2530 msgid ""
2531 "So, when you are creating such a package, please make sure to add this text "
2532 "to your short description.  If you are looking for examples, just run: "
2533 "<command>apt-cache search .|grep dummy</command> or <command>apt-cache "
2534 "search .|grep transitional</command>."
2535 msgstr ""
2536
2537 # type: Content of: <chapter><section><section><title>
2538 #. type: Content of: <chapter><section><section><title>
2539 #: best-pkging-practices.dbk:1661
2540 msgid "Best practices for <filename>orig.tar.gz</filename> files"
2541 msgstr ""
2542
2543 # type: Content of: <chapter><section><section><para>
2544 #. type: Content of: <chapter><section><section><para>
2545 #: best-pkging-practices.dbk:1663
2546 msgid ""
2547 "There are two kinds of original source tarballs: Pristine source and "
2548 "repackaged upstream source."
2549 msgstr ""
2550
2551 # type: Content of: <chapter><section><section><section><title>
2552 #. type: Content of: <chapter><section><section><section><title>
2553 #: best-pkging-practices.dbk:1667
2554 msgid "Pristine source"
2555 msgstr ""
2556
2557 #. type: Content of: <chapter><section><section><section><para><footnote><para>
2558 #: best-pkging-practices.dbk:1671
2559 msgid ""
2560 "We cannot prevent upstream authors from changing the tarball they distribute "
2561 "without also incrementing the version number, so there can be no guarantee "
2562 "that a pristine tarball is identical to what upstream <emphasis>currently</"
2563 "emphasis> distributing at any point in time.  All that can be expected is "
2564 "that it is identical to something that upstream once <emphasis>did</"
2565 "emphasis> distribute.  If a difference arises later (say, if upstream "
2566 "notices that he wasn't using maximal compression in his original "
2567 "distribution and then re-<command>gzip</command>s it), that's just too bad.  "
2568 "Since there is no good way to upload a new <literal>.orig.tar.{gz,bz2}</"
2569 "literal> for the same version, there is not even any point in treating this "
2570 "situation as a bug."
2571 msgstr ""
2572
2573 #. type: Content of: <chapter><section><section><section><para>
2574 #: best-pkging-practices.dbk:1669
2575 msgid ""
2576 "The defining characteristic of a pristine source tarball is that the "
2577 "<literal>.orig.tar.{gz,bz2}</literal> file is byte-for-byte identical to a "
2578 "tarball officially distributed by the upstream author.  <placeholder type="
2579 "\"footnote\" id=\"0\"/> This makes it possible to use checksums to easily "
2580 "verify that all changes between Debian's version and upstream's are "
2581 "contained in the Debian diff.  Also, if the original source is huge, "
2582 "upstream authors and others who already have the upstream tarball can save "
2583 "download time if they want to inspect your packaging in detail."
2584 msgstr ""
2585
2586 # type: Content of: <chapter><section><section><section><para>
2587 #. type: Content of: <chapter><section><section><section><para>
2588 #: best-pkging-practices.dbk:1689
2589 msgid ""
2590 "There is no universally accepted guidelines that upstream authors follow "
2591 "regarding to the directory structure inside their tarball, but <command>dpkg-"
2592 "source</command> is nevertheless able to deal with most upstream tarballs as "
2593 "pristine source.  Its strategy is equivalent to the following:"
2594 msgstr ""
2595
2596 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2597 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2598 #: best-pkging-practices.dbk:1697
2599 msgid "It unpacks the tarball in an empty temporary directory by doing"
2600 msgstr ""
2601
2602 # type: Content of: <chapter><section><section><section><orderedlist><listitem><screen>
2603 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><screen>
2604 #: best-pkging-practices.dbk:1700
2605 #, fuzzy, no-wrap
2606 msgid "zcat path/to/&lt;packagename&gt;_&lt;upstream-version&gt;.orig.tar.gz | tar xf -\n"
2607 msgstr ""
2608 "\n"
2609 "zcat path/to/&lt;packagename&gt;_&lt;upstream-version&gt;.orig.tar.gz | tar xf -\n"
2610
2611 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2612 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2613 #: best-pkging-practices.dbk:1705
2614 msgid ""
2615 "If, after this, the temporary directory contains nothing but one directory "
2616 "and no other files, <command>dpkg-source</command> renames that directory to "
2617 "<literal>&lt;packagename&gt;-&lt;upstream-version&gt;(.orig)</literal>.  The "
2618 "name of the top-level directory in the tarball does not matter, and is "
2619 "forgotten."
2620 msgstr ""
2621
2622 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2623 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2624 #: best-pkging-practices.dbk:1714
2625 msgid ""
2626 "Otherwise, the upstream tarball must have been packaged without a common top-"
2627 "level directory (shame on the upstream author!).  In this case, "
2628 "<command>dpkg-source</command> renames the temporary directory "
2629 "<emphasis>itself</emphasis> to <literal>&lt;packagename&gt;-&lt;upstream-"
2630 "version&gt;(.orig)</literal>."
2631 msgstr ""
2632
2633 # type: Content of: <chapter><section><section><section><title>
2634 #. type: Content of: <chapter><section><section><section><title>
2635 #: best-pkging-practices.dbk:1725
2636 msgid "Repackaged upstream source"
2637 msgstr "upstream のソースをパッケージしなおす"
2638
2639 # type: Content of: <chapter><section><section><section><para>
2640 #. type: Content of: <chapter><section><section><section><para>
2641 #: best-pkging-practices.dbk:1727
2642 msgid ""
2643 "You <emphasis role=\"strong\">should</emphasis> upload packages with a "
2644 "pristine source tarball if possible, but there are various reasons why it "
2645 "might not be possible.  This is the case if upstream does not distribute the "
2646 "source as gzipped tar at all, or if upstream's tarball contains non-DFSG-"
2647 "free material that you must remove before uploading."
2648 msgstr ""
2649
2650 #. type: Content of: <chapter><section><section><section><para>
2651 #: best-pkging-practices.dbk:1734
2652 msgid ""
2653 "In these cases the developer must construct a suitable <literal>.orig.tar."
2654 "{gz,bz2} </literal> file himself.  We refer to such a tarball as a "
2655 "repackaged upstream source.  Note that a repackaged upstream source is "
2656 "different from a Debian-native package.  A repackaged source still comes "
2657 "with Debian-specific changes in a separate <literal>.diff.gz</literal> or "
2658 "<literal>.debian.tar.{gz,bz2}</literal> and still has a version number "
2659 "composed of <literal>&lt;upstream-version&gt;</literal> and <literal>&lt;"
2660 "debian-revision&gt;</literal>."
2661 msgstr ""
2662
2663 # type: Content of: <chapter><section><section><section><para>
2664 #. type: Content of: <chapter><section><section><section><para>
2665 #: best-pkging-practices.dbk:1743
2666 msgid ""
2667 "There may be cases where it is desirable to repackage the source even though "
2668 "upstream distributes a <literal>.tar.gz</literal> that could in principle be "
2669 "used in its pristine form.  The most obvious is if <emphasis>significant</"
2670 "emphasis> space savings can be achieved by recompressing the tar archive or "
2671 "by removing genuinely useless cruft from the upstream archive.  Use your own "
2672 "discretion here, but be prepared to defend your decision if you repackage "
2673 "source that could have been pristine."
2674 msgstr ""
2675
2676 #. type: Content of: <chapter><section><section><section><para>
2677 #: best-pkging-practices.dbk:1752
2678 msgid "A repackaged <literal>.orig.tar.{gz,bz2}</literal>"
2679 msgstr ""
2680
2681 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2682 #: best-pkging-practices.dbk:1757
2683 msgid ""
2684 "should be documented in the resulting source package.  Detailed information "
2685 "on how the repackaged source was obtained, and on how this can be reproduced "
2686 "should be provided in <filename>debian/copyright</filename>.  It is also a "
2687 "good idea to provide a <literal>get-orig-source</literal> target in your "
2688 "<filename>debian/rules</filename> file that repeats the process, as "
2689 "described in the Policy Manual, <ulink url=\"&url-debian-policy;ch-source."
2690 "html#s-debianrules\">Main building script: debian/rules</ulink>."
2691 msgstr ""
2692
2693 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para><footnote><para>
2694 #: best-pkging-practices.dbk:1772
2695 msgid ""
2696 "As a special exception, if the omission of non-free files would lead to the "
2697 "source failing to build without assistance from the Debian diff, it might be "
2698 "appropriate to instead edit the files, omitting only the non-free parts of "
2699 "them, and/or explain the situation in a README.source file in the root of "
2700 "the source tree.  But in that case please also urge the upstream author to "
2701 "make the non-free components easier seperable from the rest of the source."
2702 msgstr ""
2703
2704 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2705 #: best-pkging-practices.dbk:1770
2706 msgid ""
2707 "<emphasis role=\"strong\">should not</emphasis> contain any file that does "
2708 "not come from the upstream author(s), or whose contents has been changed by "
2709 "you.  <placeholder type=\"footnote\" id=\"0\"/>"
2710 msgstr ""
2711
2712 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2713 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2714 #: best-pkging-practices.dbk:1783
2715 msgid ""
2716 "<emphasis role=\"strong\">should</emphasis>, except where impossible for "
2717 "legal reasons, preserve the entire building and portablility infrastructure "
2718 "provided by the upstream author.  For example, it is not a sufficient reason "
2719 "for omitting a file that it is used only when building on MS-DOS.  "
2720 "Similarly, a Makefile provided by upstream should not be omitted even if the "
2721 "first thing your <filename>debian/rules</filename> does is to overwrite it "
2722 "by running a configure script."
2723 msgstr ""
2724
2725 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2726 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2727 #: best-pkging-practices.dbk:1792
2728 msgid ""
2729 "(<emphasis>Rationale:</emphasis> It is common for Debian users who need to "
2730 "build software for non-Debian platforms to fetch the source from a Debian "
2731 "mirror rather than trying to locate a canonical upstream distribution point)."
2732 msgstr ""
2733
2734 # type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2735 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2736 #: best-pkging-practices.dbk:1799
2737 msgid ""
2738 "<emphasis role=\"strong\">should</emphasis> use <literal>&lt;packagename&gt;-"
2739 "&lt;upstream-version&gt;.orig</literal> as the name of the top-level "
2740 "directory in its tarball.  This makes it possible to distinguish pristine "
2741 "tarballs from repackaged ones."
2742 msgstr ""
2743
2744 #. type: Content of: <chapter><section><section><section><orderedlist><listitem><para>
2745 #: best-pkging-practices.dbk:1807
2746 msgid ""
2747 "<emphasis role=\"strong\">should</emphasis> be gzipped or bzipped with "
2748 "maximal compression."
2749 msgstr ""
2750
2751 #. type: Content of: <chapter><section><section><section><title>
2752 #: best-pkging-practices.dbk:1814
2753 msgid "Changing binary files"
2754 msgstr ""
2755
2756 #. type: Content of: <chapter><section><section><section><para>
2757 #: best-pkging-practices.dbk:1816
2758 msgid ""
2759 "Sometimes it is necessary to change binary files contained in the original "
2760 "tarball, or to add binary files that are not in it. This is fully supported "
2761 "when using source packages in “3.0 (quilt)” format, see the "
2762 "<citerefentry><refentrytitle>dpkg-source</refentrytitle><manvolnum>1</"
2763 "manvolnum></citerefentry> manual page for details. When using the older "
2764 "format “1.0”, binary files can't be stored in the <filename>.diff.gz</"
2765 "filename> so you must store an <command>uuencode</command>d (or similar) "
2766 "version of the file(s)  and decode it at build time in <filename>debian/"
2767 "rules</filename> (and move it in its official location)."
2768 msgstr ""
2769
2770 # type: Content of: <chapter><section><section><title>
2771 #. type: Content of: <chapter><section><section><title>
2772 #: best-pkging-practices.dbk:1831
2773 msgid "Best practices for debug packages"
2774 msgstr ""
2775
2776 # type: Content of: <chapter><section><section><para>
2777 #. type: Content of: <chapter><section><section><para>
2778 #: best-pkging-practices.dbk:1833
2779 msgid ""
2780 "A debug package is a package with a name ending in -dbg, that contains "
2781 "additional information that gdb can use.  Since Debian binaries are stripped "
2782 "by default, debugging information, including function names and line "
2783 "numbers, is otherwise not available when running gdb on Debian binaries.  "
2784 "Debug packages allow users who need this additional debugging information to "
2785 "install it, without bloating a regular system with the information."
2786 msgstr ""
2787
2788 # type: Content of: <chapter><section><section><para>
2789 #. type: Content of: <chapter><section><section><para>
2790 #: best-pkging-practices.dbk:1841
2791 msgid ""
2792 "It is up to a package's maintainer whether to create a debug package or "
2793 "not.  Maintainers are encouraged to create debug packages for library "
2794 "packages, since this can aid in debugging many programs linked to a "
2795 "library.  In general, debug packages do not need to be added for all "
2796 "programs; doing so would bloat the archive.  But if a maintainer finds that "
2797 "users often need a debugging version of a program, it can be worthwhile to "
2798 "make a debug package for it.  Programs that are core infrastructure, such as "
2799 "apache and the X server are also good candidates for debug packages."
2800 msgstr ""
2801
2802 # type: Content of: <chapter><section><section><para>
2803 #. type: Content of: <chapter><section><section><para>
2804 #: best-pkging-practices.dbk:1851
2805 msgid ""
2806 "Some debug packages may contain an entire special debugging build of a "
2807 "library or other binary, but most of them can save space and build time by "
2808 "instead containing separated debugging symbols that gdb can find and load on "
2809 "the fly when debugging a program or library.  The convention in Debian is to "
2810 "keep these symbols in <filename>/usr/lib/debug/<replaceable>path</"
2811 "replaceable></filename>, where <replaceable>path</replaceable> is the path "
2812 "to the executable or library.  For example, debugging symbols for <filename>/"
2813 "usr/bin/foo</filename> go in <filename>/usr/lib/debug/usr/bin/foo</"
2814 "filename>, and debugging symbols for <filename>/usr/lib/libfoo.so.1</"
2815 "filename> go in <filename>/usr/lib/debug/usr/lib/libfoo.so.1</filename>."
2816 msgstr ""
2817
2818 # type: Content of: <chapter><section><section><para>
2819 #. type: Content of: <chapter><section><section><para>
2820 #: best-pkging-practices.dbk:1863
2821 msgid ""
2822 "The debugging symbols can be extracted from an object file using <command> "
2823 "objcopy --only-keep-debug</command>.  Then the object file can be stripped, "
2824 "and <command>objcopy --add-gnu-debuglink</command> used to specify the path "
2825 "to the debugging symbol file.  <citerefentry> <refentrytitle>objcopy</"
2826 "refentrytitle> <manvolnum>1</manvolnum> </citerefentry> explains in detail "
2827 "how this works."
2828 msgstr ""
2829
2830 # type: Content of: <chapter><section><section><para>
2831 #. type: Content of: <chapter><section><section><para>
2832 #: best-pkging-practices.dbk:1871
2833 msgid ""
2834 "The <command>dh_strip</command> command in debhelper supports creating debug "
2835 "packages, and can take care of using <command>objcopy</command> to separate "
2836 "out the debugging symbols for you.  If your package uses debhelper, all you "
2837 "need to do is call <command>dh_strip --dbg-package=libfoo-dbg</command>, and "
2838 "add an entry to <filename>debian/control</filename> for the debug package."
2839 msgstr ""
2840
2841 #. type: Content of: <chapter><section><section><para>
2842 #: best-pkging-practices.dbk:1878
2843 msgid ""
2844 "Note that the debug package should depend on the package that it provides "
2845 "debugging symbols for, and this dependency should be versioned.  For example:"
2846 msgstr ""
2847
2848 # type: Content of: <chapter><section><section><screen>
2849 #. type: Content of: <chapter><section><section><screen>
2850 #: best-pkging-practices.dbk:1882
2851 #, fuzzy, no-wrap
2852 msgid "Depends: libfoo (= ${binary:Version})\n"
2853 msgstr ""
2854 "\n"
2855 "Depends: libfoo (= ${binary:Version})\n"