1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../general.ent">
8 <sect1 id="ch-system-gettext" role="wrap">
9 <?dbhtml filename="gettext.html"?>
11 <sect1info condition="script">
12 <productname>gettext</productname>
13 <productnumber>&gettext-version;</productnumber>
14 <address>&gettext-url;</address>
17 <title>Gettext-&gettext-version;</title>
19 <indexterm zone="ch-system-gettext">
20 <primary sortas="a-Gettext">Gettext</primary>
23 <sect2 role="package">
26 <para>The Gettext package contains utilities for internationalization and
27 localization. These allow programs to be compiled with NLS (Native Language
28 Support), enabling them to output messages in the user's native
32 <segtitle>&buildtime;</segtitle>
33 <segtitle>&diskspace;</segtitle>
36 <seg>&gettext-fin-sbu;</seg>
37 <seg>&gettext-fin-du;</seg>
43 <sect2 role="installation">
44 <title>Installation of Gettext</title>
46 <para>Prepare Gettext for compilation:</para>
48 <screen><userinput remap="configure">./configure --prefix=/usr \
50 --docdir=/usr/share/doc/gettext-&gettext-version;</userinput></screen>
52 <para>Compile the package:</para>
54 <!--<screen><userinput remap="make">make BISON_LOCALEDIR=/usr/share/locale</userinput></screen>-->
55 <screen><userinput remap="make">make</userinput></screen>
58 <title>The meaning of the make parameter:</title>
61 <term><parameter>BISON_LOCALEDIR=/usr/share/locale</parameter></term>
63 <para>Since bison is not yet installed in /usr, configure hardcodes
64 the directory containing translations for the bison program (the
65 "locale" directory) as /tools/share/locale. Passing this variable
66 to make allows overriding the choice made by configure.</para>
72 <para>To test the results (this takes a long time, around 3 SBUs),
75 <screen><userinput remap="test">make check</userinput></screen>
77 <para>Install the package:</para>
79 <screen><userinput remap="install">make install
80 chmod -v 0755 /usr/lib/preloadable_libintl.so</userinput></screen>
84 <sect2 id="contents-gettext" role="content">
85 <title>Contents of Gettext</title>
88 <segtitle>Installed programs</segtitle>
89 <segtitle>Installed libraries</segtitle>
90 <segtitle>Installed directories</segtitle>
93 <seg>autopoint, envsubst, gettext, gettext.sh,
94 gettextize, msgattrib, msgcat, msgcmp, msgcomm, msgconv, msgen,
95 msgexec, msgfilter, msgfmt, msggrep, msginit, msgmerge, msgunfmt, msguniq,
96 ngettext, recode-sr-latin, and xgettext</seg>
97 <seg>libasprintf.so, libgettextlib.so, libgettextpo.so,
98 libgettextsrc.so, libtextstyle.so, and preloadable_libintl.so</seg>
99 <seg>/usr/lib/gettext, /usr/share/doc/gettext-&gettext-version;,
100 /usr/share/gettext, and /usr/share/gettext-0.19.8</seg>
105 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
106 <?dbfo list-presentation="list"?>
107 <?dbhtml list-presentation="table"?>
109 <varlistentry id="autopoint">
110 <term><command>autopoint</command></term>
112 <para>Copies standard Gettext infrastructure files into a source
114 <indexterm zone="ch-system-gettext autopoint">
115 <primary sortas="b-autopoint">autopoint</primary>
120 <varlistentry id="envsubst">
121 <term><command>envsubst</command></term>
123 <para>Substitutes environment variables in shell format strings</para>
124 <indexterm zone="ch-system-gettext envsubst">
125 <primary sortas="b-envsubst">envsubst</primary>
130 <varlistentry id="gettext">
131 <term><command>gettext</command></term>
133 <para>Translates a natural language message into the user's language
134 by looking up the translation in a message catalog</para>
135 <indexterm zone="ch-system-gettext gettext">
136 <primary sortas="b-gettext">gettext</primary>
141 <varlistentry id="gettext.sh">
142 <term><command>gettext.sh</command></term>
144 <para>Primarily serves as a shell function library for gettext</para>
145 <indexterm zone="ch-system-gettext gettext.sh">
146 <primary sortas="b-gettext.sh">gettext.sh</primary>
151 <varlistentry id="gettextize">
152 <term><command>gettextize</command></term>
154 <para>Copies all standard Gettext files into the given top-level
155 directory of a package to begin internationalizing it</para>
156 <indexterm zone="ch-system-gettext gettextize">
157 <primary sortas="b-gettextize">gettextize</primary>
162 <varlistentry id="msgattrib">
163 <term><command>msgattrib</command></term>
165 <para>Filters the messages of a translation catalog according to their
166 attributes and manipulates the attributes</para>
167 <indexterm zone="ch-system-gettext msgattrib">
168 <primary sortas="b-msgattrib">msgattrib</primary>
173 <varlistentry id="msgcat">
174 <term><command>msgcat</command></term>
176 <para>Concatenates and merges the given
177 <filename class="extension">.po</filename> files</para>
178 <indexterm zone="ch-system-gettext msgcat">
179 <primary sortas="b-msgcat">msgcat</primary>
184 <varlistentry id="msgcmp">
185 <term><command>msgcmp</command></term>
187 <para>Compares two <filename class="extension">.po</filename>
188 files to check that both contain the same set of msgid strings</para>
189 <indexterm zone="ch-system-gettext msgcmp">
190 <primary sortas="b-msgcmp">msgcmp</primary>
195 <varlistentry id="msgcomm">
196 <term><command>msgcomm</command></term>
198 <para>Finds the messages that are common to the given
199 <filename class="extension">.po</filename> files</para>
200 <indexterm zone="ch-system-gettext msgcomm">
201 <primary sortas="b-msgcomm">msgcomm</primary>
206 <varlistentry id="msgconv">
207 <term><command>msgconv</command></term>
209 <para>Converts a translation catalog to a different character
211 <indexterm zone="ch-system-gettext msgconv">
212 <primary sortas="b-msgconv">msgconv</primary>
217 <varlistentry id="msgen">
218 <term><command>msgen</command></term>
220 <para>Creates an English translation catalog</para>
221 <indexterm zone="ch-system-gettext msgen">
222 <primary sortas="b-msgen">msgen</primary>
227 <varlistentry id="msgexec">
228 <term><command>msgexec</command></term>
230 <para>Applies a command to all translations of a translation
232 <indexterm zone="ch-system-gettext msgexec">
233 <primary sortas="b-msgexec">msgexec</primary>
238 <varlistentry id="msgfilter">
239 <term><command>msgfilter</command></term>
241 <para>Applies a filter to all translations of a translation
243 <indexterm zone="ch-system-gettext msgfilter">
244 <primary sortas="b-msgfilter">msgfilter</primary>
249 <varlistentry id="msgfmt">
250 <term><command>msgfmt</command></term>
252 <para>Generates a binary message catalog from a translation
254 <indexterm zone="ch-system-gettext msgfmt">
255 <primary sortas="b-msgfmt">msgfmt</primary>
260 <varlistentry id="msggrep">
261 <term><command>msggrep</command></term>
263 <para>Extracts all messages of a translation catalog that match a
264 given pattern or belong to some given source files</para>
265 <indexterm zone="ch-system-gettext msggrep">
266 <primary sortas="b-msggrep">msggrep</primary>
271 <varlistentry id="msginit">
272 <term><command>msginit</command></term>
274 <para>Creates a new <filename class="extension">.po</filename> file,
275 initializing the meta information with values from the user's
277 <indexterm zone="ch-system-gettext msginit">
278 <primary sortas="b-msginit">msginit</primary>
283 <varlistentry id="msgmerge">
284 <term><command>msgmerge</command></term>
286 <para>Combines two raw translations into a single file</para>
287 <indexterm zone="ch-system-gettext msgmerge">
288 <primary sortas="b-msgmerge">msgmerge</primary>
293 <varlistentry id="msgunfmt">
294 <term><command>msgunfmt</command></term>
296 <para>Decompiles a binary message catalog into raw translation
298 <indexterm zone="ch-system-gettext msgunfmt">
299 <primary sortas="b-msgunfmt">msgunfmt</primary>
304 <varlistentry id="msguniq">
305 <term><command>msguniq</command></term>
307 <para>Unifies duplicate translations in a translation catalog</para>
308 <indexterm zone="ch-system-gettext msguniq">
309 <primary sortas="b-msguniq">msguniq</primary>
314 <varlistentry id="ngettext">
315 <term><command>ngettext</command></term>
317 <para>Displays native language translations of a textual message whose
318 grammatical form depends on a number</para>
319 <indexterm zone="ch-system-gettext ngettext">
320 <primary sortas="b-ngettext">ngettext</primary>
325 <varlistentry id="recode-sr-latin">
326 <term><command>recode-sr-latin</command></term>
328 <para>Recodes Serbian text from Cyrillic to Latin script</para>
329 <indexterm zone="ch-system-gettext recode-sr-latin">
330 <primary sortas="b-recode-sr-latin">recode-sr-latin</primary>
335 <varlistentry id="xgettext">
336 <term><command>xgettext</command></term>
338 <para>Extracts the translatable message lines from the given source
339 files to make the first translation template</para>
340 <indexterm zone="ch-system-gettext xgettext">
341 <primary sortas="b-xgettext">xgettext</primary>
346 <varlistentry id="libasprintf">
347 <term><filename class="libraryfile">libasprintf</filename></term>
349 <para>defines the <emphasis>autosprintf</emphasis> class, which makes
350 C formatted output routines usable in C++ programs, for use with the
351 <emphasis><string></emphasis> strings and the
352 <emphasis><iostream></emphasis> streams</para>
353 <indexterm zone="ch-system-gettext libasprintf">
354 <primary sortas="c-libasprintf">libasprintf</primary>
359 <varlistentry id="libgettextlib">
360 <term><filename class="libraryfile">libgettextlib</filename></term>
362 <para>a private library containing common routines used by the
363 various Gettext programs; these are not intended for general use</para>
364 <indexterm zone="ch-system-gettext libgettextlib">
365 <primary sortas="c-libgettextlib">libgettextlib</primary>
370 <varlistentry id="libgettextpo">
371 <term><filename class="libraryfile">libgettextpo</filename></term>
373 <para>Used to write specialized programs that process
374 <filename class="extension">.po</filename> files; this library is
375 used when the standard applications shipped with Gettext (such as
376 <command>msgcomm</command>, <command>msgcmp</command>,
377 <command>msgattrib</command>, and <command>msgen</command>) will
379 <indexterm zone="ch-system-gettext libgettextpo">
380 <primary sortas="c-libgettextpo">libgettextpo</primary>
385 <varlistentry id="libgettextsrc">
386 <term><filename class="libraryfile">libgettextsrc</filename></term>
388 <para>A private library containing common routines used by the
389 various Gettext programs; these are not intended for general use</para>
390 <indexterm zone="ch-system-gettext libgettextsrc">
391 <primary sortas="c-libgettextsrc">libgettextsrc</primary>
396 <varlistentry id="libtextstyle">
397 <term><filename class="libraryfile">libtextstyle</filename></term>
399 <para>Text styling library</para>
400 <indexterm zone="ch-system-gettext libtextstyle">
401 <primary sortas="c-libtextstyle">libtextstyle</primary>
406 <varlistentry id="preloadable_libintl">
407 <term><filename class="libraryfile">preloadable_libintl</filename></term>
409 <para>A library, intended to be used by LD_PRELOAD that assists
410 <filename class="libraryfile">libintl</filename> in logging
411 untranslated messages</para>
412 <indexterm zone="ch-system-gettext preloadable_libintl">
413 <primary sortas="c-preloadable_libintl">preloadable_libintl</primary>