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