~ubuntu-branches/ubuntu/utopic/developers-reference/utopic

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
    "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
  <!ENTITY % commondata SYSTEM "common.ent" > %commondata;
]>
<chapter id="l10n">
<title>Internationalization and Translations</title>
<para>
Debian supports an ever-increasing number of natural languages.  Even if you
are a native English speaker and do not speak any other language, it is part of
your duty as a maintainer to be aware of issues of internationalization
(abbreviated i18n because there are 18 letters between the 'i' and the 'n' in
internationalization).  Therefore, even if you are ok with English-only
programs, you should read most of this chapter.
</para>
<para>
According to <ulink
url="&url-i18n-intro;">Introduction to
i18n</ulink> from Tomohiro KUBOTA, I18N (internationalization) means
modification of a software or related technologies so that a software can
potentially handle multiple languages, customs, and so on in the world,  while
L10N (localization) means implementation of a specific language for an already
internationalized software.
</para>
<para>
l10n and i18n are interconnected, but the difficulties related to each of them
are very different.  It's not really difficult to allow a program to change the
language in which texts are displayed based on user settings, but it is very
time consuming to actually translate these messages.  On the other hand,
setting the character encoding is trivial, but adapting the code to use several
character encodings is a really hard problem.
</para>
<para>
Setting aside the i18n problems, where no general guideline can be given, there
is actually no central infrastructure for l10n within Debian which could be
compared to the buildd mechanism for porting.  So most of the work has to be
done manually.
</para>
<section id="l10n-handling">
<title>How translations are handled within Debian</title>
<para>
Handling translation of the texts contained in a package is still a manual
task, and the process depends on the kind of text you want to see translated.
</para>
<para>
For program messages, the gettext infrastructure is used most of the time.
Most of the time, the translation is handled upstream within projects like the
<ulink url="&url-l10n-tp;">Free Translation
Project</ulink>, the <ulink
url="&url-l10n-gnome;">Gnome translation
Project</ulink> or the <ulink url="&url-l10n-kde;">KDE one</ulink>.  The
only centralized resource within Debian is the <ulink
url="&url-l10n;">Central Debian translation
statistics</ulink>, where you can find some statistics about the translation
files found in the actual packages, but no real infrastructure to ease the
translation process.
</para>
<para>
An effort to translate the package descriptions started long ago, even if very
little support is offered by the tools to actually use them (i.e., only APT can
use them, when configured correctly).  Maintainers don't need to do anything
special to support translated package descriptions; translators should use the
<ulink url="&url-ddtp;">Debian Description Translation Project (DDTP)</ulink>.
</para>
<para>
For <systemitem role="package">debconf</systemitem> templates, maintainers
should use the <systemitem role="package">po-debconf</systemitem> package to ease
the work of translators, who could use the DDTP to do their work (but the
French and Brazilian teams don't).  Some statistics can be found both on the
<ulink url="&url-ddtp;">DDTP site</ulink> (about what is actually translated),
and on the <ulink url="&url-l10n;">Central Debian translation
statistics</ulink> site (about what is integrated in the packages).
</para>
<para>
For web pages, each l10n team has access to the relevant VCS, and the
statistics are available from the Central Debian translation statistics site.
</para>
<para>
For general documentation about Debian, the process is more or less the same as
for the web pages (the translators have access to the VCS), but there are no
statistics pages.
</para>
<para>
For package-specific documentation (man pages, info documents, other formats),
almost everything remains to be done.
</para>
<para>
Most notably, the KDE project handles translation of its documentation in the
same way as its program messages.
</para>
<para>
There is an effort to handle Debian-specific man pages within a <ulink
url="&url-cvsweb;manpages/?cvsroot=debian-doc">specific VCS
repository</ulink>.
</para>
</section>

<section id="l10n-faqm">
<title>I18N &amp; L10N FAQ for maintainers</title>
<para>
This is a list of problems that maintainers may face concerning i18n and l10n.
While reading this, keep in mind that there is no real consensus on these
points within Debian, and that this is only advice.  If you have a better idea
for a given problem, or if you disagree on some points, feel free to provide
your feedback, so that this document can be enhanced.
</para>
<section id="l10n-faqm-tr">
<title>How to get a given text translated</title>
<para>
To translate package descriptions or <systemitem role="package">debconf</systemitem> templates, you have nothing to do;
the DDTP infrastructure will dispatch the material to translate to volunteers
with no need for interaction from your part.
</para>
<para>
For all other material (gettext files, man pages, or other documentation), the
best solution is to put your text somewhere on the Internet, and ask on
debian-i18n for a translation in different languages.  Some translation team
members are subscribed to this list, and they will take care of the translation
and of the reviewing process.  Once they are done, you will get your translated
document from them in your mailbox.
</para>
</section>

<section id="l10n-faqm-rev">
<title>How to get a given translation reviewed</title>
<para>
From time to time, individuals translate some texts in your package and will
ask you for inclusion of the translation in the package.  This can become
problematic if you are not fluent in the given language.  It is a good idea to
send the document to the corresponding l10n mailing list, asking for a review.
Once it has been done, you should feel more confident in the quality of the
translation, and feel safe to include it in your package.
</para>
</section>

<section id="l10n-faqm-update">
<title>How to get a given translation updated</title>
<para>
If you have some translations of a given text lying around, each time you
update the original, you should ask the previous translator to update the
translation with your new changes.  Keep in mind that this task takes time; at
least one week to get the update reviewed and all.
</para>
<para>
If the translator is unresponsive, you may ask for help on the corresponding
l10n mailing list.  If everything fails, don't forget to put a warning in the
translated document, stating that the translation is somehow outdated, and that
the reader should refer to the original document if possible.
</para>
<para>
Avoid removing a translation completely because it is outdated.  Old
documentation is often better than no documentation at all for non-English
speakers.
</para>
</section>

<section id="l10n-faqm-bug">
<title>How to handle a bug report concerning a translation</title>
<para>
The best solution may be to mark the bug as forwarded to upstream, and forward
it to both the previous translator and their team (using the corresponding
debian-l10n-XXX mailing list).
<!-- TODO: add the i18n tag to the bug? -->
</para>
</section>

</section>

<section id="l10n-faqtr">
<title>I18N &amp; L10N FAQ for translators</title>
<para>
While reading this, please keep in mind that there is no general procedure
within Debian concerning these points, and that in any case, you should
collaborate with your team and the package maintainer.
</para>
<section id="l10n-faqtr-help">
<title>How to help the translation effort</title>
<para>
Choose what you want to translate, make sure that nobody is already working on
it (using your debian-l10n-XXX mailing list), translate it, get it reviewed by
other native speakers on your l10n mailing list, and provide it to the
maintainer of the package (see next point).
</para>
</section>

<section id="l10n-faqtr-inc">
<title>How to provide a translation for inclusion in a package</title>
<para>
Make sure your translation is correct (asking for review on your l10n mailing
list) before providing it for inclusion.  It will save time for everyone, and
avoid the chaos resulting in having several versions of the same document in
bug reports.
</para>
<para>
The best solution is to file a regular bug containing the translation against
the package.  Make sure to use the 'PATCH' tag, and to not use a severity
higher than 'wishlist', since the lack of translation never prevented a program
from running.
</para>
</section>

</section>

<section id="l10n-best">
<title>Best current practice concerning l10n</title>
<itemizedlist>
<listitem>
<para>
As a maintainer, never edit the translations in any way (even to reformat the
layout) without asking on the corresponding l10n mailing list.  You risk for
example breaking the encoding of the file by doing so.  Moreover, what you
consider an error can be right (or even needed) in the given language.
</para>
</listitem>
<listitem>
<para>
As a translator, if you find an error in the original text, make sure to report
it.  Translators are often the most attentive readers of a given text, and if
they don't report the errors they find, nobody will.
</para>
</listitem>
<listitem>
<para>
In any case, remember that the major issue with l10n is that it requires
several people to cooperate, and that it is very easy to start a flamewar about
small problems because of misunderstandings.  So if you have problems with your
interlocutor, ask for help on the corresponding l10n mailing list, on
debian-i18n, or even on debian-devel (but beware, l10n discussions very often
become flamewars on that list :)
</para>
</listitem>
<listitem>
<para>
In any case, cooperation can only be achieved with <emphasis
role="strong">mutual respect</emphasis>.
</para>
</listitem>
</itemizedlist>
</section>

</chapter>