1MSGFMT(1) User Commands MSGFMT(1)
2
3
4
6 msgfmt - compile message catalog to binary format
7
9 msgfmt [OPTION] filename.po ...
10
12 Generate binary message catalog from textual translation description.
13
14 Mandatory arguments to long options are mandatory for short options
15 too. Similarly for optional arguments.
16
17 Input file location:
18 filename.po ...
19 input files
20
21 -D, --directory=DIRECTORY
22 add DIRECTORY to list for input files search
23
24 If input file is -, standard input is read.
25
26 Operation mode:
27 -j, --java
28 Java mode: generate a Java ResourceBundle class
29
30 --java2
31 like --java, and assume Java2 (JDK 1.2 or higher)
32
33 --csharp
34 C# mode: generate a .NET .dll file
35
36 --csharp-resources
37 C# resources mode: generate a .NET .resources file
38
39 --tcl Tcl mode: generate a tcl/msgcat .msg file
40
41 --qt Qt mode: generate a Qt .qm file
42
43 --desktop
44 Desktop Entry mode: generate a .desktop file
45
46 --xml XML mode: generate XML file
47
48 Output file location:
49 -o, --output-file=FILE
50 write output to specified file
51
52 --strict
53 enable strict Uniforum mode
54
55 If output file is -, output is written to standard output.
56
57 Output file location in Java mode:
58 -r, --resource=RESOURCE
59 resource name
60
61 -l, --locale=LOCALE
62 locale name, either language or language_COUNTRY
63
64 --source
65 produce a .java file, instead of a .class file
66
67 -d DIRECTORY
68 base directory of classes directory hierarchy
69
70 The class name is determined by appending the locale name to the re‐
71 source name, separated with an underscore. The -d option is mandatory.
72 The class is written under the specified directory.
73
74 Output file location in C# mode:
75 -r, --resource=RESOURCE
76 resource name
77
78 -l, --locale=LOCALE
79 locale name, either language or language_COUNTRY
80
81 -d DIRECTORY
82 base directory for locale dependent .dll files
83
84 The -l and -d options are mandatory. The .dll file is written in a
85 subdirectory of the specified directory whose name depends on the lo‐
86 cale.
87
88 Output file location in Tcl mode:
89 -l, --locale=LOCALE
90 locale name, either language or language_COUNTRY
91
92 -d DIRECTORY
93 base directory of .msg message catalogs
94
95 The -l and -d options are mandatory. The .msg file is written in the
96 specified directory.
97
98 Desktop Entry mode options:
99 -l, --locale=LOCALE
100 locale name, either language or language_COUNTRY
101
102 -o, --output-file=FILE
103 write output to specified file
104
105 --template=TEMPLATE
106 a .desktop file used as a template
107
108 -d DIRECTORY
109 base directory of .po files
110
111 -kWORD, --keyword=WORD
112 look for WORD as an additional keyword
113
114 -k, --keyword
115 do not to use default keywords
116
117 The -l, -o, and --template options are mandatory. If -D is specified,
118 input files are read from the directory instead of the command line ar‐
119 guments.
120
121 XML mode options:
122 -l, --locale=LOCALE
123 locale name, either language or language_COUNTRY
124
125 -L, --language=NAME
126 recognise the specified XML language
127
128 -o, --output-file=FILE
129 write output to specified file
130
131 --template=TEMPLATE
132 an XML file used as a template
133
134 -d DIRECTORY
135 base directory of .po files
136
137 The -l, -o, and --template options are mandatory. If -D is specified,
138 input files are read from the directory instead of the command line ar‐
139 guments.
140
141 Input file syntax:
142 -P, --properties-input
143 input files are in Java .properties syntax
144
145 --stringtable-input
146 input files are in NeXTstep/GNUstep .strings syntax
147
148 Input file interpretation:
149 -c, --check
150 perform all the checks implied by --check-format,
151 --check-header, --check-domain
152
153 --check-format
154 check language dependent format strings
155
156 --check-header
157 verify presence and contents of the header entry
158
159 --check-domain
160 check for conflicts between domain directives and the --out‐
161 put-file option
162
163 -C, --check-compatibility
164 check that GNU msgfmt behaves like X/Open msgfmt
165
166 --check-accelerators[=CHAR]
167 check presence of keyboard accelerators for menu items
168
169 -f, --use-fuzzy
170 use fuzzy entries in output
171
172 Output details:
173 --no-convert
174 don't convert the messages to UTF-8 encoding
175
176 --no-redundancy
177 don't pre-expand ISO C 99 <inttypes.h> format string directive
178 macros
179
180 -a, --alignment=NUMBER
181 align strings to NUMBER bytes (default: 1)
182
183 --endianness=BYTEORDER
184 write out 32-bit numbers in the given byte order (big or little,
185 default depends on platform)
186
187 --no-hash
188 binary file will not include the hash table
189
190 Informative output:
191 -h, --help
192 display this help and exit
193
194 -V, --version
195 output version information and exit
196
197 --statistics
198 print statistics about translations
199
200 -v, --verbose
201 increase verbosity level
202
204 Written by Ulrich Drepper.
205
207 Report bugs in the bug tracker at <https://savan‐
208 nah.gnu.org/projects/gettext> or by email to <bug-gettext@gnu.org>.
209
211 Copyright © 1995-2023 Free Software Foundation, Inc. License GPLv3+:
212 GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>
213 This is free software: you are free to change and redistribute it.
214 There is NO WARRANTY, to the extent permitted by law.
215
217 The full documentation for msgfmt is maintained as a Texinfo manual.
218 If the info and msgfmt programs are properly installed at your site,
219 the command
220
221 info msgfmt
222
223 should give you access to the complete manual.
224
225
226
227GNU gettext-tools 0.22 June 2023 MSGFMT(1)